@gmb/bitmark-parser-generator 3.25.1 → 3.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/bitmark-parser-generator.min.js +1 -1
- package/dist/browser/bundle-report.html +2 -2
- package/dist/cjs/ast/Builder.js +5 -1
- package/dist/cjs/ast/Builder.js.map +1 -1
- package/dist/cjs/config/Config.js +1 -1
- package/dist/cjs/config/Config.js.map +1 -1
- package/dist/cjs/config/raw/bits.js +0 -1
- package/dist/cjs/config/raw/bits.js.map +1 -1
- package/dist/cjs/generated/build-info.js +1 -1
- package/dist/cjs/generated/parser/text/text-peggy-parser.js +16 -14
- package/dist/cjs/generated/parser/text/text-peggy-parser.js.map +1 -1
- package/dist/cjs/model/enum/TextFormat.js +3 -0
- package/dist/cjs/model/enum/TextFormat.js.map +1 -1
- package/dist/cjs/parser/bitmark/peg/BitmarkPegParserProcessor.js +6 -1
- package/dist/cjs/parser/bitmark/peg/BitmarkPegParserProcessor.js.map +1 -1
- package/dist/cjs/parser/json/JsonParser.js +5 -1
- package/dist/cjs/parser/json/JsonParser.js.map +1 -1
- package/dist/esm/ast/Builder.js +5 -1
- package/dist/esm/ast/Builder.js.map +1 -1
- package/dist/esm/config/Config.js +1 -1
- package/dist/esm/config/Config.js.map +1 -1
- package/dist/esm/config/raw/bits.js +0 -1
- package/dist/esm/config/raw/bits.js.map +1 -1
- package/dist/esm/generated/build-info.js +1 -1
- package/dist/esm/generated/parser/text/text-peggy-parser.js +16 -14
- package/dist/esm/generated/parser/text/text-peggy-parser.js.map +1 -1
- package/dist/esm/model/enum/TextFormat.js +3 -0
- package/dist/esm/model/enum/TextFormat.js.map +1 -1
- package/dist/esm/parser/bitmark/peg/BitmarkPegParserProcessor.js +6 -1
- package/dist/esm/parser/bitmark/peg/BitmarkPegParserProcessor.js.map +1 -1
- package/dist/esm/parser/json/JsonParser.js +5 -1
- package/dist/esm/parser/json/JsonParser.js.map +1 -1
- package/dist/types/ast/Builder.d.ts.map +1 -1
- package/dist/types/config/raw/bits.d.ts.map +1 -1
- package/dist/types/generated/parser/text/text-peggy-parser.d.ts.map +1 -1
- package/dist/types/model/enum/TextFormat.d.ts.map +1 -1
- package/dist/types/parser/bitmark/peg/BitmarkPegParserProcessor.d.ts.map +1 -1
- package/dist/types/parser/json/JsonParser.d.ts.map +1 -1
- package/package.json +2 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.bitmarkParserGenerator=t():e.bitmarkParserGenerator=t()}(this,(()=>(()=>{"use strict";var e={4:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.AstWalkerGenerator=void 0;const i=r(5126);t.AstWalkerGenerator=class{constructor(){this.ast=new i.Ast,this.debugGenerationInline=!1,this.printed=!1}enter(e,t,r){let i;const o=this,n=`enter_${e.key}`;return this.printed||(this.printed=!0),this.debugGenerationInline&&this.writeInlineDebug(e.key,{open:!0}),"function"==typeof o[n]&&(i=o[n](e,t,r)),i}between(e,t,r,i,o){let n;const a=this,s=`between_${e.key}`;return this.debugGenerationInline&&this.writeInlineDebug(e.key,{single:!0}),"function"==typeof a[s]&&(n=a[s](e,t,r,i,o)),n}exit(e,t,r){const i=this,o=`exit_${e.key}`;this.debugGenerationInline&&this.writeInlineDebug(e.key,{close:!0}),"function"==typeof i[o]&&i[o](e,t,r)}leaf(e,t,r){const i=this,o=`leaf_${e.key}`;this.debugGenerationInline&&this.writeInlineDebug(e.key,{open:!0}),"function"==typeof i[o]&&i[o](e,t,r),this.debugGenerationInline&&this.writeInlineDebug(e.key,{close:!0})}getParentNode(e,t=1){if(e.length>t)return e[e.length-t-1]}}},21:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.personChainContentProcessor=function(e,t,r,p,u){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("person content",p);const c=e.bitContentProcessor(l.BitContentLevel.Chain,r,p.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("person TAGS",c);const{propertyTitle:y,resources:g}=c,d=i.Breakscape.unbreakscape(s.StringUtils.trimmedString(p.value),{textFormat:n.TextFormat.bitmarkMinusMinus,textLocation:a.TextLocation.tag}),f=s.StringUtils.trimmedString(y),m=function(e,t){let r;const i=[];if(t)for(const e of t.reverse())r||o.ResourceTag.image!==e.type?i.push(e):r=e;i.length>0&&(e.parser.excessResources=i,e.addWarning(`${i.length} excess resource(s) present in the [@person] chain.`));return r}(e,g),T={name:d,title:f,avatarImage:m};u.person=T};const i=r(7735),o=r(6149),n=r(385),a=r(6877),s=r(9681),l=r(3029)},98:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonStringGenerator=void 0;const o=r(6772),n=r(2497);t.JsonStringGenerator=class{constructor(e){this.writer=new o.StringWriter,this.generator=new n.JsonGenerator(this.writer,e)}generate(e){return i(this,void 0,void 0,(function*(){return yield this.generator.generate(e),this.writer.getString()}))}generateSync(e){return this.generator.generateSync(e),this.writer.getString()}}},126:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.NodeType=void 0;const i=(0,r(4718).superenum)({unknown:"unknown",action:"action",actionValue:"actionValue",activityType:"activityType",activityTypeValue:"activityTypeValue",additionalSolutions:"additionalSolutions",additionalSolutionsValue:"additionalSolutionsValue",ageRange:"ageRange",ageRangeValue:"ageRangeValue",aiGenerated:"aiGenerated",aiGeneratedValue:"aiGeneratedValue",alias:"alias",alignment:"alignment",allowedBit:"allowedBit",allowedBitValue:"allowedBitValue",alt:"alt",alternativeAnswers:"alternativeAnswers",alternativeAnswersValue:"alternativeAnswersValue",alternativeDefinitions:"alternativeDefinitions",alternativeDefinitionsValue:"alternativeDefinitionsValue",altLangTag:"altLangTag",altLangTagValue:"altLangTagValue",analyticsTag:"analyticsTag",analyticsTagValue:"analyticsTagValue",anchor:"anchor",answer:"answer",appLink:"appLink",attrs:"attrs",audio:"audio",audioEmbed:"audioEmbed",audioLink:"audioLink",author:"author",authorValue:"authorValue",availableClassifications:"availableClassifications",availableClassificationsValue:"availableClassificationsValue",avatarImage:"avatarImage",backgroundWallpaper:"backgroundWallpaper",backgroundWallpaperValue:"backgroundWallpaperValue",bitLevel:"bitLevel",bitmarkAst:"bitmarkAst",bitmarkVersion:"bitmarkVersion",bits:"bits",bitsValue:"bitsValue",bitType:"bitType",blockId:"blockId",blockIdValue:"blockIdValue",body:"body",bodyValue:"bodyValue",bodyBit:"bodyBit",bodyBits:"bodyBits",bodyJson:"bodyJson",bodyParts:"bodyParts",bodyPartsValue:"bodyPartsValue",bodyPartText:"bodyPartText",bodyText:"bodyText",book:"book",bookValue:"bookValue",bookAlias:"bookAlias",bookAliasValue:"bookAliasValue",bookDiff:"bookDiff",bookDiffValue:"bookDiffValue",bot:"bot",botResponses:"botResponses",botResponsesValue:"botResponsesValue",botValue:"botValue",bubbleTag:"bubbleTag",bubbleTagValue:"bubbleTagValue",buttonCaption:"buttonCaption",buttonCaptionValue:"buttonCaptionValue",callToActionUrl:"callToActionUrl",callToActionUrlValue:"callToActionUrlValue",caption:"caption",captionDefinitionList:"captionDefinitionList",captionValue:"captionValue",cardBits:"cardBits",cardBitsValue:"cardBitsValue",cardNode:"cardNode",categoryTag:"categoryTag",categoryTagValue:"categoryTagValue",cells:"cells",cellsValue:"cellsValue",chatWithBook:"chatWithBook",chatWithBookValue:"chatWithBookValue",chatWithBookBrainKey:"chatWithBookBrainKey",chatWithBookBrainKeyValue:"chatWithBookBrainKeyValue",checked:"checked",choice:"choice",choices:"choices",choicesValue:"choicesValue",class:"class",classification:"classification",classificationValue:"classificationValue",codeLineNumbers:"codeLineNumbers",codeLineNumbersValue:"codeLineNumbersValue",codeMinimap:"codeMinimap",codeMinimapValue:"codeMinimapValue",color:"color",colorTag:"colorTag",colorTagValue:"colorTagValue",column:"column",columns:"columns",columnsValue:"columnsValue",comment:"comment",commentedBitType:"commentedBitType",computerLanguage:"computerLanguage",computerLanguageValue:"computerLanguageValue",content:"contentValue",content2Buy:"content2Buy",contentValue:"contentValue",contentValueValue:"contentValueValue",copyright:"copyright",coverColor:"coverColor",coverColorValue:"coverColorValue",coverImage:"coverImage",coverImageValue:"coverImageValue",customerExternalId:"customerExternalId",customerId:"customerId",customerIdValue:"customerIdValue",data:"data",dataValue:"dataValue",dataValueValue:"dataValueValue",date:"date",dateEnd:"dateEnd",dateEndValue:"dateEndValue",dateValue:"dateValue",decimalPlaces:"decimalPlaces",deeplink:"deeplink",deeplinkValue:"deeplinkValue",definition:"definition",definitions:"definitions",definitionsValue:"definitionsValue",disableCalculation:"disableCalculation",disableFeedback:"disableFeedback",disableFeedbackValue:"disableFeedbackValue",diffTo:"diffTo",diffToValue:"diffToValue",diffOp:"diffOp",diffOpValue:"diffOpValue",diffRef:"diffRef",diffRefValue:"diffRefValue",diffContext:"diffContext",diffContextValue:"diffContextValue",diffTime:"diffTime",diffTimeValue:"diffTimeValue",document:"document",documentDownload:"documentDownload",documentEmbed:"documentEmbed",documentLink:"documentLink",duration:"duration",durationValue:"durationValue",elements:"elements",elementsValue:"elementsValue",emphasis:"emphasis",end:"end",errors:"errors",errorsValue:"errorsValue",example:"example",exampleValue:"exampleValue",externalId:"externalId",externalIdValue:"externalIdValue",externalLink:"externalLink",externalLinkText:"externalLinkText",extraProperties:"extraProperties",feedbacks:"feedbacks",feedbacksValue:"feedbacksValue",feedback:"feedback",feedbackEngine:"feedbackEngine",feedbackEngineValue:"feedbackEngineValue",feedbackType:"feedbackType",flashcards:"flashcards",flashcardSet:"flashcardSet",flashcardSetValue:"flashcardSetValue",flashcardsValue:"flashcardsValue",focusX:"focusX",focusXValue:"focusXValue",focusY:"focusY",focusYValue:"focusYValue",footer:"footer",footerText:"footerText",forKeys:"forKeys",format:"format",forValues:"forValues",forValuesValue:"forValuesValue",gap:"gap",handInAcceptFileType:"handInAcceptFileType",handInAcceptFileTypeValue:"handInAcceptFileTypeValue",handInRequirement:"handInRequirement",handInRequirementValue:"handInRequirementValue",handInInstruction:"handInInstruction",handInInstructionValue:"handInInstructionValue",hasBookNavigation:"hasBookNavigation",hasBookNavigationValue:"hasBookNavigationValue",hasMarkAsDone:"hasMarkAsDone",hasMarkAsDoneValue:"hasMarkAsDoneValue",heading:"heading",height:"height",heightValue:"heightValue",highlight:"highlight",hint:"hint",href:"href",icon:"icon",iconTag:"iconTag",iconTagValue:"iconTagValue",iconValue:"iconValue",id:"id",idValue:"idValue",image:"image",imageFirst:"imageFirst",imageFirstValue:"imageFirstValue",imageLandscape:"imageLandscape",imageLink:"imageLink",imagePlaceholder:"imagePlaceholder",imagePlaceholderValue:"imagePlaceholderValue",imagePortrait:"imagePortrait",imageSource:"imageSource",index:"index",indexValue:"indexValue",ingredients:"ingredients",ingredientsValue:"ingredientsValue",instruction:"instruction",internalComment:"internalComment",internalCommentValue:"internalCommentValue",isCaseSensitive:"isCaseSensitive",isCommented:"isCommented",isCorrect:"isCorrect",__isDefaultExample:"__isDefaultExample",isExample:"isExample",isInfoOnly:"isInfoOnly",isInfoOnlyValue:"isInfoOnlyValue",isPlain:"isPlain",isPublic:"isPublic",isPublicValue:"isPublicValue",isTracked:"isTracked",isTrackedValue:"isTrackedValue",item:"item",itemLead:"itemLead",jupyterExecutionCount:"jupyterExecutionCount",jupyterExecutionCountValue:"jupyterExecutionCountValue",jupyterId:"jupyterId",jupyterIdValue:"jupyterIdValue",key:"key",keyAudio:"keyAudio",keyImage:"keyImage",kind:"kind",kindValue:"kindValue",label:"label",labelFalse:"labelFalse",labelFalseValue:"labelFalseValue",labelTrue:"labelTrue",labelTrueValue:"labelTrueValue",lang:"lang",language:"language",languageValue:"languageValue",langValue:"langValue",layer:"layer",layerValue:"layerValue",lead:"lead",level:"level",levelACTFL:"levelACTFL",levelACTFLValue:"levelACTFLValue",levelCEFR:"levelCEFR",levelCEFRp:"levelCEFRp",levelCEFRpValue:"levelCEFRpValue",levelCEFRValue:"levelCEFRValue",levelILR:"levelILR",levelILRValue:"levelILRValue",license:"license",line:"line",list:"list",listItemIndent:"listItemIndent",listItemIndentValue:"listItemIndentValue",listValue:"listValue",location:"location",locationValue:"locationValue",machineTranslated:"machineTranslated",machineTranslatedValue:"machineTranslatedValue",mailingList:"mailingList",marginNumber:"marginNumber",mark:"mark",markConfig:"markConfig",markConfigValue:"markConfigValue",marks:"marks",marksValue:"marksValue",markup:"markup",matrix:"matrix",matrixValue:"matrixValue",maxCreatedBits:"maxCreatedBits",maxCreatedBitsValue:"maxCreatedBitsValue",maxDisplayLevel:"maxDisplayLevel",maxDisplayLevelValue:"maxDisplayLevelValue",maxTocChapterLevel:"maxTocChapterLevel",maxTocChapterLevelValue:"maxTocChapterLevelValue",message:"message",mockupId:"mockupId",name:"name",offset:"offset",options:"options",optionsValue:"optionsValue",original:"original",padletId:"padletId",padletIdValue:"padletIdValue",page:"page",pageNo:"pageNo",pageNoValue:"pageNoValue",pageNumber:"pageNumber",pageValue:"pageValue",pairs:"pairs",pairsValue:"pairsValue",parent:"parent",parser:"parser",partialAnswer:"partialAnswer",partialAnswerValue:"partialAnswerValue",person:"person",path:"path",pathValue:"pathValue",pointerLeft:"pointerLeft",pointerLeftValue:"pointerLeftValue",pointerTop:"pointerTop",pointerTopValue:"pointerTopValue",posterImage:"posterImage",posterImageValue:"posterImageValue",postfix:"postfix",prefix:"prefix",processHandIn:"processHandIn",processHandInValue:"processHandInValue",product:"product",productFolder:"productFolder",productFolderValue:"productFolderValue",productId:"productId",productIdValue:"productIdValue",productList:"productList",productListValue:"productListValue",productValue:"productValue",productVideo:"productVideo",productVideoList:"productVideoList",productVideoListValue:"productVideoListValue",productVideoValue:"productVideoValue",progress:"progress",progressValue:"progressValue",pronunciationTable:"pronunciationTable",properties:"properties",property:"property",propertyKey:"propertyKey",propertyValue:"propertyValue",propertyValues:"propertyValues",provider:"provider",publications:"publications",publicationsValue:"publicationsValue",publisher:"publisher",publisherName:"publisherName",publisherNameValue:"publisherNameValue",publisherValue:"publisherValue",quantity:"quantity",question:"question",questions:"questions",questionsValue:"questionsValue",quizCountItems:"quizCountItems",quizCountItemsValue:"quizCountItemsValue",quizStrikethroughSolutions:"quizStrikethroughSolutions",quizStrikethroughSolutionsValue:"quizStrikethroughSolutionsValue",quizzes:"quizzes",quizzesValue:"quizzesValue",quotedPerson:"quotedPerson",ratingLevelEnd:"ratingLevelEnd",ratingLevelSelected:"ratingLevelSelected",ratingLevelSelectedValue:"ratingLevelSelectedValue",ratingLevelStart:"ratingLevelStart",reaction:"reaction",reason:"reason",reasonableNumOfChars:"reasonableNumOfChars",reasonableNumOfCharsValue:"reasonableNumOfCharsValue",reductionTag:"reductionTag",reductionTagValue:"reductionTagValue",refAuthor:"refAuthor",refBookTitle:"refBookTitle",reference:"reference",referenceEnd:"referenceEnd",referenceProperty:"referenceProperty",referencePropertyValue:"referencePropertyValue",refPublisher:"refPublisher",refPublicationYear:"refPublicationYear",citationStyle:"citationStyle",citationStyleValue:"citationStyleValue",releaseDate:"releaseDate",releaseDateValue:"releaseDateValue",releaseKind:"releaseKind",releaseKindValue:"releaseKindValue",releaseVersion:"releaseVersion",releaseVersionValue:"releaseVersionValue",resolved:"resolved",resolvedBy:"resolvedBy",resolvedByValue:"resolvedByValue",resolvedDate:"resolvedDate",resolvedDateValue:"resolvedDateValue",resolvedValue:"resolvedValue",resources:"resources",resourcesValue:"resourcesValue",resourceType:"resourceType",response:"response",responses:"responses",responsesValue:"responsesValue",revealSolutions:"revealSolutions",root:"root",sampleSolution:"sampleSolution",sampleSolutionValue:"sampleSolutionValue",scormSource:"scormSource",scormSourceValue:"scormSourceValue",search:"search",searchValue:"searchValue",searchIndex:"searchIndex",searchIndexValue:"searchIndexValue",section:"section",select:"select",servings:"servings",servingsValue:"servingsValue",showInIndex:"showInIndex",showInIndexValue:"showInIndexValue",size:"size",slug:"slug",slugValue:"slugValue",solution:"solution",solutions:"solutions",solutionsValue:"solutionsValue",spaceId:"spaceId",spaceIdValue:"spaceIdValue",src:"src",src1x:"src1x",src2x:"src2x",src3x:"src3x",src4x:"src4x",start:"start",statement:"statement",statements:"statements",statementsValue:"statementsValue",statementText:"statementText",stillImageFilmEmbed:"stillImageFilmEmbed",stillImageFilmLink:"stillImageFilmLink",stripePricingTableId:"stripePricingTableId",stripePricingTableIdValue:"stripePricingTableIdValue",stripePublishableKey:"stripePublishableKey",stripePublishableKeyValue:"stripePublishableKeyValue",subject:"subject",subjectValue:"subjectValue",subtitle:"subtitle",subtype:"subtype",subtypeValue:"subtypeValue",table:"table",tableAutoWidth:"tableAutoWidth",tableAutoWidthValue:"tableAutoWidthValue",tableFixedHeader:"tableFixedHeader",tableFixedHeaderValue:"tableFixedHeaderValue",tableHeight:"tableHeight",tableHeightValue:"tableHeightValue",tablePagination:"tablePagination",tablePaginationLimit:"tablePaginationLimit",tablePaginationLimitValue:"tablePaginationLimitValue",tablePaginationValue:"tablePaginationValue",tableResizableColumns:"tableResizableColumns",tableResizableColumnsValue:"tableResizableColumnsValue",tableColumnMinWidth:"tableColumnMinWidth",tableColumnMinWidthValue:"tableColumnMinWidthValue",tableSearch:"tableSearch",tableSearchValue:"tableSearchValue",tableSort:"tableSort",tableSortValue:"tableSortValue",tableWhitespaceNoWrap:"tableWhitespaceNoWrap",tableWhitespaceNoWrapValue:"tableWhitespaceNoWrapValue",tag:"tag",tagValue:"tagValue",target:"target",targetValue:"targetValue",technicalTerm:"technicalTerm",technicalTermValue:"technicalTermValue",term:"term",text:"text",textAlign:"textAlign",textAst:"textAst",textAstValue:"textAstValue",textFormat:"textFormat",textReference:"textReference",textReferenceValue:"textReferenceValue",texts:"texts",textsValue:"textsValue",theme:"theme",themeValue:"themeValue",thumbImage:"thumbImage",thumbImageValue:"thumbImageValue",thumbnails:"thumbnails",thumbnailsValue:"thumbnailsValue",title:"title",toc:"toc",tocValue:"tocValue",topicTag:"topicTag",topicTagValue:"topicTagValue",trim:"trim",type:"type",__typeAlias:"__typeAlias",unit:"unit",unitAbbr:"unitAbbr",url:"url",value:"value",values:"values",valuesValue:"valuesValue",vendorDashboardId:"vendorDashboardId",vendorDashboardIdValue:"vendorDashboardIdValue",vendorSurveyId:"vendorSurveyId",vendorSurveyIdValue:"vendorSurveyIdValue",vendorUrl:"vendorUrl",vendorUrlValue:"vendorUrlValue",version:"version",video:"video",videoCallLink:"videoCallLink",videoCallLinkValue:"videoCallLinkValue",videoEmbed:"videoEmbed",videoLink:"videoLink",warnings:"warnings",warningsValue:"warningsValue",websiteLink:"websiteLink",width:"width",widthValue:"widthValue",x:"x",xValue:"xValue",y:"y",yValue:"yValue",zoomDisabled:"zoomDisabled"});t.NodeType=i},166:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyTag=void 0;const i=r(4718),o=r(9888),n=(0,i.superenum)(Object.assign(Object.assign({},o.propertyConfigKeys),{tag_mark:"mark",tag_reference:"reference",tag_sampleSolution:"sampleSolution",tag_title:"title"}));t.PropertyTag=n},168:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.RESOURCES=void 0;const i=r(5051),o=r(9984),n=r(6149),a={[i.ResourceConfigKey.icon]:{tag:n.ResourceTag.icon},[i.ResourceConfigKey.image]:{tag:n.ResourceTag.image},[i.ResourceConfigKey.imagePortrait]:{tag:n.ResourceTag.imagePortrait,jsonKey:o.ResourceJsonKey.imagePortrait},[i.ResourceConfigKey.imageLandscape]:{tag:n.ResourceTag.imageLandscape,jsonKey:o.ResourceJsonKey.imageLandscape},[i.ResourceConfigKey.imageEmbed]:{tag:n.ResourceTag.imageEmbed,jsonKey:o.ResourceJsonKey.imageEmbed},[i.ResourceConfigKey.imageLink]:{tag:n.ResourceTag.imageLink,jsonKey:o.ResourceJsonKey.imageLink},[i.ResourceConfigKey.audio]:{tag:n.ResourceTag.audio},[i.ResourceConfigKey.audioEmbed]:{tag:n.ResourceTag.audioEmbed,jsonKey:o.ResourceJsonKey.audioEmbed},[i.ResourceConfigKey.audioLink]:{tag:n.ResourceTag.audioLink,jsonKey:o.ResourceJsonKey.audioLink},[i.ResourceConfigKey.video]:{tag:n.ResourceTag.video},[i.ResourceConfigKey.videoEmbed]:{tag:n.ResourceTag.videoEmbed,jsonKey:o.ResourceJsonKey.videoEmbed},[i.ResourceConfigKey.videoLink]:{tag:n.ResourceTag.videoLink,jsonKey:o.ResourceJsonKey.videoLink},[i.ResourceConfigKey.stillImageFilmEmbed]:{tag:n.ResourceTag.stillImageFilmEmbed,jsonKey:o.ResourceJsonKey.stillImageFilmEmbed},[i.ResourceConfigKey.stillImageFilmLink]:{tag:n.ResourceTag.stillImageFilmLink,jsonKey:o.ResourceJsonKey.stillImageFilmLink},[i.ResourceConfigKey.article]:{tag:n.ResourceTag.article},[i.ResourceConfigKey.articleEmbed]:{tag:n.ResourceTag.articleEmbed,jsonKey:o.ResourceJsonKey.articleEmbed},[i.ResourceConfigKey.articleLink]:{tag:n.ResourceTag.articleLink,jsonKey:o.ResourceJsonKey.articleLink},[i.ResourceConfigKey.document]:{tag:n.ResourceTag.document},[i.ResourceConfigKey.documentEmbed]:{tag:n.ResourceTag.documentEmbed,jsonKey:o.ResourceJsonKey.documentEmbed},[i.ResourceConfigKey.documentLink]:{tag:n.ResourceTag.documentLink,jsonKey:o.ResourceJsonKey.documentLink},[i.ResourceConfigKey.documentDownload]:{tag:n.ResourceTag.documentDownload,jsonKey:o.ResourceJsonKey.documentDownload},[i.ResourceConfigKey.appLink]:{tag:n.ResourceTag.appLink,jsonKey:o.ResourceJsonKey.appLink},[i.ResourceConfigKey.websiteLink]:{tag:n.ResourceTag.websiteLink,jsonKey:o.ResourceJsonKey.websiteLink}};t.RESOURCES=a},201:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.UrlUtils=void 0;const r=new class{fileExtensionFromUrl(e){let t;if(e)try{const r=new URL(e).pathname.split(".");r.length>1&&(t=r[r.length-1])}catch(e){}return t}domainFromUrl(e){let t;if(e)try{t=new URL(e).hostname}catch(e){}return t}};t.UrlUtils=r},363:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ExampleType=void 0;const i=(0,r(4718).superenum)({none:"none",string:"string",boolean:"boolean"});t.ExampleType=i},385:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextFormat=void 0;const i=(0,r(4718).superenum)({text:"text",latex:"latex",json:"json",xml:"xml",bitmarkMinusMinus:"bitmark--",bitmarkPlusPlus:"bitmark++"});t.TextFormat=i},431:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TextGenerator=void 0;const o=r(5126),n=r(7735),a=r(126),s=r(3811),l=r(385),p=r(6877),u=r(2483),c=r(9554),y=r(9681),g=r(4),d={bodyBitCallback:void 0,debugGenerationInline:!1},f="==",m=["*","`","_","!","="],T={[u.TextMarkType.bold]:"**",[u.TextMarkType.light]:"``",[u.TextMarkType.italic]:"__",[u.TextMarkType.highlight]:"!!"},h=[u.TextMarkType.bold,u.TextMarkType.light,u.TextMarkType.italic,u.TextMarkType.highlight],b=[u.TextMarkType.strike,u.TextMarkType.subscript,u.TextMarkType.superscript,u.TextMarkType.ins,u.TextMarkType.del,u.TextMarkType.underline,u.TextMarkType.doubleUnderline,u.TextMarkType.circle,u.TextMarkType.languageEm,u.TextMarkType.userUnderline,u.TextMarkType.userDoubleUnderline,u.TextMarkType.userStrike,u.TextMarkType.userCircle,u.TextMarkType.userHighlight,u.TextMarkType.notranslate,u.TextMarkType.link,u.TextMarkType.ref,u.TextMarkType.xref,u.TextMarkType.extref,u.TextMarkType.footnote,u.TextMarkType.footnoteStar,u.TextMarkType.symbol,u.TextMarkType.var,u.TextMarkType.code,u.TextMarkType.timer,u.TextMarkType.duration,u.TextMarkType.color,u.TextMarkType.comment],B=new RegExp(/(\n|\r\n)/,"g"),v=new RegExp(/https?:\/\/|mailto:(.*)/,"g"),C=new RegExp(/\]/,"g"),P="enter",x="between",k="exit";class K extends g.AstWalkerGenerator{constructor(e,t){var r,i;super(),this.ast=new o.Ast,this.generateOptions={},this.textFormat=l.TextFormat.bitmarkMinusMinus,this.textLocation=p.TextLocation.body,this.writerText="",this.nodeIndex=0,this.currentIndent=0,this.prevIndent=0,this.indentationStringCache="",this.inParagraph=!1,this.inHeading=!1,this.inCodeBlock=!1,this.exitedCodeBlock=!1,this.inBulletList=!1,this.inInline=!1,this.textDepth=0,this.placeholderIndex=0,this.placeholders={},this.rootParagraphNodeContentIndex=0,this.previousRootParagraphContextType=c.TextNodeType.text,this.inPreText=!1,this.thisNodeIsPreText=!1,this.preTextIndexTemp=-1,this.havePreText=!1,this.preTextIndex=-1,this.bitmarkVersion=null!==(r=s.BitmarkVersion.fromValue(e))&&void 0!==r?r:s.DEFAULT_BITMARK_VERSION,this.options=Object.assign(Object.assign({},d),t),this.debugGenerationInline=null!==(i=this.options.debugGenerationInline)&&void 0!==i&&i,this.bitmarkVersion,s.BitmarkVersion.v2,this.enter=this.enter.bind(this),this.between=this.between.bind(this),this.exit=this.exit.bind(this),this.leaf=this.leaf.bind(this)}generate(e,t,r,o){return i(this,void 0,void 0,(function*(){return this.generateSync(e,t,r,o)}))}generateSync(e,t,r,i){if(this.generateOptions=Object.assign({},i),this.validateGenerateOptions(e),this.generateOptions.plainTextDividerAllowed){const i=this.options.writeCallback,o=this.options.bodyBitCallback;this.options.writeCallback=void 0,this.options.bodyBitCallback=void 0,this.resetState(t,r),this.walkAndWrite(e),this.options.writeCallback=i,this.options.bodyBitCallback=o;const n=this.havePreText,a=this.preTextIndex;this.resetState(t,r),this.havePreText=n,this.preTextIndex=a,this.walkAndWrite(e)}else this.resetState(t,r),this.walkAndWrite(e);return this.writerText}getPlaceholders(){return this.placeholders}resetState(e,t){this.printed=!1,this.textFormat=null!=e?e:l.TextFormat.bitmarkMinusMinus,this.textLocation=t,this.writerText="",this.nodeIndex=0,this.currentIndent=0,this.prevIndent=0,this.indentationStringCache="",this.inParagraph=!1,this.inHeading=!1,this.inCodeBlock=!1,this.exitedCodeBlock=!1,this.inBulletList=!1,this.inInline=!1,this.textDepth=0,this.placeholderIndex=0,this.placeholders={},this.rootParagraphNodeContentIndex=0,this.previousRootParagraphContextType=c.TextNodeType.hardBreak,this.inPreText=!1,this.thisNodeIsPreText=!1,this.preTextIndexTemp=-1,this.havePreText=!1,this.preTextIndex=-1}walkAndWrite(e){this.ast.walk(e,a.NodeType.textAst,this,void 0)}enter_textAstValue(e,t){return this.handleEnterNode(e.value,t)}between_textAstValue(e,t,r,i){return this.handleBetweenNode(e.value,t,r,i)}exit_textAstValue(e,t){return this.handleExitNode(e.value,t)}enter_contentValue(e,t){return this.handleEnterContentValueNode(e,t)}between_contentValue(e,t,r,i){this.handleBetweenContentValueNode(e,t,r,i)}exit_contentValue(e,t){this.handleExitContentValueNode(e,t)}enter_contentValueValue(e,t){return this.handleEnterNode(e.value,t)}between_contentValueValue(e,t,r,i){this.handleBetweenNode(e.value,t,r,i)}exit_contentValueValue(e,t){return this.handleExitNode(e.value,t)}handleEnterNode(e,t){switch(this.handleEnterNodePreTextCheck(e,t),this.handleIndent(e),e.type){case c.TextNodeType.paragraph:this.inParagraph=!0,this.writeParagraph(e);break;case c.TextNodeType.hardBreak:this.writeHardBreak(e);break;case c.TextNodeType.text:this.writeMarks(e,P),this.writeText(e),this.writeMarks(e,x),0===this.textDepth&&(this.inInline=!0),this.textDepth++;break;case c.TextNodeType.heading:this.writeHeading(e),this.inHeading=!0;break;case c.TextNodeType.section:this.writeSection(e);break;case c.TextNodeType.listItem:case c.TextNodeType.taskItem:this.writeBullet(e,t);break;case c.TextNodeType.image:case c.TextNodeType.imageInline:this.writeImage(e);break;case c.TextNodeType.codeBlock:this.inCodeBlock=!0,this.writeCodeBlock(e);break;case c.TextNodeType.latex:this.writeLatex(e);break;case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.inBulletList=!0;break;case c.TextNodeType.gap:case c.TextNodeType.select:case c.TextNodeType.highlight:case c.TextNodeType.mark:return this.writeBodyBit(e,t),!1}this.exitedCodeBlock=!1}handleBetweenNode(e,t,r,i){e.type}handleExitNode(e,t){switch(e.type){case c.TextNodeType.text:this.textDepth--,0===this.textDepth&&(this.inInline=!1),this.writeMarks(e,k);break;case c.TextNodeType.paragraph:this.textFormat!==l.TextFormat.bitmarkMinusMinus&&this.writeNL(),this.inParagraph=!1;break;case c.TextNodeType.heading:this.inHeading=!1;case c.TextNodeType.section:case c.TextNodeType.image:this.inParagraph||(this.writeNL(),this.writeNL());break;case c.TextNodeType.codeBlock:this.writeNL(),this.writeNL(),this.inCodeBlock=!1,this.exitedCodeBlock=!0;break;case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.currentIndent<=1&&(this.writeNL(),this.inBulletList=!1)}this.handleDedent(e),this.nodeIndex++}handleIndent(e){switch(e.type){case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.currentIndent++}}handleDedent(e){switch(e.type){case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.currentIndent--}}handleEnterContentValueNode(e,t){3===t.length&&(this.thisNodeIsPreText=!0,this.inPreText=!1,this.previousRootParagraphContextType=c.TextNodeType.hardBreak)}handleBetweenContentValueNode(e,t,r,i){if(3===i.length){const e=t.value;this.updatePreTextState(),this.thisNodeIsPreText=!0,this.previousRootParagraphContextType=e.type,this.rootParagraphNodeContentIndex++}}handleExitContentValueNode(e,t){3===t.length&&(this.updatePreTextState(),this.thisNodeIsPreText=!1,this.generateOptions.plainTextDividerAllowed&&this.inPreText&&(this.havePreText=!0,this.preTextIndex=this.preTextIndexTemp),this.inPreText=!1)}updatePreTextState(){!this.inPreText&&this.thisNodeIsPreText&&this.previousRootParagraphContextType===c.TextNodeType.hardBreak?(this.inPreText=!0,this.preTextIndexTemp=this.rootParagraphNodeContentIndex):this.inPreText&&!this.thisNodeIsPreText&&(this.inPreText=!1,this.preTextIndexTemp=-1)}handleEnterNodePreTextCheck(e,t){if(4===t.length){if(this.inPreText&&e.type===c.TextNodeType.hardBreak)return;if(e.type===c.TextNodeType.text)return}this.thisNodeIsPreText=!1}getLinkHref(e){if(e.type===c.TextNodeType.text&&e.marks){const t=e.marks.reduce(((e,t)=>{var r;if(t.type===u.TextMarkType.link){const e=null===(r=t.attrs)||void 0===r?void 0:r.href;if(e)return e}return e}),"");if(t)return t}return!1}getIndentationString(){if(this.currentIndent===this.prevIndent)return this.indentationStringCache;let e="";for(let t=1;t<this.currentIndent;t++)e+="\t";return this.indentationStringCache=e,this.prevIndent=this.currentIndent,e}writeBodyBit(e,t){const r=`[!${this.placeholderIndex}]`;if(this.placeholders[r]=e,this.options.bodyBitCallback){const r=this.options.bodyBitCallback(e,this.placeholderIndex,t);this.write(r)}else this.write(r);this.placeholderIndex++}writeText(e){if(null==e.text)return;const t=this.inCodeBlock;let r=e.text;const i=this.getLinkText(e);if(i&&(r=i),r=i||this.breakscape(r,{textFormat:this.textFormat,textLocation:this.textLocation}),this.currentIndent>1){const e=this.getIndentationString();r=r.replace(B,`$1${e}`)}if(this.havePreText&&this.rootParagraphNodeContentIndex===this.preTextIndex&&(this.writePlainTextDivider(),this.writeNL()),this.havePreText&&this.rootParagraphNodeContentIndex>=this.preTextIndex){const t=this.breakscape(e.text,{textFormat:l.TextFormat.text,textLocation:this.textLocation});this.write(t)}else this.write(r);(this.currentIndent>1||t)&&(this.thisNodeIsPreText=!1),this.inPreText||e.text!==r||(this.thisNodeIsPreText=!1)}isSimpleLink(e){var t;if(null==e.text)return!1;if(1!==(null===(t=e.marks)||void 0===t?void 0:t.length))return!1;const r=this.getLinkHref(e);if(r){return r.replace(v,"$1")===e.text}return!1}getLinkText(e){if(null==e.text)return!1;const t=this.getLinkHref(e);if(t){let r;return r=t.replace(v,"$1")===e.text?t:e.text,r=(null!=r?r:"").replace(C,"^]"),r}return!1}getInterTextBreakscape(e){if(this.bitmarkVersion===s.BitmarkVersion.v2)return"";if(this.textFormat===l.TextFormat.text)return"";const t=this.writerText.slice(-1),r=e.slice(0,1);return t===r&&-1!==m.indexOf(t)||this.textLocation===p.TextLocation.body&&"["===t&&-1!=="@#▼►%!?+-$_=&".indexOf(r)?"^":""}validateGenerateOptions(e){this.generateOptions.plainTextDividerAllowed&&(1!==e.length||1===e.length&&e[0].type!==c.TextNodeType.paragraph)&&(this.generateOptions.plainTextDividerAllowed=!1)}writeMarks(e,t){if(e.marks){const r=this.inInline||this.inHeading?l.TextFormat.bitmarkMinusMinus:this.textFormat;this.thisNodeIsPreText=!1;if(0===e.marks.length)return void this.writeMarkTextWrapper(f);const i=1===e.marks.length&&r!==l.TextFormat.bitmarkPlusPlus,o=e.marks.reduce(((e,t)=>e||(-1!==h.indexOf(t.type)?i?T[t.type]:f:-1!==b.indexOf(t.type)?f:e)),void 0),n=this.isSimpleLink(e);if(null!=o&&!n){if(t!=P&&t!=x||this.writeMarkTextWrapper(o),t==x)for(const t of e.marks)-1!==h.indexOf(t.type)?i||(this.writeInlineMarkStartEnd(),this.writeInlineMark(t)):u.TextMarkType.comment===t.type?(this.writeInlineMarkStartEnd(),this.writeCommentMark(t)):u.TextMarkType.link===t.type?(this.writeInlineMarkStartEnd(),this.writeLinkMark(t)):u.TextMarkType.ref===t.type?(this.writeInlineMarkStartEnd(),this.writeRefMark(t)):u.TextMarkType.xref===t.type?(this.writeInlineMarkStartEnd(),this.writeXRefMark(t)):u.TextMarkType.extref===t.type?(this.writeInlineMarkStartEnd(),this.writeExtRefMark(t)):u.TextMarkType.footnote===t.type?(this.writeInlineMarkStartEnd(),this.writeFootnoteMark(t)):u.TextMarkType.footnoteStar===t.type?(this.writeInlineMarkStartEnd(),this.writeFootnoteStarMark(t)):u.TextMarkType.symbol===t.type?(this.writeInlineMarkStartEnd(),this.writeSymbolMark(t)):-1!==b.indexOf(t.type)&&(this.writeInlineMarkStartEnd(),this.writeInlineMark(t));if(t==k){let t=!1;for(const r of e.marks)-1!==h.indexOf(r.type)?i||(t=!0):u.TextMarkType.comment!==r.type&&u.TextMarkType.link!==r.type&&u.TextMarkType.ref!==r.type&&u.TextMarkType.xref!==r.type&&u.TextMarkType.footnote!==r.type&&u.TextMarkType.footnoteStar!==r.type&&-1===b.indexOf(r.type)||(t=!0);t&&this.writeInlineMarkStartEnd()}}}}writeParagraph(e){var t,r,i,o,n;if(this.textFormat===l.TextFormat.bitmarkPlusPlus){if(this.inBulletList)return;const a=null!==(r=null===(t=e.content)||void 0===t?void 0:t.length)&&void 0!==r?r:0;if(0===this.nodeIndex){if(1===a){const t=(null===(i=e.content)||void 0===i?void 0:i[0].type)===c.TextNodeType.text,r=null!==(n=null===(o=e.content)||void 0===o?void 0:o[0].text)&&void 0!==n?n:"";if(!t||""!==r)return}if(a>1)return}this.write("|"),this.writeNL(),this.exitedCodeBlock&&this.writeNL()}}writeHardBreak(e){if(this.writeNL(),this.currentIndent>1){const e=this.getIndentationString();this.write(e)}}writeHeading(e){var t,r;let i="";const o=null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.level)&&void 0!==r?r:1;for(let e=0;e<+o;e++)i+="#";i+=" ",this.write(i)}writeSection(e){let t="";t=e.section?`|${e.section}: `:"|",this.write(t)}writeBullet(e,t){var r,i,o,n;let a=this.getIndentationString();const s=this.getParentNode(t,2),l=null==s?void 0:s.value,p=null==l?void 0:l.type,u=null!==(i=null===(r=null==l?void 0:l.attrs)||void 0===r?void 0:r.start)&&void 0!==i?i:1;if(p===c.TextNodeType.bulletList)a+="• ";else if(p===c.TextNodeType.noBulletList)a+="•_ ";else if(p===c.TextNodeType.orderedList)a+=`•${u} `;else if(p===c.TextNodeType.orderedListRoman)a+=`•${u}I `;else if(p===c.TextNodeType.orderedListRomanLower)a+=`•${u}i `;else if(p===c.TextNodeType.letteredList)a+="•A ";else if(p===c.TextNodeType.letteredListLower)a+="•a ";else if(p===c.TextNodeType.taskList){a+=null!==(n=null===(o=e.attrs)||void 0===o?void 0:o.checked)&&void 0!==n&&n?"•+ ":"•- "}a&&this.write(a)}writeImage(e){var t;if(null==e.attrs||!e.attrs.src)return;const r=e.attrs,i=this.inParagraph,o=this.getMediaAttrs(i?"imageInline":"image",r,{ignoreAttributes:i?new Set(["alt","zoomDisabled","title"]):void 0});let n="";i&&(n=`==${null!==(t=r.alt)&&void 0!==t?t:""}==`),n+=o?`|${o}|`:"",this.write(n)}writeCodeBlock(e){if(null==e.attrs||!e.attrs.language)return;const t=`|code:${e.attrs.language}\n`;this.write(t)}writeLatex(e){if(null==e.attrs||!e.attrs.formula)return;const t=e.attrs,r=`==${this.breakscape(t.formula,{textFormat:this.textFormat,textLocation:this.textLocation})}==|latex|`;this.write(r)}writeMarkTextWrapper(e){e&&this.write(e)}writeInlineMark(e){let t=`${e.type}`;if(e.attrs)for(const[r,i]of Object.entries(e.attrs))("language"===r&&"plain text"!==i||"color"===r||"name"===r||"duration"===r)&&(t=`${t}:${i}`);this.write(t)}writeCommentMark(e){const t=`#${e.comment||""}`;this.write(t)}writeLinkMark(e){var t;const r=(null===(t=e.attrs)||void 0===t?void 0:t.href)||"",i=`link:${(null!=r?r:"").replace(C,"^]")}`;this.write(i)}writeRefMark(e){var t,r;const i=`►${null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.reference)&&void 0!==r?r:""}`;this.write(i)}writeXRefMark(e){var t,r,i,o;const n=null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.xref)&&void 0!==r?r:"",a=null!==(o=null===(i=e.attrs)||void 0===i?void 0:i.reference)&&void 0!==o?o:"";let s=`xref:${n}`;a&&(s+=`|►${a}`),this.write(s)}writeExtRefMark(e){var t,r,i,o,n,a;const s=null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.extref)&&void 0!==r?r:"",l=null!==(o=null===(i=e.attrs)||void 0===i?void 0:i.references)&&void 0!==o?o:[],p=null!==(a=null===(n=e.attrs)||void 0===n?void 0:n.provider)&&void 0!==a?a:"";let u=`extref:${s}`;for(const e of l)u+=`|►${null!=e?e:""}`;u+=`|provider:${p}`,this.write(u)}writeFootnoteMark(e){this.write("footnote:")}writeFootnoteStarMark(e){this.write("footnote*:")}writeSymbolMark(e){if(null==e.attrs)return;const t=e.attrs,r=this.getMediaAttrs("symbol",t),i=null!=r?r:"";this.write(i)}writeInlineMarkStartEnd(){this.write("|")}writePlainTextDivider(){this.write("==== text ====")}writeString(e){null!=e&&this.write(`${e}`)}writeNL(){this.options.debugGenerationInline?this.write("\\n"):this.write("\n")}writeInlineDebug(e,t){let r=e;t.open?r=`<${e}>`:t.close?r=`</${e}>`:t.single&&(r=`<${e} />`),this.writeString(r)}getMediaAttrs(e,t,r){var i,o;if(!e)return;const n=null!==(i=Object.assign({},r).ignoreAttributes)&&void 0!==i?i:new Set;let a=`${e}:${null!==(o=null==t?void 0:t.src)&&void 0!==o?o:""}`;const s=Object.entries(t).filter((([e,t])=>"src"!==e));for(let e=0;e<s.length;e++){const[t,r]=s[e];if(!n.has(t))switch(t){case"textAlign":"left"!==r&&(a+=`|captionAlign:${r}`);break;case"alignment":"center"!==r&&r&&(a+=`|alignment:${r}`);break;case"title":r&&(a+=`|caption:${r}`);break;case"class":"center"!==r&&r&&(a+=`|align:${r}`);break;case"comment":r&&(a+=`|#${r}`);break;case"":y.StringUtils.isString(r)?a+=`|:${r}`:a+="|";break;default:t&&r&&(a+=`|${t}:${r}`)}}return a}breakscape(e,t){return this.generateOptions.noBreakscaping?e:n.Breakscape.breakscape(e,t)}getBitType(e){for(const t of e)if(t.key===a.NodeType.bitsValue){const e=t.value;return null==e?void 0:e.bitType}}write(e){return e=this.getInterTextBreakscape(e)+e,this.options.writeCallback&&this.options.writeCallback(e),this.writerText+=e,this}writeLine(e){return this.write(`${e}\n`),this}writeLines(e,t){for(const r of e)this.write(`${r}${null!=t?t:""}\n`);return this}writeWhiteSpace(){return this.write(" "),this}}t.TextGenerator=K},486:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.InfoType=void 0;const i=(0,r(4718).superenum)({list:"list",deprecated:"deprecated",all:"all",bit:"bit"});t.InfoType=i},554:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.clozeTagContentProcessor=function(e,t,r,l,p){const{textFormat:u}=e,{value:c}=l,y=p.solutions,g=p.__solutionsAst;if(!y||!g)return;if(a.StringUtils.isString(c)){const e=a.StringUtils.trimmedString(c);y.push(i.Breakscape.unbreakscape(e,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}));const t=s.toAst(e,{textFormat:u,isProperty:!0});g.push(t)}};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=new(r(777).TextParser)},777:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextParser=void 0;const i=r(385),o=r(9554),n=r(9681),a=r(2220);t.TextParser=class{version(){return(0,a.parse)("",{startRule:"version"})}preprocessAst(e){if(n.StringUtils.isString(e)){const t=e;try{e=JSON.parse(t)}catch(e){return}}if(this.isAst(e))return e}isAst(e){if(Array.isArray(e)){if(0===e.length)return!0;if(Object.prototype.hasOwnProperty.call(e[0],"type"))return!0}return!1}toAst(e,t){var r;if(Array.isArray(e))return e;let o=null!==(r=e)&&void 0!==r?r:"";if(!o)return[];const n=Object.assign({},t);let s=n.textFormat===i.TextFormat.bitmarkPlusPlus?"bitmarkPlusPlus":"bitmarkMinusMinus";return n.isProperty&&n.textFormat===i.TextFormat.bitmarkPlusPlus&&(s="bitmarkPlus"),o=o.trim(),(0,a.parse)(o,{startRule:s})}extractBodyBits(e){if(!Array.isArray(e))return[];const t=[],r=e;for(const e of r)switch(e.type){case o.TextNodeType.gap:case o.TextNodeType.select:case o.TextNodeType.highlight:case o.TextNodeType.mark:t.push(e);break;default:{const r=this.extractBodyBits(e.content);for(const e of r)t.push(e)}}return t}walkBodyBits(e,t){if(!Array.isArray(e))return;const r=e;for(let e=0;e<r.length;e++){const i=r[e];switch(i.type){case o.TextNodeType.gap:case o.TextNodeType.select:case o.TextNodeType.highlight:case o.TextNodeType.mark:t(r,e,i);break;default:this.walkBodyBits(i.content,t)}}}}},955:function(e,t,r){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ObjectUtils=void 0;const o=i(r(7678));const n=new class{isFunction(e){return"[object Function]"===Object.prototype.toString.call(e)}isArray(e){return Array.isArray(e)}isDate(e){return"[object Date]"===Object.prototype.toString.call(e)}isObject(e){return"[object Object]"===Object.prototype.toString.call(e)}isValue(e){return!this.isObject(e)&&!this.isArray(e)}getViaPath(e,t){if(!e)return;if(!t)return;Array.isArray(t)||(t=[t]),t=t.flatMap((e=>e.split(".")));let r=e;for(const e of t){if(null==r)return;r=r[e]}return r}setViaPath(e,t,r,i){if(!e)return!1;if(!t)return!1;Array.isArray(t)||(t=[t]),t=t.flatMap((e=>e.split(".")));let o=e;for(let e=0;e<t.length-1;e++){const r=t[e];if(null==o[r]){if(!i)return!1;o[r]={}}o=o[r]}return o[t[t.length-1]]=r,!0}flatMapPath(e,t){if(!e)return[];if(!t)return[];Array.isArray(t)||(t=[t]);const r=e,i=t.shift();if(null==i)return r;const o=r[i];return o?Array.isArray(o)?o.flatMap((e=>this.flatMapPath(e,t.slice()))):[this.flatMapPath(o,t)].flat():[]}orderProperties(e,t){const r=e,i=Object.assign({},r);for(const e of Object.keys(r))delete r[e];for(const e of t)Object.prototype.hasOwnProperty.call(i,e)&&(r[e]=i[e])}removeUndefinedProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||null==i&&delete r[e]}removeFalseProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||!1===i&&delete r[e]}removeEmptyStringProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||""===i&&delete r[e]}removeEmptyArrayProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||Array.isArray(i)&&0===i.length&&delete r[e]}removeEmptyObjectProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||this.isObject(i)&&0===Object.keys(i).length&&delete r[e]}removeUnwantedProperties(e,t){(t=Object.assign({},t)).ignoreAllUndefined||this.removeUndefinedProperties(e,t.ignoreUndefined),t.ignoreAllFalse||this.removeFalseProperties(e,t.ignoreFalse),t.ignoreAllEmptyString||this.removeEmptyStringProperties(e,t.ignoreEmptyString),t.ignoreAllEmptyArrays||this.removeEmptyArrayProperties(e,t.ignoreEmptyArrays),t.ignoreAllEmptyObjects||this.removeEmptyObjectProperties(e,t.ignoreEmptyObjects)}extractSingleValue(e,t){if(!e)return;const r=e;if(null==r[t])return;let i=r[t];if(Array.isArray(i)){if(0===i.length)return;i=i[i.length-1]}return i}deepMerge(...e){return function e(...t){function r(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function i(t,i){for(const[n,a]of Object.entries(i)){const i=r(a);void 0!==t[n]&&r(t[n])===i&&["array","object"].includes(i)?t[n]=e(t[n],a):t[n]=(0,o.default)(a)}}let n=(0,o.default)(t.shift());for(const e of t){const t=r(e);r(n)===t?"array"===t?n=[...n,...(0,o.default)(e)]:"object"===t?i(n,e):n=e:n=(0,o.default)(e)}return n}(...e)}};t.ObjectUtils=n},1083:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.buildCards=function(e,t,r,d,f,m,T,h){var b;const{bitConfig:B}=e;e.DEBUG_CARD_SET&&e.debugPrint("card set",d);let v={};const C=function(e,t){var r;const i={cards:[],internalComments:[]};if(!t)return i;const{bitType:o}=e;let a=0,s=0,l=0;for(const p of t.cards){const t={no:a++,sides:[]};i.cards.push(t);for(const a of p.sides){const p={no:s++,variants:[]};t.sides.push(p);for(const u of a.variants){const{parser:a,content:g}=u,d={parser:a,no:l++};p.variants.push(d);const f=n.Config.getTagsConfigForCardSet(o,s,l),m=e.bitContentProcessor(y.BitContentLevel.Card,f,g);e.DEBUG_CARD_TAGS&&e.debugPrint("card tags",m),m.cardBody=c.BitmarkPegParserValidator.checkCardBody(e,y.BitContentLevel.Card,o,m.cardBody,t.no,p.no,d.no),m.cardBodyStr=null===(r=m.cardBody)||void 0===r?void 0:r.bodyString,d.data=m,m.internalComments&&i.internalComments.push(...m.internalComments)}l=0}s=0}return i}(e,d);switch(null===(b=B.cardSet)||void 0===b?void 0:b.configKey){case a.CardSetConfigKey._flashcard:case a.CardSetConfigKey._definitionList:v=function(e,t,r){var o;const a=[],l=[];let p,u,c,y="",d=[],f=0,m={};const T=t===s.BitType.flashcard1,h=g(r);for(let g=0;g<r.cards.length;g++){const b=r.cards[g];if(!h||0!==g){p=void 0,u=void 0,d=[],f=0,m={};for(const e of b.sides)for(const t of e.variants){const e=t.data,{cardBody:r,resources:n}=e,a=i(e,["cardBody","resources"]);m=Object.assign(Object.assign({},m),a);const s=n&&n.length>0?n[0]:void 0,l=null==r?void 0:r.body,g=null!==(o=null==r?void 0:r.bodyString)&&void 0!==o?o:"";0===f?(c=t,y=g,p={text:l,icon:s}):1===f?u={text:l,icon:s}:d.push({text:l,icon:s}),f++}if(0!==g&&T){e.addWarning(`Bit '${t}' should only contain one card. Ignore subsequent card: '${y}'`,c);break}if(n.Config.isOfBitType(t,[s.BitType.flashcard])){const e=Object.assign({question:p,answer:u,alternativeAnswers:d},m);e&&a.push(e)}else{const e=Object.assign({term:p,definition:u,alternativeDefinitions:d},m);e&&l.push(e)}}}return{heading:null==h?void 0:h.heading,flashcards:a.length>0?a:void 0,definitions:l.length>0?l:void 0}}(e,t,C);break;case a.CardSetConfigKey._elements:v=function(e,t,r){var i;const o=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data;o.push(null!==(i=t.cardBodyStr)&&void 0!==i?i:"")}return{elements:o.length>0?o:void 0}}(0,0,C);break;case a.CardSetConfigKey._statements:v=function(e,t,r,o,n){var a;const s=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{statements:r,statement:o}=t,n=i(t,["statements","statement"]);if(Array.isArray(r))for(const e of r){const t=Object.assign({statement:null!==(a=e.statement)&&void 0!==a?a:"",isCorrect:e.isCorrect,item:e.item,lead:e.lead,hint:e.hint,instruction:e.instruction,example:e.example},n);t&&s.push(t)}}o&&s.push(o);Array.isArray(n)&&n.length>0&&s.push(...n);return{statements:s.length>0?s:void 0}}(0,0,C,f,m);break;case a.CardSetConfigKey._feedback:v=function(e,t,r){let o;const n=[],a=g(r);for(let e=0;e<r.cards.length;e++){const t=r.cards[e];if(!a||0!==e){o=void 0;for(let e=0;e<t.sides.length;e++){const r=t.sides[e];for(const t of r.variants){const r=t.data,{cardBody:a,cardBodyStr:s,choices:l}=r,p=i(r,["cardBody","cardBodyStr","choices"]);if(0===e){const e=[];if(l&&l.length>0)for(const t of l){const{__isDefaultExample:r,example:o}=t,n=i(t,["__isDefaultExample","example"]),a={choice:n.choice,requireReason:n.isCorrect,__isDefaultExample:r,example:o};e.push(a)}o=Object.assign(Object.assign({},r),{choices:e}),o&&n.push(o)}else if(1===e){const e=Object.assign({text:null!=s?s:"",__textAst:null==a?void 0:a.body},p);o&&(o.reason=e)}}}}}return{heading:null==a?void 0:a.heading,feedbacks:n.length>0?n:void 0}}(0,0,C);break;case a.CardSetConfigKey._quiz:v=function(e,t,r,o,a){const l=[],p=n.Config.isOfBitType(t,s.BitType.multipleChoice),u=n.Config.isOfBitType(t,s.BitType.multipleResponse);if(!p&&!u)return{};let c,y=!1;for(const e of r.cards){y=!1,c=void 0;for(const t of e.sides)for(const e of t.variants){const t=e.data,{__isDefaultExample:r,example:o}=t,n=i(t,["__isDefaultExample","example"]);if(y=!0===r||y,c=o||c,n.trueFalse&&n.trueFalse.length>0){const e=[];for(const t of n.trueFalse){const{__isDefaultExample:r,example:o}=t,n=i(t,["__isDefaultExample","example"]),a=r||y,s=o||c,l={isCorrect:n.isCorrect,__isDefaultExample:a,example:s};u?l.response=n.text:l.choice=n.text,l&&e.push(l)}u?n.responses=e:n.choices=e}const a=Object.assign(Object.assign({},n),{choices:n.choices,responses:n.responses,__isDefaultExample:y,__defaultExample:c});a&&l.push(a)}}if(p&&Array.isArray(o)&&o.length>0){const e={choices:o};e&&l.push(e)}if(u&&Array.isArray(a)&&a.length>0){const e={responses:a};e&&l.push(e)}return{quizzes:l.length>0?l:void 0}}(0,t,C,T,h);break;case a.CardSetConfigKey._questions:v=function(e,t,r){var i;const o=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,r=Object.assign({question:null!==(i=t.cardBodyStr)&&void 0!==i?i:""},t);r&&o.push(r)}return{questions:o.length>0?o:void 0}}(0,0,C);break;case a.CardSetConfigKey._matchPairs:v=function(e,t,r){var o;const a=[];let l,u,c,y,d=[],f=[],m={},T=!1;const h=n.Config.isOfBitType(t,s.BitType.matchMatrix),b=g(r,h),B=null!==(o=null==b?void 0:b.isDefaultExampleCardSet)&&void 0!==o&&o;let v=null==b?void 0:b.exampleCardSet;for(let e=0;e<r.cards.length;e++){const t=r.cards[e];if(b&&0===e)continue;l=void 0,d=[],f=[],u=void 0,c=void 0,m={},T=!1,y=void 0;for(let e=0;e<t.sides.length;e++){const r=t.sides[e];for(const t of r.variants){const r=t.data,{cardBody:o,cardBodyStr:n,resources:a,__isDefaultExample:s,example:g}=r,h=i(r,["cardBody","cardBodyStr","resources","__isDefaultExample","example"]);if(T=!0===s||T,y=g||y,0===e)if(Array.isArray(a)&&a.length>0){const e=a[0];e.type===p.ResourceTag.audio?u=e:e.type===p.ResourceTag.image&&(c=e)}else l=n;else{const e=null!=n?n:"",t=null==o?void 0:o.body;d.push(e),f.push(t),!B&&!T||y||(y=t),delete h.item,delete h.lead}m=Object.assign(Object.assign({},m),h)}}T&&(v=void 0);const o=T||B,n=y||v,s=Object.assign(Object.assign({key:null!=l?l:"",keyAudio:u,keyImage:c,values:d,__valuesAst:f},m),{__isDefaultExample:o,example:n});s&&a.push(s)}return{heading:null==b?void 0:b.heading,pairs:a.length>0?a:void 0}}(0,t,C);break;case a.CardSetConfigKey._matchMatrix:v=function(e,t,r){var n;let a,s;const l=[];let p,u,c,y,d=[],f=[],m=[],T={},h=!1,b=!1;const B=g(r,!0),v=null!==(n=null==B?void 0:B.isDefaultExampleCardSet)&&void 0!==n&&n;let C=null==B?void 0:B.exampleCardSet;for(let e=0;e<r.cards.length;e++){const t=r.cards[e];if(B&&0===e)continue;a=void 0,s=void 0,d=[],f=[],m=[],h=!1,p=void 0,c=void 0;for(let e=0;e<t.sides.length;e++){const r=t.sides[e];f=[],m=[],T={},b=!1,u=void 0,y=void 0;for(const t of r.variants){const r=t.data,{cardBody:n,cardBodyStr:l,__isDefaultExample:g,example:d,isCaseSensitive:B}=r,C=i(r,["cardBody","cardBodyStr","__isDefaultExample","example","isCaseSensitive"]);if(b=!0===g||b,u=d||u,Object.assign(T,C),0===e)a=l,s=C,h=!0===g||h,p=d||p,c=null!=B?B:c;else{const e=null!=l?l:o.Breakscape.EMPTY_STRING,t=null==n?void 0:n.body;f.push(e),m.push(t),!v&&!b||u||(u=t),y=null!=B?B:c}}if(e>0){b&&(p=C=void 0),h&&(C=void 0);const e=b||h||v,t=u||p||C,r=Object.assign(Object.assign({values:f,__valuesAst:m},T),{__isDefaultExample:e,example:t,isCaseSensitive:y});r&&d.push(r)}}const n=Object.assign({key:null!=a?a:o.Breakscape.EMPTY_STRING,cells:d},s);n&&l.push(n)}return{heading:null==B?void 0:B.heading,matrix:l.length>0?l:void 0}}(0,0,C);break;case a.CardSetConfigKey._pronunciationTable:v=function(e,t,r){var i;const o=[];let n=[];for(const e of r.cards){n=[];for(const t of e.sides)for(const e of t.variants){const t=e.data,{title:r,cardBody:o,resources:a}=t,s=r&&r[1].titleAst,l=a&&a.length>0?a.find((e=>e.type===p.ResourceTag.audio)):void 0,u={title:null!=s?s:[],body:null!==(i=null==o?void 0:o.body)&&void 0!==i?i:[],audio:l};n.push(u)}o.push(n)}return{pronunciationTable:{data:o}}}(0,0,C);break;case a.CardSetConfigKey._table:v=function(e,t,r){var i;let o=!1;const n=[],a=[];let s=[];for(let e=0;e<r.cards.length;e++){const t=r.cards[e];o=!1,s=[];for(const r of t.sides)for(const t of r.variants){const r=t.data,{title:a,cardBody:l}=r,p=a&&a[1].titleAst;if(0===e&&null!=p&&(o=!0),o)n.push(null!=p?p:[]);else{const e=null!==(i=null==l?void 0:l.body)&&void 0!==i?i:[];s.push(e)}}o||a.push(s)}return{table:{columns:n,data:a}}}(0,0,C);break;case a.CardSetConfigKey._botActionResponses:v=function(e,t,r){const n=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{__instructionString:r,reaction:a,cardBodyStr:s}=t,l=i(t,["__instructionString","reaction","cardBodyStr"]),p=Object.assign({response:null!=r?r:o.Breakscape.EMPTY_STRING,reaction:null!=a?a:o.Breakscape.EMPTY_STRING,feedback:null!=s?s:o.Breakscape.EMPTY_STRING},l);p&&n.push(p)}return{botResponses:n.length>0?n:void 0}}(0,0,C);break;case a.CardSetConfigKey._ingredients:v=function(e,t,r){const n=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{title:r,__instructionString:a,unit:s,unitAbbr:p,decimalPlaces:c,disableCalculation:y,cardBodyStr:g,cardBody:d}=t,f=i(t,["title","__instructionString","unit","unitAbbr","decimalPlaces","disableCalculation","cardBodyStr","cardBody"]),m=Array.isArray(r)&&r.length>0?r[r.length-1].titleString:void 0;let T=!1,h=u.NumberUtils.asNumber(a);if(d&&d.bodyBits){const e=d.bodyBits.find((e=>e.type===l.BodyBitType.select));e&&(h=e.__instructionString?u.NumberUtils.asNumber(e.__instructionString):h,e.options&&e.options.length>0&&(T=e.options[0].isCorrect))}const b=Object.assign({title:m,checked:T,item:g,quantity:h,unit:null!=s?s:o.Breakscape.EMPTY_STRING,unitAbbr:null!=p?p:o.Breakscape.EMPTY_STRING,decimalPlaces:null!=c?c:1,disableCalculation:y},f);b&&n.push(b)}return{ingredients:n.length>0?n:void 0}}(0,0,C);break;case a.CardSetConfigKey._clozeList:case a.CardSetConfigKey._exampleBitList:case a.CardSetConfigKey._bookReferenceList:v=function(e,t,r,o){const n=[];for(const e of o.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{cardBody:r}=t,o=i(t,["cardBody"]),a=Object.assign({body:r},o);a&&n.push(a)}return{cardBits:n.length>0?n:void 0}}(0,0,0,C)}return v.internalComments=C.internalComments.length>0?C.internalComments:void 0,v};const o=r(7735),n=r(2028),a=r(8199),s=r(5854),l=r(4410),p=r(6149),u=r(8025),c=r(4266),y=r(3029);function g(e,t=!1){let r,i,o=!1;const n=[];let a,s=!1;if(0===e.cards.length)return;const l=e.cards[0];for(let e=0;e<l.sides.length;e++){const t=l.sides[e];if(0===t.variants.length)continue;const r=t.variants[0].data,{title:p,__isDefaultExample:u,example:c}=r,y=p&&p[1].titleString;null!=y&&(o=!0),0===e?o&&(i=y,s=!0===u||s,a=c||a):o&&(n.push(null!=y?y:""),s=!0===u||s,a=c||a)}if(o){let e=n;e=t?n:n.length>=1?n[n.length-1]:"",r={forKeys:null!=i?i:"",forValues:e}}return r?{heading:r,isDefaultExampleCardSet:s,exampleCardSet:a}:void 0}},1163:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardSetVersion=void 0;const i=(0,r(4718).superenum)({v1:1,v2:2});t.CardSetVersion=i},1412:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.init=function(){if(n)return;(0,o.initEnv)(i.buildInfo.name,i.buildInfo.version),n=!0};const i=r(1464),o=r(6936);r(2028);let n=!1},1457:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourcesConfig=void 0;t.ResourcesConfig=class{constructor(e,t,r,i){this.tags=e,this.resourceAttachmentAllowed=null!=t&&t,this.resourceTypeAttachment=r,this.comboResourceTagTypesMap=i}getCountsMin(){const e=new Map;for(const t of Object.values(this.tags))null!=t.minCount&&e.set(t.tag,t.minCount);return e}getCountsMax(){const e=new Map;for(const t of Object.values(this.tags))null!=t.maxCount&&e.set(t.tag,t.maxCount);return e}}},1464:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.buildInfo=void 0,t.buildInfo={name:"@gmb/bitmark-parser-generator",version:"3.25.1",author:"Get More Brain Ltd",license:"ISC",description:"A bitmark parser and generator using Peggy.js"}},1519:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyTagConfig=void 0;const i=r(5512),o=r(6634);class n extends o.AbstractTagConfig{constructor(e,t,r,o,n,a,s,l,p,u,c){super(i.BitTagType.property,e,t,r,o,n,a,s,c),this.type=i.BitTagType.property,this.single=l,this.format=p,this.defaultValue=u}toString(e){const t=Object.assign({},e);let r=`PTY[${this.tag}`;if(t.includeConfigs&&(null!=this.deprecated&&(r+=`, deprecated=${this.deprecated}`),null!=this.maxCount&&(r+=`, max=${this.maxCount}`),null!=this.minCount&&(r+=`, min=${this.minCount}`),null!=this.single&&(r+=`, sgl=${this.single}`),null!=this.format&&(r+=`, fmt=${this.format}`),null!=this.defaultValue&&(r+=`, def=${this.defaultValue}`),null!=this.jsonKey&&(r+=`, json=${this.jsonKey}`),null!=this.astKey&&(r+=`, ast=${this.astKey}`)),r+="]",this.chain&&t.includeChains){r+="\n|__";let e=!0;for(const i of Object.values(this.chain))e||(r+=" "),r+=`${i.toString(t)}`,e=!1}return r}}t.PropertyTagConfig=n},1731:(e,t)=>{t.VOID=-1;t.PRIMITIVE=0;t.ARRAY=1;t.OBJECT=2;t.DATE=3;t.REGEXP=4;t.MAP=5;t.SET=6;t.ERROR=7;t.BIGINT=8},1791:function(e,t,r){var i,o=this&&this.__createBinding||(Object.create?function(e,t,r,i){void 0===i&&(i=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,i,o)}:function(e,t,r,i){void 0===i&&(i=r),e[i]=t[r]}),n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),a=(this&&this.__importStar||(i=function(e){return i=Object.getOwnPropertyNames||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[t.length]=r);return t},i(e)}),this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))});this&&this.__importDefault;Object.defineProperty(t,"__esModule",{value:!0}),t.Output=t.Input=t.BitmarkParserGenerator=void 0;const s=r(4718),l=r(5126),p=r(3968),u=r(7984),c=r(8588),y=r(5633),g=r(5663),d=r(6936),f=r(3881),m=r(486),T=r(3069),h=r(2028),b=r(385),B=r(431),v=r(777),C=(0,s.superenum)({string:"string",file:"file"});t.Input=C;const P=(0,s.superenum)({bitmark:"bitmark",json:"json",ast:"ast"});t.Output=P;t.BitmarkParserGenerator=class{constructor(){this.ast=new l.Ast,this.jsonParser=new g.JsonParser,this.bitmarkParser=new y.BitmarkParser,this.textParser=new v.TextParser,this.textGenerator=new B.TextGenerator,this.jsonStringifyPrettify=(e,t,r)=>{const i=!0===t.prettify?2:t.prettify||void 0;return r||!0===t.stringify||void 0!==i?JSON.stringify(e,null,i):e}}version(){return d.env.appVersion.full}info(e){const t=Object.assign({},e),r=new f.InfoBuilder;let i;const o=!t.outputFormat||t.outputFormat===T.InfoFormat.text,n=t.outputFormat===T.InfoFormat.json,a=t.type===m.InfoType.all,s=t.type===m.InfoType.deprecated,l=a||!s,p=a||s;if(t.type===m.InfoType.bit){const e=r.getSupportedBitConfigs().filter((e=>{if(!t.bit)return!0;return h.Config.getBitType(t.bit)===e.bitType}));i=o?e.map((e=>e.toString({includeChains:!0,includeConfigs:!0}))).join("\n\n--------------\n\n"):e}else{const e=r.getSupportedBits({includeNonDeprecated:l,includeDeprecated:p}).filter((e=>{if(!t.bit)return!0;const r=h.Config.getBitType(t.bit);return e.name===r||void 0}));i=o?this.supportedBitsAsString(e):e}if(n){const e=!0===t.prettify?2:t.prettify||void 0;i=JSON.stringify(i,null,e)}return i}convert(e,t){return a(this,void 0,void 0,(function*(){let r;const i=Object.assign({},t),o=Object.assign({},i.jsonOptions),n=i.outputFormat,s=n===P.bitmark,l=n===P.json,y=n===P.ast,g=c.BitmarkParserType.peggy;let f=e;if(d.env.isBrowser&&i.outputFile)throw new Error("Cannot write to file in browser environment");i.inputFormat&&i.inputFormat!==C.file||d.env.isNode&&fs.existsSync(f)&&(f=fs.readFileSync(f,{encoding:"utf8"}));let m=this.ast.preprocessAst(f);const T=!!m;T||(m=this.jsonParser.toAst(f));const h=!!(null==m?void 0:m.bits),b=e=>a(this,void 0,void 0,(function*(){yield B(e),yield x(r)})),B=e=>a(this,void 0,void 0,(function*(){r=this.bitmarkParser.toAst(e,{parserType:g})})),v=e=>a(this,void 0,void 0,(function*(){if(g===c.BitmarkParserType.peggy)if(m=this.bitmarkParser.toAst(e,{parserType:g}),i.outputFile){const e=new JsonFileGenerator_1.JsonFileGenerator(i.outputFile,i);yield e.generate(m)}else{const e=new u.JsonObjectGenerator(i),t=yield e.generate(m);r=this.jsonStringifyPrettify(t,o)}})),x=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new BitmarkFileGenerator_1.BitmarkFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new p.BitmarkStringGenerator(i);r=yield t.generate(e)}})),k=e=>a(this,void 0,void 0,(function*(){r=this.jsonStringifyPrettify(e,o)})),K=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new JsonFileGenerator_1.JsonFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new u.JsonObjectGenerator(i),n=yield t.generate(e);r=this.jsonStringifyPrettify(n,o)}})),w=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new BitmarkFileGenerator_1.BitmarkFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new p.BitmarkStringGenerator(i);r=yield t.generate(e)}})),_=e=>a(this,void 0,void 0,(function*(){r=this.jsonStringifyPrettify(e,o)})),S=e=>a(this,void 0,void 0,(function*(){yield K(e)}));return!h&&!T?s?yield b(f):y?yield B(f):yield v(f):T?y?yield k(m):l?yield K(m):yield x(m):l?yield S(m):y?yield _(m):yield w(m),r}))}upgrade(e,t){return a(this,void 0,void 0,(function*(){let r;const i=Object.assign({},t),o=Object.assign({},i.jsonOptions),n=i.bitmarkParserType;let s=e;if(d.env.isBrowser&&i.outputFile)throw new Error("Cannot write to file in browser environment");i.inputFormat&&i.inputFormat!==C.file||d.env.isNode&&fs.existsSync(s)&&(s=fs.readFileSync(s,{encoding:"utf8"}));let l=this.jsonParser.toAst(s);const c=e=>a(this,void 0,void 0,(function*(){const t=this.bitmarkParser.toAst(e,{parserType:n});if(i.outputFile){const e=new BitmarkFileGenerator_1.BitmarkFileGenerator(i.outputFile,i);yield e.generate(t)}else{const e=new p.BitmarkStringGenerator(i);r=yield e.generate(t)}})),y=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new JsonFileGenerator_1.JsonFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new u.JsonObjectGenerator(i),n=yield t.generate(e);r=this.jsonStringifyPrettify(n,o)}}));return!!!(null==l?void 0:l.bits)?yield c(s):yield y(l),r}))}createAst(e,t){let r,i=e;const o=Object.assign({},t);o.inputFormat&&o.inputFormat!==C.file||d.env.isNode&&fs.existsSync(i)&&(i=fs.readFileSync(i,{encoding:"utf8"}));let n=this.ast.preprocessAst(i);const a=!!n;a||(n=this.jsonParser.toAst(i));return r=!!!(null==n?void 0:n.bits)&&!a?this.bitmarkParser.toAst(i):n,r}convertText(e,t){return a(this,void 0,void 0,(function*(){var r,i;let o,n;const a=Object.assign({},t),s=Object.assign({},a.fileOptions),l=Object.assign({},a.jsonOptions),p=null!==(r=a.textFormat)&&void 0!==r?r:b.TextFormat.bitmarkMinusMinus,u=null!==(i=a.textLocation)&&void 0!==i?i:TextLocation_1.TextLocation.body;let c=e;if(d.env.isBrowser&&a.outputFile)throw new Error("Cannot write to file in browser environment");a.inputFormat&&a.inputFormat!==C.file||d.env.isNode&&fs.existsSync(c)&&(c=fs.readFileSync(c,{encoding:"utf8"}));const y=this.textParser.preprocessAst(c),g=!!y;if(n=g?yield this.textGenerator.generate(y,p,u):this.textParser.toAst(c,{textFormat:p,isProperty:!1}),a.outputFile){const e=a.outputFile.toString();let t=n;g||(t=this.jsonStringifyPrettify(n,l,!0));const r=s.append?"a":"w";fs.ensureDirSync(path_1.default.dirname(e)),fs.writeFileSync(e,t,{flag:r})}else o=g?n:this.jsonStringifyPrettify(n,l);return o}))}breakscapeText(e,t){if(!e)return e;const r=Object.assign({},t),i=Object.assign({},r.fileOptions);r.textFormat||(r.textFormat=b.TextFormat.bitmarkMinusMinus),r.textLocation||(r.textLocation=TextLocation_1.TextLocation.body);let o=e;if(d.env.isBrowser&&r.outputFile)throw new Error("Cannot write to file in browser environment");r.inputFormat&&r.inputFormat!==C.file||d.env.isNode&&fs.existsSync(o)&&(o=fs.readFileSync(o,{encoding:"utf8"}));const n=Breakscape_1.Breakscape.breakscape(o,{textFormat:r.textFormat,textLocation:r.textLocation});if(!r.outputFile)return n;{const e=r.outputFile.toString(),t=i.append?"a":"w";fs.ensureDirSync(path_1.default.dirname(e)),fs.writeFileSync(e,n,{flag:t})}}unbreakscapeText(e,t){if(!e)return e;const r=Object.assign({},t),i=Object.assign({},r.fileOptions);r.textFormat||(r.textFormat=b.TextFormat.bitmarkMinusMinus),r.textLocation||(r.textLocation=TextLocation_1.TextLocation.body);let o=e;if(d.env.isBrowser&&r.outputFile)throw new Error("Cannot write to file in browser environment");r.inputFormat&&r.inputFormat!==C.file||d.env.isNode&&fs.existsSync(o)&&(o=fs.readFileSync(o,{encoding:"utf8"}));const n=Breakscape_1.Breakscape.unbreakscape(o,{textFormat:r.textFormat,textLocation:r.textLocation});if(!r.outputFile)return n;{const e=r.outputFile.toString(),t=i.append?"a":"w";fs.ensureDirSync(path_1.default.dirname(e)),fs.writeFileSync(e,n,{flag:t})}}supportedBitsAsString(e){let t="";for(const r of e)t+=`${r.name} (since: ${r.since}`,r.deprecated&&(t+=`, deprecated: ${r.deprecated}`),t+=")\n";return t}}},2028:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Config=void 0;const i=r(3619),o=r(9600),n=r(1457),a=r(6915),s=r(5512),l=r(5854),p=r(385),u=r(955),c=r(4445),y=r(6853),g=r(5837),d=r(9916);const f=new class{constructor(){this.bitLevelMin=1,this.bitLevelMax=7,this.bitCache=new Map,this.comboResourcesCache=new Map}getBitType(e){var t;return(null==e?void 0:e.startsWith("|"))&&(e=e.substring(1)),null!==(t=l.BitType.fromValue(e))&&void 0!==t?t:l.BitType._error}isOfBitType(e,t){if(!e)return!1;if(e===t)return!0;const r=this.getBitConfig(e);if(!r)return!1;if(Array.isArray(t)){for(const e of t)if(r.inheritedBitTypesSet.has(e))return!0;return!1}return r.inheritedBitTypesSet.has(t)}isBitTypeCommented(e){return!!(null==e?void 0:e.startsWith("|"))}getBitConfig(e){var t;let r=this.bitCache.get(e);if(!r){const o=()=>{throw new Error(`No config found for bit: ${e}`)},n=[],a=[];let s=e;for(;s;){const e=y.BITS[s];e||o(),n.push(s),a.push(e),s=e.baseBitType}a.reverse();const l=a.reduce(((e,t)=>e=u.ObjectUtils.deepMerge(e,t)),{}),{since:g,textFormatDefault:d,quizBit:f,tags:m,cardSet:T,deprecated:h,bodyAllowed:b,bodyRequired:B,footerAllowed:v,footerRequired:C,resourceAttachmentAllowed:P,rootExampleType:x}=l,k=this.getAllResourcesTagsWithZeroCounts(),K=c.ConfigHydrator.hydrateTagsConfig(null!=m?m:[]),w=c.ConfigHydrator.hydrateCardSetConfig(T),_=null===(t=K.info)||void 0===t?void 0:t.comboResourceType,S=Object.assign({},K.tags);for(const[e,t]of Object.entries(k))S[e]||(S[e]=t);r=new i.BitConfig({since:g,bitType:e,inheritedBitTypes:n,textFormatDefault:null!=d?d:p.TextFormat.bitmarkMinusMinus,tags:S,cardSet:w,quizBit:f,deprecated:h,bodyAllowed:b,bodyRequired:B,footerAllowed:v,footerRequired:C,resourceAttachmentAllowed:P,rootExampleType:x,comboResourceType:_}),this.bitCache.set(e,r)}return r}getRawPropertiesConfig(){return d.PROPERTIES}getTagConfigForTag(e,t){if(e)for(const[,r]of Object.entries(e))if(r.tag===t)return r}getTagsConfigForCardSet(e,t,r){const i=this.getBitConfig(e);if(!i)return;const o=i.cardSet;if(!o)return;t=Math.min(t,o.variants.length-1);const n=o.variants[t];return n[r=Math.min(r,n.length-1)].tags}getBitResourcesConfig(e,t){var r;let i={};const a=new Map,l=this.getBitConfig(e),p={};for(const[e,t]of Object.entries(l.tags))t.type===s.BitTagType.resource&&(p[e]=t);const u=null!==(r=l.comboResourceType)&&void 0!==r?r:l.resourceAttachmentAllowed&&t;if(u){const e=new Map,r=this.getComboResource(u);if(r){const t=Object.values(r).filter((e=>e.type===s.BitTagType.resource));t.map((e=>e.tag)).forEach((r=>{const i=t.find((e=>e.tag===r));i&&e.set(r,i)}));const i=this.getComboResourceTagTypes(u);i&&i.length>0&&a.set(u,i)}if(t)for(const[t,r]of Object.entries(p)){const n=u===r.tag,a=!!e&&e.has(r.tag);if(n){const e=new o.ResourceTagConfig(r.configKey,r.tag,1,1,r.chain,r.jsonKey,r.deprecated);i[t]=e}else if(a){if(e){const o=e.get(r.tag);o&&(i[t]=o)}}else i[t]=r}else i=p}else i=p;return new n.ResourcesConfig(i,l.resourceAttachmentAllowed,t,a)}getComboResourceTagTypes(e){const t=this.getComboResource(e);if(t){return Object.values(t).filter((e=>e.type===s.BitTagType.resource)).map((e=>e.tag))}}getComboResource(e){if(!e)return;let t=this.comboResourcesCache.get(e);return t||(t={},Object.values(g.GROUPS).filter((t=>t.type===a.GroupConfigType.comboResource&&t.comboResourceType===e)).forEach((e=>{t=Object.assign(Object.assign({},t),c.ConfigHydrator.hydrateTagsConfig(e.tags).tags)})),0===Object.keys(t).length&&(t=void 0),this.comboResourcesCache.set(e,t)),t}getAllResourcesTagsWithZeroCounts(){let e=this.allResourcesCache;if(!e){e={},Object.values(g.GROUPS).filter((e=>e.type===a.GroupConfigType.resource)).forEach((t=>{e=Object.assign(Object.assign({},e),c.ConfigHydrator.hydrateTagsConfig(t.tags).tags)}));for(const t of Object.values(e)){const e=t;e.maxCount=0,e.minCount=0}this.allResourcesCache=e}return e}};t.Config=f},2220:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.parse=void 0;const i=r(8321).parse;t.parse=i},2287:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.EMPTY_VERSION=void 0;t.EMPTY_VERSION={full:"",major:"",minor:"",patch:"",build:""}},2483:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextMarkType=void 0;const i=(0,r(4718).superenum)({bold:"bold",light:"light",italic:"italic",highlight:"highlight",strike:"strike",subscript:"subscript",superscript:"superscript",ins:"ins",del:"del",underline:"underline",doubleUnderline:"doubleUnderline",circle:"circle",languageEm:"languageEm",userUnderline:"userUnderline",userDoubleUnderline:"userDoubleUnderline",userStrike:"userStrike",userCircle:"userCircle",userHighlight:"userHighlight",notranslate:"notranslate",link:"link",ref:"ref",xref:"xref",extref:"extref",footnote:"footnote",footnoteStar:"footnote*",symbol:"symbol",var:"var",code:"code",timer:"timer",duration:"duration",color:"color",comment:"comment"});t.TextMarkType=i},2497:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))},o=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r},n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonGenerator=void 0;const a=n(r(7678)),s=r(5126),l=r(7735),p=r(2028),u=r(126),c=r(5854),y=r(3811),g=r(4410),d=r(363),f=r(6149),m=r(385),T=r(6877),h=r(9554),b=r(777),B=r(4078),v=r(8025),C=r(4),P=r(431),x={};class k extends C.AstWalkerGenerator{constructor(e,t){var r,i;super(),this.ast=new s.Ast,this.textParser=new b.TextParser,this.json=[],this.bitWrapperJson={},this.bitJson={},this.textDefault=l.Breakscape.EMPTY_STRING,this.bodyDefault=l.Breakscape.EMPTY_STRING,this.bodyJson=this.bodyDefault,this.placeholderIndex=0,this.enter=this.enter.bind(this),this.between=this.between.bind(this),this.exit=this.exit.bind(this),this.leaf=this.leaf.bind(this),this.bodyBitCallback=this.bodyBitCallback.bind(this),this.bitmarkVersion=null!==(r=y.BitmarkVersion.fromValue(null==t?void 0:t.bitmarkVersion))&&void 0!==r?r:y.DEFAULT_BITMARK_VERSION,this.textParserVersion=this.textParser.version(),this.options=Object.assign(Object.assign({},x),null==t?void 0:t.jsonOptions),this.debugGenerationInline=null!==(i=this.options.debugGenerationInline)&&void 0!==i&&i,this.jsonPrettifySpace=!0===this.options.prettify?2:this.options.prettify||void 0,this.bitmarkVersion===y.BitmarkVersion.v2?void 0===this.options.textAsPlainText&&(this.options.textAsPlainText=!0):void 0===this.options.textAsPlainText&&(this.options.textAsPlainText=!1),this.textGenerator=new P.TextGenerator(y.BitmarkVersion.v2,{bodyBitCallback:this.bodyBitCallback,debugGenerationInline:this.debugGenerationInline}),this.writer=e,this.generatePropertyHandlers()}generate(e){return i(this,void 0,void 0,(function*(){this.resetState(),yield this.writer.open(),this.walkAndWrite(e),this.write(JSON.stringify(this.json,null,this.jsonPrettifySpace)),yield this.writer.close()}))}generateSync(e){this.resetState(),this.writer.openSync(),this.walkAndWrite(e),this.writer.closeSync()}resetState(){this.json=[],this.bitWrapperJson={},this.bitJson={},this.textDefault=this.options.textAsPlainText?l.Breakscape.EMPTY_STRING:[],this.bodyDefault=this.options.textAsPlainText?l.Breakscape.EMPTY_STRING:[],this.bodyJson=this.bodyDefault,this.listItem=void 0,this.placeholderIndex=0,this.printed=!1}walkAndWrite(e){this.ast.walk(e,u.NodeType.bitmarkAst,this,void 0)}enter_bitmarkAst(e,t){this.json=[]}exit_bitmarkAst(e,t){this.options.textAsPlainText&&this.convertAllBitmarkTextsToStringsForPlainText(this.json),this.removeTemporaryProperties(this.json)}enter_bitsValue(e,t){var r,i;const o=e.value;this.bitWrapperJson={},this.json.push(this.bitWrapperJson),this.bitJson=this.createBitJson(o),this.bitWrapperJson.bit=this.bitJson;const n=p.Config.getBitConfig(o.bitType),a=this.getTextFormat(t),s=!!n.rootExampleType,l=n.rootExampleType===d.ExampleType.boolean;if(s){let e;l?(e=!0,p.Config.isOfBitType(o.bitType,c.BitType.trueFalse1)&&void 0!==(null===(i=null===(r=o.cardNode)||void 0===r?void 0:r.statement)||void 0===i?void 0:i.isCorrect)&&(e=o.cardNode.statement.isCorrect)):e="true";const t=this.toExample(o,{defaultExample:e,isBoolean:l,textFormat:a});this.bitJson.isExample=t.isExample,this.bitJson.example=t.example}else o.isExample&&(this.bitJson.isExample=!0);this.placeholderIndex=0}exit_bitsValue(e,t){const r=this.bitJson.isExample,i=this.bitJson.example;delete this.bitJson.isExample,delete this.bitJson.example,this.bitJson.isExample=r,this.bitJson.example=i,this.cleanBitJson(this.bitJson)}enter_imageSource(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_person(e,t){const r=this.getBitType(t);let i="person";return p.Config.isOfBitType(r,c.BitType.conversationLeft1)&&(i="partner"),this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1,keyOverride:i})}enter_ratingLevelStart(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_ratingLevelEnd(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_productId(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==u.NodeType.bitsValue)return!0;return this.getBitType(t)===c.BitType.module?this.addProperty(this.bitJson,"productId",r,{array:!0}):r.length>0&&this.addProperty(this.bitJson,"productId",r[r.length-1],{array:!1}),!1}enter_markConfig(e,t){return!0}enter_markConfigValue(e,t){const r=e.value,i=this.getParentNode(t);return(null==i?void 0:i.key)!==u.NodeType.markConfig||(this.bitJson.marks||(this.bitJson.marks=[]),this.bitJson.marks.push(r),!1)}enter_item(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_lead(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_pageNumber(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_marginNumber(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_hint(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_instruction(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_title(e,t){return this.standardHandler(e,t,[u.NodeType.bitsValue,u.NodeType.cardNode],{array:!0})}enter_subtitle(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_caption(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_width(e,t){var r;let i=e.value;const o=this.getBitType(t),n=this.getParentNode(t);return(null==n?void 0:n.key)===u.NodeType.bitsValue&&p.Config.isOfBitType(o,c.BitType.extractorBlock)&&(i=null!==(r=v.NumberUtils.asNumber(i,0))&&void 0!==r?r:0),this.standardHandler(e,t,void 0,{array:!1,valueOverride:i})}enter_height(e,t){var r;let i=e.value;const o=this.getBitType(t),n=this.getParentNode(t);return(null==n?void 0:n.key)===u.NodeType.bitsValue&&p.Config.isOfBitType(o,c.BitType.extractorBlock)&&(i=null!==(r=v.NumberUtils.asNumber(i,0))&&void 0!==r?r:0),this.standardHandler(e,t,void 0,{array:!1,valueOverride:i})}enter_extraProperties(e,t){const r=e.value;if(!this.options.excludeUnknownProperties&&r)for(const[e,t]of Object.entries(r)){let r=e;Object.prototype.hasOwnProperty.call(this.bitJson,e)&&(r=`_${e}`),this.addProperty(this.bitJson,r,t,{array:!0})}}enter_cardBitsValue(e,t){var r,i,o,n,a,s,l,p,u;const y=e.value,g=this.getBitType(t);if(!g)return;let d;if(g===c.BitType.bookReferenceList){this.bitJson.bookReferences||(this.bitJson.bookReferences=[]);const e={};this.addProperty(e,"lang",y.lang,{array:!1}),this.addProperty(e,"refAuthor",null!==(r=y.refAuthor)&&void 0!==r?r:[],{array:!0}),this.addProperty(e,"refBookTitle",null!==(i=y.refBookTitle)&&void 0!==i?i:[],{array:!1}),this.addProperty(e,"refPublisher",null!==(o=y.refPublisher)&&void 0!==o?o:[],{array:!0}),this.addProperty(e,"refPublicationYear",null!==(n=y.refPublicationYear)&&void 0!==n?n:[],{array:!1}),this.addProperty(e,"citationStyle",null!==(a=y.citationStyle)&&void 0!==a?a:[],{array:!1}),this.bitJson.bookReferences.push(e)}else g===c.BitType.pageFooter?(this.bitJson.sections||(this.bitJson.sections=[]),d=this.bitJson.sections):(this.bitJson.listItems||(this.bitJson.listItems=[]),d=this.bitJson.listItems),this.listItem={item:null!==(s=y.item)&&void 0!==s?s:[],lead:null!==(l=y.lead)&&void 0!==l?l:[],hint:null!==(p=y.hint)&&void 0!==p?p:[],instruction:null!==(u=y.instruction)&&void 0!==u?u:[],body:this.bodyDefault},d.push(this.listItem)}exit_cardBitsValue(e,t){this.listItem=void 0}enter_body(e,t){const r=e.value,i=this.getParentNode(t);if(!i)return!1;const o=this.getTextFormat(t),n=o===m.TextFormat.bitmarkMinusMinus||o===m.TextFormat.bitmarkPlusPlus;if(this.bodyJson=r.body,i.key===u.NodeType.bitsValue){this.bitJson.body=this.bodyJson;const e=n&&this.isBitmarkText(this.bodyJson);if(this.options.textAsPlainText&&e){const e=this.textGenerator.generateSync(this.bodyJson,o,T.TextLocation.body,{noBreakscaping:!0});this.bitJson.body=(null!=e?e:"").trim()}else e&&(this.bitJson.body=this.moveBodyBitPropertiesToAttrs(this.bodyJson))}else i.key===u.NodeType.cardBitsValue&&this.listItem&&(this.listItem.body=this.bodyJson);return!1}bodyBitCallback(e,t,r){var i;const o=`{${this.placeholderIndex}}`;return this.placeholderIndex++,this.bitJson.placeholders=null!==(i=this.bitJson.placeholders)&&void 0!==i?i:{},this.bitJson.placeholders[o]=e,o}moveBodyBitPropertiesToAttrs(e,t=0){if(0===t)e=(0,a.default)(e);else if(t>5e3)throw new Error("Recursion limit exceeded");for(const r of e)if(r.type!==g.BodyBitType.text&&g.BodyBitType.values().includes(r.type)){const e=r;e.attrs={};for(const[t,r]of Object.entries(e))"type"!==t&&"attrs"!==t&&(e.attrs[t]=r,delete e[t])}else Array.isArray(r.content)&&(t++,this.moveBodyBitPropertiesToAttrs(r.content,t));return e}enter_footer(e,t){return this.standardHandler(e,t,void 0,{array:!0,valueOverride:e.value.footer})}enter_elements(e,t){return this.standardHandler(e,t,void 0,{array:!0})}enter_flashcards(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0,keyOverride:"cards"})}enter_definitions(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_statement(e,t){var r,i;const o=e.value,n=this.getParentNode(t);(null==n?void 0:n.key)===u.NodeType.cardNode&&o&&(this.bitJson.statement=null!==(r=o.statement)&&void 0!==r?r:"",this.bitJson.isCorrect=null!==(i=o.isCorrect)&&void 0!==i&&i,this.bitJson.example=o.example,this.bitJson.isExample=o.isExample)}enter_statements(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_choices(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_responses(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_feedbacks(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_quizzes(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_heading(e,t){return this.standardHandler(e,t,void 0,{array:!1})}enter_pairs(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_matrix(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_pronunciationTable(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!1})}enter_table(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!1})}enter_questions(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_botResponses(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0,keyOverride:"responses"})}enter_ingredients(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_captionDefinitionList(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!1})}enter_imagePlaceholder(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_resources(e,t){var r,i;const o=e.value,n=this.getBitType(t),a=this.getResourceType(t);if(!o||!n)return!0;let s;const l=p.Config.getBitConfig(n),u=p.Config.getBitResourcesConfig(n,a),y=u.comboResourceTagTypesMap;if(u.comboResourceTagTypesMap.size>0)for(const[e,t]of y.entries()){const n={type:e,__typeAlias:e};for(const e of t){const t=o.find((t=>t.__typeAlias===e));if(t){const e=p.Config.getTagConfigForTag(l.tags,t.__typeAlias),o=null!==(r=null==e?void 0:e.jsonKey)&&void 0!==r?r:t.__typeAlias,a=null!==(i=null==e?void 0:e.tag)&&void 0!==i?i:t.__typeAlias,s=t.__typeAlias===a?t:void 0;if(s)for(const[e,t]of Object.entries(s))"type"!==e&&(n[o]=t)}}s=n}else if(p.Config.isOfBitType(n,[c.BitType.imagesLogoGrave,c.BitType.prototypeImages])){const e=[];for(const t of o)t.type===f.ResourceTag.image&&e.push(t);n===c.BitType.imagesLogoGrave?this.bitJson.logos=e:this.bitJson.images=e}else o.length>=1&&(s=o[0]);return this.bitJson.resource=s,!1}leaf_level(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_book(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}leaf_book(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_anchor(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_reference(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_referenceEnd(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_markup(e,t){const r=e.value;return r&&(this.bitWrapperJson.bitmark=r),!1}enter_internalComment(e,t){return!1}enter_parser(e,t){const r=e.value,i=this.getBitType(t),n=this.getParentNode(t);if(r&&i){const{version:e,excessResources:i,warnings:a,errors:s}=r,l=o(r,["version","excessResources","warnings","errors"]),p=`${this.bitmarkVersion}`,c=this.textParserVersion;let y;if(Array.isArray(i)&&i.length>0){y=[];for(const e of i)y.push(e)}const g=this.getInternalComments(t);(null==n?void 0:n.key)===u.NodeType.bitsValue&&(this.bitWrapperJson.parser=Object.assign(Object.assign({version:e,bitmarkVersion:p,textParserVersion:c,internalComments:g},l),{warnings:a,errors:s,excessResources:y}),this.options.enableWarnings||delete this.bitWrapperJson.parser.warnings)}}generatePropertyHandlers(){var e;const t=p.Config.getRawPropertiesConfig();for(const r of Object.values(t)){const t=null!==(e=r.astKey)&&void 0!==e?e:r.tag,i=`enter_${t}`;"function"!=typeof this[i]&&("example"!==t&&(this[i]=(e,t)=>{var i;const o=e.value;if(null==o)return;const n=this.getParentNode(t);if((null==n?void 0:n.key)!==u.NodeType.bitsValue)return;const a=null!==(i=r.jsonKey)&&void 0!==i?i:r.tag;this.addProperty(this.bitJson,a,o,{array:!r.single})},this[i]=this[i].bind(this)))}}standardHandler(e,t,r,i){var o,n;if(r){const e=Array.isArray(r)?r:[r],i=this.getParentNode(t);if(!(null==i?void 0:i.key)||!e.includes(null==i?void 0:i.key))return!0}return this.addProperty(this.bitJson,null!==(o=i.keyOverride)&&void 0!==o?o:e.key,null!==(n=i.valueOverride)&&void 0!==n?n:e.value,i),!1}addProperty(e,t,r,i){if(void 0!==r){let o;Array.isArray(r)||(r=[r]);const n=r;o=!i.array&&n.length>=1?n[n.length-1]:n,(i.allowNull||null!=o)&&(e[t]=o)}}toExample(e,t){const{isExample:r,example:i,__isDefaultExample:o}=e,{defaultExample:n,isBoolean:a}=t;if(!r)return{isExample:!1,example:null};let s;return s=o?a?B.BooleanUtils.toBoolean(n):this.convertBreakscapedStringToJsonText(n,t.textFormat,!0):a?B.BooleanUtils.toBoolean(i):this.convertBreakscapedStringToJsonText(i,t.textFormat,!0),{isExample:!0,example:s}}getBitType(e){for(const t of e)if(t.key===u.NodeType.bitsValue){const e=t.value;return null==e?void 0:e.bitType}}getTextFormat(e){var t;const r=this.getBitType(e);if(r){const i=p.Config.getBitConfig(r);for(const r of e)if(r.key===u.NodeType.bitsValue){const e=r.value;return null!==(t=m.TextFormat.fromValue(null==e?void 0:e.textFormat))&&void 0!==t?t:i.textFormatDefault}}return m.TextFormat.bitmarkMinusMinus}getResourceType(e){for(const t of e)if(t.key===u.NodeType.bitsValue){const e=t.value;return null==e?void 0:e.resourceType}}getInternalComments(e){if(this.getBitType(e))for(const t of e)if(t.key===u.NodeType.bitsValue){return t.value.internalComment}}convertBreakscapedStringToJsonText(e,t,r){if(!(t===m.TextFormat.bitmarkMinusMinus||t===m.TextFormat.bitmarkPlusPlus))return e||"";if(this.options.textAsPlainText)return e||"";return this.textParser.toAst(e,{textFormat:t,isProperty:r})}concatenatePlainTextWithJsonTexts(e,t,r){var i;if(Array.isArray(e)){if(r=r.trim()){const o=r.split("\n"),n=[];for(let e=0;e<t;e++)n.push({type:h.TextNodeType.hardBreak});for(let e=0;e<o.length;e++){const t=o[e];t&&n.push({text:t,type:h.TextNodeType.text}),e<o.length-1&&n.push({type:h.TextNodeType.hardBreak})}const a=e[e.length-1];a&&a.type===h.TextNodeType.paragraph?a.content=[...null!==(i=a.content)&&void 0!==i?i:[],...n]:e.push({type:h.TextNodeType.paragraph,content:n,attrs:{}})}return e}return`${null!=e?e:""}${"\n".repeat(t)}${null!=r?r:""}`}isBitmarkText(e){return null!=e&&(!!Array.isArray(e)&&"text"===e.__tag)}writeInlineDebug(e,t){let r=e;t.open?r=`<${e}>`:t.close?r=`</${e}>`:t.single&&(r=`<${e} />`),this.writeString(r)}writeString(e){null!=e&&this.write(`${e}`)}createBitJson(e){return{type:e.isCommented?c.BitType._comment:e.bitType,originalType:e.isCommented?e.bitType:void 0,format:e.textFormat,bitLevel:e.bitLevel}}cleanBitJson(e){var t,r,i,o,n,a;const s=p.Config.getBitType(e.type),l=p.Config.getBitConfig(s);if(null==e.originalType&&(e.originalType=void 0),e.item||(e.item=void 0),p.Config.isOfBitType(s,[c.BitType._error,c.BitType._comment]))delete e.format,delete e.item,delete e.lead,delete e.pageNumber,delete e.marginNumber,delete e.hint,delete e.instruction;else{let u=!1,y=!1;p.Config.isOfBitType(s,[c.BitType.page])?(null!=e.item&&0!==(null===(t=e.item)||void 0===t?void 0:t.length)||delete e.item,null!=e.lead&&0!==(null===(r=e.lead)||void 0===r?void 0:r.length)||delete e.lead,null!=e.pageNumber&&0!==(null===(i=e.pageNumber)||void 0===i?void 0:i.length)||delete e.pageNumber,null!=e.marginNumber&&0!==(null===(o=e.marginNumber)||void 0===o?void 0:o.length)||delete e.marginNumber,null!=e.hint&&0!==(null===(n=e.hint)||void 0===n?void 0:n.length)||delete e.hint,null!=e.instruction&&0!==(null===(a=e.instruction)||void 0===a?void 0:a.length)||delete e.instruction):(null==e.item&&(e.item=this.textDefault),null==e.lead&&(e.lead=this.textDefault),null==e.hint&&(e.hint=this.textDefault),null==e.instruction&&(e.instruction=this.textDefault),null==e.pageNumber&&(e.pageNumber=this.textDefault),null==e.marginNumber&&(e.marginNumber=this.textDefault)),null==e.body&&(e.body=this.bodyDefault),p.Config.isOfBitType(s,[c.BitType.article]),p.Config.isOfBitType(s,[c.BitType.example])&&(u=!0,y=!0),p.Config.isOfBitType(s,[c.BitType.multipleChoice1,c.BitType.multipleResponse1,c.BitType.multipleChoiceText,c.BitType.highlightText,c.BitType.gapText,c.BitType.gapTextInstructionGrouped,c.BitType.clozeAndMultipleChoiceText,c.BitType.sequence,c.BitType.mark,c.BitType.flashcard,c.BitType.definitionList])&&(u=!0,null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,[c.BitType.sequence])&&(u=!0,y=!0,null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.cloze)&&(u=!0,p.Config.isOfBitType(s,c.BitType.clozeSolutionGrouped)?(null==e.quizCountItems&&(e.quizCountItems=!0),null==e.quizStrikethroughSolutions&&(e.quizStrikethroughSolutions=!0)):p.Config.isOfBitType(s,c.BitType.clozeInstructionGrouped)&&(null==e.quizCountItems&&(e.quizCountItems=!0),null==e.quizStrikethroughSolutions&&(e.quizStrikethroughSolutions=!1))),p.Config.isOfBitType(s,[c.BitType.multipleChoice,c.BitType.multipleResponse])&&(u=!0,null==e.body&&(e.body=this.bodyDefault),null==e.footer&&(e.footer=this.textDefault)),p.Config.isOfBitType(s,c.BitType.essay)&&(u=!0,y=!0,null==e.body&&(e.body=this.bodyDefault),null==e.partialAnswer&&(e.partialAnswer="")),p.Config.isOfBitType(s,c.BitType.trueFalse1)&&(u=!0,y=!0,null==e.isCorrect&&(e.isCorrect=!1),null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.trueFalse)&&(u=!0,null==e.labelFalse&&(e.labelFalse=""),null==e.labelTrue&&(e.labelTrue=""),null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.chapter)&&(null==e.toc&&(e.toc=!0),null==e.progress&&(e.progress=!0),null==e.level&&(e.level=1),null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.interview)&&(u=!0,null==e.body&&(e.body=this.bodyDefault),null==e.footer&&(e.footer=this.textDefault),null==e.questions&&(e.questions=[])),s===c.BitType.matchMatrix&&(u=!0),p.Config.isOfBitType(s,c.BitType.match)&&(u=!0,null==e.heading&&(e.heading={})),p.Config.isOfBitType(s,c.BitType.learningPathBook)&&(null==e.isTracked&&(e.isTracked=!0),null==e.isInfoOnly&&(e.isInfoOnly=!1)),p.Config.isOfBitType(s,c.BitType.table)&&(null==e.tableFixedHeader&&(e.tableFixedHeader=!1),null==e.tableSearch&&(e.tableSearch=!1),null==e.tableSort&&(e.tableSort=!1),null==e.tablePagination&&(e.tablePagination=!1),null==e.tablePaginationLimit&&(e.tablePaginationLimit=0),null==e.tableHeight&&(e.tableHeight=0),null==e.tableWhitespaceNoWrap&&(e.tableWhitespaceNoWrap=!1),null==e.tableAutoWidth&&(e.tableAutoWidth=!0),null==e.tableResizableColumns&&(e.tableResizableColumns=!1),null==e.tableColumnMinWidth&&(e.tableColumnMinWidth=0)),p.Config.isOfBitType(s,c.BitType.bookReference)&&(null==e.refAuthor&&(e.refAuthor=[]),null==e.refBookTitle&&(e.refBookTitle=""),null==e.refPublisher&&(e.refPublisher=[]),null==e.refPublicationYear&&(e.refPublicationYear="")),p.Config.isOfBitType(s,[c.BitType.pageBanner,c.BitType.pageBuyButton,c.BitType.pageBuyButtonAlt,c.BitType.pageBuyButtonPromotion,c.BitType.pageFooter,c.BitType.pageOpenBook,c.BitType.pagePerson,c.BitType.pageProduct,c.BitType.pageProductList,c.BitType.pageProductVideo,c.BitType.pageProductVideoList,c.BitType.pageSectionFolder,c.BitType.pageSubscribe,c.BitType.pageSubpage])&&(null==e.slug&&(e.slug=""),null==e.body&&(e.body=this.bodyDefault),p.Config.isOfBitType(s,c.BitType.pageBuyButton)&&null==e.content2Buy&&(e.content2Buy="")),p.Config.isOfBitType(s,c.BitType.book)&&(null==e.maxTocChapterLevel&&(e.maxTocChapterLevel=-1),null==e.hasMarkAsDone&&(e.hasMarkAsDone=!1),null==e.processHandIn&&(e.processHandIn=!1),null==e.isPublic&&(e.isPublic=!1),null==e.chatWithBook&&(e.chatWithBook=!1),null==e.chatWithBookBrainKey&&(e.chatWithBookBrainKey="")),s!==c.BitType.articleAi&&s!==c.BitType.noteAi&&s!==c.BitType.summaryAi||null==e.aiGenerated&&(e.aiGenerated=!0),p.Config.isOfBitType(s,[c.BitType.articleResponsive,c.BitType.pageArticleResponsive])&&null==e.imageFirst&&(e.imageFirst=!0),p.Config.isOfBitType(s,c.BitType.reviewNote)&&(null==e.resolved&&(e.resolved=!1),null==e.resolvedDate&&(e.resolvedDate=""),null==e.resolvedBy&&(e.resolvedBy="")),p.Config.isOfBitType(s,[c.BitType.imagesLogoGrave,c.BitType.prototypeImages])&&(s===c.BitType.imagesLogoGrave?null==e.logos&&(e.logos=[]):null==e.images&&(e.images=[])),p.Config.isOfBitType(s,[c.BitType.stepImageScreenshotWithPointer,c.BitType.surveyMatrix])&&(null==e.pointerTop&&(e.pointerTop=""),null==e.pointerLeft&&(e.pointerLeft=""),p.Config.isOfBitType(s,[c.BitType.surveyMatrix])&&null==e.buttonCaption&&(e.buttonCaption="")),p.Config.isOfBitType(s,[c.BitType.listItem])&&null==e.listItemIndent&&(e.listItemIndent=0),p.Config.isOfBitType(s,c.BitType.surveyRating)&&(null==e.ratingLevelStart&&(e.ratingLevelStart={level:0}),null==e.ratingLevelEnd&&(e.ratingLevelEnd={level:0})),p.Config.isOfBitType(s,c.BitType.vendorStripePricingTable)&&(null==e.stripePricingTableId&&(e.stripePricingTableId=""),null==e.stripePublishableKey&&(e.stripePublishableKey="")),p.Config.isOfBitType(s,c.BitType.callToAction)&&(null==e.buttonCaption&&(e.buttonCaption=""),null==e.callToActionUrl&&(e.callToActionUrl="")),p.Config.isOfBitType(s,c.BitType.handInFile)&&null==e.handInAcceptFileType&&(e.handInAcceptFileType=[]),p.Config.isOfBitType(s,c.BitType.handInSubmit)&&(null==e.handInRequirement&&(e.handInRequirement=[]),null==e.handInInstruction&&(e.handInInstruction=""),null==e.buttonCaption&&(e.buttonCaption="")),p.Config.isOfBitType(s,c.BitType.module)&&null==e.hasBookNavigation&&(e.hasBookNavigation=!0),p.Config.isOfBitType(s,c.BitType.container)&&null==e.allowedBit&&(e.allowedBit=[]),l.quizBit&&null==e.revealSolutions&&(e.revealSolutions=!1),p.Config.isOfBitType(s,c.BitType.platformPath)&&null==e.path&&(e.path=""),u?null==e.isExample&&(e.isExample=!1):(delete e.isExample,delete e.example),y?null==e.example&&(e.example=null):delete e.example}return e}convertAllBitmarkTextsToStringsForPlainText(e){if(!this.options.textAsPlainText)return;const t=e;for(const e in t){const r=t[e];if(this.isBitmarkText(r)){const i=this.textGenerator.generateSync(r,m.TextFormat.bitmarkMinusMinus,T.TextLocation.tag,{noBreakscaping:!0});t[e]=(null!=i?i:"").trim()}else"object"==typeof t[e]&&this.convertAllBitmarkTextsToStringsForPlainText(t[e])}}removeTemporaryProperties(e){const t=e;for(const e in t)e.startsWith("__")?delete t[e]:"object"==typeof t[e]&&this.removeTemporaryProperties(t[e])}write(e){return this.writer.write(e),this}writeLine(e){return this.writer.writeLine(e),this}writeLines(e,t){return this.writer.writeLines(e,t),this}writeWhiteSpace(){return this.writer.writeWhiteSpace(),this}}t.JsonGenerator=k},3029:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CARD_VARIANT_DIVIDER_V1=t.CARD_SIDE_DIVIDER_V1=t.CARD_DIVIDER_V1=t.CARD_VARIANT_DIVIDER_V2=t.CARD_SIDE_DIVIDER_V2=t.CARD_DIVIDER_V2=t.BitContentLevel=t.TypeKey=void 0;const i=r(4718),o=r(9917);t.CARD_DIVIDER_V2="====";t.CARD_SIDE_DIVIDER_V2="--";t.CARD_VARIANT_DIVIDER_V2="++";t.CARD_DIVIDER_V1="===";t.CARD_SIDE_DIVIDER_V1="==";t.CARD_VARIANT_DIVIDER_V1="--";const n=(0,i.superenum)({TextFormat:"TextFormat",ResourceType:"ResourceType",Title:o.Tag.tag_title,Anchor:o.Tag.tag_anchor,Reference:o.Tag.tag_reference,ItemLead:o.Tag.tag_itemLead,Instruction:o.Tag.tag_instruction,Hint:o.Tag.tag_hint,True:o.Tag.tag_true,False:o.Tag.tag_false,Gap:o.Tag.tag_gap,Mark:o.Tag.tag_mark,SampleSolution:o.Tag.tag_sampleSolution,Property:"Property",Resource:"Resource",TagChain:"TagChain",BodyChar:"BodyChar",BodyText:"BodyText",BodyTextPlain:"BodyTextPlain",CardSet:"CardSet",Card:"Card",CardChar:"CardChar",CardText:"CardText",GapChain:"GapChain",TrueFalseChain:"TrueFalseChain",PlainTextDivider:"PlainTextDivider",FooterDivider:"FooterDivider"});t.TypeKey=n;const a=(0,i.superenum)({Bit:"Bit",Card:"Card",Chain:"Chain"});t.BitContentLevel=a},3045:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.bookChainContentProcessor=function(e,t,r,u,c){t===p.BitContentLevel.Chain||function(e,t,r,u,c){const{bitConfig:y}=e;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("book content",u);const g=e.bitContentProcessor(p.BitContentLevel.Chain,r,u.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("book TAGS",g);const{reference:d,referenceEnd:f}=g,m=i.Breakscape.unbreakscape(l.StringUtils.trimmedString(u.value),{textFormat:a.TextFormat.bitmarkMinusMinus,textLocation:s.TextLocation.tag}),T=y.tags[o.PropertyConfigKey.book];if(T&&(T.maxCount===n.Count.infinity||T.maxCount>1))return Array.isArray(c.book)||(c.book=[]),void c.book.push({book:m,reference:null!=d?d:"",referenceEnd:null!=f?f:void 0});c.book=m,c.reference=d,c.referenceEnd=f}(e,0,r,u,c)};const i=r(7735),o=r(9888),n=r(3778),a=r(385),s=r(6877),l=r(9681),p=r(3029)},3063:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.markConfigChainContentProcessor=function(e,t,r,c,y){var g;const{key:d}=c;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("mark content",c);const f=y.markConfig;if(!f)return;const m=n.Config.getTagConfigForTag(r,a.PropertyTag.fromValue(d)),T=e.bitContentProcessor(u.BitContentLevel.Chain,null==m?void 0:m.chain,c.chain),{mark:h}=T,b=i(T,["mark"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("mark TAGS",b);const B=o.Breakscape.unbreakscape(null!==(g=p.StringUtils.trimmedString(c.value))&&void 0!==g?g:"unknown",{textFormat:s.TextFormat.bitmarkMinusMinus,textLocation:l.TextLocation.tag}),v=Object.assign({mark:B,emphasis:"underline"},b);v&&f.push(v)};const o=r(7735),n=r(2028),a=r(166),s=r(385),l=r(6877),p=r(9681),u=r(3029)},3069:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.InfoFormat=void 0;const i=(0,r(4718).superenum)({text:"text",json:"json",pojo:"pojo"});t.InfoFormat=i},3206:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkPegParserHelper=void 0;const i=r(7735),o=r(1163),n=r(385),a=r(6877),s=r(9681),l=r(7461),p=r(3029);r(2028);t.BitmarkPegParserHelper=class{constructor(e){this.cardIndex=0,this.cardSideIndex=0,this.cardVariantIndex=0,this.parse=e.parse,this.parserText=e.parserText,this.parserLocation=e.parserLocation}handleRawBit(e){var t,r;const i=e.trim();if(this.debugPrint("RAW BIT",i),!i)return;const o=null!==(r=null===(t=this.parserLocation())||void 0===t?void 0:t.start)&&void 0!==r?r:{line:1,column:1,offset:0},n=this.parse(e,{startRule:"bit",grammarSource:new l.PeggyGrammarLocation("bit",o)});return n.value&&(n.value.markup=i),n}handleTextFormat(e){return{type:p.TypeKey.TextFormat,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleResourceType(e){return{type:p.TypeKey.ResourceType,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleBitContent(e){let t=this.reduceToArrayOfTypes(e);return t=this.mergeCharToText(t),t}handleBitTag(e){return e}handleTag(e,t){return{type:e,value:t,parser:{text:this.parserText(),location:this.parserLocation()}}}handlePropertyTag(e,t){return{type:p.TypeKey.Property,key:i.Breakscape.unbreakscape(e,{textFormat:n.TextFormat.bitmarkMinusMinus,textLocation:a.TextLocation.tag}),value:t,parser:{text:this.parserText(),location:this.parserLocation()}}}handleResourceTag(e,t){return{type:p.TypeKey.Resource,key:i.Breakscape.unbreakscape(e,{textFormat:n.TextFormat.bitmarkMinusMinus,textLocation:a.TextLocation.tag}),value:t,parser:{text:this.parserText(),location:this.parserLocation()}}}handleTagChain(e){const t=this.reduceToArrayOfTypes(e);let r=t;if(t.length>1){const e=t[0];e.chain=t.slice(1),r=[e]}return r}handlePlainTextDivider(e){return e=this.reduceToString(e),{type:p.TypeKey.PlainTextDivider,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleFooterDivider(e){return e=this.reduceToString(e),{type:p.TypeKey.FooterDivider,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardSet(e){const t=e,r={cards:[]},i={cards:[]};if(t){const e={text:this.parserText(),location:this.parserLocation()};for(const e of t){if(!e)continue;const{type:t,value:i,parser:o}=e;if(!t||t!==p.TypeKey.Card)continue;const{cardIndex:n,cardSideIndex:a,cardVariantIndex:s,value:l}=i;let u=r.cards[n];u||(u={sides:[]},r.cards[n]=u);let c=u.sides[a];c||(c={variants:[]},u.sides[a]=c);c.variants[s]?c.variants[s].value+=l:c.variants[s]={value:l,parser:o}}r.cards=r.cards.filter((e=>e.sides.some((e=>e.variants.some((e=>0!==s.StringUtils.trimmedString(e.value).length))))));for(const t of r.cards){const r={sides:[]};i.cards.push(r);for(const i of t.sides){const t={variants:[]};r.sides.push(t);for(const r of i.variants){let i={line:1,column:1,offset:0};if(r.parser.location){i=r.parser.location.start;const e=r.parser.text,t=e?e.length:0,o=1;i.offset+=t,i.line+=o}let o=this.parse(r.value,{startRule:"cardContent",grammarSource:new l.PeggyGrammarLocation("card-content",i)});o=this.reduceToArrayOfTypes(o),this.debugPrint("parsedCardContent",o),t.variants.push({parser:e,content:o})}}}}return{type:p.TypeKey.CardSet,value:i,parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardSetStart(){this.cardIndex=-1,this.cardSideIndex=0,this.cardVariantIndex=0}handleCardSetEnd(){this.cardIndex=0,this.cardSideIndex=0,this.cardVariantIndex=0}handleCards(e){return e}handleCardLineOrDivider(e,t){let r=!1,i=!1,n=!1;return Array.isArray(e)&&2===e.length&&(e=e[0],t===o.CardSetVersion.v1?(r=e===p.CARD_DIVIDER_V1,i=e===p.CARD_SIDE_DIVIDER_V1,n=e===p.CARD_VARIANT_DIVIDER_V1):(r=e===p.CARD_DIVIDER_V2,i=e===p.CARD_SIDE_DIVIDER_V2,n=e===p.CARD_VARIANT_DIVIDER_V2)),r?(this.cardIndex++,this.cardSideIndex=0,this.cardVariantIndex=0):i?(this.cardSideIndex++,this.cardVariantIndex=0):n&&this.cardVariantIndex++,this.isType(e,p.TypeKey.Card)?e:{type:p.TypeKey.Card,value:{cardIndex:this.cardIndex,cardSideIndex:this.cardSideIndex,cardVariantIndex:this.cardVariantIndex,value:""},parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardLine(e){return{type:p.TypeKey.Card,value:{cardIndex:this.cardIndex,cardSideIndex:this.cardSideIndex,cardVariantIndex:this.cardVariantIndex,value:e},parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardContent(e){return this.mergeCharToText(e)}handleCardTags(e){return e}mergeCharToText(e){var t,r,i,o,n,a;const s=[];let l,u;for(const c of e)switch(c.type){case p.TypeKey.BodyChar:if(l){const e=`${null!==(t=l.value)&&void 0!==t?t:""}${null!==(r=c.value)&&void 0!==r?r:""}`;l.value=e}else l={type:p.TypeKey.BodyText,value:null!==(i=c.value)&&void 0!==i?i:"",parser:{text:this.parserText(),location:this.parserLocation()}};break;case p.TypeKey.CardChar:if(u){const e=`${null!==(o=u.value)&&void 0!==o?o:""}${null!==(n=c.value)&&void 0!==n?n:""}`;u.value=e}else u={type:p.TypeKey.CardText,value:null!==(a=c.value)&&void 0!==a?a:"",parser:{text:this.parserText(),location:this.parserLocation()}};break;default:l&&(s.push(l),l=void 0),u&&(s.push(u),u=void 0),s.push(c)}return l&&s.push(l),u&&s.push(u),s}isType(e,t){if(!e)return!1;const{type:r}=e;return t?Array.isArray(t)?t.indexOf(r)>=0:t===r:!!p.TypeKey.fromValue(r)}reduceToArrayOfTypes(e,t,r){if(!Array.isArray(e))return[];return e.reduce(((e,i,o)=>{if(null==i)return e;const{type:n,value:a}=i;if(Array.isArray(i)){const r=this.reduceToArrayOfTypes(i,t);e.push(...r)}else{if(!this.isType(i,t))return e;if(r&&Array.isArray(a)){const r=this.reduceToArrayOfTypes(a,t);e.push(...r)}else n&&e.push(i)}return e}),[])}reduceToString(e){if(!Array.isArray(e))return"";return e.reduce(((e,t,r)=>{if(null==t)return e;if(Array.isArray(t)){e+=this.reduceToString(t)}else e+=t;return e}),[])}debugPrint(e,t){}}},3619:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitConfig=void 0;const i=r(3778);t.BitConfig=class{constructor(e){this.tags={};const{since:t,bitType:r,inheritedBitTypes:i,textFormatDefault:o,tags:n,cardSet:a,quizBit:s,deprecated:l,bodyAllowed:p,bodyRequired:u,footerAllowed:c,footerRequired:y,resourceAttachmentAllowed:g,rootExampleType:d,comboResourceType:f}=e;this.since=t,this.bitType=r,this.inheritedBitTypes=i,this.inheritedBitTypesSet=new Set(i),this.textFormatDefault=o,this.tags=n,this.cardSet=a,this.quizBit=s,this.deprecated=l,this.bodyAllowed=p??!0,this.bodyRequired=u,this.footerAllowed=c??!0,this.footerRequired=y,this.resourceAttachmentAllowed=g??!0,this.rootExampleType=d,this.comboResourceType=f}toString(e){const t=Object.assign({},e);let r=`[Bit]\n${this.bitType}`;this.inheritedBitTypes.length>0&&(r+="\n\n[Inheritance]",r+=`\n${this.inheritedBitTypes.join(" => ")}`),r+=`\n\n[Default text format]\n${this.textFormatDefault}`;const o=[];null!=this.since&&o.push(`since=${this.since}`),null!=this.deprecated&&o.push(`deprecated=${this.deprecated}`),this.bodyAllowed&&o.push("bodyAllowed"),this.bodyRequired&&o.push("bodyRequired"),this.footerAllowed&&o.push("footerAllowed"),this.footerRequired&&o.push("footerRequired"),this.resourceAttachmentAllowed&&o.push("resourceAttachmentAllowed"),null!=this.rootExampleType&&o.push(`rootExampleType=${this.rootExampleType}`),null!=this.comboResourceType&&o.push(`comboResourceType=${this.comboResourceType}`),r+=`\n\n[Flags]\n${o.join(", ")}`,r+="\n\n[Tags]";for(const e of Object.values(this.tags))(e.maxCount===i.Count.infinity||e.maxCount>0)&&(r+=`\n${e.toString(t)}`);return this.cardSet&&(r+=`\n\n${this.cardSet.toString(t)}`),r}}},3778:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Count=void 0;const i=(0,r(4718).superenum)({infinity:"infinity"});t.Count=i},3811:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_BITMARK_VERSION=t.BitmarkVersion=void 0;const i=(0,r(4718).superenum)({v2:2,v3:3});t.BitmarkVersion=i;const o=i.v3;t.DEFAULT_BITMARK_VERSION=o},3881:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.InfoBuilder=void 0;const i=r(2028),o=r(5854);t.InfoBuilder=class{getSupportedBits(e){var t,r;const n=null===(t=null==e?void 0:e.includeNonDeprecated)||void 0===t||t,a=null!==(r=null==e?void 0:e.includeDeprecated)&&void 0!==r&&r,s=[];for(const e of o.BitType.values()){if(e===o.BitType._error||e===o.BitType._comment)continue;const t=i.Config.getBitType(e),r=i.Config.getBitConfig(t),l=r.inheritedBitTypes.length>0?r.inheritedBitTypes:void 0;(n&&!r.deprecated||a&&r.deprecated)&&s.push({name:e,since:r.since,deprecated:r.deprecated,inheritedBitTypes:l})}return s}getSupportedBitConfigs(){const e=[];for(const t of o.BitType.values()){if(t===o.BitType._error||t===o.BitType._comment)continue;const r=i.Config.getBitType(t),n=i.Config.getBitConfig(r);e.push(n)}return e}}},3904:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.gapChainContentProcessor=function(e,t,r,l,p,u){if(t===s.BitContentLevel.Chain)(0,a.clozeTagContentProcessor)(e,t,r,l,p);else{const t=function(e,t,r,a){var l;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("gap content",a);const p=i.Config.getTagConfigForTag(r,n.Tag.fromValue(a.type)),u=[a,...null!==(l=a.chain)&&void 0!==l?l:[]],c=e.bitContentProcessor(s.BitContentLevel.Chain,null==p?void 0:p.chain,u);e.DEBUG_CHAIN_TAGS&&e.debugPrint("gap TAGS",c);const y=Object.assign({type:o.BodyBitType.gap},c);return y}(e,0,r,l);t&&u.push(t)}};const i=r(2028),o=r(4410),n=r(9917),a=r(554),s=r(3029)},3967:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ratingLevelChainContentProcessor=function(e,t,r,n,l){var p;const{textFormat:u}=e,{key:c,value:y}=n;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("ratingLevel content",n);const g=e.bitContentProcessor(a.BitContentLevel.Chain,r,n.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("ratingLevel TAGS",g);const{label:d}=g,f={level:null!==(p=o.NumberUtils.asNumber(y))&&void 0!==p?p:0,label:d?s.toAst(d,{textFormat:u,isProperty:!0}):void 0};switch(c){case i.PropertyTag.ratingLevelStart:l.ratingLevelStart=f;break;case i.PropertyTag.ratingLevelEnd:l.ratingLevelEnd=f}};const i=r(166),o=r(8025),n=r(777),a=r(3029),s=new n.TextParser},3968:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkStringGenerator=void 0;const o=r(6772),n=r(5087);t.BitmarkStringGenerator=class{constructor(e){this.writer=new o.StringWriter,this.generator=new n.BitmarkGenerator(this.writer,e)}generate(e){return i(this,void 0,void 0,(function*(){return yield this.generator.generate(e),this.writer.getString()}))}generateSync(e){return this.generator.generateSync(e),this.writer.getString()}}},3990:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.referenceTagContentProcessor=function(e,t,r,s,l,p){const{value:u}=s,c=a.StringUtils.trimmedString(u);p?l.referenceEnd=i.Breakscape.unbreakscape(c,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}):l.reference=i.Breakscape.unbreakscape(c,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag})};const i=r(7735),o=r(385),n=r(6877),a=r(9681)},4020:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.trueFalseTagContentProcessor=function(e,t,r,l){const{type:p,value:u}=r,c=l.trueFalse;if(!c)return;const y=i.Breakscape.unbreakscape(a.StringUtils.trimmedString(u),{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});c.push({text:y,isCorrect:p===s.TypeKey.True,__isDefaultExample:!1})};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(3029)},4078:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BooleanUtils=void 0;const r=new class{isBoolean(e){return!0===e||!1===e}isBooleanString(e){return!!this.isBoolean(e)||("true"===e||"false"===e)}toBoolean(e,t){return t?!1!==e&&"false"!==e:!0===e||"true"===e}};t.BooleanUtils=r},4091:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.exampleTagContentProcessor=function(e,t,r,c){const{bitType:y}=e,{value:g}=r,d=g;o.Config.isOfBitType(y,[n.BitType.cloze,n.BitType.clozeAndMultipleChoiceText,n.BitType.multipleChoiceText,n.BitType.highlightText,n.BitType.trueFalse,n.BitType.trueFalse1,n.BitType.multipleResponse,n.BitType.multipleResponse1,n.BitType.multipleChoice,n.BitType.multipleChoice1])?function(e,t,r,c){var y,g;const{bitType:d,textFormat:f}=e;let m;Array.isArray(c.trueFalse)&&c.trueFalse.length>0&&(m=null!==(y=c.trueFalse[c.trueFalse.length-1])&&void 0!==y?y:void 0);m?!0===r?(m.__isDefaultExample=!0,m.example=!!m.isCorrect):l.BooleanUtils.isBooleanString(r)?m.example=l.BooleanUtils.toBoolean(r):(m.__isDefaultExample=!0,m.example=void 0,e.addWarning("Only 'true' / 'false' / default are allowed here, using default",t)):Array.isArray(c.__solutionsAst)&&c.__solutionsAst.length>0?c.example=!0===r?null!==(g=c.__solutionsAst[c.__solutionsAst.length-1])&&void 0!==g?g:void 0:r?p.toAst(r,{textFormat:f,isProperty:!0}):void 0:o.Config.isOfBitType(d,[n.BitType.multipleChoiceText,n.BitType.highlightText,n.BitType.trueFalse,n.BitType.trueFalse1,n.BitType.multipleResponse,n.BitType.multipleResponse1])?function(e,t,r,o){if(!0===r)o.__isDefaultExample=!0,o.example=void 0;else{const n=r?i.Breakscape.unbreakscape(r,{textFormat:a.TextFormat.bitmarkMinusMinus,textLocation:s.TextLocation.tag}):void 0;l.BooleanUtils.isBooleanString(n)?o.example=l.BooleanUtils.toBoolean(n):(o.__isDefaultExample=!0,o.example=void 0,e.addWarning("Only 'true' / 'false' / default are allowed here, using default",t))}}(e,t,r,c):o.Config.isOfBitType(d,[n.BitType.clozeAndMultipleChoiceText,n.BitType.multipleChoice,n.BitType.multipleChoice1])?(c.__isDefaultExample=!0,c.example=void 0,!0!==r&&e.addWarning("At this level, only default [@example] is allowed, using default",t)):u(e,t,r,c)}(e,r,d,c):o.Config.isOfBitType(y,n.BitType.mark)?function(e,t,r,i){i.__isDefaultExample=!0,i.example=void 0,!0!==r&&e.addWarning("Only default [@example] is allowed, using default",t)}(e,r,d,c):u(e,r,d,c)};const i=r(7735),o=r(2028),n=r(5854),a=r(385),s=r(6877),l=r(4078),p=new(r(777).TextParser);function u(e,t,r,i){const{textFormat:o}=e;!0===r||"true"===r?(i.__isDefaultExample=!0,i.example=void 0):i.example=r?p.toAst(r,{textFormat:o,isProperty:!0}):void 0}},4266:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkPegParserValidator=void 0;const i=r(2028),o=r(5512),n=r(3778),a=r(166),s=r(9917),l=r(3029),p=["----","\n==\n","\n---\n"],u=["==\n","--\n"],c=["\n==","\n--"];const y=new class{validateBitTags(e,t){if(!t)return[];const{bitConfig:r,bitType:o,resourceType:n}=e,{tags:a,cardSet:s}=r,p=i.Config.getBitResourcesConfig(o,n),u=Object.assign(Object.assign({},a),p.tags);return this.validateTagChainsRecursive(e,l.BitContentLevel.Bit,o,t,u,s).validated}checkBody(e,t,r,i,o){if(!o)return o;const{bitConfig:n}=e,{bodyAllowed:a}=n;return o.length>0&&!a&&e.addWarning(`Bit '${r}' should not have a body.`),o}checkBodyPart(e,t,r){return r?(this.checkBodyForCommonPotentialMistakes(e,t,r),r):r}checkFooter(e,t,r){if(!r)return r;const{bitConfig:i,bitType:o}=e,{footerAllowed:n}=i;return this.checkBodyForCommonPotentialMistakes(e,t,r),n||e.addWarning(`Bit '${o}' should not have a footer.`),r}checkCardBody(e,t,r,i,o,n,a){if(!i||!i.body)return i;const{bitConfig:s}=e;if(!s.cardSet)return i;const l=this.getVariantConfig(s.cardSet.variants,n,a);if(!l)return i;const{bodyAllowed:p}=l;return i.bodyString.length>0&&!p&&e.addWarning(`Bit '${r}' should not have a card body at card:${o+1}, side:${n+1}, variant:${a+1}.`),i}validateTagChainsRecursive(e,t,r,i,p,u,c){var y;if(!i)return{validated:[]};let g;const d=[...i],f=this.convertTagsToTypeKeyMap(e,t,r,p),m=(e,t,r)=>{f.set(e,{maxCount:t,minCount:r,_type:e,_tag:e,_seenCount:0})};var T,h,b;T=a.PropertyTag.internalComment,h=n.Count.infinity,b=0,f.set(`${l.TypeKey.Property}:${T}`,{maxCount:h,minCount:b,_type:o.BitTagType.property,_tag:s.Tag.tag_property,_seenCount:0}),t===l.BitContentLevel.Bit?(u&&m(l.TypeKey.CardSet,1,0),m(l.TypeKey.TextFormat,1,0),m(l.TypeKey.BodyText,n.Count.infinity,0),m(l.TypeKey.BodyTextPlain,n.Count.infinity,0),m(l.TypeKey.PlainTextDivider,n.Count.infinity,0),m(l.TypeKey.FooterDivider,n.Count.infinity,0)):t===l.BitContentLevel.Card&&m(l.TypeKey.CardText,n.Count.infinity,0);for(let i=0;i<d.length;i++){const o=d[i];if(!o)continue;const{type:n,key:a}=o,s=l.TypeKey.fromValue(n);if(!s)continue;let p=s;s!==l.TypeKey.Property&&s!==l.TypeKey.Resource||(p=`${s}:${a}`);const m=f.get(p),{validated:T,warning:h}=this.validateSingleTag(e,t,r,o,s,m,u);s===l.TypeKey.Resource&&(c=l.TypeKey.Resource);let b=!0;if(!T)if(t===l.BitContentLevel.Chain&&c!==l.TypeKey.Resource){g=o;const e=d.slice(i+1);e.length>0&&(g.chain=e),d.splice(i),b=!1}else d.splice(i,1,null);if(h&&b&&e.addWarning(null!==(y=h.warning)&&void 0!==y?y:"",h.content,h.previousContent),t===l.BitContentLevel.Chain&&m&&m.chain&&T&&!T.chain){const e=d.slice(i+1);e.length>0&&(T.chain=e),d.splice(i+1)}if(T&&Array.isArray(T.chain)&&T.chain.length>0)if(m&&m.chain){const{validated:t,remaining:o}=this.validateTagChainsRecursive(e,l.BitContentLevel.Chain,r,T.chain,m.chain,void 0,T.type);t&&t.length>0?T.chain=t:T.chain=void 0,o&&d.splice(i+1,0,o)}else if(T.type!==l.TypeKey.Resource){const e=T.chain[0];T.chain.length>1&&(e.chain=T.chain.slice(1)),d.splice(i+1,0,e),T.chain=void 0}}for(const t of f.values()){const{minCount:r,_seenCount:i}=t;if(null!=r&&i<r){const i=`${this.getTagSignature(t)} is required at least ${r} time(s)`;e.addWarning(i)}}return{validated:d.filter((e=>null!=e)),remaining:g}}validateSingleTag(e,t,r,i,o,n,a){const{type:s,key:p}=i,u=n?this.getTagSignature(n):this.getUnknownTagSignature(s,p),c=" It will be ignored";let y,g,d="";if(n)switch(n._seenCount++,o){case l.TypeKey.Property:{const{content:o,warning:a}=this.validatePropertyTag(e,t,r,n,i);y=o,g=a;break}case l.TypeKey.Resource:{const{content:o,warning:a}=this.validateResourceTag(e,t,r,n,i);y=o,g=a;break}case l.TypeKey.CardSet:{const{content:t,warning:o}=this.validateCardSet(e,r,n,i,a);y=t,g=o;break}default:{const{content:o,warning:a}=this.validateStandardTag(e,t,r,n,i);y=o,g=a}}else switch(o){case l.TypeKey.Property:g={extraProperty:!0},t!==l.BitContentLevel.Chain&&(y=i);break;case l.TypeKey.Resource:g={excessResource:!0},y=i;break;default:g={invalid:!0}}if(g){const e=null==n?void 0:n._previous;g.invalid||g.excessResource?d=`${u} is not valid here (incorrectly chained?).${c}`:null!=g.tooMany?(d=`${u} is included more than ${g.tooMany} time(s).`,g.tooMany>0&&(d+=" The earlier ones will be ignored")):g.extraProperty?d=`${u} is an unknown property. It can be excluded from the output using the 'excludeUnknownProperties' flag`:g.unexpectedCardSet?d=`${u} is not expected here.${c}`:g.unexpectedCardSideVariant&&(d=`${u} has a card / side / variant that is not expected here.${c}`),g.warning=d,g.content=y,g.previousContent=e}return n&&(n._previous=i),{validated:y,warning:g}}validateStandardTag(e,t,r,i,o){const a=null==i.maxCount?1:i.maxCount;return a!==n.Count.infinity&&i._seenCount>a?{warning:{tooMany:a},content:o}:{content:o}}validatePropertyTag(e,t,r,i,o){const a=null==i.maxCount?1:i.maxCount;return a!==n.Count.infinity&&i._seenCount>a?{warning:{tooMany:a},content:o}:{content:o}}validateResourceTag(e,t,r,i,o){const a=null==i.maxCount?1:i.maxCount;return a!==n.Count.infinity&&i._seenCount>a?{warning:{tooMany:a},content:o}:{content:o}}validateCardSet(e,t,r,i,o){if(!o||!o.variants||0===o.variants.length)return{warning:{unexpectedCardSet:!0}};const{value:n}=i,a=n;let s,p=0,u=0;for(const r of a.cards){p=0;for(const i of r.sides){u=0;for(const r of i.variants){const n=r.content;let a;const c=this.getVariantConfig(o.variants,p,u);if(c){a=this.validateTagChainsRecursive(e,l.BitContentLevel.Card,t,n,c.tags).validated}else s={unexpectedCardSideVariant:!0};a&&a.length>0?i.variants[u]={parser:r.parser,content:a}:i.variants[u]={parser:r.parser,content:[]},u++}p++}}return{content:i,warning:s}}checkBodyForCommonPotentialMistakes(e,t,r){if(!r)return;const{bitType:i}=e;for(const t of p)r.includes(t)&&e.addWarning(`Bit '${i}' might contain a mistake: ${t}`);for(const t of u)r.startsWith(t)&&e.addWarning(`Bit '${i}' might contain a mistake: ${t}`);for(const t of c)r.endsWith(t)&&e.addWarning(`Bit '${i}' might contain a mistake: ${t}`)}convertTagsToTypeKeyMap(e,t,r,i){const n=new Map;for(const e of Object.values(i)){const t={minCount:e.minCount,maxCount:e.maxCount,isTag:e.type===o.BitTagType.tag,isProperty:e.type===o.BitTagType.property,isResource:e.type===o.BitTagType.resource,chain:e.chain,_configKey:e.configKey,_type:e.type,_tag:e.tag,_seenCount:0,_previous:void 0};if(t.isProperty)n.set(`${l.TypeKey.Property}:${e.tag}`,t);else if(t.isResource)n.set(`${l.TypeKey.Resource}:${e.tag}`,t);else{const r=l.TypeKey.fromValue(e.tag);r&&n.set(r,t)}}return n}getVariantConfig(e,t,r){let i;if(0===e.length)return;const o=e[Math.min(t,e.length-1)],a=o.length-1;if(r>a){if(i=o[a],i.repeatCount!==n.Count.infinity)return}else i=o[r];return i}getTagSignature(e){switch(e._type){case o.BitTagType.tag:return`[${e._tag}]`;case o.BitTagType.property:return`[@${e._tag}]`;case o.BitTagType.resource:return`[&${e._tag}]`;default:return`'${e._type}' tag '${e._tag}'`}}getUnknownTagSignature(e,t){switch(e){case l.TypeKey.Property:return`[@${t}]`;case l.TypeKey.Resource:return`[&${t}]`;default:return t?`'${e}' tag '${t}'`:`'${e}' tag`}}};t.BitmarkPegParserValidator=y},4382:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.FooterContentProcessor=void 0;const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(777),l=r(4266),p=r(6128),u=new s.TextParser;const c=new class{process(e,t,r,s,c,y){const{textFormat:g}=e;let d;c=c.trimStart(),y=y.trimEnd();const f=!!c.trim(),m=!!y.trim();let T=0;if(f&&m&&(T=a.StringUtils.countOccurrencesAtEnd(c,"\n")+a.StringUtils.countOccurrencesAtStart(y,"\n")),c||y){const r=g===o.TextFormat.bitmarkMinusMinus||g===o.TextFormat.bitmarkPlusPlus;c&&(c=l.BitmarkPegParserValidator.checkFooter(e,t,c));const a=r?u.toAst(c,{textFormat:g,isProperty:!1}):i.Breakscape.unbreakscape(c,{textFormat:o.TextFormat.text,textLocation:n.TextLocation.body}),s=i.Breakscape.unbreakscape(y,{textFormat:o.TextFormat.text,textLocation:n.TextLocation.body});d=p.ContentProcessorUtils.concatenatePlainTextWithAstTexts(a,T,s)}return d?{footer:d}:void 0}};t.FooterContentProcessor=c},4402:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.defaultTagContentProcessor=function(e,t,r,p,u){const{type:c,value:y}=p,{textFormat:g}=e,d=new s.TextParser,f=a.StringUtils.trimmedString(y);switch(c){case l.TypeKey.Instruction:u.instruction=d.toAst(f,{textFormat:g,isProperty:!0}),u.__instructionString=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.Hint:u.hint=d.toAst(f,{textFormat:g,isProperty:!0}),u.__hintString=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.Anchor:u.anchor=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.Reference:u.reference=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.SampleSolution:u.sampleSolution=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}),u.__sampleSolutionAst=d.toAst(f,{textFormat:g,isProperty:!0}),e.addWarning("[$...] tag is deprecated, use [@sampleSolution:...] instead",p)}};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(777),l=r(3029)},4410:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BodyBitType=void 0;const i=(0,r(4718).superenum)({text:"text",gap:"gap",mark:"mark",select:"select",highlight:"highlight"});t.BodyBitType=i},4445:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ConfigHydrator=void 0;const i=r(5814),o=r(9371),n=r(9788),a=r(1519),s=r(9600),l=r(5591),p=r(7112),u=r(9888),c=r(5051),y=r(7797),g=r(5512),d=r(5554),f=r(5837),m=r(9916),T=r(168),h=r(9248);const b=new class{hydrateTagsConfig(e){var t;const r={tags:{}};for(const i of e){let e;switch(i.type){case g.BitTagType.tag:e=this.hydrateTagConfig(i);break;case g.BitTagType.property:e=this.hydratePropertyTagConfig(i);break;case g.BitTagType.resource:e=this.hydrateResourceTagConfig(i);break;case g.BitTagType.group:e=this.hydrateTagGroupConfig(i)}e&&(r.tags=Object.assign(Object.assign({},r.tags),e.tags),r.info=Object.assign(null!==(t=r.info)&&void 0!==t?t:{},e.info))}return r}hydrateCardSetConfig(e){if(!e)return;const t=d.CARDS[e];if(!t)throw new Error(`No config found for card set config key '${e}'`);const r=[];for(const e of t.variants){const t=[];for(const r of e){const e=this.hydrateCardVariantConfig(r);t.push(e)}r.push(t)}return new i.CardSetConfig(e,r)}hydrateTagConfig(e){const{configKey:t,maxCount:r,minCount:i,chain:o}=e,a=y.TagConfigKey.fromKey(t)||l.ConfigKey._unknown,s=h.TAGS[a];if(!s)throw new Error(`No config found for tag config key '${t}'`);const{tag:p,deprecated:u}=s;let c;o&&(c=this.hydrateTagsConfig(o).tags);const g=new n.MarkupTagConfig(a,p,null!=r?r:1,null!=i?i:0,c,u);return{tags:{[a]:g}}}hydratePropertyTagConfig(e){const{configKey:t,maxCount:r,minCount:i,chain:o}=e,n=u.PropertyConfigKey.fromKey(t)||l.ConfigKey._unknown,s=m.PROPERTIES[n];if(!s)throw new Error(`No config found for property config key '${t}'`);const{tag:p,deprecated:c,single:y,format:g,defaultValue:d,jsonKey:f,astKey:T}=s;let h;o&&(h=this.hydrateTagsConfig(o).tags);const b=new a.PropertyTagConfig(n,p,null!=r?r:1,null!=i?i:0,h,f,T,y,g,d,c);return{tags:{[n]:b}}}hydrateResourceTagConfig(e){const{configKey:t,maxCount:r,minCount:i,chain:o}=e,n=c.ResourceConfigKey.fromKey(t)||l.ConfigKey._unknown,a=T.RESOURCES[n];if(!a)throw new Error(`No config found for resource config key '${t}'`);const{tag:p,deprecated:u,jsonKey:y}=a;let g;o&&(g=this.hydrateTagsConfig(o).tags);const d=new s.ResourceTagConfig(n,p,null!=r?r:1,null!=i?i:0,g,y,u);return{tags:{[n]:d}}}hydrateTagGroupConfig(e){var t,r;const{configKey:i}=e,o=p.GroupConfigKey.fromKey(i)||l.ConfigKey._unknown,n=f.GROUPS[o];if(!n)throw new Error(`No config found for group config key '${i}'`);const{tags:a}=n,s=this.hydrateTagsConfig(a).tags,u=Object.values(s);if(u.length>0){const i=u[0],o=i;o.maxCount=null!==(t=e.maxCount)&&void 0!==t?t:i.maxCount,o.minCount=null!==(r=e.minCount)&&void 0!==r?r:i.minCount}return{tags:s,info:{comboResourceType:n.comboResourceType}}}hydrateCardVariantConfig(e){const{tags:t,bodyAllowed:r,bodyRequired:i,repeatCount:n}=e,a=this.hydrateTagsConfig(t);return new o.CardVariantConfig(a.tags,r,i,n)}};t.ConfigHydrator=b},4470:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BaseBuilder=void 0;const i=r(7735),o=r(2028),n=r(431),a=r(9727),s=r(6877),l=r(777),p=r(6989),u=r(4078),c=r(8025),y=r(9681);t.BaseBuilder=class{constructor(){this.textParser=new l.TextParser,this.textGenerator=new n.TextGenerator}toExample(e,t,r){if(null!=t){let e;return e=u.BooleanUtils.isBoolean(r)?u.BooleanUtils.toBoolean(t):t,{isExample:!0,example:e,__defaultExample:null!=r?r:null}}return e?{isExample:!0,example:null!=r?r:null,__defaultExample:null!=r?r:null}:{isExample:!1,example:null,__defaultExample:null!=r?r:null}}toAstProperty(e,t){if(null==t)return;const r=o.Config.getRawPropertiesConfig()[e],i=e=>{if(null!=e){switch(r.format){case a.PropertyFormat.trimmedString:return null!=c.NumberUtils.asNumber(e)&&(e=`${e}`),y.StringUtils.isString(e)?y.StringUtils.trimmedString(e):void 0;case a.PropertyFormat.number:return c.NumberUtils.asNumber(e);case a.PropertyFormat.boolean:return u.BooleanUtils.toBoolean(e,!0);case a.PropertyFormat.invertedBoolean:return!u.BooleanUtils.toBoolean(e,!0)}return e}};if(Array.isArray(t)){const e=t;for(let t=0,r=e.length;t<r;t++)e[t]=i(e[t])}else t=i(t);return p.ArrayUtils.asArray(t)}getEmptyTextAst(e){return this.handleJsonText(e,!0," ")}handleJsonText(e,t,r){let o;const{textFormat:n}=e,a=t?s.TextLocation.tag:s.TextLocation.body;if(null==r)o=[];else if(this.textParser.isAst(r))o=r;else{if(Array.isArray(r)){const e=[];for(let o=0,s=r.length;o<s;o++){const s=r[o];this.textParser.isAst(s)?e[o]=s:y.StringUtils.isString(s)?(e[o]=this.textParser.toAst(i.Breakscape.breakscape(s,{textFormat:n,textLocation:a}),{textFormat:n,isProperty:t}),e[o].__tag="text"):e[o]=[]}return e}o=y.StringUtils.isString(r)?this.textParser.toAst(i.Breakscape.breakscape(r,{textFormat:n,textLocation:a,v2:!0}),{textFormat:n,isProperty:t}):[]}return o.__tag="text",o}}},4475:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.technicalTermChainContentProcessor=function(e,t,r,l,p){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("technicalTerm content",l);const u=e.bitContentProcessor(s.BitContentLevel.Chain,r,l.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("technicalTerm TAGS",u);const{lang:c}=u,y={technicalTerm:i.Breakscape.unbreakscape(a.StringUtils.trimmedString(l.value),{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}),lang:c};p.technicalTerm=y};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(3029)},4564:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.NodeValidator=void 0;const i=r(6149),o=r(9681);const n=new class{validateBit(e){if(!e)return e;return e}validateCardBit(e){if(!e)return e;return e}validateResource(e){if(!e)return;let t=e,r=!1;switch(e.type){case i.ResourceTag.image:r=!!e.image.src;break;case i.ResourceTag.imageLink:r=!!e.imageLink.url;break;case i.ResourceTag.audio:r=!!e.audio.src;break;case i.ResourceTag.audioEmbed:r=!!e.audioEmbed.src;break;case i.ResourceTag.audioLink:r=!!e.audioLink.url;break;case i.ResourceTag.video:r=!!e.video.src;break;case i.ResourceTag.videoEmbed:r=!!e.videoEmbed.url;break;case i.ResourceTag.videoLink:r=!!e.videoLink.url;break;case i.ResourceTag.stillImageFilm:r=!!e.image.src&&!!e.audio.src;break;case i.ResourceTag.stillImageFilmEmbed:r=!!e.stillImageFilmEmbed.url;break;case i.ResourceTag.stillImageFilmLink:r=!!e.stillImageFilmLink.url;break;case i.ResourceTag.article:r=!!e.article.body;break;case i.ResourceTag.document:r=!!e.document.url;break;case i.ResourceTag.documentEmbed:r=!!e.documentEmbed.url;break;case i.ResourceTag.documentLink:r=!!e.documentLink.url;break;case i.ResourceTag.documentDownload:r=!!e.documentDownload.url;break;case i.ResourceTag.appLink:r=!!e.appLink.url;break;case i.ResourceTag.websiteLink:r=!!e.websiteLink.url;break;default:r=!1}return r||e.type&&(t={type:e.type}),t}isRequired(e,t){if(!e)throw new Error(`${t} is required but is not set`)}isOneOfRequired(e,t){if(Array.isArray(e))for(const t of e)if(t)return;throw new Error(`One of '${t.join(", ")}' is required but none is set`)}isString(e,t){if(!o.StringUtils.isString(e))throw new Error(`${t} is required to be a string`)}isNonEmptyString(e,t){if(!o.StringUtils.isString(e)||""===e)throw new Error(`${t} is required to be a non-empty string`)}isStringOrBoolean(e,t){if(!o.StringUtils.isString(e)&&!0!==e&&!1!==e)throw new Error(`${t} is required to be a string or a boolean`)}isNonEmptyStringOrBoolean(e,t){if((!o.StringUtils.isString(e)||""===e)&&!0!==e&&!1!==e)throw new Error(`${t} is required to be a non-empty string or a boolean`)}isArray(e,t){if(!Array.isArray(e))throw new Error(`${t} is required to be a array`)}isNonEmptyArray(e,t){if(!(Array.isArray(e)&&e.length>0))throw new Error(`${t} is required to be a non-empty array`)}isNumber(e,t){if(!Number.isFinite(e))throw new Error(`${t} is required to be a number`)}isBoolean(e,t){if(!0!==e&&!1!==e)throw new Error(`${t} is required to be a boolean`)}isStringOrNumberOrBooleanOrNullOrUndefined(e,t){if(!o.StringUtils.isString(e)&&!Number.isFinite(e)&&!0!==e&&!1!==e&&null!=e)throw new Error(`${t} is required to be a string or a number or a boolean or null or undefined`)}};t.NodeValidator=n},4718:(e,t,r)=>{function i(e,t){var r;const i=Object.freeze,o=Object.defineProperty,n=Object.assign,a={enumerable:!1},s=new Map,l=new Map,p=new Map,u=new Map,c=new Map,y=(null!==(r=null==t?void 0:t.iterationKeys)&&void 0!==r?r:Object.keys(e)).map((e=>`${e}`));for(const[t,r]of Object.entries(e))s.set(t,r),p.set(t.toLowerCase(),r);for(const[e,t]of s){const r="string"==typeof t?t.toLowerCase():t;l.set(t,e),u.set(r,e)}const g=y.map((e=>s.get(e))),d=y.map((e=>[e,s.get(e)]));return(t=>{let r=e;function f(e,t){return(null==t?void 0:t.ignoreCase)&&"string"==typeof e?s.get(u.get(e.toLowerCase())):l.has(e)?e:void 0}Object.isExtensible(e)||(r=n({},e)),o(r,"fromKey",n({value:function(e,t){return(null==t?void 0:t.ignoreCase)&&"string"==typeof e?p.get(e.toLowerCase()):s.get(`${e}`)}},a)),o(r,"fromValue",n({value:f},a)),o(r,"keyFromValue",n({value:function(e,t){return(null==t?void 0:t.ignoreCase)&&"string"==typeof e?u.get(e.toLowerCase()):l.get(e)}},a)),o(r,"setMetadata",n({value:function(e,t,r){const i=f(e);null!=i&&c.set(i,t)}},a)),o(r,"getMetadata",n({value:function(e,t){return c.get(e)}},a)),o(r,Symbol.iterator,n({value:function(){let e=0;return{next:()=>e<y.length?{value:s.get(`${y[e++]}`),done:!1}:{done:!0}}}},a)),o(r,"values",n({value:()=>g},a)),o(r,"keys",n({value:()=>y},a)),o(r,"entries",n({value:()=>d},a));let m=r;return(null==t?void 0:t.noFreeze)||(m=i(r),i(y),i(g),i(d)),m})(t)}r.r(t),r.d(t,{superenum:()=>o});const o=i;o.fromObject=i,o.fromArray=function(e,t){Array.isArray(e)||(e=[]);const r=e.reduce(((e,t)=>(e[`${t}`]=t,e)),{});return(!t||t&&!t.iterationKeys)&&((t=Object.assign({},t)).iterationKeys=e),i(r,t)}},4953:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.servingsChainContentProcessor=function(e,t,r,n,a){var s;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("servings content",n);const l=e.bitContentProcessor(o.BitContentLevel.Chain,r,n.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("servings TAGS",l);const{unit:p,unitAbbr:u,decimalPlaces:c,disableCalculation:y,__hintString:g}=l,d={servings:null!==(s=i.NumberUtils.asNumber(n.value))&&void 0!==s?s:1,unit:p,unitAbbr:u,decimalPlaces:null!=c?c:1,disableCalculation:y,hint:g};a.servings=d};const i=r(8025),o=r(3029)},5005:(e,t,r)=>{const{VOID:i,PRIMITIVE:o,ARRAY:n,OBJECT:a,DATE:s,REGEXP:l,MAP:p,SET:u,ERROR:c,BIGINT:y}=r(1731),g="object"==typeof self?self:globalThis;t.deserialize=e=>((e,t)=>{const r=(t,r)=>(e.set(r,t),t),d=f=>{if(e.has(f))return e.get(f);const[m,T]=t[f];switch(m){case o:case i:return r(T,f);case n:{const e=r([],f);for(const t of T)e.push(d(t));return e}case a:{const e=r({},f);for(const[t,r]of T)e[d(t)]=d(r);return e}case s:return r(new Date(T),f);case l:{const{source:e,flags:t}=T;return r(new RegExp(e,t),f)}case p:{const e=r(new Map,f);for(const[t,r]of T)e.set(d(t),d(r));return e}case u:{const e=r(new Set,f);for(const t of T)e.add(d(t));return e}case c:{const{name:e,message:t}=T;return r(new g[e](t),f)}case y:return r(BigInt(T),f);case"BigInt":return r(Object(BigInt(T)),f);case"ArrayBuffer":return r(new Uint8Array(T).buffer,T);case"DataView":{const{buffer:e}=new Uint8Array(T);return r(new DataView(e),T)}}return r(new g[m](T),f)};return d})(new Map,e)(0)},5033:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BodyContentProcessor=void 0;const i=r(7735),o=r(4410),n=r(385),a=r(6877),s=r(9681),l=r(777),p=r(4266),u=r(6128),c=new l.TextParser;const y=new class{process(e,t,r,l,y,g,d,f){const m=[];let T,h;const b=d.length>0?this.trimBodyParts(d):void 0,B=f?b:p.BitmarkPegParserValidator.checkBody(e,t,r,l,b);if(l===n.TextFormat.json&&B){T=B.reduce(((e,t)=>{var r;if(t.type===o.BodyBitType.text&&t.data){return e+(null!==(r=t.data.bodyText)&&void 0!==r?r:"")}return e}),"");try{T=JSON.parse(T)}catch(t){T=null,e.addError("Body JSON is invalid.")}}else{let e="",t="",r="",p=0;const y=e=>`[!${e}]`;if(B)for(let n=0;n<B.length;n++){const a=B[n];if(a.type===o.BodyBitType.text){const o=a,n=o.data.bodyText;o.data.isPlain?t=i.Breakscape.concatenate(t,n):e=i.Breakscape.concatenate(e,n),r=i.Breakscape.concatenate(r,n)}else{const t=y(p);e=i.Breakscape.concatenate(e,t),m.push(a),p++}}const g=l===n.TextFormat.bitmarkMinusMinus||l===n.TextFormat.bitmarkPlusPlus?c.toAst(e,{textFormat:l,isProperty:!1}):i.Breakscape.unbreakscape(e,{textFormat:n.TextFormat.text,textLocation:a.TextLocation.body}),d=i.Breakscape.unbreakscape(t,{textFormat:n.TextFormat.text,textLocation:a.TextLocation.body}),f=s.StringUtils.countOccurrencesAtEnd(e,"\n")+s.StringUtils.countOccurrencesAtStart(t,"\n");T=u.ContentProcessorUtils.concatenatePlainTextWithAstTexts(g,f,d),h=i.Breakscape.unbreakscape(r,{textFormat:l,textLocation:a.TextLocation.body}).trim();const b=Array.isArray(T)?T:void 0;if(b&&B){p=0;for(let e=0;e<B.length;e++){const t=B[e];if(t.type===o.BodyBitType.text)continue;const r=t;let i;switch(t.type){case o.BodyBitType.gap:case o.BodyBitType.mark:case o.BodyBitType.select:case o.BodyBitType.highlight:i=r}i&&this.replacePlaceholderWithBodyBit(b,i,p),p++}}}return{body:T,bodyBits:m.length>0?m:void 0,bodyString:h}}buildBodyText(e,t){return{type:o.BodyBitType.text,data:{bodyText:e,isPlain:t}}}replacePlaceholderWithBodyBit(e,t,r){const i=(e,o,n)=>{if(Array.isArray(e))for(let t=0;t<e.length;t++){const r=e[t];if(i(r,e,t))return!0}else{if("bit"===e.type&&e.index===r)return o[n]=t,!0;if(e.content){if(i(e.content,e,"content"))return!0}}return!1};i(e,null,null)}trimBodyParts(e){let t=!1,r=e.reduce(((e,r)=>{const i=r;if(t||i.type!==o.BodyBitType.text)t=!0,e.push(r);else{const r=i.data.bodyText.trimStart();r&&(t=!0,i.data.bodyText=r,e.push(i))}return e}),[]);return t=!1,r=r.reduceRight(((e,r)=>{const i=r;if(t||i.type!==o.BodyBitType.text)t=!0,e.unshift(r);else{const r=i.data.bodyText.trimEnd();r&&(t=!0,i.data.bodyText=r,e.unshift(i))}return e}),[]),r}};t.BodyContentProcessor=y},5051:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.resourceConfigKeys=t.ResourceConfigKey=void 0;const i=r(4718),o={icon:"icon",image:"image",imagePortrait:"imagePortrait",imageLandscape:"imageLandscape",imageEmbed:"imageEmbed",imageLink:"imageLink",audio:"audio",audioEmbed:"audioEmbed",audioLink:"audioLink",video:"video",videoEmbed:"videoEmbed",videoLink:"videoLink",stillImageFilmEmbed:"stillImageFilmEmbed",stillImageFilmLink:"stillImageFilmLink",article:"article",articleEmbed:"articleEmbed",articleLink:"articleLink",document:"document",documentEmbed:"documentEmbed",documentLink:"documentLink",documentDownload:"documentDownload",appLink:"appLink",websiteLink:"websiteLink"};t.resourceConfigKeys=o;const n=(0,i.superenum)(o);t.ResourceConfigKey=n},5057:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.StartRules=void 0,t.SyntaxError=a,t.parse=function e(t,r){r=void 0!==r?r:{};var s,l={},p=r.grammarSource,u={bitmark:nr,bit:function(){var e,t,r,i,o;e=Jt,t=[],r=Ar();for(;r!==l;)t.push(r),r=Ar();if((r=lr())!==l){for(i=[],o=Ar();o!==l;)i.push(o),o=Ar();Wt=e,e=Xe(r)}else Jt=e,e=l;return e},cardContent:function(){var e,t,r;e=Jt,t=[],(r=yr())===l&&(r=Cr());for(;r!==l;)t.push(r),(r=yr())===l&&(r=Cr());return Wt=e,t=Pt(t),e=t}},c=nr,y="[.",g="]",d="[",f=":",m="&",T="$$$$",h="====",b="text",B="~~~~",v="footer",C="--",P="++",x="===",k="==",K="[@id",w="#",_="[▼",S="[►",A="[@",L="[%",I="[!",F="[?",N="[+",O="[-",E="[$",R="[_",V="[=",j="[&",M="^]",D="id:",G=".",U="\n",$="\r\n",J=/^[^\]]/,W=/^[^:\]]/,z=/^[^&:\]]/,q=/^[ \t]/,H=/^[^\n\r\u2028\u2029]/,Y=/^[\r\u2028-\u2029]/,X=/^[ \t\n\r\u2028\u2029]/,Q=Qt("[.",!1),Z=Zt(["]"],!0,!1),ee=Qt("]",!1),te=Qt("[",!1),re=Qt(":",!1),ie=Qt("&",!1),oe={type:"any"},ne=Qt("$$$$",!1),ae=Qt("====",!1),se=Qt("text",!1),le=Qt("~~~~",!1),pe=Qt("footer",!1),ue=Qt("--",!1),ce=Qt("++",!1),ye=Qt("===",!1),ge=Qt("==",!1),de=Qt("[@id",!1),fe=Qt("#",!1),me=Qt("[▼",!1),Te=Qt("[►",!1),he=Qt("[@",!1),be=Qt("[%",!1),Be=Qt("[!",!1),ve=Qt("[?",!1),Ce=Qt("[+",!1),Pe=Qt("[-",!1),xe=Qt("[$",!1),ke=Qt("[_",!1),Ke=Qt("[=",!1),we=Qt("[&",!1),_e=Qt("^]",!1),Se=Qt("id:",!1),Ae=Zt([":","]"],!0,!1),Le=Qt(".",!1),Ie=Zt(["&",":","]"],!0,!1),Fe=(er("Empty"),Zt([" ","\t"],!1,!1)),Ne=er("Anything"),Oe=er("Character"),Ee=Zt(["\n","\r","\u2028","\u2029"],!0,!1),Re=er("Line"),Ve=(er("whitespace in line"),er("Blank Line")),je=er("Line Terminator"),Me=Qt("\n",!1),De=Qt("\r\n",!1),Ge=Zt(["\r",["\u2028","\u2029"]],!1,!1),Ue=er("Whitespace, then Line Terminator"),$e=er("whitespace"),Je=Zt([" ","\t","\n","\r","\u2028","\u2029"],!1,!1),We=function(e,t){return Vr.buildBits([e,...t])},ze=function(e){return Rr.handleRawBit(e)},qe=function(e){return e},He=function(e){return Rr.handleRawBit(e)},Ye=function(e){return e},Xe=function(e){return e},Qe=function(e,t){return Vr.buildBit(e,t)},Ze=function(e){return Vr.invalidBit(e)},et=function(e,t,r){return Vr.buildBitHeader(t,e,r)},tt=function(e,t){return Vr.buildTextAndResourceType(e,t)},rt=function(e){return Rr.handleTextFormat(e)},it=function(e){return Rr.handleResourceType(e)},ot=function(e){return Rr.handleBitContent(e)},nt=function(e){return Rr.handleTagChain(e)},at=function(e){return e},st=function(e){return Rr.handleBitTag(e)},lt=function(e){return{type:i.TypeKey.BodyChar,value:e}},pt=function(e){return Rr.handlePlainTextDivider(e)},ut=function(e){return Rr.handleFooterDivider(e)},ct=function(e){return Rr.handleCardSet(e[1].flat())},yt=function(){Rr.handleCardSetStart()},gt=function(){Rr.handleCardSetEnd()},dt=function(e){return Rr.handleCards(e)},ft=function(e){return Rr.handleCardLineOrDivider(e,2)},mt=function(e){return Rr.handleCardLine(e)},Tt=function(e){return Rr.handleCardSet(e[1].flat())},ht=function(){Rr.handleCardSetStart()},bt=function(){Rr.handleCardSetEnd()},Bt=function(e){return Rr.handleCards(e)},vt=function(e){return Rr.handleCardLineOrDivider(e,1)},Ct=function(e){return Rr.handleCardLine(e)},Pt=function(e){return Rr.handleCardContent(e)},xt=function(e){return{type:i.TypeKey.CardChar,value:e}},kt=function(e){return Rr.handlePropertyTag("id",e)},Kt=function(e,t){return Rr.handleTag(i.TypeKey.Title,{level:e,title:t})},wt=function(e){return Rr.handleTag(i.TypeKey.Anchor,e)},_t=function(e){return Rr.handleTag(i.TypeKey.Reference,e)},St=function(e,t){return Rr.handlePropertyTag(e,t)},At=function(e){return Rr.handleTag(i.TypeKey.ItemLead,e)},Lt=function(e){return Rr.handleTag(i.TypeKey.Instruction,e)},It=function(e){return Rr.handleTag(i.TypeKey.Hint,e)},Ft=function(e){return Rr.handleTag(i.TypeKey.True,e)},Nt=function(e){return Rr.handleTag(i.TypeKey.False,e)},Ot=function(e){return Rr.handleTag(i.TypeKey.SampleSolution,e)},Et=function(e){return Rr.handleTag(i.TypeKey.Gap,e)},Rt=function(e){return Rr.handleTag(i.TypeKey.Mark,e)},Vt=function(e,t){return Rr.handleResourceTag(e,t)},jt=function(e){return e},Mt=function(e){return e?e.trim():""},Dt=function(e){return e.length},Gt=function(e){return e?e.trim():null},Ut=function(e){return e?e.trim():""},$t=function(){return!0},Jt=0|r.peg$currPos,Wt=Jt,zt=[{line:1,column:1}],qt=Jt,Ht=r.peg$maxFailExpected||[],Yt=0|r.peg$silentFails;if(r.startRule){if(!(r.startRule in u))throw new Error("Can't start parsing from rule \""+r.startRule+'".');c=u[r.startRule]}function Xt(){return t.substring(Wt,Jt)}function Qt(e,t){return{type:"literal",text:e,ignoreCase:t}}function Zt(e,t,r){return{type:"class",parts:e,inverted:t,ignoreCase:r}}function er(e){return{type:"other",description:e}}function tr(e){var r,i=zt[e];if(i)return i;if(e>=zt.length)r=zt.length-1;else for(r=e;!zt[--r];);for(i={line:(i=zt[r]).line,column:i.column};r<e;)10===t.charCodeAt(r)?(i.line++,i.column=1):i.column++,r++;return zt[e]=i,i}function rr(e,t,r){var i=tr(e),o=tr(t),n={source:p,start:{offset:e,line:i.line,column:i.column},end:{offset:t,line:o.line,column:o.column}};return r&&p&&"function"==typeof p.offset&&(n.start=p.offset(n.start),n.end=p.offset(n.end)),n}function ir(e){Jt<qt||(Jt>qt&&(qt=Jt,Ht=[]),Ht.push(e))}function or(e,t,r){return new a(a.buildMessage(e,t),e,t,r)}function nr(){return function(){var e,r,i,o;e=Jt,r=[],i=Fr();for(;i!==l;)r.push(i),i=Fr();return i=function(){var e,r,i,o;e=Jt,r=Jt,i=[],o=sr();for(;o!==l;)i.push(o),o=sr();return r=t.substring(r,Jt),Wt=e,r=ze(r),e=r,e}(),o=function(){var e,t;e=[],t=ar();for(;t!==l;)e.push(t),t=ar();return e}(),Wt=e,e=We(i,o),e}()}function ar(){var e,r,i,o;for(e=Jt,r=[],i=Ar();i!==l;)r.push(i),i=Ar();return(i=Lr())===l&&(i=null),o=function(){var e,r,i,o,n,a;if(e=Jt,r=Jt,i=Jt,o=function(){var e,r,i,o;e=Jt,t.substr(Jt,2)===y?(r=y,Jt+=2):(r=l,0===Yt&&ir(Q));if(r!==l){for(i=[],o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z));o!==l;)i.push(o),o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z));93===t.charCodeAt(Jt)?(o=g,Jt++):(o=l,0===Yt&&ir(ee)),o!==l?(Wt=e,e=Ye(r)):(Jt=e,e=l)}else Jt=e,e=l;return e}(),o!==l){for(n=[],a=sr();a!==l;)n.push(a),a=sr();i=o=[o,n]}else Jt=i,i=l;r=i!==l?t.substring(r,Jt):i;r!==l&&(Wt=e,r=He(r));return e=r,e}(),o!==l?(Wt=e,e=qe(o)):(Jt=e,e=l),e}function sr(){var e,t,r,i;if(e=Jt,(t=Lr())!==l?(r=Jt,Yt++,i=pr(),Yt--,i===l?r=void 0:(Jt=r,r=l),r!==l?e=t=[t,r]:(Jt=e,e=l)):(Jt=e,e=l),e===l)if(e=[],(t=_r())!==l)for(;t!==l;)e.push(t),t=_r();else e=l;return e}function lr(){var e,r,i;return e=Jt,(r=pr())!==l?(i=function(){var e,t,r;e=Jt,t=[],r=mr(),r===l&&(r=hr())===l&&(r=Br())===l&&(r=yr())===l&&(r=fr());for(;r!==l;)t.push(r),(r=mr())===l&&(r=hr())===l&&(r=Br())===l&&(r=yr())===l&&(r=fr());return Wt=e,t=ot(t),e=t,e}(),Wt=e,e=Qe(r,i)):(Jt=e,e=l),e===l&&(e=Jt,r=Jt,i=function(){var e,r;Yt++,e=[],t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe));for(;r!==l;)e.push(r),t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe));Yt--,r=l,0===Yt&&ir(Ne);return e}(),r=t.substring(r,Jt),Wt=e,e=r=Ze(r)),e}function pr(){var e,r,i,o,n,a;return e=Jt,91===t.charCodeAt(Jt)?(r=d,Jt++):(r=l,0===Yt&&ir(te)),r!==l?(i=function(){var e,r,i;e=Jt,r=[],46===t.charCodeAt(Jt)?(i=G,Jt++):(i=l,0===Yt&&ir(Le));if(i!==l)for(;i!==l;)r.push(i),46===t.charCodeAt(Jt)?(i=G,Jt++):(i=l,0===Yt&&ir(Le));else r=l;r!==l&&(Wt=e,r=Dt(r));return e=r,e}(),i!==l?(o=Kr(),n=function(){var e,t,r;e=Jt,t=ur(),t===l&&(t=cr());t===l&&(t=null);r=ur(),r===l&&(r=cr());r===l&&(r=null);return Wt=e,e=tt(t,r),e}(),93===t.charCodeAt(Jt)?(a=g,Jt++):(a=l,0===Yt&&ir(ee)),a!==l?(Wt=e,e=et(i,o,n)):(Jt=e,e=l)):(Jt=e,e=l)):(Jt=e,e=l),e}function ur(){var e,r,i;return e=Jt,58===t.charCodeAt(Jt)?(r=f,Jt++):(r=l,0===Yt&&ir(re)),r!==l?(i=Kr(),Wt=e,e=rt(i)):(Jt=e,e=l),e}function cr(){var e,r,i;return e=Jt,38===t.charCodeAt(Jt)?(r=m,Jt++):(r=l,0===Yt&&ir(ie)),r!==l?(i=Kr(),Wt=e,e=it(i)):(Jt=e,e=l),e}function yr(){var e,t,r,i,o;if(e=Jt,t=Jt,(r=dr())!==l){for(i=[],o=gr();o!==l;)i.push(o),o=gr();t=r=[r,i]}else Jt=t,t=l;return t!==l&&(Wt=e,t=nt(t)),e=t}function gr(){var e,t;return e=Jt,(t=dr())!==l&&(Wt=e,t=at(t)),e=t}function dr(){var e,r;return e=Jt,r=function(){var e,r,i,o;e=Jt,t.substr(Jt,4)===K?(r=K,Jt+=4):(r=l,0===Yt&&ir(de));r!==l&&(i=wr())!==l?(o=function(){var e;93===t.charCodeAt(Jt)?(e=g,Jt++):(e=l,0===Yt&&ir(ee));return e}(),o!==l?(Wt=e,e=kt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i,o;e=Jt,t.substr(Jt,2)===A?(r=A,Jt+=2):(r=l,0===Yt&&ir(he));r!==l&&(i=xr())!==l&&(o=wr())!==l&&kr()!==l?(Wt=e,e=St(i,o)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i,o;e=Jt,91===t.charCodeAt(Jt)?(r=d,Jt++):(r=l,0===Yt&&ir(te));if(r!==l){if(i=[],35===t.charCodeAt(Jt)?(o=w,Jt++):(o=l,0===Yt&&ir(fe)),o!==l)for(;o!==l;)i.push(o),35===t.charCodeAt(Jt)?(o=w,Jt++):(o=l,0===Yt&&ir(fe));else i=l;i!==l?(o=Pr(),kr()!==l?(Wt=e,e=Kt(i,o)):(Jt=e,e=l)):(Jt=e,e=l)}else Jt=e,e=l;return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===_?(r=_,Jt+=2):(r=l,0===Yt&&ir(me));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=wt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===S?(r=S,Jt+=2):(r=l,0===Yt&&ir(Te));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=_t(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===L?(r=L,Jt+=2):(r=l,0===Yt&&ir(be));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=At(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===I?(r=I,Jt+=2):(r=l,0===Yt&&ir(Be));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Lt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===F?(r=F,Jt+=2):(r=l,0===Yt&&ir(ve));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=It(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===R?(r=R,Jt+=2):(r=l,0===Yt&&ir(ke));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Et(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===V?(r=V,Jt+=2):(r=l,0===Yt&&ir(Ke));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Rt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===E?(r=E,Jt+=2):(r=l,0===Yt&&ir(xe));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Ot(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===N?(r=N,Jt+=2):(r=l,0===Yt&&ir(Ce));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Ft(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===O?(r=O,Jt+=2):(r=l,0===Yt&&ir(Pe));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Nt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i,o;e=Jt,t.substr(Jt,2)===j?(r=j,Jt+=2):(r=l,0===Yt&&ir(we));r!==l&&(i=xr())!==l&&(o=wr())!==l&&kr()!==l?(Wt=e,e=Vt(i,o)):(Jt=e,e=l);return e}()))))))))))))),r!==l&&(Wt=e,r=st(r)),e=r}function fr(){var e,r;return e=Jt,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),r!==l&&(Wt=e,r=lt(r)),e=r}function mr(){var e;return(e=function(){var e,t,r,i,o;e=Jt,t=Jt,(r=Lr())!==l&&(i=Tr())!==l&&(o=Ir())!==l?t=r=[r,i,o]:(Jt=t,t=l);t!==l&&(Wt=e,t=ut(t));return e=t,e}())===l&&(e=function(){var e,r,i,o,n;e=Jt,r=Jt,(i=Lr())!==l?(o=function(){var e,r,i,o,n,a;t.substr(Jt,4)===T?(e=T,Jt+=4):(e=l,0===Yt&&ir(ne));if(e===l)if(e=Jt,t.substr(Jt,4)===h?(r=h,Jt+=4):(r=l,0===Yt&&ir(ae)),r!==l){if(i=[],(o=Fr())!==l)for(;o!==l;)i.push(o),o=Fr();else i=l;if(i!==l)if(t.substr(Jt,4)===b?(o=b,Jt+=4):(o=l,0===Yt&&ir(se)),o!==l){if(n=[],(a=Fr())!==l)for(;a!==l;)n.push(a),a=Fr();else n=l;n!==l?(t.substr(Jt,4)===h?(a=h,Jt+=4):(a=l,0===Yt&&ir(ae)),a!==l?e=r=[r,i,o,n,a]:(Jt=e,e=l)):(Jt=e,e=l)}else Jt=e,e=l;else Jt=e,e=l}else Jt=e,e=l;return e}(),o!==l&&(n=Ir())!==l?r=i=[i,o,n]:(Jt=r,r=l)):(Jt=r,r=l);r!==l&&(Wt=e,r=pt(r));return e=r,e}()),e}function Tr(){var e,r,i,o,n,a;if(t.substr(Jt,4)===B?(e=B,Jt+=4):(e=l,0===Yt&&ir(le)),e===l)if(e=Jt,t.substr(Jt,4)===h?(r=h,Jt+=4):(r=l,0===Yt&&ir(ae)),r!==l){if(i=[],(o=Fr())!==l)for(;o!==l;)i.push(o),o=Fr();else i=l;if(i!==l)if(t.substr(Jt,6)===v?(o=v,Jt+=6):(o=l,0===Yt&&ir(pe)),o!==l){if(n=[],(a=Fr())!==l)for(;a!==l;)n.push(a),a=Fr();else n=l;n!==l?(t.substr(Jt,4)===h?(a=h,Jt+=4):(a=l,0===Yt&&ir(ae)),a!==l?e=r=[r,i,o,n,a]:(Jt=e,e=l)):(Jt=e,e=l)}else Jt=e,e=l;else Jt=e,e=l}else Jt=e,e=l;return e}function hr(){var e,r,i,o,n;if(e=Jt,r=Jt,i=function(){var e,r,i,o,n,a;e=Jt,r=Lr(),r!==l?(i=Jt,Yt++,o=Jt,t.substr(Jt,4)===h?(n=h,Jt+=4):(n=l,0===Yt&&ir(ae)),n!==l&&(a=Ir())!==l?o=n=[n,a]:(Jt=o,o=l),Yt--,o!==l?(Jt=i,i=void 0):i=l,i!==l?(Wt=e,e=yt()):(Jt=e,e=l)):(Jt=e,e=l);return e}(),i!==l){for(o=[],n=br();n!==l;)o.push(n),n=br();n=function(){var e,t,r,i,o;e=Jt,t=Jt,r=Tr(),r===l&&(r=null);i=Jt,Yt++,o=Or(),Yt--,o!==l?(Jt=i,i=void 0):i=l;i!==l?t=r=[r,i]:(Jt=t,t=l);t!==l&&(Wt=e,t=gt());return e=t,e}(),n!==l?r=i=[i,o,n]:(Jt=r,r=l)}else Jt=r,r=l;return r!==l&&(Wt=e,r=ct(r)),e=r}function br(){var e,r;return e=Jt,r=function(){var e,r,i,o;e=Jt,r=Jt,t.substr(Jt,4)===h?(i=h,Jt+=4):(i=l,0===Yt&&ir(ae));i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l);r===l&&(r=Jt,t.substr(Jt,2)===C?(i=C,Jt+=2):(i=l,0===Yt&&ir(ue)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=Jt,t.substr(Jt,2)===P?(i=P,Jt+=2):(i=l,0===Yt&&ir(ce)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=function(){var e,r,i,o,n,a;e=Jt,r=Jt,Yt++,i=Jt,o=Tr(),o!==l&&(n=Or())!==l?i=o=[o,n]:(Jt=i,i=l);Yt--,i===l?r=void 0:(Jt=r,r=l);if(r!==l){if(i=Jt,o=Jt,n=Sr(),(a=Lr())!==l?o=n=[n,a]:(Jt=o,o=l),o===l){if(o=Jt,n=[],(a=_r())!==l)for(;a!==l;)n.push(a),a=_r();else n=l;n!==l&&(a=Nr())!==l?o=n=[n,a]:(Jt=o,o=l)}(i=o!==l?t.substring(i,Jt):o)!==l?(Wt=e,e=mt(i)):(Jt=e,e=l)}else Jt=e,e=l;return e}())));r!==l&&(Wt=e,r=ft(r));return e=r,e}(),r!==l&&(Wt=e,r=dt(r)),e=r}function Br(){var e,r,i,o,n;if(e=Jt,r=Jt,i=function(){var e,r,i,o,n,a;e=Jt,r=Lr(),r!==l?(i=Jt,Yt++,o=Jt,t.substr(Jt,3)===x?(n=x,Jt+=3):(n=l,0===Yt&&ir(ye)),n!==l&&(a=Ir())!==l?o=n=[n,a]:(Jt=o,o=l),Yt--,o!==l?(Jt=i,i=void 0):i=l,i!==l?(Wt=e,e=ht()):(Jt=e,e=l)):(Jt=e,e=l);return e}(),i!==l){for(o=[],n=vr();n!==l;)o.push(n),n=vr();n=function(){var e,t,r,i,o;e=Jt,t=Jt,r=Tr(),r===l&&(r=null);i=Jt,Yt++,o=Or(),Yt--,o!==l?(Jt=i,i=void 0):i=l;i!==l?t=r=[r,i]:(Jt=t,t=l);t!==l&&(Wt=e,t=bt());return e=t,e}(),n!==l?r=i=[i,o,n]:(Jt=r,r=l)}else Jt=r,r=l;return r!==l&&(Wt=e,r=Tt(r)),e=r}function vr(){var e,r;return e=Jt,r=function(){var e,r,i,o;e=Jt,r=Jt,t.substr(Jt,3)===x?(i=x,Jt+=3):(i=l,0===Yt&&ir(ye));i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l);r===l&&(r=Jt,t.substr(Jt,2)===k?(i=k,Jt+=2):(i=l,0===Yt&&ir(ge)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=Jt,t.substr(Jt,2)===C?(i=C,Jt+=2):(i=l,0===Yt&&ir(ue)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=function(){var e,r,i,o,n,a;e=Jt,r=Jt,Yt++,i=Jt,o=Tr(),o!==l&&(n=Or())!==l?i=o=[o,n]:(Jt=i,i=l);Yt--,i===l?r=void 0:(Jt=r,r=l);if(r!==l){if(i=Jt,o=Jt,n=Sr(),(a=Lr())!==l?o=n=[n,a]:(Jt=o,o=l),o===l){if(o=Jt,n=[],(a=_r())!==l)for(;a!==l;)n.push(a),a=_r();else n=l;n!==l&&(a=Nr())!==l?o=n=[n,a]:(Jt=o,o=l)}(i=o!==l?t.substring(i,Jt):o)!==l?(Wt=e,e=Ct(i)):(Jt=e,e=l)}else Jt=e,e=l;return e}())));r!==l&&(Wt=e,r=vt(r));return e=r,e}(),r!==l&&(Wt=e,r=Bt(r)),e=r}function Cr(){var e,r;return e=Jt,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),r!==l&&(Wt=e,r=xt(r)),e=r}function Pr(){var e,r,i,o;for(e=Jt,r=Jt,i=[],t.substr(Jt,2)===M?(o=M,Jt+=2):(o=l,0===Yt&&ir(_e)),o===l&&(o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z)));o!==l;)i.push(o),t.substr(Jt,2)===M?(o=M,Jt+=2):(o=l,0===Yt&&ir(_e)),o===l&&(o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z)));return r=t.substring(r,Jt),Wt=e,e=r=jt(r)}function xr(){var e,r,i,o,n;if(e=Jt,r=Jt,Yt++,t.substr(Jt,3)===D?(i=D,Jt+=3):(i=l,0===Yt&&ir(Se)),Yt--,i===l?r=void 0:(Jt=r,r=l),r!==l){for(i=Jt,o=[],n=t.charAt(Jt),W.test(n)?Jt++:(n=l,0===Yt&&ir(Ae));n!==l;)o.push(n),n=t.charAt(Jt),W.test(n)?Jt++:(n=l,0===Yt&&ir(Ae));i=t.substring(i,Jt),Wt=e,e=Mt(i)}else Jt=e,e=l;return e}function kr(){var e,r,i;if(93===t.charCodeAt(Jt)?(e=g,Jt++):(e=l,0===Yt&&ir(ee)),e===l){for(e=Jt,r=[],i=Fr();i!==l;)r.push(i),i=Fr();(i=Er())!==l?e=r=[r,i]:(Jt=e,e=l)}return e}function Kr(){var e,r,i,o;for(e=Jt,r=Jt,i=[],o=t.charAt(Jt),z.test(o)?Jt++:(o=l,0===Yt&&ir(Ie));o!==l;)i.push(o),o=t.charAt(Jt),z.test(o)?Jt++:(o=l,0===Yt&&ir(Ie));return r=t.substring(r,Jt),Wt=e,e=r=Gt(r)}function wr(){var e,r,i;return e=Jt,58===t.charCodeAt(Jt)?(r=f,Jt++):(r=l,0===Yt&&ir(re)),r!==l?(i=Pr(),Wt=e,e=Ut(i)):(Jt=e,e=l),e===l&&(r="",Wt=e=Jt,e=r=$t()),e}function _r(){var e;return Yt++,e=t.charAt(Jt),H.test(e)?Jt++:(e=l,0===Yt&&ir(Ee)),Yt--,e===l&&(0===Yt&&ir(Oe)),e}function Sr(){var e,t;for(Yt++,e=[],t=_r();t!==l;)e.push(t),t=_r();return Yt--,t=l,0===Yt&&ir(Re),e}function Ar(){var e,r,i;for(Yt++,e=Jt,r=[],i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));i!==l;)r.push(i),i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));return(i=Lr())!==l?e=r=[r,i]:(Jt=e,e=l),Yt--,e===l&&(r=l,0===Yt&&ir(Ve)),e}function Lr(){var e;return Yt++,10===t.charCodeAt(Jt)?(e=U,Jt++):(e=l,0===Yt&&ir(Me)),e===l&&(t.substr(Jt,2)===$?(e=$,Jt+=2):(e=l,0===Yt&&ir(De)),e===l&&(e=t.charAt(Jt),Y.test(e)?Jt++:(e=l,0===Yt&&ir(Ge)))),Yt--,e===l&&(0===Yt&&ir(je)),e}function Ir(){var e,r,i;for(Yt++,e=Jt,r=[],i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));i!==l;)r.push(i),i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));return(i=Lr())!==l?e=r=[r,i]:(Jt=e,e=l),Yt--,e===l&&(r=l,0===Yt&&ir(Ue)),e}function Fr(){var e;return Yt++,e=t.charAt(Jt),X.test(e)?Jt++:(e=l,0===Yt&&ir(Je)),Yt--,e===l&&(0===Yt&&ir($e)),e}function Nr(){var e,r;return(e=Lr())===l&&(e=Jt,Yt++,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),Yt--,r===l?e=void 0:(Jt=e,e=l)),e}function Or(){var e,r;return(e=Ir())===l&&(e=Jt,Yt++,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),Yt--,r===l?e=void 0:(Jt=e,e=l)),e}function Er(){var e,r;return e=Jt,Yt++,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),Yt--,r===l?e=void 0:(Jt=e,e=l),e}const Rr=new o.BitmarkPegParserHelper({parse:e,parserText:Xt,parserLocation:jr}),Vr=new n.BitmarkPegParserProcessor({parse:e,parserText:Xt,parserLocation:jr});function jr(){const e=rr(Wt,Jt);return e?(delete e.source,e):e}function rr(e,t,r){var i=tr(e),o=tr(t),n={source:p,start:{offset:e,line:i.line,column:i.column},end:{offset:t,line:o.line,column:o.column}};return p&&"function"==typeof p.offset&&(n.start=p.offset(n.start),n.end=p.offset(n.end)),n}if(s=c(),r.peg$library)return{peg$result:s,peg$currPos:Jt,peg$FAILED:l,peg$maxFailExpected:Ht,peg$maxFailPos:qt};if(s!==l&&Jt===t.length)return s;throw s!==l&&Jt<t.length&&ir({type:"end"}),or(Ht,qt<t.length?t.charAt(qt):null,qt<t.length?rr(qt,qt+1):rr(qt,qt))};const i=r(3029),o=r(3206),n=r(7124);r(7735);function a(e,t,r,i){var o=Error.call(this,e);return Object.setPrototypeOf&&Object.setPrototypeOf(o,a.prototype),o.expected=t,o.found=r,o.location=i,o.name="SyntaxError",o}function s(e,t,r){return r=r||" ",e.length>t?e:(t-=e.length,e+(r+=r.repeat(t)).slice(0,t))}!function(e,t){function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r}(a,Error),a.prototype.format=function(e){var t="Error: "+this.message;if(this.location){var r,i=null;for(r=0;r<e.length;r++)if(e[r].source===this.location.source){i=e[r].text.split(/\r\n|\n|\r/g);break}var o=this.location.start,n=this.location.source&&"function"==typeof this.location.source.offset?this.location.source.offset(o):o,a=this.location.source+":"+n.line+":"+n.column;if(i){var l=this.location.end,p=s("",n.line.toString().length," "),u=i[o.line-1],c=(o.line===l.line?l.column:u.length+1)-o.column||1;t+="\n --\x3e "+a+"\n"+p+" |\n"+n.line+" | "+u+"\n"+p+" | "+s("",o.column-1," ")+s("",c,"^")}else t+="\n at "+a}return t},a.buildMessage=function(e,t){var r={literal:function(e){return'"'+o(e.text)+'"'},class:function(e){var t=e.parts.map((function(e){return Array.isArray(e)?n(e[0])+"-"+n(e[1]):n(e)}));return"["+(e.inverted?"^":"")+t.join("")+"]"},any:function(){return"any character"},end:function(){return"end of input"},other:function(e){return e.description}};function i(e){return e.charCodeAt(0).toString(16).toUpperCase()}function o(e){return e.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function n(e){return e.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function a(e){return r[e.type](e)}return"Expected "+function(e){var t,r,i=e.map(a);if(i.sort(),i.length>0){for(t=1,r=1;t<i.length;t++)i[t-1]!==i[t]&&(i[r]=i[t],r++);i.length=r}switch(i.length){case 1:return i[0];case 2:return i[0]+" or "+i[1];default:return i.slice(0,-1).join(", ")+", or "+i[i.length-1]}}(e)+" but "+function(e){return e?'"'+o(e)+'"':"end of input"}(t)+" found."};t.StartRules=["bitmark","bit","cardContent"]},5078:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.parse=void 0;const i=r(5057).parse;t.parse=i},5087:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkGenerator=void 0;const o=r(5126),n=r(6772),a=r(7735),s=r(2028),l=r(126),p=r(5854),u=r(3811),c=r(4410),y=r(1163),g=r(9727),d=r(166),f=r(6149),m=r(385),T=r(6877),h=r(4078),b=r(955),B=r(9681),v=r(4),C=r(431),P={debugGenerationInline:!1};class x extends v.AstWalkerGenerator{constructor(e,t){var r,i;super(),this.ast=new o.Ast,this.bitType=p.BitType._error,this.textFormat=m.TextFormat.bitmarkMinusMinus,this.tagTextFormat=m.TextFormat.bitmarkMinusMinus,this.isBodyBitmarkText=!1,this.isCardAllowed=!1,this.firstBit=!0,this.hasCardSet=!1,this.hasFooter=!1,this.inTag=!0,this.inTag,this.enter=this.enter.bind(this),this.between=this.between.bind(this),this.exit=this.exit.bind(this),this.leaf=this.leaf.bind(this),this.write=this.write.bind(this),this.bodyBitCallback=this.bodyBitCallback.bind(this),this.bitmarkVersion=null!==(r=u.BitmarkVersion.fromValue(null==t?void 0:t.bitmarkVersion))&&void 0!==r?r:u.DEFAULT_BITMARK_VERSION,this.options=Object.assign(Object.assign({},P),null==t?void 0:t.bitmarkOptions),this.debugGenerationInline=null!==(i=this.options.debugGenerationInline)&&void 0!==i&&i,this.bitmarkVersion===u.BitmarkVersion.v2?void 0===this.options.cardSetVersion&&(this.options.cardSetVersion=y.CardSetVersion.v1):void 0===this.options.cardSetVersion&&(this.options.cardSetVersion=y.CardSetVersion.v2),this.prettifySpace=!0===this.options.prettifyJson?2:this.options.prettifyJson||void 0,this.spacesAroundValues=this.calcSpacesAroundValues(),this.spacesAroundValuesStr=" ".repeat(this.spacesAroundValues),this.textGenerator=new C.TextGenerator(this.bitmarkVersion,{writeCallback:this.write,bodyBitCallback:this.bodyBitCallback,debugGenerationInline:this.debugGenerationInline}),this.mainWriter=e,this.partWriter=new n.StringWriter,this.writer=this.mainWriter,this.generateResourceHandlers(),this.generatePropertyHandlers()}generate(e){return i(this,void 0,void 0,(function*(){this.resetState(),yield this.writer.open(),this.walkAndWrite(e),this.writeLine(),yield this.writer.close()}))}generateSync(e){this.resetState(),this.writer.openSync(),this.walkAndWrite(e),this.writer.closeSync()}resetState(){this.bitType=p.BitType._error,this.textFormat=m.TextFormat.bitmarkMinusMinus,this.tagTextFormat=m.TextFormat.bitmarkMinusMinus,this.isBodyBitmarkText=!1,this.isCardAllowed=!1,this.firstBit=!0,this.hasCardSet=!1,this.hasFooter=!1,this.inTag=!0,this.printed=!1}walkAndWrite(e){this.ast.walk(e,l.NodeType.bitmarkAst,this,void 0),this.writeLine()}enter_bitsValue(e,t){var r;const i=e.value,o=s.Config.getBitConfig(i.bitType),n=s.Config.getBitResourcesConfig(i.bitType,i.resourceType);if(this.bitType=i.bitType,this.textFormat=null!==(r=i.textFormat)&&void 0!==r?r:o.textFormatDefault,this.isBodyBitmarkText=this.textFormat===m.TextFormat.bitmarkMinusMinus||this.textFormat===m.TextFormat.bitmarkPlusPlus,this.isCardAllowed=this.calculateIsCardAllowed(),this.tagTextFormat=this.textFormat===m.TextFormat.bitmarkPlusPlus?m.TextFormat.bitmarkPlusPlus:m.TextFormat.bitmarkMinusMinus,this.hasCardSet=this.haveValidCardSet(i),this.hasFooter=this.haveValidFooter(i),this.firstBit||(this.writeNL(),this.writeNL(),this.writeNL()),this.writeOPD(i.bitLevel),i.isCommented&&this.writeString("|"),this.writeTagKey(i.bitType),i.textFormat){this.isWriteTextFormat(i.textFormat,o.textFormatDefault)&&(this.writeColon(),this.writeTagKey(i.textFormat))}let a;if(o.resourceAttachmentAllowed&&i.resources&&i.resources.length>0){const e=n.comboResourceTagTypesMap;if(n.comboResourceTagTypesMap.size>0)for(const t of e.keys())a=t;else a=i.resources[0].type}return a&&(this.writeAmpersand(),this.writeTagKey(a)),this.writeCL(),!0}exit_bitsValue(e,t){this.firstBit=!1}enter_internalComment(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;for(let e=0;e<r.length;e++){const t=r[e];this.writeNL(),this.writeProperty("internalComment",t,{format:g.PropertyFormat.trimmedString,single:!1,ignoreEmpty:!0})}return!1}enter_labelTrue(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const o=null==i?void 0:i.value;if(o){const e=""!=r,t=o.labelFalse&&""!=o.labelFalse[0];(e||t)&&this.writeNL(),e&&this.writeProperty(d.PropertyTag.labelTrue,r,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),t&&this.writeProperty(d.PropertyTag.labelFalse,o.labelFalse,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}return!1}enter_labelFalse(e,t){return!0}enter_imageSource(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{url:o,mockupId:n,size:a,format:s,trim:p}=r;return this.writeNL(),this.writeProperty("imageSource",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),o&&(n&&this.writeProperty("mockupId",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),a&&this.writeProperty("size",a,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),s&&this.writeProperty("format",s,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),h.BooleanUtils.isBoolean(p)&&this.writeProperty("trim",p,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}enter_technicalTerm(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{technicalTerm:o,lang:n}=r;return this.writeNL(),this.writeProperty("technicalTerm",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=n&&this.writeProperty("lang",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),!1}enter_servings(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{servings:o,unit:n,unitAbbr:a,decimalPlaces:s,disableCalculation:p,hint:u}=r;return this.writeNL(),this.writeProperty("servings",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=n&&this.writeProperty("unit",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=a&&this.writeProperty("unitAbbr",a,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=s&&this.writeProperty("decimalPlaces",s,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=p&&this.writeProperty("disableCalculation",p,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=u&&(this.writeOPQ(),this.writeTextOrValue(u,m.TextFormat.text,T.TextLocation.tag),this.writeCL()),!1}enter_person(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{name:o,title:n,avatarImage:a}=r;return this.writeNL(),this.writeProperty("person",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),n&&this.writeProperty("title",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),a&&this.writeResource(f.ResourceTag.image,a.image.src),!1}enter_text(e,t){const r=this.getParentNode(t);return!r||r.key!==l.NodeType.term&&r.key!==l.NodeType.definition&&r.key!==l.NodeType.alternativeDefinitionsValue&&r.key!==l.NodeType.question&&r.key!==l.NodeType.answer&&r.key!==l.NodeType.alternativeAnswersValue||(e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}leaf_text(e,t){const r=this.getParentNode(t);return!r||r.key!==l.NodeType.term&&r.key!==l.NodeType.definition&&r.key!==l.NodeType.alternativeDefinitionsValue&&r.key!==l.NodeType.question&&r.key!==l.NodeType.answer&&r.key!==l.NodeType.alternativeAnswersValue&&r.key!==l.NodeType.reason||(B.StringUtils.isString(e.value)&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}enter_icon(e,t){const r=e.value,i=this.getParentNode(t);return!i||(i.key!==l.NodeType.term&&i.key!==l.NodeType.definition&&i.key!==l.NodeType.alternativeDefinitionsValue&&i.key!==l.NodeType.question&&i.key!==l.NodeType.answer&&i.key!==l.NodeType.alternativeAnswersValue||(this.writeNL(),this.writeResource(f.ResourceTag.icon,r.image.src)),!0)}leaf_iconValue(e,t){return this.writeNL(),this.writeProperty("icon",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),!1}enter_ratingLevelStart(e,t){return this.enterRatingLevelStartEndCommon(e,t),!1}enter_ratingLevelEnd(e,t){return this.enterRatingLevelStartEndCommon(e,t),!1}enterRatingLevelStartEndCommon(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{level:o,label:n}=r,a=e.key===l.NodeType.ratingLevelStart?d.PropertyTag.ratingLevelStart:d.PropertyTag.ratingLevelEnd;return this.writeNL(),this.writeProperty(a,o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),n&&this.writeProperty("label",n,{format:g.PropertyFormat.bitmarkMinusMinus,single:!0,ignoreEmpty:!0}),!1}enter_markConfig(e,t){return!0}enter_markConfigValue(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.markConfig)return!0;const{mark:o,color:n,emphasis:a}=r;return o&&(this.writeNL(),this.writeProperty("mark",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),n&&this.writeProperty("color",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),a&&this.writeProperty("emphasis",a,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}enter_partialAnswer(e,t){return e.value&&(this.writeNL(),this.writeProperty("partialAnswer",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}leaf_partialAnswer(e,t){return e.value&&(this.writeNL(),this.writeProperty("partialAnswer",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}enter_sampleSolution(e,t){return e.value&&(this.writeNL(),this.writeProperty("sampleSolution",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}leaf_sampleSolution(e,t){return e.value&&(this.writeNL(),this.writeProperty("sampleSolution",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}leaf_reasonableNumOfChars(e,t){this.writeNL(),this.writeProperty("reasonableNumOfChars",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_additionalSolutionsValue(e,t){const r=this.getParentNode(t,2);(null==r?void 0:r.key)===l.NodeType.questionsValue&&(this.writeNL(),this.writeProperty("additionalSolutions",e.value,{format:g.PropertyFormat.trimmedString,single:!1}))}enter_item(e,t){var r,i,o;const n=e.value,a=this.getParentNode(t);return!this.isEmptyText(n)&&(!this.isEmptyText(null===(r=null==a?void 0:a.value)||void 0===r?void 0:r.lead)||(!this.isEmptyText(null===(i=null==a?void 0:a.value)||void 0===i?void 0:i.pageNumber)||(!this.isEmptyText(null===(o=null==a?void 0:a.value)||void 0===o?void 0:o.marginNumber)||(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(n,this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0))))}enter_lead(e,t){var r,i,o,n;const a=e.value,s=this.getParentNode(t);return!this.isEmptyText(a)&&(!this.isEmptyText(null===(r=null==s?void 0:s.value)||void 0===r?void 0:r.pageNumber)||(!this.isEmptyText(null===(i=null==s?void 0:s.value)||void 0===i?void 0:i.marginNumber)||(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(null!==(n=null===(o=null==s?void 0:s.value)||void 0===o?void 0:o.item)&&void 0!==n?n:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(a,this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0)))}enter_pageNumber(e,t){var r,i,o,n,a;const s=e.value,l=this.getParentNode(t);return!this.isEmptyText(s)&&(!this.isEmptyText(null===(r=null==l?void 0:l.value)||void 0===r?void 0:r.marginNumber)||(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(null!==(o=null===(i=null==l?void 0:l.value)||void 0===i?void 0:i.item)&&void 0!==o?o:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!==(a=null===(n=null==l?void 0:l.value)||void 0===n?void 0:n.lead)&&void 0!==a?a:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!=s?s:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0))}enter_marginNumber(e,t){var r,i,o,n,a,s;const l=e.value,p=this.getParentNode(t);return!this.isEmptyText(l)&&(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(null!==(i=null===(r=null==p?void 0:p.value)||void 0===r?void 0:r.item)&&void 0!==i?i:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!==(n=null===(o=null==p?void 0:p.value)||void 0===o?void 0:o.lead)&&void 0!==n?n:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!==(s=null===(a=null==p?void 0:p.value)||void 0===a?void 0:a.pageNumber)&&void 0!==s?s:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(l,this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0)}enter_body(e,t){var r;const i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue&&(null==i?void 0:i.key)!==l.NodeType.cardBitsValue)return!0;this.inTag=!1;const o=e.value;if(this.textFormat===m.TextFormat.json){const e=null!==(r=o.body)&&void 0!==r?r:null;if(Array.isArray(e)||b.ObjectUtils.isObject(e)){const t=JSON.stringify(e,null,this.prettifySpace);t&&(this.writePlainTextDivider(),this.writeNL(),this.writeTextOrValue(t,m.TextFormat.text,T.TextLocation.body))}}else if(this.isBodyBitmarkText){const e=!(this.hasCardSet||this.hasFooter);this.writeNL();const t=Array.isArray(o.body)?o.body:[];this.writeTextOrValue(t,this.textFormat,T.TextLocation.body,{plainTextDividerAllowed:e})}else{this.writePlainTextDivider(),this.writeNL();const e=B.StringUtils.isString(o.body)?o.body:"";this.writeTextOrValue(`${e}`,m.TextFormat.text,T.TextLocation.body)}return!1}exit_body(e,t){this.inTag=!0}bodyBitCallback(e,t,r){var i;const o=null!==(i=l.NodeType.fromValue(e.type))&&void 0!==i?i:l.NodeType.bodyBit;return this.ast.walk(e,o,this,void 0),""}enter_gap(e,t){const r=e.value;if(r.solutions&&0===r.solutions.length)this.writeOPU(),this.writeCL();else for(const e of r.solutions)this.writeOPU(),this.writeTextOrValue(e,m.TextFormat.text,T.TextLocation.tag),this.writeCL();return!0}enter_mark(e,t){const r=e.value;return this.writeOPE(),this.writeTextOrValue(r.solution,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_select(e,t){return!0}enter_highlight(e,t){return!0}enter_footer(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value;return this.textFormat===m.TextFormat.json||i.footer&&i.footer.length>0&&this.isBodyBitmarkText&&(this.writeNL(),this.writeTextOrValue("==== footer ====",m.TextFormat.text,T.TextLocation.body),this.writeNL(),this.writeTextOrValue(i.footer,this.textFormat,T.TextLocation.body,{plainTextDividerAllowed:!0})),!1}enter_solutions(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value;return i&&0===i.length&&(this.writeOPU(),this.writeCL()),!0}leaf_solution(e,t){var r;const i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return;const o=e.value,n=null===(r=this.getParentNode(t,2))||void 0===r?void 0:r.value;(null==n?void 0:n.type)===c.BodyBitType.mark&&o&&(this.writeOPE(),this.writeTextOrValue(o,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_mark(e,t){const r=t[0];if((null==r?void 0:r.key)!==l.NodeType.mark)return;const i=e.value;i&&this.writeProperty("mark",i,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}enter_optionsValue(e,t){const r=e.value;return r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.text,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_textsValue(e,t){const r=e.value;return r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.text,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_cardNode(e,t){return!this.isCardAllowed||(this.writeCardSetStart(),!0)}between_cardNode(e,t,r,i){this.isCardAllowed&&this.writeCardSetCardDivider()}exit_cardNode(e,t){this.isCardAllowed&&(this.writeCardSetEnd(),this.options.cardSetVersion,y.CardSetVersion.v1)}enter_elements(e,t){}between_elements(e,t,r,i){this.writeCardSetVariantDivider()}between_flashcards(e,t,r,i){this.writeCardSetCardDivider()}between_flashcardsValue(e,t,r,i){var o;this.isCardAllowed&&(r.key===l.NodeType.answer?this.writeCardSetSideDivider():r.key===l.NodeType.alternativeAnswers&&0!==(null===(o=r.value)||void 0===o?void 0:o.length)&&this.writeCardSetVariantDivider())}between_alternativeAnswers(e,t){this.writeCardSetVariantDivider()}between_alternativeDefinitions(e,t){this.writeCardSetVariantDivider()}enter_statements(e,t){}between_statements(e,t,r,i){this.isOfBitType(p.BitType.trueFalse1)||this.writeCardSetCardDivider()}enter_statementsValue(e,t){const r=e.value;return this.writeNL(),r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.statement,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_choicesValue(e,t){const r=e.value;return this.writeNL(),r.isCorrect||r.requireReason?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.choice,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_responsesValue(e,t){const r=e.value;return this.writeNL(),r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.response,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}between_feedbacks(e,t,r,i){this.writeCardSetCardDivider()}enter_reason(e,t){return this.writeCardSetSideDivider(),!0}enter_quizzes(e,t){}between_quizzes(e,t,r,i){this.writeCardSetCardDivider()}enter_heading(e,t){}between_heading(e,t,r,i){this.isCardAllowed&&this.writeCardSetSideDivider()}enter_forValues(e,t){}between_forValues(e,t,r,i){this.isCardAllowed&&this.writeCardSetSideDivider()}enter_pairs(e,t){}between_pairs(e,t,r,i){this.writeCardSetCardDivider()}enter_keyAudio(e,t){const r=e.value;return this.writeNL(),this.writeResource(f.ResourceTag.audio,r.audio.src),!1}enter_keyImage(e,t){const r=e.value;return this.writeNL(),this.writeResource(f.ResourceTag.image,r.image.src),!1}enter_matrix(e,t){}between_matrix(e,t,r,i){this.writeCardSetCardDivider()}enter_values(e,t){this.isCardAllowed&&this.writeCardSetSideDivider()}between_values(e,t,r,i){this.isCardAllowed&&this.writeCardSetVariantDivider()}between_pronunciationTable(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)===l.NodeType.cardNode&&this.isCardAllowed&&this.writeCardSetCardDivider()}between_table(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)===l.NodeType.cardNode&&this.isCardAllowed&&this.writeCardSetCardDivider()}between_data(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)!==l.NodeType.table&&(null==o?void 0:o.key)!==l.NodeType.pronunciationTable||this.writeCardSetCardDivider()}between_columns(e,t,r,i){const o=this.getParentNode(i),n=null==o?void 0:o.key;n!==l.NodeType.table&&n!==l.NodeType.captionDefinitionList||this.isCardAllowed&&this.writeCardSetSideDivider()}leaf_columnsValue(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}enter_columnsValue(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,this.tagTextFormat,T.TextLocation.tag),this.writeCL()}between_dataValue(e,t,r,i){const o=this.getParentNode(i,2);(null==o?void 0:o.key)!==l.NodeType.table&&(null==o?void 0:o.key)!==l.NodeType.pronunciationTable||this.isCardAllowed&&this.writeCardSetSideDivider()}leaf_dataValueValue(e,t){const r=this.getParentNode(t,3);(null==r?void 0:r.key)===l.NodeType.table&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}enter_dataValueValue(e,t){const r=this.getParentNode(t,3);if(((null==r?void 0:r.key)===l.NodeType.table||(null==r?void 0:r.key)===l.NodeType.pronunciationTable)&&e.value){if((null==r?void 0:r.key)===l.NodeType.pronunciationTable){const t=e.value;return t.title&&(this.writeNL(),this.writeOP(),this.writeHash(),this.writeTextOrValue(t.title,this.tagTextFormat,T.TextLocation.tag),this.writeCL()),t.audio&&(this.writeNL(),this.writeResource(f.ResourceTag.audio,t.audio.audio.src)),t.body&&(this.writeNL(),this.writeTextOrValue(t.body,this.textFormat,T.TextLocation.body)),!1}this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)}}between_captionDefinitionList(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)===l.NodeType.cardNode&&this.writeCardSetCardDivider()}leaf_term(e,t){const r=this.getParentNode(t);return(null==r?void 0:r.key)!==l.NodeType.definitionsValue||(e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}leaf_definition(e,t){const r=this.getParentNode(t);return(null==r?void 0:r.key)!==l.NodeType.definitionsValue||(e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}between_definitions(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)!==l.NodeType.cardNode&&(null==o?void 0:o.key)!==l.NodeType.captionDefinitionList||this.writeCardSetCardDivider()}between_definitionsValue(e,t,r,i){var o;const n=this.getParentNode(i);(null==n?void 0:n.key)===l.NodeType.definitions&&this.isCardAllowed&&(r.key===l.NodeType.definition?this.writeCardSetSideDivider():r.key===l.NodeType.alternativeDefinitions&&(null===(o=r.value)||void 0===o?void 0:o.length)>0&&this.writeCardSetVariantDivider())}enter_questions(e,t){}between_questions(e,t,r,i){this.writeCardSetCardDivider()}enter_ingredients(e,t){}between_ingredients(e,t,r,i){this.writeCardSetCardDivider()}enter_ingredientsValue(e,t){const r=e.value;return null!=r.title&&(this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(r.title,m.TextFormat.text,T.TextLocation.tag),this.writeCL()),this.writeNL(),r.checked?this.writeOPP():this.writeOPM(),this.writeCL(),null!=r.quantity&&(this.writeOPB(),this.writeTextOrValue(`${r.quantity}`,m.TextFormat.text,T.TextLocation.tag),this.writeCL()),null!=r.unit&&this.writeProperty("unit",r.unit,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=r.unitAbbr&&this.writeProperty("unitAbbr",r.unitAbbr,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=r.decimalPlaces&&this.writeProperty("decimalPlaces",r.decimalPlaces,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),r.disableCalculation&&this.writeProperty("disableCalculation",!0,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=r.item&&(this.writeNL(),this.writeTextOrValue(r.item,this.textFormat,T.TextLocation.body)),!1}enter_botResponses(e,t){}between_botResponses(e,t,r,i){this.writeCardSetCardDivider()}enter_cardBits(e,t){}between_cardBits(e,t,r,i){this.writeCardSetCardDivider()}leaf_response(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)===l.NodeType.botResponsesValue&&(this.writeNL(),this.writeOPB(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_reaction(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)===l.NodeType.botResponsesValue&&(this.writeNL(),this.writeProperty("reaction",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}leaf_feedback(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.botResponsesValue)return;const i=e.value;i&&(this.writeNL(),this.writeTextOrValue(i,this.textFormat,T.TextLocation.body))}enter_imagePlaceholder(e,t){const r=e.value;return this.writeNL(),this.writePropertyStyleResource(e.key,r),!0}exit_imagePlaceholder(e,t){}enter_posterImage(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)===l.NodeType.bitsValue){const t=e.value;t&&this.writeProperty("posterImage",t,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}else{const t=e.value;t&&t.src&&this.writeProperty("posterImage",t.src,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}return!0}enter_thumbnails(e,t){const r=e.value;if(Array.isArray(r)){const e=["src1x","src2x","src3x","src4x"];for(let t=0;t<r.length&&t!==e.length;t++){const i=r[t],o=e[t];this.writeProperty(o,i.src,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}}return!1}leaf_level(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;if(!s.Config.isOfBitType(this.bitType,[p.BitType.chapter]))return!0;const i=e.value,o=null==r?void 0:r.value;if(i>0&&null==o.title){this.writeNL(),this.writeOP();for(let e=0;e<+i;e++)this.writeHash();this.writeCL()}return!1}enter_title(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value,o=(null==r?void 0:r.value).level||1;if(o&&i){this.writeNL(),this.writeOP();for(let e=0;e<+o;e++)this.writeHash();this.writeTextOrValue(i,this.tagTextFormat,T.TextLocation.tag),this.writeCL()}return!1}enter_subtitle(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value;if(i){this.writeNL(),this.writeOP();for(let e=0;e<2;e++)this.writeHash();this.writeTextOrValue(i,this.tagTextFormat,T.TextLocation.tag),this.writeCL()}return!1}enter_book(e,t){}enter_bookValue(e,t){const r=e.value;return r&&(this.writeNL(),this.writeProperty("book",r.book,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!1}),r.reference&&(this.writeOPRANGLE(),this.writeTextOrValue(r.reference,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),r.referenceEnd&&(this.writeOPRANGLE(),this.writeTextOrValue(r.referenceEnd,m.TextFormat.text,T.TextLocation.tag),this.writeCL()))),!1}leaf_book(e,t){const r=this.getParentNode(t),i=null==r?void 0:r.value;i&&e.value&&(this.writeNL(),this.writeProperty("book",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!1}),i.reference&&(this.writeOPRANGLE(),this.writeTextOrValue(i.reference,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),i.referenceEnd&&(this.writeOPRANGLE(),this.writeTextOrValue(i.referenceEnd,m.TextFormat.text,T.TextLocation.tag),this.writeCL())))}leaf_anchor(e,t){e.value&&(this.writeNL(),this.writeOPDANGLE(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_reference(e,t){const r=this.getParentNode(t),i=null==r?void 0:r.value;i&&e.value&&(i.book||(this.writeNL(),this.writeOPRANGLE(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()))}enter_hint(e,t){const r=e.value;return this.isEmptyText(r)||(this.writeNL_IfNotChain(t),this.writeOPQ(),this.writeTextOrValue(r,this.tagTextFormat,T.TextLocation.tag),this.writeCL()),!1}enter_instruction(e,t){const r=e.value;return this.isEmptyText(r)||(this.writeNL_IfNotChain(t),this.writeOPB(),this.writeTextOrValue(r,this.tagTextFormat,T.TextLocation.tag),this.writeCL()),!1}enter_lang(e,t){e.value&&(this.writeNL(),this.writeProperty("lang",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0}))}enter_refAuthor(e,t){e.value&&(this.writeNL(),this.writeProperty("refAuthor",e.value,{format:g.PropertyFormat.trimmedString,single:!1,ignoreEmpty:!0}))}enter_refBookTitle(e,t){e.value&&(this.writeNL(),this.writeProperty("refBookTitle",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}enter_refPublisher(e,t){e.value&&(this.writeNL(),this.writeProperty("refPublisher",e.value,{format:g.PropertyFormat.trimmedString,single:!1,ignoreEmpty:!0}))}enter_refPublicationYear(e,t){e.value&&(this.writeNL(),this.writeProperty("refPublicationYear",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}enter_citationStyle(e,t){e.value&&(this.writeNL(),this.writeProperty("citationStyle",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}leaf_isExample(e,t){var r;if(!e.value)return;const i=this.getParentNode(t),o=null!==(r=null==i?void 0:i.value.example)&&void 0!==r?r:null;null!=o&&""!==o&&(this.writeNL_IfNotChain(t),this.writeOPA(),this.writeString("example"),this.writeColon(),!0===o?this.writeString(" true "):!1===o?this.writeString(" false "):Array.isArray(o)?this.writeTextOrValue(o,this.tagTextFormat,T.TextLocation.tag):this.writeTextOrValue(o,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_elementsValue(e,t){e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_solutionsValue(e,t){const r=this.getParentNode(t,2);(null==r?void 0:r.key)===l.NodeType.bitsValue&&null!=e.value&&(this.writeOPU(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_prefix(e,t){e.value&&(this.writeOPPRE(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_postfix(e,t){e.value&&(this.writeOPPOST(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_isCaseSensitive(e,t){this.writeProperty("isCaseSensitive",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreFalse:!1,ignoreTrue:!0})}leaf_forKeys(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}leaf_forValues(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}leaf_forValuesValue(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}leaf_key(e,t){e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_valuesValue(e,t){e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_question(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)!==l.NodeType.questionsValue&&(null==r?void 0:r.key)!==l.NodeType.flashcardsValue||e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_src1x(e,t){this.writeProperty("src1x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_src2x(e,t){this.writeProperty("src2x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_src3x(e,t){this.writeProperty("src3x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_src4x(e,t){this.writeProperty("src4x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_width(e,t){this.writeProperty("width",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_height(e,t){this.writeProperty("height",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_alt(e,t){this.writeProperty("alt",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_zoomDisabled(e,t){s.Config.isOfBitType(this.bitType,[p.BitType.imageSeparator,p.BitType.pageBanner,p.BitType.imagesLogoGrave,p.BitType.prototypeImages])?this.writeProperty("zoomDisabled",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreFalse:!1,ignoreTrue:!0}):this.writeProperty("zoomDisabled",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreFalse:!0,ignoreTrue:!1})}leaf_license(e,t){this.writeProperty("license",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_copyright(e,t){this.writeProperty("copyright",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_provider(e,t){}leaf_showInIndex(e,t){null!=e.value&&(this.writeNL_IfNotChain(t),this.writeProperty("showInIndex",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0,ignoreFalse:!0}))}enter_caption(e,t){const r=e.value;return this.writeNL_IfNotChain(t),this.writeProperty("caption",r,{format:g.PropertyFormat.bitmarkMinusMinus,single:!0,ignoreEmpty:!0}),!1}leaf_search(e,t){const r=e.value;r&&(this.writeNL_IfNotChain(t),this.writeProperty("search",r,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}leaf_duration(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)!==l.NodeType.bitsValue&&this.writeProperty("duration",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_mute(e,t){this.writeProperty("mute",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}leaf_autoplay(e,t){this.writeProperty("autoplay",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}leaf_allowSubtitles(e,t){this.writeProperty("allowSubtitles",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}leaf_showSubtitles(e,t){this.writeProperty("showSubtitles",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}generateResourceHandlers(){for(const e of f.ResourceTag.keys()){if(e===f.ResourceTag.keyFromValue(f.ResourceTag.unknown))continue;const t=`enter_${e}`;"function"!=typeof this[t]&&(this[t]=(e,t)=>{const r=e.value;if(null==r)return!1;const i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.resourcesValue)return!0;const o=f.ResourceTag.fromValue(i.value.__typeAlias),n=null!=o?o:f.ResourceTag.fromValue(i.value.type);if(!n)return!1;const a=r.url||r.src||r.body||"";return this.writeNL(),this.writeResource(n,a),!0},this[t]=this[t].bind(this))}}generatePropertyHandlers(){var e;const t=s.Config.getRawPropertiesConfig();for(const r of Object.values(t)){const t=null!==(e=r.astKey)&&void 0!==e?e:r.tag,i=`enter_${t}`;"function"!=typeof this[i]&&("example"!==t&&(this[i]=(e,t)=>{var i,o;if(null==e.value)return;const n=this.getParentNode(t);(null==n?void 0:n.key)===l.NodeType.bitsValue&&(this.writeNL_IfNotChain(t),this.writeProperty(r.tag,e.value,{format:null!==(i=r.format)&&void 0!==i?i:g.PropertyFormat.trimmedString,single:null!==(o=r.single)&&void 0!==o&&o,ignoreFalse:"false"===r.defaultValue,ignoreTrue:"true"===r.defaultValue}))},this[i]=this[i].bind(this)))}}isChain(e){const t=this.getParentNode(e);return(null==t?void 0:t.key)!==l.NodeType.bitsValue&&((null==t?void 0:t.key)!==l.NodeType.cardBitsValue&&((null==t?void 0:t.key)!==l.NodeType.feedbacksValue&&((null==t?void 0:t.key)!==l.NodeType.quizzesValue&&((null==t?void 0:t.key)!==l.NodeType.pairsValue&&((null==t?void 0:t.key)!==l.NodeType.matrixValue&&((null==t?void 0:t.key)!==l.NodeType.definitionsValue&&((null==t?void 0:t.key)!==l.NodeType.questionsValue&&(null==t?void 0:t.key)!==l.NodeType.reason)))))))}haveValidCardSet(e){const t=s.Config.getBitConfig(e.bitType);return!!t&&!!t.cardSet}haveValidFooter(e){const t=e.footer;if(!t)return!1;return e.textFormat!==m.TextFormat.json&&(!!(t.footer&&t.footer.length>0)&&!!this.isBodyBitmarkText)}calcSpacesAroundValues(){const e=this.options.spacesAroundValues;let t=1;return null!=e&&(t=!0===e?1:!1===e?0:e),t=Math.min(Math.max(t,0),10),t}writeTagKey(e){null!=e&&this.write(a.Breakscape.breakscape(`${e}`,{textFormat:m.TextFormat.text,textLocation:T.TextLocation.tag}))}writeTextOrValue(e,t,r,i){const o=r===T.TextLocation.tag,n="string"==typeof e?e:void 0,s=Array.isArray(e)?e:void 0,l=o?this.spacesAroundValuesStr:"",p=t===m.TextFormat.bitmarkPlusPlus||t===m.TextFormat.bitmarkMinusMinus?t:m.TextFormat.text,u=e=>o?`${l}${e}${l}`:e,c=e=>{const t=this.writer;this.writer=this.partWriter,this.partWriter.openSync(),e(),this.partWriter.closeSync();const r=this.partWriter.getString().trim();return this.writer=t,r};if(null==n){if(null!=s){const e=()=>this.textGenerator.generateSync(s,t,r,i);if(o){const t=c(e);t&&this.write(u(t))}else e()}}else{const e=()=>this.write(a.Breakscape.breakscape(n,{textFormat:p,textLocation:r}));if(o){const t=c(e);t&&this.write(u(t))}else e()}}writeString(e){null!=e&&this.write(`${e}`)}writeOPBUL(){this.write("[•")}writeOPESC(){this.write("[^")}writeOPRANGLE(){this.write("[►")}writeOPDANGLE(){this.write("[▼")}writeOPD(e){this.write(`[${".".repeat(e)}`)}writeOPU(){this.write("[_")}writeOPE(){this.write("[=")}writeOPB(){this.write("[!")}writeOPQ(){this.write("[?")}writeOPA(){this.write("[@")}writeOPP(){this.write("[+")}writeOPM(){this.write("[-")}writeOPS(){this.write("[\\")}writeOPR(){this.write("[*")}writeOPC(){this.write("[%")}writeOPAMP(){this.write("[&")}writeOPDOLLAR(){this.write("[$")}writeOPHASH(){this.write("[#")}writeOPPRE(){this.write("['")}writeOPPOST(){this.write("[")}writeOP(){this.write("[")}writeCL(){0===this.spacesAroundValues&&this.writer.getLastWrite().endsWith("^")?this.write(" ]"):this.write("]")}writeAmpersand(){this.write("&")}writeColon(){this.write(":")}writeHash(){this.write("#")}writeSpacesAroundValues(){this.write(this.spacesAroundValuesStr)}writePlainTextDivider(){this.writeNL(),this.write("==== text ====")}writeCardSetStart(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("==="):this.write("====")}writeCardSetEnd(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1&&this.write("===")}writeCardSetCardDivider(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("==="):this.write("====")}writeCardSetSideDivider(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("=="):this.write("--")}writeCardSetVariantDivider(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("--"):this.write("++")}writeNL_IfNotChain(e){this.isChain(e)||this.writeNL()}writeNL(){this.options.debugGenerationInline?this.write("\\n"):this.write("\n")}writePropertyStyleResource(e,t){var r;if(e&&t){const i=t[null!==(r=f.ResourceTag.keyFromValue(t.type))&&void 0!==r?r:""],o=i&&(i.src||i.url||i.body)||"";this.writeOPA(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(o,m.TextFormat.text,T.TextLocation.tag),t.type,f.ResourceTag.article,this.writeCL()}}writeResource(e,t){e&&(this.writeOPAMP(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(t,m.TextFormat.text,T.TextLocation.tag),f.ResourceTag.article,this.writeCL())}writeProperty(e,t,r){var i;let o;if(void 0!==t){const n=r.format===g.PropertyFormat.bitmarkMinusMinus||r.format===g.PropertyFormat.bitmarkPlusPlus;if(n){if(r.ignoreEmpty&&n&&this.isEmptyText(t))return;this.writeOPA(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(t,null!==(i=m.TextFormat.fromValue(r.format))&&void 0!==i?i:m.TextFormat.bitmarkMinusMinus,T.TextLocation.tag),this.writeCL()}else if(o=Array.isArray(t)?t:[t],o.length>0){r.single&&(o=o.slice(o.length-1));for(const t of o)if(void 0!==t){if(r.ignoreFalse&&!1===t)continue;if(r.ignoreTrue&&!0===t)continue;if(r.ignoreEmpty&&""===t)continue;this.writeOPA(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(`${t}`,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}}}}writeInlineDebug(e,t){let r=e;t.open?r=`<${e}>`:t.close?r=`</${e}>`:t.single&&(r=`<${e} />`),this.writeString(r)}isEmptyText(e){return!e||(!Array.isArray(e)||0===e.length)}isWriteTextFormat(e,t){return!!(!(m.TextFormat.fromValue(e)===t)||this.options.explicitTextFormat)}calculateIsCardAllowed(){return this.isBodyBitmarkText&&!this.isOfBitType1()}isOfBitType1(){return this.isOfBitType([p.BitType.trueFalse1,p.BitType.multipleChoice1,p.BitType.multipleResponse1])}isOfBitType(e){return s.Config.isOfBitType(this.bitType,e)}write(e){return this.writer.write(e),this}writeLine(e){return this.writer.writeLine(e),this}writeLines(e,t){return this.writer.writeLines(e,t),this}writeWhiteSpace(){return this.writer.writeWhiteSpace(),this}}t.BitmarkGenerator=x},5126:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Ast=void 0;const i=r(1412),o=r(126),n=r(9681);t.Ast=class{constructor(){(0,i.init)()}walk(e,t,r,i){this.walkRecursive(e,[{index:0,key:t,value:e}],r,i)}getRouteKey(e){return e.reduce(((t,r,i)=>(+r.key!==r.index&&(t+=`${r.key}`,i<e.length-1&&(t+="_")),t)),"")}printTree(e,t=o.NodeType.bitmarkAst){this.walkRecursive(e,[{index:0,key:t,value:e}],{enter:(e,t)=>(console.log("Enter: "+this.getRouteKey(t)),t[t.length-1].key!==o.NodeType.bodyJson),between:(e,t,r,i)=>{console.log("Between: "+this.getRouteKey(i))},exit:(e,t)=>{console.log("Exit: "+this.getRouteKey(t))},leaf:(e,t)=>{console.log("Leaf: "+this.getRouteKey(t))}},void 0)}preprocessAst(e){if(n.StringUtils.isString(e)){const t=e;try{e=JSON.parse(t)}catch(e){return}}if(this.isAst(e))return e}isAst(e){return!(!Object.prototype.hasOwnProperty.call(e,"bits")||!Array.isArray(e.bits))}walkRecursive(e,t,r,i){const{enter:o,between:n,exit:a,leaf:s}=r,l=t[t.length-1].key,p=!this.isValue(e),u=t[t.length-1];if(p){if(o){if(!1===o(u,t,i))return}}else s&&s(u,t,i);if(p){const o=this.isArray(e),a=Object.keys(e);for(let s=0,p=a.length;s<p;s++){const c=a[s],y=s===p-1,g=e,d=g[c];if(null!=d){const e={key:this.getAstKey(c,l,o),index:s,value:d},p=t.slice();if(p.push(e),this.walkRecursive(d,p,r,i),!y){const r=a[s+1],p=g[r],c={key:this.getAstKey(r,l,o),index:s+1,value:p};if(n){if(!1===n(u,e,c,t,i))break}}}}}p&&a&&a(u,t,i)}getAstKey(e,t,r){let i=e;return r&&t&&(i=`${t}Value`),o.NodeType.fromKey(i)||`unknown(${i})`}isArray(e){return Array.isArray(e)}isObject(e){return"[object Object]"===Object.prototype.toString.call(e)}isValue(e){return!this.isObject(e)&&!this.isArray(e)}}},5189:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.markChainContentProcessor=function(e,t,r,u,c,y){if(t===p.BitContentLevel.Chain)(0,l.markTagContentProcessor)(e,p.BitContentLevel.Chain,u,c);else{const t=function(e,t,r,l){var u;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("mark content",l);const c=o.Config.getTagConfigForTag(r,a.Tag.fromValue(l.type)),y=e.bitContentProcessor(p.BitContentLevel.Chain,r,[l]),g=e.bitContentProcessor(p.BitContentLevel.Chain,null==c?void 0:c.chain,l.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("mark TAGS",g);const{solution:d}=y,{mark:f}=g,m=i(g,["mark"]),T=Object.assign({type:n.BodyBitType.mark,solution:null!=d?d:"",mark:null!==(u=s.ArrayUtils.asSingle(f))&&void 0!==u?u:""},m);return T}(e,0,r,u);t&&y.push(t)}};const o=r(2028),n=r(4410),a=r(9917),s=r(6989),l=r(5980),p=r(3029)},5416:(e,t,r)=>{const{VOID:i,PRIMITIVE:o,ARRAY:n,OBJECT:a,DATE:s,REGEXP:l,MAP:p,SET:u,ERROR:c,BIGINT:y}=r(1731),g="",{toString:d}={},{keys:f}=Object,m=e=>{const t=typeof e;if("object"!==t||!e)return[o,t];const r=d.call(e).slice(8,-1);switch(r){case"Array":return[n,g];case"Object":return[a,g];case"Date":return[s,g];case"RegExp":return[l,g];case"Map":return[p,g];case"Set":return[u,g];case"DataView":return[n,r]}return r.includes("Array")?[n,r]:r.includes("Error")?[c,r]:[a,r]},T=([e,t])=>e===o&&("function"===t||"symbol"===t);t.serialize=(e,{json:t,lossy:r}={})=>{const c=[];return((e,t,r,c)=>{const g=(e,t)=>{const i=c.push(e)-1;return r.set(t,i),i},d=c=>{if(r.has(c))return r.get(c);let[h,b]=m(c);switch(h){case o:{let t=c;switch(b){case"bigint":h=y,t=c.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+b);t=null;break;case"undefined":return g([i],c)}return g([h,t],c)}case n:{if(b){let e=c;return"DataView"===b?e=new Uint8Array(c.buffer):"ArrayBuffer"===b&&(e=new Uint8Array(c)),g([b,[...e]],c)}const e=[],t=g([h,e],c);for(const t of c)e.push(d(t));return t}case a:{if(b)switch(b){case"BigInt":return g([b,c.toString()],c);case"Boolean":case"Number":case"String":return g([b,c.valueOf()],c)}if(t&&"toJSON"in c)return d(c.toJSON());const r=[],i=g([h,r],c);for(const t of f(c))!e&&T(m(c[t]))||r.push([d(t),d(c[t])]);return i}case s:return g([h,c.toISOString()],c);case l:{const{source:e,flags:t}=c;return g([h,{source:e,flags:t}],c)}case p:{const t=[],r=g([h,t],c);for(const[r,i]of c)(e||!T(m(r))&&!T(m(i)))&&t.push([d(r),d(i)]);return r}case u:{const t=[],r=g([h,t],c);for(const r of c)!e&&T(m(r))||t.push(d(r));return r}}const{message:B}=c;return g([h,{name:b,message:B}],c)};return d})(!(t||r),!!t,new Map,c)(e),c}},5512:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitTagType=void 0;const i=(0,r(4718).superenum)({tag:"tag",property:"property",resource:"resource",group:"group"});t.BitTagType=i},5533:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceBuilder=void 0;const o=r(7735),n=r(2028),a=r(5854),s=r(6149),l=r(955),p=r(9681),u=r(201),c=r(4470),y=r(4564);class g extends c.BaseBuilder{resourceFromResourceJson(e,t){if(!t)return;const r=[];Array.isArray(t)||(t=[t]);for(const i of t){let t=s.ResourceTag.fromValue(i.type);if(!t)return;const o=s.ResourceTag.keyFromValue(t);if(!o)return;const n=s.ResourceTag.fromValue(i.__typeAlias);let a;if(t=null!=n?n:t,t===s.ResourceTag.imageResponsive){const t=i,o=this.resourceFromResourceDataJson(e,s.ResourceTag.imagePortrait,t.imagePortrait),n=this.resourceFromResourceDataJson(e,s.ResourceTag.imageLandscape,t.imageLandscape);o&&r.push(o),n&&r.push(n)}else if(t===s.ResourceTag.stillImageFilm){const t=i,o=this.resourceFromResourceDataJson(e,s.ResourceTag.image,t.image),n=this.resourceFromResourceDataJson(e,s.ResourceTag.audio,t.audio);o&&r.push(o),n&&r.push(n)}else{if(a=i[o],!a)return;const n=this.resourceFromResourceDataJson(e,t,a);n&&r.push(n)}}return 0!==r.length?1===r.length?r[0]:r:void 0}resourceFromResourceDataJson(e,t,r){var i,o,n;if(!r)return;if(!(t=s.ResourceTag.fromValue(t)))return;const a=p.StringUtils.isString(r)?r:void 0,l=r.url||r.src||r.body||a,u=r.posterImage?null===(i=this.resourceFromResourceDataJson(e,s.ResourceTag.image,r.posterImage))||void 0===i?void 0:i.image:void 0,c=r.thumbnails?r.thumbnails.map((t=>{var r;return null===(r=this.resourceFromResourceDataJson(e,s.ResourceTag.image,t))||void 0===r?void 0:r.image})):void 0;return this.resource(e,{type:t,value:l,format:r.format,src1x:r.src1x,src2x:r.src2x,src3x:r.src3x,src4x:r.src4x,caption:this.handleJsonText(e,!0,r.caption),width:null!==(o=r.width)&&void 0!==o?o:void 0,height:null!==(n=r.height)&&void 0!==n?n:void 0,alt:r.alt,zoomDisabled:r.zoomDisabled,duration:r.duration,mute:r.mute,autoplay:r.autoplay,allowSubtitles:r.allowSubtitles,showSubtitles:r.showSubtitles,posterImage:u,thumbnails:c,siteName:void 0,license:r.license,copyright:r.copyright,showInIndex:r.showInIndex,search:r.search})}resource(e,t){var r;let n;const{type:a,value:l,format:p}=t,u=i(t,["type","value","format"]),c=Object.assign({type:a,value:null!=l?l:o.Breakscape.EMPTY_STRING,format:null!=p?p:o.Breakscape.EMPTY_STRING},u);switch(a){case s.ResourceTag.video:case s.ResourceTag.videoEmbed:case s.ResourceTag.videoLink:case s.ResourceTag.stillImageFilmEmbed:case s.ResourceTag.stillImageFilmLink:{const i=["src1x","src2x","src3x","src4x"],o=[];for(const r of i){const i=t[r];if(i){const t=this.resource(e,{type:s.ResourceTag.image,value:i});t&&o.push(t.image)}}c.thumbnails=[...null!==(r=c.thumbnails)&&void 0!==r?r:[],...o]}}switch(a){case s.ResourceTag.icon:case s.ResourceTag.image:case s.ResourceTag.imagePortrait:case s.ResourceTag.imageLandscape:n=this.imageResource(e,c,a);break;case s.ResourceTag.imageLink:n=this.imageLinkResource(e,c);break;case s.ResourceTag.audio:n=this.audioResource(e,c);break;case s.ResourceTag.audioEmbed:n=this.audioEmbedResource(e,c);break;case s.ResourceTag.audioLink:n=this.audioLinkResource(e,c);break;case s.ResourceTag.video:n=this.videoResource(e,c);break;case s.ResourceTag.videoEmbed:n=this.videoEmbedResource(e,c);break;case s.ResourceTag.videoLink:n=this.videoLinkResource(e,c);break;case s.ResourceTag.stillImageFilmEmbed:n=this.stillImageFilmEmbedResource(e,c);break;case s.ResourceTag.stillImageFilmLink:n=this.stillImageFilmLinkResource(e,c);break;case s.ResourceTag.article:n=this.articleResource(e,c);break;case s.ResourceTag.document:n=this.documentResource(e,c);break;case s.ResourceTag.documentEmbed:n=this.documentEmbedResource(e,c);break;case s.ResourceTag.documentLink:n=this.documentLinkResource(e,c);break;case s.ResourceTag.documentDownload:n=this.documentDownloadResource(e,c);break;case s.ResourceTag.appLink:n=this.appLinkResource(e,c);break;case s.ResourceTag.websiteLink:n=this.websiteLinkResource(e,c)}return n}imageResource(e,t,r){var i,o;const{value:p,src1x:c,src2x:g,src3x:d,src4x:f,width:m,height:T,alt:h,zoomDisabled:b,license:B,copyright:v,showInIndex:C,caption:P,search:x}=t,{bitType:k}=e;let K=!1;n.Config.isOfBitType(k,[a.BitType.imageSeparator,a.BitType.pageBanner,a.BitType.imagesLogoGrave,a.BitType.prototypeImages])&&(K=!0);const w={type:s.ResourceTag.image,__typeAlias:null!=r?r:s.ResourceTag.image,image:{format:null!==(i=u.UrlUtils.fileExtensionFromUrl(p))&&void 0!==i?i:void 0,provider:null!==(o=u.UrlUtils.domainFromUrl(p))&&void 0!==o?o:void 0,src:null!=p?p:"",src1x:null!=c?c:void 0,src2x:null!=g?g:void 0,src3x:null!=d?d:void 0,src4x:null!=f?f:void 0,width:null!=m?m:null,height:null!=T?T:null,alt:null!=h?h:"",zoomDisabled:null!=b?b:K,license:null!=B?B:"",copyright:null!=v?v:"",showInIndex:null!=C&&C,caption:this.handleJsonText(e,!0,P),search:null!=x?x:void 0}};return l.ObjectUtils.removeUnwantedProperties(w.image,{ignoreFalse:["zoomDisabled","showInIndex"],ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["src","alt","license","copyright"]}),y.NodeValidator.validateResource(w)}imageLinkResource(e,t){var r,i;const{value:o,src1x:n,src2x:a,src3x:p,src4x:c,width:g,height:d,alt:f,zoomDisabled:m,license:T,copyright:h,showInIndex:b,caption:B,search:v}=t,C={type:s.ResourceTag.imageLink,__typeAlias:s.ResourceTag.imageLink,imageLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",src1x:null!=n?n:void 0,src2x:null!=a?a:void 0,src3x:null!=p?p:void 0,src4x:null!=c?c:void 0,width:null!=g?g:null,height:null!=d?d:null,alt:null!=f?f:"",zoomDisabled:null!=m&&m,license:null!=T?T:"",copyright:null!=h?h:"",showInIndex:null!=b&&b,caption:this.handleJsonText(e,!0,B),search:null!=v?v:void 0}};return l.ObjectUtils.removeUnwantedProperties(C.imageLink,{ignoreFalse:["zoomDisabled","showInIndex"],ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","alt","license","copyright"]}),y.NodeValidator.validateResource(C)}audioResource(e,t){var r,i;const{value:o,duration:n,mute:a,autoplay:p,license:c,copyright:g,showInIndex:d,caption:f,search:m}=t,T={type:s.ResourceTag.audio,__typeAlias:s.ResourceTag.audio,audio:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,src:null!=o?o:"",duration:null!=n?n:void 0,mute:null!=a?a:void 0,autoplay:null!=p?p:void 0,license:null!=c?c:"",copyright:null!=g?g:"",showInIndex:null!=d&&d,caption:this.handleJsonText(e,!0,f),search:null!=m?m:void 0}};return l.ObjectUtils.removeUnwantedProperties(T.audio,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["src","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(T)}audioEmbedResource(e,t){var r,i;const{value:o,duration:n,mute:a,autoplay:p,license:c,copyright:g,showInIndex:d,caption:f,search:m}=t,T={type:s.ResourceTag.audioEmbed,__typeAlias:s.ResourceTag.audioEmbed,audioEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,src:null!=o?o:"",duration:null!=n?n:void 0,mute:null!=a?a:void 0,autoplay:null!=p?p:void 0,license:null!=c?c:"",copyright:null!=g?g:"",showInIndex:null!=d&&d,caption:this.handleJsonText(e,!0,f),search:null!=m?m:void 0}};return l.ObjectUtils.removeUnwantedProperties(T.audioEmbed,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["src","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(T)}audioLinkResource(e,t){var r,i;const{value:o,duration:n,mute:a,autoplay:p,license:c,copyright:g,showInIndex:d,caption:f,search:m}=t,T={type:s.ResourceTag.audioLink,__typeAlias:s.ResourceTag.audioLink,audioLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",duration:null!=n?n:void 0,mute:null!=a?a:void 0,autoplay:null!=p?p:void 0,license:null!=c?c:"",copyright:null!=g?g:"",showInIndex:null!=d&&d,caption:this.handleJsonText(e,!0,f),search:null!=m?m:void 0}};return l.ObjectUtils.removeUnwantedProperties(T.audioLink,{ignoreEmptyString:["url"]}),y.NodeValidator.validateResource(T)}videoResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.video,__typeAlias:s.ResourceTag.video,video:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,src:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0,posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.video,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["src","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}videoEmbedResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.videoEmbed,__typeAlias:s.ResourceTag.videoEmbed,videoEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.videoEmbed,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}videoLinkResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.videoLink,__typeAlias:s.ResourceTag.videoLink,videoLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.videoLink,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}stillImageFilmEmbedResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.stillImageFilmEmbed,__typeAlias:s.ResourceTag.stillImageFilmEmbed,stillImageFilmEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.stillImageFilmEmbed,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}stillImageFilmLinkResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.stillImageFilmLink,__typeAlias:s.ResourceTag.stillImageFilmLink,stillImageFilmLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.stillImageFilmLink,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}articleResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.article,__typeAlias:s.ResourceTag.article,article:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,body:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.article,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["body","alt","license","copyright"]}),y.NodeValidator.validateResource(d)}documentResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.document,__typeAlias:s.ResourceTag.document,document:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.document,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}documentEmbedResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.documentEmbed,__typeAlias:s.ResourceTag.documentEmbed,documentEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.documentEmbed,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}documentLinkResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.documentLink,__typeAlias:s.ResourceTag.documentLink,documentLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.documentLink,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}documentDownloadResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.documentDownload,__typeAlias:s.ResourceTag.documentDownload,documentDownload:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.documentDownload,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}appLinkResource(e,t){const{value:r,license:i,copyright:o,showInIndex:n,caption:a,search:p}=t,u={type:s.ResourceTag.appLink,__typeAlias:s.ResourceTag.appLink,appLink:{provider:void 0,url:null!=r?r:"",license:null!=i?i:"",copyright:null!=o?o:"",showInIndex:null!=n&&n,caption:this.handleJsonText(e,!0,a),search:null!=p?p:void 0}};return l.ObjectUtils.removeUnwantedProperties(u.appLink,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(u)}websiteLinkResource(e,t){const{value:r,license:i,copyright:o,showInIndex:n,caption:a,search:p}=t,u={type:s.ResourceTag.websiteLink,__typeAlias:s.ResourceTag.websiteLink,websiteLink:{provider:void 0,url:null!=r?r:"",license:null!=i?i:"",copyright:null!=o?o:"",showInIndex:null!=n&&n,caption:this.handleJsonText(e,!0,a),search:null!=p?p:void 0}};return l.ObjectUtils.removeUnwantedProperties(u.websiteLink,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(u)}}t.ResourceBuilder=g},5554:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CARDS=void 0;const i=r(8199),o=r(7112),n=r(9888),a=r(5051),s=r(7797),l=r(5512),p=r(3778),u={[i.CardSetConfigKey._definitionList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_resourceIcon}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._flashcard]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_resourceIcon}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._elements]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._statements]:{variants:[[{tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:1},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:1},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],bodyAllowed:!1}]]},[i.CardSetConfigKey._quiz]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],bodyAllowed:!1}]]},[i.CardSetConfigKey._feedback]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],bodyAllowed:!1}],[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],bodyAllowed:!0}]]},[i.CardSetConfigKey._questions]:{variants:[[{tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars},{type:l.BitTagType.tag,configKey:s.TagConfigKey.sampleSolution},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_sampleSolution},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.additionalSolutions,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.partialAnswer},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchPairs]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchAudioPairs]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audio}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchImagePairs]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.image}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchMatrix]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._table]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._pronunciationTable]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audio}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._botActionResponses]:{variants:[[{tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reaction},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}]}]]},[i.CardSetConfigKey._clozeList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_gap}]}]]},[i.CardSetConfigKey._exampleBitList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._ingredients]:{variants:[[{tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.unit},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.unitAbbr},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.decimalPlaces},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.disableCalculation}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._bookReferenceList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refAuthor,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refBookTitle},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refPublisher,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refPublicationYear},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.citationStyle}],repeatCount:p.Count.infinity}]]}};t.CARDS=u},5591:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ConfigKey=void 0;const i=r(4718),o=r(7112),n=r(9888),a=r(5051),s=r(7797),l=(0,i.superenum)(Object.assign(Object.assign(Object.assign(Object.assign({_unknown:"_unknown"},s.tagConfigKeys),n.propertyConfigKeys),a.resourceConfigKeys),o.groupConfigKeys));t.ConfigKey=l,function(){const e=new Set,t=[s.tagConfigKeys,n.propertyConfigKeys,a.resourceConfigKeys,o.groupConfigKeys];for(const r of t)for(const t in r)e.add(t)}()},5633:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkParser=void 0;const i=r(5663),o=r(5078);t.BitmarkParser=class{constructor(){this.jsonParser=new i.JsonParser}toAst(e,t){return(0,o.parse)(e)}}},5659:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.parseUserAgent=function(){if("undefined"==typeof window||!window.navigator||!window.navigator.userAgent)return;const e={browser:i.Environment.unknown,os:o.Os.unknown},t=function(e){const t=e.toLowerCase().split(new RegExp("[ /,;()]","g")).reduce(((e,t)=>(t&&e.push(t),e)),[]),r={keys:new Set,versions:{}};let i="";for(let e=0,o=t.length;e<o;e++){const o=t[e];let n=!1;for(let e=0;e<=9;e++)if(o.startsWith(`${e}`)){n=!0;break}n?r.versions[i]=o.replace("_","."):r.keys.add(o),i=o}return r}(window.navigator.userAgent),r=t.keys.has("firefox"),n=t.keys.has("chrome"),a=t.keys.has("chromium"),s=t.keys.has("safari"),l=t.keys.has("macintosh"),p=n,u=r,c=l;!s||n||a?p?(e.browser=i.Environment.chrome,e.browserVersion=t.versions.chrome):u&&(e.browser=i.Environment.firefox,e.browserVersion=t.versions.firefox):(e.browser=i.Environment.safari,e.browserVersion=t.versions.version);c&&(e.os=o.Os.macos,e.osVersion=t.versions.x);return e};const i=r(6278),o=r(9561)},5663:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonParser=void 0;const o=r(5809),n=r(2028),a=r(5854),s=r(6149),l=r(385),p=r(9681),u=new o.Builder;t.JsonParser=class{toAst(e){const t=this.preprocessJson(e),r=[];for(const e of t){const{bit:t,parser:i}=e,o=this.bitToAst(t,null==i?void 0:i.internalComments);o&&r.push(o)}const i=r.length>0?{bits:r}:{};return u.buildBitmark(i)}preprocessJson(e){const t=[];if(p.StringUtils.isString(e)){const t=e;try{e=JSON.parse(t)}catch(e){return[]}}const r=e=>{if(this.isBitWrapper(e)){const r=e;t.push(r)}else if(this.isBit(e)){const r=e;t.push(this.bitToBitWrapper(r))}};if(Array.isArray(e))for(const t of e)r(t);else r(e);return t}isBitWrapper(e){if(Object.prototype.hasOwnProperty.call(e,"bit")){const t=e;return this.isBit(t.bit)}return!1}isBit(e){if(Object.prototype.hasOwnProperty.call(e,"type")){const t=e;return n.Config.getBitType(t.type)!==a.BitType._error}return!1}bitToBitWrapper(e){return{bit:e}}bitToAst(e,t){var r,o,s,p,c;const{statement:y,product:g,productVideo:d,reference:f}=e,m=i(e,["statement","product","productVideo","reference"]),T=e.type===a.BitType._comment&&void 0!==e.originalType,h=n.Config.getBitType(T?e.originalType:e.type),b=n.Config.getBitConfig(h);null!==(r=l.TextFormat.fromValue(e.format))&&void 0!==r||b.textFormatDefault;return u.buildBit(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},m),{bitType:h,bitLevel:Math.max(Math.min(null!==(o=e.bitLevel)&&void 0!==o?o:1,n.Config.bitLevelMax),n.Config.bitLevelMin),textFormat:e.format,resourceType:this.getResourceType(e.resource),isCommented:T,internalComment:t,productList:g,productVideoList:d}),this.processReference(f)),this.parseExample(e.example)),{person:null!==(s=e.partner)&&void 0!==s?s:e.person,markConfig:e.marks,resources:this.processResources(h,e.resource,e.images,e.logos),body:this.processBody(e.body,e.placeholders),flashcards:e.cards,statements:this.processStatements(y,e.isCorrect,e.statements,e.example),responses:this.processResponses(h,e.responses),botResponses:this.processBotResponse(h,e.responses),cardBits:this.processListItems(null!==(c=null!==(p=e.listItems)&&void 0!==p?p:e.sections)&&void 0!==c?c:e.bookReferences,e.placeholders),footer:this.processFooter(e.footer)}))}processStatements(e,t,r,i){const o=[];if(e){const r=Object.assign({statement:null!=e?e:"",isCorrect:null!=t&&t},this.parseExample(i));r&&o.push(r)}if(Array.isArray(r))for(const e of r)o.push(e);if(0!==o.length)return o}processResponses(e,t){if(!n.Config.isOfBitType(e,a.BitType.botActionResponse)&&Array.isArray(t))return t}processBotResponse(e,t){if(n.Config.isOfBitType(e,a.BitType.botActionResponse)&&Array.isArray(t))return t}processListItems(e,t){const r=[];if(Array.isArray(e))for(const i of e){const e=Object.assign({},i);e.body&&(e.body={body:e.body,placeholders:t}),e&&r.push(e)}if(0!==r.length)return r}getResourceType(e){if(e){return s.ResourceTag.fromValue(e.type)}}processResources(e,t,r,i){const o=[];if(t&&o.push(t),n.Config.isOfBitType(e,[a.BitType.prototypeImages])&&Array.isArray(r))for(const e of r)e&&o.push(e);if(n.Config.isOfBitType(e,[a.BitType.imagesLogoGrave])&&Array.isArray(i))for(const e of i)e&&o.push(e);return o}processBody(e,t){return{body:e,placeholders:t}}processFooter(e){if(e)return{footer:e}}processReference(e){return Array.isArray(e)&&e.length>0?{reference:void 0,referenceProperty:e}:{reference:e,referenceProperty:void 0}}parseExample(e){if(null==e)return;if(!0===e)return{example:!0};if(!1===e)return{example:!1};const t=p.StringUtils.isString(e)||Array.isArray(e)?e:void 0;return t?{example:t}:{example:!!e}}}},5809:function(e,t,r){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Builder=void 0;const o=i(r(7678)),n=r(7735),a=r(2028),s=r(9888),l=r(5854),p=r(4410),u=r(6149),c=r(385),y=r(6877),g=r(6989),d=r(8903),f=r(4078),m=r(8025),T=r(955),h=r(9681),b=r(6936),B=r(4470),v=r(5533),C=r(4564);class P extends B.BaseBuilder{constructor(){super(...arguments),this.resourceBuilder=new v.ResourceBuilder}buildBitmark(e){const{bits:t,errors:r}=e,i={bits:t,errors:r};return T.ObjectUtils.removeUnwantedProperties(i),i}buildBit(e){var t,r,i,o,n,y,d,f;const h=a.Config.getBitConfig(e.bitType),b=e.bitType,B=null!==(t=c.TextFormat.fromValue(e.textFormat))&&void 0!==t?t:h.textFormatDefault,v={bitConfig:h,bitType:b,textFormat:B},P=this.buildCardNode(v,e),x=a.Config.isOfBitType(e.bitType,l.BitType.essay)?this.toAstProperty(s.PropertyConfigKey.reasonableNumOfChars,e.reasonableNumOfChars):void 0,k=Object.assign({},this.toExample(e.__isDefaultExample,e.example)),K=Object.assign(Object.assign({bitType:b,bitLevel:e.bitLevel,textFormat:B,resourceType:u.ResourceTag.fromValue(e.resourceType),isCommented:e.isCommented,id:this.toAstProperty(s.PropertyConfigKey.id,e.id),internalComment:this.toAstProperty(s.PropertyConfigKey.internalComment,e.internalComment),customerId:this.toAstProperty(s.PropertyConfigKey.customerId,e.customerId),customerExternalId:this.toAstProperty(s.PropertyConfigKey.customerExternalId,e.customerExternalId),externalId:this.toAstProperty(s.PropertyConfigKey.externalId,e.externalId),spaceId:this.toAstProperty(s.PropertyConfigKey.spaceId,e.spaceId),padletId:this.toAstProperty(s.PropertyConfigKey.padletId,e.padletId),jupyterId:this.toAstProperty(s.PropertyConfigKey.jupyterId,e.jupyterId),jupyterExecutionCount:this.toAstProperty(s.PropertyConfigKey.jupyterExecutionCount,e.jupyterExecutionCount),isPublic:this.toAstProperty(s.PropertyConfigKey.isPublic,e.isPublic),aiGenerated:this.toAstProperty(s.PropertyConfigKey.aiGenerated,e.aiGenerated),machineTranslated:this.toAstProperty(s.PropertyConfigKey.machineTranslated,e.machineTranslated),searchIndex:this.toAstProperty(s.PropertyConfigKey.searchIndex,e.searchIndex),analyticsTag:this.toAstProperty(s.PropertyConfigKey.analyticsTag,e.analyticsTag),categoryTag:this.toAstProperty(s.PropertyConfigKey.categoryTag,e.categoryTag),topicTag:this.toAstProperty(s.PropertyConfigKey.topicTag,e.topicTag),altLangTag:this.toAstProperty(s.PropertyConfigKey.altLangTag,e.altLangTag),feedbackEngine:this.toAstProperty(s.PropertyConfigKey.feedbackEngine,e.feedbackEngine),feedbackType:this.toAstProperty(s.PropertyConfigKey.feedbackType,e.feedbackType),disableFeedback:this.toAstProperty(s.PropertyConfigKey.disableFeedback,e.disableFeedback),diffTo:this.toAstProperty(s.PropertyConfigKey.diffTo,e.diffTo),diffOp:this.toAstProperty(s.PropertyConfigKey.diffOp,e.diffOp),diffRef:this.toAstProperty(s.PropertyConfigKey.diffRef,e.diffRef),diffContext:this.toAstProperty(s.PropertyConfigKey.diffContext,e.diffContext),diffTime:this.toAstProperty(s.PropertyConfigKey.diffTime,e.diffTime),path:this.toAstProperty(s.PropertyConfigKey.path,e.path),releaseVersion:this.toAstProperty(s.PropertyConfigKey.releaseVersion,e.releaseVersion),releaseKind:this.toAstProperty(s.PropertyConfigKey.releaseKind,e.releaseKind),releaseDate:this.toAstProperty(s.PropertyConfigKey.releaseDate,e.releaseDate),book:this.buildBooks(v,e.book),ageRange:this.toAstProperty(s.PropertyConfigKey.ageRange,e.ageRange),lang:this.toAstProperty(s.PropertyConfigKey.lang,e.lang),language:this.toAstProperty(s.PropertyConfigKey.language,e.language),publisher:this.toAstProperty(s.PropertyConfigKey.publisher,e.publisher),publisherName:this.toAstProperty(s.PropertyConfigKey.publisherName,e.publisherName),theme:this.toAstProperty(s.PropertyConfigKey.theme,e.theme),computerLanguage:this.toAstProperty(s.PropertyConfigKey.computerLanguage,e.computerLanguage),target:this.toAstProperty(s.PropertyConfigKey.target,e.target),slug:this.toAstProperty(s.PropertyConfigKey.slug,e.slug),tag:this.toAstProperty(s.PropertyConfigKey.tag,e.tag),reductionTag:this.toAstProperty(s.PropertyConfigKey.reductionTag,e.reductionTag),bubbleTag:this.toAstProperty(s.PropertyConfigKey.bubbleTag,e.bubbleTag),levelCEFRp:this.toAstProperty(s.PropertyConfigKey.levelCEFRp,e.levelCEFRp),levelCEFR:this.toAstProperty(s.PropertyConfigKey.levelCEFR,e.levelCEFR),levelILR:this.toAstProperty(s.PropertyConfigKey.levelILR,e.levelILR),levelACTFL:this.toAstProperty(s.PropertyConfigKey.levelACTFL,e.levelACTFL),icon:this.toAstProperty(s.PropertyConfigKey.icon,e.icon),iconTag:this.toAstProperty(s.PropertyConfigKey.iconTag,e.iconTag),colorTag:this.toAstProperty(s.PropertyConfigKey.colorTag,e.colorTag),flashcardSet:this.toAstProperty(s.PropertyConfigKey.flashcardSet,e.flashcardSet),subtype:this.toAstProperty(s.PropertyConfigKey.subtype,e.subtype),bookAlias:this.toAstProperty(s.PropertyConfigKey.bookAlias,e.bookAlias),bookDiff:this.toAstProperty(s.PropertyConfigKey.bookDiff,e.bookDiff),coverImage:this.toAstProperty(s.PropertyConfigKey.coverImage,e.coverImage),coverColor:this.toAstProperty(s.PropertyConfigKey.coverColor,e.coverColor),publications:this.toAstProperty(s.PropertyConfigKey.publications,e.publications),author:this.toAstProperty(s.PropertyConfigKey.author,e.author),subject:this.toAstProperty(s.PropertyConfigKey.subject,e.subject),date:this.toAstProperty(s.PropertyConfigKey.date,e.date),dateEnd:this.toAstProperty(s.PropertyConfigKey.dateEnd,e.dateEnd),location:this.toAstProperty(s.PropertyConfigKey.location,e.location),kind:this.toAstProperty(s.PropertyConfigKey.kind,e.kind),hasMarkAsDone:this.toAstProperty(s.PropertyConfigKey.hasMarkAsDone,e.hasMarkAsDone),processHandIn:this.toAstProperty(s.PropertyConfigKey.processHandIn,e.processHandIn),chatWithBook:this.toAstProperty(s.PropertyConfigKey.chatWithBook,e.chatWithBook),chatWithBookBrainKey:this.toAstProperty(s.PropertyConfigKey.chatWithBookBrainKey,e.chatWithBookBrainKey),action:this.toAstProperty(s.PropertyConfigKey.action,e.action),showInIndex:this.toAstProperty(s.PropertyConfigKey.showInIndex,e.showInIndex),refAuthor:this.toAstProperty(s.PropertyConfigKey.refAuthor,e.refAuthor),refBookTitle:this.toAstProperty(s.PropertyConfigKey.refBookTitle,e.refBookTitle),refPublisher:this.toAstProperty(s.PropertyConfigKey.refPublisher,e.refPublisher),refPublicationYear:this.toAstProperty(s.PropertyConfigKey.refPublicationYear,e.refPublicationYear),citationStyle:this.toAstProperty(s.PropertyConfigKey.citationStyle,e.citationStyle),blockId:this.toAstProperty(s.PropertyConfigKey.blockId,e.blockId),pageNo:this.toAstProperty(s.PropertyConfigKey.pageNo,e.pageNo),x:this.toAstProperty(s.PropertyConfigKey.x,e.x),y:this.toAstProperty(s.PropertyConfigKey.y,e.y),width:this.toAstProperty(s.PropertyConfigKey.width,e.width),height:this.toAstProperty(s.PropertyConfigKey.height,e.height),index:this.toAstProperty(s.PropertyConfigKey.index,e.index),classification:this.toAstProperty(s.PropertyConfigKey.classification,e.classification),availableClassifications:this.toAstProperty(s.PropertyConfigKey.availableClassifications,e.availableClassifications),allowedBit:this.toAstProperty(s.PropertyConfigKey.allowedBit,e.allowedBit),tableFixedHeader:this.toAstProperty(s.PropertyConfigKey.tableFixedHeader,e.tableFixedHeader),tableSearch:this.toAstProperty(s.PropertyConfigKey.tableSearch,e.tableSearch),tableSort:this.toAstProperty(s.PropertyConfigKey.tableSort,e.tableSort),tablePagination:this.toAstProperty(s.PropertyConfigKey.tablePagination,e.tablePagination),tablePaginationLimit:this.toAstProperty(s.PropertyConfigKey.tablePaginationLimit,e.tablePaginationLimit),tableHeight:this.toAstProperty(s.PropertyConfigKey.tableHeight,e.tableHeight),tableWhitespaceNoWrap:this.toAstProperty(s.PropertyConfigKey.tableWhitespaceNoWrap,e.tableWhitespaceNoWrap),tableAutoWidth:this.toAstProperty(s.PropertyConfigKey.tableAutoWidth,e.tableAutoWidth),tableResizableColumns:this.toAstProperty(s.PropertyConfigKey.tableResizableColumns,e.tableResizableColumns),tableColumnMinWidth:this.toAstProperty(s.PropertyConfigKey.tableColumnMinWidth,e.tableColumnMinWidth),quizCountItems:this.toAstProperty(s.PropertyConfigKey.quizCountItems,e.quizCountItems),quizStrikethroughSolutions:this.toAstProperty(s.PropertyConfigKey.quizStrikethroughSolutions,e.quizStrikethroughSolutions),codeLineNumbers:this.toAstProperty(s.PropertyConfigKey.codeLineNumbers,e.codeLineNumbers),codeMinimap:this.toAstProperty(s.PropertyConfigKey.codeMinimap,e.codeMinimap),stripePricingTableId:this.toAstProperty(s.PropertyConfigKey.stripePricingTableId,e.stripePricingTableId),stripePublishableKey:this.toAstProperty(s.PropertyConfigKey.stripePublishableKey,e.stripePublishableKey),thumbImage:this.toAstProperty(s.PropertyConfigKey.thumbImage,e.thumbImage),scormSource:this.toAstProperty(s.PropertyConfigKey.scormSource,e.scormSource),posterImage:this.toAstProperty(s.PropertyConfigKey.posterImage,e.posterImage),focusX:this.toAstProperty(s.PropertyConfigKey.focusX,e.focusX),focusY:this.toAstProperty(s.PropertyConfigKey.focusY,e.focusY),pointerLeft:this.toAstProperty(s.PropertyConfigKey.pointerLeft,e.pointerLeft),pointerTop:this.toAstProperty(s.PropertyConfigKey.pointerTop,e.pointerTop),listItemIndent:this.toAstProperty(s.PropertyConfigKey.listItemIndent,e.listItemIndent),backgroundWallpaper:this.toAstProperty(s.PropertyConfigKey.backgroundWallpaper,e.backgroundWallpaper),hasBookNavigation:this.toAstProperty(s.PropertyConfigKey.hasBookNavigation,e.hasBookNavigation),duration:this.toAstProperty(s.PropertyConfigKey.duration,e.duration),deeplink:this.toAstProperty(s.PropertyConfigKey.deeplink,e.deeplink),externalLink:this.toAstProperty(s.PropertyConfigKey.externalLink,e.externalLink),externalLinkText:this.toAstProperty(s.PropertyConfigKey.externalLinkText,e.externalLinkText),videoCallLink:this.toAstProperty(s.PropertyConfigKey.videoCallLink,e.videoCallLink),vendorDashboardId:this.toAstProperty(s.PropertyConfigKey.vendorDashboardId,e.vendorDashboardId),vendorSurveyId:this.toAstProperty(s.PropertyConfigKey.vendorSurveyId,e.vendorSurveyId),vendorUrl:this.toAstProperty(s.PropertyConfigKey.vendorUrl,e.vendorUrl),search:this.toAstProperty(s.PropertyConfigKey.search,e.search),list:this.toAstProperty(s.PropertyConfigKey.list,e.list),layer:this.toAstProperty(s.PropertyConfigKey.layer,e.layer),textReference:this.toAstProperty(s.PropertyConfigKey.textReference,e.textReference),isTracked:this.toAstProperty(s.PropertyConfigKey.isTracked,e.isTracked),isInfoOnly:this.toAstProperty(s.PropertyConfigKey.isInfoOnly,e.isInfoOnly),imageFirst:this.toAstProperty(s.PropertyConfigKey.imageFirst,e.imageFirst),activityType:this.toAstProperty(s.PropertyConfigKey.activityType,e.activityType),labelTrue:this.toAstProperty(s.PropertyConfigKey.labelTrue,e.labelTrue),labelFalse:this.toAstProperty(s.PropertyConfigKey.labelFalse,e.labelFalse),content2Buy:this.toAstProperty(s.PropertyConfigKey.content2Buy,e.content2Buy),mailingList:this.toAstProperty(s.PropertyConfigKey.mailingList,e.mailingList),buttonCaption:this.toAstProperty(s.PropertyConfigKey.buttonCaption,e.buttonCaption),callToActionUrl:this.toAstProperty(s.PropertyConfigKey.callToActionUrl,e.callToActionUrl),caption:this.handleJsonText(v,!0,e.caption),quotedPerson:this.toAstProperty(s.PropertyConfigKey.quotedPerson,e.quotedPerson),reasonableNumOfChars:x,resolved:this.toAstProperty(s.PropertyConfigKey.resolved,e.resolved),resolvedDate:this.toAstProperty(s.PropertyConfigKey.resolvedDate,e.resolvedDate),resolvedBy:this.toAstProperty(s.PropertyConfigKey.resolvedBy,e.resolvedBy),handInAcceptFileType:this.toAstProperty(s.PropertyConfigKey.handInAcceptFileType,e.handInAcceptFileType),handInRequirement:this.toAstProperty(s.PropertyConfigKey.handInRequirement,e.handInRequirement),handInInstruction:this.toAstProperty(s.PropertyConfigKey.handInInstruction,e.handInInstruction),maxCreatedBits:this.toAstProperty(s.PropertyConfigKey.maxCreatedBits,e.maxCreatedBits),maxDisplayLevel:this.toAstProperty(s.PropertyConfigKey.maxDisplayLevel,e.maxDisplayLevel),maxTocChapterLevel:this.toAstProperty(s.PropertyConfigKey.maxTocChapterLevel,e.maxTocChapterLevel),page:this.toAstProperty(s.PropertyConfigKey.page,e.page),productId:this.toAstProperty(s.PropertyConfigKey.productId,e.productId),product:this.toAstProperty(s.PropertyConfigKey.product,e.product),productList:this.toAstProperty(s.PropertyConfigKey.productList,e.productList),productVideo:this.toAstProperty(s.PropertyConfigKey.productVideo,e.productVideo),productVideoList:this.toAstProperty(s.PropertyConfigKey.productVideoList,e.productVideoList),productFolder:this.toAstProperty(s.PropertyConfigKey.productFolder,e.productFolder),technicalTerm:this.buildTechnicalTerm(v,e.technicalTerm),servings:this.buildServings(v,e.servings),ratingLevelStart:this.buildRatingLevelStartEnd(v,e.ratingLevelStart),ratingLevelEnd:this.buildRatingLevelStartEnd(v,e.ratingLevelEnd),ratingLevelSelected:this.toAstProperty(s.PropertyConfigKey.ratingLevelSelected,e.ratingLevelSelected),markConfig:this.buildMarkConfigs(v,e.markConfig),imageSource:this.buildImageSource(v,e.imageSource),person:this.buildPerson(v,e.person),bot:this.toAstProperty(s.PropertyConfigKey.bot,e.bot),referenceProperty:this.toAstProperty(s.PropertyConfigKey.property_reference,e.referenceProperty),title:this.handleJsonText(v,!0,e.title),subtitle:this.handleJsonText(v,!0,e.subtitle),level:m.NumberUtils.asNumber(e.level),toc:this.toAstProperty(s.PropertyConfigKey.toc,e.toc),progress:this.toAstProperty(s.PropertyConfigKey.progress,e.progress),anchor:e.anchor,reference:e.reference,referenceEnd:e.referenceEnd,revealSolutions:this.toAstProperty(s.PropertyConfigKey.revealSolutions,e.revealSolutions),item:this.handleJsonText(v,!0,e.item),lead:this.handleJsonText(v,!0,e.lead),pageNumber:this.handleJsonText(v,!0,e.pageNumber),marginNumber:this.handleJsonText(v,!0,e.marginNumber),hint:this.handleJsonText(v,!0,e.hint),instruction:this.handleJsonText(v,!0,e.instruction),partialAnswer:this.toAstProperty(s.PropertyConfigKey.partialAnswer,e.partialAnswer),sampleSolution:this.toAstProperty(s.PropertyConfigKey.property_sampleSolution,e.sampleSolution),additionalSolutions:this.toAstProperty(s.PropertyConfigKey.additionalSolutions,e.additionalSolutions)},this.toExample(e.__isDefaultExample,e.example)),{imagePlaceholder:g.ArrayUtils.asSingle(this.resourceBuilder.resourceFromResourceDataJson(v,u.ResourceTag.image,null===(r=e.imagePlaceholder)||void 0===r?void 0:r.image)),resources:g.ArrayUtils.asArray(this.resourceBuilder.resourceFromResourceJson(v,e.resources)),body:this.buildBody(v,e.body),cardNode:P,footer:this.buildFooter(v,e.footer),extraProperties:this.parseExtraProperties(e.extraProperties),markup:e.markup,parser:e.parser,__isDefaultExample:null!==(i=e.__isDefaultExample)&&void 0!==i&&i});return a.Config.isOfBitType(K.bitType,l.BitType.interview)&&this.pushDownTree(v,void 0,void 0,P,"questions",s.PropertyConfigKey.reasonableNumOfChars,e.reasonableNumOfChars),a.Config.isOfBitType(K.bitType,l.BitType.feedback)&&this.pushDownTree(v,void 0,void 0,P,["feedbacks","reason"],s.PropertyConfigKey.reasonableNumOfChars,e.reasonableNumOfChars),this.pushDownTree(v,[K.body,...null!==(n=null===(o=null==P?void 0:P.cardBits)||void 0===o?void 0:o.map((e=>e.body)))&&void 0!==n?n:[]],[p.BodyBitType.gap],void 0,void 0,s.PropertyConfigKey.isCaseSensitive,null===(y=e.isCaseSensitive)||void 0===y||y),this.pushDownTree(v,void 0,void 0,P,"pairs",s.PropertyConfigKey.isCaseSensitive,null===(d=e.isCaseSensitive)||void 0===d||d),this.pushDownTree(v,void 0,void 0,P,["matrix","cells"],s.PropertyConfigKey.isCaseSensitive,null===(f=e.isCaseSensitive)||void 0===f||f),this.pushExampleDownTree(v,K.body,P,K.__isDefaultExample,k.example),this.setDefaultBitValues(K),this.setIsExampleFlags(K),this.addVersionToParserInfo(K),T.ObjectUtils.removeUnwantedProperties(K,{ignoreAllFalse:!0,ignoreUndefined:["example"],ignoreEmptyArrays:["item","lead","pageNumber","marginNumber","hint","instruction"]}),C.NodeValidator.validateBit(K)}buildBooks(e,t){if(h.StringUtils.isString(t))return t;if(!Array.isArray(t))return;const r=t.map((t=>this.buildBook(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildBook(e,t){var r,i,o;if(!t)return;const n={book:null!==(r=t.book)&&void 0!==r?r:"",reference:null!==(i=t.reference)&&void 0!==i?i:"",referenceEnd:null!==(o=t.referenceEnd)&&void 0!==o?o:void 0};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyString:["book","reference"]}),n}buildFeedbackChoices(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildFeedbackChoice(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildFeedbackChoice(e,t){var r;if(!t)return;const i=Object.assign({choice:null!==(r=t.choice)&&void 0!==r?r:"",requireReason:!!t.requireReason,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"]}),i}buildFeedbackReason(e,t){var r,i;if(!t)return;const o=this.handleJsonText(e,!0,"true"),n=Object.assign(Object.assign({text:null!==(r=t.text)&&void 0!==r?r:"",reasonableNumOfChars:null!==(i=t.reasonableNumOfChars)&&void 0!==i?i:void 0,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,o)),{__textAst:t.__textAst});return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example","reasonableNumOfChars"]}),n}buildChoices(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildChoice(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildChoice(e,t){var r;if(!t)return;const i=Object.assign({choice:null!==(r=t.choice)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"]}),i}buildResponses(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildResponse(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildResponse(e,t){var r;if(!t)return;const i=Object.assign({response:null!==(r=t.response)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"]}),i}buildBotResponses(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.botResponse(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}botResponse(e,t){var r,i,o;if(!t)return;const n={response:null!==(r=t.response)&&void 0!==r?r:"",reaction:null!==(i=t.reaction)&&void 0!==i?i:"",feedback:null!==(o=t.feedback)&&void 0!==o?o:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint)};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreEmptyString:["response","reaction","feedback"],ignoreAllFalse:!0,ignoreEmptyArrays:["item"],ignoreUndefined:["example"]}),n}buildFeedbacks(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildFeedback(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildFeedback(e,t){if(!t)return;let r,i;if(!t.choices)return;r=this.buildFeedbackChoices(e,t.choices),t.reason&&(i=this.buildFeedbackReason(e,t.reason));const o={item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),choices:r,reason:i};return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"]}),o}buildQuizzes(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildQuiz(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildQuiz(e,t){if(!t)return;const r=Object.assign({},this.toExample(t.__isDefaultExample,t.__defaultExample));let i,o;if(t.choices)i=this.buildChoices(e,t.choices),this.pushExampleDownTreeBoolean(e,t.__isDefaultExample,r.example,!0,i);else{if(!t.responses)return;o=this.buildResponses(e,t.responses),this.pushExampleDownTreeBoolean(e,t.__isDefaultExample,r.example,!1,o)}const n={item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isExample:!!t.__defaultExample,choices:i,responses:o};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"]}),n}buildHeading(e,t){var r,i,o;if(!t)return;if(null==t.forKeys)return;const n={forKeys:null!==(r=t.forKeys)&&void 0!==r?r:"",forValues:null!==(o=null!==(i=t.forValues)&&void 0!==i?i:t.__forValuesDefault)&&void 0!==o?o:""};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyString:["forKeys","forValues"],ignoreEmptyArrays:["forValues"]}),n}buildPairs(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildPair(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildPair(e,t){var r,i;if(!t)return;const o=Array.isArray(t.__valuesAst)&&t.__valuesAst.length>0?t.__valuesAst[0]:null,n=this.resourceBuilder.resourceFromResourceJson(e,t.keyAudio),a=this.resourceBuilder.resourceFromResourceJson(e,t.keyImage),s=Object.assign(Object.assign({key:null!==(r=t.key)&&void 0!==r?r:"",keyAudio:n,keyImage:a,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isCaseSensitive:t.isCaseSensitive},this.toExample(t.__isDefaultExample,t.example,o)),{values:null!==(i=t.values)&&void 0!==i?i:[],__valuesAst:t.__valuesAst});return T.ObjectUtils.removeUnwantedProperties(s,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction","values"],ignoreUndefined:["example","isCaseSensitive"]}),s}buildMatricies(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildMatrix(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildMatrix(e,t){var r,i,o;if(!t)return;let n=!1;for(const e of null!==(r=t.cells)&&void 0!==r?r:[])t.__isDefaultExample&&!e.isExample&&(e.isExample=!0),n=!!e.isExample||n;const a={key:null!==(i=t.key)&&void 0!==i?i:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isExample:n,cells:(null!==(o=t.cells)&&void 0!==o?o:[]).map((t=>this.buildMatrixCell(e,t))).filter((e=>null!=e))};return T.ObjectUtils.removeUnwantedProperties(a,{ignoreAllFalse:!0,ignoreEmptyArrays:["hint","item","cells"],ignoreUndefined:["isCaseSensitive"]}),a}buildMatrixCell(e,t){var r;if(!t)return;const i=Array.isArray(t.__valuesAst)&&t.__valuesAst.length>0?t.__valuesAst[0]:null,o=Object.assign(Object.assign({values:null!==(r=t.values)&&void 0!==r?r:[],item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isCaseSensitive:t.isCaseSensitive},this.toExample(t.__isDefaultExample,t.example,i)),{__valuesAst:t.__valuesAst});return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreEmptyArrays:["instruction","item","values"],ignoreUndefined:["example","isCaseSensitive"]}),o}buildPronunciationTable(e,t){var r;if(!t)return;return{data:(null!==(r=t.data)&&void 0!==r?r:[]).map((t=>(null!=t?t:[]).map((t=>{const r=this.resourceBuilder.resourceFromResourceJson(e,t.audio);return{title:this.handleJsonText(e,!0,t.title),body:this.handleJsonText(e,!0,t.body),audio:r}}))))}}buildTable(e,t){var r,i;if(!t)return;return{columns:(null!==(r=t.columns)&&void 0!==r?r:[]).map((t=>this.handleJsonText(e,!0,t))),data:(null!==(i=t.data)&&void 0!==i?i:[]).map((t=>(null!=t?t:[]).map((t=>this.handleJsonText(e,!0,t)))))}}buildQuestions(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildQuestion(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildQuestion(e,t){var r,i,o,n,a;if(!t)return;const s=t.__sampleSolutionAst,l=Object.assign(Object.assign({question:null!==(r=t.question)&&void 0!==r?r:"",partialAnswer:null!==(i=t.partialAnswer)&&void 0!==i?i:"",sampleSolution:null!==(o=t.sampleSolution)&&void 0!==o?o:"",additionalSolutions:null!==(n=t.additionalSolutions)&&void 0!==n?n:void 0,reasonableNumOfChars:null!==(a=t.reasonableNumOfChars)&&void 0!==a?a:void 0,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,s)),{__sampleSolutionAst:t.__sampleSolutionAst});return T.ObjectUtils.removeUnwantedProperties(l,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"],ignoreEmptyString:["question","partialAnswer","sampleSolution"]}),l}buildIngredients(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildIngredient(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildIngredient(e,t){var r,i,o,n,a,s,l,p;if(!t)return;const u={title:null!==(r=t.title)&&void 0!==r?r:"",checked:null!==(i=t.checked)&&void 0!==i&&i,item:null!==(o=t.item)&&void 0!==o?o:"",quantity:null!==(n=t.quantity)&&void 0!==n?n:0,unit:null!==(a=t.unit)&&void 0!==a?a:"",unitAbbr:null!==(s=t.unitAbbr)&&void 0!==s?s:"",decimalPlaces:null!==(l=t.decimalPlaces)&&void 0!==l?l:1,disableCalculation:null!==(p=t.disableCalculation)&&void 0!==p&&p};return T.ObjectUtils.removeUnwantedProperties(u,{ignoreAllFalse:!0,ignoreEmptyString:["item","unit"]}),u}buildBody(e,t){if(!t)return;let r;const i=[],a=t.placeholders,s=t.bodyString,{textFormat:l}=e,u=()=>{var s;let u,c=t.body;const g={};if(h.StringUtils.isString(t.body)?(u=(null!==(s=t.body)&&void 0!==s?s:"").trim(),c=[]):Array.isArray(t.body)||(c=[]),a)for(const[e,t]of Object.entries(a))g[e]=t;if(u){u=n.Breakscape.breakscape(u,{textFormat:l,textLocation:y.TextLocation.body,v2:!0});let e=0;const t=[];for(const[r,i]of Object.entries(g))if(u){const o=`[!${e}]`;u=u.replace(`${r}`,o),t.push(i),e++}c=this.textParser.toAst(u,{textFormat:l,isProperty:!1});const r=e=>{for(let i=0,o=e.length;i<o;i++){const o=e[i];if("bit"===o.type){const r=o.index;null!=t[r]&&(e[i]=t[r])}else o.content&&r(o.content)}};r(c)}c=(0,o.default)(c),this.textParser.walkBodyBits(c,((t,r,o)=>{let n;switch(o.type){case p.BodyBitType.gap:n=this.buildGap(e,o);break;case p.BodyBitType.mark:n=this.buildMark(e,o);break;case p.BodyBitType.select:n=this.buildSelect(e,o);break;case p.BodyBitType.highlight:n=this.buildHighlight(e,o)}null!=n&&(t[r]=n,i.push(n))})),r=c,r.__tag="text"},g=l===c.TextFormat.bitmarkMinusMinus||l===c.TextFormat.bitmarkPlusPlus;l===c.TextFormat.json?(()=>{if("string"==typeof t.body)try{r=JSON.parse(t.body)}catch(e){r=null}else r=t.body})():g?u():r=t.body;return{body:r,bodyBits:i,bodyString:s}}buildFooter(e,t){if(!t)return;return{footer:this.handleJsonText(e,!1,t.footer)}}buildGap(e,t){var r;if(!t)return;const i=Array.isArray(t.__solutionsAst)&&t.__solutionsAst.length>0?t.__solutionsAst[0]:null;t=this.bodyBitCopyFromAttrs(t);const o=Object.assign(Object.assign({type:p.BodyBitType.gap,solutions:null!==(r=t.solutions)&&void 0!==r?r:[],item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isCaseSensitive:t.isCaseSensitive},this.toExample(t.__isDefaultExample,t.example,i)),{__solutionsAst:t.__solutionsAst,attrs:{}});return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example","isCaseSensitive"]}),o}buildMarkConfigs(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildMarkConfig(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildMarkConfig(e,t){var r,i,o;if(!t)return;const n={mark:null!==(r=t.mark)&&void 0!==r?r:"unknown",color:null!==(i=t.color)&&void 0!==i?i:"",emphasis:null!==(o=t.emphasis)&&void 0!==o?o:""};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllEmptyString:!0}),n}buildMark(e,t){var r,i;if(!t)return;t=this.bodyBitCopyFromAttrs(t);const o=Object.assign(Object.assign({type:p.BodyBitType.mark,solution:null!==(r=t.solution)&&void 0!==r?r:"",mark:null!==(i=t.mark)&&void 0!==i?i:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0)),{attrs:{}});return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example"],ignoreEmptyString:["solution","mark"]}),o}buildSelect(e,t){var r,i,o;if(!t)return;t=this.bodyBitCopyFromAttrs(t);const n=Object.assign(Object.assign({type:p.BodyBitType.select,options:null!==(r=this.buildSelectOptions(e,t.options))&&void 0!==r?r:[],prefix:null!==(i=t.prefix)&&void 0!==i?i:"",postfix:null!==(o=t.postfix)&&void 0!==o?o:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(!1,void 0,void 0)),{__hintString:t.__hintString,__instructionString:t.__instructionString,attrs:{}});return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreEmptyString:["prefix","postfix"]}),n}buildSelectOptions(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildSelectOption(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildSelectOption(e,t){var r;if(!t)return;const i=Object.assign({text:null!==(r=t.text)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example"]}),i}buildHighlight(e,t){var r,i,o;if(!t)return;t=this.bodyBitCopyFromAttrs(t);const n=Object.assign(Object.assign({type:p.BodyBitType.highlight,texts:null!==(r=this.buildHighlightTexts(e,t.texts))&&void 0!==r?r:[],prefix:null!==(i=t.prefix)&&void 0!==i?i:"",postfix:null!==(o=t.postfix)&&void 0!==o?o:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(!1,void 0,void 0)),{attrs:{}});return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreEmptyString:["prefix","postfix"]}),n}buildHighlightTexts(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildHighlightText(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildHighlightText(e,t){var r;if(!t)return;const i=Object.assign({text:null!==(r=t.text)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,isHighlighted:!!t.isHighlighted,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example"]}),i}buildFlashcards(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildFlashcard(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildFlashcard(e,t){var r;if(!t)return;const i=Object.assign({question:this.buildTextAndIcon(e,t.question),answer:this.buildTextAndIcon(e,t.answer),alternativeAnswers:(null!==(r=t.alternativeAnswers)&&void 0!==r?r:[]).map((t=>this.buildTextAndIcon(e,t))).filter((e=>null!=e)),item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["question","answer","alternativeAnswers","item","hint","instruction"],ignoreUndefined:["example"]}),i}buildDefinitionList(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildDefinitionListItem(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildDefinitionListItem(e,t){var r;if(!t)return;const{bitType:i}=e,o=a.Config.isOfBitType(i,[l.BitType.metaSearchDefaultTerms]),n=Object.assign({term:this.buildTextAndIcon(e,t.term,o),definition:this.buildTextAndIcon(e,t.definition,o),alternativeDefinitions:(null!==(r=t.alternativeDefinitions)&&void 0!==r?r:[]).map((t=>this.buildTextAndIcon(e,t,o))).filter((e=>null!=e)),item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0));return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyArrays:["question","answer","alternativeDefinitions","item","hint","instruction"],ignoreUndefined:["example"]}),n}buildTextAndIcon(e,t,r=!1){const i=this.resourceBuilder.resourceFromResourceJson(e,null==t?void 0:t.icon);let o=this.handleJsonText(e,!0,null==t?void 0:t.text);r&&(o=this.textGenerator.generateSync(o,c.TextFormat.text,y.TextLocation.body,{noBreakscaping:!0}).trim());const n={text:o,icon:i};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreEmptyArrays:["text"],ignoreUndefined:["icon"]}),n}buildStatements(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildStatement(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildStatement(e,t){var r;if(!t)return;const i=Object.assign({statement:null!==(r=t.statement)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreUndefined:["example"]}),i}buildImageSource(e,t){if(!t)return;const{url:r,mockupId:i,size:o,format:n,trim:a}=t,s={url:null!=r?r:"",mockupId:null!=i?i:"",size:null!=o?o:null,format:null!=n?n:null,trim:f.BooleanUtils.isBoolean(a)?a:null};return T.ObjectUtils.removeUnwantedProperties(s,{ignoreFalse:["trim"],ignoreEmptyString:["url","mockupId"],ignoreAllUndefined:!0}),s}buildPerson(e,t){if(!t)return;const{name:r,title:i,avatarImage:o}=t,n={name:null!=r?r:"",title:null!=i?i:void 0,avatarImage:this.resourceBuilder.resourceFromResourceJson(e,o)};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreEmptyString:["name"],ignoreAllUndefined:!0}),n}buildTechnicalTerm(e,t){if(!t)return;const{technicalTerm:r,lang:i}=t,o={technicalTerm:null!=r?r:"",lang:null!=i?i:""};return T.ObjectUtils.removeUnwantedProperties(o,{ignoreEmptyString:["technicalTerm"]}),o}buildServings(e,t){if(!t)return;const{servings:r,unit:i,unitAbbr:o,decimalPlaces:n,disableCalculation:a,hint:s}=t,l={servings:null!=r?r:0,unit:null!=i?i:"",unitAbbr:null!=o?o:"",decimalPlaces:null!=n?n:1,disableCalculation:null!=a&&a,hint:null!=s?s:""};return T.ObjectUtils.removeUnwantedProperties(l,{ignoreEmptyString:["servings","unit"]}),l}buildRatingLevelStartEnd(e,t){if(!t)return;const{level:r,label:i}=t,o={level:null!=r?r:0,label:this.handleJsonText(e,!0,i)};return T.ObjectUtils.removeUnwantedProperties(o,{}),o}buildCardBits(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildCardBit(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildCardBit(e,t){if(!t)return;const{bitType:r,textFormat:i}=e,o=this.buildBit(Object.assign(Object.assign({},t),{bitType:r,textFormat:i}));return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreUndefined:["example"]}),C.NodeValidator.validateCardBit(o)}buildCardNode(e,t){var r;const i={heading:this.buildHeading(e,t.heading),questions:this.buildQuestions(e,t.questions),elements:t.elements,flashcards:this.buildFlashcards(e,t.flashcards),definitions:this.buildDefinitionList(e,null!==(r=t.definitions)&&void 0!==r?r:t.legend),statement:this.buildStatement(e,t.statement),statements:this.buildStatements(e,t.statements),choices:this.buildChoices(e,t.choices),responses:this.buildResponses(e,t.responses),feedbacks:this.buildFeedbacks(e,t.feedbacks),quizzes:this.buildQuizzes(e,t.quizzes),pairs:this.buildPairs(e,t.pairs),matrix:this.buildMatricies(e,t.matrix),pronunciationTable:this.buildPronunciationTable(e,t.pronunciationTable),table:this.buildTable(e,t.table),botResponses:this.buildBotResponses(e,t.botResponses),ingredients:this.buildIngredients(e,t.ingredients),cardBits:this.buildCardBits(e,t.cardBits)};return T.ObjectUtils.removeUnwantedProperties(i),Object.keys(i).length>0?i:void 0}bodyBitCopyFromAttrs(e){const t=Object.assign({},e);if(e.attrs)for(const[r,i]of Object.entries(e.attrs))t[r]=i;return t}pushExampleDownTree(e,t,r,i,o){if(i||null!=o){if(r){if(this.pushExampleDownTreeString(e,i,o,r.pairs),this.pushExampleDownTreeBoolean(e,i,o,!1,r.flashcards),this.pushExampleDownTreeBoolean(e,i,o,!1,r.definitions),this.pushExampleDownTreeBoolean(e,i,o,!0,r.choices),this.pushExampleDownTreeBoolean(e,i,o,!1,r.responses,r.statements,r.statement),r.quizzes)for(const t of r.quizzes)this.pushExampleDownTreeBoolean(e,i,o,!0,t.choices),this.pushExampleDownTreeBoolean(e,i,o,!1,t.responses);if(r.matrix)for(const t of r.matrix)this.pushExampleDownTreeString(e,i,o,t.cells)}t&&this.pushExampleDownTreeBodyBits(e,i,o,t)}}pushExampleDownTreeBoolean(e,t,r,i,...o){if((t||null!=r)&&Array.isArray(o))for(const e of o)if(e){const o=Array.isArray(e)?e:[e];d.BitUtils.fillBooleanExample(o,t,r,i)}}pushExampleDownTreeString(e,t,r,...i){if((t||r)&&Array.isArray(i))for(const o of i)if(o){const i=Array.isArray(o)?o:[o];d.BitUtils.fillStringExample(e.textFormat,i,t,r,!1)}}pushExampleDownTreeBodyBits(e,t,r,i){if(!t&&!r)return;const o=this.textParser.extractBodyBits(null==i?void 0:i.body);for(const i of o)if(i)switch(i.type){case p.BodyBitType.gap:{const o=i;d.BitUtils.fillStringExample(e.textFormat,[o],t,r,!1);break}case p.BodyBitType.mark:{const e=i;d.BitUtils.fillBooleanExample([e],t,r,!1);break}case p.BodyBitType.select:{const e=i;d.BitUtils.fillBooleanExample(e.options,t,r,!0);break}case p.BodyBitType.highlight:{const e=i;d.BitUtils.fillBooleanExample(e.texts,t,r,!0);break}}}pushDownTree(e,t,r,i,o,n,a){if(void 0!==a){if(i&&o){Array.isArray(o)||(o=[o]);const e=T.ObjectUtils.flatMapPath(i,o);for(const t of e)null==t[n]&&(t[n]=a)}if(t){const e=Array.isArray(t)?t:[t];for(const t of e)if(t&&t.body&&r){const e=this.textParser.extractBodyBits(t.body);if(r&&e&&e.length>0)for(const t of e)if(t&&-1!==r.indexOf(t.type)){const e=t;null==e[n]&&(e[n]=a)}}}}}parseExtraProperties(e){if(!e)return;const t=Object.entries(e);if(0===t.length)return;const r={};for(const[e,i]of t)r[e]=g.ArrayUtils.asArray(i)||[i];return r}setIsExampleFlags(e){var t,r,i,o,n,a,s,l,u,c,y,g,d,f;const m=t=>!!t&&(t.isExample||null!=t.example?(t.isExample=!0,e.isExample=!0):t.isExample=t===e&&!!e.isExample,t.isExample),{body:T,cardNode:h}=e,b=this.textParser.extractBodyBits(null==T?void 0:T.body);for(const e of b)switch(e.type){case p.BodyBitType.gap:case p.BodyBitType.mark:m(e);break;case p.BodyBitType.select:{const t=e;let r=!1;for(const e of t.options)r=!!m(e)||r;t.isExample=r;break}case p.BodyBitType.highlight:{const t=e;let r=!1;for(const e of t.texts)r=!!m(e)||r;t.isExample=r;break}}if(h){for(const e of null!==(t=h.flashcards)&&void 0!==t?t:[])m(e);for(const e of null!==(r=h.definitions)&&void 0!==r?r:[])m(e);for(const e of null!==(i=h.pairs)&&void 0!==i?i:[])m(e);for(const e of null!==(o=h.matrix)&&void 0!==o?o:[]){let t=!1;for(const r of null!==(n=e.cells)&&void 0!==n?n:[])t=!!m(r)||t;e.isExample=t}for(const e of null!==(a=h.quizzes)&&void 0!==a?a:[]){let t=!1;for(const r of null!==(s=e.responses)&&void 0!==s?s:[])t=!!m(r)||t;for(const r of null!==(l=e.choices)&&void 0!==l?l:[])t=!!m(r)||t;e.isExample=t}for(const e of null!==(u=h.responses)&&void 0!==u?u:[])m(e);for(const e of null!==(c=h.choices)&&void 0!==c?c:[])m(e);for(const e of null!==(y=h.statements)&&void 0!==y?y:[])m(e);m(h.statement);for(const e of null!==(g=h.questions)&&void 0!==g?g:[])m(e)}m(e.statement);for(const t of null!==(d=e.responses)&&void 0!==d?d:[])m(t);for(const t of null!==(f=e.choices)&&void 0!==f?f:[])m(t);m(e)}setDefaultBitValues(e){switch(e.bitType){case l.BitType.articleAi:case l.BitType.noteAi:case l.BitType.summaryAi:e.aiGenerated=this.toAstProperty(s.PropertyConfigKey.aiGenerated,!0)}}addVersionToParserInfo(e){var t;const r=null!==(t=e.parser)&&void 0!==t?t:{};r.version=b.env.appVersion.full,e.parser=r}}t.Builder=P},5814:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardSetConfig=void 0;t.CardSetConfig=class{constructor(e,t){this.configKey=e,this.variants=t}toString(e){const t=Object.assign({},e);let r="",i=0,o=0;for(const e of this.variants){for(const n of e)r+=`[Card - Side ${i}, Variant ${o}]`,r+=`\n${n.toString(t)}`,o++;i++}return r}}},5837:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GROUPS=void 0;const i=r(7112),o=r(6915),n=r(9888),a=r(5051),s=r(7797),l=r(5512),p=r(3778),u=r(6149),c={[i.GroupConfigKey.group_standardAllBits]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.id,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.customerId},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.externalId,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.aiGenerated},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.machineTranslated},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.searchIndex,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.analyticsTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.categoryTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.topicTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.altLangTag},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.feedbackEngine},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.feedbackType},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.disableFeedback},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffTo},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffOp},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffRef},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffContext},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffTime},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.ageRange,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.lang},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.publisher,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.publisherName,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.theme,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.target,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.tag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reductionTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.bubbleTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelCEFRp},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelCEFR},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelILR},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelACTFL},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.icon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.iconTag},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.colorTag,maxCount:p.Count.infinity},{type:l.BitTagType.tag,configKey:s.TagConfigKey.anchor},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.search},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.showInIndex},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.layer,maxCount:p.Count.infinity}]},[i.GroupConfigKey.group_standardItemLeadInstructionHint]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.itemLead,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.itemLead,maxCount:3}]},{type:l.BitTagType.tag,configKey:s.TagConfigKey.instruction},{type:l.BitTagType.tag,configKey:s.TagConfigKey.hint}]},[i.GroupConfigKey.group_standardExample]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.example}]},[i.GroupConfigKey.group_standardTags]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardAllBits},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]},[i.GroupConfigKey.group_imageSource]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.imageSource,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.mockupId},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.size},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.format},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.trim}]}]},[i.GroupConfigKey.group_technicalTerm]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.technicalTerm,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.lang}]}]},[i.GroupConfigKey.group_person]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.person,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_title},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImage}]},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.partner,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_title},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImage}]}]},[i.GroupConfigKey.group_gap]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.gap,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.gap,maxCount:p.Count.infinity},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}]}]},[i.GroupConfigKey.group_trueFalse]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:p.Count.infinity},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:p.Count.infinity},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:p.Count.infinity},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:p.Count.infinity},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]}]},[i.GroupConfigKey.group_markConfig]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.markConfig,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.color},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.emphasis}]}]},[i.GroupConfigKey.group_mark]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.tag_mark,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_mark},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]}]},[i.GroupConfigKey.group_bookCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.language,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.customerExternalId,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.spaceId,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.kind},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.hasMarkAsDone},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.processHandIn},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isPublic},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.chatWithBook},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.chatWithBookBrainKey},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title,maxCount:2},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.subtype,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.coverImage,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.coverColor},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.subject,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.author,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.publications,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.maxTocChapterLevel}]},[i.GroupConfigKey.group_learningPathCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.action},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.date},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.dateEnd},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.location},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.list,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.textReference},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isTracked},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isInfoOnly},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.deeplink},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.book,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.tag_reference,maxCount:2}]}]},[i.GroupConfigKey.group_quizCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.revealSolutions}]},[i.GroupConfigKey.group_resourceBitTags]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.imagePlaceholder,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}],maxCount:1}]},[i.GroupConfigKey.group_resourceCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.license},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.copyright},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.caption},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.showInIndex},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.search}]},[i.GroupConfigKey.group_resourceImageCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src1x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src2x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src3x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src4x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.alt},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.zoomDisabled}]},[i.GroupConfigKey.group_resourceAudioCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.mute},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.autoplay}]},[i.GroupConfigKey.group_resourceVideoCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.mute},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.autoplay},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.allowSubtitles},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.showSubtitles},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.alt},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.posterImage,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src1x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src2x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src3x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src4x}]},[i.GroupConfigKey.group_resourceIcon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.icon,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImage]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.image,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImagePortrait]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imagePortrait,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImageLandscape]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imageLandscape,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImageEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imageEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImageLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imageLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceAudio]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audio,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudioCommon}]}]},[i.GroupConfigKey.group_resourceAudioEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audioEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudioCommon}]}]},[i.GroupConfigKey.group_resourceAudioLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audioLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudioCommon}]}]},[i.GroupConfigKey.group_resourceVideo]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.video,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceVideoEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.videoEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceVideoLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.videoLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceStillImageFilmEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.stillImageFilmEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceStillImageFilmLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.stillImageFilmLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceArticle]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.article,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceArticleEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.articleEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceArticleLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.articleLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocument]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.document,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocumentEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.documentEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocumentLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.documentLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocumentDownload]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.documentDownload,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceAppLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.appLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceWebsiteLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.websiteLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceStillImageFilm]:{type:o.GroupConfigType.comboResource,comboResourceType:u.ResourceTag.stillImageFilm,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImage,maxCount:1,minCount:1},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudio,maxCount:1,minCount:1}]},[i.GroupConfigKey.group_resourceImageResponsive]:{type:o.GroupConfigType.comboResource,comboResourceType:u.ResourceTag.imageResponsive,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImagePortrait,maxCount:1,minCount:1},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageLandscape,maxCount:1,minCount:1}]}};t.GROUPS=c},5854:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitType=void 0;const i=(0,r(4718).superenum)({_error:"_error",_comment:"_comment",_standard:"_standard",aiPrompt:"ai-prompt",anchor:"anchor",appAiPrompt:"app-ai-prompt",appBitmarkFromEditor:"app-bitmark-from-editor",appBitmarkFromJavascript:"app-bitmark-from-javascript",appCodeCell:"app-code-cell",appCodeEditor:"app-code-editor",appCodeIde:"app-code-ide",appCreateBitsFromImage:"app-create-bits-from-image",appFlashcards:"app-flashcards",appFlashcardsLearn:"app-flashcards-learn",appFlashcardsQuiz:"app-flashcards-quiz",appGetScreenshot:"app-get-screenshot",appLink:"app-link",article:"article",articleAi:"article-ai",articleAlt:"article-alt",articleAttachment:"article-attachment",articleEmbed:"article-embed",articleLink:"article-link",articleResponsive:"article-responsive",articleResponsiveAlt:"article-responsive-alt",assignment:"assignment",assignmentList:"assignment-list",audio:"audio",audioEmbed:"audio-embed",audioLink:"audio-link",audioTranscript:"audio-transcript",bitAlias:"bit-alias",bitBookEnding:"bit-book-ending",bitBookSummary:"bit-book-summary",bitmarkExample:"bitmark-example",blogArticle:"blog-article",book:"book",bookAcknowledgements:"book-acknowledgements",bookAddendum:"book-addendum",bookAfterword:"book-afterword",bookAlias:"book-alias",bookAppendix:"book-appendix",bookArticle:"book-article",bookAutherBio:"book-author-bio",bookBibliography:"book-bibliography",bookClose:"book-close",bookComingSoon:"book-coming-soon",bookConclusion:"book-conclusion",bookCopyright:"book-copyright",bookCopyrightPermissions:"book-copyright-permissions",bookDedication:"book-dedication",bookDiff:"book-diff",bookEndnotes:"book-endnotes",bookEpigraph:"book-epigraph",bookEpilogue:"book-epilogue",bookForword:"book-foreword",bookFrontispiece:"book-frontispiece",bookImprint:"book-imprint",bookIncitingIncident:"book-inciting-incident",bookIntroduction:"book-introduction",bookLink:"book-link",bookLinkNext:"book-link-next",bookLinkPrev:"book-link-prev",bookListOfContributors:"book-list-of-contributors",bookNotes:"book-notes",bookPostscript:"book-postscript",bookPreface:"book-preface",bookPrologue:"book-prologue",bookReadMore:"book-read-more",bookReference:"book-reference",bookReferenceList:"book-reference-list",bookRequestForABookReview:"book-request-for-a-book-review",bookSummary:"book-summary",bookTeaser:"book-teaser",bookTitle:"book-title",botActionAnnounce:"bot-action-announce",botActionRatingNumber:"bot-action-rating-number",botActionRemind:"bot-action-remind",botActionResponse:"bot-action-response",botActionSave:"bot-action-save",botActionSend:"bot-action-send",botActionTrueFalse:"bot-action-true-false",botInterview:"bot-interview",browserImage:"browser-image",bug:"bug",bugAlt:"bug-alt",bugCollapsible:"bug-collapsible",buttonCopyText:"button-copy-text",callToAction:"call-to-action",callToActionBookNow:"call-to-action-book-now",callToActionContact:"call-to-action-contact",callToActionCreateAccount:"call-to-action-create-account",callToActionDownload:"call-to-action-download",callToActionGetNow:"call-to-action-get-now",callToActionGetOffer:"call-to-action-get-offer",callToActionJoin:"call-to-action-join",callToActionLearnMore:"call-to-action-learn-more",callToActionMail:"call-to-action-mail",callToActionSeeMore:"call-to-action-see-more",callToActionShopNow:"call-to-action-shop-now",callToActionStartNow:"call-to-action-start-now",callToActionSubscribe:"call-to-action-subscribe",callToActionWatch:"call-to-action-watch",card1:"card-1",chapter:"chapter",chapterSubjectMatter:"chapter-subject-matter",chat:"chat",checklist:"checklist",cloze:"cloze",clozeAndMultipleChoiceText:"cloze-and-multiple-choice-text",clozeInstructionGrouped:"cloze-instruction-grouped",clozeList:"cloze-list",clozeSeveral:"cloze-several",clozeSolutionGrouped:"cloze-solution-grouped",coachAudioTranscript:"coach-audio-transcript",coachCallToActionChecklist:"coach-call-to-action-checklist",coachCallToActionCloze:"coach-call-to-action-cloze",coachCallToActionClozeAndMultipleChoiceText:"coach-call-to-action-cloze-and-multiple-choice-text",coachCallToActionEssay:"coach-call-to-action-essay",coachCallToActionMultipleChoiceText:"coach-call-to-action-multiple-choice-text",coachHomeRules:"coach-home-rules",coachSelfReflectionCloze:"coach-self-reflection-cloze",coachSelfReflectionEssay:"coach-self-reflection-essay",coachSelfReflectionMultipleChoice:"coach-self-reflection-multiple-choice",coachSelfReflectionMultipleChoice1:"coach-self-reflection-multiple-choice-1",coachSelfReflectionMultipleChoiceText:"coach-self-reflection-multiple-choice-text",coachSelfReflectionMultipleResponse:"coach-self-reflection-multiple-response",coachSelfReflectionMultipleResponse1:"coach-self-reflection-multiple-response-1",coachSelfReflectionRating:"coach-self-reflection-rating",coachVideoTranscript:"coach-video-transcript",code:"code",codeRuntime:"code-runtime",collapsible:"collapsible",conclusion:"conclusion",conclusionAlt:"conclusion-alt",consoleLog:"console-log",container:"container",containerAccordionTabs:"container-accordion-tabs",containerBits2:"container-bits-2",containerCards:"container-cards",containerCarousel:"container-carousel",containerCookRecipe:"container-cook-recipe",containerFolder:"container-folder",containerFolderAll:"container-folder-all",containerGallery:"container-gallery",containerGrid:"container-grid",containerGroup:"container-group",containerNewsArticle:"container-news-article",containerNowrap:"container-nowrap",containerNowrapStretch:"container-nowrap-stretch",containerPreview:"container-preview",containerScroller:"container-scroller",containerSlides:"container-slides",containerStack:"container-stack",containerTabs:"container-tabs",containerWrap:"container-wrap",conversationLeft1:"conversation-left-1",conversationLeft1Scream:"conversation-left-1-scream",conversationLeft1Thought:"conversation-left-1-thought",conversationRight1:"conversation-right-1",conversationRight1Scream:"conversation-right-1-scream",conversationRight1Thought:"conversation-right-1-thought",cookArrangement:"cook-arrangement",cookIngredients:"cook-ingredients",cookInsert:"cook-insert",cookPersonalRecommendation:"cook-personal-recommendation",cookPlate:"cook-plate",cookPracticeAdvise:"cook-practice-advise",cookPreparation:"cook-preparation",cookRecommendation:"cook-recommendation",cookRemark:"cook-remark",cookSideDish:"cook-side-dish",cookSideDrink:"cook-side-drink",cookStep:"cook-step",cookTimer:"cook-timer",cookVariation:"cook-variation",correction:"correction",danger:"danger",dangerAlt:"danger-alt",dangerCollapsible:"danger-collapsible",definitionList:"definition-list",definitionTerm:"definition-term",deleted:"deleted",details:"details",details1:"details-1",detailsImage:"details-image",diff:"diff",document:"document",documentDownload:"document-download",documentEmbed:"document-embed",documentLink:"document-link",documentUpload:"document-upload",editorial:"editorial",editorNote:"editor-note",essay:"essay",example:"example",exampleAlt:"example-alt",exampleCollapsible:"example-collapsible",exampleList:"example-list",extractorAiChat:"extractor-ai-chat",extractorBlock:"extractor-block",extractorConfiguration:"extractor-configuration",extractorInformation:"extractor-information",extractorPage:"extractor-page",extractorPageCollapsible:"extractor-page-collapsible",extractorPageFooter:"extractor-page-footer",extractorPageFooterCollapsible:"extractor-page-footer-collapsible",extractorPageHeader:"extractor-page-header",extractorPageHeaderCollapsible:"extractor-page-header-collapsible",extractorPageNumber:"extractor-page-number",extractorPageNumberCollapsible:"extractor-page-number-collapsible",extractorPageWithBlocks:"extractor-page-with-blocks",extractorPageWithBlocksCollapsible:"extractor-page-with-blocks-collapsible",extractorRepeatedText:"extractor-repeated-text",featured:"featured",feedback:"feedback",figure:"figure",flashcard:"flashcard",flashcard1:"flashcard-1",focusImage:"focus-image",footNote:"foot-note",formula:"formula",gapText:"gap-text",gapTextInstructionGrouped:"gap-text-instruction-grouped",glossaryTerm:"glossary-term",groupBorn:"group-born",groupDied:"group-died",handInAudio:"hand-in-audio",handInContact:"hand-in-contact",handInDocument:"hand-in-document",handInFile:"hand-in-file",handInLocation:"hand-in-location",handInPhoto:"hand-in-photo",handInScan:"hand-in-scan",handInSubmit:"hand-in-submit",handInVideo:"hand-in-video",handInVoice:"hand-in-voice",help:"help",helpAlt:"help-alt",highlightText:"highlight-text",hint:"hint",hintAlt:"hint-alt",hintCollapsible:"hint-collapsible",image:"image",imageBanner:"image-banner",imageFigure:"image-figure",imageFigureAlt:"image-figure-alt",imageLandscape:"image-landscape",imageLink:"image-link",imageMood:"image-mood",imageOnDevice:"image-on-device",imagePortrait:"image-portrait",imagePrototype:"image-prototype",imageResponsive:"image-responsive",imageScreenshot:"image-screenshot",imageSeparator:"image-separator",imageSeparatorAlt:"image-separator-alt",imagesLogoGrave:"images-logo-grave",imageStyled:"image-styled",imageSuperWide:"image-super-wide",imageZoom:"image-zoom",indexTerm:"index-term",info:"info",infoAlt:"info-alt",infoCollapsible:"info-collapsible",internalLink:"internal-link",interview:"interview",interviewInstructionGrouped:"interview-instruction-grouped",langAudioScript:"lang-audio-script",langEnablingLanguageSkills:"lang-enabling-language-skills",langEnglishAroundWorld:"lang-english-around-world",langExtraActivity:"lang-extra-activity",langGoodToKnow:"lang-good-to-know",langHomework:"lang-homework",langLearningGoal:"lang-learning-goal",langLearningOutcomes:"lang-learning-outcomes",langLearningStrategy:"lang-learning-strategy",langLevelDown:"lang-level-down",langLevelUp:"lang-level-up",langLifeSkillIcon:"lang-life-skill-icon",langLifeSkills:"lang-life-skills",langLikeALocal:"lang-like-a-local",langMaterial:"lang-material",langTeacherNote:"lang-teacher-note",langTeacherPronunciation:"lang-teacher-pronunciation",langUsefulPhrases:"lang-useful-phrases",langVideoScript:"lang-video-script",langVocabulary:"lang-vocabulary",learningDocumentationFeedback:"learning-documentation-feedback",learningPathBook:"learning-path-book",learningPathBotTraining:"learning-path-bot-training",learningPathClassroomEvent:"learning-path-classroom-event",learningPathClassroomTraining:"learning-path-classroom-training",learningPathClosing:"learning-path-closing",learningPathExternalLink:"learning-path-external-link",learningPathFeedback:"learning-path-feedback",learningPathLearningGoal:"learning-path-learning-goal",learningPathLti:"learning-path-lti",learningPathSign:"learning-path-sign",learningPathStep:"learning-path-step",learningPathVideoCall:"learning-path-video-call",leAssignment:"le-assignment",leClassroomEvent:"le-classroom-event",leCompletion:"le-completion",leExternalLink:"le-external-link",leFinishingTask:"le-finishing-task",leFollowUpTask:"le-follow-up-task",legend:"legend",leDocumentDownload:"le-document-download",leLearningObjectives:"le-learning-objectives",leLearningStep:"le-learning-step",leListenAudioEmbed:"le-listen-audio-embed",lePreparationTask:"le-preparation-task",leRead:"le-read",leReadBook:"le-read-book",leTask:"le-task",leTodo:"le-todo",leVideoCall:"le-video-call",leWatchVideoEmbed:"le-watch-video-embed",lifeSkillSticker:"life-skill-sticker",list:"list",listItem:"list-item",mark:"mark",match:"match",matchAll:"match-all",matchAllReverse:"match-all-reverse",matchAudio:"match-audio",matchMatrix:"match-matrix",matchPicture:"match-picture",matchReverse:"match-reverse",matchSolutionGrouped:"match-solution-grouped",message:"message",metalevelExplanation:"metalevel-explanation",metaSearchDefaultTerms:"meta-search-default-terms",metaSearchDefaultTopics:"meta-search-default-topics",milestone:"milestone",module:"module",moduleProduct:"module-product",multipleChoice:"multiple-choice",multipleChoice1:"multiple-choice-1",multipleChoiceText:"multiple-choice-text",multipleResponse:"multiple-response",multipleResponse1:"multiple-response-1",newspaperArticle:"newspaper-article",note:"note",noteAi:"note-ai",noteAlt:"note-alt",notebookArticle:"notebook-article",noteCollapsible:"note-collapsible",output:"output",page:"page",pageAcademy:"page-academy",pageArticle:"page-article",pageArticleAlt:"page-article-alt",pageArticleResponsive:"page-article-responsive",pageBanner:"page-banner",pageBuyButton:"page-buy-button",pageBuyButtonAlt:"page-buy-button-alt",pageBuyButtonPromotion:"page-buy-button-promotion",pageCategory:"page-category",pageCollapsible:"page-collapsible",pageContainer:"page-container",pageContainerFolder:"page-container-folder",pageContainerGroup:"page-container-group",pageContainerNowrap:"page-container-nowrap",pageContainerNowrapStretch:"page-container-nowrap-stretch",pageContainerWrap:"page-container-wrap",pageCoverImage:"page-cover-image",pageFooter:"page-footer",pageHero:"page-hero",pageOpenBook:"page-open-book",pageOpenBookList:"page-open-book-list",pagePerson:"page-person",pageProduct:"page-product",pageProductList:"page-product-list",pageProductVideo:"page-product-video",pageProductVideoList:"page-product-video-list",pagePromotion:"page-promotion",pageSectionFolder:"page-section-folder",pageShopInShop:"page-shop-in-shop",pageSpecial:"page-special",pageSubpage:"page-subpage",pageSubscribe:"page-subscribe",parameters:"parameters",photo:"photo",platformPath:"platform-path",preparationNote:"preparation-note",pronunciationTable:"pronunciation-table",prototypeImages:"prototype-images",qAndA:"q-and-a",qAndACard:"q-and-a-card",question1:"question-1",quote:"quote",rating:"rating",recipe:"recipe",recordAudio:"record-audio",recordVideo:"record-video",releaseNote:"release-note",releaseNotesSummary:"release-notes-summary",remark:"remark",remarkAlt:"remark-alt",remarkCollapsible:"remark-collapsible",reviewApprovedNote:"review-approved-note",reviewAuthorNote:"review-author-note",reviewCustomerNote:"review-customer-note",reviewNote:"review-note",reviewRequestForReviewNote:"review-request-for-review-note",reviewReviewerNote:"review-reviewer-note",sampleSolution:"sample-solution",scorm:"scorm",screenshot:"screenshot",selfAssessment:"self-assessment",separator:"separator",separatorAlt:"separator-alt",sequence:"sequence",sideNote:"side-note",sideNoteCollapsible:"side-note-collapsible",smartStandardArticleNonNormative:"smart-standard-article-non-normative",smartStandardArticleNonNormativeCollapsible:"smart-standard-article-non-normative-collapsible",smartStandardArticleNormative:"smart-standard-article-normative",smartStandardArticleNormativeCollapsible:"smart-standard-article-normative-collapsible",smartStandardExampleNonNormative:"smart-standard-example-non-normative",smartStandardExampleNonNormativeCollapsible:"smart-standard-example-non-normative-collapsible",smartStandardExampleNormative:"smart-standard-example-normative",smartStandardExampleNormativeCollapsible:"smart-standard-example-normative-collapsible",smartStandardFormula:"smart-standard-formula",smartStandardFormulaNonNormative:"smart-standard-formula-non-normative",smartStandardFormulaNormative:"smart-standard-formula-normative",smartStandardImageFigureNonNormative:"smart-standard-image-figure-non-normative",smartStandardImageFigureNonNormativeCollapsible:"smart-standard-image-figure-non-normative-collapsible",smartStandardImageFigureNormative:"smart-standard-image-figure-normative",smartStandardImageFigureNormativeCollapsible:"smart-standard-image-figure-normative-collapsible",smartStandardLegend:"smart-standard-legend",smartStandardLegendNonNormative:"smart-standard-legend-non-normative",smartStandardLegendNormative:"smart-standard-legend-normative",smartStandardList:"smart-standard-list",smartStandardListCollapsible:"smart-standard-list-collapsible",smartStandardListItem:"smart-standard-list-item",smartStandardListItemCollapsible:"smart-standard-list-item-collapsible",smartStandardNoteNonNormative:"smart-standard-note-non-normative",smartStandardNoteNonNormativeCollapsible:"smart-standard-note-non-normative-collapsible",smartStandardNoteNormative:"smart-standard-note-normative",smartStandardNoteNormativeCollapsible:"smart-standard-note-normative-collapsible",smartStandardRemarkLegend:"smart-standard-remark-legend",smartStandardRemarkLegendNonNormative:"smart-standard-remark-legend-non-normative",smartStandardRemarkLegendNormative:"smart-standard-remark-legend-normative",smartStandardRemarkFormula:"smart-standard-remark-formula",smartStandardRemarkFormulaNonNormative:"smart-standard-remark-formula-non-normative",smartStandardRemarkFormulaNormative:"smart-standard-remark-formula-normative",smartStandardRemarkNonNormative:"smart-standard-remark-non-normative",smartStandardRemarkNonNormativeCollapsible:"smart-standard-remark-non-normative-collapsible",smartStandardRemarkNormative:"smart-standard-remark-normative",smartStandardRemarkNormativeCollapsible:"smart-standard-remark-normative-collapsible",smartStandardRemarkTableImageNonNormative:"smart-standard-remark-table-image-non-normative",smartStandardRemarkTableImageNonNormativeCollapsible:"smart-standard-remark-table-image-non-normative-collapsible",smartStandardRemarkTableImageNormative:"smart-standard-remark-table-image-normative",smartStandardRemarkTableImageNormativeCollapsible:"smart-standard-remark-table-image-normative-collapsible",smartStandardRemarkTableNonNormative:"smart-standard-remark-table-non-normative",smartStandardRemarkTableNonNormativeCollapsible:"smart-standard-remark-table-non-normative-collapsible",smartStandardRemarkTableNormative:"smart-standard-remark-table-normative",smartStandardRemarkTableNormativeCollapsible:"smart-standard-remark-table-normative-collapsible",smartStandardTableImageNonNormative:"smart-standard-table-image-non-normative",smartStandardTableImageNonNormativeCollapsible:"smart-standard-table-image-non-normative-collapsible",smartStandardTableImageNormative:"smart-standard-table-image-normative",smartStandardTableImageNormativeCollapsible:"smart-standard-table-image-normative-collapsible",smartStandardTableNonNormative:"smart-standard-table-non-normative",smartStandardTableNonNormativeCollapsible:"smart-standard-table-non-normative-collapsible",smartStandardTableNormative:"smart-standard-table-normative",smartStandardTableNormativeCollapsible:"smart-standard-table-normative-collapsible",standardArticleNonNormative:"standard-article-non-normative",standardArticleNormative:"standard-article-normative",standardExampleNonNormative:"standard-example-non-normative",standardExampleNormative:"standard-example-normative",standardImageFigureNonNormative:"standard-image-figure-non-normative",standardImageFigureNormative:"standard-image-figure-normative",standardList:"standard-list",standardListItem:"standard-list-item",standardNoteNonNormative:"standard-note-non-normative",standardNoteNormative:"standard-note-normative",standardRemarkNonNormative:"standard-remark-non-normative",standardRemarkNormative:"standard-remark-normative",standardRemarkTableImageNonNormative:"standard-remark-table-image-non-normative",standardRemarkTableImageNormative:"standard-remark-table-image-normative",standardRemarkTableNonNormative:"standard-remark-table-non-normative",standardRemarkTableNormative:"standard-remark-table-normative",standardTableImageNonNormative:"standard-table-image-non-normative",standardTableImageNormative:"standard-table-image-normative",standardTableNonNormative:"standard-table-non-normative",standardTableNormative:"standard-table-normative",statement:"statement",stdout:"stdout",step:"step",stepImageScreenshot:"step-image-screenshot",stepImageScreenshotWithPointer:"step-image-screenshot-with-pointer",sticker:"sticker",stickyNote:"sticky-note",stillImageFilm:"still-image-film",stillImageFilmEmbed:"still-image-film-embed",stillImageFilmLink:"still-image-film-link",summary:"summary",summaryAi:"summary-ai",survey:"survey",survey1:"survey-1",surveyAnonymous:"survey-anonymous",surveyAnonymous1:"survey-anonymous-1",surveyMatrix:"survey-matrix",surveyMatrixMe:"survey-matrix-me",surveyRating:"survey-rating",surveyRatingDisplay:"survey-rating-display",surveyRatingOnce:"survey-rating-once",table:"table",tableAlt:"table-alt",tableImage:"table-image",tableImageAlt:"table-image-alt",takePicture:"take-picture",toc:"toc",tocChapter:"toc-chapter",tocInline:"toc-inline",trueFalse:"true-false",trueFalse1:"true-false-1",vendorAmcharts5Chart:"vendor-amcharts-5-chart",vendorDatadogDashboardEmbed:"vendor-datadog-dashboard-embed",vendorFormbricksEmbed:"vendor-formbricks-embed",vendorFormbricksLink:"vendor-formbricks-link",vendorFormbricksEmbedAnonymous:"vendor-formbricks-embed-anonymous",vendorFormbricksLinkAnonymous:"vendor-formbricks-link-anonymous",vendorHighchartsChart:"vendor-highcharts-chart",vendorIframelyCard:"vendor-iframely-card",vendorIframelyEmbed:"vendor-iframely-embed",vendorIframelyPreview:"vendor-iframely-preview",vendorIframelyPreviewMini:"vendor-iframely-preview-mini",vendorJupyterCellCode:"vendor-jupyter-cell-code",vendorJupyterCellMarkdown:"vendor-jupyter-cell-markdown",vendorJupyterCellRaw:"vendor-jupyter-cell-raw",vendorJupyterIpynb:"vendor-jupyter-ipynb",vendorJupyterOutput:"vendor-jupyter-output",vendorPadletEmbed:"vendor-padlet-embed",vendorStripePricingTable:"vendor-stripe-pricing-table",vendorStripePricingTableExternal:"vendor-stripe-pricing-table-external",video:"video",videoEmbed:"video-embed",videoEmbedLandscape:"video-embed-landscape",videoEmbedPortrait:"video-embed-portrait",videoLandscape:"video-landscape",videoLink:"video-link",videoLinkLandscape:"video-link-landscape",videoLinkPortrait:"video-link-portrait",videoPortrait:"video-portrait",videoTranscript:"video-transcript",warning:"warning",warningAlt:"warning-alt",warningCollapsible:"warning-collapsible",websiteLink:"website-link",workbookArticle:"workbook-article"});t.BitType=i},5980:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.markTagContentProcessor=function(e,t,r,o){const{value:n}=r;i.StringUtils.isString(n)&&(o.solution=i.StringUtils.trimmedString(n))};const i=r(9681)},6128:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ContentProcessorUtils=void 0;const i=r(9554);const o=new class{concatenatePlainTextWithAstTexts(e,t,r){var o;if(Array.isArray(e)){if(r=r&&r.trim()){const n=r.split("\n"),a=[];for(let e=0;e<t;e++)a.push({type:i.TextNodeType.hardBreak});for(let e=0;e<n.length;e++){const t=n[e];t&&a.push({text:t,type:i.TextNodeType.text}),e<n.length-1&&a.push({type:i.TextNodeType.hardBreak})}const s=e[e.length-1];s&&s.type===i.TextNodeType.paragraph?s.content=[...null!==(o=s.content)&&void 0!==o?o:[],...a]:e.push({type:i.TextNodeType.paragraph,content:a,attrs:{}})}return e}return`${null!=e?e:""}${"\n".repeat(t)}${null!=r?r:""}`}};t.ContentProcessorUtils=o},6149:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceTag=void 0;const i=(0,r(4718).superenum)({unknown:"unknown",icon:"icon",image:"image",imageResponsive:"image-responsive",imagePortrait:"image-portrait",imageLandscape:"image-landscape",imageEmbed:"image-embed",imageLink:"image-link",audio:"audio",audioEmbed:"audio-embed",audioLink:"audio-link",video:"video",videoEmbed:"video-embed",videoLink:"video-link",stillImageFilm:"still-image-film",stillImageFilmEmbed:"still-image-film-embed",stillImageFilmLink:"still-image-film-link",article:"article",articleEmbed:"article-embed",articleLink:"article-link",document:"document",documentEmbed:"document-embed",documentLink:"document-link",documentDownload:"document-download",appLink:"app-link",websiteLink:"website-link"});t.ResourceTag=i},6278:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Environment=void 0;const i=(0,r(4718).superenum)({unknown:"",node:"node",chrome:"chrome",safari:"safari",firefox:"firefox",edge:"edge",ie:"ie"});t.Environment=i},6521:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.buildResources=function(e,t,r){var i,o;const{bitType:n}=e,p=[],u=[],c=l.ResourceTag.fromValue(t),y=a.Config.getBitResourcesConfig(n,c),g=y.resourceAttachmentAllowed,d=y.getCountsMin(),f=y.getCountsMax();if(r)for(const e of r.reverse()){let t=null!==(i=d.get(e.__typeAlias))&&void 0!==i?i:0,r=null!==(o=f.get(e.__typeAlias))&&void 0!==o?o:0;t=Math.max(0,t-1),r===s.Count.infinity?p.unshift(e):r>0?(p.unshift(e),r--):u.unshift(e),d.set(e.__typeAlias,t),f.set(e.__typeAlias,r)}if(!g&&t){const r=`Resource type [&${t}] is specified in the bit header, but no extra resource is allowed for this bit.`;e.addWarning(r)}else 0===p.length&&t&&e.addWarning(`Resource type [&${t}] is specified in the bit header, but no such a resource is present`);u.length>0&&(e.parser.excessResources=u);return p},t.resourceContentProcessor=function(e,t,r,o,s){const{type:g,key:d,value:f,chain:m}=o,T=s.resources;if(!T)return;const h=l.ResourceTag.fromValue(d);if(h){const t=a.Config.getTagConfigForTag(r,h),o=e.bitContentProcessor(c.BitContentLevel.Chain,null==t?void 0:t.chain,m),{posterImage:s}=o,g=i(o,["posterImage"]);let d;if(s){const{subConfig:r,subChain:o}=function(e,t,r){var i;let o;e&&(o=null===(i=e[r])||void 0===i?void 0:i.chain);const n=null==t?void 0:t.reduce(((e,t)=>{if(e)return e;const r=t;return"posterImage"===r.key?r.chain:void 0}),void 0);return{subConfig:o,subChain:n}}(null==t?void 0:t.chain,m,"posterImage"),n=e.bitContentProcessor(c.BitContentLevel.Chain,r,o),{posterImage:a}=n,p=i(n,["posterImage"]);d=y.resource(e,Object.assign({type:l.ResourceTag.image,value:s},p)).image}const b=y.resource(e,Object.assign({type:h,value:n.Breakscape.unbreakscape(f,{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag}),posterImage:d},g));b&&T.push(b)}},t.propertyStyleResourceContentProcessor=function(e,t,r,o,s,g){var d;const{type:f,key:m,value:T,chain:h}=o;if(s.propertyStyleResources=null!==(d=s.propertyStyleResources)&&void 0!==d?d:{},g){const t=a.Config.getTagConfigForTag(r,g),o=e.bitContentProcessor(c.BitContentLevel.Chain,null==t?void 0:t.chain,h),{posterImage:d}=o,f=i(o,["posterImage"]),b=d?y.resource(e,{type:l.ResourceTag.image,value:d}).image:void 0,B=y.resource(e,Object.assign({type:g,value:n.Breakscape.unbreakscape(T,{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag}),posterImage:b},f));B&&(s.propertyStyleResources[m]=B)}};const o=r(5533),n=r(7735),a=r(2028),s=r(3778),l=r(6149),p=r(385),u=r(6877),c=r(3029),y=new o.ResourceBuilder},6634:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractTagConfig=void 0;t.AbstractTagConfig=class{constructor(e,t,r,i,o,n,a,s,l){this.type=e,this.configKey=t,this.tag=r,this.maxCount=i,this.minCount=o,this.chain=n,this.jsonKey=a,this.astKey=s,this.deprecated=l}}},6772:function(e,t){var r=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.StringWriter=void 0;t.StringWriter=class{constructor(){this._string="",this.endOfLineString="\n",this.lastWrite=""}get isSync(){return!0}getString(){return this._string}open(){return r(this,void 0,void 0,(function*(){return this.openSync(),Promise.resolve()}))}close(){return r(this,void 0,void 0,(function*(){try{this.closeSync()}catch(e){return Promise.reject(e)}return Promise.resolve()}))}openSync(){this._buffer=[],this._string=""}closeSync(){if(!this._buffer)throw new Error("open() or openSync() never called");this._string=this._buffer.join(""),this._buffer=[]}writeLine(e){return this._buffer?(null!=e?(this._buffer.push(e+this.endOfLineString),this.lastWrite=e+this.endOfLineString):(this._buffer.push(this.endOfLineString),this.lastWrite=this.endOfLineString),this):this}writeLines(e,t){if(!this._buffer)return this;if(!e)return this;let r="";for(let i=0,o=e.length;i<o;i++){const n=e[i];this._buffer.push(n),r+=n,t&&i<o-1&&(this._buffer.push(t),r+=t),this._buffer.push(this.endOfLineString),r+=this.endOfLineString}return this.lastWrite=r,this}write(e){return this._buffer?(null==e||(e&&(this.lastWrite=e),this._buffer.push(e)),this):this}writeWhiteSpace(){return this.write(" "),this}getLastWrite(){return this.lastWrite}}},6853:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BITS=void 0;const i=r(8199),o=r(7112),n=r(9888),a=r(7797),s=r(5512),l=r(5854),p=r(3778),u=r(363),c=r(385),y={[l.BitType._error]:{since:"1.3.0",tags:[]},[l.BitType._comment]:{since:"1.4.12",tags:[]},[l.BitType._standard]:{since:"3.2.0",tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags}]},[l.BitType.appFlashcards]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.flashcardSet,maxCount:p.Count.infinity}],rootExampleType:u.ExampleType.string},[l.BitType.appFlashcardsQuiz]:{since:"1.3.0",baseBitType:l.BitType.appFlashcards},[l.BitType.appFlashcardsLearn]:{since:"1.3.0",baseBitType:l.BitType.appFlashcards},[l.BitType.appLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAppLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.article]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title}]},[l.BitType.articleAlt]:{since:"1.15.0",baseBitType:l.BitType.article},[l.BitType.articleResponsive]:{since:"1.21.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.imageFirst}]},[l.BitType.articleResponsiveAlt]:{since:"2.0.0",baseBitType:l.BitType.articleResponsive},[l.BitType.standardArticleNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.standardArticleNonNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.smartStandardArticleNormative]:{since:"1.28.0",baseBitType:l.BitType.standardArticleNormative},[l.BitType.smartStandardArticleNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardArticleNonNormative},[l.BitType.smartStandardArticleNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardArticleNormative},[l.BitType.smartStandardArticleNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardArticleNonNormative},[l.BitType.statement]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.pageArticle]:{since:"1.15.0",baseBitType:l.BitType.article},[l.BitType.pageArticleAlt]:{since:"1.15.0",baseBitType:l.BitType.article},[l.BitType.pageArticleResponsive]:{since:"1.21.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.imageFirst}]},[l.BitType.buttonCopyText]:{since:"1.4.3",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.callToAction]:{since:"1.15.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.callToActionUrl,minCount:1}]},[l.BitType.callToActionSubscribe]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionContact]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionJoin]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionMail]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionLearnMore]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionSeeMore]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionWatch]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionStartNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionGetOffer]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionBookNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionShopNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionGetNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionDownload]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionCreateAccount]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.appBitmarkFromJavascript]:{since:"1.4.5",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.maxCreatedBits}],textFormatDefault:c.TextFormat.text},[l.BitType.appBitmarkFromEditor]:{since:"1.4.5",baseBitType:l.BitType.appBitmarkFromJavascript},[l.BitType.articleEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceArticleEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.articleLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceArticleLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.audio]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudio,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.audioEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudioEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.audioLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudioLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.bitAlias]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference},{type:s.BitTagType.tag,configKey:a.TagConfigKey.anchor}]},[l.BitType.diff]:{since:"3.13.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.diffTo}]},[l.BitType.book]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_bookCommon}]},[l.BitType.bookAcknowledgements]:{since:"1.17.0",baseBitType:l.BitType.article},[l.BitType.bookAddendum]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAfterword]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAppendix]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAutherBio]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookBibliography]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookComingSoon]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookConclusion]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookCopyright]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookCopyrightPermissions]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookDedication]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookEndnotes]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookEpigraph]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookEpilogue]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookForword]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookFrontispiece]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookImprint]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookIncitingIncident]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookIntroduction]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookListOfContributors]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookNotes]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookPostscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookPreface]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookPrologue]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookReadMore]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookReferenceList]:{since:"3.2.0",baseBitType:l.BitType._standard,cardSet:i.CardSetConfigKey._bookReferenceList},[l.BitType.bookRequestForABookReview]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookSummary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookTeaser]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookTitle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAlias]:{since:"1.4.3",baseBitType:l.BitType.book,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.bookAlias,maxCount:p.Count.infinity}]},[l.BitType.bookDiff]:{since:"3.10.0",baseBitType:l.BitType.book,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.bookDiff}]},[l.BitType.bookClose]:{since:"1.18.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.bookReference]:{since:"2.2.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refAuthor,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refBookTitle},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refPublisher,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refPublicationYear},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.citationStyle}]},[l.BitType.botActionResponse]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._botActionResponses},[l.BitType.botActionSend]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.date}]},[l.BitType.browserImage]:{since:"1.3.0",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusX},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusY}]},[l.BitType.card1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}]},[l.BitType.question1]:{since:"1.3.0",baseBitType:l.BitType.card1},[l.BitType.survey1]:{since:"1.3.0",baseBitType:l.BitType.card1},[l.BitType.surveyAnonymous1]:{since:"1.3.0",baseBitType:l.BitType.card1},[l.BitType.chapter]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.anchor},{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.toc},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.progress}]},[l.BitType.clozeAndMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_gap},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachCallToActionClozeAndMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType.clozeAndMultipleChoiceText},[l.BitType.cloze]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quizCountItems},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quizStrikethroughSolutions},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quizStrikethroughSolutions},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.additionalSolutions,maxCount:p.Count.infinity},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_gap}]},[l.BitType.clozeInstructionGrouped]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.clozeSolutionGrouped]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.clozeSeveral]:{since:"3.5.0",baseBitType:l.BitType.cloze},[l.BitType.gapText]:{since:"1.5.15",baseBitType:l.BitType.cloze},[l.BitType.gapTextInstructionGrouped]:{since:"1.5.15",baseBitType:l.BitType.clozeInstructionGrouped},[l.BitType.coachSelfReflectionCloze]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.coachCallToActionCloze]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.clozeList]:{since:"1.4.13",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}],cardSet:i.CardSetConfigKey._clozeList},[l.BitType.code]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.computerLanguage},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.codeLineNumbers},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.codeMinimap}],textFormatDefault:c.TextFormat.text},[l.BitType.formula]:{since:"1.35.0",baseBitType:l.BitType._standard,tags:[],textFormatDefault:c.TextFormat.latex},[l.BitType.smartStandardFormula]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardFormulaNonNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardFormulaNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardRemarkFormula]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardRemarkFormulaNonNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardRemarkFormulaNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.appCodeCell]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.appCodeEditor]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.appCodeIde]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.codeRuntime]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.consoleLog]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.output]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.stdout]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.step]:{since:"1.5.1",baseBitType:l.BitType.article},[l.BitType.stepImageScreenshot]:{since:"1.5.1",baseBitType:l.BitType.image},[l.BitType.stepImageScreenshotWithPointer]:{since:"1.5.1",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerTop,minCount:1,maxCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerLeft,minCount:1,maxCount:1}]},[l.BitType.milestone]:{since:"1.20.0",baseBitType:l.BitType.step},[l.BitType.conversationLeft1]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_person}]},[l.BitType.conversationLeft1Scream]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationLeft1Thought]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationRight1]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationRight1Scream]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationRight1Thought]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.cookPreparation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookStep]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookIngredients]:{since:"1.5.16",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_technicalTerm},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.servings,chain:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.unit},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.unitAbbr},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.decimalPlaces},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.disableCalculation},{type:s.BitTagType.tag,configKey:a.TagConfigKey.hint}]}],cardSet:i.CardSetConfigKey._ingredients},[l.BitType.recipe]:{since:"1.5.24",baseBitType:l.BitType.cookIngredients},[l.BitType.cookRemark]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookVariation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookInsert]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookArrangement]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookPracticeAdvise]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookPlate]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookRecommendation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookPersonalRecommendation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookSideDrink]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookSideDish]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookTimer]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.document]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocument,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.documentDownload]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocumentDownload,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.leDocumentDownload]:{since:"3.18.0",baseBitType:l.BitType.documentDownload},[l.BitType.documentEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocumentEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.documentLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocumentLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.essay]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.property_sampleSolution},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.additionalSolutions,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.partialAnswer},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.property_reference,maxCount:p.Count.infinity}],rootExampleType:u.ExampleType.string},[l.BitType.coachSelfReflectionEssay]:{since:"1.3.0",baseBitType:l.BitType.essay},[l.BitType.coachCallToActionEssay]:{since:"1.3.0",baseBitType:l.BitType.essay},[l.BitType.example]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title}],rootExampleType:u.ExampleType.string},[l.BitType.exampleAlt]:{since:"1.16.0",baseBitType:l.BitType.example},[l.BitType.standardExampleNormative]:{since:"1.16.0",baseBitType:l.BitType.example},[l.BitType.standardExampleNonNormative]:{since:"1.16.0",baseBitType:l.BitType.example},[l.BitType.smartStandardExampleNormative]:{since:"1.28.0",baseBitType:l.BitType.standardExampleNormative},[l.BitType.smartStandardExampleNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardExampleNonNormative},[l.BitType.smartStandardExampleNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardExampleNormative},[l.BitType.smartStandardExampleNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardExampleNonNormative},[l.BitType.appAiPrompt]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.aiPrompt]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.articleAi]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.articleAttachment]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.assignment]:{since:"1.3.0",baseBitType:l.BitType.essay},[l.BitType.audioTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bitmarkExample]:{since:"1.3.0",baseBitType:l.BitType.example},[l.BitType.blogArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bug]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bugAlt]:{since:"1.16.0",baseBitType:l.BitType.bug},[l.BitType.checklist]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachAudioTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachCallToActionChecklist]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachHomeRules]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachVideoTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.correction]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.danger]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.dangerAlt]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.definitionTerm]:{since:"1.34.0",baseBitType:l.BitType.article},[l.BitType.deleted]:{since:"3.9.0",baseBitType:l.BitType.article},[l.BitType.details1]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.details]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.qAndA]:{since:"3.5.0",baseBitType:l.BitType.article},[l.BitType.editorial]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.editorNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.featured]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.glossaryTerm]:{since:"1.33.0",baseBitType:l.BitType.article},[l.BitType.help]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.helpAlt]:{since:"1.16.0",baseBitType:l.BitType.help},[l.BitType.hint]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.hintAlt]:{since:"1.16.0",baseBitType:l.BitType.hint},[l.BitType.indexTerm]:{since:"1.33.0",baseBitType:l.BitType.article},[l.BitType.info]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.infoAlt]:{since:"1.16.0",baseBitType:l.BitType.info},[l.BitType.langLearningOutcomes]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langEnablingLanguageSkills]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLifeSkills]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langEnglishAroundWorld]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langGoodToKnow]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLearningGoal]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLearningStrategy]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLikeALocal]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langMaterial]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langUsefulPhrases]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLevelDown]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLevelUp]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langExtraActivity]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langVideoScript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langAudioScript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langVocabulary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langHomework]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langTeacherNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langTeacherPronunciation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.list]:{since:"1.22.0",baseBitType:l.BitType.article},[l.BitType.standardList]:{since:"1.22.0",baseBitType:l.BitType.article},[l.BitType.smartStandardList]:{since:"1.28.0",baseBitType:l.BitType.standardList},[l.BitType.smartStandardListCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardList},[l.BitType.message]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.newspaperArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.note]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.noteAlt]:{since:"1.16.0",baseBitType:l.BitType.note},[l.BitType.standardNoteNormative]:{since:"1.16.0",baseBitType:l.BitType.note},[l.BitType.standardNoteNonNormative]:{since:"1.16.0",baseBitType:l.BitType.note},[l.BitType.smartStandardNoteNormative]:{since:"1.28.0",baseBitType:l.BitType.standardNoteNormative},[l.BitType.smartStandardNoteNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardNoteNonNormative},[l.BitType.smartStandardNoteNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardNoteNormative},[l.BitType.smartStandardNoteNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardNoteNonNormative},[l.BitType.noteAi]:{since:"1.3.0",baseBitType:l.BitType.note},[l.BitType.notebookArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.preparationNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.releaseNotesSummary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.remark]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.remarkAlt]:{since:"1.16.0",baseBitType:l.BitType.remark},[l.BitType.standardRemarkNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.standardRemarkNonNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.smartStandardRemarkNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkNormative},[l.BitType.smartStandardRemarkNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkNonNormative},[l.BitType.smartStandardRemarkNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkNormative},[l.BitType.smartStandardRemarkNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkNonNormative},[l.BitType.selfAssessment]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.separator]:{since:"1.4.15",baseBitType:l.BitType.article},[l.BitType.separatorAlt]:{since:"1.16.0",baseBitType:l.BitType.separator},[l.BitType.sticker]:{since:"1.5.28",baseBitType:l.BitType.article},[l.BitType.sideNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.summary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.summaryAi]:{since:"1.3.0",baseBitType:l.BitType.summary},[l.BitType.videoTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.warning]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.warningAlt]:{since:"1.16.0",baseBitType:l.BitType.warning},[l.BitType.workbookArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.collapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.sideNoteCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.infoCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.remarkCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.warningCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.dangerCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.noteCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.exampleCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.hintCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.bugCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.platformPath]:{since:"3.14.1",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.path}]},[l.BitType.container]:{since:"1.9.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.allowedBit,maxCount:p.Count.infinity}]},[l.BitType.containerWrap]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerNowrap]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerNowrapStretch]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerGroup]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerFolder]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerCarousel]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerCards]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerGrid]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerStack]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerSlides]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerGallery]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerScroller]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerTabs]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerAccordionTabs]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerFolderAll]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerBits2]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerCookRecipe]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerNewsArticle]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerPreview]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.pageContainer]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.pageContainerWrap]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerNowrap]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerNowrapStretch]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerFolder]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerGroup]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.metalevelExplanation]:{since:"1.10.0",baseBitType:l.BitType.article},[l.BitType.module]:{since:"1.5.26",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.hasBookNavigation},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productId,minCount:1,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.duration}]},[l.BitType.moduleProduct]:{since:"1.9.0",baseBitType:l.BitType.module,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productId,minCount:1}]},[l.BitType.exampleList]:{since:"1.4.13",baseBitType:l.BitType.example,cardSet:i.CardSetConfigKey._exampleBitList,rootExampleType:u.ExampleType.string},[l.BitType.extractorPage]:{since:"1.5.17",baseBitType:l.BitType.image},[l.BitType.extractorPageCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPage},[l.BitType.extractorPageWithBlocks]:{since:"1.5.21",baseBitType:l.BitType.image},[l.BitType.extractorPageWithBlocksCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageWithBlocks},[l.BitType.extractorConfiguration]:{since:"1.7.1",baseBitType:l.BitType._standard,tags:[],textFormatDefault:c.TextFormat.text},[l.BitType.extractorInformation]:{since:"3.8.0",baseBitType:l.BitType._standard,tags:[],textFormatDefault:c.TextFormat.json},[l.BitType.extractorAiChat]:{since:"3.19.0",baseBitType:l.BitType._standard},[l.BitType.extractorBlock]:{since:"1.5.16",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.blockId},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pageNo},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.x},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.y},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.index},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.classification},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.availableClassifications,maxCount:p.Count.infinity},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.extractorRepeatedText]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageNumber]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageNumberCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageNumber},[l.BitType.extractorPageHeader]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageHeaderCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageHeader},[l.BitType.extractorPageFooter]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageFooterCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageFooter},[l.BitType.pageOpenBook]:{since:"1.5.10",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.book,chain:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference,maxCount:2}]},{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageOpenBookList]:{since:"2.1.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.book,maxCount:p.Count.infinity,chain:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference,maxCount:2}]},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageSubscribe]:{since:"1.5.10",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.mailingList}]},[l.BitType.assignmentList]:{since:"1.4.13",baseBitType:l.BitType.exampleList},[l.BitType.pageFooter]:{since:"1.4.13",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug}],cardSet:i.CardSetConfigKey._exampleBitList},[l.BitType.legend]:{since:"3.12.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._definitionList},[l.BitType.smartStandardLegend]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardLegendNonNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardLegendNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardRemarkLegend]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardRemarkLegendNonNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardRemarkLegendNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.definitionList]:{since:"1.34.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._definitionList},[l.BitType.metaSearchDefaultTerms]:{since:"3.12.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._definitionList},[l.BitType.metaSearchDefaultTopics]:{since:"3.12.0",baseBitType:l.BitType.metaSearchDefaultTerms},[l.BitType.flashcard]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}],cardSet:i.CardSetConfigKey._flashcard},[l.BitType.flashcard1]:{since:"1.3.0",baseBitType:l.BitType.flashcard},[l.BitType.qAndACard]:{since:"3.25.0",baseBitType:l.BitType.flashcard1},[l.BitType.focusImage]:{since:"1.3.0",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusX},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusY}]},[l.BitType.highlightText]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.image]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.backgroundWallpaper},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.appCreateBitsFromImage]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.appGetScreenshot]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.detailsImage]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.figure]:{since:"1.3.0",baseBitType:l.BitType.image,cardSet:i.CardSetConfigKey._definitionList},[l.BitType.imageBanner]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageFigure]:{since:"1.3.0",baseBitType:l.BitType.image,cardSet:i.CardSetConfigKey._definitionList},[l.BitType.imageFigureAlt]:{since:"1.16.0",baseBitType:l.BitType.imageFigure},[l.BitType.standardImageFigureNormative]:{since:"1.16.0",baseBitType:l.BitType.imageFigure},[l.BitType.standardImageFigureNonNormative]:{since:"1.16.0",baseBitType:l.BitType.imageFigure},[l.BitType.smartStandardImageFigureNormative]:{since:"1.28.0",baseBitType:l.BitType.standardImageFigureNormative},[l.BitType.smartStandardImageFigureNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardImageFigureNonNormative},[l.BitType.smartStandardImageFigureNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardImageFigureNormative},[l.BitType.smartStandardImageFigureNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardImageFigureNonNormative},[l.BitType.imageLandscape]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageMood]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imagePortrait]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imagePrototype]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageSeparator]:{since:"1.4.15",baseBitType:l.BitType.image},[l.BitType.imageSeparatorAlt]:{since:"1.16.0",baseBitType:l.BitType.imageSeparator},[l.BitType.imageScreenshot]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageStyled]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageSuperWide]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageZoom]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.langLifeSkillIcon]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.lifeSkillSticker]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.pageBanner]:{since:"1.4.3",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug}]},[l.BitType.pageHero]:{since:"1.11.0",baseBitType:l.BitType.pageBanner},[l.BitType.screenshot]:{since:"1.3.0",deprecated:"1.4.0",baseBitType:l.BitType.image},[l.BitType.tableImage]:{since:"1.5.15",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.caption}]},[l.BitType.tableImageAlt]:{since:"1.16.0",baseBitType:l.BitType.tableImage},[l.BitType.standardTableImageNormative]:{since:"1.16.0",baseBitType:l.BitType.tableImage},[l.BitType.standardTableImageNonNormative]:{since:"1.16.0",baseBitType:l.BitType.tableImage},[l.BitType.standardRemarkTableImageNormative]:{since:"1.17.0",baseBitType:l.BitType.tableImage},[l.BitType.standardRemarkTableImageNonNormative]:{since:"1.17.0",baseBitType:l.BitType.tableImage},[l.BitType.smartStandardTableImageNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableImageNormative},[l.BitType.smartStandardTableImageNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableImageNonNormative},[l.BitType.smartStandardRemarkTableImageNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableImageNormative},[l.BitType.smartStandardRemarkTableImageNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableImageNonNormative},[l.BitType.smartStandardTableImageNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableImageNormative},[l.BitType.smartStandardTableImageNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableImageNonNormative},[l.BitType.smartStandardRemarkTableImageNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableImageNormative},[l.BitType.smartStandardRemarkTableImageNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableImageNonNormative},[l.BitType.imageLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImageLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.imageOnDevice]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_imageSource}],resourceAttachmentAllowed:!1},[l.BitType.imageResponsive]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImageResponsive}],resourceAttachmentAllowed:!1},[l.BitType.imagesLogoGrave]:{since:"1.5.11",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage,minCount:1,maxCount:p.Count.infinity}],resourceAttachmentAllowed:!1},[l.BitType.prototypeImages]:{since:"1.6.1",baseBitType:l.BitType.imagesLogoGrave},[l.BitType.internalLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference}]},[l.BitType.interview]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars}],cardSet:i.CardSetConfigKey._questions},[l.BitType.interviewInstructionGrouped]:{since:"1.3.0",baseBitType:l.BitType.interview},[l.BitType.botInterview]:{since:"1.3.0",baseBitType:l.BitType.interview},[l.BitType.learningPathBook]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_learningPathCommon}]},[l.BitType.bookLink]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.bookLinkNext]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.bookLinkPrev]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathClassroomEvent]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathClassroomTraining]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathClosing]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathFeedback]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathLearningGoal]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathLti]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathSign]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathStep]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathBotTraining]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.bot}]},[l.BitType.learningPathExternalLink]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.externalLink},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.externalLinkText}]},[l.BitType.learningPathVideoCall]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.videoCallLink}]},[l.BitType.leLearningObjectives]:{since:"1.25.0",baseBitType:l.BitType.learningPathLearningGoal,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leVideoCall]:{since:"1.25.0",baseBitType:l.BitType.learningPathVideoCall,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leClassroomEvent]:{since:"1.25.0",baseBitType:l.BitType.learningPathClassroomEvent,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leCompletion]:{since:"1.25.0",baseBitType:l.BitType.learningPathClosing,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leExternalLink]:{since:"1.25.0",baseBitType:l.BitType.learningPathExternalLink,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leReadBook]:{since:"1.25.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leLearningStep]:{since:"1.25.0",baseBitType:l.BitType.learningPathStep,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.lePreparationTask]:{since:"1.26.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leRead]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leTask]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leTodo]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leFollowUpTask]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leFinishingTask]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leAssignment]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leWatchVideoEmbed]:{since:"1.27.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideoEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.leListenAudioEmbed]:{since:"1.27.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudioEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.listItem]:{since:"1.22.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.listItemIndent}]},[l.BitType.standardListItem]:{since:"1.22.0",baseBitType:l.BitType.listItem},[l.BitType.smartStandardListItem]:{since:"1.28.0",baseBitType:l.BitType.standardListItem},[l.BitType.smartStandardListItemCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardListItem},[l.BitType.mark]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_markConfig},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_mark}]},[l.BitType.match]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}],cardSet:i.CardSetConfigKey._matchPairs},[l.BitType.matchAll]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchReverse]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchAllReverse]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchSolutionGrouped]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchMatrix]:{since:"1.3.0",baseBitType:l.BitType.match,cardSet:i.CardSetConfigKey._matchMatrix},[l.BitType.matchAudio]:{since:"1.3.0",baseBitType:l.BitType.match,cardSet:i.CardSetConfigKey._matchAudioPairs},[l.BitType.matchPicture]:{since:"1.3.0",baseBitType:l.BitType.match,cardSet:i.CardSetConfigKey._matchImagePairs},[l.BitType.feedback]:{since:"3.13.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars}],cardSet:i.CardSetConfigKey._feedback},[l.BitType.learningDocumentationFeedback]:{since:"3.13.0",baseBitType:l.BitType.feedback},[l.BitType.multipleChoice1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachSelfReflectionMultipleChoice1]:{since:"1.3.0",baseBitType:l.BitType.multipleChoice1},[l.BitType.multipleChoice]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}],cardSet:i.CardSetConfigKey._quiz},[l.BitType.coachSelfReflectionMultipleChoice]:{since:"1.3.0",baseBitType:l.BitType.multipleChoice},[l.BitType.multipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachCallToActionMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType.multipleChoiceText},[l.BitType.coachSelfReflectionMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType.multipleChoiceText},[l.BitType.multipleResponse1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachSelfReflectionMultipleResponse1]:{since:"1.3.0",baseBitType:l.BitType.multipleResponse1},[l.BitType.multipleResponse]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}],cardSet:i.CardSetConfigKey._quiz},[l.BitType.coachSelfReflectionMultipleResponse]:{since:"1.3.0",baseBitType:l.BitType.multipleResponse},[l.BitType.page]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.thumbImage}]},[l.BitType.pageCollapsible]:{since:"1.30.0",baseBitType:l.BitType.page},[l.BitType.pageCoverImage]:{since:"1.22.0",baseBitType:l.BitType.page},[l.BitType.pageBuyButton]:{since:"1.4.3",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.content2Buy},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageBuyButtonAlt]:{since:"1.31.0",baseBitType:l.BitType.pageBuyButton},[l.BitType.pageBuyButtonPromotion]:{since:"1.5.11",baseBitType:l.BitType.pageBuyButton},[l.BitType.pageSubpage]:{since:"1.6.6",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.page}]},[l.BitType.pageShopInShop]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pageCategory]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pageAcademy]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pagePromotion]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pageSpecial]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pagePerson]:{since:"1.5.16",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_person},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageProduct]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.product}]},[l.BitType.pageProductList]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productList,maxCount:p.Count.infinity}]},[l.BitType.pageProductVideo]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productVideo}]},[l.BitType.pageProductVideoList]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productVideoList,maxCount:p.Count.infinity}]},[l.BitType.pageSectionFolder]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productFolder}]},[l.BitType.photo]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.quote]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quotedPerson}]},[l.BitType.rating]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.coachSelfReflectionRating]:{since:"1.3.0",baseBitType:l.BitType.rating},[l.BitType.releaseNote]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.releaseVersion},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.releaseKind},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.releaseDate}]},[l.BitType.reviewNote]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.resolved},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.resolvedDate},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.resolvedBy}],rootExampleType:u.ExampleType.string},[l.BitType.reviewAuthorNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.reviewCustomerNote]:{since:"3.5.0",baseBitType:l.BitType.reviewNote,textFormatDefault:c.TextFormat.bitmarkPlusPlus},[l.BitType.reviewReviewerNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.reviewRequestForReviewNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.reviewApprovedNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.sampleSolution]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.anchor},{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference}]},[l.BitType.sequence]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}],cardSet:i.CardSetConfigKey._elements,rootExampleType:u.ExampleType.boolean},[l.BitType.stillImageFilm]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceStillImageFilm}],resourceAttachmentAllowed:!1},[l.BitType.stillImageFilmEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceStillImageFilmEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.stillImageFilmLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceStillImageFilmLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.surveyAnonymous]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.survey]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.surveyMatrix]:{since:"1.6.2",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerTop,minCount:1,maxCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerLeft,minCount:1,maxCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption,minCount:1,maxCount:1}]},[l.BitType.surveyMatrixMe]:{since:"1.6.2",baseBitType:l.BitType.surveyMatrix},[l.BitType.surveyRating]:{since:"1.6.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.ratingLevelStart,chain:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.label}]},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.ratingLevelEnd,chain:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.label}]},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.ratingLevelSelected},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.surveyRatingOnce]:{since:"1.6.0",baseBitType:l.BitType.surveyRating},[l.BitType.surveyRatingDisplay]:{since:"1.6.0",baseBitType:l.BitType.surveyRating},[l.BitType.scorm]:{since:"1.5.11",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.scormSource},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.posterImage}]},[l.BitType.pronunciationTable]:{since:"3.1.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._pronunciationTable},[l.BitType.table]:{since:"1.5.19",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.caption},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableFixedHeader},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableSearch},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableSort},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tablePagination},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tablePaginationLimit},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableHeight},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableWhitespaceNoWrap},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableAutoWidth},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableResizableColumns},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableColumnMinWidth}],cardSet:i.CardSetConfigKey._table},[l.BitType.tableAlt]:{since:"1.16.0",baseBitType:l.BitType.table},[l.BitType.standardTableNormative]:{since:"1.16.0",baseBitType:l.BitType.table},[l.BitType.standardTableNonNormative]:{since:"1.16.0",baseBitType:l.BitType.table},[l.BitType.standardRemarkTableNormative]:{since:"1.17.0",baseBitType:l.BitType.table},[l.BitType.standardRemarkTableNonNormative]:{since:"1.17.0",baseBitType:l.BitType.table},[l.BitType.smartStandardTableNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableNormative},[l.BitType.smartStandardTableNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableNonNormative},[l.BitType.smartStandardRemarkTableNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableNormative},[l.BitType.smartStandardRemarkTableNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableNonNormative},[l.BitType.smartStandardTableNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableNormative},[l.BitType.smartStandardTableNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableNonNormative},[l.BitType.smartStandardRemarkTableNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableNormative},[l.BitType.smartStandardRemarkTableNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableNonNormative},[l.BitType.parameters]:{since:"1.18.0",baseBitType:l.BitType.table},[l.BitType.toc]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.tocChapter]:{since:"1.5.5",baseBitType:l.BitType.toc,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.maxDisplayLevel}]},[l.BitType.tocInline]:{since:"3.24.0",baseBitType:l.BitType.toc,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.maxTocChapterLevel}]},[l.BitType.anchor]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.bitBookEnding]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.bitBookSummary]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionAnnounce]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionRatingNumber]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionRemind]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionSave]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionTrueFalse]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.chapterSubjectMatter]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.chat]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.conclusion]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.conclusionAlt]:{since:"1.16.0",baseBitType:l.BitType.conclusion},[l.BitType.documentUpload]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.footNote]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.groupBorn]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.groupDied]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.recordAudio]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.recordVideo]:{since:"1.5.24",baseBitType:l.BitType._standard},[l.BitType.stickyNote]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.takePicture]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.handInAudio]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInContact]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInDocument]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInFile]:{since:"3.2.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.handInAcceptFileType,maxCount:p.Count.infinity}]},[l.BitType.handInLocation]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInPhoto]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInScan]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInSubmit]:{since:"3.2.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.handInRequirement,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.handInInstruction},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.handInVideo]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInVoice]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.trueFalse1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelTrue},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelFalse},{type:s.BitTagType.tag,configKey:a.TagConfigKey.true},{type:s.BitTagType.tag,configKey:a.TagConfigKey.false}],rootExampleType:u.ExampleType.boolean},[l.BitType.trueFalse]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelTrue},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelFalse}],cardSet:i.CardSetConfigKey._statements},[l.BitType.vendorAmcharts5Chart]:{since:"1.5.8",baseBitType:l.BitType.code,tags:[],textFormatDefault:c.TextFormat.json},[l.BitType.vendorDatadogDashboardEmbed]:{since:"3.12.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorDashboardId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorFormbricksEmbed]:{since:"3.8.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorSurveyId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorFormbricksEmbedAnonymous]:{since:"3.9.0",baseBitType:l.BitType.vendorFormbricksEmbed},[l.BitType.vendorFormbricksLink]:{since:"3.8.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorSurveyId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorFormbricksLinkAnonymous]:{since:"3.9.0",baseBitType:l.BitType.vendorFormbricksLink},[l.BitType.vendorHighchartsChart]:{since:"1.5.28",baseBitType:l.BitType.vendorAmcharts5Chart},[l.BitType.vendorIframelyEmbed]:{since:"1.5.10",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorUrl}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorIframelyCard]:{since:"1.5.10",baseBitType:l.BitType.vendorIframelyEmbed},[l.BitType.vendorIframelyPreview]:{since:"1.5.10",baseBitType:l.BitType.vendorIframelyEmbed},[l.BitType.vendorIframelyPreviewMini]:{since:"1.5.10",baseBitType:l.BitType.vendorIframelyEmbed},[l.BitType.vendorJupyterOutput]:{since:"1.4.3",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.jupyterId},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.jupyterExecutionCount}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorJupyterCellCode]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorJupyterCellMarkdown]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorJupyterCellRaw]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorJupyterIpynb]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorPadletEmbed]:{since:"1.3.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.padletId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorStripePricingTable]:{since:"1.20.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.stripePricingTableId,minCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.stripePublishableKey,minCount:1}]},[l.BitType.vendorStripePricingTableExternal]:{since:"3.13.0",baseBitType:l.BitType.vendorStripePricingTable},[l.BitType.video]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideo,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.videoLandscape]:{since:"1.3.0",baseBitType:l.BitType.video},[l.BitType.videoPortrait]:{since:"1.3.0",baseBitType:l.BitType.video},[l.BitType.videoEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideoEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.videoEmbedLandscape]:{since:"1.3.0",baseBitType:l.BitType.videoEmbed},[l.BitType.videoEmbedPortrait]:{since:"1.3.0",baseBitType:l.BitType.videoEmbed},[l.BitType.videoLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideoLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.videoLinkLandscape]:{since:"1.3.0",baseBitType:l.BitType.videoLink},[l.BitType.videoLinkPortrait]:{since:"1.3.0",baseBitType:l.BitType.videoLink},[l.BitType.websiteLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceWebsiteLink,minCount:1}],resourceAttachmentAllowed:!1}};t.BITS=y},6877:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextLocation=void 0;const i=(0,r(4718).superenum)({tag:"tag",body:"body"});t.TextLocation=i},6915:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GroupConfigType=void 0;const i=(0,r(4718).superenum)({standard:"standard",resource:"resource",comboResource:"comboResource"});t.GroupConfigType=i},6936:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.initEnv=t.env=void 0;const i=r(6278),o=r(9561),n=r(2287),a=r(5659);const s=new class{constructor(){Object.defineProperty(this,"userAgentInfo",{value:(0,a.parseUserAgent)(),enumerable:!1}),this.bootTimestamp=Date.now(),this.app="",this.appVersion=n.EMPTY_VERSION,this.environment=this.getEnvironment(),this.environmentVersion=this.getEnvironmentVersion(),this.isBrowser=this.getIsBrowser(),this.isNode=this.environment===i.Environment.node,this.isCI=this.getIsCI(),this.NODE_ENV=this.getNodeEnv(),this.os=this.getOs(),this.osVersion=this.getOsVersion()}init(e,t){this.app=e,this.appVersion=this.parseMMBVersion(t)}get upTimestamp(){return Date.now()-this.bootTimestamp}getEnvironment(){return this.userAgentInfo?this.userAgentInfo.browser:"undefined"!=typeof process&&void 0!==process.versions&&process.versions.node?i.Environment.node:i.Environment.unknown}getEnvironmentVersion(){return this.userAgentInfo?this.parseMMBVersion(this.userAgentInfo.browserVersion):"undefined"!=typeof process?this.parseMMBVersion(process.version):n.EMPTY_VERSION}getOs(){return this.userAgentInfo?this.userAgentInfo.os:("undefined"!=typeof process&&void 0!==process.versions&&process.versions.node,o.Os.unknown)}getOsVersion(){return this.userAgentInfo?this.parseMMBVersion(this.userAgentInfo.osVersion):"undefined"!=typeof process?this.parseMMBVersion(""):n.EMPTY_VERSION}getIsBrowser(){return!("undefined"==typeof window||"undefined"==typeof document||"undefined"==typeof navigator||!navigator.userAgent)}getIsCI(){return!("undefined"==typeof process||!process.env||!process.env.CI)}getNodeEnv(){return"undefined"!=typeof process&&process.env?"production":""}parseMMBVersion(e){if(!e)return n.EMPTY_VERSION;e.startsWith("v")&&(e=e.substring(1));const t=e.split(".",1e3);let r="",i="",o="",a="";for(let e=0,n=t.length;e<n;e++){const n=t[e];0===e?r=n:1===e?i=n:2===e?a=n:3===e&&(o=n)}return{full:e,major:r,minor:i,patch:a,build:o}}};t.env=s;const l=s.init.bind(s);t.initEnv=l},6989:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ArrayUtils=void 0;const r=new class{asArray(e){if(null!=e)return Array.isArray(e)?e:[e]}asSingle(e,t){if(null!=e)return Array.isArray(e)?e.length>0?t?e[e.length-1]:e[0]:void 0:e}};t.ArrayUtils=r},6991:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.commentTagContentProcessor=function(e,t,r,o){if(!o.internalComments)return;const{value:n}=r,a=i.StringUtils.isString(n)?i.StringUtils.trimmedString(n):void 0;if(!a)return;o.internalComments.push(a)};const i=r(9681)},7112:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.groupConfigKeys=t.GroupConfigKey=void 0;const i=r(4718),o={group_standardAllBits:"group_standardAllBits",group_standardItemLeadInstructionHint:"group_standardItemLeadInstructionHint",group_standardExample:"group_standardExample",group_standardTags:"group_standardTags",group_imageSource:"group_imageSource",group_technicalTerm:"group_technicalTerm",group_person:"group_person",group_gap:"group_gap",group_trueFalse:"group_trueFalse",group_markConfig:"group_markConfig",group_mark:"group_mark",group_bookCommon:"group_bookCommon",group_learningPathCommon:"group_learningPathCommon",group_quizCommon:"group_quizCommon",group_resourceBitTags:"group_resourceBitTags",group_resourceCommon:"group_resourceCommon",group_resourceImageCommon:"group_resourceImageCommon",group_resourceAudioCommon:"group_resourceAudioCommon",group_resourceVideoCommon:"group_resourceVideoCommon",group_resourceIcon:"group_resourceIcon",group_resourceImage:"group_resourceImage",group_resourceImageEmbed:"group_resourceImageEmbed",group_resourceImageLink:"group_resourceImageLink",group_resourceImageResponsive:"group_resourceImageResponsive",group_resourceImagePortrait:"group_resourceImagePortrait",group_resourceImageLandscape:"group_resourceImageLandscape",group_resourceAudio:"group_resourceAudio",group_resourceAudioEmbed:"group_resourceAudioEmbed",group_resourceAudioLink:"group_resourceAudioLink",group_resourceVideo:"group_resourceVideo",group_resourceVideoEmbed:"group_resourceVideoEmbed",group_resourceVideoLink:"group_resourceVideoLink",group_resourceStillImageFilm:"group_resourceStillImageFilm",group_resourceStillImageFilmEmbed:"group_resourceStillImageFilmEmbed",group_resourceStillImageFilmLink:"group_resourceStillImageFilmLink",group_resourceArticle:"group_resourceArticle",group_resourceArticleEmbed:"group_resourceArticleEmbed",group_resourceArticleLink:"group_resourceArticleLink",group_resourceDocument:"group_resourceDocument",group_resourceDocumentEmbed:"group_resourceDocumentEmbed",group_resourceDocumentLink:"group_resourceDocumentLink",group_resourceDocumentDownload:"group_resourceDocumentDownload",group_resourceAppLink:"group_resourceAppLink",group_resourceWebsiteLink:"group_resourceWebsiteLink"};t.groupConfigKeys=o;const n=(0,i.superenum)(o);t.GroupConfigKey=n},7124:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkPegParserProcessor=void 0;const o=r(5809),n=r(7735),a=r(2028),s=r(5854),l=r(6149),p=r(385),u=r(6877),c=r(9681),y=r(4266),g=r(5033),d=r(1083),f=r(4402),m=r(4382),T=r(3904),h=r(9289),b=r(5189),B=r(9647),v=r(3990),C=r(6521),P=r(7667),x=r(9885),k=r(3029),K=!1,w=!0,_=!0,S=!0,A=!0,L=new o.Builder;t.BitmarkPegParserProcessor=class{constructor(e){this.nonFatalWarnings=[],this.nonFatalErrors=[],this.parser={},this.parse=e.parse,this.parserText=e.parserText,this.parserLocation=e.parserLocation,this.context={bitConfig:a.Config.getBitConfig(s.BitType._error),bitType:s.BitType._error,textFormat:p.TextFormat.bitmarkMinusMinus,DEBUG_BIT_RAW:true,DEBUG_BIT_CONTENT_RAW:K,DEBUG_BIT_CONTENT:w,DEBUG_BIT_TAGS:_,DEBUG_BODY:S,DEBUG_FOOTER:A,DEBUG_CHAIN_CONTENT:true,DEBUG_CHAIN_TAGS:true,DEBUG_CARD_SET_CONTENT:true,DEBUG_CARD_SET:true,DEBUG_CARD_TAGS:true,parser:this.parser,parse:this.parse,bitContentProcessor:this.bitContentProcessor.bind(this),splitBitContent:this.splitBitContent.bind(this),addWarning:this.addWarning.bind(this),addError:this.addError.bind(this),debugPrint:this.debugPrint.bind(this),state:{}}}buildBits(e){var t;const r=[];let i=[];for(const o of e){if(!o)continue;const e=o.value;e?r.push(e):i=i.concat(null!==(t=o.errors)&&void 0!==t?t:[])}return L.buildBitmark({bits:r,errors:i.length>0?i:void 0})}buildBit(e,t){var r;const{bitType:o,textFormat:n,resourceType:l,bitLevel:p,isCommented:u}=e;if(!o||a.Config.isOfBitType(o,s.BitType._error))return this.invalidBit();const c=a.Config.getBitConfig(o);this.context.bitConfig=c,this.context.bitType=o,this.context.textFormat=n,this.context.resourceType=l;const g=a.Config.isOfBitType(o,s.BitType.trueFalse1),f=a.Config.isOfBitType(o,s.BitType.multipleChoice1),m=a.Config.isOfBitType(o,s.BitType.multipleResponse1);this.debugPrint("BIT CONTENT",t),this.resetParserState(),t=this.squashUnwantedInlineBodyBits(t),t=y.BitmarkPegParserValidator.validateBitTags(this.context,t);const T=this.bitContentProcessor(k.BitContentLevel.Bit,c.tags,t),{body:h,footer:b,cardSet:B,title:v,statement:x,statements:K,choices:w,responses:_,propertyStyleResources:S,resources:A,posterImage:I,internalComments:F}=T,N=i(T,["body","footer","cardSet","title","statement","statements","choices","responses","propertyStyleResources","resources","posterImage","internalComments"]);this.debugPrint("BIT TAGS",N),this.debugPrint("BIT BODY",h),this.debugPrint("BIT FOOTER",b);const O=(0,P.buildTitles)(this.context,o,v),E=(0,d.buildCards)(this.context,o,n,B,x,K,w,_),R=(0,C.buildResources)(this.context,l,A),V=[...null!=F?F:[],...null!==(r=E.internalComments)&&void 0!==r?r:[]],j=this.buildBitLevelWarnings(),M=this.buildBitLevelErrors();j&&(this.parser.warnings=j),M&&(this.parser.errors=M);return{value:L.buildBit(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({bitType:o,bitLevel:p,isCommented:u,textFormat:n,resourceType:l},O),{posterImage:I,statement:g?x:void 0,choices:f?w:void 0,responses:m?_:void 0}),N),S),{resources:R}),E),{body:h,footer:b,internalComment:V,parser:this.parser}))}}invalidBit(e){e&&this.addError("Invalid bit"),this.parser.errors=this.buildBitLevelErrors();return{value:L.buildBit({bitType:a.Config.getBitType(s.BitType._error),bitLevel:1,parser:this.parser})}}buildBitHeader(e,t,r){const i=n.Breakscape.unbreakscape(e,{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag}),o=a.Config.getBitType(i),c=a.Config.isBitTypeCommented(i);a.Config.isOfBitType(o,s.BitType._error)&&this.addError(`Invalid bit type: '${i}'`);const y=a.Config.getBitConfig(o);t>a.Config.bitLevelMax?(this.addWarning(`Bit level of ${t} too high, setting to max value of ${a.Config.bitLevelMax}`),t=a.Config.bitLevelMax):t<a.Config.bitLevelMin&&(this.addWarning(`Bit level of ${t} too low, setting to min value of ${a.Config.bitLevelMin}`),t=a.Config.bitLevelMin);let g=p.TextFormat.fromValue(r.textFormat);r.textFormat&&!g&&this.addWarning(`Invalid text format '${r.textFormat}', defaulting to '${y.textFormatDefault}'`),g=null!=g?g:y.textFormatDefault;const d=l.ResourceTag.fromValue(r.resourceType);return r.resourceType&&!d&&this.addWarning(`Invalid resource type '${r.resourceType}', it will be ignored`),{bitType:o,bitLevel:t,textFormat:null!=g?g:y.textFormatDefault,resourceType:d,isCommented:c}}buildTextAndResourceType(e,t){const r={},i=e=>{if(e){const t=n.Breakscape.unbreakscape(c.StringUtils.string(e.value),{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag});e.type===k.TypeKey.TextFormat?r.textFormat=t:r.resourceType=t}};return i(e),i(t),r}resetParserState(){this.context.state={}}squashUnwantedInlineBodyBits(e){const t=[];if(!e)return t;const{textFormat:r}=this.context,i=r===p.TextFormat.bitmarkMinusMinus||r===p.TextFormat.bitmarkPlusPlus,o=(e,t="")=>{const{chain:r,parser:i}=e;if(t+=i.text,r)for(const e of r)t=o(e,t);return t};let n=!1;for(const r of e){const{type:e,value:a}=r,s=null!=a?a:"";let l=!1;if(n||(e===k.TypeKey.BodyText&&!i&&s&&s.trim()&&(n=!0),e===k.TypeKey.PlainTextDivider&&(n=!0,l=!0)),l)t.push({type:k.TypeKey.BodyText,value:"\n"});else if(n)if(e===k.TypeKey.BodyText)t.push({type:k.TypeKey.BodyTextPlain,value:a});else{const e=o(r);t.push({type:k.TypeKey.BodyTextPlain,value:e})}else t.push(r)}return t}bitContentProcessor(e,t,r){const i={};if(!r)return i;const{bitType:o,textFormat:a}=this.context;i.title=[],i.solutions=[],i.__solutionsAst=[],i.statements=[],i.choices=[],i.responses=[],i.propertyStyleResources={},i.resources=[],i.trueFalse=[],i.markConfig=[],i.extraProperties={},i.internalComments=[];let s=!1,l=!1;const p=[];let u=n.Breakscape.EMPTY_STRING,c=n.Breakscape.EMPTY_STRING,d=n.Breakscape.EMPTY_STRING,K=n.Breakscape.EMPTY_STRING;const w=e===k.BitContentLevel.Bit,_=e===k.BitContentLevel.Card,S=e===k.BitContentLevel.Chain,A=()=>{if(u){u=y.BitmarkPegParserValidator.checkBodyPart(this.context,e,u);const t=g.BodyContentProcessor.buildBodyText(u,!1);p.push(t)}u=n.Breakscape.EMPTY_STRING};for(const o of r){const{type:r,value:a}=o;switch(r){case k.TypeKey.ItemLead:(0,h.itemLeadChainContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Instruction:case k.TypeKey.Hint:case k.TypeKey.Anchor:case k.TypeKey.SampleSolution:(0,f.defaultTagContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Reference:(0,v.referenceTagContentProcessor)(this.context,e,t,o,i,s),s=!0;break;case k.TypeKey.Title:(0,P.titleTagContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Property:(0,B.propertyContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Gap:S||A(),(0,T.gapChainContentProcessor)(this.context,e,t,o,i,p);break;case k.TypeKey.Mark:S||A(),(0,b.markChainContentProcessor)(this.context,e,t,o,i,p);break;case k.TypeKey.True:case k.TypeKey.False:S||A(),(0,x.trueFalseChainContentProcessor)(this.context,e,t,o,i,p);break;case k.TypeKey.Resource:(0,C.resourceContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.CardSet:i.cardSet=a,l=!0;break;case k.TypeKey.BodyText:case k.TypeKey.CardText:l?c=n.Breakscape.concatenate(c,a):u=n.Breakscape.concatenate(u,a);break;case k.TypeKey.BodyTextPlain:l?K=n.Breakscape.concatenate(K,a):d=n.Breakscape.concatenate(d,a);break;case k.TypeKey.FooterDivider:l&&(c=n.Breakscape.concatenate(c,a)),l=!0}}A();const L=d?g.BodyContentProcessor.buildBodyText(d,!0):void 0;if(L&&p.push(L),i.itemLead){const e=i.itemLead.length;e>0&&(i.item=i.itemLead[0]),e>1&&(i.lead=i.itemLead[1]),e>2&&(i.pageNumber=i.itemLead[2]),e>3&&(i.marginNumber=i.itemLead[e-1])}return w?i.body=g.BodyContentProcessor.process(this.context,e,o,a,t,i,p,!1):_&&(i.cardBody=g.BodyContentProcessor.process(this.context,e,o,a,t,i,p,!0)),i.footer=m.FooterContentProcessor.process(this.context,e,t,i,c,K),0===Object.keys(i.extraProperties).length&&delete i.extraProperties,0===i.title.length&&delete i.title,0===i.solutions.length&&delete i.solutions,0===i.statements.length&&delete i.statements,0===i.choices.length&&delete i.choices,0===i.responses.length&&delete i.responses,0===i.trueFalse.length&&delete i.trueFalse,0===i.markConfig.length&&delete i.markConfig,0===Object.keys(i.propertyStyleResources).length&&delete i.propertyStyleResources,0===i.resources.length&&delete i.resources,0===i.internalComments.length&&delete i.internalComments,i}buildBitLevelWarnings(){let e;return this.nonFatalWarnings.length>0&&(e=this.nonFatalWarnings,this.nonFatalWarnings=[]),e}buildBitLevelErrors(){let e;return this.nonFatalErrors.length>0&&(e=this.nonFatalErrors,this.nonFatalErrors=[]),e}splitBitContent(e,t){const r=[];let i=[];for(const o of e)t.includes(o.type)&&(i.length>0&&r.push(i),i=[]),i.push(o);return i.length>0&&r.push(i),r}addWarning(e,t,r){var i,o,n;const a={message:e,text:null!==(i=null==t?void 0:t.parser.text)&&void 0!==i?i:this.parserText(),location:null!==(o=null==t?void 0:t.parser.location)&&void 0!==o?o:this.parserLocation(),original:null!==(n=null==r?void 0:r.parser)&&void 0!==n?n:void 0};a.original||delete a.original,this.nonFatalWarnings.push(a)}addError(e,t,r){var i,o,n;const a={message:e,text:null!==(i=null==t?void 0:t.parser.text)&&void 0!==i?i:this.parserText(),location:null!==(o=null==t?void 0:t.parser.location)&&void 0!==o?o:this.parserLocation(),original:null!==(n=null==r?void 0:r.parser)&&void 0!==n?n:void 0};a.original||delete a.original,this.nonFatalErrors.push(a)}debugPrint(e,t){}}},7203:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyAstKey=void 0;const i=(0,r(4718).superenum)({ast_isCaseSensitive:"isCaseSensitive",ast_referenceProperty:"referenceProperty",ast_markConfig:"markConfig",ast_productList:"productList",ast_productVideoList:"productVideoList"});t.PropertyAstKey=i},7461:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PeggyGrammarLocation=void 0;t.PeggyGrammarLocation=class{constructor(e,t){this.source=e,this.start=t}toString(){return String(this.source)}offset(e){return{line:e.line+this.start.line-1,column:1===e.line?e.column+this.start.column-1:e.column,offset:e.offset+this.start.offset}}static offsetStart(e){return e.source&&"function"==typeof e.source.offset?e.source.offset(e.start):e.start}static offsetEnd(e){return e.source&&"function"==typeof e.source.offset?e.source.offset(e.end):e.end}}},7667:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.titleTagContentProcessor=function(e,t,r,i,o){const{textFormat:s}=e,{value:l}=i,p=o.title;if(!p)return;const u=l,c=n.StringUtils.trimmedString(u.title),y=u.level.length;p[y]={titleAst:a.toAst(null!=c?c:"",{textFormat:s,isProperty:!0}),titleString:null!=c?c:""}},t.buildTitles=function(e,t,r){var n,a,s,l,p,u,c,y,g,d;if(r=null!=r?r:[],i.Config.isOfBitType(t,o.BitType.chapter)){let e;return r.length>0&&(e=r[r.length-1]),{title:null!==(n=null==e?void 0:e.titleAst)&&void 0!==n?n:[],titleString:null!==(a=null==e?void 0:e.titleString)&&void 0!==a?a:"",level:r.length>0?r.length-1:void 0}}return{title:null!==(l=null===(s=r[1])||void 0===s?void 0:s.titleAst)&&void 0!==l?l:void 0,titleString:null!==(u=null===(p=r[1])||void 0===p?void 0:p.titleString)&&void 0!==u?u:void 0,subtitle:null!==(y=null===(c=r[2])||void 0===c?void 0:c.titleAst)&&void 0!==y?y:void 0,subtitleString:null!==(d=null===(g=r[2])||void 0===g?void 0:g.titleString)&&void 0!==d?d:void 0}};const i=r(2028),o=r(5854),n=r(9681),a=new(r(777).TextParser)},7678:(e,t,r)=>{const{deserialize:i}=r(5005),{serialize:o}=r(5416);Object.defineProperty(t,"__esModule",{value:!0}).default="function"==typeof structuredClone?(e,t)=>t&&("json"in t||"lossy"in t)?i(o(e,t)):structuredClone(e):(e,t)=>i(o(e,t)),t.deserialize=i,t.serialize=o},7735:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Breakscape=void 0;const i=r(385),o=r(6877),n=r(9681),a=/([*`_!=])(?=\1)/,s=/(\[)([.@#▼►%!?+\-$_=&])/,l=/^(~)(~~~[ \t]*)$/,p=/^(\$)(\$\$\$[ \t]*)$/,u=/(\^*])/,c=/(\^+)/,y=`${u.source}|${c.source}`,g=`${a.source}|${s.source}|${l.source}|${p.source}|${c.source}`,d=`${a.source}|${/^(\|)(code[\s]*|code:|image:|[\s]*$)/.source}|${/^([#]{1,3})([^\S\r\n]+)/.source}|${/^(•)([0-9]+[iI]*|[a-zA-Z]{1}|_|\+|-|)([^\S\r\n]+)/.source}|${s.source}|${l.source}|${p.source}|${c.source}`,f=`${/^(\[)(\^*)(\.)/.source}`,m=new RegExp(`${a.source}|${u.source}|${c.source}`,"gm"),T=new RegExp(y,"gm"),h=new RegExp(g,"gm"),b=new RegExp(d,"gm"),B=new RegExp(f,"gm"),v=new RegExp("^(?:(\\[)(\\^*)(\\.))|(\\^+)","gm"),C="$1$4^$2$3",P=new RegExp("\\^([\\^]*)","gm"),x=new RegExp("^(\\[)\\^(\\^*)(\\.)","gm"),k=new RegExp("^(\\||•|#)","gm"),K={textFormat:i.TextFormat.bitmarkMinusMinus,textLocation:o.TextLocation.body};const w=new class{constructor(){this.EMPTY_STRING=""}breakscape(e,t){if(null==e)return e;const r=Object.assign({},K,t),{regex:i,replacer:o}=this.selectBreakscapeRegexAndReplacer(r.textFormat,r.textLocation,r.v2),a=e=>e?e=e.replace(i,o):e;if(Array.isArray(e)){const t=r.modifyArray?e:new Array(e.length);for(let r=0,i=e.length;r<i;r++){const i=e[r];n.StringUtils.isString(i)&&(t[r]=a(i))}e=t}else n.StringUtils.isString(e)&&(e=a(e));return e}unbreakscape(e,t){if(null==e)return e;const r=Object.assign({},K,t),{regex:i,replacer:o}=this.selectUnbreakscapeRegexAndReplacer(r.textFormat,r.textLocation),a=e=>e?e=e.replace(i,o):e;if(Array.isArray(e)){const t=r.modifyArray?e:new Array(e.length);for(let r=0,i=e.length;r<i;r++){const i=e[r];n.StringUtils.isString(i)?t[r]=a(i):t[r]=i}e=t}else n.StringUtils.isString(e)&&(e=a(e));return e}breakscapeCode(e,t){if(null==e)return e;const r=Object.assign({},K,t),i=e=>e?e.replace(k,"$1^"):e;if(Array.isArray(e)){const t=r.modifyArray?e:[e.length];for(let t=0,r=e.length;t<r;t++){const r=e[t];n.StringUtils.isString(r)&&(e[t]=i(r))}e=t}else n.StringUtils.isString(e)&&(e=i(e));return e}selectBreakscapeRegexAndReplacer(e,t,r){let n,a;return t===o.TextLocation.tag?(n=T,a="$2^$1",r||e!==i.TextFormat.bitmarkMinusMinus&&e!==i.TextFormat.bitmarkPlusPlus||(n=m,a="$1$3^$2")):(n=B,a="$1^$2$3",e===i.TextFormat.bitmarkMinusMinus?r?(n=v,a=C):(n=h,a="$1$2$4$6^$3$5$7$8"):e===i.TextFormat.bitmarkPlusPlus&&(r?(n=v,a=C):(n=b,a="$1$2$4$6$9$11$13$15^$3$5$7$8$10$12$14"))),{regex:n,replacer:a}}selectUnbreakscapeRegexAndReplacer(e,t){const r=!(e===i.TextFormat.bitmarkMinusMinus||e===i.TextFormat.bitmarkPlusPlus);let n=P,a="$1";return t===o.TextLocation.body&&r&&(n=x,a="$1$2$3"),{regex:n,replacer:a}}concatenate(e,t){return e+t}};t.Breakscape=w},7797:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.tagConfigKeys=t.TagConfigKey=void 0;const i=r(4718),o={title:"title",anchor:"anchor",tag_reference:"tag_reference",property:"property",itemLead:"itemLead",instruction:"instruction",hint:"hint",true:"true",false:"false",sampleSolution:"sampleSolution",gap:"gap",tag_mark:"tag_mark",resource:"resource"};t.tagConfigKeys=o;const n=(0,i.superenum)(o);t.TagConfigKey=n},7984:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonObjectGenerator=void 0;const o=r(6772),n=r(2497);t.JsonObjectGenerator=class{constructor(e){this.writer=new o.StringWriter,this.generator=new n.JsonGenerator(this.writer,e)}generate(e){return i(this,void 0,void 0,(function*(){return yield this.generator.generate(e),JSON.parse(this.writer.getString())}))}generateSync(e){return this.generator.generateSync(e),JSON.parse(this.writer.getString())}}},8025:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.NumberUtils=void 0;const r=new class{asNumber(e,t){if(null==e)return null!=t?t:void 0;const r=+e;return Number.isNaN(r)||!isFinite(r)?null!=t?t:void 0:r}isNumeric(e){if(null==e)return!1;const t=+e;return!Number.isNaN(t)&&isFinite(t)}};t.NumberUtils=r},8199:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardSetConfigKey=void 0;const i=(0,r(4718).superenum)({_flashcard:"_flashcard",_definitionList:"_definitionList",_elements:"_elements",_statements:"_statements",_quiz:"_quiz",_feedback:"_feedback",_questions:"_questions",_matchPairs:"_matchPairs",_matchAudioPairs:"_matchAudioPairs",_matchImagePairs:"_matchImagePairs",_matchMatrix:"_matchMatrix",_table:"_table",_pronunciationTable:"_pronunciationTable",_botActionResponses:"_botActionResponses",_exampleBitList:"_exampleBitList",_clozeList:"_clozeList",_ingredients:"_ingredients",_bookReferenceList:"_bookReferenceList"});t.CardSetConfigKey=i},8216:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.itemLeadTagContentProcessor=function(e,t,r,n,a){const{textFormat:s}=e,{value:l}=n,p=new o.TextParser,u=i.StringUtils.trimmedString(l);a.itemLead||(a.itemLead=[]);const c=p.toAst(u,{textFormat:s,isProperty:!0});a.itemLead.push(c)};const i=r(9681),o=r(777)},8321:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.StartRules=void 0,t.SyntaxError=p,t.parse=c;const i=r(7735),o="8.32.1";function n(e){return"string"!=typeof e?null:i.Breakscape.unbreakscape(e)}function a(e){e&&"object"==typeof e&&(delete e._tempParsingParent,delete e._tempListStart,Object.keys(e).forEach((t=>{a(e[t])})))}function s(e){function t(e){for(let i=e.length-1;i>=0;i--){const o=e[i];!(r=o)||"object"!=typeof r||"text"!==r.type||""!==r.text&&null!=r.text?o&&"object"==typeof o&&Array.isArray(o.content)&&t(o.content):e.splice(i,1)}var r}return Array.isArray(e)?t(e):e&&"object"==typeof e&&Array.isArray(e.content)&&t(e.content),e}function l(e){return"undefined"!=typeof parser?parser.parse(e,{startRule:"bitmarkPlusString"}):c(e,{startRule:"bitmarkPlusString"})}function p(e,t,r,i){var o=Error.call(this,e);return Object.setPrototypeOf&&Object.setPrototypeOf(o,p.prototype),o.expected=t,o.found=r,o.location=i,o.name="SyntaxError",o}function u(e,t,r){return r=r||" ",e.length>t?e:(t-=e.length,e+(r+=r.repeat(t)).slice(0,t))}function c(e,t){var r,i={},u=(t=void 0!==t?t:{}).grammarSource,c={version:qn,bitmarkPlusPlus:function(){var e,t;if(Mn++,e=[],(t=Hn())!==i)for(;t!==i;)e.push(t),t=Hn();else e=i;e===i&&(e=function(){var e,t;return e=En,t="",t=Xi(),e=t,e}());Mn--,e===i&&(t=i,0===Mn&&Wn(wt));return e},bitmarkPlus:function(){var e,t;Mn++,e=En,t=Pa(),t=Do(t),e=t,Mn--,t=i,0===Mn&&Wn(wt);return e},bitmarkMinusMinus:function(){var e,t;Mn++,e=En,t=Ia(),t=Kn(t),e=t,Mn--,t=i,0===Mn&&Wn(wi);return e},bitmarkPlusString:function(){var e;Mn++,e=Pa(),Mn--,0===Mn&&Wn(sr);return e},bitmarkMinusMinusString:Ia},y=qn,g="|",d="### ",f="## ",m="# ",T="code",h=":",b="bitmark++",B="bitmark--",v="JavaScript",C="• ",P="•_ ",x="•",k=" ",K="I ",w="i ",_="•A ",S="•a ",A="•+ ",L="•- ",I="\t",F="image",N="#",O="@",E="width",R="height",V="alignment",j="captionAlign",M="left",D="center",G="right",U="=",$="|latex|",J="|imageInline:",W="alignmentVertical",z="size",q="top",H="middle",Y="bottom",X="baseline",Q="sub",Z="super",ee="text-bottom",te="text-top",re="line-height",ie="font-height",oe="explicit",ne="link:",ae="extref:",se="provider:",le="xref:",pe="►",ue="symbol:",ce="footnote:",ye="footnote*:",ge="var:",de="code:",fe="timer",me="timer:",Te="duration:",he="P",be="color:",Be="|►",ve="bold",Ce="italic",Pe="light",xe="highlight",ke="strike",Ke="subscript",we="superscript",_e="ins",Se="del",Ae="underline",Le="doubleUnderline",Ie="circle",Fe="languageEm",Ne="userUnderline",Oe="userDoubleUnderline",Ee="userStrike",Re="userCircle",Ve="userHighlight",je="notranslate",Me="aqua",De="black",Ge="blue",Ue="pink",$e="fuchsia",Je="lightgrey",We="gray",ze="darkgray",qe="green",He="lime",Ye="magenta",Xe="maroon",Qe="navy",Ze="olive",et="orange",tt="purple",rt="red",it="silver",ot="teal",nt="violet",at="white",st="yellow",lt="*",pt="_",ut="`",ct="!",yt="[!",gt="]",dt="\n",ft="\r\n",mt="http",Tt="s",ht="://",bt="mailto:",Bt=/^[ \t]/,vt=/^[0-9]/,Ct=/^[:|]/,Pt=/^[\r\u2028-\u2029]/,xt=/^[^\n\r\u2028\u2029]/,kt=/^[!#-;=?-[\]-_a-{}-~]/,Kt={type:"any"},wt=Un("StyledText"),_t=Dn("|",!1),St=Dn("### ",!1),At=Dn("## ",!1),Lt=Dn("# ",!1),It=Dn("code",!1),Ft=Gn([" ","\t"],!1,!1),Nt=Dn(":",!1),Ot=Dn("bitmark++",!1),Et=Dn("bitmark--",!1),Rt=Dn("JavaScript",!1),Vt=Dn("• ",!1),jt=Dn("•_ ",!1),Mt=Dn("•",!1),Dt=Gn([["0","9"]],!1,!1),Gt=Dn(" ",!1),Ut=Dn("I ",!1),$t=Dn("i ",!1),Jt=Dn("•A ",!1),Wt=Dn("•a ",!1),zt=Dn("•+ ",!1),qt=Dn("•- ",!1),Ht=Dn("\t",!1),Yt=Dn("image",!1),Xt=Dn("#",!1),Qt=Dn("@",!1),Zt=Gn([":","|"],!1,!1),er=Dn("width",!1),tr=Dn("height",!1),rr=Dn("alignment",!1),ir=Dn("captionAlign",!1),or=Dn("left",!1),nr=Dn("center",!1),ar=Dn("right",!1),sr=Un("StyledString"),lr=Dn("=",!1),pr=Dn("|latex|",!1),ur=Dn("|imageInline:",!1),cr=Dn("alignmentVertical",!1),yr=Dn("size",!1),gr=Dn("top",!1),dr=Dn("middle",!1),fr=Dn("bottom",!1),mr=Dn("baseline",!1),Tr=Dn("sub",!1),hr=Dn("super",!1),br=Dn("text-bottom",!1),Br=Dn("text-top",!1),vr=Dn("line-height",!1),Cr=Dn("font-height",!1),Pr=Dn("explicit",!1),xr=Dn("link:",!1),kr=Dn("extref:",!1),Kr=Dn("provider:",!1),wr=Dn("xref:",!1),_r=Dn("►",!1),Sr=Dn("symbol:",!1),Ar=Dn("footnote:",!1),Lr=Dn("footnote*:",!1),Ir=Dn("var:",!1),Fr=Dn("code:",!1),Nr=Dn("timer",!1),Or=Dn("timer:",!1),Er=Dn("duration:",!1),Rr=Dn("P",!1),Vr=Dn("color:",!1),jr=Dn("|►",!1),Mr=Dn("bold",!1),Dr=Dn("italic",!1),Gr=Dn("light",!1),Ur=Dn("highlight",!1),$r=Dn("strike",!1),Jr=Dn("subscript",!1),Wr=Dn("superscript",!1),zr=Dn("ins",!1),qr=Dn("del",!1),Hr=Dn("underline",!1),Yr=Dn("doubleUnderline",!1),Xr=Dn("circle",!1),Qr=Dn("languageEm",!1),Zr=Dn("userUnderline",!1),ei=Dn("userDoubleUnderline",!1),ti=Dn("userStrike",!1),ri=Dn("userCircle",!1),ii=Dn("userHighlight",!1),oi=Dn("notranslate",!1),ni=Dn("aqua",!1),ai=Dn("black",!1),si=Dn("blue",!1),li=Dn("pink",!1),pi=Dn("fuchsia",!1),ui=Dn("lightgrey",!1),ci=Dn("gray",!1),yi=Dn("darkgray",!1),gi=Dn("green",!1),di=Dn("lime",!1),fi=Dn("magenta",!1),mi=Dn("maroon",!1),Ti=Dn("navy",!1),hi=Dn("olive",!1),bi=Dn("orange",!1),Bi=Dn("purple",!1),vi=Dn("red",!1),Ci=Dn("silver",!1),Pi=Dn("teal",!1),xi=Dn("violet",!1),ki=Dn("white",!1),Ki=Dn("yellow",!1),wi=Un("MinimalStyledText"),_i=Un("MinimalStyledString"),Si=Dn("*",!1),Ai=Dn("_",!1),Li=Dn("`",!1),Ii=Dn("!",!1),Fi=Dn("[!",!1),Ni=Dn("]",!1),Oi=Un("Line Terminator"),Ei=Dn("\n",!1),Ri=Dn("\r\n",!1),Vi=Gn(["\r",["\u2028","\u2029"]],!1,!1),ji=(Un("whitespace in line"),Un("space"),Un("language tag separator"),Un("white space, separator"),Gn(["\t","\v","\f"," "," ","\ufeff"," "," "," ",[" "," "]," "," "," "],!1,!1),Gn(["\n","\r","\u2028","\u2029"],!1,!1),Gn(["\n","\r","\u2028","\u2029"],!0,!1)),Mi=(Gn(["\n","\r","\u2028","\u2029","\t","\v","\f"," "," ","\ufeff"," "," "," ",[" "," "]," "," "," "],!0,!1),Dn("http",!1)),Di=Dn("s",!1),Gi=Dn("://",!1),Ui=Dn("mailto:",!1),$i=Gn(["!",["#",";"],"=",["?","["],["]","_"],["a","{"],["}","~"]],!1,!1),Ji=function(){return o},Wi=function(e){return s(Object.assign({},e))},zi=function(e){let t=Object.assign({},e);a(t);return s(t)},qi=function(e){return Object.assign({},e)},Hi=function(e){return Object.assign({},e)},Yi=function(e){return s(Object.assign({},e))},Xi=function(){return[]},Qi=function(e,t){return{type:"heading",content:l(t),attrs:{level:e.length-1}}},Zi=function(e){return e},eo=function(e,t){return Object.assign(Object.assign({},e),{content:t})},to=function(){return{type:"codeBlock",language:""}},ro=function(e){return{type:"codeBlock",attrs:{language:e.trim().toLowerCase()}}},io=function(e){return[{type:"text",text:n(e.trim())}]},oo=function(e){return e},no=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},ao=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},so=function(e,t){let r=t[0]._tempListStart;return Object.assign(Object.assign({},e),{attrs:{start:r},content:t})},lo=function(e,t){let r=t[0]._tempListStart;return Object.assign(Object.assign({},e),{attrs:{start:r},content:t})},po=function(e,t){let r=t[0]._tempListStart;return Object.assign(Object.assign({},e),{attrs:{start:r},content:t})},uo=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},co=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},yo=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},go=function(){return{type:"bulletList"}},fo=function(){return{type:"noBulletList"}},mo=function(){return{type:"orderedList"}},To=function(){return{type:"orderedListRoman"}},ho=function(){return{type:"orderedListRomanLower"}},bo=function(){return{type:"letteredList"}},Bo=function(){return{type:"letteredListLower"}},vo=function(){return{type:"taskList"}},Co=function(e,t,r,i){return i},Po=function(e,t,r,i){let o="bulletList";const n=e.match(/•([0-9]+)([Ii]?) /);let a=1;if(n&&(o="orderedList",n.length>1&&(a=Number(n[1])),n.length>2)){let e=n[2];"I"==e&&(o="orderedListRoman"),"i"==e&&(o="orderedListRomanLower")}"•_ "==e&&(o="noBulletList"),"•A "==e&&(o="letteredList"),"•a "==e&&(o="letteredListLower"),"•+ "!=e&&"•- "!=e||(o="taskList");let s=[{type:"paragraph",attrs:{},content:l((t+r.join("")).trim())}];if(i&&i[0]&&i[0]._tempParsingParent){let e={type:i[0]._tempParsingParent,attrs:{start:a},content:i};if((e.type.startsWith("orderedList")||e.type.startsWith("letteredList"))&&i[0]._tempListStart){const t=i[0]._tempListStart;t>1&&(e.attrs.start=t)}s.push(e)}let p="listItem",u=null;if("taskList"==o){p="taskItem";let t=!1;"•+ "==e&&(t=!0),u={checked:t}}return u?{type:p,attrs:u,content:s,_tempParsingParent:o,_tempListStart:a}:{type:p,content:s,_tempParsingParent:o,_tempListStart:a}},xo=function(e){return e},ko=function(e){return e.join("")===Qa},Ko=function(e){return e.length>Qa.length},wo=function(e){Xa.push(Qa),Qa=e.join("")},_o=function(){return Qa=Xa.pop(),!0},So=function(e){return{type:"paragraph",content:l(e.trim()),attrs:{}}},Ao=function(e){return{type:"paragraph",content:l(e.trim()),attrs:{}}},Lo=function(e){return{type:"paragraph",content:l(e.trim()),attrs:{}}},Io=function(e){return e},Fo=function(e,t,r){const i=Object.assign({},...r);let o=i.alignment||"center";delete i.alignment;let a=i.captionAlign||"left";delete i.captionAlign;let s=i.alt||null;delete i.alt;let l=i.caption||null;delete i.caption;let p=i.align||"center";delete i.align;let u=i.zoomDisabled||Boolean(i.zoomDisabled);return delete i.zoomDisabled,{type:e,attrs:Object.assign({alignment:o,textAlign:a,src:t,alt:n(s),title:n(l),class:p,zoomDisabled:u},i)}},No=function(e){return e},Oo=function(e){return{comment:e}},Eo=function(e,t){return{[e]:parseInt(t)}},Ro=function(e,t){return{type:"error",msg:e+" must be an positive integer.",found:t}},Vo=function(e,t){return{[e]:t}},jo=function(e,t){return{[e]:t}},Mo=function(e){return{[e]:!0}},Do=function(e){return[{type:"paragraph",content:e,attrs:{}}]},Go=function(e,t){return s(e?[e,...t.flat()]:t.flat())},Uo=function(){return{type:"hardBreak"}},$o=function(e){return{text:n(e),type:"text"}},Jo=function(e){return{index:+e,type:"bit"}},Wo=function(e){return{attrs:{formula:n(e)},type:"latex"}},zo=function(e,t,r){return{attrs:Object.assign(Object.assign({alt:e,src:(t.pr+t.t).trim()},Object.assign({},...r)),{zoomDisabled:!0}),type:"imageInline"}},qo=function(e,t){return t||(t=[]),{marks:t,text:n(e),type:"text"}},Ho=function(e){return{marks:[{type:"bold"}],text:n(e),type:"text"}},Yo=function(e){return{marks:[{type:"italic"}],text:n(e),type:"text"}},Xo=function(e){return{marks:[{type:"light"}],text:n(e),type:"text"}},Qo=function(e){return{marks:[{type:"highlight"}],text:n(e),type:"text"}},Zo=function(e){return{marks:[{type:"link",attrs:{href:(e.pr+e.t).trim(),target:"_blank"}}],text:e.t,type:"text"}},en=function(e){return e},tn=function(e){return e},rn=function(e){return{comment:e}},on=function(e,t){return{[e]:parseInt(t)}},nn=function(e,t){return{type:"error",msg:e+" must be an positive integer.",found:t}},an=function(e,t){return{[e]:t}},sn=function(e,t){return{[e]:t}},ln=function(e){return{type:"link",attrs:{href:e.trim(),target:"_blank"}}},pn=function(e,t,r){return{type:"extref",attrs:{extref:e.trim(),references:t,provider:r.trim()}}},un=function(e,t){return{type:"xref",attrs:{xref:e.trim(),reference:t.trim()}}},cn=function(e){return{type:"xref",attrs:{xref:e.trim(),reference:""}}},yn=function(e){return{type:"ref",attrs:{reference:e.trim()}}},gn=function(e,t){const r=Object.assign({},...t);return{type:"symbol",attrs:Object.assign({src:e.trim()},r)}},dn=function(e){return{type:"footnote",attrs:{content:l(e.trim())}}},fn=function(e){return{type:"footnote*",attrs:{content:l(e.trim())}}},mn=function(e){return{type:"var",attrs:{name:e.trim()}}},Tn=function(){return{type:"code",attrs:{language:"plain text"}}},hn=function(e){return{type:"code",attrs:{language:e.trim().toLowerCase()}}},bn=function(){return{type:"timer",attrs:{name:""}}},Bn=function(e){return{type:"timer",attrs:{name:e.trim()}}},vn=function(e){return{type:"duration",attrs:{duration:e}}},Cn=function(e){return{type:"color",attrs:{color:e}}},Pn=function(e){return{type:e}},xn=function(e){return{type:"comment",comment:e}},kn=function(e){return e.trim()},Kn=function(e){return[{type:"paragraph",content:e,attrs:{}}]},wn=function(e,t){return s(e?[e,...t.flat()]:t.flat())},_n=function(){return{type:"hardBreak"}},Sn=function(e){return{text:n(e),type:"text"}},An=function(e){return{index:+e,type:"bit"}},Ln=function(e){return{marks:[{type:"bold"}],text:n(e),type:"text"}},In=function(e){return{marks:[{type:"italic"}],text:n(e),type:"text"}},Fn=function(e){return{marks:[{type:"light"}],text:n(e),type:"text"}},Nn=function(e){return{marks:[{type:"highlight"}],text:n(e),type:"text"}},On=function(e,t){return{pr:e,t}},En=0|t.peg$currPos,Rn=[{line:1,column:1}],Vn=En,jn=t.peg$maxFailExpected||[],Mn=0|t.peg$silentFails;if(t.startRule){if(!(t.startRule in c))throw new Error("Can't start parsing from rule \""+t.startRule+'".');y=c[t.startRule]}function Dn(e,t){return{type:"literal",text:e,ignoreCase:t}}function Gn(e,t,r){return{type:"class",parts:e,inverted:t,ignoreCase:r}}function Un(e){return{type:"other",description:e}}function $n(t){var r,i=Rn[t];if(i)return i;if(t>=Rn.length)r=Rn.length-1;else for(r=t;!Rn[--r];);for(i={line:(i=Rn[r]).line,column:i.column};r<t;)10===e.charCodeAt(r)?(i.line++,i.column=1):i.column++,r++;return Rn[t]=i,i}function Jn(e,t,r){var i=$n(e),o=$n(t),n={source:u,start:{offset:e,line:i.line,column:i.column},end:{offset:t,line:o.line,column:o.column}};return r&&u&&"function"==typeof u.offset&&(n.start=u.offset(n.start),n.end=u.offset(n.end)),n}function Wn(e){En<Vn||(En>Vn&&(Vn=En,jn=[]),jn.push(e))}function zn(e,t,r){return new p(p.buildMessage(e,t),e,t,r)}function qn(){var t,r,o;for(t=En,r=[],e.length>En?(o=e.charAt(En),En++):(o=i,0===Mn&&Wn(Kt));o!==i;)r.push(o),e.length>En?(o=e.charAt(En),En++):(o=i,0===Mn&&Wn(Kt));return t=r=Ji()}function Hn(){var t,r;return t=En,r=function(){var t,r,o,n,a;if(t=En,r=Qn(),r!==i){for(o=En,n=[],a=za();a!==i;)n.push(a),a=za();o=e.substring(o,En),(n=qa())!==i?((a=Wa())===i&&(a=null),t=Qi(r,o)):(En=t,t=i)}else En=t,t=i;return t}(),r!==i&&(r=Wi(r)),(t=r)===i&&(t=En,r=function(){var e,t,r,o;if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=ra(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=go());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=no(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=ia(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=fo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=ao(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=oa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=mo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=so(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=na(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=To());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=lo(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=aa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=ho());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=po(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=sa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=bo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=uo(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=la(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=Bo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=co(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i)if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=pa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=vo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=yo(t,r)):(En=e,e=i)}else En=e,e=i}}}}}}return e}(),r!==i&&(r=zi(r)),(t=r)===i&&(t=En,(r=ha())!==i&&(r=qi(r)),(t=r)===i&&(t=En,r=function(){var t,r,o;t=En,r=ea(),r!==i?(o=function(){var t,r,o,n;t=En,r=En,o=[],n=ta();for(;n!==i;)o.push(n),n=ta();return r=e.substring(r,En),r=io(r),t=r,t}(),t=eo(r,o)):(En=t,t=i);return t}(),r!==i&&(r=Hi(r)),(t=r)===i&&(t=En,r=function(){var e,t,r;e=En,t=En,Mn++,r=Yn(),Mn--,r===i?t=void 0:(En=t,t=i);t!==i&&(r=da())!==i?e=So(r):(En=e,e=i);e===i&&(e=En,(t=ma())!==i&&(r=da())!==i?e=Ao(r):(En=e,e=i),e===i&&(e=En,(t=ma())!==i?e=Lo(r=""):(En=e,e=i)));return e}(),r!==i&&(r=Yi(r)),t=r)))),t}function Yn(){var e;return(e=Qn())===i&&(e=ua())===i&&(e=ha())===i&&(e=ea())===i&&(e=ma()),e}function Xn(){var t;return 124===e.charCodeAt(En)?(t=g,En++):(t=i,0===Mn&&Wn(_t)),t}function Qn(){var t;return e.substr(En,4)===d?(t=d,En+=4):(t=i,0===Mn&&Wn(St)),t===i&&(e.substr(En,3)===f?(t=f,En+=3):(t=i,0===Mn&&Wn(At)),t===i&&(e.substr(En,2)===m?(t=m,En+=2):(t=i,0===Mn&&Wn(Lt)))),t}function Zn(){var t,r;return t=En,Xn()!==i?(r=function(){var t;return e.substr(En,4)===T?(t=T,En+=4):(t=i,0===Mn&&Wn(It)),t}(),r!==i?t=Zi(r):(En=t,t=i)):(En=t,t=i),t}function ea(){var t,r,o,n,a,s,l;if(t=En,Zn()!==i){for(r=En,o=En,n=[],a=e.charAt(En),Bt.test(a)?En++:(a=i,0===Mn&&Wn(Ft));a!==i;)n.push(a),a=e.charAt(En),Bt.test(a)?En++:(a=i,0===Mn&&Wn(Ft));(a=qa())!==i?o=n=[n,a]:(En=o,o=i),(r=o!==i?e.substring(r,En):o)!==i?t=to():(En=t,t=i)}else En=t,t=i;if(t===i)if(t=En,Zn()!==i)if(58===e.charCodeAt(En)?(r=h,En++):(r=i,0===Mn&&Wn(Nt)),r!==i)if(o=function(){var t,r,o;e.substr(En,9)===b?(t=b,En+=9):(t=i,0===Mn&&Wn(Ot));if(t===i&&(e.substr(En,9)===B?(t=B,En+=9):(t=i,0===Mn&&Wn(Et)),t===i&&(e.substr(En,10)===v?(t=v,En+=10):(t=i,0===Mn&&Wn(Rt)),t===i))){if(t=En,r=[],(o=za())!==i)for(;o!==i;)r.push(o),o=za();else r=i;(t=r!==i?e.substring(t,En):r)===i&&(t="")}return t}(),o!==i){for(n=En,a=En,s=[],l=e.charAt(En),Bt.test(l)?En++:(l=i,0===Mn&&Wn(Ft));l!==i;)s.push(l),l=e.charAt(En),Bt.test(l)?En++:(l=i,0===Mn&&Wn(Ft));(l=qa())!==i?a=s=[s,l]:(En=a,a=i),(n=a!==i?e.substring(n,En):a)!==i?t=ro(o):(En=t,t=i)}else En=t,t=i;else En=t,t=i;else En=t,t=i;return t}function ta(){var t,r,o,n,a,s;if(t=En,r=En,Mn++,o=Yn(),Mn--,o===i?r=void 0:(En=r,r=i),r!==i){if(o=En,n=En,a=[],(s=za())!==i)for(;s!==i;)a.push(s),s=za();else a=i;a!==i&&(s=qa())!==i?n=a=[a,s]:(En=n,n=i),(o=n!==i?e.substring(o,En):n)!==i?t=oo(o):(En=t,t=i)}else En=t,t=i;return t===i&&(t=Wa()),t}function ra(){var t;return e.substr(En,2)===C?(t=C,En+=2):(t=i,0===Mn&&Wn(Vt)),t}function ia(){var t;return e.substr(En,3)===P?(t=P,En+=3):(t=i,0===Mn&&Wn(jt)),t}function oa(){var t,r,o,n,a;if(t=En,r=En,8226===e.charCodeAt(En)?(o=x,En++):(o=i,0===Mn&&Wn(Mt)),o!==i){if(n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;n!==i?(32===e.charCodeAt(En)?(a=k,En++):(a=i,0===Mn&&Wn(Gt)),a!==i?r=o=[o,n,a]:(En=r,r=i)):(En=r,r=i)}else En=r,r=i;return t=r!==i?e.substring(t,En):r}function na(){var t,r,o,n,a;if(t=En,r=En,8226===e.charCodeAt(En)?(o=x,En++):(o=i,0===Mn&&Wn(Mt)),o!==i){if(n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;n!==i?(e.substr(En,2)===K?(a=K,En+=2):(a=i,0===Mn&&Wn(Ut)),a!==i?r=o=[o,n,a]:(En=r,r=i)):(En=r,r=i)}else En=r,r=i;return t=r!==i?e.substring(t,En):r}function aa(){var t,r,o,n,a;if(t=En,r=En,8226===e.charCodeAt(En)?(o=x,En++):(o=i,0===Mn&&Wn(Mt)),o!==i){if(n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;n!==i?(e.substr(En,2)===w?(a=w,En+=2):(a=i,0===Mn&&Wn($t)),a!==i?r=o=[o,n,a]:(En=r,r=i)):(En=r,r=i)}else En=r,r=i;return t=r!==i?e.substring(t,En):r}function sa(){var t;return e.substr(En,3)===_?(t=_,En+=3):(t=i,0===Mn&&Wn(Jt)),t}function la(){var t;return e.substr(En,3)===S?(t=S,En+=3):(t=i,0===Mn&&Wn(Wt)),t}function pa(){var t;return e.substr(En,3)===A?(t=A,En+=3):(t=i,0===Mn&&Wn(zt)),t===i&&(e.substr(En,3)===L?(t=L,En+=3):(t=i,0===Mn&&Wn(qt))),t}function ua(){var e;return(e=ra())===i&&(e=ia())===i&&(e=oa())===i&&(e=na())===i&&(e=aa())===i&&(e=sa())===i&&(e=la())===i&&(e=pa()),e}function ca(){var t,r,o,n,a,s,l,p;if(t=En,ga()!==i)if((r=ua())!==i){for(o=En,n=En,a=[],s=En,l=En,Mn++,p=Wa(),Mn--,p===i?l=void 0:(En=l,l=i),l!==i?(e.length>En?(p=e.charAt(En),En++):(p=i,0===Mn&&Wn(Kt)),p!==i?s=l=[l,p]:(En=s,s=i)):(En=s,s=i);s!==i;)a.push(s),s=En,l=En,Mn++,p=Wa(),Mn--,p===i?l=void 0:(En=l,l=i),l!==i?(e.length>En?(p=e.charAt(En),En++):(p=i,0===Mn&&Wn(Kt)),p!==i?s=l=[l,p]:(En=s,s=i)):(En=s,s=i);for((s=Wa())===i&&(s=null),n=a=[a,s],o=e.substring(o,En),n=[],a=ya();a!==i;)n.push(a),a=ya();if(a=En,s=function(){var t,r,o,n;t=En,Mn++,r=En,o=[],9===e.charCodeAt(En)?(n=I,En++):(n=i,0===Mn&&Wn(Ht));if(n!==i)for(;n!==i;)o.push(n),9===e.charCodeAt(En)?(n=I,En++):(n=i,0===Mn&&Wn(Ht));else o=i;o!==i?(n=(n=Ko(o))?void 0:i)!==i?r=wo(o):(En=r,r=i):(En=r,r=i);Mn--,r!==i?(En=t,t=void 0):t=i;return t}(),s!==i){for(l=[],p=ca();p!==i;)l.push(p),p=ca();p=function(){var e;e=_o(),e=e?void 0:i;return e}(),p!==i?a=Co(r,o,n,l):(En=a,a=i)}else En=a,a=i;a===i&&(a=null),t=Po(r,o,n,a)}else En=t,t=i;else En=t,t=i;return t}function ya(){var t,r,o,n,a,s,l,p,u,c;if(t=En,r=En,Mn++,o=function(){var t,r,o;t=En,r=[],o=e.charAt(En),Bt.test(o)?En++:(o=i,0===Mn&&Wn(Ft));for(;o!==i;)r.push(o),o=e.charAt(En),Bt.test(o)?En++:(o=i,0===Mn&&Wn(Ft));o=Wa(),o!==i?t=r=[r,o]:(En=t,t=i);return t}(),Mn--,o===i?r=void 0:(En=r,r=i),r!==i)if((o=ga())!==i)if(n=En,Mn++,a=ua(),Mn--,a===i?n=void 0:(En=n,n=i),n!==i){if(a=En,s=En,l=[],p=En,u=En,Mn++,c=Wa(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(e.length>En?(c=e.charAt(En),En++):(c=i,0===Mn&&Wn(Kt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i),p!==i)for(;p!==i;)l.push(p),p=En,u=En,Mn++,c=Wa(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(e.length>En?(c=e.charAt(En),En++):(c=i,0===Mn&&Wn(Kt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i);else l=i;l!==i&&(p=qa())!==i?s=l=[l,p]:(En=s,s=i),(a=s!==i?e.substring(a,En):s)!==i?t=xo(a):(En=t,t=i)}else En=t,t=i;else En=t,t=i;else En=t,t=i;return t}function ga(){var t,r,o;for(t=En,r=[],9===e.charCodeAt(En)?(o=I,En++):(o=i,0===Mn&&Wn(Ht));o!==i;)r.push(o),9===e.charCodeAt(En)?(o=I,En++):(o=i,0===Mn&&Wn(Ht));return(o=(o=ko(r))?void 0:i)!==i?t=r=[r,o]:(En=t,t=i),t}function da(){var t,r,o;if(t=En,r=[],(o=fa())!==i)for(;o!==i;)r.push(o),o=fa();else r=i;return t=r!==i?e.substring(t,En):r}function fa(){var t,r,o,n,a,s;if(t=En,r=En,Mn++,o=Yn(),Mn--,o===i?r=void 0:(En=r,r=i),r!==i){if(o=En,n=En,a=[],(s=za())!==i)for(;s!==i;)a.push(s),s=za();else a=i;a!==i&&(s=qa())!==i?n=a=[a,s]:(En=n,n=i),(o=n!==i?e.substring(o,En):n)!==i?t=r=[r,o]:(En=t,t=i)}else En=t,t=i;return t===i&&(t=Wa()),t}function ma(){var t,r,o,n,a,s;if(t=En,(r=Xn())!==i){for(o=En,n=En,a=[],s=e.charAt(En),Bt.test(s)?En++:(s=i,0===Mn&&Wn(Ft));s!==i;)a.push(s),s=e.charAt(En),Bt.test(s)?En++:(s=i,0===Mn&&Wn(Ft));(s=qa())!==i?n=a=[a,s]:(En=n,n=i),(o=n!==i?e.substring(o,En):n)!==i?((n=Wa())===i&&(n=null),t=r=[r,o,n]):(En=t,t=i)}else En=t,t=i;return t}function Ta(){var t,r;return t=En,Xn()!==i?(r=function(){var t;return e.substr(En,5)===F?(t=F,En+=5):(t=i,0===Mn&&Wn(Yt)),t}(),r!==i?t=Io(r):(En=t,t=i)):(En=t,t=i),t}function ha(){var t,r,o,n,a,s,l,p,u,c;if(t=En,(r=Ta())!==i)if(58===e.charCodeAt(En)?(o=h,En++):(o=i,0===Mn&&Wn(Nt)),o!==i)if(32===e.charCodeAt(En)?(n=k,En++):(n=i,0===Mn&&Wn(Gt)),n===i&&(n=null),a=function(){var t,r,o,n,a,s,l,p,u;t=En,r=En,e.substr(En,4)===mt?(o=mt,En+=4):(o=i,0===Mn&&Wn(Mi));if(o!==i)if(115===e.charCodeAt(En)?(n=Tt,En++):(n=i,0===Mn&&Wn(Di)),n===i&&(n=null),e.substr(En,3)===ht?(a=ht,En+=3):(a=i,0===Mn&&Wn(Gi)),a!==i){for(s=[],l=En,p=En,Mn++,u=Xn(),Mn--,u===i?p=void 0:(En=p,p=i),p!==i&&(u=Ya())!==i?l=p=[p,u]:(En=l,l=i);l!==i;)s.push(l),l=En,p=En,Mn++,u=Xn(),Mn--,u===i?p=void 0:(En=p,p=i),p!==i&&(u=Ya())!==i?l=p=[p,u]:(En=l,l=i);r=o=[o,n,a,s]}else En=r,r=i;else En=r,r=i;t=r!==i?e.substring(t,En):r;return t}(),a!==i)if(Xn()!==i){for(s=ba(),l=En,p=En,u=[],c=e.charAt(En),Bt.test(c)?En++:(c=i,0===Mn&&Wn(Ft));c!==i;)u.push(c),c=e.charAt(En),Bt.test(c)?En++:(c=i,0===Mn&&Wn(Ft));(c=qa())!==i?p=u=[u,c]:(En=p,p=i),(l=p!==i?e.substring(l,En):p)!==i?((p=Wa())===i&&(p=null),t=Fo(r,a,s)):(En=t,t=i)}else En=t,t=i;else En=t,t=i;else En=t,t=i;else En=t,t=i;return t}function ba(){var e,t,r;for(e=En,t=[],r=Ba();r!==i;)t.push(r),r=Ba();return e=t=No(t)}function Ba(){var t,r,o,n,a,s,l,p,u,c;if(t=En,35===e.charCodeAt(En)?(r=N,En++):(r=i,0===Mn&&Wn(Xt)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=Oo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));if(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i),p!==i)for(;p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i);else l=i;(s=l!==i?e.substring(s,En):l)!==i&&(l=Xn())!==i?t=Eo(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=Ro(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=Ca())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s=function(){var t;e.substr(En,4)===M?(t=M,En+=4):(t=i,0===Mn&&Wn(or));t===i&&(e.substr(En,6)===D?(t=D,En+=6):(t=i,0===Mn&&Wn(nr)),t===i&&(e.substr(En,5)===G?(t=G,En+=5):(t=i,0===Mn&&Wn(ar))));return t}(),s!==i&&(l=Xn())!==i?t=Vo(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){for(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),o=En,n=[],a=En,s=En,Mn++,l=e.charAt(En),Ct.test(l)?En++:(l=i,0===Mn&&Wn(Zt)),l===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=e.charAt(En),Ct.test(l)?En++:(l=i,0===Mn&&Wn(Zt)),l===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);if(o=e.substring(o,En),58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(32===e.charCodeAt(En)?(a=k,En++):(a=i,0===Mn&&Wn(Gt)),a===i&&(a=null),s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=jo(o,s):(En=t,t=i)}else En=t,t=i;if(t===i){for(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),o=En,n=[],a=En,s=En,Mn++,(l=Xn())===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,(l=Xn())===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=Mo(o):(En=t,t=i)}}}}}return t}function va(){var t;return e.substr(En,5)===E?(t=E,En+=5):(t=i,0===Mn&&Wn(er)),t===i&&(e.substr(En,6)===R?(t=R,En+=6):(t=i,0===Mn&&Wn(tr))),t}function Ca(){var t;return e.substr(En,9)===V?(t=V,En+=9):(t=i,0===Mn&&Wn(rr)),t===i&&(e.substr(En,12)===j?(t=j,En+=12):(t=i,0===Mn&&Wn(ir))),t}function Pa(){var e,t,r,o;for(e=En,(t=xa())===i&&(t=null),r=[],(o=wa())===i&&(o=xa());o!==i;)r.push(o),(o=wa())===i&&(o=xa());return e=Go(t,r)}function xa(){var t,r,o,n,a,s,l;if(t=En,(r=Wa())!==i&&(r=Uo()),(t=r)===i){if(t=En,r=En,o=[],n=En,(a=_a())===i&&(a=null),s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=_a())!==i?(s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i)),n!==i)for(;n!==i;)o.push(n),n=En,(a=_a())===i&&(a=null),s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=_a())!==i?(s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i));else o=i;(r=o!==i?e.substring(r,En):o)!==i&&(r=$o(r)),t=r}return t}function ka(){var t;return 61===e.charCodeAt(En)?(t=U,En++):(t=i,0===Mn&&Wn(lr)),t}function Ka(){var e,t,r;return e=En,(t=ka())!==i&&(r=ka())!==i?e=t=[t,r]:(En=e,e=i),e}function wa(){var t,r,o,n,a,s,l,p;if(t=En,(r=Ga())!==i){if(o=En,n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;(o=n!==i?e.substring(o,En):n)!==i&&(n=Ua())!==i?t=Jo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ka())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ka())!==i?(e.substr(En,7)===$?(a=$,En+=7):(a=i,0===Mn&&Wn(pr)),a!==i?t=Wo(o):(En=t,t=i)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ka())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ka())!==i?(e.substr(En,13)===J?(a=J,En+=13):(a=i,0===Mn&&Wn(ur)),a!==i&&(s=Ha())!==i?(124===e.charCodeAt(En)?(l=g,En++):(l=i,0===Mn&&Wn(_t)),l!==i?(p=function(){var e,t,r;e=En,t=[],r=Sa();for(;r!==i;)t.push(r),r=Sa();return t=tn(t),e=t,e}(),t=zo(o,s,p)):(En=t,t=i)):(En=t,t=i)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ka())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ka())!==i?(a=function(){var t,r,o,n;t=En,124===e.charCodeAt(En)?(r=g,En++):(r=i,0===Mn&&Wn(_t));if(r!==i){if(o=[],(n=Aa())!==i)for(;n!==i;)o.push(n),n=Aa();else o=i;o!==i?t=en(o):(En=t,t=i)}else En=t,t=i;return t}(),a!==i?t=qo(o,a):(En=t,t=i)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Va())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Va(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Va(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Va())!==i?t=Ho(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=ja())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=ja(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=ja(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=ja())!==i?t=Yo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ma())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ma(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ma(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ma())!==i?t=Xo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Da())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Da(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Da(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Da())!==i?t=Qo(o):(En=t,t=i)}else En=t,t=i;t===i&&(t=En,(r=Ha())!==i&&(r=Zo(r)),t=r)}}}}}}}return t}function _a(){var t,r,o,n,a;if(t=En,r=En,(o=Ka())!==i){if(n=[],(a=ka())!==i)for(;a!==i;)n.push(a),a=ka();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;if((t=r!==i?e.substring(t,En):r)===i){if(t=En,r=En,(o=Ma())!==i){if(n=[],(a=Ea())!==i)for(;a!==i;)n.push(a),a=Ea();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;if((t=r!==i?e.substring(t,En):r)===i){if(t=En,r=En,(o=Da())!==i){if(n=[],(a=Ra())!==i)for(;a!==i;)n.push(a),a=Ra();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;t=r!==i?e.substring(t,En):r}}return t}function Sa(){var t,r,o,n,a,s,l,p,u,c;if(t=En,35===e.charCodeAt(En)?(r=N,En++):(r=i,0===Mn&&Wn(Xt)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=rn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));if(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i),p!==i)for(;p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i);else l=i;(s=l!==i?e.substring(s,En):l)!==i&&(l=Xn())!==i?t=on(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=nn(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),e.substr(En,17)===W?(o=W,En+=17):(o=i,0===Mn&&Wn(cr)),o!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s=function(){var t;e.substr(En,3)===q?(t=q,En+=3):(t=i,0===Mn&&Wn(gr));t===i&&(e.substr(En,6)===H?(t=H,En+=6):(t=i,0===Mn&&Wn(dr)),t===i&&(e.substr(En,6)===Y?(t=Y,En+=6):(t=i,0===Mn&&Wn(fr)),t===i&&(e.substr(En,8)===X?(t=X,En+=8):(t=i,0===Mn&&Wn(mr)),t===i&&(e.substr(En,3)===Q?(t=Q,En+=3):(t=i,0===Mn&&Wn(Tr)),t===i&&(e.substr(En,5)===Z?(t=Z,En+=5):(t=i,0===Mn&&Wn(hr)),t===i&&(e.substr(En,11)===ee?(t=ee,En+=11):(t=i,0===Mn&&Wn(br)),t===i&&(e.substr(En,8)===te?(t=te,En+=8):(t=i,0===Mn&&Wn(Br)))))))));return t}(),s!==i&&(l=Xn())!==i?t=an(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i)if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),e.substr(En,4)===z?(o=z,En+=4):(o=i,0===Mn&&Wn(yr)),o!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s=function(){var t;e.substr(En,11)===re?(t=re,En+=11):(t=i,0===Mn&&Wn(vr));t===i&&(e.substr(En,11)===ie?(t=ie,En+=11):(t=i,0===Mn&&Wn(Cr)),t===i&&(e.substr(En,5)===Z?(t=Z,En+=5):(t=i,0===Mn&&Wn(hr)),t===i&&(e.substr(En,3)===Q?(t=Q,En+=3):(t=i,0===Mn&&Wn(Tr)),t===i&&(e.substr(En,8)===oe?(t=oe,En+=8):(t=i,0===Mn&&Wn(Pr))))));return t}(),s!==i&&(l=Xn())!==i?t=sn(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i}}}return t}function Aa(){var t,r,o,n,a,s,l,p,u,c,y;if(t=En,e.substr(En,5)===ne?(r=ne,En+=5):(r=i,0===Mn&&Wn(xr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=ln(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,7)===ae?(r=ae,En+=7):(r=i,0===Mn&&Wn(kr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);if(o=e.substring(o,En),n=function(){var e,t;e=[],t=La();for(;t!==i;)e.push(t),t=La();return e}(),(a=Xn())!==i)if(e.substr(En,9)===se?(s=se,En+=9):(s=i,0===Mn&&Wn(Kr)),s!==i){for(l=En,p=[],u=En,c=En,Mn++,y=Xn(),Mn--,y===i?c=void 0:(En=c,c=i),c!==i&&(y=za())!==i?u=c=[c,y]:(En=u,u=i);u!==i;)p.push(u),u=En,c=En,Mn++,y=Xn(),Mn--,y===i?c=void 0:(En=c,c=i),c!==i&&(y=za())!==i?u=c=[c,y]:(En=u,u=i);l=e.substring(l,En),(p=Xn())!==i?t=pn(o,n,l):(En=t,t=i)}else En=t,t=i;else En=t,t=i}else En=t,t=i;if(t===i){if(t=En,e.substr(En,5)===le?(r=le,En+=5):(r=i,0===Mn&&Wn(wr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);if(o=e.substring(o,En),(n=Xn())!==i)if(9658===e.charCodeAt(En)?(a=pe,En++):(a=i,0===Mn&&Wn(_r)),a!==i){for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=un(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i}else En=t,t=i;if(t===i){if(t=En,e.substr(En,5)===le?(r=le,En+=5):(r=i,0===Mn&&Wn(wr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=cn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,9658===e.charCodeAt(En)?(r=pe,En++):(r=i,0===Mn&&Wn(_r)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=yn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,7)===ue?(r=ue,En+=7):(r=i,0===Mn&&Wn(Sr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?(a=ba(),t=gn(o,a)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,9)===ce?(r=ce,En+=9):(r=i,0===Mn&&Wn(Ar)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=dn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,10)===ye?(r=ye,En+=10):(r=i,0===Mn&&Wn(Lr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=fn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,4)===ge?(r=ge,En+=4):(r=i,0===Mn&&Wn(Ir)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=mn(o):(En=t,t=i)}else En=t,t=i;if(t===i&&(t=En,e.substr(En,4)===T?(r=T,En+=4):(r=i,0===Mn&&Wn(It)),r!==i&&(o=Xn())!==i?t=Tn():(En=t,t=i),t===i)){if(t=En,e.substr(En,5)===de?(r=de,En+=5):(r=i,0===Mn&&Wn(Fr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=hn(o):(En=t,t=i)}else En=t,t=i;if(t===i&&(t=En,e.substr(En,5)===fe?(r=fe,En+=5):(r=i,0===Mn&&Wn(Nr)),r!==i&&(o=Xn())!==i?t=bn():(En=t,t=i),t===i)){if(t=En,e.substr(En,6)===me?(r=me,En+=6):(r=i,0===Mn&&Wn(Or)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=Bn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,9)===Te?(r=Te,En+=9):(r=i,0===Mn&&Wn(Er)),r!==i){if(o=En,n=En,80===e.charCodeAt(En)?(a=he,En++):(a=i,0===Mn&&Wn(Rr)),a!==i){for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);n=a=[a,s=e.substring(s,En)]}else En=n,n=i;(o=n!==i?e.substring(o,En):n)!==i&&(n=Xn())!==i?t=vn(o):(En=t,t=i)}else En=t,t=i;if(t===i&&(t=En,e.substr(En,6)===be?(r=be,En+=6):(r=i,0===Mn&&Wn(Vr)),r!==i?(o=function(){var t;e.substr(En,4)===Me?(t=Me,En+=4):(t=i,0===Mn&&Wn(ni));t===i&&(e.substr(En,5)===De?(t=De,En+=5):(t=i,0===Mn&&Wn(ai)),t===i&&(e.substr(En,4)===Ge?(t=Ge,En+=4):(t=i,0===Mn&&Wn(si)),t===i&&(e.substr(En,4)===Ue?(t=Ue,En+=4):(t=i,0===Mn&&Wn(li)),t===i&&(e.substr(En,7)===$e?(t=$e,En+=7):(t=i,0===Mn&&Wn(pi)),t===i&&(e.substr(En,9)===Je?(t=Je,En+=9):(t=i,0===Mn&&Wn(ui)),t===i&&(e.substr(En,4)===We?(t=We,En+=4):(t=i,0===Mn&&Wn(ci)),t===i&&(e.substr(En,8)===ze?(t=ze,En+=8):(t=i,0===Mn&&Wn(yi)),t===i&&(e.substr(En,5)===qe?(t=qe,En+=5):(t=i,0===Mn&&Wn(gi)),t===i&&(e.substr(En,4)===He?(t=He,En+=4):(t=i,0===Mn&&Wn(di)),t===i&&(e.substr(En,7)===Ye?(t=Ye,En+=7):(t=i,0===Mn&&Wn(fi)),t===i&&(e.substr(En,6)===Xe?(t=Xe,En+=6):(t=i,0===Mn&&Wn(mi)),t===i&&(e.substr(En,4)===Qe?(t=Qe,En+=4):(t=i,0===Mn&&Wn(Ti)),t===i&&(e.substr(En,5)===Ze?(t=Ze,En+=5):(t=i,0===Mn&&Wn(hi)),t===i&&(e.substr(En,6)===et?(t=et,En+=6):(t=i,0===Mn&&Wn(bi)),t===i&&(e.substr(En,6)===tt?(t=tt,En+=6):(t=i,0===Mn&&Wn(Bi)),t===i&&(e.substr(En,3)===rt?(t=rt,En+=3):(t=i,0===Mn&&Wn(vi)),t===i&&(e.substr(En,6)===it?(t=it,En+=6):(t=i,0===Mn&&Wn(Ci)),t===i&&(e.substr(En,4)===ot?(t=ot,En+=4):(t=i,0===Mn&&Wn(Pi)),t===i&&(e.substr(En,6)===nt?(t=nt,En+=6):(t=i,0===Mn&&Wn(xi)),t===i&&(e.substr(En,5)===at?(t=at,En+=5):(t=i,0===Mn&&Wn(ki)),t===i&&(e.substr(En,6)===st?(t=st,En+=6):(t=i,0===Mn&&Wn(Ki)))))))))))))))))))))));return t}(),o!==i&&(n=Xn())!==i?t=Cn(o):(En=t,t=i)):(En=t,t=i),t===i&&(t=En,r=function(){var t;e.substr(En,4)===ve?(t=ve,En+=4):(t=i,0===Mn&&Wn(Mr));t===i&&(e.substr(En,6)===Ce?(t=Ce,En+=6):(t=i,0===Mn&&Wn(Dr)),t===i&&(e.substr(En,5)===Pe?(t=Pe,En+=5):(t=i,0===Mn&&Wn(Gr)),t===i&&(e.substr(En,9)===xe?(t=xe,En+=9):(t=i,0===Mn&&Wn(Ur)),t===i&&(e.substr(En,6)===ke?(t=ke,En+=6):(t=i,0===Mn&&Wn($r)),t===i&&(e.substr(En,9)===Ke?(t=Ke,En+=9):(t=i,0===Mn&&Wn(Jr)),t===i&&(e.substr(En,11)===we?(t=we,En+=11):(t=i,0===Mn&&Wn(Wr)),t===i&&(e.substr(En,3)===_e?(t=_e,En+=3):(t=i,0===Mn&&Wn(zr)),t===i&&(e.substr(En,3)===Se?(t=Se,En+=3):(t=i,0===Mn&&Wn(qr)),t===i&&(e.substr(En,9)===Ae?(t=Ae,En+=9):(t=i,0===Mn&&Wn(Hr)),t===i&&(e.substr(En,15)===Le?(t=Le,En+=15):(t=i,0===Mn&&Wn(Yr)),t===i&&(e.substr(En,6)===Ie?(t=Ie,En+=6):(t=i,0===Mn&&Wn(Xr)),t===i&&(e.substr(En,10)===Fe?(t=Fe,En+=10):(t=i,0===Mn&&Wn(Qr)),t===i&&(e.substr(En,13)===Ne?(t=Ne,En+=13):(t=i,0===Mn&&Wn(Zr)),t===i&&(e.substr(En,19)===Oe?(t=Oe,En+=19):(t=i,0===Mn&&Wn(ei)),t===i&&(e.substr(En,10)===Ee?(t=Ee,En+=10):(t=i,0===Mn&&Wn(ti)),t===i&&(e.substr(En,10)===Re?(t=Re,En+=10):(t=i,0===Mn&&Wn(ri)),t===i&&(e.substr(En,13)===Ve?(t=Ve,En+=13):(t=i,0===Mn&&Wn(ii)),t===i&&(e.substr(En,11)===je?(t=je,En+=11):(t=i,0===Mn&&Wn(oi))))))))))))))))))));return t}(),r!==i&&(o=Xn())!==i?t=Pn(r):(En=t,t=i),t===i)))if(t=En,35===e.charCodeAt(En)?(r=N,En++):(r=i,0===Mn&&Wn(Xt)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=xn(o):(En=t,t=i)}else En=t,t=i}}}}}}}}}}}return t}function La(){var t,r,o,n,a,s,l;if(t=En,e.substr(En,2)===Be?(r=Be,En+=2):(r=i,0===Mn&&Wn(jr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),t=kn(o)}else En=t,t=i;return t}function Ia(){var e,t,r,o;for(Mn++,e=En,(t=Fa())===i&&(t=null),r=[],(o=$a())===i&&(o=Fa());o!==i;)r.push(o),(o=$a())===i&&(o=Fa());return e=wn(t,r),Mn--,t=i,0===Mn&&Wn(_i),e}function Fa(){var t,r,o,n,a,s,l;if(t=En,(r=Wa())!==i&&(r=_n()),(t=r)===i){if(t=En,r=En,o=[],n=En,(a=Ja())===i&&(a=null),s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=Ja())!==i?(s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i)),n!==i)for(;n!==i;)o.push(n),n=En,(a=Ja())===i&&(a=null),s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=Ja())!==i?(s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i));else o=i;(r=o!==i?e.substring(r,En):o)!==i&&(r=Sn(r)),t=r}return t}function Na(){var t;return 42===e.charCodeAt(En)?(t=lt,En++):(t=i,0===Mn&&Wn(Si)),t}function Oa(){var t;return 95===e.charCodeAt(En)?(t=pt,En++):(t=i,0===Mn&&Wn(Ai)),t}function Ea(){var t;return 96===e.charCodeAt(En)?(t=ut,En++):(t=i,0===Mn&&Wn(Li)),t}function Ra(){var t;return 33===e.charCodeAt(En)?(t=ct,En++):(t=i,0===Mn&&Wn(Ii)),t}function Va(){var e,t,r;return e=En,(t=Na())!==i&&(r=Na())!==i?e=t=[t,r]:(En=e,e=i),e}function ja(){var e,t,r;return e=En,(t=Oa())!==i&&(r=Oa())!==i?e=t=[t,r]:(En=e,e=i),e}function Ma(){var e,t,r;return e=En,(t=Ea())!==i&&(r=Ea())!==i?e=t=[t,r]:(En=e,e=i),e}function Da(){var e,t,r;return e=En,(t=Ra())!==i&&(r=Ra())!==i?e=t=[t,r]:(En=e,e=i),e}function Ga(){var t;return e.substr(En,2)===yt?(t=yt,En+=2):(t=i,0===Mn&&Wn(Fi)),t}function Ua(){var t;return 93===e.charCodeAt(En)?(t=gt,En++):(t=i,0===Mn&&Wn(Ni)),t}function $a(){var t,r,o,n,a,s;if(t=En,Ga()!==i){if(r=En,o=[],n=e.charAt(En),vt.test(n)?En++:(n=i,0===Mn&&Wn(Dt)),n!==i)for(;n!==i;)o.push(n),n=e.charAt(En),vt.test(n)?En++:(n=i,0===Mn&&Wn(Dt));else o=i;(r=o!==i?e.substring(r,En):o)!==i&&(o=Ua())!==i?t=An(r):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,Va()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=Va(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=Va(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=Va())!==i?t=Ln(r):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,ja()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=ja(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=ja(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=ja())!==i?t=In(r):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,Ma()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=Ma(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=Ma(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=Ma())!==i?t=Fn(r):(En=t,t=i)}else En=t,t=i;if(t===i)if(t=En,Da()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=Da(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=Da(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=Da())!==i?t=Nn(r):(En=t,t=i)}else En=t,t=i}}}return t}function Ja(){var t,r,o,n,a;if(t=En,r=En,(o=Ma())!==i){if(n=[],(a=Ea())!==i)for(;a!==i;)n.push(a),a=Ea();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;if((t=r!==i?e.substring(t,En):r)===i){if(t=En,r=En,(o=Da())!==i){if(n=[],(a=Ra())!==i)for(;a!==i;)n.push(a),a=Ra();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;t=r!==i?e.substring(t,En):r}return t}function Wa(){var t;return Mn++,10===e.charCodeAt(En)?(t=dt,En++):(t=i,0===Mn&&Wn(Ei)),t===i&&(e.substr(En,2)===ft?(t=ft,En+=2):(t=i,0===Mn&&Wn(Ri)),t===i&&(t=e.charAt(En),Pt.test(t)?En++:(t=i,0===Mn&&Wn(Vi)))),Mn--,t===i&&(0===Mn&&Wn(Oi)),t}function za(){var t;return t=e.charAt(En),xt.test(t)?En++:(t=i,0===Mn&&Wn(ji)),t}function qa(){var t,r;return(t=Wa())===i&&(t=En,Mn++,e.length>En?(r=e.charAt(En),En++):(r=i,0===Mn&&Wn(Kt)),Mn--,r===i?t=void 0:(En=t,t=i)),t}function Ha(){var t,r,o,n,a,s,l;if(t=En,r=En,o=En,e.substr(En,4)===mt?(n=mt,En+=4):(n=i,0===Mn&&Wn(Mi)),n!==i?(115===e.charCodeAt(En)?(a=Tt,En++):(a=i,0===Mn&&Wn(Di)),a===i&&(a=null),e.substr(En,3)===ht?(s=ht,En+=3):(s=i,0===Mn&&Wn(Gi)),s!==i?o=n=[n,a,s]:(En=o,o=i)):(En=o,o=i),o===i&&(e.substr(En,7)===bt?(o=bt,En+=7):(o=i,0===Mn&&Wn(Ui))),(r=o!==i?e.substring(r,En):o)!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=Ya())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=Ya())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),t=On(r,o)}else En=t,t=i;return t}function Ya(){var t;return t=e.charAt(En),kt.test(t)?En++:(t=i,0===Mn&&Wn($i)),t}var Xa=[],Qa="";if(e=e.trimStart(),r=y(),t.peg$library)return{peg$result:r,peg$currPos:En,peg$FAILED:i,peg$maxFailExpected:jn,peg$maxFailPos:Vn};if(r!==i&&En===e.length)return r;throw r!==i&&En<e.length&&Wn({type:"end"}),zn(jn,Vn<e.length?e.charAt(Vn):null,Vn<e.length?Jn(Vn,Vn+1):Jn(Vn,Vn))}!function(e,t){function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r}(p,Error),p.prototype.format=function(e){var t="Error: "+this.message;if(this.location){var r,i=null;for(r=0;r<e.length;r++)if(e[r].source===this.location.source){i=e[r].text.split(/\r\n|\n|\r/g);break}var o=this.location.start,n=this.location.source&&"function"==typeof this.location.source.offset?this.location.source.offset(o):o,a=this.location.source+":"+n.line+":"+n.column;if(i){var s=this.location.end,l=u("",n.line.toString().length," "),p=i[o.line-1],c=(o.line===s.line?s.column:p.length+1)-o.column||1;t+="\n --\x3e "+a+"\n"+l+" |\n"+n.line+" | "+p+"\n"+l+" | "+u("",o.column-1," ")+u("",c,"^")}else t+="\n at "+a}return t},p.buildMessage=function(e,t){var r={literal:function(e){return'"'+o(e.text)+'"'},class:function(e){var t=e.parts.map((function(e){return Array.isArray(e)?n(e[0])+"-"+n(e[1]):n(e)}));return"["+(e.inverted?"^":"")+t.join("")+"]"},any:function(){return"any character"},end:function(){return"end of input"},other:function(e){return e.description}};function i(e){return e.charCodeAt(0).toString(16).toUpperCase()}function o(e){return e.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function n(e){return e.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function a(e){return r[e.type](e)}return"Expected "+function(e){var t,r,i=e.map(a);if(i.sort(),i.length>0){for(t=1,r=1;t<i.length;t++)i[t-1]!==i[t]&&(i[r]=i[t],r++);i.length=r}switch(i.length){case 1:return i[0];case 2:return i[0]+" or "+i[1];default:return i.slice(0,-1).join(", ")+", or "+i[i.length-1]}}(e)+" but "+function(e){return e?'"'+o(e)+'"':"end of input"}(t)+" found."};t.StartRules=["version","bitmarkPlusPlus","bitmarkPlus","bitmarkMinusMinus","bitmarkPlusString","bitmarkMinusMinusString"]},8588:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkParserType=void 0;const i=(0,r(4718).superenum)({peggy:"peggy"});t.BitmarkParserType=i},8848:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.imageSourceChainContentProcessor=function(e,t,r,c,y){t===u.BitContentLevel.Chain?function(e,t,r,i,n){const{value:a}=i,u=o.Breakscape.unbreakscape(p.StringUtils.trimmedString(a),{textFormat:s.TextFormat.bitmarkMinusMinus,textLocation:l.TextLocation.tag});n.imageSourceUrl=u}(0,0,0,c,y):function(e,t,r,o,s){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("imageSource content",o);const{key:l}=o,p=n.Config.getTagConfigForTag(r,a.PropertyTag.fromValue(l)),c=e.bitContentProcessor(u.BitContentLevel.Chain,r,[o]),y=e.bitContentProcessor(u.BitContentLevel.Chain,null==p?void 0:p.chain,o.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("imageSource TAGS",y);const{imageSourceUrl:g}=c,{mockupId:d}=y,f=i(y,["mockupId"]);g||e.addWarning("[@imageSource] is missing the image url",o);d||e.addWarning("[@mockupId:xxx] is missing from [@imageSource]",o);const m=Object.assign({url:null!=g?g:"",mockupId:null!=d?d:""},f);s.imageSource=m}(e,0,r,c,y)};const o=r(7735),n=r(2028),a=r(166),s=r(385),l=r(6877),p=r(9681),u=r(3029)},8903:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitUtils=void 0;const i=r(777),o=r(4078),n=new i.TextParser;const a=new class{fillStringExample(e,t,r,i,o){if(t){Array.isArray(t)||(t=[t]);for(const a of t)if(!a.isExample&&(r?(a.example=a.__defaultExample,a.isExample=!0):a.example=i?n.toAst(i,{textFormat:e,isProperty:!0}):void 0,o))break}}fillBooleanExample(e,t,r,i){if(e){Array.isArray(e)||(e=[e]);for(const n of e)if(!n.isExample&&(!i||n.isCorrect)&&(t?(n.example=n.__defaultExample,n.isExample=!0):n.example=o.BooleanUtils.toBoolean(r),i))break}}};t.BitUtils=a},9248:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TAGS=void 0;const i=r(7797),o=r(9917),n={[i.TagConfigKey.title]:{tag:o.Tag.tag_title},[i.TagConfigKey.anchor]:{tag:o.Tag.tag_anchor},[i.TagConfigKey.tag_reference]:{tag:o.Tag.tag_reference},[i.TagConfigKey.property]:{tag:o.Tag.tag_property},[i.TagConfigKey.itemLead]:{tag:o.Tag.tag_itemLead},[i.TagConfigKey.instruction]:{tag:o.Tag.tag_instruction},[i.TagConfigKey.hint]:{tag:o.Tag.tag_hint},[i.TagConfigKey.true]:{tag:o.Tag.tag_true},[i.TagConfigKey.false]:{tag:o.Tag.tag_false},[i.TagConfigKey.sampleSolution]:{tag:o.Tag.tag_sampleSolution},[i.TagConfigKey.gap]:{tag:o.Tag.tag_gap},[i.TagConfigKey.tag_mark]:{tag:o.Tag.tag_mark},[i.TagConfigKey.resource]:{tag:o.Tag.tag_resource}};t.TAGS=n},9289:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.itemLeadChainContentProcessor=function(e,t,r,s,l){t===a.BitContentLevel.Chain?(0,n.itemLeadTagContentProcessor)(e,t,r,s,l):function(e,t,r,n,s){var l;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("item lead content",n);const p=i.Config.getTagConfigForTag(r,o.Tag.fromValue(n.type)),u=[n,...null!==(l=n.chain)&&void 0!==l?l:[]],c=e.bitContentProcessor(a.BitContentLevel.Chain,null==p?void 0:p.chain,u);e.DEBUG_CHAIN_TAGS&&e.debugPrint("item lead TAGS",c);s.itemLead=c.itemLead}(e,0,r,s,l)};const i=r(2028),o=r(9917),n=r(8216),a=r(3029)},9371:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardVariantConfig=void 0;t.CardVariantConfig=class{constructor(e,t,r,i){this.tags=e,this.bodyAllowed=t??!0,this.bodyRequired=r,this.repeatCount=i}toString(e){const t=Object.assign({},e);let r="";const i=[];this.bodyAllowed&&i.push("bodyAllowed"),this.bodyRequired&&i.push("bodyRequired"),null!=this.repeatCount&&i.push(`repeatCount=${this.repeatCount}`),r+=`[Flags]\n${i.join(", ")}`,r+="\n\n[Tags]";for(const e of Object.values(this.tags))r+=`\n${e.toString(t)}`;return r}}},9554:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextNodeType=void 0;const i=(0,r(4718).superenum)({text:"text",hardBreak:"hardBreak",paragraph:"paragraph",heading:"heading",section:"section",noBulletList:"noBulletList",bulletList:"bulletList",orderedList:"orderedList",orderedListRoman:"orderedListRoman",orderedListRomanLower:"orderedListRomanLower",letteredList:"letteredList",letteredListLower:"letteredListLower",taskList:"taskList",listItem:"listItem",taskItem:"taskItem",image:"image",imageInline:"imageInline",codeBlock:"codeBlock",latex:"latex",gap:"gap",select:"select",highlight:"highlight",mark:"mark"});t.TextNodeType=i},9561:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Os=void 0;const i=(0,r(4718).superenum)({unknown:"",macos:"macos",windows:"windows",linux:"linux",android:"android",ios:"ios"});t.Os=i},9600:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceTagConfig=void 0;const i=r(5512),o=r(6634);class n extends o.AbstractTagConfig{constructor(e,t,r,o,n,a,s){super(i.BitTagType.resource,e,t,r,o,n,a,void 0,s),this.type=i.BitTagType.resource}toString(e){const t=Object.assign({},e);let r=`RES[${this.tag}`;if(t.includeConfigs&&(null!=this.deprecated&&(r+=`, deprecated=${this.deprecated}`),null!=this.maxCount&&(r+=`, max=${this.maxCount}`),null!=this.minCount&&(r+=`, min=${this.minCount}`),null!=this.jsonKey&&(r+=`, json=${this.jsonKey}`)),r+="]",this.chain&&t.includeChains){r+="\n|__";let e=!0;for(const i of Object.values(this.chain))e||(r+=" "),r+=`${i.toString(t)}`,e=!1}return r}}t.ResourceTagConfig=n},9647:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.propertyContentProcessor=function(e,t,r,m,S){const{value:A}=m;let{key:L}=m;const I=t===w.BitContentLevel.Chain,F=o.Config.getTagConfigForTag(r,p.PropertyTag.fromValue(L)),N=F?F.configKey:void 0;if(L===p.PropertyTag.internalComment)return void(0,B.commentTagContentProcessor)(e,t,m,S);if(F){if(N===s.PropertyConfigKey.example)return void(0,h.exampleTagContentProcessor)(e,t,m,S);if(N===s.PropertyConfigKey.ratingLevelStart||N===s.PropertyConfigKey.ratingLevelEnd)return void(0,P.ratingLevelChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.technicalTerm)return void(0,K.technicalTermChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.servings)return void(0,k.servingsChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.person||N===s.PropertyConfigKey.partner)return void(0,C.personChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.imageSource)return void(0,b.imageSourceChainContentProcessor)(e,t,r,m,S);if(N===s.PropertyConfigKey.book)return void(0,T.bookChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.markConfig&&!I)return void(0,v.markConfigChainContentProcessor)(e,t,r,m,S);if(N===s.PropertyConfigKey.property_title&&I)L="propertyTitle";else if(N===s.PropertyConfigKey.imagePlaceholder)return void(0,x.propertyStyleResourceContentProcessor)(e,t,r,m,S,u.ResourceTag.image)}const O=(e,t,r,o)=>{if(r=(e=>{if(null!=e){if(o)switch(o.format){case l.PropertyFormat.trimmedString:return i.Breakscape.unbreakscape(f.StringUtils.isString(e)?f.StringUtils.trimmedString(e):void 0,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag});case l.PropertyFormat.number:return d.NumberUtils.asNumber(i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag}));case l.PropertyFormat.boolean:return g.BooleanUtils.toBoolean(i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag}),!0);case l.PropertyFormat.invertedBoolean:return!g.BooleanUtils.toBoolean(i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag}),!0);case l.PropertyFormat.bitmarkMinusMinus:return e=f.StringUtils.isString(e)?e:"",_.toAst(e,{textFormat:c.TextFormat.bitmarkMinusMinus,isProperty:!0});case l.PropertyFormat.bitmarkPlusPlus:return e=f.StringUtils.isString(e)?e:"",_.toAst(e,{textFormat:c.TextFormat.bitmarkPlusPlus,isProperty:!0})}return i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag})}})(r),(null==o?void 0:o.astKey)&&(t=o.astKey),null==o?void 0:o.single)e[t]=r;else if(Object.prototype.hasOwnProperty.call(e,t)){const i=e[t];e[t]=[...i,r]}else e[t]=[r]};O(F?S:S.extraProperties,L,A,F);L===p.PropertyTag.tag_sampleSolution&&O(S,"__sampleSolutionAst",A,new n.PropertyTagConfig(a.ConfigKey.sampleSolution,p.PropertyTag.tag_sampleSolution,1,1,void 0,void 0,void 0,!0,l.PropertyFormat.bitmarkMinusMinus,void 0,void 0))};const i=r(7735),o=r(2028),n=r(1519),a=r(5591),s=r(9888),l=r(9727),p=r(166),u=r(6149),c=r(385),y=r(6877),g=r(4078),d=r(8025),f=r(9681),m=r(777),T=r(3045),h=r(4091),b=r(8848),B=r(6991),v=r(3063),C=r(21),P=r(3967),x=r(6521),k=r(4953),K=r(4475),w=r(3029),_=new m.TextParser},9681:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.StringUtils=void 0;const r=new class{isString(e){return"string"==typeof e||e instanceof String}string(e){return e?`${e}`:""}trimmedString(e){return this.string(e).trim()}countOccurrences(e,t){return e.split(t).length-1}countOccurrencesAtStart(e,t){let r=0;for(;e.startsWith(t);)r++,e=e.substring(t.length);return r}countOccurrencesAtEnd(e,t){let r=0;for(;e.endsWith(t);)r++,e=e.substring(0,e.length-t.length);return r}splitPlaceholders(e,t){let r=[e];const i=(e,t)=>{const r=[];for(const i of e){const e=i.split(t);for(let i=0,o=e.length;i<o;i++){const n=e[i],a=i===o-1;r.push(n),a||r.push(t)}}return r};for(const e of t)r=i(r,e);return r}firstLine(e,t){const r=e;if(null==t&&(t=e.length),t<1||null==e||e.length<=t)return r;const i=e.split("\n");return i.length>0?i[0].substring(0,t):r}wordWrap(e,t){const r=[];if(t<1||null==e||e.length<=t)return r;const i=e.length,o=i-t;let n,a=0;for(;a<o;){let i;const o=a+t,s=e.indexOf("\n",a);if(s>-1&&s>a&&s<o){i=s-a,n=e.substr(a,i),a=a+i+1,r.push(n);continue}const l=e.lastIndexOf(" ",o);let p=0;l>-1&&l!=a-1?(i=l-a,i>0&&(p=a+i+1)):(i=t,p=a+t),n=e.substr(a,i),a=p,r.push(n.trim())}return a<i&&(n=e.substr(a),r.push(n)),r}};t.StringUtils=r},9727:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyFormat=void 0;const i=(0,r(4718).superenum)({none:"none",trimmedString:"trimmedString",bitmarkMinusMinus:"bitmarkMinusMinus",bitmarkPlusPlus:"bitmarkPlusPlus",number:"number",boolean:"boolean",invertedBoolean:"invertedBoolean"});t.PropertyFormat=i},9788:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.MarkupTagConfig=void 0;const i=r(5512),o=r(6634);class n extends o.AbstractTagConfig{constructor(e,t,r,o,n,a){super(i.BitTagType.tag,e,t,r,o,n,void 0,void 0,a),this.type=i.BitTagType.tag}toString(e){const t=Object.assign({},e);let r=`TAG[${this.tag}`;if(t.includeConfigs&&(null!=this.deprecated&&(r+=`, deprecated=${this.deprecated}`),null!=this.maxCount&&(r+=`, max=${this.maxCount}`),null!=this.minCount&&(r+=`, min=${this.minCount}`)),r+="]",this.chain&&t.includeChains){r+="\n|__";let e=!0;for(const i of Object.values(this.chain))e||(r+=" "),r+=`${i.toString(t)}`,e=!1}return r}}t.MarkupTagConfig=n},9885:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.trueFalseChainContentProcessor=function(e,t,r,p,u,c){t===l.BitContentLevel.Chain?(0,s.trueFalseTagContentProcessor)(e,l.BitContentLevel.Chain,p,u):function(e,t,r,s,p,u){var c;const{bitType:y}=e,g=[s,...null!==(c=s.chain)&&void 0!==c?c:[]],d=p.statements,f=p.choices,m=p.responses;if(!(d&&f&&m&&u))return;if(o.Config.isOfBitType(y,n.BitType.trueFalse1))p.statement=function(e,t,r){const{bitType:a}=e;if(!o.Config.isOfBitType(a,n.BitType.trueFalse1))return;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("trueFalse V1 content (statement)",r);const s=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:p}=s,u=i(s,["trueFalse"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("trueFalse V1 tags (statement)",u);let c,y;p&&p.length>0&&(y=p[0]);if(y){const{statement:e}=u,t=i(u,["statement"]);c=Object.assign(Object.assign(Object.assign({},y),{statement:y.text}),t)}return c}(e,r,g);else if(o.Config.isOfBitType(y,[n.BitType.trueFalse,n.BitType.multipleChoice,n.BitType.multipleChoice1,n.BitType.multipleResponse,n.BitType.multipleResponse1,n.BitType.feedback])){const t=function(e,t,r){const{bitType:a}=e,s=o.Config.isOfBitType(a,n.BitType.trueFalse),p=o.Config.isOfBitType(a,[n.BitType.multipleChoice,n.BitType.multipleChoice1,n.BitType.feedback]),u=o.Config.isOfBitType(a,[n.BitType.multipleResponse,n.BitType.multipleResponse1]);if(!s&&!p&&!u)return{};const c=[],y=[],g=[],d=e.splitBitContent(r,[l.TypeKey.True,l.TypeKey.False]);e.DEBUG_CHAIN_CONTENT&&e.debugPrint("trueFalse V1 content (choices/responses)",d);for(const r of d){const o=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:n}=o,a=i(o,["trueFalse"]);let d;if(e.DEBUG_CHAIN_TAGS&&e.debugPrint("trueFalse V1 tags (choices/responses)",a),n&&n.length>0&&(d=n[0]),d)if(s){const{statement:e}=a,t=i(a,["statement"]),r=Object.assign(Object.assign(Object.assign({},d),{statement:d.text}),t);r&&c.push(r)}else if(p){const e=Object.assign(Object.assign(Object.assign({},d),{choice:d.text}),a);e&&y.push(e)}else if(u){const e=Object.assign(Object.assign(Object.assign({},d),{response:d.text}),a);e&&g.push(e)}}const f={};s?f.statements=c:p?f.choices=y:u&&(f.responses=g);return f}(e,r,g);t.statements&&d.push(...t.statements),t.choices&&f.push(...t.choices),t.responses&&m.push(...t.responses)}else if(o.Config.isOfBitType(y,n.BitType.highlightText)){const t=function(e,t,r){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("highlight content",r);const o=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:n}=o,s=i(o,["trueFalse"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("highlight TAGS",Object.assign({trueFalse:n},s));const p=[];if(n)for(const e of n){const t=Object.assign(Object.assign({},e),{isHighlighted:!1});t&&p.push(t)}const u=Object.assign({type:a.BodyBitType.highlight,texts:p},s);return u}(e,r,g);t&&u.push(t)}else{const t=function(e,t,r){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("select content",r);const o=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:n}=o,s=i(o,["trueFalse"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("select TAGS",Object.assign({trueFalse:n},s));const p=[];if(n)for(const e of n){const t=e;t&&p.push(t)}const u=Object.assign({type:a.BodyBitType.select,options:p},s);return u}(e,r,g);t&&u.push(t)}}(e,0,r,p,u,c)};const o=r(2028),n=r(5854),a=r(4410),s=r(4020),l=r(3029)},9888:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.propertyConfigKeys=t.PropertyConfigKey=void 0;const i=r(4718),o={action:"action",activityType:"activityType",additionalSolutions:"additionalSolutions",ageRange:"ageRange",aiGenerated:"aiGenerated",analyticsTag:"analyticsTag",allowedBit:"allowedBit",allowSubtitles:"allowSubtitles",alt:"alt",altLangTag:"altLangTag",author:"author",autoplay:"autoplay",availableClassifications:"availableClassifications",backgroundWallpaper:"backgroundWallpaper",blockId:"blockId",book:"book",bookAlias:"bookAlias",bookDiff:"bookDiff",bot:"bot",bubbleTag:"bubbleTag",buttonCaption:"buttonCaption",callToActionUrl:"callToActionUrl",caption:"caption",categoryTag:"categoryTag",chatWithBook:"chatWithBook",chatWithBookBrainKey:"chatWithBookBrainKey",citationStyle:"citationStyle",classification:"classification",codeLineNumbers:"codeLineNumbers",codeMinimap:"codeMinimap",color:"color",colorTag:"colorTag",computerLanguage:"computerLanguage",content2Buy:"content2Buy",copyright:"copyright",coverColor:"coverColor",coverImage:"coverImage",customerExternalId:"customerExternalId",customerId:"customerId",date:"date",dateEnd:"dateEnd",decimalPlaces:"decimalPlaces",deeplink:"deeplink",disableCalculation:"disableCalculation",disableFeedback:"disableFeedback",diffTo:"diffTo",diffOp:"diffOp",diffRef:"diffRef",diffContext:"diffContext",diffTime:"diffTime",duration:"duration",emphasis:"emphasis",example:"example",externalId:"externalId",externalLink:"externalLink",externalLinkText:"externalLinkText",feedbackEngine:"feedbackEngine",feedbackType:"feedbackType",flashcardSet:"flashcardSet",focusX:"focusX",focusY:"focusY",format:"format",handInAcceptFileType:"handInAcceptFileType",handInRequirement:"handInRequirement",handInInstruction:"handInInstruction",hasBookNavigation:"hasBookNavigation",hasMarkAsDone:"hasMarkAsDone",height:"height",icon:"icon",iconTag:"iconTag",id:"id",imageFirst:"imageFirst",imagePlaceholder:"imagePlaceholder",imageSource:"imageSource",index:"index",internalComment:"internalComment",isCaseSensitive:"isCaseSensitive",isInfoOnly:"isInfoOnly",isPublic:"isPublic",isTracked:"isTracked",jupyterExecutionCount:"jupyterExecutionCount",jupyterId:"jupyterId",kind:"kind",label:"label",labelFalse:"labelFalse",labelTrue:"labelTrue",lang:"lang",language:"language",layer:"layer",levelCEFRp:"levelCEFRp",levelCEFR:"levelCEFR",levelILR:"levelILR",levelACTFL:"levelACTFL",license:"license",list:"list",listItemIndent:"listItemIndent",location:"location",machineTranslated:"machineTranslated",mailingList:"mailingList",markConfig:"markConfig",maxCreatedBits:"maxCreatedBits",maxDisplayLevel:"maxDisplayLevel",maxTocChapterLevel:"maxTocChapterLevel",mockupId:"mockupId",mute:"mute",padletId:"padletId",pageNo:"pageNo",partialAnswer:"partialAnswer",partner:"partner",person:"person",path:"path",pointerLeft:"pointerLeft",pointerTop:"pointerTop",posterImage:"posterImage",page:"page",processHandIn:"processHandIn",product:"product",productFolder:"productFolder",productId:"productId",productList:"productList",productVideo:"productVideo",productVideoList:"productVideoList",progress:"progress",property_mark:"property_mark",property_reference:"property_reference",property_sampleSolution:"property_sampleSolution",property_title:"property_title",publications:"publications",publisher:"publisher",publisherName:"publisherName",quizCountItems:"quizCountItems",quizStrikethroughSolutions:"quizStrikethroughSolutions",quotedPerson:"quotedPerson",ratingLevelEnd:"ratingLevelEnd",ratingLevelSelected:"ratingLevelSelected",ratingLevelStart:"ratingLevelStart",reaction:"reaction",reasonableNumOfChars:"reasonableNumOfChars",reductionTag:"reductionTag",refAuthor:"refAuthor",refBookTitle:"refBookTitle",refPublisher:"refPublisher",refPublicationYear:"refPublicationYear",releaseDate:"releaseDate",releaseKind:"releaseKind",releaseVersion:"releaseVersion",resolved:"resolved",resolvedBy:"resolvedBy",resolvedDate:"resolvedDate",revealSolutions:"revealSolutions",scormSource:"scormSource",search:"search",searchIndex:"searchIndex",servings:"servings",showInIndex:"showInIndex",showSubtitles:"showSubtitles",siteName:"siteName",size:"size",slug:"slug",spaceId:"spaceId",src1x:"src1x",src2x:"src2x",src3x:"src3x",src4x:"src4x",stripePricingTableId:"stripePricingTableId",stripePublishableKey:"stripePublishableKey",subject:"subject",subtype:"subtype",tableAutoWidth:"tableAutoWidth",tableFixedHeader:"tableFixedHeader",tableHeight:"tableHeight",tablePagination:"tablePagination",tablePaginationLimit:"tablePaginationLimit",tableResizableColumns:"tableResizableColumns",tableColumnMinWidth:"tableColumnMinWidth",tableSearch:"tableSearch",tableSort:"tableSort",tableWhitespaceNoWrap:"tableWhitespaceNoWrap",tag:"tag",target:"target",technicalTerm:"technicalTerm",textReference:"textReference",theme:"theme",thumbImage:"thumbImage",toc:"toc",topicTag:"topicTag",trim:"trim",unit:"unit",unitAbbr:"unitAbbr",vendorDashboardId:"vendorDashboardId",vendorSurveyId:"vendorSurveyId",vendorUrl:"vendorUrl",videoCallLink:"videoCallLink",width:"width",x:"x",y:"y",zoomDisabled:"zoomDisabled"};t.propertyConfigKeys=o;const n=(0,i.superenum)(o);t.PropertyConfigKey=n},9916:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTIES=void 0;const i=r(9888),o=r(7203),n=r(9727),a=r(166),s={[i.PropertyConfigKey.id]:{tag:a.PropertyTag.id,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.internalComment]:{tag:a.PropertyTag.internalComment,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.customerId]:{tag:a.PropertyTag.customerId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.customerExternalId]:{tag:a.PropertyTag.customerExternalId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.externalId]:{tag:a.PropertyTag.externalId,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.spaceId]:{tag:a.PropertyTag.spaceId,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.padletId]:{tag:a.PropertyTag.padletId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.jupyterId]:{tag:a.PropertyTag.jupyterId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.jupyterExecutionCount]:{tag:a.PropertyTag.jupyterExecutionCount,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.aiGenerated]:{tag:a.PropertyTag.aiGenerated,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.machineTranslated]:{tag:a.PropertyTag.machineTranslated,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.searchIndex]:{tag:a.PropertyTag.searchIndex,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.analyticsTag]:{tag:a.PropertyTag.analyticsTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.categoryTag]:{tag:a.PropertyTag.categoryTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.topicTag]:{tag:a.PropertyTag.topicTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.altLangTag]:{tag:a.PropertyTag.altLangTag,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.feedbackEngine]:{tag:a.PropertyTag.feedbackEngine,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.disableFeedback]:{tag:a.PropertyTag.disableFeedback,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.diffTo]:{tag:a.PropertyTag.diffTo,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffOp]:{tag:a.PropertyTag.diffOp,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffRef]:{tag:a.PropertyTag.diffRef,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffContext]:{tag:a.PropertyTag.diffContext,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffTime]:{tag:a.PropertyTag.diffTime,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.path]:{tag:a.PropertyTag.path,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.releaseVersion]:{tag:a.PropertyTag.releaseVersion,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.releaseKind]:{tag:a.PropertyTag.releaseKind,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.releaseDate]:{tag:a.PropertyTag.releaseDate,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.resolved]:{tag:a.PropertyTag.resolved,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.resolvedDate]:{tag:a.PropertyTag.resolvedDate,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.resolvedBy]:{tag:a.PropertyTag.resolvedBy,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.handInAcceptFileType]:{tag:a.PropertyTag.handInAcceptFileType,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.handInRequirement]:{tag:a.PropertyTag.handInRequirement,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.handInInstruction]:{tag:a.PropertyTag.handInInstruction,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.ageRange]:{tag:a.PropertyTag.ageRange,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.lang]:{tag:a.PropertyTag.lang,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.language]:{tag:a.PropertyTag.language,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.computerLanguage]:{tag:a.PropertyTag.computerLanguage,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.target]:{tag:a.PropertyTag.target,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.slug]:{tag:a.PropertyTag.slug,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.tag]:{tag:a.PropertyTag.tag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.reductionTag]:{tag:a.PropertyTag.reductionTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bubbleTag]:{tag:a.PropertyTag.bubbleTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelCEFRp]:{tag:a.PropertyTag.levelCEFRp,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelCEFR]:{tag:a.PropertyTag.levelCEFR,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelILR]:{tag:a.PropertyTag.levelILR,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelACTFL]:{tag:a.PropertyTag.levelACTFL,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.icon]:{tag:a.PropertyTag.icon,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.iconTag]:{tag:a.PropertyTag.iconTag,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.colorTag]:{tag:a.PropertyTag.colorTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.flashcardSet]:{tag:a.PropertyTag.flashcardSet,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.subtype]:{tag:a.PropertyTag.subtype,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bookAlias]:{tag:a.PropertyTag.bookAlias,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bookDiff]:{tag:a.PropertyTag.bookDiff,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refAuthor]:{tag:a.PropertyTag.refAuthor,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refBookTitle]:{tag:a.PropertyTag.refBookTitle,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refPublisher]:{tag:a.PropertyTag.refPublisher,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refPublicationYear]:{tag:a.PropertyTag.refPublicationYear,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.citationStyle]:{tag:a.PropertyTag.citationStyle,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.coverImage]:{tag:a.PropertyTag.coverImage,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.coverColor]:{tag:a.PropertyTag.coverColor,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.imagePlaceholder]:{tag:a.PropertyTag.imagePlaceholder,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.publisher]:{tag:a.PropertyTag.publisher,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.publisherName]:{tag:a.PropertyTag.publisherName,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.publications]:{tag:a.PropertyTag.publications,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.author]:{tag:a.PropertyTag.author,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.subject]:{tag:a.PropertyTag.subject,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.date]:{tag:a.PropertyTag.date,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.dateEnd]:{tag:a.PropertyTag.dateEnd,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.location]:{tag:a.PropertyTag.location,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.theme]:{tag:a.PropertyTag.theme,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.kind]:{tag:a.PropertyTag.kind,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.hasMarkAsDone]:{tag:a.PropertyTag.hasMarkAsDone,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.processHandIn]:{tag:a.PropertyTag.processHandIn,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.isPublic]:{tag:a.PropertyTag.isPublic,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.chatWithBook]:{tag:a.PropertyTag.chatWithBook,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.chatWithBookBrainKey]:{tag:a.PropertyTag.chatWithBookBrainKey,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.action]:{tag:a.PropertyTag.action,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.thumbImage]:{tag:a.PropertyTag.thumbImage,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.scormSource]:{tag:a.PropertyTag.scormSource,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.posterImage]:{tag:a.PropertyTag.posterImage,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.focusX]:{tag:a.PropertyTag.focusX,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.focusY]:{tag:a.PropertyTag.focusY,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.deeplink]:{tag:a.PropertyTag.deeplink,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.externalLink]:{tag:a.PropertyTag.externalLink,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.externalLinkText]:{tag:a.PropertyTag.externalLinkText,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.videoCallLink]:{tag:a.PropertyTag.videoCallLink,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.vendorDashboardId]:{tag:a.PropertyTag.vendorDashboardId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.vendorSurveyId]:{tag:a.PropertyTag.vendorSurveyId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.vendorUrl]:{tag:a.PropertyTag.vendorUrl,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.search]:{tag:a.PropertyTag.search,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bot]:{tag:a.PropertyTag.bot,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.duration]:{tag:a.PropertyTag.duration,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.property_reference]:{tag:a.PropertyTag.tag_reference,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_referenceProperty},[i.PropertyConfigKey.list]:{tag:a.PropertyTag.list,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.layer]:{tag:a.PropertyTag.layer,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.textReference]:{tag:a.PropertyTag.textReference,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.isTracked]:{tag:a.PropertyTag.isTracked,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.isInfoOnly]:{tag:a.PropertyTag.isInfoOnly,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.labelTrue]:{tag:a.PropertyTag.labelTrue,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.labelFalse]:{tag:a.PropertyTag.labelFalse,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.content2Buy]:{tag:a.PropertyTag.content2Buy,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.quotedPerson]:{tag:a.PropertyTag.quotedPerson,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.partialAnswer]:{tag:a.PropertyTag.partialAnswer,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.reasonableNumOfChars]:{tag:a.PropertyTag.reasonableNumOfChars,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.maxCreatedBits]:{tag:a.PropertyTag.maxCreatedBits,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.maxDisplayLevel]:{tag:a.PropertyTag.maxDisplayLevel,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.maxTocChapterLevel]:{tag:a.PropertyTag.maxTocChapterLevel,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.technicalTerm]:{tag:a.PropertyTag.technicalTerm,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.servings]:{tag:a.PropertyTag.servings,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.unit]:{tag:a.PropertyTag.unit,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.unitAbbr]:{tag:a.PropertyTag.unitAbbr,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.decimalPlaces]:{tag:a.PropertyTag.decimalPlaces,single:!0,format:n.PropertyFormat.number,defaultValue:"1"},[i.PropertyConfigKey.disableCalculation]:{tag:a.PropertyTag.disableCalculation,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.example]:{tag:a.PropertyTag.example,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.toc]:{tag:a.PropertyTag.toc,single:!0,format:n.PropertyFormat.boolean,defaultValue:"true"},[i.PropertyConfigKey.page]:{tag:a.PropertyTag.page,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.product]:{tag:a.PropertyTag.product,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.productId]:{tag:a.PropertyTag.productId,single:!1,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.productList]:{tag:a.PropertyTag.product,single:!1,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_productList},[i.PropertyConfigKey.productVideo]:{tag:a.PropertyTag.productVideo,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.productVideoList]:{tag:a.PropertyTag.productVideo,single:!1,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_productVideoList},[i.PropertyConfigKey.productFolder]:{tag:a.PropertyTag.productFolder,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.progress]:{tag:a.PropertyTag.progress,single:!0,format:n.PropertyFormat.boolean,defaultValue:"true"},[i.PropertyConfigKey.book]:{tag:a.PropertyTag.book,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.person]:{tag:a.PropertyTag.person,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.partner]:{tag:a.PropertyTag.partner,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.property_sampleSolution]:{tag:a.PropertyTag.tag_sampleSolution,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.additionalSolutions]:{tag:a.PropertyTag.additionalSolutions,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.markConfig]:{tag:a.PropertyTag.tag_mark,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_markConfig},[i.PropertyConfigKey.property_mark]:{tag:a.PropertyTag.tag_mark,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.color]:{tag:a.PropertyTag.color,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.emphasis]:{tag:a.PropertyTag.emphasis,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.isCaseSensitive]:{tag:a.PropertyTag.isCaseSensitive,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.reaction]:{tag:a.PropertyTag.reaction,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.imageSource]:{tag:a.PropertyTag.imageSource,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.mockupId]:{tag:a.PropertyTag.mockupId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.size]:{tag:a.PropertyTag.size,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.format]:{tag:a.PropertyTag.format,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.property_title]:{tag:a.PropertyTag.tag_title,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.trim]:{tag:a.PropertyTag.trim,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.width]:{tag:a.PropertyTag.width,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.height]:{tag:a.PropertyTag.height,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.license]:{tag:a.PropertyTag.license,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.copyright]:{tag:a.PropertyTag.copyright,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.mailingList]:{tag:a.PropertyTag.mailingList,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.buttonCaption]:{tag:a.PropertyTag.buttonCaption,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.callToActionUrl]:{tag:a.PropertyTag.callToActionUrl,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.feedbackType]:{tag:a.PropertyTag.feedbackType,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.caption]:{tag:a.PropertyTag.caption,single:!0,format:n.PropertyFormat.bitmarkMinusMinus},[i.PropertyConfigKey.showInIndex]:{tag:a.PropertyTag.showInIndex,single:!0,format:n.PropertyFormat.boolean,defaultValue:"false"},[i.PropertyConfigKey.alt]:{tag:a.PropertyTag.alt,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.zoomDisabled]:{tag:a.PropertyTag.zoomDisabled,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.src1x]:{tag:a.PropertyTag.src1x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.src2x]:{tag:a.PropertyTag.src2x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.src3x]:{tag:a.PropertyTag.src3x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.src4x]:{tag:a.PropertyTag.src4x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.mute]:{tag:a.PropertyTag.mute,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.autoplay]:{tag:a.PropertyTag.autoplay,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.allowSubtitles]:{tag:a.PropertyTag.allowSubtitles,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.showSubtitles]:{tag:a.PropertyTag.showSubtitles,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.siteName]:{tag:a.PropertyTag.siteName,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.pointerLeft]:{tag:a.PropertyTag.pointerLeft,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.pointerTop]:{tag:a.PropertyTag.pointerTop,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.listItemIndent]:{tag:a.PropertyTag.listItemIndent,single:!0,defaultValue:"0",format:n.PropertyFormat.number},[i.PropertyConfigKey.backgroundWallpaper]:{tag:a.PropertyTag.backgroundWallpaper,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.hasBookNavigation]:{tag:a.PropertyTag.hasBookNavigation,single:!0,defaultValue:"true",format:n.PropertyFormat.boolean},[i.PropertyConfigKey.blockId]:{tag:a.PropertyTag.blockId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.pageNo]:{tag:a.PropertyTag.pageNo,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.x]:{tag:a.PropertyTag.x,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.y]:{tag:a.PropertyTag.y,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.index]:{tag:a.PropertyTag.index,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.classification]:{tag:a.PropertyTag.classification,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.availableClassifications]:{tag:a.PropertyTag.availableClassifications,single:!1,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.allowedBit]:{tag:a.PropertyTag.allowedBit,single:!1,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.tableFixedHeader]:{tag:a.PropertyTag.tableFixedHeader,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableSearch]:{tag:a.PropertyTag.tableSearch,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableSort]:{tag:a.PropertyTag.tableSort,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tablePagination]:{tag:a.PropertyTag.tablePagination,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tablePaginationLimit]:{tag:a.PropertyTag.tablePaginationLimit,single:!0,format:n.PropertyFormat.number,defaultValue:"0"},[i.PropertyConfigKey.tableHeight]:{tag:a.PropertyTag.tableHeight,single:!0,format:n.PropertyFormat.number,defaultValue:"0"},[i.PropertyConfigKey.tableWhitespaceNoWrap]:{tag:a.PropertyTag.tableWhitespaceNoWrap,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableAutoWidth]:{tag:a.PropertyTag.tableAutoWidth,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableResizableColumns]:{tag:a.PropertyTag.tableResizableColumns,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableColumnMinWidth]:{tag:a.PropertyTag.tableColumnMinWidth,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.quizCountItems]:{tag:a.PropertyTag.quizCountItems,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.quizStrikethroughSolutions]:{tag:a.PropertyTag.quizStrikethroughSolutions,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.codeLineNumbers]:{tag:a.PropertyTag.codeLineNumbers,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.codeMinimap]:{tag:a.PropertyTag.codeMinimap,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.stripePricingTableId]:{tag:a.PropertyTag.stripePricingTableId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.stripePublishableKey]:{tag:a.PropertyTag.stripePublishableKey,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.ratingLevelStart]:{tag:a.PropertyTag.ratingLevelStart,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.ratingLevelEnd]:{tag:a.PropertyTag.ratingLevelEnd,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.ratingLevelSelected]:{tag:a.PropertyTag.ratingLevelSelected,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.label]:{tag:a.PropertyTag.label,single:!0,format:n.PropertyFormat.bitmarkMinusMinus},[i.PropertyConfigKey.imageFirst]:{tag:a.PropertyTag.imageFirst,single:!0,format:n.PropertyFormat.boolean,defaultValue:"true"},[i.PropertyConfigKey.activityType]:{tag:a.PropertyTag.activityType,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.revealSolutions]:{tag:a.PropertyTag.revealSolutions,single:!0,format:n.PropertyFormat.boolean}};t.PROPERTIES=s},9917:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Tag=void 0;const i=(0,r(4718).superenum)({tag_title:"#",tag_anchor:"▼",tag_reference:"►",tag_property:"@",tag_itemLead:"%",tag_instruction:"!",tag_hint:"?",tag_true:"+",tag_false:"-",tag_sampleSolution:"$",tag_gap:"_",tag_mark:"=",tag_resource:"&"});t.Tag=i},9984:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceJsonKey=void 0;const i=(0,r(4718).superenum)({imageResponsive:"imageResponsive",imagePortrait:"imagePortrait",imageLandscape:"imageLandscape",imageEmbed:"imageEmbed",imageLink:"imageLink",audioEmbed:"audioEmbed",audioLink:"audioLink",videoEmbed:"videoEmbed",videoLink:"videoLink",stillImageFilm:"stillImageFilm",stillImageFilmEmbed:"stillImageFilmEmbed",stillImageFilmLink:"stillImageFilmLink",articleEmbed:"articleEmbed",articleLink:"articleLink",documentEmbed:"documentEmbed",documentLink:"documentLink",documentDownload:"documentDownload",appLink:"appLink",websiteLink:"websiteLink"});t.ResourceJsonKey=i}},t={};function r(i){var o=t[i];if(void 0!==o)return o.exports;var n=t[i]={exports:{}};return e[i].call(n.exports,n,n.exports,r),n.exports}r.d=(e,t)=>{for(var i in t)r.o(t,i)&&!r.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{var e=i;Object.defineProperty(e,"__esModule",{value:!0}),e.StreamWriter=e.FileWriter=e.BitmarkFileGenerator=e.JsonFileGenerator=e.bitmarkTextParse=e.InfoFormat=e.InfoType=e.CardSetVersion=e.BitmarkVersion=e.BitmarkParserType=e.NodeType=e.ResourceTag=e.TextFormat=e.BitType=e.StringWriter=e.BitmarkStringGenerator=e.BitmarkGenerator=e.BitmarkParser=e.JsonStringGenerator=e.JsonGenerator=e.JsonParser=e.Ast=e.ResourceBuilder=e.Builder=e.Output=e.Input=e.BitmarkParserGenerator=void 0;const t=r(1412);var o=r(1791);Object.defineProperty(e,"BitmarkParserGenerator",{enumerable:!0,get:function(){return o.BitmarkParserGenerator}}),Object.defineProperty(e,"Input",{enumerable:!0,get:function(){return o.Input}}),Object.defineProperty(e,"Output",{enumerable:!0,get:function(){return o.Output}});var n=r(5809);Object.defineProperty(e,"Builder",{enumerable:!0,get:function(){return n.Builder}});var a=r(5533);Object.defineProperty(e,"ResourceBuilder",{enumerable:!0,get:function(){return a.ResourceBuilder}});var s=r(5126);Object.defineProperty(e,"Ast",{enumerable:!0,get:function(){return s.Ast}});var l=r(5663);Object.defineProperty(e,"JsonParser",{enumerable:!0,get:function(){return l.JsonParser}});var p=r(2497);Object.defineProperty(e,"JsonGenerator",{enumerable:!0,get:function(){return p.JsonGenerator}});var u=r(98);Object.defineProperty(e,"JsonStringGenerator",{enumerable:!0,get:function(){return u.JsonStringGenerator}});var c=r(5633);Object.defineProperty(e,"BitmarkParser",{enumerable:!0,get:function(){return c.BitmarkParser}});var y=r(5087);Object.defineProperty(e,"BitmarkGenerator",{enumerable:!0,get:function(){return y.BitmarkGenerator}});var g=r(3968);Object.defineProperty(e,"BitmarkStringGenerator",{enumerable:!0,get:function(){return g.BitmarkStringGenerator}});var d=r(6772);Object.defineProperty(e,"StringWriter",{enumerable:!0,get:function(){return d.StringWriter}});var f=r(5854);Object.defineProperty(e,"BitType",{enumerable:!0,get:function(){return f.BitType}});var m=r(385);Object.defineProperty(e,"TextFormat",{enumerable:!0,get:function(){return m.TextFormat}});var T=r(6149);Object.defineProperty(e,"ResourceTag",{enumerable:!0,get:function(){return T.ResourceTag}});var h=r(126);Object.defineProperty(e,"NodeType",{enumerable:!0,get:function(){return h.NodeType}});var b=r(8588);Object.defineProperty(e,"BitmarkParserType",{enumerable:!0,get:function(){return b.BitmarkParserType}});var B=r(3811);Object.defineProperty(e,"BitmarkVersion",{enumerable:!0,get:function(){return B.BitmarkVersion}});var v=r(1163);Object.defineProperty(e,"CardSetVersion",{enumerable:!0,get:function(){return v.CardSetVersion}});var C=r(486);Object.defineProperty(e,"InfoType",{enumerable:!0,get:function(){return C.InfoType}});var P=r(3069);Object.defineProperty(e,"InfoFormat",{enumerable:!0,get:function(){return P.InfoFormat}});var x=r(2220);Object.defineProperty(e,"bitmarkTextParse",{enumerable:!0,get:function(){return x.parse}});(0,t.init)()})(),i})()));
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.bitmarkParserGenerator=t():e.bitmarkParserGenerator=t()}(this,(()=>(()=>{"use strict";var e={4:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.AstWalkerGenerator=void 0;const i=r(5126);t.AstWalkerGenerator=class{constructor(){this.ast=new i.Ast,this.debugGenerationInline=!1,this.printed=!1}enter(e,t,r){let i;const o=this,n=`enter_${e.key}`;return this.printed||(this.printed=!0),this.debugGenerationInline&&this.writeInlineDebug(e.key,{open:!0}),"function"==typeof o[n]&&(i=o[n](e,t,r)),i}between(e,t,r,i,o){let n;const a=this,s=`between_${e.key}`;return this.debugGenerationInline&&this.writeInlineDebug(e.key,{single:!0}),"function"==typeof a[s]&&(n=a[s](e,t,r,i,o)),n}exit(e,t,r){const i=this,o=`exit_${e.key}`;this.debugGenerationInline&&this.writeInlineDebug(e.key,{close:!0}),"function"==typeof i[o]&&i[o](e,t,r)}leaf(e,t,r){const i=this,o=`leaf_${e.key}`;this.debugGenerationInline&&this.writeInlineDebug(e.key,{open:!0}),"function"==typeof i[o]&&i[o](e,t,r),this.debugGenerationInline&&this.writeInlineDebug(e.key,{close:!0})}getParentNode(e,t=1){if(e.length>t)return e[e.length-t-1]}}},21:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.personChainContentProcessor=function(e,t,r,p,u){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("person content",p);const c=e.bitContentProcessor(l.BitContentLevel.Chain,r,p.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("person TAGS",c);const{propertyTitle:y,resources:g}=c,d=i.Breakscape.unbreakscape(s.StringUtils.trimmedString(p.value),{textFormat:n.TextFormat.bitmarkMinusMinus,textLocation:a.TextLocation.tag}),f=s.StringUtils.trimmedString(y),m=function(e,t){let r;const i=[];if(t)for(const e of t.reverse())r||o.ResourceTag.image!==e.type?i.push(e):r=e;i.length>0&&(e.parser.excessResources=i,e.addWarning(`${i.length} excess resource(s) present in the [@person] chain.`));return r}(e,g),T={name:d,title:f,avatarImage:m};u.person=T};const i=r(7735),o=r(6149),n=r(385),a=r(6877),s=r(9681),l=r(3029)},98:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonStringGenerator=void 0;const o=r(6772),n=r(2497);t.JsonStringGenerator=class{constructor(e){this.writer=new o.StringWriter,this.generator=new n.JsonGenerator(this.writer,e)}generate(e){return i(this,void 0,void 0,(function*(){return yield this.generator.generate(e),this.writer.getString()}))}generateSync(e){return this.generator.generateSync(e),this.writer.getString()}}},126:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.NodeType=void 0;const i=(0,r(4718).superenum)({unknown:"unknown",action:"action",actionValue:"actionValue",activityType:"activityType",activityTypeValue:"activityTypeValue",additionalSolutions:"additionalSolutions",additionalSolutionsValue:"additionalSolutionsValue",ageRange:"ageRange",ageRangeValue:"ageRangeValue",aiGenerated:"aiGenerated",aiGeneratedValue:"aiGeneratedValue",alias:"alias",alignment:"alignment",allowedBit:"allowedBit",allowedBitValue:"allowedBitValue",alt:"alt",alternativeAnswers:"alternativeAnswers",alternativeAnswersValue:"alternativeAnswersValue",alternativeDefinitions:"alternativeDefinitions",alternativeDefinitionsValue:"alternativeDefinitionsValue",altLangTag:"altLangTag",altLangTagValue:"altLangTagValue",analyticsTag:"analyticsTag",analyticsTagValue:"analyticsTagValue",anchor:"anchor",answer:"answer",appLink:"appLink",attrs:"attrs",audio:"audio",audioEmbed:"audioEmbed",audioLink:"audioLink",author:"author",authorValue:"authorValue",availableClassifications:"availableClassifications",availableClassificationsValue:"availableClassificationsValue",avatarImage:"avatarImage",backgroundWallpaper:"backgroundWallpaper",backgroundWallpaperValue:"backgroundWallpaperValue",bitLevel:"bitLevel",bitmarkAst:"bitmarkAst",bitmarkVersion:"bitmarkVersion",bits:"bits",bitsValue:"bitsValue",bitType:"bitType",blockId:"blockId",blockIdValue:"blockIdValue",body:"body",bodyValue:"bodyValue",bodyBit:"bodyBit",bodyBits:"bodyBits",bodyJson:"bodyJson",bodyParts:"bodyParts",bodyPartsValue:"bodyPartsValue",bodyPartText:"bodyPartText",bodyText:"bodyText",book:"book",bookValue:"bookValue",bookAlias:"bookAlias",bookAliasValue:"bookAliasValue",bookDiff:"bookDiff",bookDiffValue:"bookDiffValue",bot:"bot",botResponses:"botResponses",botResponsesValue:"botResponsesValue",botValue:"botValue",bubbleTag:"bubbleTag",bubbleTagValue:"bubbleTagValue",buttonCaption:"buttonCaption",buttonCaptionValue:"buttonCaptionValue",callToActionUrl:"callToActionUrl",callToActionUrlValue:"callToActionUrlValue",caption:"caption",captionDefinitionList:"captionDefinitionList",captionValue:"captionValue",cardBits:"cardBits",cardBitsValue:"cardBitsValue",cardNode:"cardNode",categoryTag:"categoryTag",categoryTagValue:"categoryTagValue",cells:"cells",cellsValue:"cellsValue",chatWithBook:"chatWithBook",chatWithBookValue:"chatWithBookValue",chatWithBookBrainKey:"chatWithBookBrainKey",chatWithBookBrainKeyValue:"chatWithBookBrainKeyValue",checked:"checked",choice:"choice",choices:"choices",choicesValue:"choicesValue",class:"class",classification:"classification",classificationValue:"classificationValue",codeLineNumbers:"codeLineNumbers",codeLineNumbersValue:"codeLineNumbersValue",codeMinimap:"codeMinimap",codeMinimapValue:"codeMinimapValue",color:"color",colorTag:"colorTag",colorTagValue:"colorTagValue",column:"column",columns:"columns",columnsValue:"columnsValue",comment:"comment",commentedBitType:"commentedBitType",computerLanguage:"computerLanguage",computerLanguageValue:"computerLanguageValue",content:"contentValue",content2Buy:"content2Buy",contentValue:"contentValue",contentValueValue:"contentValueValue",copyright:"copyright",coverColor:"coverColor",coverColorValue:"coverColorValue",coverImage:"coverImage",coverImageValue:"coverImageValue",customerExternalId:"customerExternalId",customerId:"customerId",customerIdValue:"customerIdValue",data:"data",dataValue:"dataValue",dataValueValue:"dataValueValue",date:"date",dateEnd:"dateEnd",dateEndValue:"dateEndValue",dateValue:"dateValue",decimalPlaces:"decimalPlaces",deeplink:"deeplink",deeplinkValue:"deeplinkValue",definition:"definition",definitions:"definitions",definitionsValue:"definitionsValue",disableCalculation:"disableCalculation",disableFeedback:"disableFeedback",disableFeedbackValue:"disableFeedbackValue",diffTo:"diffTo",diffToValue:"diffToValue",diffOp:"diffOp",diffOpValue:"diffOpValue",diffRef:"diffRef",diffRefValue:"diffRefValue",diffContext:"diffContext",diffContextValue:"diffContextValue",diffTime:"diffTime",diffTimeValue:"diffTimeValue",document:"document",documentDownload:"documentDownload",documentEmbed:"documentEmbed",documentLink:"documentLink",duration:"duration",durationValue:"durationValue",elements:"elements",elementsValue:"elementsValue",emphasis:"emphasis",end:"end",errors:"errors",errorsValue:"errorsValue",example:"example",exampleValue:"exampleValue",externalId:"externalId",externalIdValue:"externalIdValue",externalLink:"externalLink",externalLinkText:"externalLinkText",extraProperties:"extraProperties",feedbacks:"feedbacks",feedbacksValue:"feedbacksValue",feedback:"feedback",feedbackEngine:"feedbackEngine",feedbackEngineValue:"feedbackEngineValue",feedbackType:"feedbackType",flashcards:"flashcards",flashcardSet:"flashcardSet",flashcardSetValue:"flashcardSetValue",flashcardsValue:"flashcardsValue",focusX:"focusX",focusXValue:"focusXValue",focusY:"focusY",focusYValue:"focusYValue",footer:"footer",footerText:"footerText",forKeys:"forKeys",format:"format",forValues:"forValues",forValuesValue:"forValuesValue",gap:"gap",handInAcceptFileType:"handInAcceptFileType",handInAcceptFileTypeValue:"handInAcceptFileTypeValue",handInRequirement:"handInRequirement",handInRequirementValue:"handInRequirementValue",handInInstruction:"handInInstruction",handInInstructionValue:"handInInstructionValue",hasBookNavigation:"hasBookNavigation",hasBookNavigationValue:"hasBookNavigationValue",hasMarkAsDone:"hasMarkAsDone",hasMarkAsDoneValue:"hasMarkAsDoneValue",heading:"heading",height:"height",heightValue:"heightValue",highlight:"highlight",hint:"hint",href:"href",icon:"icon",iconTag:"iconTag",iconTagValue:"iconTagValue",iconValue:"iconValue",id:"id",idValue:"idValue",image:"image",imageFirst:"imageFirst",imageFirstValue:"imageFirstValue",imageLandscape:"imageLandscape",imageLink:"imageLink",imagePlaceholder:"imagePlaceholder",imagePlaceholderValue:"imagePlaceholderValue",imagePortrait:"imagePortrait",imageSource:"imageSource",index:"index",indexValue:"indexValue",ingredients:"ingredients",ingredientsValue:"ingredientsValue",instruction:"instruction",internalComment:"internalComment",internalCommentValue:"internalCommentValue",isCaseSensitive:"isCaseSensitive",isCommented:"isCommented",isCorrect:"isCorrect",__isDefaultExample:"__isDefaultExample",isExample:"isExample",isInfoOnly:"isInfoOnly",isInfoOnlyValue:"isInfoOnlyValue",isPlain:"isPlain",isPublic:"isPublic",isPublicValue:"isPublicValue",isTracked:"isTracked",isTrackedValue:"isTrackedValue",item:"item",itemLead:"itemLead",jupyterExecutionCount:"jupyterExecutionCount",jupyterExecutionCountValue:"jupyterExecutionCountValue",jupyterId:"jupyterId",jupyterIdValue:"jupyterIdValue",key:"key",keyAudio:"keyAudio",keyImage:"keyImage",kind:"kind",kindValue:"kindValue",label:"label",labelFalse:"labelFalse",labelFalseValue:"labelFalseValue",labelTrue:"labelTrue",labelTrueValue:"labelTrueValue",lang:"lang",language:"language",languageValue:"languageValue",langValue:"langValue",layer:"layer",layerValue:"layerValue",lead:"lead",level:"level",levelACTFL:"levelACTFL",levelACTFLValue:"levelACTFLValue",levelCEFR:"levelCEFR",levelCEFRp:"levelCEFRp",levelCEFRpValue:"levelCEFRpValue",levelCEFRValue:"levelCEFRValue",levelILR:"levelILR",levelILRValue:"levelILRValue",license:"license",line:"line",list:"list",listItemIndent:"listItemIndent",listItemIndentValue:"listItemIndentValue",listValue:"listValue",location:"location",locationValue:"locationValue",machineTranslated:"machineTranslated",machineTranslatedValue:"machineTranslatedValue",mailingList:"mailingList",marginNumber:"marginNumber",mark:"mark",markConfig:"markConfig",markConfigValue:"markConfigValue",marks:"marks",marksValue:"marksValue",markup:"markup",matrix:"matrix",matrixValue:"matrixValue",maxCreatedBits:"maxCreatedBits",maxCreatedBitsValue:"maxCreatedBitsValue",maxDisplayLevel:"maxDisplayLevel",maxDisplayLevelValue:"maxDisplayLevelValue",maxTocChapterLevel:"maxTocChapterLevel",maxTocChapterLevelValue:"maxTocChapterLevelValue",message:"message",mockupId:"mockupId",name:"name",offset:"offset",options:"options",optionsValue:"optionsValue",original:"original",padletId:"padletId",padletIdValue:"padletIdValue",page:"page",pageNo:"pageNo",pageNoValue:"pageNoValue",pageNumber:"pageNumber",pageValue:"pageValue",pairs:"pairs",pairsValue:"pairsValue",parent:"parent",parser:"parser",partialAnswer:"partialAnswer",partialAnswerValue:"partialAnswerValue",person:"person",path:"path",pathValue:"pathValue",pointerLeft:"pointerLeft",pointerLeftValue:"pointerLeftValue",pointerTop:"pointerTop",pointerTopValue:"pointerTopValue",posterImage:"posterImage",posterImageValue:"posterImageValue",postfix:"postfix",prefix:"prefix",processHandIn:"processHandIn",processHandInValue:"processHandInValue",product:"product",productFolder:"productFolder",productFolderValue:"productFolderValue",productId:"productId",productIdValue:"productIdValue",productList:"productList",productListValue:"productListValue",productValue:"productValue",productVideo:"productVideo",productVideoList:"productVideoList",productVideoListValue:"productVideoListValue",productVideoValue:"productVideoValue",progress:"progress",progressValue:"progressValue",pronunciationTable:"pronunciationTable",properties:"properties",property:"property",propertyKey:"propertyKey",propertyValue:"propertyValue",propertyValues:"propertyValues",provider:"provider",publications:"publications",publicationsValue:"publicationsValue",publisher:"publisher",publisherName:"publisherName",publisherNameValue:"publisherNameValue",publisherValue:"publisherValue",quantity:"quantity",question:"question",questions:"questions",questionsValue:"questionsValue",quizCountItems:"quizCountItems",quizCountItemsValue:"quizCountItemsValue",quizStrikethroughSolutions:"quizStrikethroughSolutions",quizStrikethroughSolutionsValue:"quizStrikethroughSolutionsValue",quizzes:"quizzes",quizzesValue:"quizzesValue",quotedPerson:"quotedPerson",ratingLevelEnd:"ratingLevelEnd",ratingLevelSelected:"ratingLevelSelected",ratingLevelSelectedValue:"ratingLevelSelectedValue",ratingLevelStart:"ratingLevelStart",reaction:"reaction",reason:"reason",reasonableNumOfChars:"reasonableNumOfChars",reasonableNumOfCharsValue:"reasonableNumOfCharsValue",reductionTag:"reductionTag",reductionTagValue:"reductionTagValue",refAuthor:"refAuthor",refBookTitle:"refBookTitle",reference:"reference",referenceEnd:"referenceEnd",referenceProperty:"referenceProperty",referencePropertyValue:"referencePropertyValue",refPublisher:"refPublisher",refPublicationYear:"refPublicationYear",citationStyle:"citationStyle",citationStyleValue:"citationStyleValue",releaseDate:"releaseDate",releaseDateValue:"releaseDateValue",releaseKind:"releaseKind",releaseKindValue:"releaseKindValue",releaseVersion:"releaseVersion",releaseVersionValue:"releaseVersionValue",resolved:"resolved",resolvedBy:"resolvedBy",resolvedByValue:"resolvedByValue",resolvedDate:"resolvedDate",resolvedDateValue:"resolvedDateValue",resolvedValue:"resolvedValue",resources:"resources",resourcesValue:"resourcesValue",resourceType:"resourceType",response:"response",responses:"responses",responsesValue:"responsesValue",revealSolutions:"revealSolutions",root:"root",sampleSolution:"sampleSolution",sampleSolutionValue:"sampleSolutionValue",scormSource:"scormSource",scormSourceValue:"scormSourceValue",search:"search",searchValue:"searchValue",searchIndex:"searchIndex",searchIndexValue:"searchIndexValue",section:"section",select:"select",servings:"servings",servingsValue:"servingsValue",showInIndex:"showInIndex",showInIndexValue:"showInIndexValue",size:"size",slug:"slug",slugValue:"slugValue",solution:"solution",solutions:"solutions",solutionsValue:"solutionsValue",spaceId:"spaceId",spaceIdValue:"spaceIdValue",src:"src",src1x:"src1x",src2x:"src2x",src3x:"src3x",src4x:"src4x",start:"start",statement:"statement",statements:"statements",statementsValue:"statementsValue",statementText:"statementText",stillImageFilmEmbed:"stillImageFilmEmbed",stillImageFilmLink:"stillImageFilmLink",stripePricingTableId:"stripePricingTableId",stripePricingTableIdValue:"stripePricingTableIdValue",stripePublishableKey:"stripePublishableKey",stripePublishableKeyValue:"stripePublishableKeyValue",subject:"subject",subjectValue:"subjectValue",subtitle:"subtitle",subtype:"subtype",subtypeValue:"subtypeValue",table:"table",tableAutoWidth:"tableAutoWidth",tableAutoWidthValue:"tableAutoWidthValue",tableFixedHeader:"tableFixedHeader",tableFixedHeaderValue:"tableFixedHeaderValue",tableHeight:"tableHeight",tableHeightValue:"tableHeightValue",tablePagination:"tablePagination",tablePaginationLimit:"tablePaginationLimit",tablePaginationLimitValue:"tablePaginationLimitValue",tablePaginationValue:"tablePaginationValue",tableResizableColumns:"tableResizableColumns",tableResizableColumnsValue:"tableResizableColumnsValue",tableColumnMinWidth:"tableColumnMinWidth",tableColumnMinWidthValue:"tableColumnMinWidthValue",tableSearch:"tableSearch",tableSearchValue:"tableSearchValue",tableSort:"tableSort",tableSortValue:"tableSortValue",tableWhitespaceNoWrap:"tableWhitespaceNoWrap",tableWhitespaceNoWrapValue:"tableWhitespaceNoWrapValue",tag:"tag",tagValue:"tagValue",target:"target",targetValue:"targetValue",technicalTerm:"technicalTerm",technicalTermValue:"technicalTermValue",term:"term",text:"text",textAlign:"textAlign",textAst:"textAst",textAstValue:"textAstValue",textFormat:"textFormat",textReference:"textReference",textReferenceValue:"textReferenceValue",texts:"texts",textsValue:"textsValue",theme:"theme",themeValue:"themeValue",thumbImage:"thumbImage",thumbImageValue:"thumbImageValue",thumbnails:"thumbnails",thumbnailsValue:"thumbnailsValue",title:"title",toc:"toc",tocValue:"tocValue",topicTag:"topicTag",topicTagValue:"topicTagValue",trim:"trim",type:"type",__typeAlias:"__typeAlias",unit:"unit",unitAbbr:"unitAbbr",url:"url",value:"value",values:"values",valuesValue:"valuesValue",vendorDashboardId:"vendorDashboardId",vendorDashboardIdValue:"vendorDashboardIdValue",vendorSurveyId:"vendorSurveyId",vendorSurveyIdValue:"vendorSurveyIdValue",vendorUrl:"vendorUrl",vendorUrlValue:"vendorUrlValue",version:"version",video:"video",videoCallLink:"videoCallLink",videoCallLinkValue:"videoCallLinkValue",videoEmbed:"videoEmbed",videoLink:"videoLink",warnings:"warnings",warningsValue:"warningsValue",websiteLink:"websiteLink",width:"width",widthValue:"widthValue",x:"x",xValue:"xValue",y:"y",yValue:"yValue",zoomDisabled:"zoomDisabled"});t.NodeType=i},166:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyTag=void 0;const i=r(4718),o=r(9888),n=(0,i.superenum)(Object.assign(Object.assign({},o.propertyConfigKeys),{tag_mark:"mark",tag_reference:"reference",tag_sampleSolution:"sampleSolution",tag_title:"title"}));t.PropertyTag=n},168:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.RESOURCES=void 0;const i=r(5051),o=r(9984),n=r(6149),a={[i.ResourceConfigKey.icon]:{tag:n.ResourceTag.icon},[i.ResourceConfigKey.image]:{tag:n.ResourceTag.image},[i.ResourceConfigKey.imagePortrait]:{tag:n.ResourceTag.imagePortrait,jsonKey:o.ResourceJsonKey.imagePortrait},[i.ResourceConfigKey.imageLandscape]:{tag:n.ResourceTag.imageLandscape,jsonKey:o.ResourceJsonKey.imageLandscape},[i.ResourceConfigKey.imageEmbed]:{tag:n.ResourceTag.imageEmbed,jsonKey:o.ResourceJsonKey.imageEmbed},[i.ResourceConfigKey.imageLink]:{tag:n.ResourceTag.imageLink,jsonKey:o.ResourceJsonKey.imageLink},[i.ResourceConfigKey.audio]:{tag:n.ResourceTag.audio},[i.ResourceConfigKey.audioEmbed]:{tag:n.ResourceTag.audioEmbed,jsonKey:o.ResourceJsonKey.audioEmbed},[i.ResourceConfigKey.audioLink]:{tag:n.ResourceTag.audioLink,jsonKey:o.ResourceJsonKey.audioLink},[i.ResourceConfigKey.video]:{tag:n.ResourceTag.video},[i.ResourceConfigKey.videoEmbed]:{tag:n.ResourceTag.videoEmbed,jsonKey:o.ResourceJsonKey.videoEmbed},[i.ResourceConfigKey.videoLink]:{tag:n.ResourceTag.videoLink,jsonKey:o.ResourceJsonKey.videoLink},[i.ResourceConfigKey.stillImageFilmEmbed]:{tag:n.ResourceTag.stillImageFilmEmbed,jsonKey:o.ResourceJsonKey.stillImageFilmEmbed},[i.ResourceConfigKey.stillImageFilmLink]:{tag:n.ResourceTag.stillImageFilmLink,jsonKey:o.ResourceJsonKey.stillImageFilmLink},[i.ResourceConfigKey.article]:{tag:n.ResourceTag.article},[i.ResourceConfigKey.articleEmbed]:{tag:n.ResourceTag.articleEmbed,jsonKey:o.ResourceJsonKey.articleEmbed},[i.ResourceConfigKey.articleLink]:{tag:n.ResourceTag.articleLink,jsonKey:o.ResourceJsonKey.articleLink},[i.ResourceConfigKey.document]:{tag:n.ResourceTag.document},[i.ResourceConfigKey.documentEmbed]:{tag:n.ResourceTag.documentEmbed,jsonKey:o.ResourceJsonKey.documentEmbed},[i.ResourceConfigKey.documentLink]:{tag:n.ResourceTag.documentLink,jsonKey:o.ResourceJsonKey.documentLink},[i.ResourceConfigKey.documentDownload]:{tag:n.ResourceTag.documentDownload,jsonKey:o.ResourceJsonKey.documentDownload},[i.ResourceConfigKey.appLink]:{tag:n.ResourceTag.appLink,jsonKey:o.ResourceJsonKey.appLink},[i.ResourceConfigKey.websiteLink]:{tag:n.ResourceTag.websiteLink,jsonKey:o.ResourceJsonKey.websiteLink}};t.RESOURCES=a},201:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.UrlUtils=void 0;const r=new class{fileExtensionFromUrl(e){let t;if(e)try{const r=new URL(e).pathname.split(".");r.length>1&&(t=r[r.length-1])}catch(e){}return t}domainFromUrl(e){let t;if(e)try{t=new URL(e).hostname}catch(e){}return t}};t.UrlUtils=r},363:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ExampleType=void 0;const i=(0,r(4718).superenum)({none:"none",string:"string",boolean:"boolean"});t.ExampleType=i},385:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextFormat=void 0;const i=(0,r(4718).superenum)({text:"text",latex:"latex",json:"json",xml:"xml",bitmarkMinusMinus:"bitmark--",bitmarkPlusPlus:"bitmark++"});t.TextFormat=i},431:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TextGenerator=void 0;const o=r(5126),n=r(7735),a=r(126),s=r(3811),l=r(385),p=r(6877),u=r(2483),c=r(9554),y=r(9681),g=r(4),d={bodyBitCallback:void 0,debugGenerationInline:!1},f="==",m=["*","`","_","!","="],T={[u.TextMarkType.bold]:"**",[u.TextMarkType.light]:"``",[u.TextMarkType.italic]:"__",[u.TextMarkType.highlight]:"!!"},h=[u.TextMarkType.bold,u.TextMarkType.light,u.TextMarkType.italic,u.TextMarkType.highlight],b=[u.TextMarkType.strike,u.TextMarkType.subscript,u.TextMarkType.superscript,u.TextMarkType.ins,u.TextMarkType.del,u.TextMarkType.underline,u.TextMarkType.doubleUnderline,u.TextMarkType.circle,u.TextMarkType.languageEm,u.TextMarkType.userUnderline,u.TextMarkType.userDoubleUnderline,u.TextMarkType.userStrike,u.TextMarkType.userCircle,u.TextMarkType.userHighlight,u.TextMarkType.notranslate,u.TextMarkType.link,u.TextMarkType.ref,u.TextMarkType.xref,u.TextMarkType.extref,u.TextMarkType.footnote,u.TextMarkType.footnoteStar,u.TextMarkType.symbol,u.TextMarkType.var,u.TextMarkType.code,u.TextMarkType.timer,u.TextMarkType.duration,u.TextMarkType.color,u.TextMarkType.comment],B=new RegExp(/(\n|\r\n)/,"g"),v=new RegExp(/https?:\/\/|mailto:(.*)/,"g"),C=new RegExp(/\]/,"g"),P="enter",x="between",k="exit";class K extends g.AstWalkerGenerator{constructor(e,t){var r,i;super(),this.ast=new o.Ast,this.generateOptions={},this.textFormat=l.TextFormat.bitmarkMinusMinus,this.textLocation=p.TextLocation.body,this.writerText="",this.nodeIndex=0,this.currentIndent=0,this.prevIndent=0,this.indentationStringCache="",this.inParagraph=!1,this.inHeading=!1,this.inCodeBlock=!1,this.exitedCodeBlock=!1,this.inBulletList=!1,this.inInline=!1,this.textDepth=0,this.placeholderIndex=0,this.placeholders={},this.rootParagraphNodeContentIndex=0,this.previousRootParagraphContextType=c.TextNodeType.text,this.inPreText=!1,this.thisNodeIsPreText=!1,this.preTextIndexTemp=-1,this.havePreText=!1,this.preTextIndex=-1,this.bitmarkVersion=null!==(r=s.BitmarkVersion.fromValue(e))&&void 0!==r?r:s.DEFAULT_BITMARK_VERSION,this.options=Object.assign(Object.assign({},d),t),this.debugGenerationInline=null!==(i=this.options.debugGenerationInline)&&void 0!==i&&i,this.bitmarkVersion,s.BitmarkVersion.v2,this.enter=this.enter.bind(this),this.between=this.between.bind(this),this.exit=this.exit.bind(this),this.leaf=this.leaf.bind(this)}generate(e,t,r,o){return i(this,void 0,void 0,(function*(){return this.generateSync(e,t,r,o)}))}generateSync(e,t,r,i){if(this.generateOptions=Object.assign({},i),this.validateGenerateOptions(e),this.generateOptions.plainTextDividerAllowed){const i=this.options.writeCallback,o=this.options.bodyBitCallback;this.options.writeCallback=void 0,this.options.bodyBitCallback=void 0,this.resetState(t,r),this.walkAndWrite(e),this.options.writeCallback=i,this.options.bodyBitCallback=o;const n=this.havePreText,a=this.preTextIndex;this.resetState(t,r),this.havePreText=n,this.preTextIndex=a,this.walkAndWrite(e)}else this.resetState(t,r),this.walkAndWrite(e);return this.writerText}getPlaceholders(){return this.placeholders}resetState(e,t){this.printed=!1,this.textFormat=null!=e?e:l.TextFormat.bitmarkMinusMinus,this.textLocation=t,this.writerText="",this.nodeIndex=0,this.currentIndent=0,this.prevIndent=0,this.indentationStringCache="",this.inParagraph=!1,this.inHeading=!1,this.inCodeBlock=!1,this.exitedCodeBlock=!1,this.inBulletList=!1,this.inInline=!1,this.textDepth=0,this.placeholderIndex=0,this.placeholders={},this.rootParagraphNodeContentIndex=0,this.previousRootParagraphContextType=c.TextNodeType.hardBreak,this.inPreText=!1,this.thisNodeIsPreText=!1,this.preTextIndexTemp=-1,this.havePreText=!1,this.preTextIndex=-1}walkAndWrite(e){this.ast.walk(e,a.NodeType.textAst,this,void 0)}enter_textAstValue(e,t){return this.handleEnterNode(e.value,t)}between_textAstValue(e,t,r,i){return this.handleBetweenNode(e.value,t,r,i)}exit_textAstValue(e,t){return this.handleExitNode(e.value,t)}enter_contentValue(e,t){return this.handleEnterContentValueNode(e,t)}between_contentValue(e,t,r,i){this.handleBetweenContentValueNode(e,t,r,i)}exit_contentValue(e,t){this.handleExitContentValueNode(e,t)}enter_contentValueValue(e,t){return this.handleEnterNode(e.value,t)}between_contentValueValue(e,t,r,i){this.handleBetweenNode(e.value,t,r,i)}exit_contentValueValue(e,t){return this.handleExitNode(e.value,t)}handleEnterNode(e,t){switch(this.handleEnterNodePreTextCheck(e,t),this.handleIndent(e),e.type){case c.TextNodeType.paragraph:this.inParagraph=!0,this.writeParagraph(e);break;case c.TextNodeType.hardBreak:this.writeHardBreak(e);break;case c.TextNodeType.text:this.writeMarks(e,P),this.writeText(e),this.writeMarks(e,x),0===this.textDepth&&(this.inInline=!0),this.textDepth++;break;case c.TextNodeType.heading:this.writeHeading(e),this.inHeading=!0;break;case c.TextNodeType.section:this.writeSection(e);break;case c.TextNodeType.listItem:case c.TextNodeType.taskItem:this.writeBullet(e,t);break;case c.TextNodeType.image:case c.TextNodeType.imageInline:this.writeImage(e);break;case c.TextNodeType.codeBlock:this.inCodeBlock=!0,this.writeCodeBlock(e);break;case c.TextNodeType.latex:this.writeLatex(e);break;case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.inBulletList=!0;break;case c.TextNodeType.gap:case c.TextNodeType.select:case c.TextNodeType.highlight:case c.TextNodeType.mark:return this.writeBodyBit(e,t),!1}this.exitedCodeBlock=!1}handleBetweenNode(e,t,r,i){e.type}handleExitNode(e,t){switch(e.type){case c.TextNodeType.text:this.textDepth--,0===this.textDepth&&(this.inInline=!1),this.writeMarks(e,k);break;case c.TextNodeType.paragraph:this.textFormat!==l.TextFormat.bitmarkMinusMinus&&this.writeNL(),this.inParagraph=!1;break;case c.TextNodeType.heading:this.inHeading=!1;case c.TextNodeType.section:case c.TextNodeType.image:this.inParagraph||(this.writeNL(),this.writeNL());break;case c.TextNodeType.codeBlock:this.writeNL(),this.writeNL(),this.inCodeBlock=!1,this.exitedCodeBlock=!0;break;case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.currentIndent<=1&&(this.writeNL(),this.inBulletList=!1)}this.handleDedent(e),this.nodeIndex++}handleIndent(e){switch(e.type){case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.currentIndent++}}handleDedent(e){switch(e.type){case c.TextNodeType.noBulletList:case c.TextNodeType.bulletList:case c.TextNodeType.orderedList:case c.TextNodeType.orderedListRoman:case c.TextNodeType.orderedListRomanLower:case c.TextNodeType.letteredList:case c.TextNodeType.letteredListLower:case c.TextNodeType.taskList:this.currentIndent--}}handleEnterContentValueNode(e,t){3===t.length&&(this.thisNodeIsPreText=!0,this.inPreText=!1,this.previousRootParagraphContextType=c.TextNodeType.hardBreak)}handleBetweenContentValueNode(e,t,r,i){if(3===i.length){const e=t.value;this.updatePreTextState(),this.thisNodeIsPreText=!0,this.previousRootParagraphContextType=e.type,this.rootParagraphNodeContentIndex++}}handleExitContentValueNode(e,t){3===t.length&&(this.updatePreTextState(),this.thisNodeIsPreText=!1,this.generateOptions.plainTextDividerAllowed&&this.inPreText&&(this.havePreText=!0,this.preTextIndex=this.preTextIndexTemp),this.inPreText=!1)}updatePreTextState(){!this.inPreText&&this.thisNodeIsPreText&&this.previousRootParagraphContextType===c.TextNodeType.hardBreak?(this.inPreText=!0,this.preTextIndexTemp=this.rootParagraphNodeContentIndex):this.inPreText&&!this.thisNodeIsPreText&&(this.inPreText=!1,this.preTextIndexTemp=-1)}handleEnterNodePreTextCheck(e,t){if(4===t.length){if(this.inPreText&&e.type===c.TextNodeType.hardBreak)return;if(e.type===c.TextNodeType.text)return}this.thisNodeIsPreText=!1}getLinkHref(e){if(e.type===c.TextNodeType.text&&e.marks){const t=e.marks.reduce(((e,t)=>{var r;if(t.type===u.TextMarkType.link){const e=null===(r=t.attrs)||void 0===r?void 0:r.href;if(e)return e}return e}),"");if(t)return t}return!1}getIndentationString(){if(this.currentIndent===this.prevIndent)return this.indentationStringCache;let e="";for(let t=1;t<this.currentIndent;t++)e+="\t";return this.indentationStringCache=e,this.prevIndent=this.currentIndent,e}writeBodyBit(e,t){const r=`[!${this.placeholderIndex}]`;if(this.placeholders[r]=e,this.options.bodyBitCallback){const r=this.options.bodyBitCallback(e,this.placeholderIndex,t);this.write(r)}else this.write(r);this.placeholderIndex++}writeText(e){if(null==e.text)return;const t=this.inCodeBlock;let r=e.text;const i=this.getLinkText(e);if(i&&(r=i),r=i||this.breakscape(r,{textFormat:this.textFormat,textLocation:this.textLocation}),this.currentIndent>1){const e=this.getIndentationString();r=r.replace(B,`$1${e}`)}if(this.havePreText&&this.rootParagraphNodeContentIndex===this.preTextIndex&&(this.writePlainTextDivider(),this.writeNL()),this.havePreText&&this.rootParagraphNodeContentIndex>=this.preTextIndex){const t=this.breakscape(e.text,{textFormat:l.TextFormat.text,textLocation:this.textLocation});this.write(t)}else this.write(r);(this.currentIndent>1||t)&&(this.thisNodeIsPreText=!1),this.inPreText||e.text!==r||(this.thisNodeIsPreText=!1)}isSimpleLink(e){var t;if(null==e.text)return!1;if(1!==(null===(t=e.marks)||void 0===t?void 0:t.length))return!1;const r=this.getLinkHref(e);if(r){return r.replace(v,"$1")===e.text}return!1}getLinkText(e){if(null==e.text)return!1;const t=this.getLinkHref(e);if(t){let r;return r=t.replace(v,"$1")===e.text?t:e.text,r=(null!=r?r:"").replace(C,"^]"),r}return!1}getInterTextBreakscape(e){if(this.bitmarkVersion===s.BitmarkVersion.v2)return"";if(this.textFormat===l.TextFormat.text)return"";const t=this.writerText.slice(-1),r=e.slice(0,1);return t===r&&-1!==m.indexOf(t)||this.textLocation===p.TextLocation.body&&"["===t&&-1!=="@#▼►%!?+-$_=&".indexOf(r)?"^":""}validateGenerateOptions(e){this.generateOptions.plainTextDividerAllowed&&(1!==e.length||1===e.length&&e[0].type!==c.TextNodeType.paragraph)&&(this.generateOptions.plainTextDividerAllowed=!1)}writeMarks(e,t){if(e.marks){const r=this.inInline||this.inHeading?l.TextFormat.bitmarkMinusMinus:this.textFormat;this.thisNodeIsPreText=!1;if(0===e.marks.length)return void this.writeMarkTextWrapper(f);const i=1===e.marks.length&&r!==l.TextFormat.bitmarkPlusPlus,o=e.marks.reduce(((e,t)=>e||(-1!==h.indexOf(t.type)?i?T[t.type]:f:-1!==b.indexOf(t.type)?f:e)),void 0),n=this.isSimpleLink(e);if(null!=o&&!n){if(t!=P&&t!=x||this.writeMarkTextWrapper(o),t==x)for(const t of e.marks)-1!==h.indexOf(t.type)?i||(this.writeInlineMarkStartEnd(),this.writeInlineMark(t)):u.TextMarkType.comment===t.type?(this.writeInlineMarkStartEnd(),this.writeCommentMark(t)):u.TextMarkType.link===t.type?(this.writeInlineMarkStartEnd(),this.writeLinkMark(t)):u.TextMarkType.ref===t.type?(this.writeInlineMarkStartEnd(),this.writeRefMark(t)):u.TextMarkType.xref===t.type?(this.writeInlineMarkStartEnd(),this.writeXRefMark(t)):u.TextMarkType.extref===t.type?(this.writeInlineMarkStartEnd(),this.writeExtRefMark(t)):u.TextMarkType.footnote===t.type?(this.writeInlineMarkStartEnd(),this.writeFootnoteMark(t)):u.TextMarkType.footnoteStar===t.type?(this.writeInlineMarkStartEnd(),this.writeFootnoteStarMark(t)):u.TextMarkType.symbol===t.type?(this.writeInlineMarkStartEnd(),this.writeSymbolMark(t)):-1!==b.indexOf(t.type)&&(this.writeInlineMarkStartEnd(),this.writeInlineMark(t));if(t==k){let t=!1;for(const r of e.marks)-1!==h.indexOf(r.type)?i||(t=!0):u.TextMarkType.comment!==r.type&&u.TextMarkType.link!==r.type&&u.TextMarkType.ref!==r.type&&u.TextMarkType.xref!==r.type&&u.TextMarkType.footnote!==r.type&&u.TextMarkType.footnoteStar!==r.type&&-1===b.indexOf(r.type)||(t=!0);t&&this.writeInlineMarkStartEnd()}}}}writeParagraph(e){var t,r,i,o,n;if(this.textFormat===l.TextFormat.bitmarkPlusPlus){if(this.inBulletList)return;const a=null!==(r=null===(t=e.content)||void 0===t?void 0:t.length)&&void 0!==r?r:0;if(0===this.nodeIndex){if(1===a){const t=(null===(i=e.content)||void 0===i?void 0:i[0].type)===c.TextNodeType.text,r=null!==(n=null===(o=e.content)||void 0===o?void 0:o[0].text)&&void 0!==n?n:"";if(!t||""!==r)return}if(a>1)return}this.write("|"),this.writeNL(),this.exitedCodeBlock&&this.writeNL()}}writeHardBreak(e){if(this.writeNL(),this.currentIndent>1){const e=this.getIndentationString();this.write(e)}}writeHeading(e){var t,r;let i="";const o=null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.level)&&void 0!==r?r:1;for(let e=0;e<+o;e++)i+="#";i+=" ",this.write(i)}writeSection(e){let t="";t=e.section?`|${e.section}: `:"|",this.write(t)}writeBullet(e,t){var r,i,o,n;let a=this.getIndentationString();const s=this.getParentNode(t,2),l=null==s?void 0:s.value,p=null==l?void 0:l.type,u=null!==(i=null===(r=null==l?void 0:l.attrs)||void 0===r?void 0:r.start)&&void 0!==i?i:1;if(p===c.TextNodeType.bulletList)a+="• ";else if(p===c.TextNodeType.noBulletList)a+="•_ ";else if(p===c.TextNodeType.orderedList)a+=`•${u} `;else if(p===c.TextNodeType.orderedListRoman)a+=`•${u}I `;else if(p===c.TextNodeType.orderedListRomanLower)a+=`•${u}i `;else if(p===c.TextNodeType.letteredList)a+="•A ";else if(p===c.TextNodeType.letteredListLower)a+="•a ";else if(p===c.TextNodeType.taskList){a+=null!==(n=null===(o=e.attrs)||void 0===o?void 0:o.checked)&&void 0!==n&&n?"•+ ":"•- "}a&&this.write(a)}writeImage(e){var t;if(null==e.attrs||!e.attrs.src)return;const r=e.attrs,i=this.inParagraph,o=this.getMediaAttrs(i?"imageInline":"image",r,{ignoreAttributes:i?new Set(["alt","zoomDisabled","title"]):void 0});let n="";i&&(n=`==${null!==(t=r.alt)&&void 0!==t?t:""}==`),n+=o?`|${o}|`:"",this.write(n)}writeCodeBlock(e){if(null==e.attrs||!e.attrs.language)return;const t=`|code:${e.attrs.language}\n`;this.write(t)}writeLatex(e){if(null==e.attrs||!e.attrs.formula)return;const t=e.attrs,r=`==${this.breakscape(t.formula,{textFormat:this.textFormat,textLocation:this.textLocation})}==|latex|`;this.write(r)}writeMarkTextWrapper(e){e&&this.write(e)}writeInlineMark(e){let t=`${e.type}`;if(e.attrs)for(const[r,i]of Object.entries(e.attrs))("language"===r&&"plain text"!==i||"color"===r||"name"===r||"duration"===r)&&(t=`${t}:${i}`);this.write(t)}writeCommentMark(e){const t=`#${e.comment||""}`;this.write(t)}writeLinkMark(e){var t;const r=(null===(t=e.attrs)||void 0===t?void 0:t.href)||"",i=`link:${(null!=r?r:"").replace(C,"^]")}`;this.write(i)}writeRefMark(e){var t,r;const i=`►${null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.reference)&&void 0!==r?r:""}`;this.write(i)}writeXRefMark(e){var t,r,i,o;const n=null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.xref)&&void 0!==r?r:"",a=null!==(o=null===(i=e.attrs)||void 0===i?void 0:i.reference)&&void 0!==o?o:"";let s=`xref:${n}`;a&&(s+=`|►${a}`),this.write(s)}writeExtRefMark(e){var t,r,i,o,n,a;const s=null!==(r=null===(t=e.attrs)||void 0===t?void 0:t.extref)&&void 0!==r?r:"",l=null!==(o=null===(i=e.attrs)||void 0===i?void 0:i.references)&&void 0!==o?o:[],p=null!==(a=null===(n=e.attrs)||void 0===n?void 0:n.provider)&&void 0!==a?a:"";let u=`extref:${s}`;for(const e of l)u+=`|►${null!=e?e:""}`;u+=`|provider:${p}`,this.write(u)}writeFootnoteMark(e){this.write("footnote:")}writeFootnoteStarMark(e){this.write("footnote*:")}writeSymbolMark(e){if(null==e.attrs)return;const t=e.attrs,r=this.getMediaAttrs("symbol",t),i=null!=r?r:"";this.write(i)}writeInlineMarkStartEnd(){this.write("|")}writePlainTextDivider(){this.write("==== text ====")}writeString(e){null!=e&&this.write(`${e}`)}writeNL(){this.options.debugGenerationInline?this.write("\\n"):this.write("\n")}writeInlineDebug(e,t){let r=e;t.open?r=`<${e}>`:t.close?r=`</${e}>`:t.single&&(r=`<${e} />`),this.writeString(r)}getMediaAttrs(e,t,r){var i,o;if(!e)return;const n=null!==(i=Object.assign({},r).ignoreAttributes)&&void 0!==i?i:new Set;let a=`${e}:${null!==(o=null==t?void 0:t.src)&&void 0!==o?o:""}`;const s=Object.entries(t).filter((([e,t])=>"src"!==e));for(let e=0;e<s.length;e++){const[t,r]=s[e];if(!n.has(t))switch(t){case"textAlign":"left"!==r&&(a+=`|captionAlign:${r}`);break;case"alignment":"center"!==r&&r&&(a+=`|alignment:${r}`);break;case"title":r&&(a+=`|caption:${r}`);break;case"class":"center"!==r&&r&&(a+=`|align:${r}`);break;case"comment":r&&(a+=`|#${r}`);break;case"":y.StringUtils.isString(r)?a+=`|:${r}`:a+="|";break;default:t&&r&&(a+=`|${t}:${r}`)}}return a}breakscape(e,t){return this.generateOptions.noBreakscaping?e:n.Breakscape.breakscape(e,t)}getBitType(e){for(const t of e)if(t.key===a.NodeType.bitsValue){const e=t.value;return null==e?void 0:e.bitType}}write(e){return e=this.getInterTextBreakscape(e)+e,this.options.writeCallback&&this.options.writeCallback(e),this.writerText+=e,this}writeLine(e){return this.write(`${e}\n`),this}writeLines(e,t){for(const r of e)this.write(`${r}${null!=t?t:""}\n`);return this}writeWhiteSpace(){return this.write(" "),this}}t.TextGenerator=K},486:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.InfoType=void 0;const i=(0,r(4718).superenum)({list:"list",deprecated:"deprecated",all:"all",bit:"bit"});t.InfoType=i},554:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.clozeTagContentProcessor=function(e,t,r,l,p){const{textFormat:u}=e,{value:c}=l,y=p.solutions,g=p.__solutionsAst;if(!y||!g)return;if(a.StringUtils.isString(c)){const e=a.StringUtils.trimmedString(c);y.push(i.Breakscape.unbreakscape(e,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}));const t=s.toAst(e,{textFormat:u,isProperty:!0});g.push(t)}};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=new(r(777).TextParser)},777:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextParser=void 0;const i=r(385),o=r(9554),n=r(9681),a=r(2220);t.TextParser=class{version(){return(0,a.parse)("",{startRule:"version"})}preprocessAst(e){if(n.StringUtils.isString(e)){const t=e;try{e=JSON.parse(t)}catch(e){return}}if(this.isAst(e))return e}isAst(e){if(Array.isArray(e)){if(0===e.length)return!0;if(Object.prototype.hasOwnProperty.call(e[0],"type"))return!0}return!1}toAst(e,t){var r;if(Array.isArray(e))return e;let o=null!==(r=e)&&void 0!==r?r:"";if(!o)return[];const n=Object.assign({},t);let s=n.textFormat===i.TextFormat.bitmarkPlusPlus?"bitmarkPlusPlus":"bitmarkMinusMinus";return n.isProperty&&n.textFormat===i.TextFormat.bitmarkPlusPlus&&(s="bitmarkPlus"),o=o.trim(),(0,a.parse)(o,{startRule:s})}extractBodyBits(e){if(!Array.isArray(e))return[];const t=[],r=e;for(const e of r)switch(e.type){case o.TextNodeType.gap:case o.TextNodeType.select:case o.TextNodeType.highlight:case o.TextNodeType.mark:t.push(e);break;default:{const r=this.extractBodyBits(e.content);for(const e of r)t.push(e)}}return t}walkBodyBits(e,t){if(!Array.isArray(e))return;const r=e;for(let e=0;e<r.length;e++){const i=r[e];switch(i.type){case o.TextNodeType.gap:case o.TextNodeType.select:case o.TextNodeType.highlight:case o.TextNodeType.mark:t(r,e,i);break;default:this.walkBodyBits(i.content,t)}}}}},955:function(e,t,r){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ObjectUtils=void 0;const o=i(r(7678));const n=new class{isFunction(e){return"[object Function]"===Object.prototype.toString.call(e)}isArray(e){return Array.isArray(e)}isDate(e){return"[object Date]"===Object.prototype.toString.call(e)}isObject(e){return"[object Object]"===Object.prototype.toString.call(e)}isValue(e){return!this.isObject(e)&&!this.isArray(e)}getViaPath(e,t){if(!e)return;if(!t)return;Array.isArray(t)||(t=[t]),t=t.flatMap((e=>e.split(".")));let r=e;for(const e of t){if(null==r)return;r=r[e]}return r}setViaPath(e,t,r,i){if(!e)return!1;if(!t)return!1;Array.isArray(t)||(t=[t]),t=t.flatMap((e=>e.split(".")));let o=e;for(let e=0;e<t.length-1;e++){const r=t[e];if(null==o[r]){if(!i)return!1;o[r]={}}o=o[r]}return o[t[t.length-1]]=r,!0}flatMapPath(e,t){if(!e)return[];if(!t)return[];Array.isArray(t)||(t=[t]);const r=e,i=t.shift();if(null==i)return r;const o=r[i];return o?Array.isArray(o)?o.flatMap((e=>this.flatMapPath(e,t.slice()))):[this.flatMapPath(o,t)].flat():[]}orderProperties(e,t){const r=e,i=Object.assign({},r);for(const e of Object.keys(r))delete r[e];for(const e of t)Object.prototype.hasOwnProperty.call(i,e)&&(r[e]=i[e])}removeUndefinedProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||null==i&&delete r[e]}removeFalseProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||!1===i&&delete r[e]}removeEmptyStringProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||""===i&&delete r[e]}removeEmptyArrayProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||Array.isArray(i)&&0===i.length&&delete r[e]}removeEmptyObjectProperties(e,t){const r=e;for(const[e,i]of Object.entries(r))t&&t.indexOf(e)>=0||this.isObject(i)&&0===Object.keys(i).length&&delete r[e]}removeUnwantedProperties(e,t){(t=Object.assign({},t)).ignoreAllUndefined||this.removeUndefinedProperties(e,t.ignoreUndefined),t.ignoreAllFalse||this.removeFalseProperties(e,t.ignoreFalse),t.ignoreAllEmptyString||this.removeEmptyStringProperties(e,t.ignoreEmptyString),t.ignoreAllEmptyArrays||this.removeEmptyArrayProperties(e,t.ignoreEmptyArrays),t.ignoreAllEmptyObjects||this.removeEmptyObjectProperties(e,t.ignoreEmptyObjects)}extractSingleValue(e,t){if(!e)return;const r=e;if(null==r[t])return;let i=r[t];if(Array.isArray(i)){if(0===i.length)return;i=i[i.length-1]}return i}deepMerge(...e){return function e(...t){function r(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function i(t,i){for(const[n,a]of Object.entries(i)){const i=r(a);void 0!==t[n]&&r(t[n])===i&&["array","object"].includes(i)?t[n]=e(t[n],a):t[n]=(0,o.default)(a)}}let n=(0,o.default)(t.shift());for(const e of t){const t=r(e);r(n)===t?"array"===t?n=[...n,...(0,o.default)(e)]:"object"===t?i(n,e):n=e:n=(0,o.default)(e)}return n}(...e)}};t.ObjectUtils=n},1083:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.buildCards=function(e,t,r,d,f,m,T,h){var b;const{bitConfig:B}=e;e.DEBUG_CARD_SET&&e.debugPrint("card set",d);let v={};const C=function(e,t){var r;const i={cards:[],internalComments:[]};if(!t)return i;const{bitType:o}=e;let a=0,s=0,l=0;for(const p of t.cards){const t={no:a++,sides:[]};i.cards.push(t);for(const a of p.sides){const p={no:s++,variants:[]};t.sides.push(p);for(const u of a.variants){const{parser:a,content:g}=u,d={parser:a,no:l++};p.variants.push(d);const f=n.Config.getTagsConfigForCardSet(o,s,l),m=e.bitContentProcessor(y.BitContentLevel.Card,f,g);e.DEBUG_CARD_TAGS&&e.debugPrint("card tags",m),m.cardBody=c.BitmarkPegParserValidator.checkCardBody(e,y.BitContentLevel.Card,o,m.cardBody,t.no,p.no,d.no),m.cardBodyStr=null===(r=m.cardBody)||void 0===r?void 0:r.bodyString,d.data=m,m.internalComments&&i.internalComments.push(...m.internalComments)}l=0}s=0}return i}(e,d);switch(null===(b=B.cardSet)||void 0===b?void 0:b.configKey){case a.CardSetConfigKey._flashcard:case a.CardSetConfigKey._definitionList:v=function(e,t,r){var o;const a=[],l=[];let p,u,c,y="",d=[],f=0,m={};const T=t===s.BitType.flashcard1,h=g(r);for(let g=0;g<r.cards.length;g++){const b=r.cards[g];if(!h||0!==g){p=void 0,u=void 0,d=[],f=0,m={};for(const e of b.sides)for(const t of e.variants){const e=t.data,{cardBody:r,resources:n}=e,a=i(e,["cardBody","resources"]);m=Object.assign(Object.assign({},m),a);const s=n&&n.length>0?n[0]:void 0,l=null==r?void 0:r.body,g=null!==(o=null==r?void 0:r.bodyString)&&void 0!==o?o:"";0===f?(c=t,y=g,p={text:l,icon:s}):1===f?u={text:l,icon:s}:d.push({text:l,icon:s}),f++}if(0!==g&&T){e.addWarning(`Bit '${t}' should only contain one card. Ignore subsequent card: '${y}'`,c);break}if(n.Config.isOfBitType(t,[s.BitType.flashcard])){const e=Object.assign({question:p,answer:u,alternativeAnswers:d},m);e&&a.push(e)}else{const e=Object.assign({term:p,definition:u,alternativeDefinitions:d},m);e&&l.push(e)}}}return{heading:null==h?void 0:h.heading,flashcards:a.length>0?a:void 0,definitions:l.length>0?l:void 0}}(e,t,C);break;case a.CardSetConfigKey._elements:v=function(e,t,r){var i;const o=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data;o.push(null!==(i=t.cardBodyStr)&&void 0!==i?i:"")}return{elements:o.length>0?o:void 0}}(0,0,C);break;case a.CardSetConfigKey._statements:v=function(e,t,r,o,n){var a;const s=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{statements:r,statement:o}=t,n=i(t,["statements","statement"]);if(Array.isArray(r))for(const e of r){const t=Object.assign({statement:null!==(a=e.statement)&&void 0!==a?a:"",isCorrect:e.isCorrect,item:e.item,lead:e.lead,hint:e.hint,instruction:e.instruction,example:e.example},n);t&&s.push(t)}}o&&s.push(o);Array.isArray(n)&&n.length>0&&s.push(...n);return{statements:s.length>0?s:void 0}}(0,0,C,f,m);break;case a.CardSetConfigKey._feedback:v=function(e,t,r){let o;const n=[],a=g(r);for(let e=0;e<r.cards.length;e++){const t=r.cards[e];if(!a||0!==e){o=void 0;for(let e=0;e<t.sides.length;e++){const r=t.sides[e];for(const t of r.variants){const r=t.data,{cardBody:a,cardBodyStr:s,choices:l}=r,p=i(r,["cardBody","cardBodyStr","choices"]);if(0===e){const e=[];if(l&&l.length>0)for(const t of l){const{__isDefaultExample:r,example:o}=t,n=i(t,["__isDefaultExample","example"]),a={choice:n.choice,requireReason:n.isCorrect,__isDefaultExample:r,example:o};e.push(a)}o=Object.assign(Object.assign({},r),{choices:e}),o&&n.push(o)}else if(1===e){const e=Object.assign({text:null!=s?s:"",__textAst:null==a?void 0:a.body},p);o&&(o.reason=e)}}}}}return{heading:null==a?void 0:a.heading,feedbacks:n.length>0?n:void 0}}(0,0,C);break;case a.CardSetConfigKey._quiz:v=function(e,t,r,o,a){const l=[],p=n.Config.isOfBitType(t,s.BitType.multipleChoice),u=n.Config.isOfBitType(t,s.BitType.multipleResponse);if(!p&&!u)return{};let c,y=!1;for(const e of r.cards){y=!1,c=void 0;for(const t of e.sides)for(const e of t.variants){const t=e.data,{__isDefaultExample:r,example:o}=t,n=i(t,["__isDefaultExample","example"]);if(y=!0===r||y,c=o||c,n.trueFalse&&n.trueFalse.length>0){const e=[];for(const t of n.trueFalse){const{__isDefaultExample:r,example:o}=t,n=i(t,["__isDefaultExample","example"]),a=r||y,s=o||c,l={isCorrect:n.isCorrect,__isDefaultExample:a,example:s};u?l.response=n.text:l.choice=n.text,l&&e.push(l)}u?n.responses=e:n.choices=e}const a=Object.assign(Object.assign({},n),{choices:n.choices,responses:n.responses,__isDefaultExample:y,__defaultExample:c});a&&l.push(a)}}if(p&&Array.isArray(o)&&o.length>0){const e={choices:o};e&&l.push(e)}if(u&&Array.isArray(a)&&a.length>0){const e={responses:a};e&&l.push(e)}return{quizzes:l.length>0?l:void 0}}(0,t,C,T,h);break;case a.CardSetConfigKey._questions:v=function(e,t,r){var i;const o=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,r=Object.assign({question:null!==(i=t.cardBodyStr)&&void 0!==i?i:""},t);r&&o.push(r)}return{questions:o.length>0?o:void 0}}(0,0,C);break;case a.CardSetConfigKey._matchPairs:v=function(e,t,r){var o;const a=[];let l,u,c,y,d=[],f=[],m={},T=!1;const h=n.Config.isOfBitType(t,s.BitType.matchMatrix),b=g(r,h),B=null!==(o=null==b?void 0:b.isDefaultExampleCardSet)&&void 0!==o&&o;let v=null==b?void 0:b.exampleCardSet;for(let e=0;e<r.cards.length;e++){const t=r.cards[e];if(b&&0===e)continue;l=void 0,d=[],f=[],u=void 0,c=void 0,m={},T=!1,y=void 0;for(let e=0;e<t.sides.length;e++){const r=t.sides[e];for(const t of r.variants){const r=t.data,{cardBody:o,cardBodyStr:n,resources:a,__isDefaultExample:s,example:g}=r,h=i(r,["cardBody","cardBodyStr","resources","__isDefaultExample","example"]);if(T=!0===s||T,y=g||y,0===e)if(Array.isArray(a)&&a.length>0){const e=a[0];e.type===p.ResourceTag.audio?u=e:e.type===p.ResourceTag.image&&(c=e)}else l=n;else{const e=null!=n?n:"",t=null==o?void 0:o.body;d.push(e),f.push(t),!B&&!T||y||(y=t),delete h.item,delete h.lead}m=Object.assign(Object.assign({},m),h)}}T&&(v=void 0);const o=T||B,n=y||v,s=Object.assign(Object.assign({key:null!=l?l:"",keyAudio:u,keyImage:c,values:d,__valuesAst:f},m),{__isDefaultExample:o,example:n});s&&a.push(s)}return{heading:null==b?void 0:b.heading,pairs:a.length>0?a:void 0}}(0,t,C);break;case a.CardSetConfigKey._matchMatrix:v=function(e,t,r){var n;let a,s;const l=[];let p,u,c,y,d=[],f=[],m=[],T={},h=!1,b=!1;const B=g(r,!0),v=null!==(n=null==B?void 0:B.isDefaultExampleCardSet)&&void 0!==n&&n;let C=null==B?void 0:B.exampleCardSet;for(let e=0;e<r.cards.length;e++){const t=r.cards[e];if(B&&0===e)continue;a=void 0,s=void 0,d=[],f=[],m=[],h=!1,p=void 0,c=void 0;for(let e=0;e<t.sides.length;e++){const r=t.sides[e];f=[],m=[],T={},b=!1,u=void 0,y=void 0;for(const t of r.variants){const r=t.data,{cardBody:n,cardBodyStr:l,__isDefaultExample:g,example:d,isCaseSensitive:B}=r,C=i(r,["cardBody","cardBodyStr","__isDefaultExample","example","isCaseSensitive"]);if(b=!0===g||b,u=d||u,Object.assign(T,C),0===e)a=l,s=C,h=!0===g||h,p=d||p,c=null!=B?B:c;else{const e=null!=l?l:o.Breakscape.EMPTY_STRING,t=null==n?void 0:n.body;f.push(e),m.push(t),!v&&!b||u||(u=t),y=null!=B?B:c}}if(e>0){b&&(p=C=void 0),h&&(C=void 0);const e=b||h||v,t=u||p||C,r=Object.assign(Object.assign({values:f,__valuesAst:m},T),{__isDefaultExample:e,example:t,isCaseSensitive:y});r&&d.push(r)}}const n=Object.assign({key:null!=a?a:o.Breakscape.EMPTY_STRING,cells:d},s);n&&l.push(n)}return{heading:null==B?void 0:B.heading,matrix:l.length>0?l:void 0}}(0,0,C);break;case a.CardSetConfigKey._pronunciationTable:v=function(e,t,r){var i;const o=[];let n=[];for(const e of r.cards){n=[];for(const t of e.sides)for(const e of t.variants){const t=e.data,{title:r,cardBody:o,resources:a}=t,s=r&&r[1].titleAst,l=a&&a.length>0?a.find((e=>e.type===p.ResourceTag.audio)):void 0,u={title:null!=s?s:[],body:null!==(i=null==o?void 0:o.body)&&void 0!==i?i:[],audio:l};n.push(u)}o.push(n)}return{pronunciationTable:{data:o}}}(0,0,C);break;case a.CardSetConfigKey._table:v=function(e,t,r){var i;let o=!1;const n=[],a=[];let s=[];for(let e=0;e<r.cards.length;e++){const t=r.cards[e];o=!1,s=[];for(const r of t.sides)for(const t of r.variants){const r=t.data,{title:a,cardBody:l}=r,p=a&&a[1].titleAst;if(0===e&&null!=p&&(o=!0),o)n.push(null!=p?p:[]);else{const e=null!==(i=null==l?void 0:l.body)&&void 0!==i?i:[];s.push(e)}}o||a.push(s)}return{table:{columns:n,data:a}}}(0,0,C);break;case a.CardSetConfigKey._botActionResponses:v=function(e,t,r){const n=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{__instructionString:r,reaction:a,cardBodyStr:s}=t,l=i(t,["__instructionString","reaction","cardBodyStr"]),p=Object.assign({response:null!=r?r:o.Breakscape.EMPTY_STRING,reaction:null!=a?a:o.Breakscape.EMPTY_STRING,feedback:null!=s?s:o.Breakscape.EMPTY_STRING},l);p&&n.push(p)}return{botResponses:n.length>0?n:void 0}}(0,0,C);break;case a.CardSetConfigKey._ingredients:v=function(e,t,r){const n=[];for(const e of r.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{title:r,__instructionString:a,unit:s,unitAbbr:p,decimalPlaces:c,disableCalculation:y,cardBodyStr:g,cardBody:d}=t,f=i(t,["title","__instructionString","unit","unitAbbr","decimalPlaces","disableCalculation","cardBodyStr","cardBody"]),m=Array.isArray(r)&&r.length>0?r[r.length-1].titleString:void 0;let T=!1,h=u.NumberUtils.asNumber(a);if(d&&d.bodyBits){const e=d.bodyBits.find((e=>e.type===l.BodyBitType.select));e&&(h=e.__instructionString?u.NumberUtils.asNumber(e.__instructionString):h,e.options&&e.options.length>0&&(T=e.options[0].isCorrect))}const b=Object.assign({title:m,checked:T,item:g,quantity:h,unit:null!=s?s:o.Breakscape.EMPTY_STRING,unitAbbr:null!=p?p:o.Breakscape.EMPTY_STRING,decimalPlaces:null!=c?c:1,disableCalculation:y},f);b&&n.push(b)}return{ingredients:n.length>0?n:void 0}}(0,0,C);break;case a.CardSetConfigKey._clozeList:case a.CardSetConfigKey._exampleBitList:case a.CardSetConfigKey._bookReferenceList:v=function(e,t,r,o){const n=[];for(const e of o.cards)for(const t of e.sides)for(const e of t.variants){const t=e.data,{cardBody:r}=t,o=i(t,["cardBody"]),a=Object.assign({body:r},o);a&&n.push(a)}return{cardBits:n.length>0?n:void 0}}(0,0,0,C)}return v.internalComments=C.internalComments.length>0?C.internalComments:void 0,v};const o=r(7735),n=r(2028),a=r(8199),s=r(5854),l=r(4410),p=r(6149),u=r(8025),c=r(4266),y=r(3029);function g(e,t=!1){let r,i,o=!1;const n=[];let a,s=!1;if(0===e.cards.length)return;const l=e.cards[0];for(let e=0;e<l.sides.length;e++){const t=l.sides[e];if(0===t.variants.length)continue;const r=t.variants[0].data,{title:p,__isDefaultExample:u,example:c}=r,y=p&&p[1].titleString;null!=y&&(o=!0),0===e?o&&(i=y,s=!0===u||s,a=c||a):o&&(n.push(null!=y?y:""),s=!0===u||s,a=c||a)}if(o){let e=n;e=t?n:n.length>=1?n[n.length-1]:"",r={forKeys:null!=i?i:"",forValues:e}}return r?{heading:r,isDefaultExampleCardSet:s,exampleCardSet:a}:void 0}},1163:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardSetVersion=void 0;const i=(0,r(4718).superenum)({v1:1,v2:2});t.CardSetVersion=i},1412:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.init=function(){if(n)return;(0,o.initEnv)(i.buildInfo.name,i.buildInfo.version),n=!0};const i=r(1464),o=r(6936);r(2028);let n=!1},1457:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourcesConfig=void 0;t.ResourcesConfig=class{constructor(e,t,r,i){this.tags=e,this.resourceAttachmentAllowed=null!=t&&t,this.resourceTypeAttachment=r,this.comboResourceTagTypesMap=i}getCountsMin(){const e=new Map;for(const t of Object.values(this.tags))null!=t.minCount&&e.set(t.tag,t.minCount);return e}getCountsMax(){const e=new Map;for(const t of Object.values(this.tags))null!=t.maxCount&&e.set(t.tag,t.maxCount);return e}}},1464:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.buildInfo=void 0,t.buildInfo={name:"@gmb/bitmark-parser-generator",version:"3.26.0",author:"Get More Brain Ltd",license:"ISC",description:"A bitmark parser and generator using Peggy.js"}},1519:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyTagConfig=void 0;const i=r(5512),o=r(6634);class n extends o.AbstractTagConfig{constructor(e,t,r,o,n,a,s,l,p,u,c){super(i.BitTagType.property,e,t,r,o,n,a,s,c),this.type=i.BitTagType.property,this.single=l,this.format=p,this.defaultValue=u}toString(e){const t=Object.assign({},e);let r=`PTY[${this.tag}`;if(t.includeConfigs&&(null!=this.deprecated&&(r+=`, deprecated=${this.deprecated}`),null!=this.maxCount&&(r+=`, max=${this.maxCount}`),null!=this.minCount&&(r+=`, min=${this.minCount}`),null!=this.single&&(r+=`, sgl=${this.single}`),null!=this.format&&(r+=`, fmt=${this.format}`),null!=this.defaultValue&&(r+=`, def=${this.defaultValue}`),null!=this.jsonKey&&(r+=`, json=${this.jsonKey}`),null!=this.astKey&&(r+=`, ast=${this.astKey}`)),r+="]",this.chain&&t.includeChains){r+="\n|__";let e=!0;for(const i of Object.values(this.chain))e||(r+=" "),r+=`${i.toString(t)}`,e=!1}return r}}t.PropertyTagConfig=n},1731:(e,t)=>{t.VOID=-1;t.PRIMITIVE=0;t.ARRAY=1;t.OBJECT=2;t.DATE=3;t.REGEXP=4;t.MAP=5;t.SET=6;t.ERROR=7;t.BIGINT=8},1791:function(e,t,r){var i,o=this&&this.__createBinding||(Object.create?function(e,t,r,i){void 0===i&&(i=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,i,o)}:function(e,t,r,i){void 0===i&&(i=r),e[i]=t[r]}),n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),a=(this&&this.__importStar||(i=function(e){return i=Object.getOwnPropertyNames||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[t.length]=r);return t},i(e)}),this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))});this&&this.__importDefault;Object.defineProperty(t,"__esModule",{value:!0}),t.Output=t.Input=t.BitmarkParserGenerator=void 0;const s=r(4718),l=r(5126),p=r(3968),u=r(7984),c=r(8588),y=r(5633),g=r(5663),d=r(6936),f=r(3881),m=r(486),T=r(3069),h=r(2028),b=r(385),B=r(431),v=r(777),C=(0,s.superenum)({string:"string",file:"file"});t.Input=C;const P=(0,s.superenum)({bitmark:"bitmark",json:"json",ast:"ast"});t.Output=P;t.BitmarkParserGenerator=class{constructor(){this.ast=new l.Ast,this.jsonParser=new g.JsonParser,this.bitmarkParser=new y.BitmarkParser,this.textParser=new v.TextParser,this.textGenerator=new B.TextGenerator,this.jsonStringifyPrettify=(e,t,r)=>{const i=!0===t.prettify?2:t.prettify||void 0;return r||!0===t.stringify||void 0!==i?JSON.stringify(e,null,i):e}}version(){return d.env.appVersion.full}info(e){const t=Object.assign({},e),r=new f.InfoBuilder;let i;const o=!t.outputFormat||t.outputFormat===T.InfoFormat.text,n=t.outputFormat===T.InfoFormat.json,a=t.type===m.InfoType.all,s=t.type===m.InfoType.deprecated,l=a||!s,p=a||s;if(t.type===m.InfoType.bit){const e=r.getSupportedBitConfigs().filter((e=>{if(!t.bit)return!0;return h.Config.getBitType(t.bit)===e.bitType}));i=o?e.map((e=>e.toString({includeChains:!0,includeConfigs:!0}))).join("\n\n--------------\n\n"):e}else{const e=r.getSupportedBits({includeNonDeprecated:l,includeDeprecated:p}).filter((e=>{if(!t.bit)return!0;const r=h.Config.getBitType(t.bit);return e.name===r||void 0}));i=o?this.supportedBitsAsString(e):e}if(n){const e=!0===t.prettify?2:t.prettify||void 0;i=JSON.stringify(i,null,e)}return i}convert(e,t){return a(this,void 0,void 0,(function*(){let r;const i=Object.assign({},t),o=Object.assign({},i.jsonOptions),n=i.outputFormat,s=n===P.bitmark,l=n===P.json,y=n===P.ast,g=c.BitmarkParserType.peggy;let f=e;if(d.env.isBrowser&&i.outputFile)throw new Error("Cannot write to file in browser environment");i.inputFormat&&i.inputFormat!==C.file||d.env.isNode&&fs.existsSync(f)&&(f=fs.readFileSync(f,{encoding:"utf8"}));let m=this.ast.preprocessAst(f);const T=!!m;T||(m=this.jsonParser.toAst(f));const h=!!(null==m?void 0:m.bits),b=e=>a(this,void 0,void 0,(function*(){yield B(e),yield x(r)})),B=e=>a(this,void 0,void 0,(function*(){r=this.bitmarkParser.toAst(e,{parserType:g})})),v=e=>a(this,void 0,void 0,(function*(){if(g===c.BitmarkParserType.peggy)if(m=this.bitmarkParser.toAst(e,{parserType:g}),i.outputFile){const e=new JsonFileGenerator_1.JsonFileGenerator(i.outputFile,i);yield e.generate(m)}else{const e=new u.JsonObjectGenerator(i),t=yield e.generate(m);r=this.jsonStringifyPrettify(t,o)}})),x=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new BitmarkFileGenerator_1.BitmarkFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new p.BitmarkStringGenerator(i);r=yield t.generate(e)}})),k=e=>a(this,void 0,void 0,(function*(){r=this.jsonStringifyPrettify(e,o)})),K=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new JsonFileGenerator_1.JsonFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new u.JsonObjectGenerator(i),n=yield t.generate(e);r=this.jsonStringifyPrettify(n,o)}})),w=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new BitmarkFileGenerator_1.BitmarkFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new p.BitmarkStringGenerator(i);r=yield t.generate(e)}})),_=e=>a(this,void 0,void 0,(function*(){r=this.jsonStringifyPrettify(e,o)})),S=e=>a(this,void 0,void 0,(function*(){yield K(e)}));return!h&&!T?s?yield b(f):y?yield B(f):yield v(f):T?y?yield k(m):l?yield K(m):yield x(m):l?yield S(m):y?yield _(m):yield w(m),r}))}upgrade(e,t){return a(this,void 0,void 0,(function*(){let r;const i=Object.assign({},t),o=Object.assign({},i.jsonOptions),n=i.bitmarkParserType;let s=e;if(d.env.isBrowser&&i.outputFile)throw new Error("Cannot write to file in browser environment");i.inputFormat&&i.inputFormat!==C.file||d.env.isNode&&fs.existsSync(s)&&(s=fs.readFileSync(s,{encoding:"utf8"}));let l=this.jsonParser.toAst(s);const c=e=>a(this,void 0,void 0,(function*(){const t=this.bitmarkParser.toAst(e,{parserType:n});if(i.outputFile){const e=new BitmarkFileGenerator_1.BitmarkFileGenerator(i.outputFile,i);yield e.generate(t)}else{const e=new p.BitmarkStringGenerator(i);r=yield e.generate(t)}})),y=e=>a(this,void 0,void 0,(function*(){if(i.outputFile){const t=new JsonFileGenerator_1.JsonFileGenerator(i.outputFile,i);yield t.generate(e)}else{const t=new u.JsonObjectGenerator(i),n=yield t.generate(e);r=this.jsonStringifyPrettify(n,o)}}));return!!!(null==l?void 0:l.bits)?yield c(s):yield y(l),r}))}createAst(e,t){let r,i=e;const o=Object.assign({},t);o.inputFormat&&o.inputFormat!==C.file||d.env.isNode&&fs.existsSync(i)&&(i=fs.readFileSync(i,{encoding:"utf8"}));let n=this.ast.preprocessAst(i);const a=!!n;a||(n=this.jsonParser.toAst(i));return r=!!!(null==n?void 0:n.bits)&&!a?this.bitmarkParser.toAst(i):n,r}convertText(e,t){return a(this,void 0,void 0,(function*(){var r,i;let o,n;const a=Object.assign({},t),s=Object.assign({},a.fileOptions),l=Object.assign({},a.jsonOptions),p=null!==(r=a.textFormat)&&void 0!==r?r:b.TextFormat.bitmarkMinusMinus,u=null!==(i=a.textLocation)&&void 0!==i?i:TextLocation_1.TextLocation.body;let c=e;if(d.env.isBrowser&&a.outputFile)throw new Error("Cannot write to file in browser environment");a.inputFormat&&a.inputFormat!==C.file||d.env.isNode&&fs.existsSync(c)&&(c=fs.readFileSync(c,{encoding:"utf8"}));const y=this.textParser.preprocessAst(c),g=!!y;if(n=g?yield this.textGenerator.generate(y,p,u):this.textParser.toAst(c,{textFormat:p,isProperty:!1}),a.outputFile){const e=a.outputFile.toString();let t=n;g||(t=this.jsonStringifyPrettify(n,l,!0));const r=s.append?"a":"w";fs.ensureDirSync(path_1.default.dirname(e)),fs.writeFileSync(e,t,{flag:r})}else o=g?n:this.jsonStringifyPrettify(n,l);return o}))}breakscapeText(e,t){if(!e)return e;const r=Object.assign({},t),i=Object.assign({},r.fileOptions);r.textFormat||(r.textFormat=b.TextFormat.bitmarkMinusMinus),r.textLocation||(r.textLocation=TextLocation_1.TextLocation.body);let o=e;if(d.env.isBrowser&&r.outputFile)throw new Error("Cannot write to file in browser environment");r.inputFormat&&r.inputFormat!==C.file||d.env.isNode&&fs.existsSync(o)&&(o=fs.readFileSync(o,{encoding:"utf8"}));const n=Breakscape_1.Breakscape.breakscape(o,{textFormat:r.textFormat,textLocation:r.textLocation});if(!r.outputFile)return n;{const e=r.outputFile.toString(),t=i.append?"a":"w";fs.ensureDirSync(path_1.default.dirname(e)),fs.writeFileSync(e,n,{flag:t})}}unbreakscapeText(e,t){if(!e)return e;const r=Object.assign({},t),i=Object.assign({},r.fileOptions);r.textFormat||(r.textFormat=b.TextFormat.bitmarkMinusMinus),r.textLocation||(r.textLocation=TextLocation_1.TextLocation.body);let o=e;if(d.env.isBrowser&&r.outputFile)throw new Error("Cannot write to file in browser environment");r.inputFormat&&r.inputFormat!==C.file||d.env.isNode&&fs.existsSync(o)&&(o=fs.readFileSync(o,{encoding:"utf8"}));const n=Breakscape_1.Breakscape.unbreakscape(o,{textFormat:r.textFormat,textLocation:r.textLocation});if(!r.outputFile)return n;{const e=r.outputFile.toString(),t=i.append?"a":"w";fs.ensureDirSync(path_1.default.dirname(e)),fs.writeFileSync(e,n,{flag:t})}}supportedBitsAsString(e){let t="";for(const r of e)t+=`${r.name} (since: ${r.since}`,r.deprecated&&(t+=`, deprecated: ${r.deprecated}`),t+=")\n";return t}}},2028:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Config=void 0;const i=r(3619),o=r(9600),n=r(1457),a=r(6915),s=r(5512),l=r(5854),p=r(385),u=r(955),c=r(4445),y=r(6853),g=r(5837),d=r(9916);const f=new class{constructor(){this.bitLevelMin=1,this.bitLevelMax=7,this.bitCache=new Map,this.comboResourcesCache=new Map}getBitType(e){var t;return(null==e?void 0:e.startsWith("|"))&&(e=e.substring(1)),null!==(t=l.BitType.fromValue(e))&&void 0!==t?t:l.BitType._error}isOfBitType(e,t){if(!e)return!1;if(e===t)return!0;const r=this.getBitConfig(e);if(!r)return!1;if(Array.isArray(t)){for(const e of t)if(r.inheritedBitTypesSet.has(e))return!0;return!1}return r.inheritedBitTypesSet.has(t)}isBitTypeCommented(e){return!!(null==e?void 0:e.startsWith("|"))}getBitConfig(e){var t;let r=this.bitCache.get(e);if(!r){const o=()=>{throw new Error(`No config found for bit: ${e}`)},n=[],a=[];let s=e;for(;s;){const e=y.BITS[s];e||o(),n.push(s),a.push(e),s=e.baseBitType}a.reverse();const l=a.reduce(((e,t)=>e=u.ObjectUtils.deepMerge(e,t)),{}),{since:g,textFormatDefault:d,quizBit:f,tags:m,cardSet:T,deprecated:h,bodyAllowed:b,bodyRequired:B,footerAllowed:v,footerRequired:C,resourceAttachmentAllowed:P,rootExampleType:x}=l,k=this.getAllResourcesTagsWithZeroCounts(),K=c.ConfigHydrator.hydrateTagsConfig(null!=m?m:[]),w=c.ConfigHydrator.hydrateCardSetConfig(T),_=null===(t=K.info)||void 0===t?void 0:t.comboResourceType,S=Object.assign({},K.tags);for(const[e,t]of Object.entries(k))S[e]||(S[e]=t);r=new i.BitConfig({since:g,bitType:e,inheritedBitTypes:n,textFormatDefault:null!=d?d:p.TextFormat.bitmarkPlusPlus,tags:S,cardSet:w,quizBit:f,deprecated:h,bodyAllowed:b,bodyRequired:B,footerAllowed:v,footerRequired:C,resourceAttachmentAllowed:P,rootExampleType:x,comboResourceType:_}),this.bitCache.set(e,r)}return r}getRawPropertiesConfig(){return d.PROPERTIES}getTagConfigForTag(e,t){if(e)for(const[,r]of Object.entries(e))if(r.tag===t)return r}getTagsConfigForCardSet(e,t,r){const i=this.getBitConfig(e);if(!i)return;const o=i.cardSet;if(!o)return;t=Math.min(t,o.variants.length-1);const n=o.variants[t];return n[r=Math.min(r,n.length-1)].tags}getBitResourcesConfig(e,t){var r;let i={};const a=new Map,l=this.getBitConfig(e),p={};for(const[e,t]of Object.entries(l.tags))t.type===s.BitTagType.resource&&(p[e]=t);const u=null!==(r=l.comboResourceType)&&void 0!==r?r:l.resourceAttachmentAllowed&&t;if(u){const e=new Map,r=this.getComboResource(u);if(r){const t=Object.values(r).filter((e=>e.type===s.BitTagType.resource));t.map((e=>e.tag)).forEach((r=>{const i=t.find((e=>e.tag===r));i&&e.set(r,i)}));const i=this.getComboResourceTagTypes(u);i&&i.length>0&&a.set(u,i)}if(t)for(const[t,r]of Object.entries(p)){const n=u===r.tag,a=!!e&&e.has(r.tag);if(n){const e=new o.ResourceTagConfig(r.configKey,r.tag,1,1,r.chain,r.jsonKey,r.deprecated);i[t]=e}else if(a){if(e){const o=e.get(r.tag);o&&(i[t]=o)}}else i[t]=r}else i=p}else i=p;return new n.ResourcesConfig(i,l.resourceAttachmentAllowed,t,a)}getComboResourceTagTypes(e){const t=this.getComboResource(e);if(t){return Object.values(t).filter((e=>e.type===s.BitTagType.resource)).map((e=>e.tag))}}getComboResource(e){if(!e)return;let t=this.comboResourcesCache.get(e);return t||(t={},Object.values(g.GROUPS).filter((t=>t.type===a.GroupConfigType.comboResource&&t.comboResourceType===e)).forEach((e=>{t=Object.assign(Object.assign({},t),c.ConfigHydrator.hydrateTagsConfig(e.tags).tags)})),0===Object.keys(t).length&&(t=void 0),this.comboResourcesCache.set(e,t)),t}getAllResourcesTagsWithZeroCounts(){let e=this.allResourcesCache;if(!e){e={},Object.values(g.GROUPS).filter((e=>e.type===a.GroupConfigType.resource)).forEach((t=>{e=Object.assign(Object.assign({},e),c.ConfigHydrator.hydrateTagsConfig(t.tags).tags)}));for(const t of Object.values(e)){const e=t;e.maxCount=0,e.minCount=0}this.allResourcesCache=e}return e}};t.Config=f},2220:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.parse=void 0;const i=r(8321).parse;t.parse=i},2287:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.EMPTY_VERSION=void 0;t.EMPTY_VERSION={full:"",major:"",minor:"",patch:"",build:""}},2483:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextMarkType=void 0;const i=(0,r(4718).superenum)({bold:"bold",light:"light",italic:"italic",highlight:"highlight",strike:"strike",subscript:"subscript",superscript:"superscript",ins:"ins",del:"del",underline:"underline",doubleUnderline:"doubleUnderline",circle:"circle",languageEm:"languageEm",userUnderline:"userUnderline",userDoubleUnderline:"userDoubleUnderline",userStrike:"userStrike",userCircle:"userCircle",userHighlight:"userHighlight",notranslate:"notranslate",link:"link",ref:"ref",xref:"xref",extref:"extref",footnote:"footnote",footnoteStar:"footnote*",symbol:"symbol",var:"var",code:"code",timer:"timer",duration:"duration",color:"color",comment:"comment"});t.TextMarkType=i},2497:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))},o=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r},n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonGenerator=void 0;const a=n(r(7678)),s=r(5126),l=r(7735),p=r(2028),u=r(126),c=r(5854),y=r(3811),g=r(4410),d=r(363),f=r(6149),m=r(385),T=r(6877),h=r(9554),b=r(777),B=r(4078),v=r(8025),C=r(4),P=r(431),x={};class k extends C.AstWalkerGenerator{constructor(e,t){var r,i;super(),this.ast=new s.Ast,this.textParser=new b.TextParser,this.json=[],this.bitWrapperJson={},this.bitJson={},this.textDefault=l.Breakscape.EMPTY_STRING,this.bodyDefault=l.Breakscape.EMPTY_STRING,this.bodyJson=this.bodyDefault,this.placeholderIndex=0,this.enter=this.enter.bind(this),this.between=this.between.bind(this),this.exit=this.exit.bind(this),this.leaf=this.leaf.bind(this),this.bodyBitCallback=this.bodyBitCallback.bind(this),this.bitmarkVersion=null!==(r=y.BitmarkVersion.fromValue(null==t?void 0:t.bitmarkVersion))&&void 0!==r?r:y.DEFAULT_BITMARK_VERSION,this.textParserVersion=this.textParser.version(),this.options=Object.assign(Object.assign({},x),null==t?void 0:t.jsonOptions),this.debugGenerationInline=null!==(i=this.options.debugGenerationInline)&&void 0!==i&&i,this.jsonPrettifySpace=!0===this.options.prettify?2:this.options.prettify||void 0,this.bitmarkVersion===y.BitmarkVersion.v2?void 0===this.options.textAsPlainText&&(this.options.textAsPlainText=!0):void 0===this.options.textAsPlainText&&(this.options.textAsPlainText=!1),this.textGenerator=new P.TextGenerator(y.BitmarkVersion.v2,{bodyBitCallback:this.bodyBitCallback,debugGenerationInline:this.debugGenerationInline}),this.writer=e,this.generatePropertyHandlers()}generate(e){return i(this,void 0,void 0,(function*(){this.resetState(),yield this.writer.open(),this.walkAndWrite(e),this.write(JSON.stringify(this.json,null,this.jsonPrettifySpace)),yield this.writer.close()}))}generateSync(e){this.resetState(),this.writer.openSync(),this.walkAndWrite(e),this.writer.closeSync()}resetState(){this.json=[],this.bitWrapperJson={},this.bitJson={},this.textDefault=this.options.textAsPlainText?l.Breakscape.EMPTY_STRING:[],this.bodyDefault=this.options.textAsPlainText?l.Breakscape.EMPTY_STRING:[],this.bodyJson=this.bodyDefault,this.listItem=void 0,this.placeholderIndex=0,this.printed=!1}walkAndWrite(e){this.ast.walk(e,u.NodeType.bitmarkAst,this,void 0)}enter_bitmarkAst(e,t){this.json=[]}exit_bitmarkAst(e,t){this.options.textAsPlainText&&this.convertAllBitmarkTextsToStringsForPlainText(this.json),this.removeTemporaryProperties(this.json)}enter_bitsValue(e,t){var r,i;const o=e.value;this.bitWrapperJson={},this.json.push(this.bitWrapperJson),this.bitJson=this.createBitJson(o),this.bitWrapperJson.bit=this.bitJson;const n=p.Config.getBitConfig(o.bitType),a=this.getTextFormat(t),s=!!n.rootExampleType,l=n.rootExampleType===d.ExampleType.boolean;if(s){let e;l?(e=!0,p.Config.isOfBitType(o.bitType,c.BitType.trueFalse1)&&void 0!==(null===(i=null===(r=o.cardNode)||void 0===r?void 0:r.statement)||void 0===i?void 0:i.isCorrect)&&(e=o.cardNode.statement.isCorrect)):e="true";const t=this.toExample(o,{defaultExample:e,isBoolean:l,textFormat:a});this.bitJson.isExample=t.isExample,this.bitJson.example=t.example}else o.isExample&&(this.bitJson.isExample=!0);this.placeholderIndex=0}exit_bitsValue(e,t){const r=this.bitJson.isExample,i=this.bitJson.example;delete this.bitJson.isExample,delete this.bitJson.example,this.bitJson.isExample=r,this.bitJson.example=i,this.cleanBitJson(this.bitJson)}enter_imageSource(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_person(e,t){const r=this.getBitType(t);let i="person";return p.Config.isOfBitType(r,c.BitType.conversationLeft1)&&(i="partner"),this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1,keyOverride:i})}enter_ratingLevelStart(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_ratingLevelEnd(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_productId(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==u.NodeType.bitsValue)return!0;return this.getBitType(t)===c.BitType.module?this.addProperty(this.bitJson,"productId",r,{array:!0}):r.length>0&&this.addProperty(this.bitJson,"productId",r[r.length-1],{array:!1}),!1}enter_markConfig(e,t){return!0}enter_markConfigValue(e,t){const r=e.value,i=this.getParentNode(t);return(null==i?void 0:i.key)!==u.NodeType.markConfig||(this.bitJson.marks||(this.bitJson.marks=[]),this.bitJson.marks.push(r),!1)}enter_item(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_lead(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_pageNumber(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_marginNumber(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_hint(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_instruction(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_title(e,t){return this.standardHandler(e,t,[u.NodeType.bitsValue,u.NodeType.cardNode],{array:!0})}enter_subtitle(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_caption(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}enter_width(e,t){var r;let i=e.value;const o=this.getBitType(t),n=this.getParentNode(t);return(null==n?void 0:n.key)===u.NodeType.bitsValue&&p.Config.isOfBitType(o,c.BitType.extractorBlock)&&(i=null!==(r=v.NumberUtils.asNumber(i,0))&&void 0!==r?r:0),this.standardHandler(e,t,void 0,{array:!1,valueOverride:i})}enter_height(e,t){var r;let i=e.value;const o=this.getBitType(t),n=this.getParentNode(t);return(null==n?void 0:n.key)===u.NodeType.bitsValue&&p.Config.isOfBitType(o,c.BitType.extractorBlock)&&(i=null!==(r=v.NumberUtils.asNumber(i,0))&&void 0!==r?r:0),this.standardHandler(e,t,void 0,{array:!1,valueOverride:i})}enter_extraProperties(e,t){const r=e.value;if(!this.options.excludeUnknownProperties&&r)for(const[e,t]of Object.entries(r)){let r=e;Object.prototype.hasOwnProperty.call(this.bitJson,e)&&(r=`_${e}`),this.addProperty(this.bitJson,r,t,{array:!0})}}enter_cardBitsValue(e,t){var r,i,o,n,a,s,l,p,u;const y=e.value,g=this.getBitType(t);if(!g)return;let d;if(g===c.BitType.bookReferenceList){this.bitJson.bookReferences||(this.bitJson.bookReferences=[]);const e={};this.addProperty(e,"lang",y.lang,{array:!1}),this.addProperty(e,"refAuthor",null!==(r=y.refAuthor)&&void 0!==r?r:[],{array:!0}),this.addProperty(e,"refBookTitle",null!==(i=y.refBookTitle)&&void 0!==i?i:[],{array:!1}),this.addProperty(e,"refPublisher",null!==(o=y.refPublisher)&&void 0!==o?o:[],{array:!0}),this.addProperty(e,"refPublicationYear",null!==(n=y.refPublicationYear)&&void 0!==n?n:[],{array:!1}),this.addProperty(e,"citationStyle",null!==(a=y.citationStyle)&&void 0!==a?a:[],{array:!1}),this.bitJson.bookReferences.push(e)}else g===c.BitType.pageFooter?(this.bitJson.sections||(this.bitJson.sections=[]),d=this.bitJson.sections):(this.bitJson.listItems||(this.bitJson.listItems=[]),d=this.bitJson.listItems),this.listItem={item:null!==(s=y.item)&&void 0!==s?s:[],lead:null!==(l=y.lead)&&void 0!==l?l:[],hint:null!==(p=y.hint)&&void 0!==p?p:[],instruction:null!==(u=y.instruction)&&void 0!==u?u:[],body:this.bodyDefault},d.push(this.listItem)}exit_cardBitsValue(e,t){this.listItem=void 0}enter_body(e,t){const r=e.value,i=this.getParentNode(t);if(!i)return!1;const o=this.getTextFormat(t),n=o===m.TextFormat.bitmarkMinusMinus||o===m.TextFormat.bitmarkPlusPlus;if(this.bodyJson=r.body,i.key===u.NodeType.bitsValue){this.bitJson.body=this.bodyJson;const e=n&&this.isBitmarkText(this.bodyJson);if(this.options.textAsPlainText&&e){const e=this.textGenerator.generateSync(this.bodyJson,o,T.TextLocation.body,{noBreakscaping:!0});this.bitJson.body=(null!=e?e:"").trim()}else e&&(this.bitJson.body=this.moveBodyBitPropertiesToAttrs(this.bodyJson))}else i.key===u.NodeType.cardBitsValue&&this.listItem&&(this.listItem.body=this.bodyJson);return!1}bodyBitCallback(e,t,r){var i;const o=`{${this.placeholderIndex}}`;return this.placeholderIndex++,this.bitJson.placeholders=null!==(i=this.bitJson.placeholders)&&void 0!==i?i:{},this.bitJson.placeholders[o]=e,o}moveBodyBitPropertiesToAttrs(e,t=0){if(0===t)e=(0,a.default)(e);else if(t>5e3)throw new Error("Recursion limit exceeded");for(const r of e)if(r.type!==g.BodyBitType.text&&g.BodyBitType.values().includes(r.type)){const e=r;e.attrs={};for(const[t,r]of Object.entries(e))"type"!==t&&"attrs"!==t&&(e.attrs[t]=r,delete e[t])}else Array.isArray(r.content)&&(t++,this.moveBodyBitPropertiesToAttrs(r.content,t));return e}enter_footer(e,t){return this.standardHandler(e,t,void 0,{array:!0,valueOverride:e.value.footer})}enter_elements(e,t){return this.standardHandler(e,t,void 0,{array:!0})}enter_flashcards(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0,keyOverride:"cards"})}enter_definitions(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_statement(e,t){var r,i;const o=e.value,n=this.getParentNode(t);(null==n?void 0:n.key)===u.NodeType.cardNode&&o&&(this.bitJson.statement=null!==(r=o.statement)&&void 0!==r?r:"",this.bitJson.isCorrect=null!==(i=o.isCorrect)&&void 0!==i&&i,this.bitJson.example=o.example,this.bitJson.isExample=o.isExample)}enter_statements(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_choices(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_responses(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_feedbacks(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_quizzes(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_heading(e,t){return this.standardHandler(e,t,void 0,{array:!1})}enter_pairs(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_matrix(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_pronunciationTable(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!1})}enter_table(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!1})}enter_questions(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_botResponses(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0,keyOverride:"responses"})}enter_ingredients(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!0})}enter_captionDefinitionList(e,t){return this.standardHandler(e,t,u.NodeType.cardNode,{array:!1})}enter_imagePlaceholder(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_resources(e,t){var r,i;const o=e.value,n=this.getBitType(t),a=this.getResourceType(t);if(!o||!n)return!0;let s;const l=p.Config.getBitConfig(n),u=p.Config.getBitResourcesConfig(n,a),y=u.comboResourceTagTypesMap;if(u.comboResourceTagTypesMap.size>0)for(const[e,t]of y.entries()){const n={type:e,__typeAlias:e};for(const e of t){const t=o.find((t=>t.__typeAlias===e));if(t){const e=p.Config.getTagConfigForTag(l.tags,t.__typeAlias),o=null!==(r=null==e?void 0:e.jsonKey)&&void 0!==r?r:t.__typeAlias,a=null!==(i=null==e?void 0:e.tag)&&void 0!==i?i:t.__typeAlias,s=t.__typeAlias===a?t:void 0;if(s)for(const[e,t]of Object.entries(s))"type"!==e&&(n[o]=t)}}s=n}else if(p.Config.isOfBitType(n,[c.BitType.imagesLogoGrave,c.BitType.prototypeImages])){const e=[];for(const t of o)t.type===f.ResourceTag.image&&e.push(t);n===c.BitType.imagesLogoGrave?this.bitJson.logos=e:this.bitJson.images=e}else o.length>=1&&(s=o[0]);return this.bitJson.resource=s,!1}leaf_level(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}enter_book(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!0})}leaf_book(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_anchor(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_reference(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_referenceEnd(e,t){return this.standardHandler(e,t,u.NodeType.bitsValue,{array:!1})}leaf_markup(e,t){const r=e.value;return r&&(this.bitWrapperJson.bitmark=r),!1}enter_internalComment(e,t){return!1}enter_parser(e,t){const r=e.value,i=this.getBitType(t),n=this.getParentNode(t);if(r&&i){const{version:e,excessResources:i,warnings:a,errors:s}=r,l=o(r,["version","excessResources","warnings","errors"]),p=`${this.bitmarkVersion}`,c=this.textParserVersion;let y;if(Array.isArray(i)&&i.length>0){y=[];for(const e of i)y.push(e)}const g=this.getInternalComments(t);(null==n?void 0:n.key)===u.NodeType.bitsValue&&(this.bitWrapperJson.parser=Object.assign(Object.assign({version:e,bitmarkVersion:p,textParserVersion:c,internalComments:g},l),{warnings:a,errors:s,excessResources:y}),this.options.enableWarnings||delete this.bitWrapperJson.parser.warnings)}}generatePropertyHandlers(){var e;const t=p.Config.getRawPropertiesConfig();for(const r of Object.values(t)){const t=null!==(e=r.astKey)&&void 0!==e?e:r.tag,i=`enter_${t}`;"function"!=typeof this[i]&&("example"!==t&&(this[i]=(e,t)=>{var i;const o=e.value;if(null==o)return;const n=this.getParentNode(t);if((null==n?void 0:n.key)!==u.NodeType.bitsValue)return;const a=null!==(i=r.jsonKey)&&void 0!==i?i:r.tag;this.addProperty(this.bitJson,a,o,{array:!r.single})},this[i]=this[i].bind(this)))}}standardHandler(e,t,r,i){var o,n;if(r){const e=Array.isArray(r)?r:[r],i=this.getParentNode(t);if(!(null==i?void 0:i.key)||!e.includes(null==i?void 0:i.key))return!0}return this.addProperty(this.bitJson,null!==(o=i.keyOverride)&&void 0!==o?o:e.key,null!==(n=i.valueOverride)&&void 0!==n?n:e.value,i),!1}addProperty(e,t,r,i){if(void 0!==r){let o;Array.isArray(r)||(r=[r]);const n=r;o=!i.array&&n.length>=1?n[n.length-1]:n,(i.allowNull||null!=o)&&(e[t]=o)}}toExample(e,t){const{isExample:r,example:i,__isDefaultExample:o}=e,{defaultExample:n,isBoolean:a}=t;if(!r)return{isExample:!1,example:null};let s;return s=o?a?B.BooleanUtils.toBoolean(n):this.convertBreakscapedStringToJsonText(n,t.textFormat,!0):a?B.BooleanUtils.toBoolean(i):this.convertBreakscapedStringToJsonText(i,t.textFormat,!0),{isExample:!0,example:s}}getBitType(e){for(const t of e)if(t.key===u.NodeType.bitsValue){const e=t.value;return null==e?void 0:e.bitType}}getTextFormat(e){var t;const r=this.getBitType(e);if(r){const i=p.Config.getBitConfig(r);for(const r of e)if(r.key===u.NodeType.bitsValue){const e=r.value;return null!==(t=m.TextFormat.fromValue(null==e?void 0:e.textFormat))&&void 0!==t?t:i.textFormatDefault}}return m.TextFormat.bitmarkMinusMinus}getResourceType(e){for(const t of e)if(t.key===u.NodeType.bitsValue){const e=t.value;return null==e?void 0:e.resourceType}}getInternalComments(e){if(this.getBitType(e))for(const t of e)if(t.key===u.NodeType.bitsValue){return t.value.internalComment}}convertBreakscapedStringToJsonText(e,t,r){if(!(t===m.TextFormat.bitmarkMinusMinus||t===m.TextFormat.bitmarkPlusPlus))return e||"";if(this.options.textAsPlainText)return e||"";return this.textParser.toAst(e,{textFormat:t,isProperty:r})}concatenatePlainTextWithJsonTexts(e,t,r){var i;if(Array.isArray(e)){if(r=r.trim()){const o=r.split("\n"),n=[];for(let e=0;e<t;e++)n.push({type:h.TextNodeType.hardBreak});for(let e=0;e<o.length;e++){const t=o[e];t&&n.push({text:t,type:h.TextNodeType.text}),e<o.length-1&&n.push({type:h.TextNodeType.hardBreak})}const a=e[e.length-1];a&&a.type===h.TextNodeType.paragraph?a.content=[...null!==(i=a.content)&&void 0!==i?i:[],...n]:e.push({type:h.TextNodeType.paragraph,content:n,attrs:{}})}return e}return`${null!=e?e:""}${"\n".repeat(t)}${null!=r?r:""}`}isBitmarkText(e){return null!=e&&(!!Array.isArray(e)&&"text"===e.__tag)}writeInlineDebug(e,t){let r=e;t.open?r=`<${e}>`:t.close?r=`</${e}>`:t.single&&(r=`<${e} />`),this.writeString(r)}writeString(e){null!=e&&this.write(`${e}`)}createBitJson(e){return{type:e.isCommented?c.BitType._comment:e.bitType,originalType:e.isCommented?e.bitType:void 0,format:e.textFormat,bitLevel:e.bitLevel}}cleanBitJson(e){var t,r,i,o,n,a;const s=p.Config.getBitType(e.type),l=p.Config.getBitConfig(s);if(null==e.originalType&&(e.originalType=void 0),e.item||(e.item=void 0),p.Config.isOfBitType(s,[c.BitType._error,c.BitType._comment]))delete e.format,delete e.item,delete e.lead,delete e.pageNumber,delete e.marginNumber,delete e.hint,delete e.instruction;else{let u=!1,y=!1;p.Config.isOfBitType(s,[c.BitType.page])?(null!=e.item&&0!==(null===(t=e.item)||void 0===t?void 0:t.length)||delete e.item,null!=e.lead&&0!==(null===(r=e.lead)||void 0===r?void 0:r.length)||delete e.lead,null!=e.pageNumber&&0!==(null===(i=e.pageNumber)||void 0===i?void 0:i.length)||delete e.pageNumber,null!=e.marginNumber&&0!==(null===(o=e.marginNumber)||void 0===o?void 0:o.length)||delete e.marginNumber,null!=e.hint&&0!==(null===(n=e.hint)||void 0===n?void 0:n.length)||delete e.hint,null!=e.instruction&&0!==(null===(a=e.instruction)||void 0===a?void 0:a.length)||delete e.instruction):(null==e.item&&(e.item=this.textDefault),null==e.lead&&(e.lead=this.textDefault),null==e.hint&&(e.hint=this.textDefault),null==e.instruction&&(e.instruction=this.textDefault),null==e.pageNumber&&(e.pageNumber=this.textDefault),null==e.marginNumber&&(e.marginNumber=this.textDefault)),null==e.body&&(e.body=this.bodyDefault),p.Config.isOfBitType(s,[c.BitType.article]),p.Config.isOfBitType(s,[c.BitType.example])&&(u=!0,y=!0),p.Config.isOfBitType(s,[c.BitType.multipleChoice1,c.BitType.multipleResponse1,c.BitType.multipleChoiceText,c.BitType.highlightText,c.BitType.gapText,c.BitType.gapTextInstructionGrouped,c.BitType.clozeAndMultipleChoiceText,c.BitType.sequence,c.BitType.mark,c.BitType.flashcard,c.BitType.definitionList])&&(u=!0,null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,[c.BitType.sequence])&&(u=!0,y=!0,null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.cloze)&&(u=!0,p.Config.isOfBitType(s,c.BitType.clozeSolutionGrouped)?(null==e.quizCountItems&&(e.quizCountItems=!0),null==e.quizStrikethroughSolutions&&(e.quizStrikethroughSolutions=!0)):p.Config.isOfBitType(s,c.BitType.clozeInstructionGrouped)&&(null==e.quizCountItems&&(e.quizCountItems=!0),null==e.quizStrikethroughSolutions&&(e.quizStrikethroughSolutions=!1))),p.Config.isOfBitType(s,[c.BitType.multipleChoice,c.BitType.multipleResponse])&&(u=!0,null==e.body&&(e.body=this.bodyDefault),null==e.footer&&(e.footer=this.textDefault)),p.Config.isOfBitType(s,c.BitType.essay)&&(u=!0,y=!0,null==e.body&&(e.body=this.bodyDefault),null==e.partialAnswer&&(e.partialAnswer="")),p.Config.isOfBitType(s,c.BitType.trueFalse1)&&(u=!0,y=!0,null==e.isCorrect&&(e.isCorrect=!1),null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.trueFalse)&&(u=!0,null==e.labelFalse&&(e.labelFalse=""),null==e.labelTrue&&(e.labelTrue=""),null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.chapter)&&(null==e.toc&&(e.toc=!0),null==e.progress&&(e.progress=!0),null==e.level&&(e.level=1),null==e.body&&(e.body=this.bodyDefault)),p.Config.isOfBitType(s,c.BitType.interview)&&(u=!0,null==e.body&&(e.body=this.bodyDefault),null==e.footer&&(e.footer=this.textDefault),null==e.questions&&(e.questions=[])),s===c.BitType.matchMatrix&&(u=!0),p.Config.isOfBitType(s,c.BitType.match)&&(u=!0,null==e.heading&&(e.heading={})),p.Config.isOfBitType(s,c.BitType.learningPathBook)&&(null==e.isTracked&&(e.isTracked=!0),null==e.isInfoOnly&&(e.isInfoOnly=!1)),p.Config.isOfBitType(s,c.BitType.table)&&(null==e.tableFixedHeader&&(e.tableFixedHeader=!1),null==e.tableSearch&&(e.tableSearch=!1),null==e.tableSort&&(e.tableSort=!1),null==e.tablePagination&&(e.tablePagination=!1),null==e.tablePaginationLimit&&(e.tablePaginationLimit=0),null==e.tableHeight&&(e.tableHeight=0),null==e.tableWhitespaceNoWrap&&(e.tableWhitespaceNoWrap=!1),null==e.tableAutoWidth&&(e.tableAutoWidth=!0),null==e.tableResizableColumns&&(e.tableResizableColumns=!1),null==e.tableColumnMinWidth&&(e.tableColumnMinWidth=0)),p.Config.isOfBitType(s,c.BitType.bookReference)&&(null==e.refAuthor&&(e.refAuthor=[]),null==e.refBookTitle&&(e.refBookTitle=""),null==e.refPublisher&&(e.refPublisher=[]),null==e.refPublicationYear&&(e.refPublicationYear="")),p.Config.isOfBitType(s,[c.BitType.pageBanner,c.BitType.pageBuyButton,c.BitType.pageBuyButtonAlt,c.BitType.pageBuyButtonPromotion,c.BitType.pageFooter,c.BitType.pageOpenBook,c.BitType.pagePerson,c.BitType.pageProduct,c.BitType.pageProductList,c.BitType.pageProductVideo,c.BitType.pageProductVideoList,c.BitType.pageSectionFolder,c.BitType.pageSubscribe,c.BitType.pageSubpage])&&(null==e.slug&&(e.slug=""),null==e.body&&(e.body=this.bodyDefault),p.Config.isOfBitType(s,c.BitType.pageBuyButton)&&null==e.content2Buy&&(e.content2Buy="")),p.Config.isOfBitType(s,c.BitType.book)&&(null==e.maxTocChapterLevel&&(e.maxTocChapterLevel=-1),null==e.hasMarkAsDone&&(e.hasMarkAsDone=!1),null==e.processHandIn&&(e.processHandIn=!1),null==e.isPublic&&(e.isPublic=!1),null==e.chatWithBook&&(e.chatWithBook=!1),null==e.chatWithBookBrainKey&&(e.chatWithBookBrainKey="")),s!==c.BitType.articleAi&&s!==c.BitType.noteAi&&s!==c.BitType.summaryAi||null==e.aiGenerated&&(e.aiGenerated=!0),p.Config.isOfBitType(s,[c.BitType.articleResponsive,c.BitType.pageArticleResponsive])&&null==e.imageFirst&&(e.imageFirst=!0),p.Config.isOfBitType(s,c.BitType.reviewNote)&&(null==e.resolved&&(e.resolved=!1),null==e.resolvedDate&&(e.resolvedDate=""),null==e.resolvedBy&&(e.resolvedBy="")),p.Config.isOfBitType(s,[c.BitType.imagesLogoGrave,c.BitType.prototypeImages])&&(s===c.BitType.imagesLogoGrave?null==e.logos&&(e.logos=[]):null==e.images&&(e.images=[])),p.Config.isOfBitType(s,[c.BitType.stepImageScreenshotWithPointer,c.BitType.surveyMatrix])&&(null==e.pointerTop&&(e.pointerTop=""),null==e.pointerLeft&&(e.pointerLeft=""),p.Config.isOfBitType(s,[c.BitType.surveyMatrix])&&null==e.buttonCaption&&(e.buttonCaption="")),p.Config.isOfBitType(s,[c.BitType.listItem])&&null==e.listItemIndent&&(e.listItemIndent=0),p.Config.isOfBitType(s,c.BitType.surveyRating)&&(null==e.ratingLevelStart&&(e.ratingLevelStart={level:0}),null==e.ratingLevelEnd&&(e.ratingLevelEnd={level:0})),p.Config.isOfBitType(s,c.BitType.vendorStripePricingTable)&&(null==e.stripePricingTableId&&(e.stripePricingTableId=""),null==e.stripePublishableKey&&(e.stripePublishableKey="")),p.Config.isOfBitType(s,c.BitType.callToAction)&&(null==e.buttonCaption&&(e.buttonCaption=""),null==e.callToActionUrl&&(e.callToActionUrl="")),p.Config.isOfBitType(s,c.BitType.handInFile)&&null==e.handInAcceptFileType&&(e.handInAcceptFileType=[]),p.Config.isOfBitType(s,c.BitType.handInSubmit)&&(null==e.handInRequirement&&(e.handInRequirement=[]),null==e.handInInstruction&&(e.handInInstruction=""),null==e.buttonCaption&&(e.buttonCaption="")),p.Config.isOfBitType(s,c.BitType.module)&&null==e.hasBookNavigation&&(e.hasBookNavigation=!0),p.Config.isOfBitType(s,c.BitType.container)&&null==e.allowedBit&&(e.allowedBit=[]),l.quizBit&&null==e.revealSolutions&&(e.revealSolutions=!1),p.Config.isOfBitType(s,c.BitType.platformPath)&&null==e.path&&(e.path=""),u?null==e.isExample&&(e.isExample=!1):(delete e.isExample,delete e.example),y?null==e.example&&(e.example=null):delete e.example}return e}convertAllBitmarkTextsToStringsForPlainText(e){if(!this.options.textAsPlainText)return;const t=e;for(const e in t){const r=t[e];if(this.isBitmarkText(r)){const i=this.textGenerator.generateSync(r,m.TextFormat.bitmarkMinusMinus,T.TextLocation.tag,{noBreakscaping:!0});t[e]=(null!=i?i:"").trim()}else"object"==typeof t[e]&&this.convertAllBitmarkTextsToStringsForPlainText(t[e])}}removeTemporaryProperties(e){const t=e;for(const e in t)e.startsWith("__")?delete t[e]:"object"==typeof t[e]&&this.removeTemporaryProperties(t[e])}write(e){return this.writer.write(e),this}writeLine(e){return this.writer.writeLine(e),this}writeLines(e,t){return this.writer.writeLines(e,t),this}writeWhiteSpace(){return this.writer.writeWhiteSpace(),this}}t.JsonGenerator=k},3029:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CARD_VARIANT_DIVIDER_V1=t.CARD_SIDE_DIVIDER_V1=t.CARD_DIVIDER_V1=t.CARD_VARIANT_DIVIDER_V2=t.CARD_SIDE_DIVIDER_V2=t.CARD_DIVIDER_V2=t.BitContentLevel=t.TypeKey=void 0;const i=r(4718),o=r(9917);t.CARD_DIVIDER_V2="====";t.CARD_SIDE_DIVIDER_V2="--";t.CARD_VARIANT_DIVIDER_V2="++";t.CARD_DIVIDER_V1="===";t.CARD_SIDE_DIVIDER_V1="==";t.CARD_VARIANT_DIVIDER_V1="--";const n=(0,i.superenum)({TextFormat:"TextFormat",ResourceType:"ResourceType",Title:o.Tag.tag_title,Anchor:o.Tag.tag_anchor,Reference:o.Tag.tag_reference,ItemLead:o.Tag.tag_itemLead,Instruction:o.Tag.tag_instruction,Hint:o.Tag.tag_hint,True:o.Tag.tag_true,False:o.Tag.tag_false,Gap:o.Tag.tag_gap,Mark:o.Tag.tag_mark,SampleSolution:o.Tag.tag_sampleSolution,Property:"Property",Resource:"Resource",TagChain:"TagChain",BodyChar:"BodyChar",BodyText:"BodyText",BodyTextPlain:"BodyTextPlain",CardSet:"CardSet",Card:"Card",CardChar:"CardChar",CardText:"CardText",GapChain:"GapChain",TrueFalseChain:"TrueFalseChain",PlainTextDivider:"PlainTextDivider",FooterDivider:"FooterDivider"});t.TypeKey=n;const a=(0,i.superenum)({Bit:"Bit",Card:"Card",Chain:"Chain"});t.BitContentLevel=a},3045:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.bookChainContentProcessor=function(e,t,r,u,c){t===p.BitContentLevel.Chain||function(e,t,r,u,c){const{bitConfig:y}=e;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("book content",u);const g=e.bitContentProcessor(p.BitContentLevel.Chain,r,u.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("book TAGS",g);const{reference:d,referenceEnd:f}=g,m=i.Breakscape.unbreakscape(l.StringUtils.trimmedString(u.value),{textFormat:a.TextFormat.bitmarkMinusMinus,textLocation:s.TextLocation.tag}),T=y.tags[o.PropertyConfigKey.book];if(T&&(T.maxCount===n.Count.infinity||T.maxCount>1))return Array.isArray(c.book)||(c.book=[]),void c.book.push({book:m,reference:null!=d?d:"",referenceEnd:null!=f?f:void 0});c.book=m,c.reference=d,c.referenceEnd=f}(e,0,r,u,c)};const i=r(7735),o=r(9888),n=r(3778),a=r(385),s=r(6877),l=r(9681),p=r(3029)},3063:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.markConfigChainContentProcessor=function(e,t,r,c,y){var g;const{key:d}=c;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("mark content",c);const f=y.markConfig;if(!f)return;const m=n.Config.getTagConfigForTag(r,a.PropertyTag.fromValue(d)),T=e.bitContentProcessor(u.BitContentLevel.Chain,null==m?void 0:m.chain,c.chain),{mark:h}=T,b=i(T,["mark"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("mark TAGS",b);const B=o.Breakscape.unbreakscape(null!==(g=p.StringUtils.trimmedString(c.value))&&void 0!==g?g:"unknown",{textFormat:s.TextFormat.bitmarkMinusMinus,textLocation:l.TextLocation.tag}),v=Object.assign({mark:B,emphasis:"underline"},b);v&&f.push(v)};const o=r(7735),n=r(2028),a=r(166),s=r(385),l=r(6877),p=r(9681),u=r(3029)},3069:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.InfoFormat=void 0;const i=(0,r(4718).superenum)({text:"text",json:"json",pojo:"pojo"});t.InfoFormat=i},3206:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkPegParserHelper=void 0;const i=r(7735),o=r(1163),n=r(385),a=r(6877),s=r(9681),l=r(7461),p=r(3029);r(2028);t.BitmarkPegParserHelper=class{constructor(e){this.cardIndex=0,this.cardSideIndex=0,this.cardVariantIndex=0,this.parse=e.parse,this.parserText=e.parserText,this.parserLocation=e.parserLocation}handleRawBit(e){var t,r;const i=e.trim();if(this.debugPrint("RAW BIT",i),!i)return;const o=null!==(r=null===(t=this.parserLocation())||void 0===t?void 0:t.start)&&void 0!==r?r:{line:1,column:1,offset:0},n=this.parse(e,{startRule:"bit",grammarSource:new l.PeggyGrammarLocation("bit",o)});return n.value&&(n.value.markup=i),n}handleTextFormat(e){return{type:p.TypeKey.TextFormat,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleResourceType(e){return{type:p.TypeKey.ResourceType,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleBitContent(e){let t=this.reduceToArrayOfTypes(e);return t=this.mergeCharToText(t),t}handleBitTag(e){return e}handleTag(e,t){return{type:e,value:t,parser:{text:this.parserText(),location:this.parserLocation()}}}handlePropertyTag(e,t){return{type:p.TypeKey.Property,key:i.Breakscape.unbreakscape(e,{textFormat:n.TextFormat.bitmarkMinusMinus,textLocation:a.TextLocation.tag}),value:t,parser:{text:this.parserText(),location:this.parserLocation()}}}handleResourceTag(e,t){return{type:p.TypeKey.Resource,key:i.Breakscape.unbreakscape(e,{textFormat:n.TextFormat.bitmarkMinusMinus,textLocation:a.TextLocation.tag}),value:t,parser:{text:this.parserText(),location:this.parserLocation()}}}handleTagChain(e){const t=this.reduceToArrayOfTypes(e);let r=t;if(t.length>1){const e=t[0];e.chain=t.slice(1),r=[e]}return r}handlePlainTextDivider(e){return e=this.reduceToString(e),{type:p.TypeKey.PlainTextDivider,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleFooterDivider(e){return e=this.reduceToString(e),{type:p.TypeKey.FooterDivider,value:e,parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardSet(e){const t=e,r={cards:[]},i={cards:[]};if(t){const e={text:this.parserText(),location:this.parserLocation()};for(const e of t){if(!e)continue;const{type:t,value:i,parser:o}=e;if(!t||t!==p.TypeKey.Card)continue;const{cardIndex:n,cardSideIndex:a,cardVariantIndex:s,value:l}=i;let u=r.cards[n];u||(u={sides:[]},r.cards[n]=u);let c=u.sides[a];c||(c={variants:[]},u.sides[a]=c);c.variants[s]?c.variants[s].value+=l:c.variants[s]={value:l,parser:o}}r.cards=r.cards.filter((e=>e.sides.some((e=>e.variants.some((e=>0!==s.StringUtils.trimmedString(e.value).length))))));for(const t of r.cards){const r={sides:[]};i.cards.push(r);for(const i of t.sides){const t={variants:[]};r.sides.push(t);for(const r of i.variants){let i={line:1,column:1,offset:0};if(r.parser.location){i=r.parser.location.start;const e=r.parser.text,t=e?e.length:0,o=1;i.offset+=t,i.line+=o}let o=this.parse(r.value,{startRule:"cardContent",grammarSource:new l.PeggyGrammarLocation("card-content",i)});o=this.reduceToArrayOfTypes(o),this.debugPrint("parsedCardContent",o),t.variants.push({parser:e,content:o})}}}}return{type:p.TypeKey.CardSet,value:i,parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardSetStart(){this.cardIndex=-1,this.cardSideIndex=0,this.cardVariantIndex=0}handleCardSetEnd(){this.cardIndex=0,this.cardSideIndex=0,this.cardVariantIndex=0}handleCards(e){return e}handleCardLineOrDivider(e,t){let r=!1,i=!1,n=!1;return Array.isArray(e)&&2===e.length&&(e=e[0],t===o.CardSetVersion.v1?(r=e===p.CARD_DIVIDER_V1,i=e===p.CARD_SIDE_DIVIDER_V1,n=e===p.CARD_VARIANT_DIVIDER_V1):(r=e===p.CARD_DIVIDER_V2,i=e===p.CARD_SIDE_DIVIDER_V2,n=e===p.CARD_VARIANT_DIVIDER_V2)),r?(this.cardIndex++,this.cardSideIndex=0,this.cardVariantIndex=0):i?(this.cardSideIndex++,this.cardVariantIndex=0):n&&this.cardVariantIndex++,this.isType(e,p.TypeKey.Card)?e:{type:p.TypeKey.Card,value:{cardIndex:this.cardIndex,cardSideIndex:this.cardSideIndex,cardVariantIndex:this.cardVariantIndex,value:""},parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardLine(e){return{type:p.TypeKey.Card,value:{cardIndex:this.cardIndex,cardSideIndex:this.cardSideIndex,cardVariantIndex:this.cardVariantIndex,value:e},parser:{text:this.parserText(),location:this.parserLocation()}}}handleCardContent(e){return this.mergeCharToText(e)}handleCardTags(e){return e}mergeCharToText(e){var t,r,i,o,n,a;const s=[];let l,u;for(const c of e)switch(c.type){case p.TypeKey.BodyChar:if(l){const e=`${null!==(t=l.value)&&void 0!==t?t:""}${null!==(r=c.value)&&void 0!==r?r:""}`;l.value=e}else l={type:p.TypeKey.BodyText,value:null!==(i=c.value)&&void 0!==i?i:"",parser:{text:this.parserText(),location:this.parserLocation()}};break;case p.TypeKey.CardChar:if(u){const e=`${null!==(o=u.value)&&void 0!==o?o:""}${null!==(n=c.value)&&void 0!==n?n:""}`;u.value=e}else u={type:p.TypeKey.CardText,value:null!==(a=c.value)&&void 0!==a?a:"",parser:{text:this.parserText(),location:this.parserLocation()}};break;default:l&&(s.push(l),l=void 0),u&&(s.push(u),u=void 0),s.push(c)}return l&&s.push(l),u&&s.push(u),s}isType(e,t){if(!e)return!1;const{type:r}=e;return t?Array.isArray(t)?t.indexOf(r)>=0:t===r:!!p.TypeKey.fromValue(r)}reduceToArrayOfTypes(e,t,r){if(!Array.isArray(e))return[];return e.reduce(((e,i,o)=>{if(null==i)return e;const{type:n,value:a}=i;if(Array.isArray(i)){const r=this.reduceToArrayOfTypes(i,t);e.push(...r)}else{if(!this.isType(i,t))return e;if(r&&Array.isArray(a)){const r=this.reduceToArrayOfTypes(a,t);e.push(...r)}else n&&e.push(i)}return e}),[])}reduceToString(e){if(!Array.isArray(e))return"";return e.reduce(((e,t,r)=>{if(null==t)return e;if(Array.isArray(t)){e+=this.reduceToString(t)}else e+=t;return e}),[])}debugPrint(e,t){}}},3619:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitConfig=void 0;const i=r(3778);t.BitConfig=class{constructor(e){this.tags={};const{since:t,bitType:r,inheritedBitTypes:i,textFormatDefault:o,tags:n,cardSet:a,quizBit:s,deprecated:l,bodyAllowed:p,bodyRequired:u,footerAllowed:c,footerRequired:y,resourceAttachmentAllowed:g,rootExampleType:d,comboResourceType:f}=e;this.since=t,this.bitType=r,this.inheritedBitTypes=i,this.inheritedBitTypesSet=new Set(i),this.textFormatDefault=o,this.tags=n,this.cardSet=a,this.quizBit=s,this.deprecated=l,this.bodyAllowed=p??!0,this.bodyRequired=u,this.footerAllowed=c??!0,this.footerRequired=y,this.resourceAttachmentAllowed=g??!0,this.rootExampleType=d,this.comboResourceType=f}toString(e){const t=Object.assign({},e);let r=`[Bit]\n${this.bitType}`;this.inheritedBitTypes.length>0&&(r+="\n\n[Inheritance]",r+=`\n${this.inheritedBitTypes.join(" => ")}`),r+=`\n\n[Default text format]\n${this.textFormatDefault}`;const o=[];null!=this.since&&o.push(`since=${this.since}`),null!=this.deprecated&&o.push(`deprecated=${this.deprecated}`),this.bodyAllowed&&o.push("bodyAllowed"),this.bodyRequired&&o.push("bodyRequired"),this.footerAllowed&&o.push("footerAllowed"),this.footerRequired&&o.push("footerRequired"),this.resourceAttachmentAllowed&&o.push("resourceAttachmentAllowed"),null!=this.rootExampleType&&o.push(`rootExampleType=${this.rootExampleType}`),null!=this.comboResourceType&&o.push(`comboResourceType=${this.comboResourceType}`),r+=`\n\n[Flags]\n${o.join(", ")}`,r+="\n\n[Tags]";for(const e of Object.values(this.tags))(e.maxCount===i.Count.infinity||e.maxCount>0)&&(r+=`\n${e.toString(t)}`);return this.cardSet&&(r+=`\n\n${this.cardSet.toString(t)}`),r}}},3778:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Count=void 0;const i=(0,r(4718).superenum)({infinity:"infinity"});t.Count=i},3811:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_BITMARK_VERSION=t.BitmarkVersion=void 0;const i=(0,r(4718).superenum)({v2:2,v3:3});t.BitmarkVersion=i;const o=i.v3;t.DEFAULT_BITMARK_VERSION=o},3881:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.InfoBuilder=void 0;const i=r(2028),o=r(5854);t.InfoBuilder=class{getSupportedBits(e){var t,r;const n=null===(t=null==e?void 0:e.includeNonDeprecated)||void 0===t||t,a=null!==(r=null==e?void 0:e.includeDeprecated)&&void 0!==r&&r,s=[];for(const e of o.BitType.values()){if(e===o.BitType._error||e===o.BitType._comment)continue;const t=i.Config.getBitType(e),r=i.Config.getBitConfig(t),l=r.inheritedBitTypes.length>0?r.inheritedBitTypes:void 0;(n&&!r.deprecated||a&&r.deprecated)&&s.push({name:e,since:r.since,deprecated:r.deprecated,inheritedBitTypes:l})}return s}getSupportedBitConfigs(){const e=[];for(const t of o.BitType.values()){if(t===o.BitType._error||t===o.BitType._comment)continue;const r=i.Config.getBitType(t),n=i.Config.getBitConfig(r);e.push(n)}return e}}},3904:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.gapChainContentProcessor=function(e,t,r,l,p,u){if(t===s.BitContentLevel.Chain)(0,a.clozeTagContentProcessor)(e,t,r,l,p);else{const t=function(e,t,r,a){var l;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("gap content",a);const p=i.Config.getTagConfigForTag(r,n.Tag.fromValue(a.type)),u=[a,...null!==(l=a.chain)&&void 0!==l?l:[]],c=e.bitContentProcessor(s.BitContentLevel.Chain,null==p?void 0:p.chain,u);e.DEBUG_CHAIN_TAGS&&e.debugPrint("gap TAGS",c);const y=Object.assign({type:o.BodyBitType.gap},c);return y}(e,0,r,l);t&&u.push(t)}};const i=r(2028),o=r(4410),n=r(9917),a=r(554),s=r(3029)},3967:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ratingLevelChainContentProcessor=function(e,t,r,n,l){var p;const{textFormat:u}=e,{key:c,value:y}=n;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("ratingLevel content",n);const g=e.bitContentProcessor(a.BitContentLevel.Chain,r,n.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("ratingLevel TAGS",g);const{label:d}=g,f={level:null!==(p=o.NumberUtils.asNumber(y))&&void 0!==p?p:0,label:d?s.toAst(d,{textFormat:u,isProperty:!0}):void 0};switch(c){case i.PropertyTag.ratingLevelStart:l.ratingLevelStart=f;break;case i.PropertyTag.ratingLevelEnd:l.ratingLevelEnd=f}};const i=r(166),o=r(8025),n=r(777),a=r(3029),s=new n.TextParser},3968:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkStringGenerator=void 0;const o=r(6772),n=r(5087);t.BitmarkStringGenerator=class{constructor(e){this.writer=new o.StringWriter,this.generator=new n.BitmarkGenerator(this.writer,e)}generate(e){return i(this,void 0,void 0,(function*(){return yield this.generator.generate(e),this.writer.getString()}))}generateSync(e){return this.generator.generateSync(e),this.writer.getString()}}},3990:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.referenceTagContentProcessor=function(e,t,r,s,l,p){const{value:u}=s,c=a.StringUtils.trimmedString(u);p?l.referenceEnd=i.Breakscape.unbreakscape(c,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}):l.reference=i.Breakscape.unbreakscape(c,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag})};const i=r(7735),o=r(385),n=r(6877),a=r(9681)},4020:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.trueFalseTagContentProcessor=function(e,t,r,l){const{type:p,value:u}=r,c=l.trueFalse;if(!c)return;const y=i.Breakscape.unbreakscape(a.StringUtils.trimmedString(u),{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});c.push({text:y,isCorrect:p===s.TypeKey.True,__isDefaultExample:!1})};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(3029)},4078:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BooleanUtils=void 0;const r=new class{isBoolean(e){return!0===e||!1===e}isBooleanString(e){return!!this.isBoolean(e)||("true"===e||"false"===e)}toBoolean(e,t){return t?!1!==e&&"false"!==e:!0===e||"true"===e}};t.BooleanUtils=r},4091:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.exampleTagContentProcessor=function(e,t,r,c){const{bitType:y}=e,{value:g}=r,d=g;o.Config.isOfBitType(y,[n.BitType.cloze,n.BitType.clozeAndMultipleChoiceText,n.BitType.multipleChoiceText,n.BitType.highlightText,n.BitType.trueFalse,n.BitType.trueFalse1,n.BitType.multipleResponse,n.BitType.multipleResponse1,n.BitType.multipleChoice,n.BitType.multipleChoice1])?function(e,t,r,c){var y,g;const{bitType:d,textFormat:f}=e;let m;Array.isArray(c.trueFalse)&&c.trueFalse.length>0&&(m=null!==(y=c.trueFalse[c.trueFalse.length-1])&&void 0!==y?y:void 0);m?!0===r?(m.__isDefaultExample=!0,m.example=!!m.isCorrect):l.BooleanUtils.isBooleanString(r)?m.example=l.BooleanUtils.toBoolean(r):(m.__isDefaultExample=!0,m.example=void 0,e.addWarning("Only 'true' / 'false' / default are allowed here, using default",t)):Array.isArray(c.__solutionsAst)&&c.__solutionsAst.length>0?c.example=!0===r?null!==(g=c.__solutionsAst[c.__solutionsAst.length-1])&&void 0!==g?g:void 0:r?p.toAst(r,{textFormat:f,isProperty:!0}):void 0:o.Config.isOfBitType(d,[n.BitType.multipleChoiceText,n.BitType.highlightText,n.BitType.trueFalse,n.BitType.trueFalse1,n.BitType.multipleResponse,n.BitType.multipleResponse1])?function(e,t,r,o){if(!0===r)o.__isDefaultExample=!0,o.example=void 0;else{const n=r?i.Breakscape.unbreakscape(r,{textFormat:a.TextFormat.bitmarkMinusMinus,textLocation:s.TextLocation.tag}):void 0;l.BooleanUtils.isBooleanString(n)?o.example=l.BooleanUtils.toBoolean(n):(o.__isDefaultExample=!0,o.example=void 0,e.addWarning("Only 'true' / 'false' / default are allowed here, using default",t))}}(e,t,r,c):o.Config.isOfBitType(d,[n.BitType.clozeAndMultipleChoiceText,n.BitType.multipleChoice,n.BitType.multipleChoice1])?(c.__isDefaultExample=!0,c.example=void 0,!0!==r&&e.addWarning("At this level, only default [@example] is allowed, using default",t)):u(e,t,r,c)}(e,r,d,c):o.Config.isOfBitType(y,n.BitType.mark)?function(e,t,r,i){i.__isDefaultExample=!0,i.example=void 0,!0!==r&&e.addWarning("Only default [@example] is allowed, using default",t)}(e,r,d,c):u(e,r,d,c)};const i=r(7735),o=r(2028),n=r(5854),a=r(385),s=r(6877),l=r(4078),p=new(r(777).TextParser);function u(e,t,r,i){const{textFormat:o}=e;!0===r||"true"===r?(i.__isDefaultExample=!0,i.example=void 0):i.example=r?p.toAst(r,{textFormat:o,isProperty:!0}):void 0}},4266:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkPegParserValidator=void 0;const i=r(2028),o=r(5512),n=r(3778),a=r(166),s=r(9917),l=r(3029),p=["----","\n==\n","\n---\n"],u=["==\n","--\n"],c=["\n==","\n--"];const y=new class{validateBitTags(e,t){if(!t)return[];const{bitConfig:r,bitType:o,resourceType:n}=e,{tags:a,cardSet:s}=r,p=i.Config.getBitResourcesConfig(o,n),u=Object.assign(Object.assign({},a),p.tags);return this.validateTagChainsRecursive(e,l.BitContentLevel.Bit,o,t,u,s).validated}checkBody(e,t,r,i,o){if(!o)return o;const{bitConfig:n}=e,{bodyAllowed:a}=n;return o.length>0&&!a&&e.addWarning(`Bit '${r}' should not have a body.`),o}checkBodyPart(e,t,r){return r?(this.checkBodyForCommonPotentialMistakes(e,t,r),r):r}checkFooter(e,t,r){if(!r)return r;const{bitConfig:i,bitType:o}=e,{footerAllowed:n}=i;return this.checkBodyForCommonPotentialMistakes(e,t,r),n||e.addWarning(`Bit '${o}' should not have a footer.`),r}checkCardBody(e,t,r,i,o,n,a){if(!i||!i.body)return i;const{bitConfig:s}=e;if(!s.cardSet)return i;const l=this.getVariantConfig(s.cardSet.variants,n,a);if(!l)return i;const{bodyAllowed:p}=l;return i.bodyString.length>0&&!p&&e.addWarning(`Bit '${r}' should not have a card body at card:${o+1}, side:${n+1}, variant:${a+1}.`),i}validateTagChainsRecursive(e,t,r,i,p,u,c){var y;if(!i)return{validated:[]};let g;const d=[...i],f=this.convertTagsToTypeKeyMap(e,t,r,p),m=(e,t,r)=>{f.set(e,{maxCount:t,minCount:r,_type:e,_tag:e,_seenCount:0})};var T,h,b;T=a.PropertyTag.internalComment,h=n.Count.infinity,b=0,f.set(`${l.TypeKey.Property}:${T}`,{maxCount:h,minCount:b,_type:o.BitTagType.property,_tag:s.Tag.tag_property,_seenCount:0}),t===l.BitContentLevel.Bit?(u&&m(l.TypeKey.CardSet,1,0),m(l.TypeKey.TextFormat,1,0),m(l.TypeKey.BodyText,n.Count.infinity,0),m(l.TypeKey.BodyTextPlain,n.Count.infinity,0),m(l.TypeKey.PlainTextDivider,n.Count.infinity,0),m(l.TypeKey.FooterDivider,n.Count.infinity,0)):t===l.BitContentLevel.Card&&m(l.TypeKey.CardText,n.Count.infinity,0);for(let i=0;i<d.length;i++){const o=d[i];if(!o)continue;const{type:n,key:a}=o,s=l.TypeKey.fromValue(n);if(!s)continue;let p=s;s!==l.TypeKey.Property&&s!==l.TypeKey.Resource||(p=`${s}:${a}`);const m=f.get(p),{validated:T,warning:h}=this.validateSingleTag(e,t,r,o,s,m,u);s===l.TypeKey.Resource&&(c=l.TypeKey.Resource);let b=!0;if(!T)if(t===l.BitContentLevel.Chain&&c!==l.TypeKey.Resource){g=o;const e=d.slice(i+1);e.length>0&&(g.chain=e),d.splice(i),b=!1}else d.splice(i,1,null);if(h&&b&&e.addWarning(null!==(y=h.warning)&&void 0!==y?y:"",h.content,h.previousContent),t===l.BitContentLevel.Chain&&m&&m.chain&&T&&!T.chain){const e=d.slice(i+1);e.length>0&&(T.chain=e),d.splice(i+1)}if(T&&Array.isArray(T.chain)&&T.chain.length>0)if(m&&m.chain){const{validated:t,remaining:o}=this.validateTagChainsRecursive(e,l.BitContentLevel.Chain,r,T.chain,m.chain,void 0,T.type);t&&t.length>0?T.chain=t:T.chain=void 0,o&&d.splice(i+1,0,o)}else if(T.type!==l.TypeKey.Resource){const e=T.chain[0];T.chain.length>1&&(e.chain=T.chain.slice(1)),d.splice(i+1,0,e),T.chain=void 0}}for(const t of f.values()){const{minCount:r,_seenCount:i}=t;if(null!=r&&i<r){const i=`${this.getTagSignature(t)} is required at least ${r} time(s)`;e.addWarning(i)}}return{validated:d.filter((e=>null!=e)),remaining:g}}validateSingleTag(e,t,r,i,o,n,a){const{type:s,key:p}=i,u=n?this.getTagSignature(n):this.getUnknownTagSignature(s,p),c=" It will be ignored";let y,g,d="";if(n)switch(n._seenCount++,o){case l.TypeKey.Property:{const{content:o,warning:a}=this.validatePropertyTag(e,t,r,n,i);y=o,g=a;break}case l.TypeKey.Resource:{const{content:o,warning:a}=this.validateResourceTag(e,t,r,n,i);y=o,g=a;break}case l.TypeKey.CardSet:{const{content:t,warning:o}=this.validateCardSet(e,r,n,i,a);y=t,g=o;break}default:{const{content:o,warning:a}=this.validateStandardTag(e,t,r,n,i);y=o,g=a}}else switch(o){case l.TypeKey.Property:g={extraProperty:!0},t!==l.BitContentLevel.Chain&&(y=i);break;case l.TypeKey.Resource:g={excessResource:!0},y=i;break;default:g={invalid:!0}}if(g){const e=null==n?void 0:n._previous;g.invalid||g.excessResource?d=`${u} is not valid here (incorrectly chained?).${c}`:null!=g.tooMany?(d=`${u} is included more than ${g.tooMany} time(s).`,g.tooMany>0&&(d+=" The earlier ones will be ignored")):g.extraProperty?d=`${u} is an unknown property. It can be excluded from the output using the 'excludeUnknownProperties' flag`:g.unexpectedCardSet?d=`${u} is not expected here.${c}`:g.unexpectedCardSideVariant&&(d=`${u} has a card / side / variant that is not expected here.${c}`),g.warning=d,g.content=y,g.previousContent=e}return n&&(n._previous=i),{validated:y,warning:g}}validateStandardTag(e,t,r,i,o){const a=null==i.maxCount?1:i.maxCount;return a!==n.Count.infinity&&i._seenCount>a?{warning:{tooMany:a},content:o}:{content:o}}validatePropertyTag(e,t,r,i,o){const a=null==i.maxCount?1:i.maxCount;return a!==n.Count.infinity&&i._seenCount>a?{warning:{tooMany:a},content:o}:{content:o}}validateResourceTag(e,t,r,i,o){const a=null==i.maxCount?1:i.maxCount;return a!==n.Count.infinity&&i._seenCount>a?{warning:{tooMany:a},content:o}:{content:o}}validateCardSet(e,t,r,i,o){if(!o||!o.variants||0===o.variants.length)return{warning:{unexpectedCardSet:!0}};const{value:n}=i,a=n;let s,p=0,u=0;for(const r of a.cards){p=0;for(const i of r.sides){u=0;for(const r of i.variants){const n=r.content;let a;const c=this.getVariantConfig(o.variants,p,u);if(c){a=this.validateTagChainsRecursive(e,l.BitContentLevel.Card,t,n,c.tags).validated}else s={unexpectedCardSideVariant:!0};a&&a.length>0?i.variants[u]={parser:r.parser,content:a}:i.variants[u]={parser:r.parser,content:[]},u++}p++}}return{content:i,warning:s}}checkBodyForCommonPotentialMistakes(e,t,r){if(!r)return;const{bitType:i}=e;for(const t of p)r.includes(t)&&e.addWarning(`Bit '${i}' might contain a mistake: ${t}`);for(const t of u)r.startsWith(t)&&e.addWarning(`Bit '${i}' might contain a mistake: ${t}`);for(const t of c)r.endsWith(t)&&e.addWarning(`Bit '${i}' might contain a mistake: ${t}`)}convertTagsToTypeKeyMap(e,t,r,i){const n=new Map;for(const e of Object.values(i)){const t={minCount:e.minCount,maxCount:e.maxCount,isTag:e.type===o.BitTagType.tag,isProperty:e.type===o.BitTagType.property,isResource:e.type===o.BitTagType.resource,chain:e.chain,_configKey:e.configKey,_type:e.type,_tag:e.tag,_seenCount:0,_previous:void 0};if(t.isProperty)n.set(`${l.TypeKey.Property}:${e.tag}`,t);else if(t.isResource)n.set(`${l.TypeKey.Resource}:${e.tag}`,t);else{const r=l.TypeKey.fromValue(e.tag);r&&n.set(r,t)}}return n}getVariantConfig(e,t,r){let i;if(0===e.length)return;const o=e[Math.min(t,e.length-1)],a=o.length-1;if(r>a){if(i=o[a],i.repeatCount!==n.Count.infinity)return}else i=o[r];return i}getTagSignature(e){switch(e._type){case o.BitTagType.tag:return`[${e._tag}]`;case o.BitTagType.property:return`[@${e._tag}]`;case o.BitTagType.resource:return`[&${e._tag}]`;default:return`'${e._type}' tag '${e._tag}'`}}getUnknownTagSignature(e,t){switch(e){case l.TypeKey.Property:return`[@${t}]`;case l.TypeKey.Resource:return`[&${t}]`;default:return t?`'${e}' tag '${t}'`:`'${e}' tag`}}};t.BitmarkPegParserValidator=y},4382:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.FooterContentProcessor=void 0;const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(777),l=r(4266),p=r(6128),u=new s.TextParser;const c=new class{process(e,t,r,s,c,y){const{textFormat:g}=e;let d;c=c.trimStart(),y=y.trimEnd();const f=!!c.trim(),m=!!y.trim();let T=0;if(f&&m&&(T=a.StringUtils.countOccurrencesAtEnd(c,"\n")+a.StringUtils.countOccurrencesAtStart(y,"\n")),c||y){const r=g===o.TextFormat.bitmarkMinusMinus||g===o.TextFormat.bitmarkPlusPlus;c&&(c=l.BitmarkPegParserValidator.checkFooter(e,t,c));const a=r?u.toAst(c,{textFormat:g,isProperty:!1}):i.Breakscape.unbreakscape(c,{textFormat:o.TextFormat.text,textLocation:n.TextLocation.body}),s=i.Breakscape.unbreakscape(y,{textFormat:o.TextFormat.text,textLocation:n.TextLocation.body});d=p.ContentProcessorUtils.concatenatePlainTextWithAstTexts(a,T,s)}return d?{footer:d}:void 0}};t.FooterContentProcessor=c},4402:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.defaultTagContentProcessor=function(e,t,r,p,u){const{type:c,value:y}=p,{textFormat:g}=e,d=new s.TextParser,f=a.StringUtils.trimmedString(y);switch(c){case l.TypeKey.Instruction:u.instruction=d.toAst(f,{textFormat:g,isProperty:!0}),u.__instructionString=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.Hint:u.hint=d.toAst(f,{textFormat:g,isProperty:!0}),u.__hintString=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.Anchor:u.anchor=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.Reference:u.reference=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag});break;case l.TypeKey.SampleSolution:u.sampleSolution=i.Breakscape.unbreakscape(f,{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}),u.__sampleSolutionAst=d.toAst(f,{textFormat:g,isProperty:!0}),e.addWarning("[$...] tag is deprecated, use [@sampleSolution:...] instead",p)}};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(777),l=r(3029)},4410:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BodyBitType=void 0;const i=(0,r(4718).superenum)({text:"text",gap:"gap",mark:"mark",select:"select",highlight:"highlight"});t.BodyBitType=i},4445:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ConfigHydrator=void 0;const i=r(5814),o=r(9371),n=r(9788),a=r(1519),s=r(9600),l=r(5591),p=r(7112),u=r(9888),c=r(5051),y=r(7797),g=r(5512),d=r(5554),f=r(5837),m=r(9916),T=r(168),h=r(9248);const b=new class{hydrateTagsConfig(e){var t;const r={tags:{}};for(const i of e){let e;switch(i.type){case g.BitTagType.tag:e=this.hydrateTagConfig(i);break;case g.BitTagType.property:e=this.hydratePropertyTagConfig(i);break;case g.BitTagType.resource:e=this.hydrateResourceTagConfig(i);break;case g.BitTagType.group:e=this.hydrateTagGroupConfig(i)}e&&(r.tags=Object.assign(Object.assign({},r.tags),e.tags),r.info=Object.assign(null!==(t=r.info)&&void 0!==t?t:{},e.info))}return r}hydrateCardSetConfig(e){if(!e)return;const t=d.CARDS[e];if(!t)throw new Error(`No config found for card set config key '${e}'`);const r=[];for(const e of t.variants){const t=[];for(const r of e){const e=this.hydrateCardVariantConfig(r);t.push(e)}r.push(t)}return new i.CardSetConfig(e,r)}hydrateTagConfig(e){const{configKey:t,maxCount:r,minCount:i,chain:o}=e,a=y.TagConfigKey.fromKey(t)||l.ConfigKey._unknown,s=h.TAGS[a];if(!s)throw new Error(`No config found for tag config key '${t}'`);const{tag:p,deprecated:u}=s;let c;o&&(c=this.hydrateTagsConfig(o).tags);const g=new n.MarkupTagConfig(a,p,null!=r?r:1,null!=i?i:0,c,u);return{tags:{[a]:g}}}hydratePropertyTagConfig(e){const{configKey:t,maxCount:r,minCount:i,chain:o}=e,n=u.PropertyConfigKey.fromKey(t)||l.ConfigKey._unknown,s=m.PROPERTIES[n];if(!s)throw new Error(`No config found for property config key '${t}'`);const{tag:p,deprecated:c,single:y,format:g,defaultValue:d,jsonKey:f,astKey:T}=s;let h;o&&(h=this.hydrateTagsConfig(o).tags);const b=new a.PropertyTagConfig(n,p,null!=r?r:1,null!=i?i:0,h,f,T,y,g,d,c);return{tags:{[n]:b}}}hydrateResourceTagConfig(e){const{configKey:t,maxCount:r,minCount:i,chain:o}=e,n=c.ResourceConfigKey.fromKey(t)||l.ConfigKey._unknown,a=T.RESOURCES[n];if(!a)throw new Error(`No config found for resource config key '${t}'`);const{tag:p,deprecated:u,jsonKey:y}=a;let g;o&&(g=this.hydrateTagsConfig(o).tags);const d=new s.ResourceTagConfig(n,p,null!=r?r:1,null!=i?i:0,g,y,u);return{tags:{[n]:d}}}hydrateTagGroupConfig(e){var t,r;const{configKey:i}=e,o=p.GroupConfigKey.fromKey(i)||l.ConfigKey._unknown,n=f.GROUPS[o];if(!n)throw new Error(`No config found for group config key '${i}'`);const{tags:a}=n,s=this.hydrateTagsConfig(a).tags,u=Object.values(s);if(u.length>0){const i=u[0],o=i;o.maxCount=null!==(t=e.maxCount)&&void 0!==t?t:i.maxCount,o.minCount=null!==(r=e.minCount)&&void 0!==r?r:i.minCount}return{tags:s,info:{comboResourceType:n.comboResourceType}}}hydrateCardVariantConfig(e){const{tags:t,bodyAllowed:r,bodyRequired:i,repeatCount:n}=e,a=this.hydrateTagsConfig(t);return new o.CardVariantConfig(a.tags,r,i,n)}};t.ConfigHydrator=b},4470:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BaseBuilder=void 0;const i=r(7735),o=r(2028),n=r(431),a=r(9727),s=r(6877),l=r(777),p=r(6989),u=r(4078),c=r(8025),y=r(9681);t.BaseBuilder=class{constructor(){this.textParser=new l.TextParser,this.textGenerator=new n.TextGenerator}toExample(e,t,r){if(null!=t){let e;return e=u.BooleanUtils.isBoolean(r)?u.BooleanUtils.toBoolean(t):t,{isExample:!0,example:e,__defaultExample:null!=r?r:null}}return e?{isExample:!0,example:null!=r?r:null,__defaultExample:null!=r?r:null}:{isExample:!1,example:null,__defaultExample:null!=r?r:null}}toAstProperty(e,t){if(null==t)return;const r=o.Config.getRawPropertiesConfig()[e],i=e=>{if(null!=e){switch(r.format){case a.PropertyFormat.trimmedString:return null!=c.NumberUtils.asNumber(e)&&(e=`${e}`),y.StringUtils.isString(e)?y.StringUtils.trimmedString(e):void 0;case a.PropertyFormat.number:return c.NumberUtils.asNumber(e);case a.PropertyFormat.boolean:return u.BooleanUtils.toBoolean(e,!0);case a.PropertyFormat.invertedBoolean:return!u.BooleanUtils.toBoolean(e,!0)}return e}};if(Array.isArray(t)){const e=t;for(let t=0,r=e.length;t<r;t++)e[t]=i(e[t])}else t=i(t);return p.ArrayUtils.asArray(t)}getEmptyTextAst(e){return this.handleJsonText(e,!0," ")}handleJsonText(e,t,r){let o;const{textFormat:n}=e,a=t?s.TextLocation.tag:s.TextLocation.body;if(null==r)o=[];else if(this.textParser.isAst(r))o=r;else{if(Array.isArray(r)){const e=[];for(let o=0,s=r.length;o<s;o++){const s=r[o];this.textParser.isAst(s)?e[o]=s:y.StringUtils.isString(s)?(e[o]=this.textParser.toAst(i.Breakscape.breakscape(s,{textFormat:n,textLocation:a}),{textFormat:n,isProperty:t}),e[o].__tag="text"):e[o]=[]}return e}o=y.StringUtils.isString(r)?this.textParser.toAst(i.Breakscape.breakscape(r,{textFormat:n,textLocation:a,v2:!0}),{textFormat:n,isProperty:t}):[]}return o.__tag="text",o}}},4475:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.technicalTermChainContentProcessor=function(e,t,r,l,p){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("technicalTerm content",l);const u=e.bitContentProcessor(s.BitContentLevel.Chain,r,l.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("technicalTerm TAGS",u);const{lang:c}=u,y={technicalTerm:i.Breakscape.unbreakscape(a.StringUtils.trimmedString(l.value),{textFormat:o.TextFormat.bitmarkMinusMinus,textLocation:n.TextLocation.tag}),lang:c};p.technicalTerm=y};const i=r(7735),o=r(385),n=r(6877),a=r(9681),s=r(3029)},4564:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.NodeValidator=void 0;const i=r(6149),o=r(9681);const n=new class{validateBit(e){if(!e)return e;return e}validateCardBit(e){if(!e)return e;return e}validateResource(e){if(!e)return;let t=e,r=!1;switch(e.type){case i.ResourceTag.image:r=!!e.image.src;break;case i.ResourceTag.imageLink:r=!!e.imageLink.url;break;case i.ResourceTag.audio:r=!!e.audio.src;break;case i.ResourceTag.audioEmbed:r=!!e.audioEmbed.src;break;case i.ResourceTag.audioLink:r=!!e.audioLink.url;break;case i.ResourceTag.video:r=!!e.video.src;break;case i.ResourceTag.videoEmbed:r=!!e.videoEmbed.url;break;case i.ResourceTag.videoLink:r=!!e.videoLink.url;break;case i.ResourceTag.stillImageFilm:r=!!e.image.src&&!!e.audio.src;break;case i.ResourceTag.stillImageFilmEmbed:r=!!e.stillImageFilmEmbed.url;break;case i.ResourceTag.stillImageFilmLink:r=!!e.stillImageFilmLink.url;break;case i.ResourceTag.article:r=!!e.article.body;break;case i.ResourceTag.document:r=!!e.document.url;break;case i.ResourceTag.documentEmbed:r=!!e.documentEmbed.url;break;case i.ResourceTag.documentLink:r=!!e.documentLink.url;break;case i.ResourceTag.documentDownload:r=!!e.documentDownload.url;break;case i.ResourceTag.appLink:r=!!e.appLink.url;break;case i.ResourceTag.websiteLink:r=!!e.websiteLink.url;break;default:r=!1}return r||e.type&&(t={type:e.type}),t}isRequired(e,t){if(!e)throw new Error(`${t} is required but is not set`)}isOneOfRequired(e,t){if(Array.isArray(e))for(const t of e)if(t)return;throw new Error(`One of '${t.join(", ")}' is required but none is set`)}isString(e,t){if(!o.StringUtils.isString(e))throw new Error(`${t} is required to be a string`)}isNonEmptyString(e,t){if(!o.StringUtils.isString(e)||""===e)throw new Error(`${t} is required to be a non-empty string`)}isStringOrBoolean(e,t){if(!o.StringUtils.isString(e)&&!0!==e&&!1!==e)throw new Error(`${t} is required to be a string or a boolean`)}isNonEmptyStringOrBoolean(e,t){if((!o.StringUtils.isString(e)||""===e)&&!0!==e&&!1!==e)throw new Error(`${t} is required to be a non-empty string or a boolean`)}isArray(e,t){if(!Array.isArray(e))throw new Error(`${t} is required to be a array`)}isNonEmptyArray(e,t){if(!(Array.isArray(e)&&e.length>0))throw new Error(`${t} is required to be a non-empty array`)}isNumber(e,t){if(!Number.isFinite(e))throw new Error(`${t} is required to be a number`)}isBoolean(e,t){if(!0!==e&&!1!==e)throw new Error(`${t} is required to be a boolean`)}isStringOrNumberOrBooleanOrNullOrUndefined(e,t){if(!o.StringUtils.isString(e)&&!Number.isFinite(e)&&!0!==e&&!1!==e&&null!=e)throw new Error(`${t} is required to be a string or a number or a boolean or null or undefined`)}};t.NodeValidator=n},4718:(e,t,r)=>{function i(e,t){var r;const i=Object.freeze,o=Object.defineProperty,n=Object.assign,a={enumerable:!1},s=new Map,l=new Map,p=new Map,u=new Map,c=new Map,y=(null!==(r=null==t?void 0:t.iterationKeys)&&void 0!==r?r:Object.keys(e)).map((e=>`${e}`));for(const[t,r]of Object.entries(e))s.set(t,r),p.set(t.toLowerCase(),r);for(const[e,t]of s){const r="string"==typeof t?t.toLowerCase():t;l.set(t,e),u.set(r,e)}const g=y.map((e=>s.get(e))),d=y.map((e=>[e,s.get(e)]));return(t=>{let r=e;function f(e,t){return(null==t?void 0:t.ignoreCase)&&"string"==typeof e?s.get(u.get(e.toLowerCase())):l.has(e)?e:void 0}Object.isExtensible(e)||(r=n({},e)),o(r,"fromKey",n({value:function(e,t){return(null==t?void 0:t.ignoreCase)&&"string"==typeof e?p.get(e.toLowerCase()):s.get(`${e}`)}},a)),o(r,"fromValue",n({value:f},a)),o(r,"keyFromValue",n({value:function(e,t){return(null==t?void 0:t.ignoreCase)&&"string"==typeof e?u.get(e.toLowerCase()):l.get(e)}},a)),o(r,"setMetadata",n({value:function(e,t,r){const i=f(e);null!=i&&c.set(i,t)}},a)),o(r,"getMetadata",n({value:function(e,t){return c.get(e)}},a)),o(r,Symbol.iterator,n({value:function(){let e=0;return{next:()=>e<y.length?{value:s.get(`${y[e++]}`),done:!1}:{done:!0}}}},a)),o(r,"values",n({value:()=>g},a)),o(r,"keys",n({value:()=>y},a)),o(r,"entries",n({value:()=>d},a));let m=r;return(null==t?void 0:t.noFreeze)||(m=i(r),i(y),i(g),i(d)),m})(t)}r.r(t),r.d(t,{superenum:()=>o});const o=i;o.fromObject=i,o.fromArray=function(e,t){Array.isArray(e)||(e=[]);const r=e.reduce(((e,t)=>(e[`${t}`]=t,e)),{});return(!t||t&&!t.iterationKeys)&&((t=Object.assign({},t)).iterationKeys=e),i(r,t)}},4953:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.servingsChainContentProcessor=function(e,t,r,n,a){var s;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("servings content",n);const l=e.bitContentProcessor(o.BitContentLevel.Chain,r,n.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("servings TAGS",l);const{unit:p,unitAbbr:u,decimalPlaces:c,disableCalculation:y,__hintString:g}=l,d={servings:null!==(s=i.NumberUtils.asNumber(n.value))&&void 0!==s?s:1,unit:p,unitAbbr:u,decimalPlaces:null!=c?c:1,disableCalculation:y,hint:g};a.servings=d};const i=r(8025),o=r(3029)},5005:(e,t,r)=>{const{VOID:i,PRIMITIVE:o,ARRAY:n,OBJECT:a,DATE:s,REGEXP:l,MAP:p,SET:u,ERROR:c,BIGINT:y}=r(1731),g="object"==typeof self?self:globalThis;t.deserialize=e=>((e,t)=>{const r=(t,r)=>(e.set(r,t),t),d=f=>{if(e.has(f))return e.get(f);const[m,T]=t[f];switch(m){case o:case i:return r(T,f);case n:{const e=r([],f);for(const t of T)e.push(d(t));return e}case a:{const e=r({},f);for(const[t,r]of T)e[d(t)]=d(r);return e}case s:return r(new Date(T),f);case l:{const{source:e,flags:t}=T;return r(new RegExp(e,t),f)}case p:{const e=r(new Map,f);for(const[t,r]of T)e.set(d(t),d(r));return e}case u:{const e=r(new Set,f);for(const t of T)e.add(d(t));return e}case c:{const{name:e,message:t}=T;return r(new g[e](t),f)}case y:return r(BigInt(T),f);case"BigInt":return r(Object(BigInt(T)),f);case"ArrayBuffer":return r(new Uint8Array(T).buffer,T);case"DataView":{const{buffer:e}=new Uint8Array(T);return r(new DataView(e),T)}}return r(new g[m](T),f)};return d})(new Map,e)(0)},5033:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BodyContentProcessor=void 0;const i=r(7735),o=r(4410),n=r(385),a=r(6877),s=r(9681),l=r(777),p=r(4266),u=r(6128),c=new l.TextParser;const y=new class{process(e,t,r,l,y,g,d,f){const m=[];let T,h;const b=d.length>0?this.trimBodyParts(d):void 0,B=f?b:p.BitmarkPegParserValidator.checkBody(e,t,r,l,b);if(l===n.TextFormat.json&&B){T=B.reduce(((e,t)=>{var r;if(t.type===o.BodyBitType.text&&t.data){return e+(null!==(r=t.data.bodyText)&&void 0!==r?r:"")}return e}),"");try{T=JSON.parse(T)}catch(t){T=null,e.addError("Body JSON is invalid.")}}else{let e="",t="",r="",p=0;const y=e=>`[!${e}]`;if(B)for(let n=0;n<B.length;n++){const a=B[n];if(a.type===o.BodyBitType.text){const o=a,n=o.data.bodyText;o.data.isPlain?t=i.Breakscape.concatenate(t,n):e=i.Breakscape.concatenate(e,n),r=i.Breakscape.concatenate(r,n)}else{const t=y(p);e=i.Breakscape.concatenate(e,t),m.push(a),p++}}const g=l===n.TextFormat.bitmarkMinusMinus||l===n.TextFormat.bitmarkPlusPlus?c.toAst(e,{textFormat:l,isProperty:!1}):i.Breakscape.unbreakscape(e,{textFormat:n.TextFormat.text,textLocation:a.TextLocation.body}),d=i.Breakscape.unbreakscape(t,{textFormat:n.TextFormat.text,textLocation:a.TextLocation.body}),f=s.StringUtils.countOccurrencesAtEnd(e,"\n")+s.StringUtils.countOccurrencesAtStart(t,"\n");T=u.ContentProcessorUtils.concatenatePlainTextWithAstTexts(g,f,d),h=i.Breakscape.unbreakscape(r,{textFormat:l,textLocation:a.TextLocation.body}).trim();const b=Array.isArray(T)?T:void 0;if(b&&B){p=0;for(let e=0;e<B.length;e++){const t=B[e];if(t.type===o.BodyBitType.text)continue;const r=t;let i;switch(t.type){case o.BodyBitType.gap:case o.BodyBitType.mark:case o.BodyBitType.select:case o.BodyBitType.highlight:i=r}i&&this.replacePlaceholderWithBodyBit(b,i,p),p++}}}return{body:T,bodyBits:m.length>0?m:void 0,bodyString:h}}buildBodyText(e,t){return{type:o.BodyBitType.text,data:{bodyText:e,isPlain:t}}}replacePlaceholderWithBodyBit(e,t,r){const i=(e,o,n)=>{if(Array.isArray(e))for(let t=0;t<e.length;t++){const r=e[t];if(i(r,e,t))return!0}else{if("bit"===e.type&&e.index===r)return o[n]=t,!0;if(e.content){if(i(e.content,e,"content"))return!0}}return!1};i(e,null,null)}trimBodyParts(e){let t=!1,r=e.reduce(((e,r)=>{const i=r;if(t||i.type!==o.BodyBitType.text)t=!0,e.push(r);else{const r=i.data.bodyText.trimStart();r&&(t=!0,i.data.bodyText=r,e.push(i))}return e}),[]);return t=!1,r=r.reduceRight(((e,r)=>{const i=r;if(t||i.type!==o.BodyBitType.text)t=!0,e.unshift(r);else{const r=i.data.bodyText.trimEnd();r&&(t=!0,i.data.bodyText=r,e.unshift(i))}return e}),[]),r}};t.BodyContentProcessor=y},5051:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.resourceConfigKeys=t.ResourceConfigKey=void 0;const i=r(4718),o={icon:"icon",image:"image",imagePortrait:"imagePortrait",imageLandscape:"imageLandscape",imageEmbed:"imageEmbed",imageLink:"imageLink",audio:"audio",audioEmbed:"audioEmbed",audioLink:"audioLink",video:"video",videoEmbed:"videoEmbed",videoLink:"videoLink",stillImageFilmEmbed:"stillImageFilmEmbed",stillImageFilmLink:"stillImageFilmLink",article:"article",articleEmbed:"articleEmbed",articleLink:"articleLink",document:"document",documentEmbed:"documentEmbed",documentLink:"documentLink",documentDownload:"documentDownload",appLink:"appLink",websiteLink:"websiteLink"};t.resourceConfigKeys=o;const n=(0,i.superenum)(o);t.ResourceConfigKey=n},5057:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.StartRules=void 0,t.SyntaxError=a,t.parse=function e(t,r){r=void 0!==r?r:{};var s,l={},p=r.grammarSource,u={bitmark:nr,bit:function(){var e,t,r,i,o;e=Jt,t=[],r=Ar();for(;r!==l;)t.push(r),r=Ar();if((r=lr())!==l){for(i=[],o=Ar();o!==l;)i.push(o),o=Ar();Wt=e,e=Xe(r)}else Jt=e,e=l;return e},cardContent:function(){var e,t,r;e=Jt,t=[],(r=yr())===l&&(r=Cr());for(;r!==l;)t.push(r),(r=yr())===l&&(r=Cr());return Wt=e,t=Pt(t),e=t}},c=nr,y="[.",g="]",d="[",f=":",m="&",T="$$$$",h="====",b="text",B="~~~~",v="footer",C="--",P="++",x="===",k="==",K="[@id",w="#",_="[▼",S="[►",A="[@",L="[%",I="[!",F="[?",N="[+",O="[-",E="[$",R="[_",V="[=",j="[&",M="^]",D="id:",G=".",U="\n",$="\r\n",J=/^[^\]]/,W=/^[^:\]]/,z=/^[^&:\]]/,q=/^[ \t]/,H=/^[^\n\r\u2028\u2029]/,Y=/^[\r\u2028-\u2029]/,X=/^[ \t\n\r\u2028\u2029]/,Q=Qt("[.",!1),Z=Zt(["]"],!0,!1),ee=Qt("]",!1),te=Qt("[",!1),re=Qt(":",!1),ie=Qt("&",!1),oe={type:"any"},ne=Qt("$$$$",!1),ae=Qt("====",!1),se=Qt("text",!1),le=Qt("~~~~",!1),pe=Qt("footer",!1),ue=Qt("--",!1),ce=Qt("++",!1),ye=Qt("===",!1),ge=Qt("==",!1),de=Qt("[@id",!1),fe=Qt("#",!1),me=Qt("[▼",!1),Te=Qt("[►",!1),he=Qt("[@",!1),be=Qt("[%",!1),Be=Qt("[!",!1),ve=Qt("[?",!1),Ce=Qt("[+",!1),Pe=Qt("[-",!1),xe=Qt("[$",!1),ke=Qt("[_",!1),Ke=Qt("[=",!1),we=Qt("[&",!1),_e=Qt("^]",!1),Se=Qt("id:",!1),Ae=Zt([":","]"],!0,!1),Le=Qt(".",!1),Ie=Zt(["&",":","]"],!0,!1),Fe=(er("Empty"),Zt([" ","\t"],!1,!1)),Ne=er("Anything"),Oe=er("Character"),Ee=Zt(["\n","\r","\u2028","\u2029"],!0,!1),Re=er("Line"),Ve=(er("whitespace in line"),er("Blank Line")),je=er("Line Terminator"),Me=Qt("\n",!1),De=Qt("\r\n",!1),Ge=Zt(["\r",["\u2028","\u2029"]],!1,!1),Ue=er("Whitespace, then Line Terminator"),$e=er("whitespace"),Je=Zt([" ","\t","\n","\r","\u2028","\u2029"],!1,!1),We=function(e,t){return Vr.buildBits([e,...t])},ze=function(e){return Rr.handleRawBit(e)},qe=function(e){return e},He=function(e){return Rr.handleRawBit(e)},Ye=function(e){return e},Xe=function(e){return e},Qe=function(e,t){return Vr.buildBit(e,t)},Ze=function(e){return Vr.invalidBit(e)},et=function(e,t,r){return Vr.buildBitHeader(t,e,r)},tt=function(e,t){return Vr.buildTextAndResourceType(e,t)},rt=function(e){return Rr.handleTextFormat(e)},it=function(e){return Rr.handleResourceType(e)},ot=function(e){return Rr.handleBitContent(e)},nt=function(e){return Rr.handleTagChain(e)},at=function(e){return e},st=function(e){return Rr.handleBitTag(e)},lt=function(e){return{type:i.TypeKey.BodyChar,value:e}},pt=function(e){return Rr.handlePlainTextDivider(e)},ut=function(e){return Rr.handleFooterDivider(e)},ct=function(e){return Rr.handleCardSet(e[1].flat())},yt=function(){Rr.handleCardSetStart()},gt=function(){Rr.handleCardSetEnd()},dt=function(e){return Rr.handleCards(e)},ft=function(e){return Rr.handleCardLineOrDivider(e,2)},mt=function(e){return Rr.handleCardLine(e)},Tt=function(e){return Rr.handleCardSet(e[1].flat())},ht=function(){Rr.handleCardSetStart()},bt=function(){Rr.handleCardSetEnd()},Bt=function(e){return Rr.handleCards(e)},vt=function(e){return Rr.handleCardLineOrDivider(e,1)},Ct=function(e){return Rr.handleCardLine(e)},Pt=function(e){return Rr.handleCardContent(e)},xt=function(e){return{type:i.TypeKey.CardChar,value:e}},kt=function(e){return Rr.handlePropertyTag("id",e)},Kt=function(e,t){return Rr.handleTag(i.TypeKey.Title,{level:e,title:t})},wt=function(e){return Rr.handleTag(i.TypeKey.Anchor,e)},_t=function(e){return Rr.handleTag(i.TypeKey.Reference,e)},St=function(e,t){return Rr.handlePropertyTag(e,t)},At=function(e){return Rr.handleTag(i.TypeKey.ItemLead,e)},Lt=function(e){return Rr.handleTag(i.TypeKey.Instruction,e)},It=function(e){return Rr.handleTag(i.TypeKey.Hint,e)},Ft=function(e){return Rr.handleTag(i.TypeKey.True,e)},Nt=function(e){return Rr.handleTag(i.TypeKey.False,e)},Ot=function(e){return Rr.handleTag(i.TypeKey.SampleSolution,e)},Et=function(e){return Rr.handleTag(i.TypeKey.Gap,e)},Rt=function(e){return Rr.handleTag(i.TypeKey.Mark,e)},Vt=function(e,t){return Rr.handleResourceTag(e,t)},jt=function(e){return e},Mt=function(e){return e?e.trim():""},Dt=function(e){return e.length},Gt=function(e){return e?e.trim():null},Ut=function(e){return e?e.trim():""},$t=function(){return!0},Jt=0|r.peg$currPos,Wt=Jt,zt=[{line:1,column:1}],qt=Jt,Ht=r.peg$maxFailExpected||[],Yt=0|r.peg$silentFails;if(r.startRule){if(!(r.startRule in u))throw new Error("Can't start parsing from rule \""+r.startRule+'".');c=u[r.startRule]}function Xt(){return t.substring(Wt,Jt)}function Qt(e,t){return{type:"literal",text:e,ignoreCase:t}}function Zt(e,t,r){return{type:"class",parts:e,inverted:t,ignoreCase:r}}function er(e){return{type:"other",description:e}}function tr(e){var r,i=zt[e];if(i)return i;if(e>=zt.length)r=zt.length-1;else for(r=e;!zt[--r];);for(i={line:(i=zt[r]).line,column:i.column};r<e;)10===t.charCodeAt(r)?(i.line++,i.column=1):i.column++,r++;return zt[e]=i,i}function rr(e,t,r){var i=tr(e),o=tr(t),n={source:p,start:{offset:e,line:i.line,column:i.column},end:{offset:t,line:o.line,column:o.column}};return r&&p&&"function"==typeof p.offset&&(n.start=p.offset(n.start),n.end=p.offset(n.end)),n}function ir(e){Jt<qt||(Jt>qt&&(qt=Jt,Ht=[]),Ht.push(e))}function or(e,t,r){return new a(a.buildMessage(e,t),e,t,r)}function nr(){return function(){var e,r,i,o;e=Jt,r=[],i=Fr();for(;i!==l;)r.push(i),i=Fr();return i=function(){var e,r,i,o;e=Jt,r=Jt,i=[],o=sr();for(;o!==l;)i.push(o),o=sr();return r=t.substring(r,Jt),Wt=e,r=ze(r),e=r,e}(),o=function(){var e,t;e=[],t=ar();for(;t!==l;)e.push(t),t=ar();return e}(),Wt=e,e=We(i,o),e}()}function ar(){var e,r,i,o;for(e=Jt,r=[],i=Ar();i!==l;)r.push(i),i=Ar();return(i=Lr())===l&&(i=null),o=function(){var e,r,i,o,n,a;if(e=Jt,r=Jt,i=Jt,o=function(){var e,r,i,o;e=Jt,t.substr(Jt,2)===y?(r=y,Jt+=2):(r=l,0===Yt&&ir(Q));if(r!==l){for(i=[],o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z));o!==l;)i.push(o),o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z));93===t.charCodeAt(Jt)?(o=g,Jt++):(o=l,0===Yt&&ir(ee)),o!==l?(Wt=e,e=Ye(r)):(Jt=e,e=l)}else Jt=e,e=l;return e}(),o!==l){for(n=[],a=sr();a!==l;)n.push(a),a=sr();i=o=[o,n]}else Jt=i,i=l;r=i!==l?t.substring(r,Jt):i;r!==l&&(Wt=e,r=He(r));return e=r,e}(),o!==l?(Wt=e,e=qe(o)):(Jt=e,e=l),e}function sr(){var e,t,r,i;if(e=Jt,(t=Lr())!==l?(r=Jt,Yt++,i=pr(),Yt--,i===l?r=void 0:(Jt=r,r=l),r!==l?e=t=[t,r]:(Jt=e,e=l)):(Jt=e,e=l),e===l)if(e=[],(t=_r())!==l)for(;t!==l;)e.push(t),t=_r();else e=l;return e}function lr(){var e,r,i;return e=Jt,(r=pr())!==l?(i=function(){var e,t,r;e=Jt,t=[],r=mr(),r===l&&(r=hr())===l&&(r=Br())===l&&(r=yr())===l&&(r=fr());for(;r!==l;)t.push(r),(r=mr())===l&&(r=hr())===l&&(r=Br())===l&&(r=yr())===l&&(r=fr());return Wt=e,t=ot(t),e=t,e}(),Wt=e,e=Qe(r,i)):(Jt=e,e=l),e===l&&(e=Jt,r=Jt,i=function(){var e,r;Yt++,e=[],t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe));for(;r!==l;)e.push(r),t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe));Yt--,r=l,0===Yt&&ir(Ne);return e}(),r=t.substring(r,Jt),Wt=e,e=r=Ze(r)),e}function pr(){var e,r,i,o,n,a;return e=Jt,91===t.charCodeAt(Jt)?(r=d,Jt++):(r=l,0===Yt&&ir(te)),r!==l?(i=function(){var e,r,i;e=Jt,r=[],46===t.charCodeAt(Jt)?(i=G,Jt++):(i=l,0===Yt&&ir(Le));if(i!==l)for(;i!==l;)r.push(i),46===t.charCodeAt(Jt)?(i=G,Jt++):(i=l,0===Yt&&ir(Le));else r=l;r!==l&&(Wt=e,r=Dt(r));return e=r,e}(),i!==l?(o=Kr(),n=function(){var e,t,r;e=Jt,t=ur(),t===l&&(t=cr());t===l&&(t=null);r=ur(),r===l&&(r=cr());r===l&&(r=null);return Wt=e,e=tt(t,r),e}(),93===t.charCodeAt(Jt)?(a=g,Jt++):(a=l,0===Yt&&ir(ee)),a!==l?(Wt=e,e=et(i,o,n)):(Jt=e,e=l)):(Jt=e,e=l)):(Jt=e,e=l),e}function ur(){var e,r,i;return e=Jt,58===t.charCodeAt(Jt)?(r=f,Jt++):(r=l,0===Yt&&ir(re)),r!==l?(i=Kr(),Wt=e,e=rt(i)):(Jt=e,e=l),e}function cr(){var e,r,i;return e=Jt,38===t.charCodeAt(Jt)?(r=m,Jt++):(r=l,0===Yt&&ir(ie)),r!==l?(i=Kr(),Wt=e,e=it(i)):(Jt=e,e=l),e}function yr(){var e,t,r,i,o;if(e=Jt,t=Jt,(r=dr())!==l){for(i=[],o=gr();o!==l;)i.push(o),o=gr();t=r=[r,i]}else Jt=t,t=l;return t!==l&&(Wt=e,t=nt(t)),e=t}function gr(){var e,t;return e=Jt,(t=dr())!==l&&(Wt=e,t=at(t)),e=t}function dr(){var e,r;return e=Jt,r=function(){var e,r,i,o;e=Jt,t.substr(Jt,4)===K?(r=K,Jt+=4):(r=l,0===Yt&&ir(de));r!==l&&(i=wr())!==l?(o=function(){var e;93===t.charCodeAt(Jt)?(e=g,Jt++):(e=l,0===Yt&&ir(ee));return e}(),o!==l?(Wt=e,e=kt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i,o;e=Jt,t.substr(Jt,2)===A?(r=A,Jt+=2):(r=l,0===Yt&&ir(he));r!==l&&(i=xr())!==l&&(o=wr())!==l&&kr()!==l?(Wt=e,e=St(i,o)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i,o;e=Jt,91===t.charCodeAt(Jt)?(r=d,Jt++):(r=l,0===Yt&&ir(te));if(r!==l){if(i=[],35===t.charCodeAt(Jt)?(o=w,Jt++):(o=l,0===Yt&&ir(fe)),o!==l)for(;o!==l;)i.push(o),35===t.charCodeAt(Jt)?(o=w,Jt++):(o=l,0===Yt&&ir(fe));else i=l;i!==l?(o=Pr(),kr()!==l?(Wt=e,e=Kt(i,o)):(Jt=e,e=l)):(Jt=e,e=l)}else Jt=e,e=l;return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===_?(r=_,Jt+=2):(r=l,0===Yt&&ir(me));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=wt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===S?(r=S,Jt+=2):(r=l,0===Yt&&ir(Te));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=_t(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===L?(r=L,Jt+=2):(r=l,0===Yt&&ir(be));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=At(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===I?(r=I,Jt+=2):(r=l,0===Yt&&ir(Be));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Lt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===F?(r=F,Jt+=2):(r=l,0===Yt&&ir(ve));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=It(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===R?(r=R,Jt+=2):(r=l,0===Yt&&ir(ke));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Et(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===V?(r=V,Jt+=2):(r=l,0===Yt&&ir(Ke));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Rt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===E?(r=E,Jt+=2):(r=l,0===Yt&&ir(xe));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Ot(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===N?(r=N,Jt+=2):(r=l,0===Yt&&ir(Ce));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Ft(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i;e=Jt,t.substr(Jt,2)===O?(r=O,Jt+=2):(r=l,0===Yt&&ir(Pe));r!==l?(i=Pr(),kr()!==l?(Wt=e,e=Nt(i)):(Jt=e,e=l)):(Jt=e,e=l);return e}(),r===l&&(r=function(){var e,r,i,o;e=Jt,t.substr(Jt,2)===j?(r=j,Jt+=2):(r=l,0===Yt&&ir(we));r!==l&&(i=xr())!==l&&(o=wr())!==l&&kr()!==l?(Wt=e,e=Vt(i,o)):(Jt=e,e=l);return e}()))))))))))))),r!==l&&(Wt=e,r=st(r)),e=r}function fr(){var e,r;return e=Jt,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),r!==l&&(Wt=e,r=lt(r)),e=r}function mr(){var e;return(e=function(){var e,t,r,i,o;e=Jt,t=Jt,(r=Lr())!==l&&(i=Tr())!==l&&(o=Ir())!==l?t=r=[r,i,o]:(Jt=t,t=l);t!==l&&(Wt=e,t=ut(t));return e=t,e}())===l&&(e=function(){var e,r,i,o,n;e=Jt,r=Jt,(i=Lr())!==l?(o=function(){var e,r,i,o,n,a;t.substr(Jt,4)===T?(e=T,Jt+=4):(e=l,0===Yt&&ir(ne));if(e===l)if(e=Jt,t.substr(Jt,4)===h?(r=h,Jt+=4):(r=l,0===Yt&&ir(ae)),r!==l){if(i=[],(o=Fr())!==l)for(;o!==l;)i.push(o),o=Fr();else i=l;if(i!==l)if(t.substr(Jt,4)===b?(o=b,Jt+=4):(o=l,0===Yt&&ir(se)),o!==l){if(n=[],(a=Fr())!==l)for(;a!==l;)n.push(a),a=Fr();else n=l;n!==l?(t.substr(Jt,4)===h?(a=h,Jt+=4):(a=l,0===Yt&&ir(ae)),a!==l?e=r=[r,i,o,n,a]:(Jt=e,e=l)):(Jt=e,e=l)}else Jt=e,e=l;else Jt=e,e=l}else Jt=e,e=l;return e}(),o!==l&&(n=Ir())!==l?r=i=[i,o,n]:(Jt=r,r=l)):(Jt=r,r=l);r!==l&&(Wt=e,r=pt(r));return e=r,e}()),e}function Tr(){var e,r,i,o,n,a;if(t.substr(Jt,4)===B?(e=B,Jt+=4):(e=l,0===Yt&&ir(le)),e===l)if(e=Jt,t.substr(Jt,4)===h?(r=h,Jt+=4):(r=l,0===Yt&&ir(ae)),r!==l){if(i=[],(o=Fr())!==l)for(;o!==l;)i.push(o),o=Fr();else i=l;if(i!==l)if(t.substr(Jt,6)===v?(o=v,Jt+=6):(o=l,0===Yt&&ir(pe)),o!==l){if(n=[],(a=Fr())!==l)for(;a!==l;)n.push(a),a=Fr();else n=l;n!==l?(t.substr(Jt,4)===h?(a=h,Jt+=4):(a=l,0===Yt&&ir(ae)),a!==l?e=r=[r,i,o,n,a]:(Jt=e,e=l)):(Jt=e,e=l)}else Jt=e,e=l;else Jt=e,e=l}else Jt=e,e=l;return e}function hr(){var e,r,i,o,n;if(e=Jt,r=Jt,i=function(){var e,r,i,o,n,a;e=Jt,r=Lr(),r!==l?(i=Jt,Yt++,o=Jt,t.substr(Jt,4)===h?(n=h,Jt+=4):(n=l,0===Yt&&ir(ae)),n!==l&&(a=Ir())!==l?o=n=[n,a]:(Jt=o,o=l),Yt--,o!==l?(Jt=i,i=void 0):i=l,i!==l?(Wt=e,e=yt()):(Jt=e,e=l)):(Jt=e,e=l);return e}(),i!==l){for(o=[],n=br();n!==l;)o.push(n),n=br();n=function(){var e,t,r,i,o;e=Jt,t=Jt,r=Tr(),r===l&&(r=null);i=Jt,Yt++,o=Or(),Yt--,o!==l?(Jt=i,i=void 0):i=l;i!==l?t=r=[r,i]:(Jt=t,t=l);t!==l&&(Wt=e,t=gt());return e=t,e}(),n!==l?r=i=[i,o,n]:(Jt=r,r=l)}else Jt=r,r=l;return r!==l&&(Wt=e,r=ct(r)),e=r}function br(){var e,r;return e=Jt,r=function(){var e,r,i,o;e=Jt,r=Jt,t.substr(Jt,4)===h?(i=h,Jt+=4):(i=l,0===Yt&&ir(ae));i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l);r===l&&(r=Jt,t.substr(Jt,2)===C?(i=C,Jt+=2):(i=l,0===Yt&&ir(ue)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=Jt,t.substr(Jt,2)===P?(i=P,Jt+=2):(i=l,0===Yt&&ir(ce)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=function(){var e,r,i,o,n,a;e=Jt,r=Jt,Yt++,i=Jt,o=Tr(),o!==l&&(n=Or())!==l?i=o=[o,n]:(Jt=i,i=l);Yt--,i===l?r=void 0:(Jt=r,r=l);if(r!==l){if(i=Jt,o=Jt,n=Sr(),(a=Lr())!==l?o=n=[n,a]:(Jt=o,o=l),o===l){if(o=Jt,n=[],(a=_r())!==l)for(;a!==l;)n.push(a),a=_r();else n=l;n!==l&&(a=Nr())!==l?o=n=[n,a]:(Jt=o,o=l)}(i=o!==l?t.substring(i,Jt):o)!==l?(Wt=e,e=mt(i)):(Jt=e,e=l)}else Jt=e,e=l;return e}())));r!==l&&(Wt=e,r=ft(r));return e=r,e}(),r!==l&&(Wt=e,r=dt(r)),e=r}function Br(){var e,r,i,o,n;if(e=Jt,r=Jt,i=function(){var e,r,i,o,n,a;e=Jt,r=Lr(),r!==l?(i=Jt,Yt++,o=Jt,t.substr(Jt,3)===x?(n=x,Jt+=3):(n=l,0===Yt&&ir(ye)),n!==l&&(a=Ir())!==l?o=n=[n,a]:(Jt=o,o=l),Yt--,o!==l?(Jt=i,i=void 0):i=l,i!==l?(Wt=e,e=ht()):(Jt=e,e=l)):(Jt=e,e=l);return e}(),i!==l){for(o=[],n=vr();n!==l;)o.push(n),n=vr();n=function(){var e,t,r,i,o;e=Jt,t=Jt,r=Tr(),r===l&&(r=null);i=Jt,Yt++,o=Or(),Yt--,o!==l?(Jt=i,i=void 0):i=l;i!==l?t=r=[r,i]:(Jt=t,t=l);t!==l&&(Wt=e,t=bt());return e=t,e}(),n!==l?r=i=[i,o,n]:(Jt=r,r=l)}else Jt=r,r=l;return r!==l&&(Wt=e,r=Tt(r)),e=r}function vr(){var e,r;return e=Jt,r=function(){var e,r,i,o;e=Jt,r=Jt,t.substr(Jt,3)===x?(i=x,Jt+=3):(i=l,0===Yt&&ir(ye));i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l);r===l&&(r=Jt,t.substr(Jt,2)===k?(i=k,Jt+=2):(i=l,0===Yt&&ir(ge)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=Jt,t.substr(Jt,2)===C?(i=C,Jt+=2):(i=l,0===Yt&&ir(ue)),i!==l?((o=Ir())===l&&(o=Or()),o!==l?r=i=[i,o]:(Jt=r,r=l)):(Jt=r,r=l),r===l&&(r=function(){var e,r,i,o,n,a;e=Jt,r=Jt,Yt++,i=Jt,o=Tr(),o!==l&&(n=Or())!==l?i=o=[o,n]:(Jt=i,i=l);Yt--,i===l?r=void 0:(Jt=r,r=l);if(r!==l){if(i=Jt,o=Jt,n=Sr(),(a=Lr())!==l?o=n=[n,a]:(Jt=o,o=l),o===l){if(o=Jt,n=[],(a=_r())!==l)for(;a!==l;)n.push(a),a=_r();else n=l;n!==l&&(a=Nr())!==l?o=n=[n,a]:(Jt=o,o=l)}(i=o!==l?t.substring(i,Jt):o)!==l?(Wt=e,e=Ct(i)):(Jt=e,e=l)}else Jt=e,e=l;return e}())));r!==l&&(Wt=e,r=vt(r));return e=r,e}(),r!==l&&(Wt=e,r=Bt(r)),e=r}function Cr(){var e,r;return e=Jt,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),r!==l&&(Wt=e,r=xt(r)),e=r}function Pr(){var e,r,i,o;for(e=Jt,r=Jt,i=[],t.substr(Jt,2)===M?(o=M,Jt+=2):(o=l,0===Yt&&ir(_e)),o===l&&(o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z)));o!==l;)i.push(o),t.substr(Jt,2)===M?(o=M,Jt+=2):(o=l,0===Yt&&ir(_e)),o===l&&(o=t.charAt(Jt),J.test(o)?Jt++:(o=l,0===Yt&&ir(Z)));return r=t.substring(r,Jt),Wt=e,e=r=jt(r)}function xr(){var e,r,i,o,n;if(e=Jt,r=Jt,Yt++,t.substr(Jt,3)===D?(i=D,Jt+=3):(i=l,0===Yt&&ir(Se)),Yt--,i===l?r=void 0:(Jt=r,r=l),r!==l){for(i=Jt,o=[],n=t.charAt(Jt),W.test(n)?Jt++:(n=l,0===Yt&&ir(Ae));n!==l;)o.push(n),n=t.charAt(Jt),W.test(n)?Jt++:(n=l,0===Yt&&ir(Ae));i=t.substring(i,Jt),Wt=e,e=Mt(i)}else Jt=e,e=l;return e}function kr(){var e,r,i;if(93===t.charCodeAt(Jt)?(e=g,Jt++):(e=l,0===Yt&&ir(ee)),e===l){for(e=Jt,r=[],i=Fr();i!==l;)r.push(i),i=Fr();(i=Er())!==l?e=r=[r,i]:(Jt=e,e=l)}return e}function Kr(){var e,r,i,o;for(e=Jt,r=Jt,i=[],o=t.charAt(Jt),z.test(o)?Jt++:(o=l,0===Yt&&ir(Ie));o!==l;)i.push(o),o=t.charAt(Jt),z.test(o)?Jt++:(o=l,0===Yt&&ir(Ie));return r=t.substring(r,Jt),Wt=e,e=r=Gt(r)}function wr(){var e,r,i;return e=Jt,58===t.charCodeAt(Jt)?(r=f,Jt++):(r=l,0===Yt&&ir(re)),r!==l?(i=Pr(),Wt=e,e=Ut(i)):(Jt=e,e=l),e===l&&(r="",Wt=e=Jt,e=r=$t()),e}function _r(){var e;return Yt++,e=t.charAt(Jt),H.test(e)?Jt++:(e=l,0===Yt&&ir(Ee)),Yt--,e===l&&(0===Yt&&ir(Oe)),e}function Sr(){var e,t;for(Yt++,e=[],t=_r();t!==l;)e.push(t),t=_r();return Yt--,t=l,0===Yt&&ir(Re),e}function Ar(){var e,r,i;for(Yt++,e=Jt,r=[],i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));i!==l;)r.push(i),i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));return(i=Lr())!==l?e=r=[r,i]:(Jt=e,e=l),Yt--,e===l&&(r=l,0===Yt&&ir(Ve)),e}function Lr(){var e;return Yt++,10===t.charCodeAt(Jt)?(e=U,Jt++):(e=l,0===Yt&&ir(Me)),e===l&&(t.substr(Jt,2)===$?(e=$,Jt+=2):(e=l,0===Yt&&ir(De)),e===l&&(e=t.charAt(Jt),Y.test(e)?Jt++:(e=l,0===Yt&&ir(Ge)))),Yt--,e===l&&(0===Yt&&ir(je)),e}function Ir(){var e,r,i;for(Yt++,e=Jt,r=[],i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));i!==l;)r.push(i),i=t.charAt(Jt),q.test(i)?Jt++:(i=l,0===Yt&&ir(Fe));return(i=Lr())!==l?e=r=[r,i]:(Jt=e,e=l),Yt--,e===l&&(r=l,0===Yt&&ir(Ue)),e}function Fr(){var e;return Yt++,e=t.charAt(Jt),X.test(e)?Jt++:(e=l,0===Yt&&ir(Je)),Yt--,e===l&&(0===Yt&&ir($e)),e}function Nr(){var e,r;return(e=Lr())===l&&(e=Jt,Yt++,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),Yt--,r===l?e=void 0:(Jt=e,e=l)),e}function Or(){var e,r;return(e=Ir())===l&&(e=Jt,Yt++,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),Yt--,r===l?e=void 0:(Jt=e,e=l)),e}function Er(){var e,r;return e=Jt,Yt++,t.length>Jt?(r=t.charAt(Jt),Jt++):(r=l,0===Yt&&ir(oe)),Yt--,r===l?e=void 0:(Jt=e,e=l),e}const Rr=new o.BitmarkPegParserHelper({parse:e,parserText:Xt,parserLocation:jr}),Vr=new n.BitmarkPegParserProcessor({parse:e,parserText:Xt,parserLocation:jr});function jr(){const e=rr(Wt,Jt);return e?(delete e.source,e):e}function rr(e,t,r){var i=tr(e),o=tr(t),n={source:p,start:{offset:e,line:i.line,column:i.column},end:{offset:t,line:o.line,column:o.column}};return p&&"function"==typeof p.offset&&(n.start=p.offset(n.start),n.end=p.offset(n.end)),n}if(s=c(),r.peg$library)return{peg$result:s,peg$currPos:Jt,peg$FAILED:l,peg$maxFailExpected:Ht,peg$maxFailPos:qt};if(s!==l&&Jt===t.length)return s;throw s!==l&&Jt<t.length&&ir({type:"end"}),or(Ht,qt<t.length?t.charAt(qt):null,qt<t.length?rr(qt,qt+1):rr(qt,qt))};const i=r(3029),o=r(3206),n=r(7124);r(7735);function a(e,t,r,i){var o=Error.call(this,e);return Object.setPrototypeOf&&Object.setPrototypeOf(o,a.prototype),o.expected=t,o.found=r,o.location=i,o.name="SyntaxError",o}function s(e,t,r){return r=r||" ",e.length>t?e:(t-=e.length,e+(r+=r.repeat(t)).slice(0,t))}!function(e,t){function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r}(a,Error),a.prototype.format=function(e){var t="Error: "+this.message;if(this.location){var r,i=null;for(r=0;r<e.length;r++)if(e[r].source===this.location.source){i=e[r].text.split(/\r\n|\n|\r/g);break}var o=this.location.start,n=this.location.source&&"function"==typeof this.location.source.offset?this.location.source.offset(o):o,a=this.location.source+":"+n.line+":"+n.column;if(i){var l=this.location.end,p=s("",n.line.toString().length," "),u=i[o.line-1],c=(o.line===l.line?l.column:u.length+1)-o.column||1;t+="\n --\x3e "+a+"\n"+p+" |\n"+n.line+" | "+u+"\n"+p+" | "+s("",o.column-1," ")+s("",c,"^")}else t+="\n at "+a}return t},a.buildMessage=function(e,t){var r={literal:function(e){return'"'+o(e.text)+'"'},class:function(e){var t=e.parts.map((function(e){return Array.isArray(e)?n(e[0])+"-"+n(e[1]):n(e)}));return"["+(e.inverted?"^":"")+t.join("")+"]"},any:function(){return"any character"},end:function(){return"end of input"},other:function(e){return e.description}};function i(e){return e.charCodeAt(0).toString(16).toUpperCase()}function o(e){return e.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function n(e){return e.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function a(e){return r[e.type](e)}return"Expected "+function(e){var t,r,i=e.map(a);if(i.sort(),i.length>0){for(t=1,r=1;t<i.length;t++)i[t-1]!==i[t]&&(i[r]=i[t],r++);i.length=r}switch(i.length){case 1:return i[0];case 2:return i[0]+" or "+i[1];default:return i.slice(0,-1).join(", ")+", or "+i[i.length-1]}}(e)+" but "+function(e){return e?'"'+o(e)+'"':"end of input"}(t)+" found."};t.StartRules=["bitmark","bit","cardContent"]},5078:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.parse=void 0;const i=r(5057).parse;t.parse=i},5087:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkGenerator=void 0;const o=r(5126),n=r(6772),a=r(7735),s=r(2028),l=r(126),p=r(5854),u=r(3811),c=r(4410),y=r(1163),g=r(9727),d=r(166),f=r(6149),m=r(385),T=r(6877),h=r(4078),b=r(955),B=r(9681),v=r(4),C=r(431),P={debugGenerationInline:!1};class x extends v.AstWalkerGenerator{constructor(e,t){var r,i;super(),this.ast=new o.Ast,this.bitType=p.BitType._error,this.textFormat=m.TextFormat.bitmarkMinusMinus,this.tagTextFormat=m.TextFormat.bitmarkMinusMinus,this.isBodyBitmarkText=!1,this.isCardAllowed=!1,this.firstBit=!0,this.hasCardSet=!1,this.hasFooter=!1,this.inTag=!0,this.inTag,this.enter=this.enter.bind(this),this.between=this.between.bind(this),this.exit=this.exit.bind(this),this.leaf=this.leaf.bind(this),this.write=this.write.bind(this),this.bodyBitCallback=this.bodyBitCallback.bind(this),this.bitmarkVersion=null!==(r=u.BitmarkVersion.fromValue(null==t?void 0:t.bitmarkVersion))&&void 0!==r?r:u.DEFAULT_BITMARK_VERSION,this.options=Object.assign(Object.assign({},P),null==t?void 0:t.bitmarkOptions),this.debugGenerationInline=null!==(i=this.options.debugGenerationInline)&&void 0!==i&&i,this.bitmarkVersion===u.BitmarkVersion.v2?void 0===this.options.cardSetVersion&&(this.options.cardSetVersion=y.CardSetVersion.v1):void 0===this.options.cardSetVersion&&(this.options.cardSetVersion=y.CardSetVersion.v2),this.prettifySpace=!0===this.options.prettifyJson?2:this.options.prettifyJson||void 0,this.spacesAroundValues=this.calcSpacesAroundValues(),this.spacesAroundValuesStr=" ".repeat(this.spacesAroundValues),this.textGenerator=new C.TextGenerator(this.bitmarkVersion,{writeCallback:this.write,bodyBitCallback:this.bodyBitCallback,debugGenerationInline:this.debugGenerationInline}),this.mainWriter=e,this.partWriter=new n.StringWriter,this.writer=this.mainWriter,this.generateResourceHandlers(),this.generatePropertyHandlers()}generate(e){return i(this,void 0,void 0,(function*(){this.resetState(),yield this.writer.open(),this.walkAndWrite(e),this.writeLine(),yield this.writer.close()}))}generateSync(e){this.resetState(),this.writer.openSync(),this.walkAndWrite(e),this.writer.closeSync()}resetState(){this.bitType=p.BitType._error,this.textFormat=m.TextFormat.bitmarkMinusMinus,this.tagTextFormat=m.TextFormat.bitmarkMinusMinus,this.isBodyBitmarkText=!1,this.isCardAllowed=!1,this.firstBit=!0,this.hasCardSet=!1,this.hasFooter=!1,this.inTag=!0,this.printed=!1}walkAndWrite(e){this.ast.walk(e,l.NodeType.bitmarkAst,this,void 0),this.writeLine()}enter_bitsValue(e,t){var r;const i=e.value,o=s.Config.getBitConfig(i.bitType),n=s.Config.getBitResourcesConfig(i.bitType,i.resourceType);if(this.bitType=i.bitType,this.textFormat=null!==(r=i.textFormat)&&void 0!==r?r:o.textFormatDefault,this.isBodyBitmarkText=this.textFormat===m.TextFormat.bitmarkMinusMinus||this.textFormat===m.TextFormat.bitmarkPlusPlus,this.isCardAllowed=this.calculateIsCardAllowed(),this.tagTextFormat=this.textFormat===m.TextFormat.bitmarkPlusPlus?m.TextFormat.bitmarkPlusPlus:m.TextFormat.bitmarkMinusMinus,this.hasCardSet=this.haveValidCardSet(i),this.hasFooter=this.haveValidFooter(i),this.firstBit||(this.writeNL(),this.writeNL(),this.writeNL()),this.writeOPD(i.bitLevel),i.isCommented&&this.writeString("|"),this.writeTagKey(i.bitType),i.textFormat){this.isWriteTextFormat(i.textFormat,o.textFormatDefault)&&(this.writeColon(),this.writeTagKey(i.textFormat))}let a;if(o.resourceAttachmentAllowed&&i.resources&&i.resources.length>0){const e=n.comboResourceTagTypesMap;if(n.comboResourceTagTypesMap.size>0)for(const t of e.keys())a=t;else a=i.resources[0].type}return a&&(this.writeAmpersand(),this.writeTagKey(a)),this.writeCL(),!0}exit_bitsValue(e,t){this.firstBit=!1}enter_internalComment(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;for(let e=0;e<r.length;e++){const t=r[e];this.writeNL(),this.writeProperty("internalComment",t,{format:g.PropertyFormat.trimmedString,single:!1,ignoreEmpty:!0})}return!1}enter_labelTrue(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const o=null==i?void 0:i.value;if(o){const e=""!=r,t=o.labelFalse&&""!=o.labelFalse[0];(e||t)&&this.writeNL(),e&&this.writeProperty(d.PropertyTag.labelTrue,r,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),t&&this.writeProperty(d.PropertyTag.labelFalse,o.labelFalse,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}return!1}enter_labelFalse(e,t){return!0}enter_imageSource(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{url:o,mockupId:n,size:a,format:s,trim:p}=r;return this.writeNL(),this.writeProperty("imageSource",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),o&&(n&&this.writeProperty("mockupId",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),a&&this.writeProperty("size",a,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),s&&this.writeProperty("format",s,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),h.BooleanUtils.isBoolean(p)&&this.writeProperty("trim",p,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}enter_technicalTerm(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{technicalTerm:o,lang:n}=r;return this.writeNL(),this.writeProperty("technicalTerm",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=n&&this.writeProperty("lang",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),!1}enter_servings(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{servings:o,unit:n,unitAbbr:a,decimalPlaces:s,disableCalculation:p,hint:u}=r;return this.writeNL(),this.writeProperty("servings",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=n&&this.writeProperty("unit",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=a&&this.writeProperty("unitAbbr",a,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=s&&this.writeProperty("decimalPlaces",s,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=p&&this.writeProperty("disableCalculation",p,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=u&&(this.writeOPQ(),this.writeTextOrValue(u,m.TextFormat.text,T.TextLocation.tag),this.writeCL()),!1}enter_person(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{name:o,title:n,avatarImage:a}=r;return this.writeNL(),this.writeProperty("person",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),n&&this.writeProperty("title",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),a&&this.writeResource(f.ResourceTag.image,a.image.src),!1}enter_text(e,t){const r=this.getParentNode(t);return!r||r.key!==l.NodeType.term&&r.key!==l.NodeType.definition&&r.key!==l.NodeType.alternativeDefinitionsValue&&r.key!==l.NodeType.question&&r.key!==l.NodeType.answer&&r.key!==l.NodeType.alternativeAnswersValue||(e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}leaf_text(e,t){const r=this.getParentNode(t);return!r||r.key!==l.NodeType.term&&r.key!==l.NodeType.definition&&r.key!==l.NodeType.alternativeDefinitionsValue&&r.key!==l.NodeType.question&&r.key!==l.NodeType.answer&&r.key!==l.NodeType.alternativeAnswersValue&&r.key!==l.NodeType.reason||(B.StringUtils.isString(e.value)&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}enter_icon(e,t){const r=e.value,i=this.getParentNode(t);return!i||(i.key!==l.NodeType.term&&i.key!==l.NodeType.definition&&i.key!==l.NodeType.alternativeDefinitionsValue&&i.key!==l.NodeType.question&&i.key!==l.NodeType.answer&&i.key!==l.NodeType.alternativeAnswersValue||(this.writeNL(),this.writeResource(f.ResourceTag.icon,r.image.src)),!0)}leaf_iconValue(e,t){return this.writeNL(),this.writeProperty("icon",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),!1}enter_ratingLevelStart(e,t){return this.enterRatingLevelStartEndCommon(e,t),!1}enter_ratingLevelEnd(e,t){return this.enterRatingLevelStartEndCommon(e,t),!1}enterRatingLevelStartEndCommon(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return!0;const{level:o,label:n}=r,a=e.key===l.NodeType.ratingLevelStart?d.PropertyTag.ratingLevelStart:d.PropertyTag.ratingLevelEnd;return this.writeNL(),this.writeProperty(a,o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),n&&this.writeProperty("label",n,{format:g.PropertyFormat.bitmarkMinusMinus,single:!0,ignoreEmpty:!0}),!1}enter_markConfig(e,t){return!0}enter_markConfigValue(e,t){const r=e.value,i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.markConfig)return!0;const{mark:o,color:n,emphasis:a}=r;return o&&(this.writeNL(),this.writeProperty("mark",o,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),n&&this.writeProperty("color",n,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),a&&this.writeProperty("emphasis",a,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}enter_partialAnswer(e,t){return e.value&&(this.writeNL(),this.writeProperty("partialAnswer",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}leaf_partialAnswer(e,t){return e.value&&(this.writeNL(),this.writeProperty("partialAnswer",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}enter_sampleSolution(e,t){return e.value&&(this.writeNL(),this.writeProperty("sampleSolution",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}leaf_sampleSolution(e,t){return e.value&&(this.writeNL(),this.writeProperty("sampleSolution",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})),!1}leaf_reasonableNumOfChars(e,t){this.writeNL(),this.writeProperty("reasonableNumOfChars",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_additionalSolutionsValue(e,t){const r=this.getParentNode(t,2);(null==r?void 0:r.key)===l.NodeType.questionsValue&&(this.writeNL(),this.writeProperty("additionalSolutions",e.value,{format:g.PropertyFormat.trimmedString,single:!1}))}enter_item(e,t){var r,i,o;const n=e.value,a=this.getParentNode(t);return!this.isEmptyText(n)&&(!this.isEmptyText(null===(r=null==a?void 0:a.value)||void 0===r?void 0:r.lead)||(!this.isEmptyText(null===(i=null==a?void 0:a.value)||void 0===i?void 0:i.pageNumber)||(!this.isEmptyText(null===(o=null==a?void 0:a.value)||void 0===o?void 0:o.marginNumber)||(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(n,this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0))))}enter_lead(e,t){var r,i,o,n;const a=e.value,s=this.getParentNode(t);return!this.isEmptyText(a)&&(!this.isEmptyText(null===(r=null==s?void 0:s.value)||void 0===r?void 0:r.pageNumber)||(!this.isEmptyText(null===(i=null==s?void 0:s.value)||void 0===i?void 0:i.marginNumber)||(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(null!==(n=null===(o=null==s?void 0:s.value)||void 0===o?void 0:o.item)&&void 0!==n?n:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(a,this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0)))}enter_pageNumber(e,t){var r,i,o,n,a;const s=e.value,l=this.getParentNode(t);return!this.isEmptyText(s)&&(!this.isEmptyText(null===(r=null==l?void 0:l.value)||void 0===r?void 0:r.marginNumber)||(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(null!==(o=null===(i=null==l?void 0:l.value)||void 0===i?void 0:i.item)&&void 0!==o?o:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!==(a=null===(n=null==l?void 0:l.value)||void 0===n?void 0:n.lead)&&void 0!==a?a:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!=s?s:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0))}enter_marginNumber(e,t){var r,i,o,n,a,s;const l=e.value,p=this.getParentNode(t);return!this.isEmptyText(l)&&(this.writeNL_IfNotChain(t),this.writeOPC(),this.writeTextOrValue(null!==(i=null===(r=null==p?void 0:p.value)||void 0===r?void 0:r.item)&&void 0!==i?i:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!==(n=null===(o=null==p?void 0:p.value)||void 0===o?void 0:o.lead)&&void 0!==n?n:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(null!==(s=null===(a=null==p?void 0:p.value)||void 0===a?void 0:a.pageNumber)&&void 0!==s?s:"",this.tagTextFormat,T.TextLocation.tag),this.writeCL(),this.writeOPC(),this.writeTextOrValue(l,this.tagTextFormat,T.TextLocation.tag),this.writeCL(),!0)}enter_body(e,t){var r;const i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue&&(null==i?void 0:i.key)!==l.NodeType.cardBitsValue)return!0;this.inTag=!1;const o=e.value;if(this.textFormat===m.TextFormat.json){const e=null!==(r=o.body)&&void 0!==r?r:null;if(Array.isArray(e)||b.ObjectUtils.isObject(e)){const t=JSON.stringify(e,null,this.prettifySpace);t&&(this.writePlainTextDivider(),this.writeNL(),this.writeTextOrValue(t,m.TextFormat.text,T.TextLocation.body))}}else if(this.isBodyBitmarkText){const e=!(this.hasCardSet||this.hasFooter);this.writeNL();const t=Array.isArray(o.body)?o.body:[];this.writeTextOrValue(t,this.textFormat,T.TextLocation.body,{plainTextDividerAllowed:e})}else{this.writePlainTextDivider(),this.writeNL();const e=B.StringUtils.isString(o.body)?o.body:"";this.writeTextOrValue(`${e}`,m.TextFormat.text,T.TextLocation.body)}return!1}exit_body(e,t){this.inTag=!0}bodyBitCallback(e,t,r){var i;const o=null!==(i=l.NodeType.fromValue(e.type))&&void 0!==i?i:l.NodeType.bodyBit;return this.ast.walk(e,o,this,void 0),""}enter_gap(e,t){const r=e.value;if(r.solutions&&0===r.solutions.length)this.writeOPU(),this.writeCL();else for(const e of r.solutions)this.writeOPU(),this.writeTextOrValue(e,m.TextFormat.text,T.TextLocation.tag),this.writeCL();return!0}enter_mark(e,t){const r=e.value;return this.writeOPE(),this.writeTextOrValue(r.solution,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_select(e,t){return!0}enter_highlight(e,t){return!0}enter_footer(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value;return this.textFormat===m.TextFormat.json||i.footer&&i.footer.length>0&&this.isBodyBitmarkText&&(this.writeNL(),this.writeTextOrValue("==== footer ====",m.TextFormat.text,T.TextLocation.body),this.writeNL(),this.writeTextOrValue(i.footer,this.textFormat,T.TextLocation.body,{plainTextDividerAllowed:!0})),!1}enter_solutions(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value;return i&&0===i.length&&(this.writeOPU(),this.writeCL()),!0}leaf_solution(e,t){var r;const i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.bitsValue)return;const o=e.value,n=null===(r=this.getParentNode(t,2))||void 0===r?void 0:r.value;(null==n?void 0:n.type)===c.BodyBitType.mark&&o&&(this.writeOPE(),this.writeTextOrValue(o,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_mark(e,t){const r=t[0];if((null==r?void 0:r.key)!==l.NodeType.mark)return;const i=e.value;i&&this.writeProperty("mark",i,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}enter_optionsValue(e,t){const r=e.value;return r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.text,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_textsValue(e,t){const r=e.value;return r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.text,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_cardNode(e,t){return!this.isCardAllowed||(this.writeCardSetStart(),!0)}between_cardNode(e,t,r,i){this.isCardAllowed&&this.writeCardSetCardDivider()}exit_cardNode(e,t){this.isCardAllowed&&(this.writeCardSetEnd(),this.options.cardSetVersion,y.CardSetVersion.v1)}enter_elements(e,t){}between_elements(e,t,r,i){this.writeCardSetVariantDivider()}between_flashcards(e,t,r,i){this.writeCardSetCardDivider()}between_flashcardsValue(e,t,r,i){var o;this.isCardAllowed&&(r.key===l.NodeType.answer?this.writeCardSetSideDivider():r.key===l.NodeType.alternativeAnswers&&0!==(null===(o=r.value)||void 0===o?void 0:o.length)&&this.writeCardSetVariantDivider())}between_alternativeAnswers(e,t){this.writeCardSetVariantDivider()}between_alternativeDefinitions(e,t){this.writeCardSetVariantDivider()}enter_statements(e,t){}between_statements(e,t,r,i){this.isOfBitType(p.BitType.trueFalse1)||this.writeCardSetCardDivider()}enter_statementsValue(e,t){const r=e.value;return this.writeNL(),r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.statement,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_choicesValue(e,t){const r=e.value;return this.writeNL(),r.isCorrect||r.requireReason?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.choice,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}enter_responsesValue(e,t){const r=e.value;return this.writeNL(),r.isCorrect?this.writeOPP():this.writeOPM(),this.writeTextOrValue(r.response,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),!0}between_feedbacks(e,t,r,i){this.writeCardSetCardDivider()}enter_reason(e,t){return this.writeCardSetSideDivider(),!0}enter_quizzes(e,t){}between_quizzes(e,t,r,i){this.writeCardSetCardDivider()}enter_heading(e,t){}between_heading(e,t,r,i){this.isCardAllowed&&this.writeCardSetSideDivider()}enter_forValues(e,t){}between_forValues(e,t,r,i){this.isCardAllowed&&this.writeCardSetSideDivider()}enter_pairs(e,t){}between_pairs(e,t,r,i){this.writeCardSetCardDivider()}enter_keyAudio(e,t){const r=e.value;return this.writeNL(),this.writeResource(f.ResourceTag.audio,r.audio.src),!1}enter_keyImage(e,t){const r=e.value;return this.writeNL(),this.writeResource(f.ResourceTag.image,r.image.src),!1}enter_matrix(e,t){}between_matrix(e,t,r,i){this.writeCardSetCardDivider()}enter_values(e,t){this.isCardAllowed&&this.writeCardSetSideDivider()}between_values(e,t,r,i){this.isCardAllowed&&this.writeCardSetVariantDivider()}between_pronunciationTable(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)===l.NodeType.cardNode&&this.isCardAllowed&&this.writeCardSetCardDivider()}between_table(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)===l.NodeType.cardNode&&this.isCardAllowed&&this.writeCardSetCardDivider()}between_data(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)!==l.NodeType.table&&(null==o?void 0:o.key)!==l.NodeType.pronunciationTable||this.writeCardSetCardDivider()}between_columns(e,t,r,i){const o=this.getParentNode(i),n=null==o?void 0:o.key;n!==l.NodeType.table&&n!==l.NodeType.captionDefinitionList||this.isCardAllowed&&this.writeCardSetSideDivider()}leaf_columnsValue(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}enter_columnsValue(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,this.tagTextFormat,T.TextLocation.tag),this.writeCL()}between_dataValue(e,t,r,i){const o=this.getParentNode(i,2);(null==o?void 0:o.key)!==l.NodeType.table&&(null==o?void 0:o.key)!==l.NodeType.pronunciationTable||this.isCardAllowed&&this.writeCardSetSideDivider()}leaf_dataValueValue(e,t){const r=this.getParentNode(t,3);(null==r?void 0:r.key)===l.NodeType.table&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}enter_dataValueValue(e,t){const r=this.getParentNode(t,3);if(((null==r?void 0:r.key)===l.NodeType.table||(null==r?void 0:r.key)===l.NodeType.pronunciationTable)&&e.value){if((null==r?void 0:r.key)===l.NodeType.pronunciationTable){const t=e.value;return t.title&&(this.writeNL(),this.writeOP(),this.writeHash(),this.writeTextOrValue(t.title,this.tagTextFormat,T.TextLocation.tag),this.writeCL()),t.audio&&(this.writeNL(),this.writeResource(f.ResourceTag.audio,t.audio.audio.src)),t.body&&(this.writeNL(),this.writeTextOrValue(t.body,this.textFormat,T.TextLocation.body)),!1}this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)}}between_captionDefinitionList(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)===l.NodeType.cardNode&&this.writeCardSetCardDivider()}leaf_term(e,t){const r=this.getParentNode(t);return(null==r?void 0:r.key)!==l.NodeType.definitionsValue||(e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}leaf_definition(e,t){const r=this.getParentNode(t);return(null==r?void 0:r.key)!==l.NodeType.definitionsValue||(e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body)),!1)}between_definitions(e,t,r,i){const o=this.getParentNode(i);(null==o?void 0:o.key)!==l.NodeType.cardNode&&(null==o?void 0:o.key)!==l.NodeType.captionDefinitionList||this.writeCardSetCardDivider()}between_definitionsValue(e,t,r,i){var o;const n=this.getParentNode(i);(null==n?void 0:n.key)===l.NodeType.definitions&&this.isCardAllowed&&(r.key===l.NodeType.definition?this.writeCardSetSideDivider():r.key===l.NodeType.alternativeDefinitions&&(null===(o=r.value)||void 0===o?void 0:o.length)>0&&this.writeCardSetVariantDivider())}enter_questions(e,t){}between_questions(e,t,r,i){this.writeCardSetCardDivider()}enter_ingredients(e,t){}between_ingredients(e,t,r,i){this.writeCardSetCardDivider()}enter_ingredientsValue(e,t){const r=e.value;return null!=r.title&&(this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(r.title,m.TextFormat.text,T.TextLocation.tag),this.writeCL()),this.writeNL(),r.checked?this.writeOPP():this.writeOPM(),this.writeCL(),null!=r.quantity&&(this.writeOPB(),this.writeTextOrValue(`${r.quantity}`,m.TextFormat.text,T.TextLocation.tag),this.writeCL()),null!=r.unit&&this.writeProperty("unit",r.unit,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=r.unitAbbr&&this.writeProperty("unitAbbr",r.unitAbbr,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=r.decimalPlaces&&this.writeProperty("decimalPlaces",r.decimalPlaces,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),r.disableCalculation&&this.writeProperty("disableCalculation",!0,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}),null!=r.item&&(this.writeNL(),this.writeTextOrValue(r.item,this.textFormat,T.TextLocation.body)),!1}enter_botResponses(e,t){}between_botResponses(e,t,r,i){this.writeCardSetCardDivider()}enter_cardBits(e,t){}between_cardBits(e,t,r,i){this.writeCardSetCardDivider()}leaf_response(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)===l.NodeType.botResponsesValue&&(this.writeNL(),this.writeOPB(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_reaction(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)===l.NodeType.botResponsesValue&&(this.writeNL(),this.writeProperty("reaction",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}leaf_feedback(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.botResponsesValue)return;const i=e.value;i&&(this.writeNL(),this.writeTextOrValue(i,this.textFormat,T.TextLocation.body))}enter_imagePlaceholder(e,t){const r=e.value;return this.writeNL(),this.writePropertyStyleResource(e.key,r),!0}exit_imagePlaceholder(e,t){}enter_posterImage(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)===l.NodeType.bitsValue){const t=e.value;t&&this.writeProperty("posterImage",t,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}else{const t=e.value;t&&t.src&&this.writeProperty("posterImage",t.src,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}return!0}enter_thumbnails(e,t){const r=e.value;if(Array.isArray(r)){const e=["src1x","src2x","src3x","src4x"];for(let t=0;t<r.length&&t!==e.length;t++){const i=r[t],o=e[t];this.writeProperty(o,i.src,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}}return!1}leaf_level(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;if(!s.Config.isOfBitType(this.bitType,[p.BitType.chapter]))return!0;const i=e.value,o=null==r?void 0:r.value;if(i>0&&null==o.title){this.writeNL(),this.writeOP();for(let e=0;e<+i;e++)this.writeHash();this.writeCL()}return!1}enter_title(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value,o=(null==r?void 0:r.value).level||1;if(o&&i){this.writeNL(),this.writeOP();for(let e=0;e<+o;e++)this.writeHash();this.writeTextOrValue(i,this.tagTextFormat,T.TextLocation.tag),this.writeCL()}return!1}enter_subtitle(e,t){const r=this.getParentNode(t);if((null==r?void 0:r.key)!==l.NodeType.bitsValue)return!0;const i=e.value;if(i){this.writeNL(),this.writeOP();for(let e=0;e<2;e++)this.writeHash();this.writeTextOrValue(i,this.tagTextFormat,T.TextLocation.tag),this.writeCL()}return!1}enter_book(e,t){}enter_bookValue(e,t){const r=e.value;return r&&(this.writeNL(),this.writeProperty("book",r.book,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!1}),r.reference&&(this.writeOPRANGLE(),this.writeTextOrValue(r.reference,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),r.referenceEnd&&(this.writeOPRANGLE(),this.writeTextOrValue(r.referenceEnd,m.TextFormat.text,T.TextLocation.tag),this.writeCL()))),!1}leaf_book(e,t){const r=this.getParentNode(t),i=null==r?void 0:r.value;i&&e.value&&(this.writeNL(),this.writeProperty("book",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!1}),i.reference&&(this.writeOPRANGLE(),this.writeTextOrValue(i.reference,m.TextFormat.text,T.TextLocation.tag),this.writeCL(),i.referenceEnd&&(this.writeOPRANGLE(),this.writeTextOrValue(i.referenceEnd,m.TextFormat.text,T.TextLocation.tag),this.writeCL())))}leaf_anchor(e,t){e.value&&(this.writeNL(),this.writeOPDANGLE(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_reference(e,t){const r=this.getParentNode(t),i=null==r?void 0:r.value;i&&e.value&&(i.book||(this.writeNL(),this.writeOPRANGLE(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()))}enter_hint(e,t){const r=e.value;return this.isEmptyText(r)||(this.writeNL_IfNotChain(t),this.writeOPQ(),this.writeTextOrValue(r,this.tagTextFormat,T.TextLocation.tag),this.writeCL()),!1}enter_instruction(e,t){const r=e.value;return this.isEmptyText(r)||(this.writeNL_IfNotChain(t),this.writeOPB(),this.writeTextOrValue(r,this.tagTextFormat,T.TextLocation.tag),this.writeCL()),!1}enter_lang(e,t){e.value&&(this.writeNL(),this.writeProperty("lang",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0}))}enter_refAuthor(e,t){e.value&&(this.writeNL(),this.writeProperty("refAuthor",e.value,{format:g.PropertyFormat.trimmedString,single:!1,ignoreEmpty:!0}))}enter_refBookTitle(e,t){e.value&&(this.writeNL(),this.writeProperty("refBookTitle",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}enter_refPublisher(e,t){e.value&&(this.writeNL(),this.writeProperty("refPublisher",e.value,{format:g.PropertyFormat.trimmedString,single:!1,ignoreEmpty:!0}))}enter_refPublicationYear(e,t){e.value&&(this.writeNL(),this.writeProperty("refPublicationYear",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}enter_citationStyle(e,t){e.value&&(this.writeNL(),this.writeProperty("citationStyle",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}leaf_isExample(e,t){var r;if(!e.value)return;const i=this.getParentNode(t),o=null!==(r=null==i?void 0:i.value.example)&&void 0!==r?r:null;null!=o&&""!==o&&(this.writeNL_IfNotChain(t),this.writeOPA(),this.writeString("example"),this.writeColon(),!0===o?this.writeString(" true "):!1===o?this.writeString(" false "):Array.isArray(o)?this.writeTextOrValue(o,this.tagTextFormat,T.TextLocation.tag):this.writeTextOrValue(o,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_elementsValue(e,t){e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_solutionsValue(e,t){const r=this.getParentNode(t,2);(null==r?void 0:r.key)===l.NodeType.bitsValue&&null!=e.value&&(this.writeOPU(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_prefix(e,t){e.value&&(this.writeOPPRE(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_postfix(e,t){e.value&&(this.writeOPPOST(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL())}leaf_isCaseSensitive(e,t){this.writeProperty("isCaseSensitive",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreFalse:!1,ignoreTrue:!0})}leaf_forKeys(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}leaf_forValues(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}leaf_forValuesValue(e,t){this.writeNL(),this.writeOPHASH(),this.writeTextOrValue(e.value,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}leaf_key(e,t){e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_valuesValue(e,t){e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_question(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)!==l.NodeType.questionsValue&&(null==r?void 0:r.key)!==l.NodeType.flashcardsValue||e.value&&(this.writeNL(),this.writeTextOrValue(e.value,this.textFormat,T.TextLocation.body))}leaf_src1x(e,t){this.writeProperty("src1x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_src2x(e,t){this.writeProperty("src2x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_src3x(e,t){this.writeProperty("src3x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_src4x(e,t){this.writeProperty("src4x",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_width(e,t){this.writeProperty("width",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_height(e,t){this.writeProperty("height",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_alt(e,t){this.writeProperty("alt",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_zoomDisabled(e,t){s.Config.isOfBitType(this.bitType,[p.BitType.imageSeparator,p.BitType.pageBanner,p.BitType.imagesLogoGrave,p.BitType.prototypeImages])?this.writeProperty("zoomDisabled",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreFalse:!1,ignoreTrue:!0}):this.writeProperty("zoomDisabled",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreFalse:!0,ignoreTrue:!1})}leaf_license(e,t){this.writeProperty("license",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_copyright(e,t){this.writeProperty("copyright",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_provider(e,t){}leaf_showInIndex(e,t){null!=e.value&&(this.writeNL_IfNotChain(t),this.writeProperty("showInIndex",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0,ignoreFalse:!0}))}enter_caption(e,t){const r=e.value;return this.writeNL_IfNotChain(t),this.writeProperty("caption",r,{format:g.PropertyFormat.bitmarkMinusMinus,single:!0,ignoreEmpty:!0}),!1}leaf_search(e,t){const r=e.value;r&&(this.writeNL_IfNotChain(t),this.writeProperty("search",r,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0}))}leaf_duration(e,t){const r=this.getParentNode(t);(null==r?void 0:r.key)!==l.NodeType.bitsValue&&this.writeProperty("duration",e.value,{format:g.PropertyFormat.trimmedString,single:!0,ignoreEmpty:!0})}leaf_mute(e,t){this.writeProperty("mute",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}leaf_autoplay(e,t){this.writeProperty("autoplay",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}leaf_allowSubtitles(e,t){this.writeProperty("allowSubtitles",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}leaf_showSubtitles(e,t){this.writeProperty("showSubtitles",e.value,{format:g.PropertyFormat.boolean,single:!0,ignoreEmpty:!0})}generateResourceHandlers(){for(const e of f.ResourceTag.keys()){if(e===f.ResourceTag.keyFromValue(f.ResourceTag.unknown))continue;const t=`enter_${e}`;"function"!=typeof this[t]&&(this[t]=(e,t)=>{const r=e.value;if(null==r)return!1;const i=this.getParentNode(t);if((null==i?void 0:i.key)!==l.NodeType.resourcesValue)return!0;const o=f.ResourceTag.fromValue(i.value.__typeAlias),n=null!=o?o:f.ResourceTag.fromValue(i.value.type);if(!n)return!1;const a=r.url||r.src||r.body||"";return this.writeNL(),this.writeResource(n,a),!0},this[t]=this[t].bind(this))}}generatePropertyHandlers(){var e;const t=s.Config.getRawPropertiesConfig();for(const r of Object.values(t)){const t=null!==(e=r.astKey)&&void 0!==e?e:r.tag,i=`enter_${t}`;"function"!=typeof this[i]&&("example"!==t&&(this[i]=(e,t)=>{var i,o;if(null==e.value)return;const n=this.getParentNode(t);(null==n?void 0:n.key)===l.NodeType.bitsValue&&(this.writeNL_IfNotChain(t),this.writeProperty(r.tag,e.value,{format:null!==(i=r.format)&&void 0!==i?i:g.PropertyFormat.trimmedString,single:null!==(o=r.single)&&void 0!==o&&o,ignoreFalse:"false"===r.defaultValue,ignoreTrue:"true"===r.defaultValue}))},this[i]=this[i].bind(this)))}}isChain(e){const t=this.getParentNode(e);return(null==t?void 0:t.key)!==l.NodeType.bitsValue&&((null==t?void 0:t.key)!==l.NodeType.cardBitsValue&&((null==t?void 0:t.key)!==l.NodeType.feedbacksValue&&((null==t?void 0:t.key)!==l.NodeType.quizzesValue&&((null==t?void 0:t.key)!==l.NodeType.pairsValue&&((null==t?void 0:t.key)!==l.NodeType.matrixValue&&((null==t?void 0:t.key)!==l.NodeType.definitionsValue&&((null==t?void 0:t.key)!==l.NodeType.questionsValue&&(null==t?void 0:t.key)!==l.NodeType.reason)))))))}haveValidCardSet(e){const t=s.Config.getBitConfig(e.bitType);return!!t&&!!t.cardSet}haveValidFooter(e){const t=e.footer;if(!t)return!1;return e.textFormat!==m.TextFormat.json&&(!!(t.footer&&t.footer.length>0)&&!!this.isBodyBitmarkText)}calcSpacesAroundValues(){const e=this.options.spacesAroundValues;let t=1;return null!=e&&(t=!0===e?1:!1===e?0:e),t=Math.min(Math.max(t,0),10),t}writeTagKey(e){null!=e&&this.write(a.Breakscape.breakscape(`${e}`,{textFormat:m.TextFormat.text,textLocation:T.TextLocation.tag}))}writeTextOrValue(e,t,r,i){const o=r===T.TextLocation.tag,n="string"==typeof e?e:void 0,s=Array.isArray(e)?e:void 0,l=o?this.spacesAroundValuesStr:"",p=t===m.TextFormat.bitmarkPlusPlus||t===m.TextFormat.bitmarkMinusMinus?t:m.TextFormat.text,u=e=>o?`${l}${e}${l}`:e,c=e=>{const t=this.writer;this.writer=this.partWriter,this.partWriter.openSync(),e(),this.partWriter.closeSync();const r=this.partWriter.getString().trim();return this.writer=t,r};if(null==n){if(null!=s){const e=()=>this.textGenerator.generateSync(s,t,r,i);if(o){const t=c(e);t&&this.write(u(t))}else e()}}else{const e=()=>this.write(a.Breakscape.breakscape(n,{textFormat:p,textLocation:r}));if(o){const t=c(e);t&&this.write(u(t))}else e()}}writeString(e){null!=e&&this.write(`${e}`)}writeOPBUL(){this.write("[•")}writeOPESC(){this.write("[^")}writeOPRANGLE(){this.write("[►")}writeOPDANGLE(){this.write("[▼")}writeOPD(e){this.write(`[${".".repeat(e)}`)}writeOPU(){this.write("[_")}writeOPE(){this.write("[=")}writeOPB(){this.write("[!")}writeOPQ(){this.write("[?")}writeOPA(){this.write("[@")}writeOPP(){this.write("[+")}writeOPM(){this.write("[-")}writeOPS(){this.write("[\\")}writeOPR(){this.write("[*")}writeOPC(){this.write("[%")}writeOPAMP(){this.write("[&")}writeOPDOLLAR(){this.write("[$")}writeOPHASH(){this.write("[#")}writeOPPRE(){this.write("['")}writeOPPOST(){this.write("[")}writeOP(){this.write("[")}writeCL(){0===this.spacesAroundValues&&this.writer.getLastWrite().endsWith("^")?this.write(" ]"):this.write("]")}writeAmpersand(){this.write("&")}writeColon(){this.write(":")}writeHash(){this.write("#")}writeSpacesAroundValues(){this.write(this.spacesAroundValuesStr)}writePlainTextDivider(){this.writeNL(),this.write("==== text ====")}writeCardSetStart(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("==="):this.write("====")}writeCardSetEnd(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1&&this.write("===")}writeCardSetCardDivider(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("==="):this.write("====")}writeCardSetSideDivider(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("=="):this.write("--")}writeCardSetVariantDivider(){this.writeNL(),this.options.cardSetVersion===y.CardSetVersion.v1?this.write("--"):this.write("++")}writeNL_IfNotChain(e){this.isChain(e)||this.writeNL()}writeNL(){this.options.debugGenerationInline?this.write("\\n"):this.write("\n")}writePropertyStyleResource(e,t){var r;if(e&&t){const i=t[null!==(r=f.ResourceTag.keyFromValue(t.type))&&void 0!==r?r:""],o=i&&(i.src||i.url||i.body)||"";this.writeOPA(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(o,m.TextFormat.text,T.TextLocation.tag),t.type,f.ResourceTag.article,this.writeCL()}}writeResource(e,t){e&&(this.writeOPAMP(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(t,m.TextFormat.text,T.TextLocation.tag),f.ResourceTag.article,this.writeCL())}writeProperty(e,t,r){var i;let o;if(void 0!==t){const n=r.format===g.PropertyFormat.bitmarkMinusMinus||r.format===g.PropertyFormat.bitmarkPlusPlus;if(n){if(r.ignoreEmpty&&n&&this.isEmptyText(t))return;this.writeOPA(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(t,null!==(i=m.TextFormat.fromValue(r.format))&&void 0!==i?i:m.TextFormat.bitmarkMinusMinus,T.TextLocation.tag),this.writeCL()}else if(o=Array.isArray(t)?t:[t],o.length>0){r.single&&(o=o.slice(o.length-1));for(const t of o)if(void 0!==t){if(r.ignoreFalse&&!1===t)continue;if(r.ignoreTrue&&!0===t)continue;if(r.ignoreEmpty&&""===t)continue;this.writeOPA(),this.writeTagKey(e),this.writeColon(),this.writeTextOrValue(`${t}`,m.TextFormat.text,T.TextLocation.tag),this.writeCL()}}}}writeInlineDebug(e,t){let r=e;t.open?r=`<${e}>`:t.close?r=`</${e}>`:t.single&&(r=`<${e} />`),this.writeString(r)}isEmptyText(e){return!e||(!Array.isArray(e)||0===e.length)}isWriteTextFormat(e,t){return!!(!(m.TextFormat.fromValue(e)===t)||this.options.explicitTextFormat)}calculateIsCardAllowed(){return this.isBodyBitmarkText&&!this.isOfBitType1()}isOfBitType1(){return this.isOfBitType([p.BitType.trueFalse1,p.BitType.multipleChoice1,p.BitType.multipleResponse1])}isOfBitType(e){return s.Config.isOfBitType(this.bitType,e)}write(e){return this.writer.write(e),this}writeLine(e){return this.writer.writeLine(e),this}writeLines(e,t){return this.writer.writeLines(e,t),this}writeWhiteSpace(){return this.writer.writeWhiteSpace(),this}}t.BitmarkGenerator=x},5126:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Ast=void 0;const i=r(1412),o=r(126),n=r(9681);t.Ast=class{constructor(){(0,i.init)()}walk(e,t,r,i){this.walkRecursive(e,[{index:0,key:t,value:e}],r,i)}getRouteKey(e){return e.reduce(((t,r,i)=>(+r.key!==r.index&&(t+=`${r.key}`,i<e.length-1&&(t+="_")),t)),"")}printTree(e,t=o.NodeType.bitmarkAst){this.walkRecursive(e,[{index:0,key:t,value:e}],{enter:(e,t)=>(console.log("Enter: "+this.getRouteKey(t)),t[t.length-1].key!==o.NodeType.bodyJson),between:(e,t,r,i)=>{console.log("Between: "+this.getRouteKey(i))},exit:(e,t)=>{console.log("Exit: "+this.getRouteKey(t))},leaf:(e,t)=>{console.log("Leaf: "+this.getRouteKey(t))}},void 0)}preprocessAst(e){if(n.StringUtils.isString(e)){const t=e;try{e=JSON.parse(t)}catch(e){return}}if(this.isAst(e))return e}isAst(e){return!(!Object.prototype.hasOwnProperty.call(e,"bits")||!Array.isArray(e.bits))}walkRecursive(e,t,r,i){const{enter:o,between:n,exit:a,leaf:s}=r,l=t[t.length-1].key,p=!this.isValue(e),u=t[t.length-1];if(p){if(o){if(!1===o(u,t,i))return}}else s&&s(u,t,i);if(p){const o=this.isArray(e),a=Object.keys(e);for(let s=0,p=a.length;s<p;s++){const c=a[s],y=s===p-1,g=e,d=g[c];if(null!=d){const e={key:this.getAstKey(c,l,o),index:s,value:d},p=t.slice();if(p.push(e),this.walkRecursive(d,p,r,i),!y){const r=a[s+1],p=g[r],c={key:this.getAstKey(r,l,o),index:s+1,value:p};if(n){if(!1===n(u,e,c,t,i))break}}}}}p&&a&&a(u,t,i)}getAstKey(e,t,r){let i=e;return r&&t&&(i=`${t}Value`),o.NodeType.fromKey(i)||`unknown(${i})`}isArray(e){return Array.isArray(e)}isObject(e){return"[object Object]"===Object.prototype.toString.call(e)}isValue(e){return!this.isObject(e)&&!this.isArray(e)}}},5189:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.markChainContentProcessor=function(e,t,r,u,c,y){if(t===p.BitContentLevel.Chain)(0,l.markTagContentProcessor)(e,p.BitContentLevel.Chain,u,c);else{const t=function(e,t,r,l){var u;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("mark content",l);const c=o.Config.getTagConfigForTag(r,a.Tag.fromValue(l.type)),y=e.bitContentProcessor(p.BitContentLevel.Chain,r,[l]),g=e.bitContentProcessor(p.BitContentLevel.Chain,null==c?void 0:c.chain,l.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("mark TAGS",g);const{solution:d}=y,{mark:f}=g,m=i(g,["mark"]),T=Object.assign({type:n.BodyBitType.mark,solution:null!=d?d:"",mark:null!==(u=s.ArrayUtils.asSingle(f))&&void 0!==u?u:""},m);return T}(e,0,r,u);t&&y.push(t)}};const o=r(2028),n=r(4410),a=r(9917),s=r(6989),l=r(5980),p=r(3029)},5416:(e,t,r)=>{const{VOID:i,PRIMITIVE:o,ARRAY:n,OBJECT:a,DATE:s,REGEXP:l,MAP:p,SET:u,ERROR:c,BIGINT:y}=r(1731),g="",{toString:d}={},{keys:f}=Object,m=e=>{const t=typeof e;if("object"!==t||!e)return[o,t];const r=d.call(e).slice(8,-1);switch(r){case"Array":return[n,g];case"Object":return[a,g];case"Date":return[s,g];case"RegExp":return[l,g];case"Map":return[p,g];case"Set":return[u,g];case"DataView":return[n,r]}return r.includes("Array")?[n,r]:r.includes("Error")?[c,r]:[a,r]},T=([e,t])=>e===o&&("function"===t||"symbol"===t);t.serialize=(e,{json:t,lossy:r}={})=>{const c=[];return((e,t,r,c)=>{const g=(e,t)=>{const i=c.push(e)-1;return r.set(t,i),i},d=c=>{if(r.has(c))return r.get(c);let[h,b]=m(c);switch(h){case o:{let t=c;switch(b){case"bigint":h=y,t=c.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+b);t=null;break;case"undefined":return g([i],c)}return g([h,t],c)}case n:{if(b){let e=c;return"DataView"===b?e=new Uint8Array(c.buffer):"ArrayBuffer"===b&&(e=new Uint8Array(c)),g([b,[...e]],c)}const e=[],t=g([h,e],c);for(const t of c)e.push(d(t));return t}case a:{if(b)switch(b){case"BigInt":return g([b,c.toString()],c);case"Boolean":case"Number":case"String":return g([b,c.valueOf()],c)}if(t&&"toJSON"in c)return d(c.toJSON());const r=[],i=g([h,r],c);for(const t of f(c))!e&&T(m(c[t]))||r.push([d(t),d(c[t])]);return i}case s:return g([h,c.toISOString()],c);case l:{const{source:e,flags:t}=c;return g([h,{source:e,flags:t}],c)}case p:{const t=[],r=g([h,t],c);for(const[r,i]of c)(e||!T(m(r))&&!T(m(i)))&&t.push([d(r),d(i)]);return r}case u:{const t=[],r=g([h,t],c);for(const r of c)!e&&T(m(r))||t.push(d(r));return r}}const{message:B}=c;return g([h,{name:b,message:B}],c)};return d})(!(t||r),!!t,new Map,c)(e),c}},5512:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitTagType=void 0;const i=(0,r(4718).superenum)({tag:"tag",property:"property",resource:"resource",group:"group"});t.BitTagType=i},5533:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceBuilder=void 0;const o=r(7735),n=r(2028),a=r(5854),s=r(6149),l=r(955),p=r(9681),u=r(201),c=r(4470),y=r(4564);class g extends c.BaseBuilder{resourceFromResourceJson(e,t){if(!t)return;const r=[];Array.isArray(t)||(t=[t]);for(const i of t){let t=s.ResourceTag.fromValue(i.type);if(!t)return;const o=s.ResourceTag.keyFromValue(t);if(!o)return;const n=s.ResourceTag.fromValue(i.__typeAlias);let a;if(t=null!=n?n:t,t===s.ResourceTag.imageResponsive){const t=i,o=this.resourceFromResourceDataJson(e,s.ResourceTag.imagePortrait,t.imagePortrait),n=this.resourceFromResourceDataJson(e,s.ResourceTag.imageLandscape,t.imageLandscape);o&&r.push(o),n&&r.push(n)}else if(t===s.ResourceTag.stillImageFilm){const t=i,o=this.resourceFromResourceDataJson(e,s.ResourceTag.image,t.image),n=this.resourceFromResourceDataJson(e,s.ResourceTag.audio,t.audio);o&&r.push(o),n&&r.push(n)}else{if(a=i[o],!a)return;const n=this.resourceFromResourceDataJson(e,t,a);n&&r.push(n)}}return 0!==r.length?1===r.length?r[0]:r:void 0}resourceFromResourceDataJson(e,t,r){var i,o,n;if(!r)return;if(!(t=s.ResourceTag.fromValue(t)))return;const a=p.StringUtils.isString(r)?r:void 0,l=r.url||r.src||r.body||a,u=r.posterImage?null===(i=this.resourceFromResourceDataJson(e,s.ResourceTag.image,r.posterImage))||void 0===i?void 0:i.image:void 0,c=r.thumbnails?r.thumbnails.map((t=>{var r;return null===(r=this.resourceFromResourceDataJson(e,s.ResourceTag.image,t))||void 0===r?void 0:r.image})):void 0;return this.resource(e,{type:t,value:l,format:r.format,src1x:r.src1x,src2x:r.src2x,src3x:r.src3x,src4x:r.src4x,caption:this.handleJsonText(e,!0,r.caption),width:null!==(o=r.width)&&void 0!==o?o:void 0,height:null!==(n=r.height)&&void 0!==n?n:void 0,alt:r.alt,zoomDisabled:r.zoomDisabled,duration:r.duration,mute:r.mute,autoplay:r.autoplay,allowSubtitles:r.allowSubtitles,showSubtitles:r.showSubtitles,posterImage:u,thumbnails:c,siteName:void 0,license:r.license,copyright:r.copyright,showInIndex:r.showInIndex,search:r.search})}resource(e,t){var r;let n;const{type:a,value:l,format:p}=t,u=i(t,["type","value","format"]),c=Object.assign({type:a,value:null!=l?l:o.Breakscape.EMPTY_STRING,format:null!=p?p:o.Breakscape.EMPTY_STRING},u);switch(a){case s.ResourceTag.video:case s.ResourceTag.videoEmbed:case s.ResourceTag.videoLink:case s.ResourceTag.stillImageFilmEmbed:case s.ResourceTag.stillImageFilmLink:{const i=["src1x","src2x","src3x","src4x"],o=[];for(const r of i){const i=t[r];if(i){const t=this.resource(e,{type:s.ResourceTag.image,value:i});t&&o.push(t.image)}}c.thumbnails=[...null!==(r=c.thumbnails)&&void 0!==r?r:[],...o]}}switch(a){case s.ResourceTag.icon:case s.ResourceTag.image:case s.ResourceTag.imagePortrait:case s.ResourceTag.imageLandscape:n=this.imageResource(e,c,a);break;case s.ResourceTag.imageLink:n=this.imageLinkResource(e,c);break;case s.ResourceTag.audio:n=this.audioResource(e,c);break;case s.ResourceTag.audioEmbed:n=this.audioEmbedResource(e,c);break;case s.ResourceTag.audioLink:n=this.audioLinkResource(e,c);break;case s.ResourceTag.video:n=this.videoResource(e,c);break;case s.ResourceTag.videoEmbed:n=this.videoEmbedResource(e,c);break;case s.ResourceTag.videoLink:n=this.videoLinkResource(e,c);break;case s.ResourceTag.stillImageFilmEmbed:n=this.stillImageFilmEmbedResource(e,c);break;case s.ResourceTag.stillImageFilmLink:n=this.stillImageFilmLinkResource(e,c);break;case s.ResourceTag.article:n=this.articleResource(e,c);break;case s.ResourceTag.document:n=this.documentResource(e,c);break;case s.ResourceTag.documentEmbed:n=this.documentEmbedResource(e,c);break;case s.ResourceTag.documentLink:n=this.documentLinkResource(e,c);break;case s.ResourceTag.documentDownload:n=this.documentDownloadResource(e,c);break;case s.ResourceTag.appLink:n=this.appLinkResource(e,c);break;case s.ResourceTag.websiteLink:n=this.websiteLinkResource(e,c)}return n}imageResource(e,t,r){var i,o;const{value:p,src1x:c,src2x:g,src3x:d,src4x:f,width:m,height:T,alt:h,zoomDisabled:b,license:B,copyright:v,showInIndex:C,caption:P,search:x}=t,{bitType:k}=e;let K=!1;n.Config.isOfBitType(k,[a.BitType.imageSeparator,a.BitType.pageBanner,a.BitType.imagesLogoGrave,a.BitType.prototypeImages])&&(K=!0);const w={type:s.ResourceTag.image,__typeAlias:null!=r?r:s.ResourceTag.image,image:{format:null!==(i=u.UrlUtils.fileExtensionFromUrl(p))&&void 0!==i?i:void 0,provider:null!==(o=u.UrlUtils.domainFromUrl(p))&&void 0!==o?o:void 0,src:null!=p?p:"",src1x:null!=c?c:void 0,src2x:null!=g?g:void 0,src3x:null!=d?d:void 0,src4x:null!=f?f:void 0,width:null!=m?m:null,height:null!=T?T:null,alt:null!=h?h:"",zoomDisabled:null!=b?b:K,license:null!=B?B:"",copyright:null!=v?v:"",showInIndex:null!=C&&C,caption:this.handleJsonText(e,!0,P),search:null!=x?x:void 0}};return l.ObjectUtils.removeUnwantedProperties(w.image,{ignoreFalse:["zoomDisabled","showInIndex"],ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["src","alt","license","copyright"]}),y.NodeValidator.validateResource(w)}imageLinkResource(e,t){var r,i;const{value:o,src1x:n,src2x:a,src3x:p,src4x:c,width:g,height:d,alt:f,zoomDisabled:m,license:T,copyright:h,showInIndex:b,caption:B,search:v}=t,C={type:s.ResourceTag.imageLink,__typeAlias:s.ResourceTag.imageLink,imageLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",src1x:null!=n?n:void 0,src2x:null!=a?a:void 0,src3x:null!=p?p:void 0,src4x:null!=c?c:void 0,width:null!=g?g:null,height:null!=d?d:null,alt:null!=f?f:"",zoomDisabled:null!=m&&m,license:null!=T?T:"",copyright:null!=h?h:"",showInIndex:null!=b&&b,caption:this.handleJsonText(e,!0,B),search:null!=v?v:void 0}};return l.ObjectUtils.removeUnwantedProperties(C.imageLink,{ignoreFalse:["zoomDisabled","showInIndex"],ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","alt","license","copyright"]}),y.NodeValidator.validateResource(C)}audioResource(e,t){var r,i;const{value:o,duration:n,mute:a,autoplay:p,license:c,copyright:g,showInIndex:d,caption:f,search:m}=t,T={type:s.ResourceTag.audio,__typeAlias:s.ResourceTag.audio,audio:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,src:null!=o?o:"",duration:null!=n?n:void 0,mute:null!=a?a:void 0,autoplay:null!=p?p:void 0,license:null!=c?c:"",copyright:null!=g?g:"",showInIndex:null!=d&&d,caption:this.handleJsonText(e,!0,f),search:null!=m?m:void 0}};return l.ObjectUtils.removeUnwantedProperties(T.audio,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["src","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(T)}audioEmbedResource(e,t){var r,i;const{value:o,duration:n,mute:a,autoplay:p,license:c,copyright:g,showInIndex:d,caption:f,search:m}=t,T={type:s.ResourceTag.audioEmbed,__typeAlias:s.ResourceTag.audioEmbed,audioEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,src:null!=o?o:"",duration:null!=n?n:void 0,mute:null!=a?a:void 0,autoplay:null!=p?p:void 0,license:null!=c?c:"",copyright:null!=g?g:"",showInIndex:null!=d&&d,caption:this.handleJsonText(e,!0,f),search:null!=m?m:void 0}};return l.ObjectUtils.removeUnwantedProperties(T.audioEmbed,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["src","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(T)}audioLinkResource(e,t){var r,i;const{value:o,duration:n,mute:a,autoplay:p,license:c,copyright:g,showInIndex:d,caption:f,search:m}=t,T={type:s.ResourceTag.audioLink,__typeAlias:s.ResourceTag.audioLink,audioLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",duration:null!=n?n:void 0,mute:null!=a?a:void 0,autoplay:null!=p?p:void 0,license:null!=c?c:"",copyright:null!=g?g:"",showInIndex:null!=d&&d,caption:this.handleJsonText(e,!0,f),search:null!=m?m:void 0}};return l.ObjectUtils.removeUnwantedProperties(T.audioLink,{ignoreEmptyString:["url"]}),y.NodeValidator.validateResource(T)}videoResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.video,__typeAlias:s.ResourceTag.video,video:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,src:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0,posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.video,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["src","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}videoEmbedResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.videoEmbed,__typeAlias:s.ResourceTag.videoEmbed,videoEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.videoEmbed,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}videoLinkResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.videoLink,__typeAlias:s.ResourceTag.videoLink,videoLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.videoLink,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}stillImageFilmEmbedResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.stillImageFilmEmbed,__typeAlias:s.ResourceTag.stillImageFilmEmbed,stillImageFilmEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.stillImageFilmEmbed,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}stillImageFilmLinkResource(e,t){var r,i;const{value:o,width:n,height:a,duration:p,mute:c,autoplay:g,allowSubtitles:d,showSubtitles:f,alt:m,posterImage:T,thumbnails:h,license:b,copyright:B,showInIndex:v,caption:C,search:P}=t,x={type:s.ResourceTag.stillImageFilmLink,__typeAlias:s.ResourceTag.stillImageFilmLink,stillImageFilmLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",width:null!=n?n:null,height:null!=a?a:null,duration:null!=p?p:void 0,mute:null!=c?c:void 0,autoplay:null!=g?g:void 0,allowSubtitles:null!=d?d:void 0,showSubtitles:null!=f?f:void 0,alt:null!=m?m:"",posterImage:null!=T?T:void 0,thumbnails:null!=h?h:void 0,license:null!=b?b:"",copyright:null!=B?B:"",showInIndex:null!=v&&v,caption:this.handleJsonText(e,!0,C),search:null!=P?P:void 0}};return l.ObjectUtils.removeUnwantedProperties(x.stillImageFilmLink,{ignoreEmptyArrays:["caption"],ignoreUndefined:["width","height"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(x)}articleResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.article,__typeAlias:s.ResourceTag.article,article:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,body:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.article,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["body","alt","license","copyright"]}),y.NodeValidator.validateResource(d)}documentResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.document,__typeAlias:s.ResourceTag.document,document:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.document,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}documentEmbedResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.documentEmbed,__typeAlias:s.ResourceTag.documentEmbed,documentEmbed:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.documentEmbed,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}documentLinkResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.documentLink,__typeAlias:s.ResourceTag.documentLink,documentLink:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.documentLink,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}documentDownloadResource(e,t){var r,i;const{value:o,license:n,copyright:a,showInIndex:p,caption:c,search:g}=t,d={type:s.ResourceTag.documentDownload,__typeAlias:s.ResourceTag.documentDownload,documentDownload:{format:null!==(r=u.UrlUtils.fileExtensionFromUrl(o))&&void 0!==r?r:void 0,provider:null!==(i=u.UrlUtils.domainFromUrl(o))&&void 0!==i?i:void 0,url:null!=o?o:"",license:null!=n?n:"",copyright:null!=a?a:"",showInIndex:null!=p&&p,caption:this.handleJsonText(e,!0,c),search:null!=g?g:void 0}};return l.ObjectUtils.removeUnwantedProperties(d.documentDownload,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(d)}appLinkResource(e,t){const{value:r,license:i,copyright:o,showInIndex:n,caption:a,search:p}=t,u={type:s.ResourceTag.appLink,__typeAlias:s.ResourceTag.appLink,appLink:{provider:void 0,url:null!=r?r:"",license:null!=i?i:"",copyright:null!=o?o:"",showInIndex:null!=n&&n,caption:this.handleJsonText(e,!0,a),search:null!=p?p:void 0}};return l.ObjectUtils.removeUnwantedProperties(u.appLink,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(u)}websiteLinkResource(e,t){const{value:r,license:i,copyright:o,showInIndex:n,caption:a,search:p}=t,u={type:s.ResourceTag.websiteLink,__typeAlias:s.ResourceTag.websiteLink,websiteLink:{provider:void 0,url:null!=r?r:"",license:null!=i?i:"",copyright:null!=o?o:"",showInIndex:null!=n&&n,caption:this.handleJsonText(e,!0,a),search:null!=p?p:void 0}};return l.ObjectUtils.removeUnwantedProperties(u.websiteLink,{ignoreEmptyArrays:["caption"],ignoreEmptyString:["url","alt","license","copyright"],ignoreFalse:["showInIndex"]}),y.NodeValidator.validateResource(u)}}t.ResourceBuilder=g},5554:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CARDS=void 0;const i=r(8199),o=r(7112),n=r(9888),a=r(5051),s=r(7797),l=r(5512),p=r(3778),u={[i.CardSetConfigKey._definitionList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_resourceIcon}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._flashcard]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_resourceIcon}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._elements]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._statements]:{variants:[[{tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:1},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:1},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],bodyAllowed:!1}]]},[i.CardSetConfigKey._quiz]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],bodyAllowed:!1}]]},[i.CardSetConfigKey._feedback]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],bodyAllowed:!1}],[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],bodyAllowed:!0}]]},[i.CardSetConfigKey._questions]:{variants:[[{tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars},{type:l.BitTagType.tag,configKey:s.TagConfigKey.sampleSolution},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_sampleSolution},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.additionalSolutions,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.partialAnswer},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchPairs]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchAudioPairs]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audio}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchImagePairs]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.image}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._matchMatrix]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._table]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._pronunciationTable]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audio}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._botActionResponses]:{variants:[[{tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reaction},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardExample}]}]]},[i.CardSetConfigKey._clozeList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_gap}]}]]},[i.CardSetConfigKey._exampleBitList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._ingredients]:{variants:[[{tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.title},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse},{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.unit},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.unitAbbr},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.decimalPlaces},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.disableCalculation}],repeatCount:p.Count.infinity}]]},[i.CardSetConfigKey._bookReferenceList]:{variants:[[{tags:[{type:l.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refAuthor,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refBookTitle},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refPublisher,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.refPublicationYear},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.citationStyle}],repeatCount:p.Count.infinity}]]}};t.CARDS=u},5591:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ConfigKey=void 0;const i=r(4718),o=r(7112),n=r(9888),a=r(5051),s=r(7797),l=(0,i.superenum)(Object.assign(Object.assign(Object.assign(Object.assign({_unknown:"_unknown"},s.tagConfigKeys),n.propertyConfigKeys),a.resourceConfigKeys),o.groupConfigKeys));t.ConfigKey=l,function(){const e=new Set,t=[s.tagConfigKeys,n.propertyConfigKeys,a.resourceConfigKeys,o.groupConfigKeys];for(const r of t)for(const t in r)e.add(t)}()},5633:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkParser=void 0;const i=r(5663),o=r(5078);t.BitmarkParser=class{constructor(){this.jsonParser=new i.JsonParser}toAst(e,t){return(0,o.parse)(e)}}},5659:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.parseUserAgent=function(){if("undefined"==typeof window||!window.navigator||!window.navigator.userAgent)return;const e={browser:i.Environment.unknown,os:o.Os.unknown},t=function(e){const t=e.toLowerCase().split(new RegExp("[ /,;()]","g")).reduce(((e,t)=>(t&&e.push(t),e)),[]),r={keys:new Set,versions:{}};let i="";for(let e=0,o=t.length;e<o;e++){const o=t[e];let n=!1;for(let e=0;e<=9;e++)if(o.startsWith(`${e}`)){n=!0;break}n?r.versions[i]=o.replace("_","."):r.keys.add(o),i=o}return r}(window.navigator.userAgent),r=t.keys.has("firefox"),n=t.keys.has("chrome"),a=t.keys.has("chromium"),s=t.keys.has("safari"),l=t.keys.has("macintosh"),p=n,u=r,c=l;!s||n||a?p?(e.browser=i.Environment.chrome,e.browserVersion=t.versions.chrome):u&&(e.browser=i.Environment.firefox,e.browserVersion=t.versions.firefox):(e.browser=i.Environment.safari,e.browserVersion=t.versions.version);c&&(e.os=o.Os.macos,e.osVersion=t.versions.x);return e};const i=r(6278),o=r(9561)},5663:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonParser=void 0;const o=r(5809),n=r(2028),a=r(5854),s=r(6149),l=r(385),p=r(9681),u=new o.Builder;t.JsonParser=class{toAst(e){const t=this.preprocessJson(e),r=[];for(const e of t){const{bit:t,parser:i}=e,o=this.bitToAst(t,null==i?void 0:i.internalComments);o&&r.push(o)}const i=r.length>0?{bits:r}:{};return u.buildBitmark(i)}preprocessJson(e){const t=[];if(p.StringUtils.isString(e)){const t=e;try{e=JSON.parse(t)}catch(e){return[]}}const r=e=>{if(this.isBitWrapper(e)){const r=e;t.push(r)}else if(this.isBit(e)){const r=e;t.push(this.bitToBitWrapper(r))}};if(Array.isArray(e))for(const t of e)r(t);else r(e);return t}isBitWrapper(e){if(Object.prototype.hasOwnProperty.call(e,"bit")){const t=e;return this.isBit(t.bit)}return!1}isBit(e){if(Object.prototype.hasOwnProperty.call(e,"type")){const t=e;return n.Config.getBitType(t.type)!==a.BitType._error}return!1}bitToBitWrapper(e){return{bit:e}}bitToAst(e,t){var r,o,s,p,c;const{statement:y,product:g,productVideo:d,reference:f}=e,m=i(e,["statement","product","productVideo","reference"]),T=e.type===a.BitType._comment&&void 0!==e.originalType,h=n.Config.getBitType(T?e.originalType:e.type),b=n.Config.getBitConfig(h);let B=null!==(r=l.TextFormat.fromValue(e.format))&&void 0!==r?r:b.textFormatDefault;B===l.TextFormat.bitmarkMinusMinus&&(B=l.TextFormat.bitmarkPlusPlus);return u.buildBit(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},m),{bitType:h,bitLevel:Math.max(Math.min(null!==(o=e.bitLevel)&&void 0!==o?o:1,n.Config.bitLevelMax),n.Config.bitLevelMin),textFormat:e.format,resourceType:this.getResourceType(e.resource),isCommented:T,internalComment:t,productList:g,productVideoList:d}),this.processReference(f)),this.parseExample(e.example)),{person:null!==(s=e.partner)&&void 0!==s?s:e.person,markConfig:e.marks,resources:this.processResources(h,e.resource,e.images,e.logos),body:this.processBody(e.body,e.placeholders),flashcards:e.cards,statements:this.processStatements(y,e.isCorrect,e.statements,e.example),responses:this.processResponses(h,e.responses),botResponses:this.processBotResponse(h,e.responses),cardBits:this.processListItems(null!==(c=null!==(p=e.listItems)&&void 0!==p?p:e.sections)&&void 0!==c?c:e.bookReferences,e.placeholders),footer:this.processFooter(e.footer)}))}processStatements(e,t,r,i){const o=[];if(e){const r=Object.assign({statement:null!=e?e:"",isCorrect:null!=t&&t},this.parseExample(i));r&&o.push(r)}if(Array.isArray(r))for(const e of r)o.push(e);if(0!==o.length)return o}processResponses(e,t){if(!n.Config.isOfBitType(e,a.BitType.botActionResponse)&&Array.isArray(t))return t}processBotResponse(e,t){if(n.Config.isOfBitType(e,a.BitType.botActionResponse)&&Array.isArray(t))return t}processListItems(e,t){const r=[];if(Array.isArray(e))for(const i of e){const e=Object.assign({},i);e.body&&(e.body={body:e.body,placeholders:t}),e&&r.push(e)}if(0!==r.length)return r}getResourceType(e){if(e){return s.ResourceTag.fromValue(e.type)}}processResources(e,t,r,i){const o=[];if(t&&o.push(t),n.Config.isOfBitType(e,[a.BitType.prototypeImages])&&Array.isArray(r))for(const e of r)e&&o.push(e);if(n.Config.isOfBitType(e,[a.BitType.imagesLogoGrave])&&Array.isArray(i))for(const e of i)e&&o.push(e);return o}processBody(e,t){return{body:e,placeholders:t}}processFooter(e){if(e)return{footer:e}}processReference(e){return Array.isArray(e)&&e.length>0?{reference:void 0,referenceProperty:e}:{reference:e,referenceProperty:void 0}}parseExample(e){if(null==e)return;if(!0===e)return{example:!0};if(!1===e)return{example:!1};const t=p.StringUtils.isString(e)||Array.isArray(e)?e:void 0;return t?{example:t}:{example:!!e}}}},5809:function(e,t,r){var i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Builder=void 0;const o=i(r(7678)),n=r(7735),a=r(2028),s=r(9888),l=r(5854),p=r(4410),u=r(6149),c=r(385),y=r(6877),g=r(6989),d=r(8903),f=r(4078),m=r(8025),T=r(955),h=r(9681),b=r(6936),B=r(4470),v=r(5533),C=r(4564);class P extends B.BaseBuilder{constructor(){super(...arguments),this.resourceBuilder=new v.ResourceBuilder}buildBitmark(e){const{bits:t,errors:r}=e,i={bits:t,errors:r};return T.ObjectUtils.removeUnwantedProperties(i),i}buildBit(e){var t,r,i,o,n,y,d,f;const h=a.Config.getBitConfig(e.bitType),b=e.bitType;let B=null!==(t=c.TextFormat.fromValue(e.textFormat))&&void 0!==t?t:h.textFormatDefault;B===c.TextFormat.bitmarkMinusMinus&&(B=c.TextFormat.bitmarkPlusPlus);const v={bitConfig:h,bitType:b,textFormat:B},P=this.buildCardNode(v,e),x=a.Config.isOfBitType(e.bitType,l.BitType.essay)?this.toAstProperty(s.PropertyConfigKey.reasonableNumOfChars,e.reasonableNumOfChars):void 0,k=Object.assign({},this.toExample(e.__isDefaultExample,e.example)),K=Object.assign(Object.assign({bitType:b,bitLevel:e.bitLevel,textFormat:B,resourceType:u.ResourceTag.fromValue(e.resourceType),isCommented:e.isCommented,id:this.toAstProperty(s.PropertyConfigKey.id,e.id),internalComment:this.toAstProperty(s.PropertyConfigKey.internalComment,e.internalComment),customerId:this.toAstProperty(s.PropertyConfigKey.customerId,e.customerId),customerExternalId:this.toAstProperty(s.PropertyConfigKey.customerExternalId,e.customerExternalId),externalId:this.toAstProperty(s.PropertyConfigKey.externalId,e.externalId),spaceId:this.toAstProperty(s.PropertyConfigKey.spaceId,e.spaceId),padletId:this.toAstProperty(s.PropertyConfigKey.padletId,e.padletId),jupyterId:this.toAstProperty(s.PropertyConfigKey.jupyterId,e.jupyterId),jupyterExecutionCount:this.toAstProperty(s.PropertyConfigKey.jupyterExecutionCount,e.jupyterExecutionCount),isPublic:this.toAstProperty(s.PropertyConfigKey.isPublic,e.isPublic),aiGenerated:this.toAstProperty(s.PropertyConfigKey.aiGenerated,e.aiGenerated),machineTranslated:this.toAstProperty(s.PropertyConfigKey.machineTranslated,e.machineTranslated),searchIndex:this.toAstProperty(s.PropertyConfigKey.searchIndex,e.searchIndex),analyticsTag:this.toAstProperty(s.PropertyConfigKey.analyticsTag,e.analyticsTag),categoryTag:this.toAstProperty(s.PropertyConfigKey.categoryTag,e.categoryTag),topicTag:this.toAstProperty(s.PropertyConfigKey.topicTag,e.topicTag),altLangTag:this.toAstProperty(s.PropertyConfigKey.altLangTag,e.altLangTag),feedbackEngine:this.toAstProperty(s.PropertyConfigKey.feedbackEngine,e.feedbackEngine),feedbackType:this.toAstProperty(s.PropertyConfigKey.feedbackType,e.feedbackType),disableFeedback:this.toAstProperty(s.PropertyConfigKey.disableFeedback,e.disableFeedback),diffTo:this.toAstProperty(s.PropertyConfigKey.diffTo,e.diffTo),diffOp:this.toAstProperty(s.PropertyConfigKey.diffOp,e.diffOp),diffRef:this.toAstProperty(s.PropertyConfigKey.diffRef,e.diffRef),diffContext:this.toAstProperty(s.PropertyConfigKey.diffContext,e.diffContext),diffTime:this.toAstProperty(s.PropertyConfigKey.diffTime,e.diffTime),path:this.toAstProperty(s.PropertyConfigKey.path,e.path),releaseVersion:this.toAstProperty(s.PropertyConfigKey.releaseVersion,e.releaseVersion),releaseKind:this.toAstProperty(s.PropertyConfigKey.releaseKind,e.releaseKind),releaseDate:this.toAstProperty(s.PropertyConfigKey.releaseDate,e.releaseDate),book:this.buildBooks(v,e.book),ageRange:this.toAstProperty(s.PropertyConfigKey.ageRange,e.ageRange),lang:this.toAstProperty(s.PropertyConfigKey.lang,e.lang),language:this.toAstProperty(s.PropertyConfigKey.language,e.language),publisher:this.toAstProperty(s.PropertyConfigKey.publisher,e.publisher),publisherName:this.toAstProperty(s.PropertyConfigKey.publisherName,e.publisherName),theme:this.toAstProperty(s.PropertyConfigKey.theme,e.theme),computerLanguage:this.toAstProperty(s.PropertyConfigKey.computerLanguage,e.computerLanguage),target:this.toAstProperty(s.PropertyConfigKey.target,e.target),slug:this.toAstProperty(s.PropertyConfigKey.slug,e.slug),tag:this.toAstProperty(s.PropertyConfigKey.tag,e.tag),reductionTag:this.toAstProperty(s.PropertyConfigKey.reductionTag,e.reductionTag),bubbleTag:this.toAstProperty(s.PropertyConfigKey.bubbleTag,e.bubbleTag),levelCEFRp:this.toAstProperty(s.PropertyConfigKey.levelCEFRp,e.levelCEFRp),levelCEFR:this.toAstProperty(s.PropertyConfigKey.levelCEFR,e.levelCEFR),levelILR:this.toAstProperty(s.PropertyConfigKey.levelILR,e.levelILR),levelACTFL:this.toAstProperty(s.PropertyConfigKey.levelACTFL,e.levelACTFL),icon:this.toAstProperty(s.PropertyConfigKey.icon,e.icon),iconTag:this.toAstProperty(s.PropertyConfigKey.iconTag,e.iconTag),colorTag:this.toAstProperty(s.PropertyConfigKey.colorTag,e.colorTag),flashcardSet:this.toAstProperty(s.PropertyConfigKey.flashcardSet,e.flashcardSet),subtype:this.toAstProperty(s.PropertyConfigKey.subtype,e.subtype),bookAlias:this.toAstProperty(s.PropertyConfigKey.bookAlias,e.bookAlias),bookDiff:this.toAstProperty(s.PropertyConfigKey.bookDiff,e.bookDiff),coverImage:this.toAstProperty(s.PropertyConfigKey.coverImage,e.coverImage),coverColor:this.toAstProperty(s.PropertyConfigKey.coverColor,e.coverColor),publications:this.toAstProperty(s.PropertyConfigKey.publications,e.publications),author:this.toAstProperty(s.PropertyConfigKey.author,e.author),subject:this.toAstProperty(s.PropertyConfigKey.subject,e.subject),date:this.toAstProperty(s.PropertyConfigKey.date,e.date),dateEnd:this.toAstProperty(s.PropertyConfigKey.dateEnd,e.dateEnd),location:this.toAstProperty(s.PropertyConfigKey.location,e.location),kind:this.toAstProperty(s.PropertyConfigKey.kind,e.kind),hasMarkAsDone:this.toAstProperty(s.PropertyConfigKey.hasMarkAsDone,e.hasMarkAsDone),processHandIn:this.toAstProperty(s.PropertyConfigKey.processHandIn,e.processHandIn),chatWithBook:this.toAstProperty(s.PropertyConfigKey.chatWithBook,e.chatWithBook),chatWithBookBrainKey:this.toAstProperty(s.PropertyConfigKey.chatWithBookBrainKey,e.chatWithBookBrainKey),action:this.toAstProperty(s.PropertyConfigKey.action,e.action),showInIndex:this.toAstProperty(s.PropertyConfigKey.showInIndex,e.showInIndex),refAuthor:this.toAstProperty(s.PropertyConfigKey.refAuthor,e.refAuthor),refBookTitle:this.toAstProperty(s.PropertyConfigKey.refBookTitle,e.refBookTitle),refPublisher:this.toAstProperty(s.PropertyConfigKey.refPublisher,e.refPublisher),refPublicationYear:this.toAstProperty(s.PropertyConfigKey.refPublicationYear,e.refPublicationYear),citationStyle:this.toAstProperty(s.PropertyConfigKey.citationStyle,e.citationStyle),blockId:this.toAstProperty(s.PropertyConfigKey.blockId,e.blockId),pageNo:this.toAstProperty(s.PropertyConfigKey.pageNo,e.pageNo),x:this.toAstProperty(s.PropertyConfigKey.x,e.x),y:this.toAstProperty(s.PropertyConfigKey.y,e.y),width:this.toAstProperty(s.PropertyConfigKey.width,e.width),height:this.toAstProperty(s.PropertyConfigKey.height,e.height),index:this.toAstProperty(s.PropertyConfigKey.index,e.index),classification:this.toAstProperty(s.PropertyConfigKey.classification,e.classification),availableClassifications:this.toAstProperty(s.PropertyConfigKey.availableClassifications,e.availableClassifications),allowedBit:this.toAstProperty(s.PropertyConfigKey.allowedBit,e.allowedBit),tableFixedHeader:this.toAstProperty(s.PropertyConfigKey.tableFixedHeader,e.tableFixedHeader),tableSearch:this.toAstProperty(s.PropertyConfigKey.tableSearch,e.tableSearch),tableSort:this.toAstProperty(s.PropertyConfigKey.tableSort,e.tableSort),tablePagination:this.toAstProperty(s.PropertyConfigKey.tablePagination,e.tablePagination),tablePaginationLimit:this.toAstProperty(s.PropertyConfigKey.tablePaginationLimit,e.tablePaginationLimit),tableHeight:this.toAstProperty(s.PropertyConfigKey.tableHeight,e.tableHeight),tableWhitespaceNoWrap:this.toAstProperty(s.PropertyConfigKey.tableWhitespaceNoWrap,e.tableWhitespaceNoWrap),tableAutoWidth:this.toAstProperty(s.PropertyConfigKey.tableAutoWidth,e.tableAutoWidth),tableResizableColumns:this.toAstProperty(s.PropertyConfigKey.tableResizableColumns,e.tableResizableColumns),tableColumnMinWidth:this.toAstProperty(s.PropertyConfigKey.tableColumnMinWidth,e.tableColumnMinWidth),quizCountItems:this.toAstProperty(s.PropertyConfigKey.quizCountItems,e.quizCountItems),quizStrikethroughSolutions:this.toAstProperty(s.PropertyConfigKey.quizStrikethroughSolutions,e.quizStrikethroughSolutions),codeLineNumbers:this.toAstProperty(s.PropertyConfigKey.codeLineNumbers,e.codeLineNumbers),codeMinimap:this.toAstProperty(s.PropertyConfigKey.codeMinimap,e.codeMinimap),stripePricingTableId:this.toAstProperty(s.PropertyConfigKey.stripePricingTableId,e.stripePricingTableId),stripePublishableKey:this.toAstProperty(s.PropertyConfigKey.stripePublishableKey,e.stripePublishableKey),thumbImage:this.toAstProperty(s.PropertyConfigKey.thumbImage,e.thumbImage),scormSource:this.toAstProperty(s.PropertyConfigKey.scormSource,e.scormSource),posterImage:this.toAstProperty(s.PropertyConfigKey.posterImage,e.posterImage),focusX:this.toAstProperty(s.PropertyConfigKey.focusX,e.focusX),focusY:this.toAstProperty(s.PropertyConfigKey.focusY,e.focusY),pointerLeft:this.toAstProperty(s.PropertyConfigKey.pointerLeft,e.pointerLeft),pointerTop:this.toAstProperty(s.PropertyConfigKey.pointerTop,e.pointerTop),listItemIndent:this.toAstProperty(s.PropertyConfigKey.listItemIndent,e.listItemIndent),backgroundWallpaper:this.toAstProperty(s.PropertyConfigKey.backgroundWallpaper,e.backgroundWallpaper),hasBookNavigation:this.toAstProperty(s.PropertyConfigKey.hasBookNavigation,e.hasBookNavigation),duration:this.toAstProperty(s.PropertyConfigKey.duration,e.duration),deeplink:this.toAstProperty(s.PropertyConfigKey.deeplink,e.deeplink),externalLink:this.toAstProperty(s.PropertyConfigKey.externalLink,e.externalLink),externalLinkText:this.toAstProperty(s.PropertyConfigKey.externalLinkText,e.externalLinkText),videoCallLink:this.toAstProperty(s.PropertyConfigKey.videoCallLink,e.videoCallLink),vendorDashboardId:this.toAstProperty(s.PropertyConfigKey.vendorDashboardId,e.vendorDashboardId),vendorSurveyId:this.toAstProperty(s.PropertyConfigKey.vendorSurveyId,e.vendorSurveyId),vendorUrl:this.toAstProperty(s.PropertyConfigKey.vendorUrl,e.vendorUrl),search:this.toAstProperty(s.PropertyConfigKey.search,e.search),list:this.toAstProperty(s.PropertyConfigKey.list,e.list),layer:this.toAstProperty(s.PropertyConfigKey.layer,e.layer),textReference:this.toAstProperty(s.PropertyConfigKey.textReference,e.textReference),isTracked:this.toAstProperty(s.PropertyConfigKey.isTracked,e.isTracked),isInfoOnly:this.toAstProperty(s.PropertyConfigKey.isInfoOnly,e.isInfoOnly),imageFirst:this.toAstProperty(s.PropertyConfigKey.imageFirst,e.imageFirst),activityType:this.toAstProperty(s.PropertyConfigKey.activityType,e.activityType),labelTrue:this.toAstProperty(s.PropertyConfigKey.labelTrue,e.labelTrue),labelFalse:this.toAstProperty(s.PropertyConfigKey.labelFalse,e.labelFalse),content2Buy:this.toAstProperty(s.PropertyConfigKey.content2Buy,e.content2Buy),mailingList:this.toAstProperty(s.PropertyConfigKey.mailingList,e.mailingList),buttonCaption:this.toAstProperty(s.PropertyConfigKey.buttonCaption,e.buttonCaption),callToActionUrl:this.toAstProperty(s.PropertyConfigKey.callToActionUrl,e.callToActionUrl),caption:this.handleJsonText(v,!0,e.caption),quotedPerson:this.toAstProperty(s.PropertyConfigKey.quotedPerson,e.quotedPerson),reasonableNumOfChars:x,resolved:this.toAstProperty(s.PropertyConfigKey.resolved,e.resolved),resolvedDate:this.toAstProperty(s.PropertyConfigKey.resolvedDate,e.resolvedDate),resolvedBy:this.toAstProperty(s.PropertyConfigKey.resolvedBy,e.resolvedBy),handInAcceptFileType:this.toAstProperty(s.PropertyConfigKey.handInAcceptFileType,e.handInAcceptFileType),handInRequirement:this.toAstProperty(s.PropertyConfigKey.handInRequirement,e.handInRequirement),handInInstruction:this.toAstProperty(s.PropertyConfigKey.handInInstruction,e.handInInstruction),maxCreatedBits:this.toAstProperty(s.PropertyConfigKey.maxCreatedBits,e.maxCreatedBits),maxDisplayLevel:this.toAstProperty(s.PropertyConfigKey.maxDisplayLevel,e.maxDisplayLevel),maxTocChapterLevel:this.toAstProperty(s.PropertyConfigKey.maxTocChapterLevel,e.maxTocChapterLevel),page:this.toAstProperty(s.PropertyConfigKey.page,e.page),productId:this.toAstProperty(s.PropertyConfigKey.productId,e.productId),product:this.toAstProperty(s.PropertyConfigKey.product,e.product),productList:this.toAstProperty(s.PropertyConfigKey.productList,e.productList),productVideo:this.toAstProperty(s.PropertyConfigKey.productVideo,e.productVideo),productVideoList:this.toAstProperty(s.PropertyConfigKey.productVideoList,e.productVideoList),productFolder:this.toAstProperty(s.PropertyConfigKey.productFolder,e.productFolder),technicalTerm:this.buildTechnicalTerm(v,e.technicalTerm),servings:this.buildServings(v,e.servings),ratingLevelStart:this.buildRatingLevelStartEnd(v,e.ratingLevelStart),ratingLevelEnd:this.buildRatingLevelStartEnd(v,e.ratingLevelEnd),ratingLevelSelected:this.toAstProperty(s.PropertyConfigKey.ratingLevelSelected,e.ratingLevelSelected),markConfig:this.buildMarkConfigs(v,e.markConfig),imageSource:this.buildImageSource(v,e.imageSource),person:this.buildPerson(v,e.person),bot:this.toAstProperty(s.PropertyConfigKey.bot,e.bot),referenceProperty:this.toAstProperty(s.PropertyConfigKey.property_reference,e.referenceProperty),title:this.handleJsonText(v,!0,e.title),subtitle:this.handleJsonText(v,!0,e.subtitle),level:m.NumberUtils.asNumber(e.level),toc:this.toAstProperty(s.PropertyConfigKey.toc,e.toc),progress:this.toAstProperty(s.PropertyConfigKey.progress,e.progress),anchor:e.anchor,reference:e.reference,referenceEnd:e.referenceEnd,revealSolutions:this.toAstProperty(s.PropertyConfigKey.revealSolutions,e.revealSolutions),item:this.handleJsonText(v,!0,e.item),lead:this.handleJsonText(v,!0,e.lead),pageNumber:this.handleJsonText(v,!0,e.pageNumber),marginNumber:this.handleJsonText(v,!0,e.marginNumber),hint:this.handleJsonText(v,!0,e.hint),instruction:this.handleJsonText(v,!0,e.instruction),partialAnswer:this.toAstProperty(s.PropertyConfigKey.partialAnswer,e.partialAnswer),sampleSolution:this.toAstProperty(s.PropertyConfigKey.property_sampleSolution,e.sampleSolution),additionalSolutions:this.toAstProperty(s.PropertyConfigKey.additionalSolutions,e.additionalSolutions)},this.toExample(e.__isDefaultExample,e.example)),{imagePlaceholder:g.ArrayUtils.asSingle(this.resourceBuilder.resourceFromResourceDataJson(v,u.ResourceTag.image,null===(r=e.imagePlaceholder)||void 0===r?void 0:r.image)),resources:g.ArrayUtils.asArray(this.resourceBuilder.resourceFromResourceJson(v,e.resources)),body:this.buildBody(v,e.body),cardNode:P,footer:this.buildFooter(v,e.footer),extraProperties:this.parseExtraProperties(e.extraProperties),markup:e.markup,parser:e.parser,__isDefaultExample:null!==(i=e.__isDefaultExample)&&void 0!==i&&i});return a.Config.isOfBitType(K.bitType,l.BitType.interview)&&this.pushDownTree(v,void 0,void 0,P,"questions",s.PropertyConfigKey.reasonableNumOfChars,e.reasonableNumOfChars),a.Config.isOfBitType(K.bitType,l.BitType.feedback)&&this.pushDownTree(v,void 0,void 0,P,["feedbacks","reason"],s.PropertyConfigKey.reasonableNumOfChars,e.reasonableNumOfChars),this.pushDownTree(v,[K.body,...null!==(n=null===(o=null==P?void 0:P.cardBits)||void 0===o?void 0:o.map((e=>e.body)))&&void 0!==n?n:[]],[p.BodyBitType.gap],void 0,void 0,s.PropertyConfigKey.isCaseSensitive,null===(y=e.isCaseSensitive)||void 0===y||y),this.pushDownTree(v,void 0,void 0,P,"pairs",s.PropertyConfigKey.isCaseSensitive,null===(d=e.isCaseSensitive)||void 0===d||d),this.pushDownTree(v,void 0,void 0,P,["matrix","cells"],s.PropertyConfigKey.isCaseSensitive,null===(f=e.isCaseSensitive)||void 0===f||f),this.pushExampleDownTree(v,K.body,P,K.__isDefaultExample,k.example),this.setDefaultBitValues(K),this.setIsExampleFlags(K),this.addVersionToParserInfo(K),T.ObjectUtils.removeUnwantedProperties(K,{ignoreAllFalse:!0,ignoreUndefined:["example"],ignoreEmptyArrays:["item","lead","pageNumber","marginNumber","hint","instruction"]}),C.NodeValidator.validateBit(K)}buildBooks(e,t){if(h.StringUtils.isString(t))return t;if(!Array.isArray(t))return;const r=t.map((t=>this.buildBook(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildBook(e,t){var r,i,o;if(!t)return;const n={book:null!==(r=t.book)&&void 0!==r?r:"",reference:null!==(i=t.reference)&&void 0!==i?i:"",referenceEnd:null!==(o=t.referenceEnd)&&void 0!==o?o:void 0};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyString:["book","reference"]}),n}buildFeedbackChoices(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildFeedbackChoice(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildFeedbackChoice(e,t){var r;if(!t)return;const i=Object.assign({choice:null!==(r=t.choice)&&void 0!==r?r:"",requireReason:!!t.requireReason,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"]}),i}buildFeedbackReason(e,t){var r,i;if(!t)return;const o=this.handleJsonText(e,!0,"true"),n=Object.assign(Object.assign({text:null!==(r=t.text)&&void 0!==r?r:"",reasonableNumOfChars:null!==(i=t.reasonableNumOfChars)&&void 0!==i?i:void 0,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,o)),{__textAst:t.__textAst});return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example","reasonableNumOfChars"]}),n}buildChoices(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildChoice(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildChoice(e,t){var r;if(!t)return;const i=Object.assign({choice:null!==(r=t.choice)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"]}),i}buildResponses(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildResponse(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildResponse(e,t){var r;if(!t)return;const i=Object.assign({response:null!==(r=t.response)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"]}),i}buildBotResponses(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.botResponse(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}botResponse(e,t){var r,i,o;if(!t)return;const n={response:null!==(r=t.response)&&void 0!==r?r:"",reaction:null!==(i=t.reaction)&&void 0!==i?i:"",feedback:null!==(o=t.feedback)&&void 0!==o?o:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint)};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreEmptyString:["response","reaction","feedback"],ignoreAllFalse:!0,ignoreEmptyArrays:["item"],ignoreUndefined:["example"]}),n}buildFeedbacks(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildFeedback(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildFeedback(e,t){if(!t)return;let r,i;if(!t.choices)return;r=this.buildFeedbackChoices(e,t.choices),t.reason&&(i=this.buildFeedbackReason(e,t.reason));const o={item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),choices:r,reason:i};return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"]}),o}buildQuizzes(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildQuiz(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildQuiz(e,t){if(!t)return;const r=Object.assign({},this.toExample(t.__isDefaultExample,t.__defaultExample));let i,o;if(t.choices)i=this.buildChoices(e,t.choices),this.pushExampleDownTreeBoolean(e,t.__isDefaultExample,r.example,!0,i);else{if(!t.responses)return;o=this.buildResponses(e,t.responses),this.pushExampleDownTreeBoolean(e,t.__isDefaultExample,r.example,!1,o)}const n={item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isExample:!!t.__defaultExample,choices:i,responses:o};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"]}),n}buildHeading(e,t){var r,i,o;if(!t)return;if(null==t.forKeys)return;const n={forKeys:null!==(r=t.forKeys)&&void 0!==r?r:"",forValues:null!==(o=null!==(i=t.forValues)&&void 0!==i?i:t.__forValuesDefault)&&void 0!==o?o:""};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyString:["forKeys","forValues"],ignoreEmptyArrays:["forValues"]}),n}buildPairs(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildPair(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildPair(e,t){var r,i;if(!t)return;const o=Array.isArray(t.__valuesAst)&&t.__valuesAst.length>0?t.__valuesAst[0]:null,n=this.resourceBuilder.resourceFromResourceJson(e,t.keyAudio),a=this.resourceBuilder.resourceFromResourceJson(e,t.keyImage),s=Object.assign(Object.assign({key:null!==(r=t.key)&&void 0!==r?r:"",keyAudio:n,keyImage:a,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isCaseSensitive:t.isCaseSensitive},this.toExample(t.__isDefaultExample,t.example,o)),{values:null!==(i=t.values)&&void 0!==i?i:[],__valuesAst:t.__valuesAst});return T.ObjectUtils.removeUnwantedProperties(s,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction","values"],ignoreUndefined:["example","isCaseSensitive"]}),s}buildMatricies(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildMatrix(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildMatrix(e,t){var r,i,o;if(!t)return;let n=!1;for(const e of null!==(r=t.cells)&&void 0!==r?r:[])t.__isDefaultExample&&!e.isExample&&(e.isExample=!0),n=!!e.isExample||n;const a={key:null!==(i=t.key)&&void 0!==i?i:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isExample:n,cells:(null!==(o=t.cells)&&void 0!==o?o:[]).map((t=>this.buildMatrixCell(e,t))).filter((e=>null!=e))};return T.ObjectUtils.removeUnwantedProperties(a,{ignoreAllFalse:!0,ignoreEmptyArrays:["hint","item","cells"],ignoreUndefined:["isCaseSensitive"]}),a}buildMatrixCell(e,t){var r;if(!t)return;const i=Array.isArray(t.__valuesAst)&&t.__valuesAst.length>0?t.__valuesAst[0]:null,o=Object.assign(Object.assign({values:null!==(r=t.values)&&void 0!==r?r:[],item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isCaseSensitive:t.isCaseSensitive},this.toExample(t.__isDefaultExample,t.example,i)),{__valuesAst:t.__valuesAst});return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreEmptyArrays:["instruction","item","values"],ignoreUndefined:["example","isCaseSensitive"]}),o}buildPronunciationTable(e,t){var r;if(!t)return;return{data:(null!==(r=t.data)&&void 0!==r?r:[]).map((t=>(null!=t?t:[]).map((t=>{const r=this.resourceBuilder.resourceFromResourceJson(e,t.audio);return{title:this.handleJsonText(e,!0,t.title),body:this.handleJsonText(e,!0,t.body),audio:r}}))))}}buildTable(e,t){var r,i;if(!t)return;return{columns:(null!==(r=t.columns)&&void 0!==r?r:[]).map((t=>this.handleJsonText(e,!0,t))),data:(null!==(i=t.data)&&void 0!==i?i:[]).map((t=>(null!=t?t:[]).map((t=>this.handleJsonText(e,!0,t)))))}}buildQuestions(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildQuestion(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildQuestion(e,t){var r,i,o,n,a;if(!t)return;const s=t.__sampleSolutionAst,l=Object.assign(Object.assign({question:null!==(r=t.question)&&void 0!==r?r:"",partialAnswer:null!==(i=t.partialAnswer)&&void 0!==i?i:"",sampleSolution:null!==(o=t.sampleSolution)&&void 0!==o?o:"",additionalSolutions:null!==(n=t.additionalSolutions)&&void 0!==n?n:void 0,reasonableNumOfChars:null!==(a=t.reasonableNumOfChars)&&void 0!==a?a:void 0,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,s)),{__sampleSolutionAst:t.__sampleSolutionAst});return T.ObjectUtils.removeUnwantedProperties(l,{ignoreAllFalse:!0,ignoreEmptyArrays:["item","hint","instruction"],ignoreUndefined:["example"],ignoreEmptyString:["question","partialAnswer","sampleSolution"]}),l}buildIngredients(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildIngredient(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildIngredient(e,t){var r,i,o,n,a,s,l,p;if(!t)return;const u={title:null!==(r=t.title)&&void 0!==r?r:"",checked:null!==(i=t.checked)&&void 0!==i&&i,item:null!==(o=t.item)&&void 0!==o?o:"",quantity:null!==(n=t.quantity)&&void 0!==n?n:0,unit:null!==(a=t.unit)&&void 0!==a?a:"",unitAbbr:null!==(s=t.unitAbbr)&&void 0!==s?s:"",decimalPlaces:null!==(l=t.decimalPlaces)&&void 0!==l?l:1,disableCalculation:null!==(p=t.disableCalculation)&&void 0!==p&&p};return T.ObjectUtils.removeUnwantedProperties(u,{ignoreAllFalse:!0,ignoreEmptyString:["item","unit"]}),u}buildBody(e,t){if(!t)return;let r;const i=[],a=t.placeholders,s=t.bodyString,{textFormat:l}=e,u=()=>{var s;let u,c=t.body;const g={};if(h.StringUtils.isString(t.body)?(u=(null!==(s=t.body)&&void 0!==s?s:"").trim(),c=[]):Array.isArray(t.body)||(c=[]),a)for(const[e,t]of Object.entries(a))g[e]=t;if(u){u=n.Breakscape.breakscape(u,{textFormat:l,textLocation:y.TextLocation.body,v2:!0});let e=0;const t=[];for(const[r,i]of Object.entries(g))if(u){const o=`[!${e}]`;u=u.replace(`${r}`,o),t.push(i),e++}c=this.textParser.toAst(u,{textFormat:l,isProperty:!1});const r=e=>{for(let i=0,o=e.length;i<o;i++){const o=e[i];if("bit"===o.type){const r=o.index;null!=t[r]&&(e[i]=t[r])}else o.content&&r(o.content)}};r(c)}c=(0,o.default)(c),this.textParser.walkBodyBits(c,((t,r,o)=>{let n;switch(o.type){case p.BodyBitType.gap:n=this.buildGap(e,o);break;case p.BodyBitType.mark:n=this.buildMark(e,o);break;case p.BodyBitType.select:n=this.buildSelect(e,o);break;case p.BodyBitType.highlight:n=this.buildHighlight(e,o)}null!=n&&(t[r]=n,i.push(n))})),r=c,r.__tag="text"},g=l===c.TextFormat.bitmarkMinusMinus||l===c.TextFormat.bitmarkPlusPlus;l===c.TextFormat.json?(()=>{if("string"==typeof t.body)try{r=JSON.parse(t.body)}catch(e){r=null}else r=t.body})():g?u():r=t.body;return{body:r,bodyBits:i,bodyString:s}}buildFooter(e,t){if(!t)return;return{footer:this.handleJsonText(e,!1,t.footer)}}buildGap(e,t){var r;if(!t)return;const i=Array.isArray(t.__solutionsAst)&&t.__solutionsAst.length>0?t.__solutionsAst[0]:null;t=this.bodyBitCopyFromAttrs(t);const o=Object.assign(Object.assign({type:p.BodyBitType.gap,solutions:null!==(r=t.solutions)&&void 0!==r?r:[],item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction),isCaseSensitive:t.isCaseSensitive},this.toExample(t.__isDefaultExample,t.example,i)),{__solutionsAst:t.__solutionsAst,attrs:{}});return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example","isCaseSensitive"]}),o}buildMarkConfigs(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildMarkConfig(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildMarkConfig(e,t){var r,i,o;if(!t)return;const n={mark:null!==(r=t.mark)&&void 0!==r?r:"unknown",color:null!==(i=t.color)&&void 0!==i?i:"",emphasis:null!==(o=t.emphasis)&&void 0!==o?o:""};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllEmptyString:!0}),n}buildMark(e,t){var r,i;if(!t)return;t=this.bodyBitCopyFromAttrs(t);const o=Object.assign(Object.assign({type:p.BodyBitType.mark,solution:null!==(r=t.solution)&&void 0!==r?r:"",mark:null!==(i=t.mark)&&void 0!==i?i:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0)),{attrs:{}});return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example"],ignoreEmptyString:["solution","mark"]}),o}buildSelect(e,t){var r,i,o;if(!t)return;t=this.bodyBitCopyFromAttrs(t);const n=Object.assign(Object.assign({type:p.BodyBitType.select,options:null!==(r=this.buildSelectOptions(e,t.options))&&void 0!==r?r:[],prefix:null!==(i=t.prefix)&&void 0!==i?i:"",postfix:null!==(o=t.postfix)&&void 0!==o?o:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(!1,void 0,void 0)),{__hintString:t.__hintString,__instructionString:t.__instructionString,attrs:{}});return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreEmptyString:["prefix","postfix"]}),n}buildSelectOptions(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildSelectOption(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildSelectOption(e,t){var r;if(!t)return;const i=Object.assign({text:null!==(r=t.text)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example"]}),i}buildHighlight(e,t){var r,i,o;if(!t)return;t=this.bodyBitCopyFromAttrs(t);const n=Object.assign(Object.assign({type:p.BodyBitType.highlight,texts:null!==(r=this.buildHighlightTexts(e,t.texts))&&void 0!==r?r:[],prefix:null!==(i=t.prefix)&&void 0!==i?i:"",postfix:null!==(o=t.postfix)&&void 0!==o?o:"",item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(!1,void 0,void 0)),{attrs:{}});return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreEmptyString:["prefix","postfix"]}),n}buildHighlightTexts(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildHighlightText(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildHighlightText(e,t){var r;if(!t)return;const i=Object.assign({text:null!==(r=t.text)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,isHighlighted:!!t.isHighlighted,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreAllEmptyArrays:!0,ignoreUndefined:["example"]}),i}buildFlashcards(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildFlashcard(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildFlashcard(e,t){var r;if(!t)return;const i=Object.assign({question:this.buildTextAndIcon(e,t.question),answer:this.buildTextAndIcon(e,t.answer),alternativeAnswers:(null!==(r=t.alternativeAnswers)&&void 0!==r?r:[]).map((t=>this.buildTextAndIcon(e,t))).filter((e=>null!=e)),item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreEmptyArrays:["question","answer","alternativeAnswers","item","hint","instruction"],ignoreUndefined:["example"]}),i}buildDefinitionList(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildDefinitionListItem(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildDefinitionListItem(e,t){var r;if(!t)return;const{bitType:i}=e,o=a.Config.isOfBitType(i,[l.BitType.metaSearchDefaultTerms]),n=Object.assign({term:this.buildTextAndIcon(e,t.term,o),definition:this.buildTextAndIcon(e,t.definition,o),alternativeDefinitions:(null!==(r=t.alternativeDefinitions)&&void 0!==r?r:[]).map((t=>this.buildTextAndIcon(e,t,o))).filter((e=>null!=e)),item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!0));return T.ObjectUtils.removeUnwantedProperties(n,{ignoreAllFalse:!0,ignoreEmptyArrays:["question","answer","alternativeDefinitions","item","hint","instruction"],ignoreUndefined:["example"]}),n}buildTextAndIcon(e,t,r=!1){const i=this.resourceBuilder.resourceFromResourceJson(e,null==t?void 0:t.icon);let o=this.handleJsonText(e,!0,null==t?void 0:t.text);r&&(o=this.textGenerator.generateSync(o,c.TextFormat.text,y.TextLocation.body,{noBreakscaping:!0}).trim());const n={text:o,icon:i};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreEmptyArrays:["text"],ignoreUndefined:["icon"]}),n}buildStatements(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildStatement(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildStatement(e,t){var r;if(!t)return;const i=Object.assign({statement:null!==(r=t.statement)&&void 0!==r?r:"",isCorrect:!!t.isCorrect,item:this.handleJsonText(e,!0,t.item),lead:this.handleJsonText(e,!0,t.lead),hint:this.handleJsonText(e,!0,t.hint),instruction:this.handleJsonText(e,!0,t.instruction)},this.toExample(t.__isDefaultExample,t.example,!!t.isCorrect));return T.ObjectUtils.removeUnwantedProperties(i,{ignoreAllFalse:!0,ignoreUndefined:["example"]}),i}buildImageSource(e,t){if(!t)return;const{url:r,mockupId:i,size:o,format:n,trim:a}=t,s={url:null!=r?r:"",mockupId:null!=i?i:"",size:null!=o?o:null,format:null!=n?n:null,trim:f.BooleanUtils.isBoolean(a)?a:null};return T.ObjectUtils.removeUnwantedProperties(s,{ignoreFalse:["trim"],ignoreEmptyString:["url","mockupId"],ignoreAllUndefined:!0}),s}buildPerson(e,t){if(!t)return;const{name:r,title:i,avatarImage:o}=t,n={name:null!=r?r:"",title:null!=i?i:void 0,avatarImage:this.resourceBuilder.resourceFromResourceJson(e,o)};return T.ObjectUtils.removeUnwantedProperties(n,{ignoreEmptyString:["name"],ignoreAllUndefined:!0}),n}buildTechnicalTerm(e,t){if(!t)return;const{technicalTerm:r,lang:i}=t,o={technicalTerm:null!=r?r:"",lang:null!=i?i:""};return T.ObjectUtils.removeUnwantedProperties(o,{ignoreEmptyString:["technicalTerm"]}),o}buildServings(e,t){if(!t)return;const{servings:r,unit:i,unitAbbr:o,decimalPlaces:n,disableCalculation:a,hint:s}=t,l={servings:null!=r?r:0,unit:null!=i?i:"",unitAbbr:null!=o?o:"",decimalPlaces:null!=n?n:1,disableCalculation:null!=a&&a,hint:null!=s?s:""};return T.ObjectUtils.removeUnwantedProperties(l,{ignoreEmptyString:["servings","unit"]}),l}buildRatingLevelStartEnd(e,t){if(!t)return;const{level:r,label:i}=t,o={level:null!=r?r:0,label:this.handleJsonText(e,!0,i)};return T.ObjectUtils.removeUnwantedProperties(o,{}),o}buildCardBits(e,t){if(!Array.isArray(t))return;const r=t.map((t=>this.buildCardBit(e,t))).filter((e=>null!=e));return r.length>0?r:void 0}buildCardBit(e,t){if(!t)return;const{bitType:r,textFormat:i}=e,o=this.buildBit(Object.assign(Object.assign({},t),{bitType:r,textFormat:i}));return T.ObjectUtils.removeUnwantedProperties(o,{ignoreAllFalse:!0,ignoreUndefined:["example"]}),C.NodeValidator.validateCardBit(o)}buildCardNode(e,t){var r;const i={heading:this.buildHeading(e,t.heading),questions:this.buildQuestions(e,t.questions),elements:t.elements,flashcards:this.buildFlashcards(e,t.flashcards),definitions:this.buildDefinitionList(e,null!==(r=t.definitions)&&void 0!==r?r:t.legend),statement:this.buildStatement(e,t.statement),statements:this.buildStatements(e,t.statements),choices:this.buildChoices(e,t.choices),responses:this.buildResponses(e,t.responses),feedbacks:this.buildFeedbacks(e,t.feedbacks),quizzes:this.buildQuizzes(e,t.quizzes),pairs:this.buildPairs(e,t.pairs),matrix:this.buildMatricies(e,t.matrix),pronunciationTable:this.buildPronunciationTable(e,t.pronunciationTable),table:this.buildTable(e,t.table),botResponses:this.buildBotResponses(e,t.botResponses),ingredients:this.buildIngredients(e,t.ingredients),cardBits:this.buildCardBits(e,t.cardBits)};return T.ObjectUtils.removeUnwantedProperties(i),Object.keys(i).length>0?i:void 0}bodyBitCopyFromAttrs(e){const t=Object.assign({},e);if(e.attrs)for(const[r,i]of Object.entries(e.attrs))t[r]=i;return t}pushExampleDownTree(e,t,r,i,o){if(i||null!=o){if(r){if(this.pushExampleDownTreeString(e,i,o,r.pairs),this.pushExampleDownTreeBoolean(e,i,o,!1,r.flashcards),this.pushExampleDownTreeBoolean(e,i,o,!1,r.definitions),this.pushExampleDownTreeBoolean(e,i,o,!0,r.choices),this.pushExampleDownTreeBoolean(e,i,o,!1,r.responses,r.statements,r.statement),r.quizzes)for(const t of r.quizzes)this.pushExampleDownTreeBoolean(e,i,o,!0,t.choices),this.pushExampleDownTreeBoolean(e,i,o,!1,t.responses);if(r.matrix)for(const t of r.matrix)this.pushExampleDownTreeString(e,i,o,t.cells)}t&&this.pushExampleDownTreeBodyBits(e,i,o,t)}}pushExampleDownTreeBoolean(e,t,r,i,...o){if((t||null!=r)&&Array.isArray(o))for(const e of o)if(e){const o=Array.isArray(e)?e:[e];d.BitUtils.fillBooleanExample(o,t,r,i)}}pushExampleDownTreeString(e,t,r,...i){if((t||r)&&Array.isArray(i))for(const o of i)if(o){const i=Array.isArray(o)?o:[o];d.BitUtils.fillStringExample(e.textFormat,i,t,r,!1)}}pushExampleDownTreeBodyBits(e,t,r,i){if(!t&&!r)return;const o=this.textParser.extractBodyBits(null==i?void 0:i.body);for(const i of o)if(i)switch(i.type){case p.BodyBitType.gap:{const o=i;d.BitUtils.fillStringExample(e.textFormat,[o],t,r,!1);break}case p.BodyBitType.mark:{const e=i;d.BitUtils.fillBooleanExample([e],t,r,!1);break}case p.BodyBitType.select:{const e=i;d.BitUtils.fillBooleanExample(e.options,t,r,!0);break}case p.BodyBitType.highlight:{const e=i;d.BitUtils.fillBooleanExample(e.texts,t,r,!0);break}}}pushDownTree(e,t,r,i,o,n,a){if(void 0!==a){if(i&&o){Array.isArray(o)||(o=[o]);const e=T.ObjectUtils.flatMapPath(i,o);for(const t of e)null==t[n]&&(t[n]=a)}if(t){const e=Array.isArray(t)?t:[t];for(const t of e)if(t&&t.body&&r){const e=this.textParser.extractBodyBits(t.body);if(r&&e&&e.length>0)for(const t of e)if(t&&-1!==r.indexOf(t.type)){const e=t;null==e[n]&&(e[n]=a)}}}}}parseExtraProperties(e){if(!e)return;const t=Object.entries(e);if(0===t.length)return;const r={};for(const[e,i]of t)r[e]=g.ArrayUtils.asArray(i)||[i];return r}setIsExampleFlags(e){var t,r,i,o,n,a,s,l,u,c,y,g,d,f;const m=t=>!!t&&(t.isExample||null!=t.example?(t.isExample=!0,e.isExample=!0):t.isExample=t===e&&!!e.isExample,t.isExample),{body:T,cardNode:h}=e,b=this.textParser.extractBodyBits(null==T?void 0:T.body);for(const e of b)switch(e.type){case p.BodyBitType.gap:case p.BodyBitType.mark:m(e);break;case p.BodyBitType.select:{const t=e;let r=!1;for(const e of t.options)r=!!m(e)||r;t.isExample=r;break}case p.BodyBitType.highlight:{const t=e;let r=!1;for(const e of t.texts)r=!!m(e)||r;t.isExample=r;break}}if(h){for(const e of null!==(t=h.flashcards)&&void 0!==t?t:[])m(e);for(const e of null!==(r=h.definitions)&&void 0!==r?r:[])m(e);for(const e of null!==(i=h.pairs)&&void 0!==i?i:[])m(e);for(const e of null!==(o=h.matrix)&&void 0!==o?o:[]){let t=!1;for(const r of null!==(n=e.cells)&&void 0!==n?n:[])t=!!m(r)||t;e.isExample=t}for(const e of null!==(a=h.quizzes)&&void 0!==a?a:[]){let t=!1;for(const r of null!==(s=e.responses)&&void 0!==s?s:[])t=!!m(r)||t;for(const r of null!==(l=e.choices)&&void 0!==l?l:[])t=!!m(r)||t;e.isExample=t}for(const e of null!==(u=h.responses)&&void 0!==u?u:[])m(e);for(const e of null!==(c=h.choices)&&void 0!==c?c:[])m(e);for(const e of null!==(y=h.statements)&&void 0!==y?y:[])m(e);m(h.statement);for(const e of null!==(g=h.questions)&&void 0!==g?g:[])m(e)}m(e.statement);for(const t of null!==(d=e.responses)&&void 0!==d?d:[])m(t);for(const t of null!==(f=e.choices)&&void 0!==f?f:[])m(t);m(e)}setDefaultBitValues(e){switch(e.bitType){case l.BitType.articleAi:case l.BitType.noteAi:case l.BitType.summaryAi:e.aiGenerated=this.toAstProperty(s.PropertyConfigKey.aiGenerated,!0)}}addVersionToParserInfo(e){var t;const r=null!==(t=e.parser)&&void 0!==t?t:{};r.version=b.env.appVersion.full,e.parser=r}}t.Builder=P},5814:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardSetConfig=void 0;t.CardSetConfig=class{constructor(e,t){this.configKey=e,this.variants=t}toString(e){const t=Object.assign({},e);let r="",i=0,o=0;for(const e of this.variants){for(const n of e)r+=`[Card - Side ${i}, Variant ${o}]`,r+=`\n${n.toString(t)}`,o++;i++}return r}}},5837:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GROUPS=void 0;const i=r(7112),o=r(6915),n=r(9888),a=r(5051),s=r(7797),l=r(5512),p=r(3778),u=r(6149),c={[i.GroupConfigKey.group_standardAllBits]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.id,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.customerId},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.externalId,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.aiGenerated},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.machineTranslated},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.searchIndex,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.analyticsTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.categoryTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.topicTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.altLangTag},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.feedbackEngine},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.feedbackType},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.disableFeedback},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffTo},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffOp},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffRef},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffContext},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.diffTime},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.ageRange,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.lang},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.publisher,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.publisherName,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.theme,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.target,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.tag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.reductionTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.bubbleTag,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelCEFRp},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelCEFR},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelILR},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.levelACTFL},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.icon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.iconTag},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.colorTag,maxCount:p.Count.infinity},{type:l.BitTagType.tag,configKey:s.TagConfigKey.anchor},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.search},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.showInIndex},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.layer,maxCount:p.Count.infinity}]},[i.GroupConfigKey.group_standardItemLeadInstructionHint]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.itemLead,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.itemLead,maxCount:3}]},{type:l.BitTagType.tag,configKey:s.TagConfigKey.instruction},{type:l.BitTagType.tag,configKey:s.TagConfigKey.hint}]},[i.GroupConfigKey.group_standardExample]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.example}]},[i.GroupConfigKey.group_standardTags]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardAllBits},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]},[i.GroupConfigKey.group_imageSource]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.imageSource,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.mockupId},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.size},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.format},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.trim}]}]},[i.GroupConfigKey.group_technicalTerm]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.technicalTerm,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.lang}]}]},[i.GroupConfigKey.group_person]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.person,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_title},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImage}]},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.partner,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_title},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImage}]}]},[i.GroupConfigKey.group_gap]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.gap,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.gap,maxCount:p.Count.infinity},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}]}]},[i.GroupConfigKey.group_trueFalse]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:p.Count.infinity},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:p.Count.infinity},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.true,maxCount:p.Count.infinity},{type:l.BitTagType.tag,configKey:s.TagConfigKey.false,maxCount:p.Count.infinity},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardItemLeadInstructionHint},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]}]},[i.GroupConfigKey.group_markConfig]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.markConfig,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.color},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.emphasis}]}]},[i.GroupConfigKey.group_mark]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.tag_mark,maxCount:p.Count.infinity,chain:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.property_mark},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_standardExample}]}]},[i.GroupConfigKey.group_bookCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.language,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.customerExternalId,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.spaceId,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.kind},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.hasMarkAsDone},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.processHandIn},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isPublic},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.chatWithBook},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.chatWithBookBrainKey},{type:l.BitTagType.tag,configKey:s.TagConfigKey.title,maxCount:2},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.subtype,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.coverImage,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.coverColor},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.subject,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.author,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.publications,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.maxTocChapterLevel}]},[i.GroupConfigKey.group_learningPathCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.action},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.date},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.dateEnd},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.location},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.list,maxCount:p.Count.infinity},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.textReference},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isTracked},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.isInfoOnly},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.deeplink},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.book,chain:[{type:l.BitTagType.tag,configKey:s.TagConfigKey.tag_reference,maxCount:2}]}]},[i.GroupConfigKey.group_quizCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.revealSolutions}]},[i.GroupConfigKey.group_resourceBitTags]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.imagePlaceholder,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}],maxCount:1}]},[i.GroupConfigKey.group_resourceCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.property,configKey:n.PropertyConfigKey.license},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.copyright},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.caption},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.showInIndex},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.search}]},[i.GroupConfigKey.group_resourceImageCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src1x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src2x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src3x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src4x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.alt},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.zoomDisabled}]},[i.GroupConfigKey.group_resourceAudioCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.mute},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.autoplay}]},[i.GroupConfigKey.group_resourceVideoCommon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.duration},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.mute},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.autoplay},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.allowSubtitles},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.showSubtitles},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.alt},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.posterImage,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src1x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src2x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src3x},{type:l.BitTagType.property,configKey:n.PropertyConfigKey.src4x}]},[i.GroupConfigKey.group_resourceIcon]:{type:o.GroupConfigType.standard,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.icon,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImage]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.image,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImagePortrait]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imagePortrait,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImageLandscape]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imageLandscape,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImageEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imageEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceImageLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.imageLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageCommon}]}]},[i.GroupConfigKey.group_resourceAudio]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audio,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudioCommon}]}]},[i.GroupConfigKey.group_resourceAudioEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audioEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudioCommon}]}]},[i.GroupConfigKey.group_resourceAudioLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.audioLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudioCommon}]}]},[i.GroupConfigKey.group_resourceVideo]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.video,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceVideoEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.videoEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceVideoLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.videoLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceStillImageFilmEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.stillImageFilmEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceStillImageFilmLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.stillImageFilmLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceVideoCommon}]}]},[i.GroupConfigKey.group_resourceArticle]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.article,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceArticleEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.articleEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceArticleLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.articleLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocument]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.document,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocumentEmbed]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.documentEmbed,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocumentLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.documentLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceDocumentDownload]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.documentDownload,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceAppLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.appLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceWebsiteLink]:{type:o.GroupConfigType.resource,tags:[{type:l.BitTagType.resource,configKey:a.ResourceConfigKey.websiteLink,chain:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceCommon}]}]},[i.GroupConfigKey.group_resourceStillImageFilm]:{type:o.GroupConfigType.comboResource,comboResourceType:u.ResourceTag.stillImageFilm,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImage,maxCount:1,minCount:1},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceAudio,maxCount:1,minCount:1}]},[i.GroupConfigKey.group_resourceImageResponsive]:{type:o.GroupConfigType.comboResource,comboResourceType:u.ResourceTag.imageResponsive,tags:[{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImagePortrait,maxCount:1,minCount:1},{type:l.BitTagType.group,configKey:i.GroupConfigKey.group_resourceImageLandscape,maxCount:1,minCount:1}]}};t.GROUPS=c},5854:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitType=void 0;const i=(0,r(4718).superenum)({_error:"_error",_comment:"_comment",_standard:"_standard",aiPrompt:"ai-prompt",anchor:"anchor",appAiPrompt:"app-ai-prompt",appBitmarkFromEditor:"app-bitmark-from-editor",appBitmarkFromJavascript:"app-bitmark-from-javascript",appCodeCell:"app-code-cell",appCodeEditor:"app-code-editor",appCodeIde:"app-code-ide",appCreateBitsFromImage:"app-create-bits-from-image",appFlashcards:"app-flashcards",appFlashcardsLearn:"app-flashcards-learn",appFlashcardsQuiz:"app-flashcards-quiz",appGetScreenshot:"app-get-screenshot",appLink:"app-link",article:"article",articleAi:"article-ai",articleAlt:"article-alt",articleAttachment:"article-attachment",articleEmbed:"article-embed",articleLink:"article-link",articleResponsive:"article-responsive",articleResponsiveAlt:"article-responsive-alt",assignment:"assignment",assignmentList:"assignment-list",audio:"audio",audioEmbed:"audio-embed",audioLink:"audio-link",audioTranscript:"audio-transcript",bitAlias:"bit-alias",bitBookEnding:"bit-book-ending",bitBookSummary:"bit-book-summary",bitmarkExample:"bitmark-example",blogArticle:"blog-article",book:"book",bookAcknowledgements:"book-acknowledgements",bookAddendum:"book-addendum",bookAfterword:"book-afterword",bookAlias:"book-alias",bookAppendix:"book-appendix",bookArticle:"book-article",bookAutherBio:"book-author-bio",bookBibliography:"book-bibliography",bookClose:"book-close",bookComingSoon:"book-coming-soon",bookConclusion:"book-conclusion",bookCopyright:"book-copyright",bookCopyrightPermissions:"book-copyright-permissions",bookDedication:"book-dedication",bookDiff:"book-diff",bookEndnotes:"book-endnotes",bookEpigraph:"book-epigraph",bookEpilogue:"book-epilogue",bookForword:"book-foreword",bookFrontispiece:"book-frontispiece",bookImprint:"book-imprint",bookIncitingIncident:"book-inciting-incident",bookIntroduction:"book-introduction",bookLink:"book-link",bookLinkNext:"book-link-next",bookLinkPrev:"book-link-prev",bookListOfContributors:"book-list-of-contributors",bookNotes:"book-notes",bookPostscript:"book-postscript",bookPreface:"book-preface",bookPrologue:"book-prologue",bookReadMore:"book-read-more",bookReference:"book-reference",bookReferenceList:"book-reference-list",bookRequestForABookReview:"book-request-for-a-book-review",bookSummary:"book-summary",bookTeaser:"book-teaser",bookTitle:"book-title",botActionAnnounce:"bot-action-announce",botActionRatingNumber:"bot-action-rating-number",botActionRemind:"bot-action-remind",botActionResponse:"bot-action-response",botActionSave:"bot-action-save",botActionSend:"bot-action-send",botActionTrueFalse:"bot-action-true-false",botInterview:"bot-interview",browserImage:"browser-image",bug:"bug",bugAlt:"bug-alt",bugCollapsible:"bug-collapsible",buttonCopyText:"button-copy-text",callToAction:"call-to-action",callToActionBookNow:"call-to-action-book-now",callToActionContact:"call-to-action-contact",callToActionCreateAccount:"call-to-action-create-account",callToActionDownload:"call-to-action-download",callToActionGetNow:"call-to-action-get-now",callToActionGetOffer:"call-to-action-get-offer",callToActionJoin:"call-to-action-join",callToActionLearnMore:"call-to-action-learn-more",callToActionMail:"call-to-action-mail",callToActionSeeMore:"call-to-action-see-more",callToActionShopNow:"call-to-action-shop-now",callToActionStartNow:"call-to-action-start-now",callToActionSubscribe:"call-to-action-subscribe",callToActionWatch:"call-to-action-watch",card1:"card-1",chapter:"chapter",chapterSubjectMatter:"chapter-subject-matter",chat:"chat",checklist:"checklist",cloze:"cloze",clozeAndMultipleChoiceText:"cloze-and-multiple-choice-text",clozeInstructionGrouped:"cloze-instruction-grouped",clozeList:"cloze-list",clozeSeveral:"cloze-several",clozeSolutionGrouped:"cloze-solution-grouped",coachAudioTranscript:"coach-audio-transcript",coachCallToActionChecklist:"coach-call-to-action-checklist",coachCallToActionCloze:"coach-call-to-action-cloze",coachCallToActionClozeAndMultipleChoiceText:"coach-call-to-action-cloze-and-multiple-choice-text",coachCallToActionEssay:"coach-call-to-action-essay",coachCallToActionMultipleChoiceText:"coach-call-to-action-multiple-choice-text",coachHomeRules:"coach-home-rules",coachSelfReflectionCloze:"coach-self-reflection-cloze",coachSelfReflectionEssay:"coach-self-reflection-essay",coachSelfReflectionMultipleChoice:"coach-self-reflection-multiple-choice",coachSelfReflectionMultipleChoice1:"coach-self-reflection-multiple-choice-1",coachSelfReflectionMultipleChoiceText:"coach-self-reflection-multiple-choice-text",coachSelfReflectionMultipleResponse:"coach-self-reflection-multiple-response",coachSelfReflectionMultipleResponse1:"coach-self-reflection-multiple-response-1",coachSelfReflectionRating:"coach-self-reflection-rating",coachVideoTranscript:"coach-video-transcript",code:"code",codeRuntime:"code-runtime",collapsible:"collapsible",conclusion:"conclusion",conclusionAlt:"conclusion-alt",consoleLog:"console-log",container:"container",containerAccordionTabs:"container-accordion-tabs",containerBits2:"container-bits-2",containerCards:"container-cards",containerCarousel:"container-carousel",containerCookRecipe:"container-cook-recipe",containerFolder:"container-folder",containerFolderAll:"container-folder-all",containerGallery:"container-gallery",containerGrid:"container-grid",containerGroup:"container-group",containerNewsArticle:"container-news-article",containerNowrap:"container-nowrap",containerNowrapStretch:"container-nowrap-stretch",containerPreview:"container-preview",containerScroller:"container-scroller",containerSlides:"container-slides",containerStack:"container-stack",containerTabs:"container-tabs",containerWrap:"container-wrap",conversationLeft1:"conversation-left-1",conversationLeft1Scream:"conversation-left-1-scream",conversationLeft1Thought:"conversation-left-1-thought",conversationRight1:"conversation-right-1",conversationRight1Scream:"conversation-right-1-scream",conversationRight1Thought:"conversation-right-1-thought",cookArrangement:"cook-arrangement",cookIngredients:"cook-ingredients",cookInsert:"cook-insert",cookPersonalRecommendation:"cook-personal-recommendation",cookPlate:"cook-plate",cookPracticeAdvise:"cook-practice-advise",cookPreparation:"cook-preparation",cookRecommendation:"cook-recommendation",cookRemark:"cook-remark",cookSideDish:"cook-side-dish",cookSideDrink:"cook-side-drink",cookStep:"cook-step",cookTimer:"cook-timer",cookVariation:"cook-variation",correction:"correction",danger:"danger",dangerAlt:"danger-alt",dangerCollapsible:"danger-collapsible",definitionList:"definition-list",definitionTerm:"definition-term",deleted:"deleted",details:"details",details1:"details-1",detailsImage:"details-image",diff:"diff",document:"document",documentDownload:"document-download",documentEmbed:"document-embed",documentLink:"document-link",documentUpload:"document-upload",editorial:"editorial",editorNote:"editor-note",essay:"essay",example:"example",exampleAlt:"example-alt",exampleCollapsible:"example-collapsible",exampleList:"example-list",extractorAiChat:"extractor-ai-chat",extractorBlock:"extractor-block",extractorConfiguration:"extractor-configuration",extractorInformation:"extractor-information",extractorPage:"extractor-page",extractorPageCollapsible:"extractor-page-collapsible",extractorPageFooter:"extractor-page-footer",extractorPageFooterCollapsible:"extractor-page-footer-collapsible",extractorPageHeader:"extractor-page-header",extractorPageHeaderCollapsible:"extractor-page-header-collapsible",extractorPageNumber:"extractor-page-number",extractorPageNumberCollapsible:"extractor-page-number-collapsible",extractorPageWithBlocks:"extractor-page-with-blocks",extractorPageWithBlocksCollapsible:"extractor-page-with-blocks-collapsible",extractorRepeatedText:"extractor-repeated-text",featured:"featured",feedback:"feedback",figure:"figure",flashcard:"flashcard",flashcard1:"flashcard-1",focusImage:"focus-image",footNote:"foot-note",formula:"formula",gapText:"gap-text",gapTextInstructionGrouped:"gap-text-instruction-grouped",glossaryTerm:"glossary-term",groupBorn:"group-born",groupDied:"group-died",handInAudio:"hand-in-audio",handInContact:"hand-in-contact",handInDocument:"hand-in-document",handInFile:"hand-in-file",handInLocation:"hand-in-location",handInPhoto:"hand-in-photo",handInScan:"hand-in-scan",handInSubmit:"hand-in-submit",handInVideo:"hand-in-video",handInVoice:"hand-in-voice",help:"help",helpAlt:"help-alt",highlightText:"highlight-text",hint:"hint",hintAlt:"hint-alt",hintCollapsible:"hint-collapsible",image:"image",imageBanner:"image-banner",imageFigure:"image-figure",imageFigureAlt:"image-figure-alt",imageLandscape:"image-landscape",imageLink:"image-link",imageMood:"image-mood",imageOnDevice:"image-on-device",imagePortrait:"image-portrait",imagePrototype:"image-prototype",imageResponsive:"image-responsive",imageScreenshot:"image-screenshot",imageSeparator:"image-separator",imageSeparatorAlt:"image-separator-alt",imagesLogoGrave:"images-logo-grave",imageStyled:"image-styled",imageSuperWide:"image-super-wide",imageZoom:"image-zoom",indexTerm:"index-term",info:"info",infoAlt:"info-alt",infoCollapsible:"info-collapsible",internalLink:"internal-link",interview:"interview",interviewInstructionGrouped:"interview-instruction-grouped",langAudioScript:"lang-audio-script",langEnablingLanguageSkills:"lang-enabling-language-skills",langEnglishAroundWorld:"lang-english-around-world",langExtraActivity:"lang-extra-activity",langGoodToKnow:"lang-good-to-know",langHomework:"lang-homework",langLearningGoal:"lang-learning-goal",langLearningOutcomes:"lang-learning-outcomes",langLearningStrategy:"lang-learning-strategy",langLevelDown:"lang-level-down",langLevelUp:"lang-level-up",langLifeSkillIcon:"lang-life-skill-icon",langLifeSkills:"lang-life-skills",langLikeALocal:"lang-like-a-local",langMaterial:"lang-material",langTeacherNote:"lang-teacher-note",langTeacherPronunciation:"lang-teacher-pronunciation",langUsefulPhrases:"lang-useful-phrases",langVideoScript:"lang-video-script",langVocabulary:"lang-vocabulary",learningDocumentationFeedback:"learning-documentation-feedback",learningPathBook:"learning-path-book",learningPathBotTraining:"learning-path-bot-training",learningPathClassroomEvent:"learning-path-classroom-event",learningPathClassroomTraining:"learning-path-classroom-training",learningPathClosing:"learning-path-closing",learningPathExternalLink:"learning-path-external-link",learningPathFeedback:"learning-path-feedback",learningPathLearningGoal:"learning-path-learning-goal",learningPathLti:"learning-path-lti",learningPathSign:"learning-path-sign",learningPathStep:"learning-path-step",learningPathVideoCall:"learning-path-video-call",leAssignment:"le-assignment",leClassroomEvent:"le-classroom-event",leCompletion:"le-completion",leExternalLink:"le-external-link",leFinishingTask:"le-finishing-task",leFollowUpTask:"le-follow-up-task",legend:"legend",leDocumentDownload:"le-document-download",leLearningObjectives:"le-learning-objectives",leLearningStep:"le-learning-step",leListenAudioEmbed:"le-listen-audio-embed",lePreparationTask:"le-preparation-task",leRead:"le-read",leReadBook:"le-read-book",leTask:"le-task",leTodo:"le-todo",leVideoCall:"le-video-call",leWatchVideoEmbed:"le-watch-video-embed",lifeSkillSticker:"life-skill-sticker",list:"list",listItem:"list-item",mark:"mark",match:"match",matchAll:"match-all",matchAllReverse:"match-all-reverse",matchAudio:"match-audio",matchMatrix:"match-matrix",matchPicture:"match-picture",matchReverse:"match-reverse",matchSolutionGrouped:"match-solution-grouped",message:"message",metalevelExplanation:"metalevel-explanation",metaSearchDefaultTerms:"meta-search-default-terms",metaSearchDefaultTopics:"meta-search-default-topics",milestone:"milestone",module:"module",moduleProduct:"module-product",multipleChoice:"multiple-choice",multipleChoice1:"multiple-choice-1",multipleChoiceText:"multiple-choice-text",multipleResponse:"multiple-response",multipleResponse1:"multiple-response-1",newspaperArticle:"newspaper-article",note:"note",noteAi:"note-ai",noteAlt:"note-alt",notebookArticle:"notebook-article",noteCollapsible:"note-collapsible",output:"output",page:"page",pageAcademy:"page-academy",pageArticle:"page-article",pageArticleAlt:"page-article-alt",pageArticleResponsive:"page-article-responsive",pageBanner:"page-banner",pageBuyButton:"page-buy-button",pageBuyButtonAlt:"page-buy-button-alt",pageBuyButtonPromotion:"page-buy-button-promotion",pageCategory:"page-category",pageCollapsible:"page-collapsible",pageContainer:"page-container",pageContainerFolder:"page-container-folder",pageContainerGroup:"page-container-group",pageContainerNowrap:"page-container-nowrap",pageContainerNowrapStretch:"page-container-nowrap-stretch",pageContainerWrap:"page-container-wrap",pageCoverImage:"page-cover-image",pageFooter:"page-footer",pageHero:"page-hero",pageOpenBook:"page-open-book",pageOpenBookList:"page-open-book-list",pagePerson:"page-person",pageProduct:"page-product",pageProductList:"page-product-list",pageProductVideo:"page-product-video",pageProductVideoList:"page-product-video-list",pagePromotion:"page-promotion",pageSectionFolder:"page-section-folder",pageShopInShop:"page-shop-in-shop",pageSpecial:"page-special",pageSubpage:"page-subpage",pageSubscribe:"page-subscribe",parameters:"parameters",photo:"photo",platformPath:"platform-path",preparationNote:"preparation-note",pronunciationTable:"pronunciation-table",prototypeImages:"prototype-images",qAndA:"q-and-a",qAndACard:"q-and-a-card",question1:"question-1",quote:"quote",rating:"rating",recipe:"recipe",recordAudio:"record-audio",recordVideo:"record-video",releaseNote:"release-note",releaseNotesSummary:"release-notes-summary",remark:"remark",remarkAlt:"remark-alt",remarkCollapsible:"remark-collapsible",reviewApprovedNote:"review-approved-note",reviewAuthorNote:"review-author-note",reviewCustomerNote:"review-customer-note",reviewNote:"review-note",reviewRequestForReviewNote:"review-request-for-review-note",reviewReviewerNote:"review-reviewer-note",sampleSolution:"sample-solution",scorm:"scorm",screenshot:"screenshot",selfAssessment:"self-assessment",separator:"separator",separatorAlt:"separator-alt",sequence:"sequence",sideNote:"side-note",sideNoteCollapsible:"side-note-collapsible",smartStandardArticleNonNormative:"smart-standard-article-non-normative",smartStandardArticleNonNormativeCollapsible:"smart-standard-article-non-normative-collapsible",smartStandardArticleNormative:"smart-standard-article-normative",smartStandardArticleNormativeCollapsible:"smart-standard-article-normative-collapsible",smartStandardExampleNonNormative:"smart-standard-example-non-normative",smartStandardExampleNonNormativeCollapsible:"smart-standard-example-non-normative-collapsible",smartStandardExampleNormative:"smart-standard-example-normative",smartStandardExampleNormativeCollapsible:"smart-standard-example-normative-collapsible",smartStandardFormula:"smart-standard-formula",smartStandardFormulaNonNormative:"smart-standard-formula-non-normative",smartStandardFormulaNormative:"smart-standard-formula-normative",smartStandardImageFigureNonNormative:"smart-standard-image-figure-non-normative",smartStandardImageFigureNonNormativeCollapsible:"smart-standard-image-figure-non-normative-collapsible",smartStandardImageFigureNormative:"smart-standard-image-figure-normative",smartStandardImageFigureNormativeCollapsible:"smart-standard-image-figure-normative-collapsible",smartStandardLegend:"smart-standard-legend",smartStandardLegendNonNormative:"smart-standard-legend-non-normative",smartStandardLegendNormative:"smart-standard-legend-normative",smartStandardList:"smart-standard-list",smartStandardListCollapsible:"smart-standard-list-collapsible",smartStandardListItem:"smart-standard-list-item",smartStandardListItemCollapsible:"smart-standard-list-item-collapsible",smartStandardNoteNonNormative:"smart-standard-note-non-normative",smartStandardNoteNonNormativeCollapsible:"smart-standard-note-non-normative-collapsible",smartStandardNoteNormative:"smart-standard-note-normative",smartStandardNoteNormativeCollapsible:"smart-standard-note-normative-collapsible",smartStandardRemarkLegend:"smart-standard-remark-legend",smartStandardRemarkLegendNonNormative:"smart-standard-remark-legend-non-normative",smartStandardRemarkLegendNormative:"smart-standard-remark-legend-normative",smartStandardRemarkFormula:"smart-standard-remark-formula",smartStandardRemarkFormulaNonNormative:"smart-standard-remark-formula-non-normative",smartStandardRemarkFormulaNormative:"smart-standard-remark-formula-normative",smartStandardRemarkNonNormative:"smart-standard-remark-non-normative",smartStandardRemarkNonNormativeCollapsible:"smart-standard-remark-non-normative-collapsible",smartStandardRemarkNormative:"smart-standard-remark-normative",smartStandardRemarkNormativeCollapsible:"smart-standard-remark-normative-collapsible",smartStandardRemarkTableImageNonNormative:"smart-standard-remark-table-image-non-normative",smartStandardRemarkTableImageNonNormativeCollapsible:"smart-standard-remark-table-image-non-normative-collapsible",smartStandardRemarkTableImageNormative:"smart-standard-remark-table-image-normative",smartStandardRemarkTableImageNormativeCollapsible:"smart-standard-remark-table-image-normative-collapsible",smartStandardRemarkTableNonNormative:"smart-standard-remark-table-non-normative",smartStandardRemarkTableNonNormativeCollapsible:"smart-standard-remark-table-non-normative-collapsible",smartStandardRemarkTableNormative:"smart-standard-remark-table-normative",smartStandardRemarkTableNormativeCollapsible:"smart-standard-remark-table-normative-collapsible",smartStandardTableImageNonNormative:"smart-standard-table-image-non-normative",smartStandardTableImageNonNormativeCollapsible:"smart-standard-table-image-non-normative-collapsible",smartStandardTableImageNormative:"smart-standard-table-image-normative",smartStandardTableImageNormativeCollapsible:"smart-standard-table-image-normative-collapsible",smartStandardTableNonNormative:"smart-standard-table-non-normative",smartStandardTableNonNormativeCollapsible:"smart-standard-table-non-normative-collapsible",smartStandardTableNormative:"smart-standard-table-normative",smartStandardTableNormativeCollapsible:"smart-standard-table-normative-collapsible",standardArticleNonNormative:"standard-article-non-normative",standardArticleNormative:"standard-article-normative",standardExampleNonNormative:"standard-example-non-normative",standardExampleNormative:"standard-example-normative",standardImageFigureNonNormative:"standard-image-figure-non-normative",standardImageFigureNormative:"standard-image-figure-normative",standardList:"standard-list",standardListItem:"standard-list-item",standardNoteNonNormative:"standard-note-non-normative",standardNoteNormative:"standard-note-normative",standardRemarkNonNormative:"standard-remark-non-normative",standardRemarkNormative:"standard-remark-normative",standardRemarkTableImageNonNormative:"standard-remark-table-image-non-normative",standardRemarkTableImageNormative:"standard-remark-table-image-normative",standardRemarkTableNonNormative:"standard-remark-table-non-normative",standardRemarkTableNormative:"standard-remark-table-normative",standardTableImageNonNormative:"standard-table-image-non-normative",standardTableImageNormative:"standard-table-image-normative",standardTableNonNormative:"standard-table-non-normative",standardTableNormative:"standard-table-normative",statement:"statement",stdout:"stdout",step:"step",stepImageScreenshot:"step-image-screenshot",stepImageScreenshotWithPointer:"step-image-screenshot-with-pointer",sticker:"sticker",stickyNote:"sticky-note",stillImageFilm:"still-image-film",stillImageFilmEmbed:"still-image-film-embed",stillImageFilmLink:"still-image-film-link",summary:"summary",summaryAi:"summary-ai",survey:"survey",survey1:"survey-1",surveyAnonymous:"survey-anonymous",surveyAnonymous1:"survey-anonymous-1",surveyMatrix:"survey-matrix",surveyMatrixMe:"survey-matrix-me",surveyRating:"survey-rating",surveyRatingDisplay:"survey-rating-display",surveyRatingOnce:"survey-rating-once",table:"table",tableAlt:"table-alt",tableImage:"table-image",tableImageAlt:"table-image-alt",takePicture:"take-picture",toc:"toc",tocChapter:"toc-chapter",tocInline:"toc-inline",trueFalse:"true-false",trueFalse1:"true-false-1",vendorAmcharts5Chart:"vendor-amcharts-5-chart",vendorDatadogDashboardEmbed:"vendor-datadog-dashboard-embed",vendorFormbricksEmbed:"vendor-formbricks-embed",vendorFormbricksLink:"vendor-formbricks-link",vendorFormbricksEmbedAnonymous:"vendor-formbricks-embed-anonymous",vendorFormbricksLinkAnonymous:"vendor-formbricks-link-anonymous",vendorHighchartsChart:"vendor-highcharts-chart",vendorIframelyCard:"vendor-iframely-card",vendorIframelyEmbed:"vendor-iframely-embed",vendorIframelyPreview:"vendor-iframely-preview",vendorIframelyPreviewMini:"vendor-iframely-preview-mini",vendorJupyterCellCode:"vendor-jupyter-cell-code",vendorJupyterCellMarkdown:"vendor-jupyter-cell-markdown",vendorJupyterCellRaw:"vendor-jupyter-cell-raw",vendorJupyterIpynb:"vendor-jupyter-ipynb",vendorJupyterOutput:"vendor-jupyter-output",vendorPadletEmbed:"vendor-padlet-embed",vendorStripePricingTable:"vendor-stripe-pricing-table",vendorStripePricingTableExternal:"vendor-stripe-pricing-table-external",video:"video",videoEmbed:"video-embed",videoEmbedLandscape:"video-embed-landscape",videoEmbedPortrait:"video-embed-portrait",videoLandscape:"video-landscape",videoLink:"video-link",videoLinkLandscape:"video-link-landscape",videoLinkPortrait:"video-link-portrait",videoPortrait:"video-portrait",videoTranscript:"video-transcript",warning:"warning",warningAlt:"warning-alt",warningCollapsible:"warning-collapsible",websiteLink:"website-link",workbookArticle:"workbook-article"});t.BitType=i},5980:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.markTagContentProcessor=function(e,t,r,o){const{value:n}=r;i.StringUtils.isString(n)&&(o.solution=i.StringUtils.trimmedString(n))};const i=r(9681)},6128:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ContentProcessorUtils=void 0;const i=r(9554);const o=new class{concatenatePlainTextWithAstTexts(e,t,r){var o;if(Array.isArray(e)){if(r=r&&r.trim()){const n=r.split("\n"),a=[];for(let e=0;e<t;e++)a.push({type:i.TextNodeType.hardBreak});for(let e=0;e<n.length;e++){const t=n[e];t&&a.push({text:t,type:i.TextNodeType.text}),e<n.length-1&&a.push({type:i.TextNodeType.hardBreak})}const s=e[e.length-1];s&&s.type===i.TextNodeType.paragraph?s.content=[...null!==(o=s.content)&&void 0!==o?o:[],...a]:e.push({type:i.TextNodeType.paragraph,content:a,attrs:{}})}return e}return`${null!=e?e:""}${"\n".repeat(t)}${null!=r?r:""}`}};t.ContentProcessorUtils=o},6149:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceTag=void 0;const i=(0,r(4718).superenum)({unknown:"unknown",icon:"icon",image:"image",imageResponsive:"image-responsive",imagePortrait:"image-portrait",imageLandscape:"image-landscape",imageEmbed:"image-embed",imageLink:"image-link",audio:"audio",audioEmbed:"audio-embed",audioLink:"audio-link",video:"video",videoEmbed:"video-embed",videoLink:"video-link",stillImageFilm:"still-image-film",stillImageFilmEmbed:"still-image-film-embed",stillImageFilmLink:"still-image-film-link",article:"article",articleEmbed:"article-embed",articleLink:"article-link",document:"document",documentEmbed:"document-embed",documentLink:"document-link",documentDownload:"document-download",appLink:"app-link",websiteLink:"website-link"});t.ResourceTag=i},6278:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Environment=void 0;const i=(0,r(4718).superenum)({unknown:"",node:"node",chrome:"chrome",safari:"safari",firefox:"firefox",edge:"edge",ie:"ie"});t.Environment=i},6521:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.buildResources=function(e,t,r){var i,o;const{bitType:n}=e,p=[],u=[],c=l.ResourceTag.fromValue(t),y=a.Config.getBitResourcesConfig(n,c),g=y.resourceAttachmentAllowed,d=y.getCountsMin(),f=y.getCountsMax();if(r)for(const e of r.reverse()){let t=null!==(i=d.get(e.__typeAlias))&&void 0!==i?i:0,r=null!==(o=f.get(e.__typeAlias))&&void 0!==o?o:0;t=Math.max(0,t-1),r===s.Count.infinity?p.unshift(e):r>0?(p.unshift(e),r--):u.unshift(e),d.set(e.__typeAlias,t),f.set(e.__typeAlias,r)}if(!g&&t){const r=`Resource type [&${t}] is specified in the bit header, but no extra resource is allowed for this bit.`;e.addWarning(r)}else 0===p.length&&t&&e.addWarning(`Resource type [&${t}] is specified in the bit header, but no such a resource is present`);u.length>0&&(e.parser.excessResources=u);return p},t.resourceContentProcessor=function(e,t,r,o,s){const{type:g,key:d,value:f,chain:m}=o,T=s.resources;if(!T)return;const h=l.ResourceTag.fromValue(d);if(h){const t=a.Config.getTagConfigForTag(r,h),o=e.bitContentProcessor(c.BitContentLevel.Chain,null==t?void 0:t.chain,m),{posterImage:s}=o,g=i(o,["posterImage"]);let d;if(s){const{subConfig:r,subChain:o}=function(e,t,r){var i;let o;e&&(o=null===(i=e[r])||void 0===i?void 0:i.chain);const n=null==t?void 0:t.reduce(((e,t)=>{if(e)return e;const r=t;return"posterImage"===r.key?r.chain:void 0}),void 0);return{subConfig:o,subChain:n}}(null==t?void 0:t.chain,m,"posterImage"),n=e.bitContentProcessor(c.BitContentLevel.Chain,r,o),{posterImage:a}=n,p=i(n,["posterImage"]);d=y.resource(e,Object.assign({type:l.ResourceTag.image,value:s},p)).image}const b=y.resource(e,Object.assign({type:h,value:n.Breakscape.unbreakscape(f,{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag}),posterImage:d},g));b&&T.push(b)}},t.propertyStyleResourceContentProcessor=function(e,t,r,o,s,g){var d;const{type:f,key:m,value:T,chain:h}=o;if(s.propertyStyleResources=null!==(d=s.propertyStyleResources)&&void 0!==d?d:{},g){const t=a.Config.getTagConfigForTag(r,g),o=e.bitContentProcessor(c.BitContentLevel.Chain,null==t?void 0:t.chain,h),{posterImage:d}=o,f=i(o,["posterImage"]),b=d?y.resource(e,{type:l.ResourceTag.image,value:d}).image:void 0,B=y.resource(e,Object.assign({type:g,value:n.Breakscape.unbreakscape(T,{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag}),posterImage:b},f));B&&(s.propertyStyleResources[m]=B)}};const o=r(5533),n=r(7735),a=r(2028),s=r(3778),l=r(6149),p=r(385),u=r(6877),c=r(3029),y=new o.ResourceBuilder},6634:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractTagConfig=void 0;t.AbstractTagConfig=class{constructor(e,t,r,i,o,n,a,s,l){this.type=e,this.configKey=t,this.tag=r,this.maxCount=i,this.minCount=o,this.chain=n,this.jsonKey=a,this.astKey=s,this.deprecated=l}}},6772:function(e,t){var r=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.StringWriter=void 0;t.StringWriter=class{constructor(){this._string="",this.endOfLineString="\n",this.lastWrite=""}get isSync(){return!0}getString(){return this._string}open(){return r(this,void 0,void 0,(function*(){return this.openSync(),Promise.resolve()}))}close(){return r(this,void 0,void 0,(function*(){try{this.closeSync()}catch(e){return Promise.reject(e)}return Promise.resolve()}))}openSync(){this._buffer=[],this._string=""}closeSync(){if(!this._buffer)throw new Error("open() or openSync() never called");this._string=this._buffer.join(""),this._buffer=[]}writeLine(e){return this._buffer?(null!=e?(this._buffer.push(e+this.endOfLineString),this.lastWrite=e+this.endOfLineString):(this._buffer.push(this.endOfLineString),this.lastWrite=this.endOfLineString),this):this}writeLines(e,t){if(!this._buffer)return this;if(!e)return this;let r="";for(let i=0,o=e.length;i<o;i++){const n=e[i];this._buffer.push(n),r+=n,t&&i<o-1&&(this._buffer.push(t),r+=t),this._buffer.push(this.endOfLineString),r+=this.endOfLineString}return this.lastWrite=r,this}write(e){return this._buffer?(null==e||(e&&(this.lastWrite=e),this._buffer.push(e)),this):this}writeWhiteSpace(){return this.write(" "),this}getLastWrite(){return this.lastWrite}}},6853:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BITS=void 0;const i=r(8199),o=r(7112),n=r(9888),a=r(7797),s=r(5512),l=r(5854),p=r(3778),u=r(363),c=r(385),y={[l.BitType._error]:{since:"1.3.0",tags:[]},[l.BitType._comment]:{since:"1.4.12",tags:[]},[l.BitType._standard]:{since:"3.2.0",tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_standardTags}]},[l.BitType.appFlashcards]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.flashcardSet,maxCount:p.Count.infinity}],rootExampleType:u.ExampleType.string},[l.BitType.appFlashcardsQuiz]:{since:"1.3.0",baseBitType:l.BitType.appFlashcards},[l.BitType.appFlashcardsLearn]:{since:"1.3.0",baseBitType:l.BitType.appFlashcards},[l.BitType.appLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAppLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.article]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title}]},[l.BitType.articleAlt]:{since:"1.15.0",baseBitType:l.BitType.article},[l.BitType.articleResponsive]:{since:"1.21.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.imageFirst}]},[l.BitType.articleResponsiveAlt]:{since:"2.0.0",baseBitType:l.BitType.articleResponsive},[l.BitType.standardArticleNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.standardArticleNonNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.smartStandardArticleNormative]:{since:"1.28.0",baseBitType:l.BitType.standardArticleNormative},[l.BitType.smartStandardArticleNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardArticleNonNormative},[l.BitType.smartStandardArticleNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardArticleNormative},[l.BitType.smartStandardArticleNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardArticleNonNormative},[l.BitType.statement]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.pageArticle]:{since:"1.15.0",baseBitType:l.BitType.article},[l.BitType.pageArticleAlt]:{since:"1.15.0",baseBitType:l.BitType.article},[l.BitType.pageArticleResponsive]:{since:"1.21.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.imageFirst}]},[l.BitType.buttonCopyText]:{since:"1.4.3",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.callToAction]:{since:"1.15.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.callToActionUrl,minCount:1}]},[l.BitType.callToActionSubscribe]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionContact]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionJoin]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionMail]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionLearnMore]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionSeeMore]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionWatch]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionStartNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionGetOffer]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionBookNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionShopNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionGetNow]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionDownload]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.callToActionCreateAccount]:{since:"1.15.0",baseBitType:l.BitType.callToAction},[l.BitType.appBitmarkFromJavascript]:{since:"1.4.5",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.maxCreatedBits}],textFormatDefault:c.TextFormat.text},[l.BitType.appBitmarkFromEditor]:{since:"1.4.5",baseBitType:l.BitType.appBitmarkFromJavascript},[l.BitType.articleEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceArticleEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.articleLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceArticleLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.audio]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudio,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.audioEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudioEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.audioLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudioLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.bitAlias]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference},{type:s.BitTagType.tag,configKey:a.TagConfigKey.anchor}]},[l.BitType.diff]:{since:"3.13.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.diffTo}]},[l.BitType.book]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_bookCommon}]},[l.BitType.bookAcknowledgements]:{since:"1.17.0",baseBitType:l.BitType.article},[l.BitType.bookAddendum]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAfterword]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAppendix]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAutherBio]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookBibliography]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookComingSoon]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookConclusion]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookCopyright]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookCopyrightPermissions]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookDedication]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookEndnotes]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookEpigraph]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookEpilogue]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookForword]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookFrontispiece]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookImprint]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookIncitingIncident]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookIntroduction]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookListOfContributors]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookNotes]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookPostscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookPreface]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookPrologue]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookReadMore]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookReferenceList]:{since:"3.2.0",baseBitType:l.BitType._standard,cardSet:i.CardSetConfigKey._bookReferenceList},[l.BitType.bookRequestForABookReview]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookSummary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookTeaser]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookTitle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bookAlias]:{since:"1.4.3",baseBitType:l.BitType.book,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.bookAlias,maxCount:p.Count.infinity}]},[l.BitType.bookDiff]:{since:"3.10.0",baseBitType:l.BitType.book,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.bookDiff}]},[l.BitType.bookClose]:{since:"1.18.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.bookReference]:{since:"2.2.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refAuthor,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refBookTitle},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refPublisher,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.refPublicationYear},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.citationStyle}]},[l.BitType.botActionResponse]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._botActionResponses},[l.BitType.botActionSend]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.date}]},[l.BitType.browserImage]:{since:"1.3.0",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusX},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusY}]},[l.BitType.card1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}]},[l.BitType.question1]:{since:"1.3.0",baseBitType:l.BitType.card1},[l.BitType.survey1]:{since:"1.3.0",baseBitType:l.BitType.card1},[l.BitType.surveyAnonymous1]:{since:"1.3.0",baseBitType:l.BitType.card1},[l.BitType.chapter]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.anchor},{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.toc},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.progress}]},[l.BitType.clozeAndMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_gap},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachCallToActionClozeAndMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType.clozeAndMultipleChoiceText},[l.BitType.cloze]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quizCountItems},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quizStrikethroughSolutions},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quizStrikethroughSolutions},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.additionalSolutions,maxCount:p.Count.infinity},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_gap}]},[l.BitType.clozeInstructionGrouped]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.clozeSolutionGrouped]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.clozeSeveral]:{since:"3.5.0",baseBitType:l.BitType.cloze},[l.BitType.gapText]:{since:"1.5.15",baseBitType:l.BitType.cloze},[l.BitType.gapTextInstructionGrouped]:{since:"1.5.15",baseBitType:l.BitType.clozeInstructionGrouped},[l.BitType.coachSelfReflectionCloze]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.coachCallToActionCloze]:{since:"1.3.0",baseBitType:l.BitType.cloze},[l.BitType.clozeList]:{since:"1.4.13",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}],cardSet:i.CardSetConfigKey._clozeList},[l.BitType.code]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.computerLanguage},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.codeLineNumbers},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.codeMinimap}],textFormatDefault:c.TextFormat.text},[l.BitType.formula]:{since:"1.35.0",baseBitType:l.BitType._standard,tags:[],textFormatDefault:c.TextFormat.latex},[l.BitType.smartStandardFormula]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardFormulaNonNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardFormulaNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardRemarkFormula]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardRemarkFormulaNonNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.smartStandardRemarkFormulaNormative]:{since:"3.11.0",baseBitType:l.BitType.formula},[l.BitType.appCodeCell]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.appCodeEditor]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.appCodeIde]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.codeRuntime]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.consoleLog]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.output]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.stdout]:{since:"1.4.3",baseBitType:l.BitType.code},[l.BitType.step]:{since:"1.5.1",baseBitType:l.BitType.article},[l.BitType.stepImageScreenshot]:{since:"1.5.1",baseBitType:l.BitType.image},[l.BitType.stepImageScreenshotWithPointer]:{since:"1.5.1",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerTop,minCount:1,maxCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerLeft,minCount:1,maxCount:1}]},[l.BitType.milestone]:{since:"1.20.0",baseBitType:l.BitType.step},[l.BitType.conversationLeft1]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_person}]},[l.BitType.conversationLeft1Scream]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationLeft1Thought]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationRight1]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationRight1Scream]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.conversationRight1Thought]:{since:"1.3.0",baseBitType:l.BitType.conversationLeft1},[l.BitType.cookPreparation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookStep]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookIngredients]:{since:"1.5.16",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_technicalTerm},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.servings,chain:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.unit},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.unitAbbr},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.decimalPlaces},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.disableCalculation},{type:s.BitTagType.tag,configKey:a.TagConfigKey.hint}]}],cardSet:i.CardSetConfigKey._ingredients},[l.BitType.recipe]:{since:"1.5.24",baseBitType:l.BitType.cookIngredients},[l.BitType.cookRemark]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookVariation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookInsert]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookArrangement]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookPracticeAdvise]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookPlate]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookRecommendation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookPersonalRecommendation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookSideDrink]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookSideDish]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.cookTimer]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.document]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocument,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.documentDownload]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocumentDownload,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.leDocumentDownload]:{since:"3.18.0",baseBitType:l.BitType.documentDownload},[l.BitType.documentEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocumentEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.documentLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceDocumentLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.essay]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.property_sampleSolution},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.additionalSolutions,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.partialAnswer},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.property_reference,maxCount:p.Count.infinity}],rootExampleType:u.ExampleType.string},[l.BitType.coachSelfReflectionEssay]:{since:"1.3.0",baseBitType:l.BitType.essay},[l.BitType.coachCallToActionEssay]:{since:"1.3.0",baseBitType:l.BitType.essay},[l.BitType.example]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title}],rootExampleType:u.ExampleType.string},[l.BitType.exampleAlt]:{since:"1.16.0",baseBitType:l.BitType.example},[l.BitType.standardExampleNormative]:{since:"1.16.0",baseBitType:l.BitType.example},[l.BitType.standardExampleNonNormative]:{since:"1.16.0",baseBitType:l.BitType.example},[l.BitType.smartStandardExampleNormative]:{since:"1.28.0",baseBitType:l.BitType.standardExampleNormative},[l.BitType.smartStandardExampleNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardExampleNonNormative},[l.BitType.smartStandardExampleNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardExampleNormative},[l.BitType.smartStandardExampleNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardExampleNonNormative},[l.BitType.appAiPrompt]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.aiPrompt]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.articleAi]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.articleAttachment]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.assignment]:{since:"1.3.0",baseBitType:l.BitType.essay},[l.BitType.audioTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bitmarkExample]:{since:"1.3.0",baseBitType:l.BitType.example},[l.BitType.blogArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bug]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.bugAlt]:{since:"1.16.0",baseBitType:l.BitType.bug},[l.BitType.checklist]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachAudioTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachCallToActionChecklist]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachHomeRules]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.coachVideoTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.correction]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.danger]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.dangerAlt]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.definitionTerm]:{since:"1.34.0",baseBitType:l.BitType.article},[l.BitType.deleted]:{since:"3.9.0",baseBitType:l.BitType.article},[l.BitType.details1]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.details]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.qAndA]:{since:"3.5.0",baseBitType:l.BitType.article},[l.BitType.editorial]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.editorNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.featured]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.glossaryTerm]:{since:"1.33.0",baseBitType:l.BitType.article},[l.BitType.help]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.helpAlt]:{since:"1.16.0",baseBitType:l.BitType.help},[l.BitType.hint]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.hintAlt]:{since:"1.16.0",baseBitType:l.BitType.hint},[l.BitType.indexTerm]:{since:"1.33.0",baseBitType:l.BitType.article},[l.BitType.info]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.infoAlt]:{since:"1.16.0",baseBitType:l.BitType.info},[l.BitType.langLearningOutcomes]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langEnablingLanguageSkills]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLifeSkills]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langEnglishAroundWorld]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langGoodToKnow]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLearningGoal]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLearningStrategy]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLikeALocal]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langMaterial]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langUsefulPhrases]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLevelDown]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langLevelUp]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langExtraActivity]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langVideoScript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langAudioScript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langVocabulary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langHomework]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langTeacherNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.langTeacherPronunciation]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.list]:{since:"1.22.0",baseBitType:l.BitType.article},[l.BitType.standardList]:{since:"1.22.0",baseBitType:l.BitType.article},[l.BitType.smartStandardList]:{since:"1.28.0",baseBitType:l.BitType.standardList},[l.BitType.smartStandardListCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardList},[l.BitType.message]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.newspaperArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.note]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.noteAlt]:{since:"1.16.0",baseBitType:l.BitType.note},[l.BitType.standardNoteNormative]:{since:"1.16.0",baseBitType:l.BitType.note},[l.BitType.standardNoteNonNormative]:{since:"1.16.0",baseBitType:l.BitType.note},[l.BitType.smartStandardNoteNormative]:{since:"1.28.0",baseBitType:l.BitType.standardNoteNormative},[l.BitType.smartStandardNoteNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardNoteNonNormative},[l.BitType.smartStandardNoteNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardNoteNormative},[l.BitType.smartStandardNoteNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardNoteNonNormative},[l.BitType.noteAi]:{since:"1.3.0",baseBitType:l.BitType.note},[l.BitType.notebookArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.preparationNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.releaseNotesSummary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.remark]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.remarkAlt]:{since:"1.16.0",baseBitType:l.BitType.remark},[l.BitType.standardRemarkNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.standardRemarkNonNormative]:{since:"1.16.0",baseBitType:l.BitType.article},[l.BitType.smartStandardRemarkNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkNormative},[l.BitType.smartStandardRemarkNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkNonNormative},[l.BitType.smartStandardRemarkNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkNormative},[l.BitType.smartStandardRemarkNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkNonNormative},[l.BitType.selfAssessment]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.separator]:{since:"1.4.15",baseBitType:l.BitType.article},[l.BitType.separatorAlt]:{since:"1.16.0",baseBitType:l.BitType.separator},[l.BitType.sticker]:{since:"1.5.28",baseBitType:l.BitType.article},[l.BitType.sideNote]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.summary]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.summaryAi]:{since:"1.3.0",baseBitType:l.BitType.summary},[l.BitType.videoTranscript]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.warning]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.warningAlt]:{since:"1.16.0",baseBitType:l.BitType.warning},[l.BitType.workbookArticle]:{since:"1.3.0",baseBitType:l.BitType.article},[l.BitType.collapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.sideNoteCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.infoCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.remarkCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.warningCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.dangerCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.noteCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.exampleCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.hintCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.bugCollapsible]:{since:"1.21.0",baseBitType:l.BitType.article},[l.BitType.platformPath]:{since:"3.14.1",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.path}]},[l.BitType.container]:{since:"1.9.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.allowedBit,maxCount:p.Count.infinity}]},[l.BitType.containerWrap]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerNowrap]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerNowrapStretch]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerGroup]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerFolder]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.containerCarousel]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerCards]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerGrid]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerStack]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerSlides]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerGallery]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerScroller]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerTabs]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerAccordionTabs]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerFolderAll]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerBits2]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerCookRecipe]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerNewsArticle]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.containerPreview]:{since:"1.11.0",baseBitType:l.BitType.container},[l.BitType.pageContainer]:{since:"1.9.0",baseBitType:l.BitType.container},[l.BitType.pageContainerWrap]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerNowrap]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerNowrapStretch]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerFolder]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.pageContainerGroup]:{since:"1.9.0",baseBitType:l.BitType.pageContainer},[l.BitType.metalevelExplanation]:{since:"1.10.0",baseBitType:l.BitType.article},[l.BitType.module]:{since:"1.5.26",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.hasBookNavigation},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productId,minCount:1,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.duration}]},[l.BitType.moduleProduct]:{since:"1.9.0",baseBitType:l.BitType.module,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productId,minCount:1}]},[l.BitType.exampleList]:{since:"1.4.13",baseBitType:l.BitType.example,cardSet:i.CardSetConfigKey._exampleBitList,rootExampleType:u.ExampleType.string},[l.BitType.extractorPage]:{since:"1.5.17",baseBitType:l.BitType.image},[l.BitType.extractorPageCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPage},[l.BitType.extractorPageWithBlocks]:{since:"1.5.21",baseBitType:l.BitType.image},[l.BitType.extractorPageWithBlocksCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageWithBlocks},[l.BitType.extractorConfiguration]:{since:"1.7.1",baseBitType:l.BitType._standard,tags:[],textFormatDefault:c.TextFormat.text},[l.BitType.extractorInformation]:{since:"3.8.0",baseBitType:l.BitType._standard,tags:[],textFormatDefault:c.TextFormat.json},[l.BitType.extractorAiChat]:{since:"3.19.0",baseBitType:l.BitType._standard},[l.BitType.extractorBlock]:{since:"1.5.16",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.blockId},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pageNo},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.x},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.y},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.index},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.classification},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.availableClassifications,maxCount:p.Count.infinity},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.extractorRepeatedText]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageNumber]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageNumberCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageNumber},[l.BitType.extractorPageHeader]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageHeaderCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageHeader},[l.BitType.extractorPageFooter]:{since:"1.5.21",baseBitType:l.BitType.article},[l.BitType.extractorPageFooterCollapsible]:{since:"1.30.0",baseBitType:l.BitType.extractorPageFooter},[l.BitType.pageOpenBook]:{since:"1.5.10",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.book,chain:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference,maxCount:2}]},{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageOpenBookList]:{since:"2.1.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.book,maxCount:p.Count.infinity,chain:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference,maxCount:2}]},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageSubscribe]:{since:"1.5.10",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.mailingList}]},[l.BitType.assignmentList]:{since:"1.4.13",baseBitType:l.BitType.exampleList},[l.BitType.pageFooter]:{since:"1.4.13",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug}],cardSet:i.CardSetConfigKey._exampleBitList},[l.BitType.legend]:{since:"3.12.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._definitionList},[l.BitType.smartStandardLegend]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardLegendNonNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardLegendNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardRemarkLegend]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardRemarkLegendNonNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.smartStandardRemarkLegendNormative]:{since:"3.12.0",baseBitType:l.BitType.legend},[l.BitType.definitionList]:{since:"1.34.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._definitionList},[l.BitType.metaSearchDefaultTerms]:{since:"3.12.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._definitionList},[l.BitType.metaSearchDefaultTopics]:{since:"3.12.0",baseBitType:l.BitType.metaSearchDefaultTerms},[l.BitType.flashcard]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}],cardSet:i.CardSetConfigKey._flashcard},[l.BitType.flashcard1]:{since:"1.3.0",baseBitType:l.BitType.flashcard},[l.BitType.qAndACard]:{since:"3.25.0",baseBitType:l.BitType.flashcard1},[l.BitType.focusImage]:{since:"1.3.0",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusX},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.focusY}]},[l.BitType.highlightText]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.image]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.backgroundWallpaper},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.appCreateBitsFromImage]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.appGetScreenshot]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.detailsImage]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.figure]:{since:"1.3.0",baseBitType:l.BitType.image,cardSet:i.CardSetConfigKey._definitionList},[l.BitType.imageBanner]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageFigure]:{since:"1.3.0",baseBitType:l.BitType.image,cardSet:i.CardSetConfigKey._definitionList},[l.BitType.imageFigureAlt]:{since:"1.16.0",baseBitType:l.BitType.imageFigure},[l.BitType.standardImageFigureNormative]:{since:"1.16.0",baseBitType:l.BitType.imageFigure},[l.BitType.standardImageFigureNonNormative]:{since:"1.16.0",baseBitType:l.BitType.imageFigure},[l.BitType.smartStandardImageFigureNormative]:{since:"1.28.0",baseBitType:l.BitType.standardImageFigureNormative},[l.BitType.smartStandardImageFigureNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardImageFigureNonNormative},[l.BitType.smartStandardImageFigureNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardImageFigureNormative},[l.BitType.smartStandardImageFigureNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardImageFigureNonNormative},[l.BitType.imageLandscape]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageMood]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imagePortrait]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imagePrototype]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageSeparator]:{since:"1.4.15",baseBitType:l.BitType.image},[l.BitType.imageSeparatorAlt]:{since:"1.16.0",baseBitType:l.BitType.imageSeparator},[l.BitType.imageScreenshot]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageStyled]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageSuperWide]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.imageZoom]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.langLifeSkillIcon]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.lifeSkillSticker]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.pageBanner]:{since:"1.4.3",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug}]},[l.BitType.pageHero]:{since:"1.11.0",baseBitType:l.BitType.pageBanner},[l.BitType.screenshot]:{since:"1.3.0",deprecated:"1.4.0",baseBitType:l.BitType.image},[l.BitType.tableImage]:{since:"1.5.15",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.caption}]},[l.BitType.tableImageAlt]:{since:"1.16.0",baseBitType:l.BitType.tableImage},[l.BitType.standardTableImageNormative]:{since:"1.16.0",baseBitType:l.BitType.tableImage},[l.BitType.standardTableImageNonNormative]:{since:"1.16.0",baseBitType:l.BitType.tableImage},[l.BitType.standardRemarkTableImageNormative]:{since:"1.17.0",baseBitType:l.BitType.tableImage},[l.BitType.standardRemarkTableImageNonNormative]:{since:"1.17.0",baseBitType:l.BitType.tableImage},[l.BitType.smartStandardTableImageNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableImageNormative},[l.BitType.smartStandardTableImageNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableImageNonNormative},[l.BitType.smartStandardRemarkTableImageNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableImageNormative},[l.BitType.smartStandardRemarkTableImageNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableImageNonNormative},[l.BitType.smartStandardTableImageNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableImageNormative},[l.BitType.smartStandardTableImageNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableImageNonNormative},[l.BitType.smartStandardRemarkTableImageNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableImageNormative},[l.BitType.smartStandardRemarkTableImageNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableImageNonNormative},[l.BitType.imageLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImageLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.imageOnDevice]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_imageSource}],resourceAttachmentAllowed:!1},[l.BitType.imageResponsive]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImageResponsive}],resourceAttachmentAllowed:!1},[l.BitType.imagesLogoGrave]:{since:"1.5.11",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceImage,minCount:1,maxCount:p.Count.infinity}],resourceAttachmentAllowed:!1},[l.BitType.prototypeImages]:{since:"1.6.1",baseBitType:l.BitType.imagesLogoGrave},[l.BitType.internalLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference}]},[l.BitType.interview]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars}],cardSet:i.CardSetConfigKey._questions},[l.BitType.interviewInstructionGrouped]:{since:"1.3.0",baseBitType:l.BitType.interview},[l.BitType.botInterview]:{since:"1.3.0",baseBitType:l.BitType.interview},[l.BitType.learningPathBook]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_learningPathCommon}]},[l.BitType.bookLink]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.bookLinkNext]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.bookLinkPrev]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathClassroomEvent]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathClassroomTraining]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathClosing]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathFeedback]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathLearningGoal]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathLti]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathSign]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathStep]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook},[l.BitType.learningPathBotTraining]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.bot}]},[l.BitType.learningPathExternalLink]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.externalLink},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.externalLinkText}]},[l.BitType.learningPathVideoCall]:{since:"1.3.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.videoCallLink}]},[l.BitType.leLearningObjectives]:{since:"1.25.0",baseBitType:l.BitType.learningPathLearningGoal,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leVideoCall]:{since:"1.25.0",baseBitType:l.BitType.learningPathVideoCall,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leClassroomEvent]:{since:"1.25.0",baseBitType:l.BitType.learningPathClassroomEvent,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leCompletion]:{since:"1.25.0",baseBitType:l.BitType.learningPathClosing,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leExternalLink]:{since:"1.25.0",baseBitType:l.BitType.learningPathExternalLink,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leReadBook]:{since:"1.25.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leLearningStep]:{since:"1.25.0",baseBitType:l.BitType.learningPathStep,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.lePreparationTask]:{since:"1.26.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType}]},[l.BitType.leRead]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leTask]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leTodo]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leFollowUpTask]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leFinishingTask]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leAssignment]:{since:"1.27.0",baseBitType:l.BitType.lePreparationTask},[l.BitType.leWatchVideoEmbed]:{since:"1.27.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideoEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.leListenAudioEmbed]:{since:"1.27.0",baseBitType:l.BitType.learningPathBook,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.activityType},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceAudioEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.listItem]:{since:"1.22.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.listItemIndent}]},[l.BitType.standardListItem]:{since:"1.22.0",baseBitType:l.BitType.listItem},[l.BitType.smartStandardListItem]:{since:"1.28.0",baseBitType:l.BitType.standardListItem},[l.BitType.smartStandardListItemCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardListItem},[l.BitType.mark]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_markConfig},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_mark}]},[l.BitType.match]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.isCaseSensitive}],cardSet:i.CardSetConfigKey._matchPairs},[l.BitType.matchAll]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchReverse]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchAllReverse]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchSolutionGrouped]:{since:"1.3.0",baseBitType:l.BitType.match},[l.BitType.matchMatrix]:{since:"1.3.0",baseBitType:l.BitType.match,cardSet:i.CardSetConfigKey._matchMatrix},[l.BitType.matchAudio]:{since:"1.3.0",baseBitType:l.BitType.match,cardSet:i.CardSetConfigKey._matchAudioPairs},[l.BitType.matchPicture]:{since:"1.3.0",baseBitType:l.BitType.match,cardSet:i.CardSetConfigKey._matchImagePairs},[l.BitType.feedback]:{since:"3.13.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.reasonableNumOfChars}],cardSet:i.CardSetConfigKey._feedback},[l.BitType.learningDocumentationFeedback]:{since:"3.13.0",baseBitType:l.BitType.feedback},[l.BitType.multipleChoice1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachSelfReflectionMultipleChoice1]:{since:"1.3.0",baseBitType:l.BitType.multipleChoice1},[l.BitType.multipleChoice]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}],cardSet:i.CardSetConfigKey._quiz},[l.BitType.coachSelfReflectionMultipleChoice]:{since:"1.3.0",baseBitType:l.BitType.multipleChoice},[l.BitType.multipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachCallToActionMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType.multipleChoiceText},[l.BitType.coachSelfReflectionMultipleChoiceText]:{since:"1.3.0",baseBitType:l.BitType.multipleChoiceText},[l.BitType.multipleResponse1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}]},[l.BitType.coachSelfReflectionMultipleResponse1]:{since:"1.3.0",baseBitType:l.BitType.multipleResponse1},[l.BitType.multipleResponse]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_trueFalse}],cardSet:i.CardSetConfigKey._quiz},[l.BitType.coachSelfReflectionMultipleResponse]:{since:"1.3.0",baseBitType:l.BitType.multipleResponse},[l.BitType.page]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.thumbImage}]},[l.BitType.pageCollapsible]:{since:"1.30.0",baseBitType:l.BitType.page},[l.BitType.pageCoverImage]:{since:"1.22.0",baseBitType:l.BitType.page},[l.BitType.pageBuyButton]:{since:"1.4.3",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.content2Buy},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageBuyButtonAlt]:{since:"1.31.0",baseBitType:l.BitType.pageBuyButton},[l.BitType.pageBuyButtonPromotion]:{since:"1.5.11",baseBitType:l.BitType.pageBuyButton},[l.BitType.pageSubpage]:{since:"1.6.6",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.page}]},[l.BitType.pageShopInShop]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pageCategory]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pageAcademy]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pagePromotion]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pageSpecial]:{since:"1.6.6",baseBitType:l.BitType.pageSubpage},[l.BitType.pagePerson]:{since:"1.5.16",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_person},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.pageProduct]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.product}]},[l.BitType.pageProductList]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productList,maxCount:p.Count.infinity}]},[l.BitType.pageProductVideo]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productVideo}]},[l.BitType.pageProductVideoList]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productVideoList,maxCount:p.Count.infinity}]},[l.BitType.pageSectionFolder]:{since:"1.4.17",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.slug},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.productFolder}]},[l.BitType.photo]:{since:"1.3.0",baseBitType:l.BitType.image},[l.BitType.quote]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.quotedPerson}]},[l.BitType.rating]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.coachSelfReflectionRating]:{since:"1.3.0",baseBitType:l.BitType.rating},[l.BitType.releaseNote]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.releaseVersion},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.releaseKind},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.releaseDate}]},[l.BitType.reviewNote]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.title},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.resolved},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.resolvedDate},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.resolvedBy}],rootExampleType:u.ExampleType.string},[l.BitType.reviewAuthorNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.reviewCustomerNote]:{since:"3.5.0",baseBitType:l.BitType.reviewNote},[l.BitType.reviewReviewerNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.reviewRequestForReviewNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.reviewApprovedNote]:{since:"1.3.0",baseBitType:l.BitType.reviewNote},[l.BitType.sampleSolution]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.tag,configKey:a.TagConfigKey.anchor},{type:s.BitTagType.tag,configKey:a.TagConfigKey.tag_reference}]},[l.BitType.sequence]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon}],cardSet:i.CardSetConfigKey._elements,rootExampleType:u.ExampleType.boolean},[l.BitType.stillImageFilm]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceStillImageFilm}],resourceAttachmentAllowed:!1},[l.BitType.stillImageFilmEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceStillImageFilmEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.stillImageFilmLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceStillImageFilmLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.surveyAnonymous]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.survey]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.surveyMatrix]:{since:"1.6.2",baseBitType:l.BitType.image,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerTop,minCount:1,maxCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.pointerLeft,minCount:1,maxCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption,minCount:1,maxCount:1}]},[l.BitType.surveyMatrixMe]:{since:"1.6.2",baseBitType:l.BitType.surveyMatrix},[l.BitType.surveyRating]:{since:"1.6.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.ratingLevelStart,chain:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.label}]},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.ratingLevelEnd,chain:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.label}]},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.ratingLevelSelected},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.surveyRatingOnce]:{since:"1.6.0",baseBitType:l.BitType.surveyRating},[l.BitType.surveyRatingDisplay]:{since:"1.6.0",baseBitType:l.BitType.surveyRating},[l.BitType.scorm]:{since:"1.5.11",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.scormSource},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.posterImage}]},[l.BitType.pronunciationTable]:{since:"3.1.0",baseBitType:l.BitType._standard,tags:[],cardSet:i.CardSetConfigKey._pronunciationTable},[l.BitType.table]:{since:"1.5.19",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.caption},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableFixedHeader},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableSearch},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableSort},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tablePagination},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tablePaginationLimit},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableHeight},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableWhitespaceNoWrap},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableAutoWidth},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableResizableColumns},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.tableColumnMinWidth}],cardSet:i.CardSetConfigKey._table},[l.BitType.tableAlt]:{since:"1.16.0",baseBitType:l.BitType.table},[l.BitType.standardTableNormative]:{since:"1.16.0",baseBitType:l.BitType.table},[l.BitType.standardTableNonNormative]:{since:"1.16.0",baseBitType:l.BitType.table},[l.BitType.standardRemarkTableNormative]:{since:"1.17.0",baseBitType:l.BitType.table},[l.BitType.standardRemarkTableNonNormative]:{since:"1.17.0",baseBitType:l.BitType.table},[l.BitType.smartStandardTableNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableNormative},[l.BitType.smartStandardTableNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardTableNonNormative},[l.BitType.smartStandardRemarkTableNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableNormative},[l.BitType.smartStandardRemarkTableNonNormative]:{since:"1.28.0",baseBitType:l.BitType.standardRemarkTableNonNormative},[l.BitType.smartStandardTableNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableNormative},[l.BitType.smartStandardTableNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardTableNonNormative},[l.BitType.smartStandardRemarkTableNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableNormative},[l.BitType.smartStandardRemarkTableNonNormativeCollapsible]:{since:"1.28.0",baseBitType:l.BitType.smartStandardRemarkTableNonNormative},[l.BitType.parameters]:{since:"1.18.0",baseBitType:l.BitType.table},[l.BitType.toc]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[]},[l.BitType.tocChapter]:{since:"1.5.5",baseBitType:l.BitType.toc,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.maxDisplayLevel}]},[l.BitType.tocInline]:{since:"3.24.0",baseBitType:l.BitType.toc,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.maxTocChapterLevel}]},[l.BitType.anchor]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.bitBookEnding]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.bitBookSummary]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionAnnounce]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionRatingNumber]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionRemind]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionSave]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.botActionTrueFalse]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.chapterSubjectMatter]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.chat]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.conclusion]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.conclusionAlt]:{since:"1.16.0",baseBitType:l.BitType.conclusion},[l.BitType.documentUpload]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.footNote]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.groupBorn]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.groupDied]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.recordAudio]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.recordVideo]:{since:"1.5.24",baseBitType:l.BitType._standard},[l.BitType.stickyNote]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.takePicture]:{since:"1.3.0",baseBitType:l.BitType._standard},[l.BitType.handInAudio]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInContact]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInDocument]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInFile]:{since:"3.2.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.handInAcceptFileType,maxCount:p.Count.infinity}]},[l.BitType.handInLocation]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInPhoto]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInScan]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInSubmit]:{since:"3.2.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.handInRequirement,maxCount:p.Count.infinity},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.handInInstruction},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.buttonCaption}]},[l.BitType.handInVideo]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.handInVoice]:{since:"1.5.15",baseBitType:l.BitType._standard},[l.BitType.trueFalse1]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelTrue},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelFalse},{type:s.BitTagType.tag,configKey:a.TagConfigKey.true},{type:s.BitTagType.tag,configKey:a.TagConfigKey.false}],rootExampleType:u.ExampleType.boolean},[l.BitType.trueFalse]:{since:"1.3.0",baseBitType:l.BitType._standard,quizBit:!0,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_quizCommon},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelTrue},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.labelFalse}],cardSet:i.CardSetConfigKey._statements},[l.BitType.vendorAmcharts5Chart]:{since:"1.5.8",baseBitType:l.BitType.code,tags:[],textFormatDefault:c.TextFormat.json},[l.BitType.vendorDatadogDashboardEmbed]:{since:"3.12.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorDashboardId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorFormbricksEmbed]:{since:"3.8.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorSurveyId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorFormbricksEmbedAnonymous]:{since:"3.9.0",baseBitType:l.BitType.vendorFormbricksEmbed},[l.BitType.vendorFormbricksLink]:{since:"3.8.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorSurveyId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorFormbricksLinkAnonymous]:{since:"3.9.0",baseBitType:l.BitType.vendorFormbricksLink},[l.BitType.vendorHighchartsChart]:{since:"1.5.28",baseBitType:l.BitType.vendorAmcharts5Chart},[l.BitType.vendorIframelyEmbed]:{since:"1.5.10",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.width},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.height},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.vendorUrl}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorIframelyCard]:{since:"1.5.10",baseBitType:l.BitType.vendorIframelyEmbed},[l.BitType.vendorIframelyPreview]:{since:"1.5.10",baseBitType:l.BitType.vendorIframelyEmbed},[l.BitType.vendorIframelyPreviewMini]:{since:"1.5.10",baseBitType:l.BitType.vendorIframelyEmbed},[l.BitType.vendorJupyterOutput]:{since:"1.4.3",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.jupyterId},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.jupyterExecutionCount}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorJupyterCellCode]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorJupyterCellMarkdown]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorJupyterCellRaw]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorJupyterIpynb]:{since:"1.4.3",baseBitType:l.BitType.vendorJupyterOutput},[l.BitType.vendorPadletEmbed]:{since:"1.3.0",baseBitType:l.BitType.code,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.padletId}],textFormatDefault:c.TextFormat.text},[l.BitType.vendorStripePricingTable]:{since:"1.20.0",baseBitType:l.BitType.article,tags:[{type:s.BitTagType.property,configKey:n.PropertyConfigKey.stripePricingTableId,minCount:1},{type:s.BitTagType.property,configKey:n.PropertyConfigKey.stripePublishableKey,minCount:1}]},[l.BitType.vendorStripePricingTableExternal]:{since:"3.13.0",baseBitType:l.BitType.vendorStripePricingTable},[l.BitType.video]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideo,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.videoLandscape]:{since:"1.3.0",baseBitType:l.BitType.video},[l.BitType.videoPortrait]:{since:"1.3.0",baseBitType:l.BitType.video},[l.BitType.videoEmbed]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideoEmbed,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.videoEmbedLandscape]:{since:"1.3.0",baseBitType:l.BitType.videoEmbed},[l.BitType.videoEmbedPortrait]:{since:"1.3.0",baseBitType:l.BitType.videoEmbed},[l.BitType.videoLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceVideoLink,minCount:1}],resourceAttachmentAllowed:!1},[l.BitType.videoLinkLandscape]:{since:"1.3.0",baseBitType:l.BitType.videoLink},[l.BitType.videoLinkPortrait]:{since:"1.3.0",baseBitType:l.BitType.videoLink},[l.BitType.websiteLink]:{since:"1.3.0",baseBitType:l.BitType._standard,tags:[{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceBitTags},{type:s.BitTagType.group,configKey:o.GroupConfigKey.group_resourceWebsiteLink,minCount:1}],resourceAttachmentAllowed:!1}};t.BITS=y},6877:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextLocation=void 0;const i=(0,r(4718).superenum)({tag:"tag",body:"body"});t.TextLocation=i},6915:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GroupConfigType=void 0;const i=(0,r(4718).superenum)({standard:"standard",resource:"resource",comboResource:"comboResource"});t.GroupConfigType=i},6936:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.initEnv=t.env=void 0;const i=r(6278),o=r(9561),n=r(2287),a=r(5659);const s=new class{constructor(){Object.defineProperty(this,"userAgentInfo",{value:(0,a.parseUserAgent)(),enumerable:!1}),this.bootTimestamp=Date.now(),this.app="",this.appVersion=n.EMPTY_VERSION,this.environment=this.getEnvironment(),this.environmentVersion=this.getEnvironmentVersion(),this.isBrowser=this.getIsBrowser(),this.isNode=this.environment===i.Environment.node,this.isCI=this.getIsCI(),this.NODE_ENV=this.getNodeEnv(),this.os=this.getOs(),this.osVersion=this.getOsVersion()}init(e,t){this.app=e,this.appVersion=this.parseMMBVersion(t)}get upTimestamp(){return Date.now()-this.bootTimestamp}getEnvironment(){return this.userAgentInfo?this.userAgentInfo.browser:"undefined"!=typeof process&&void 0!==process.versions&&process.versions.node?i.Environment.node:i.Environment.unknown}getEnvironmentVersion(){return this.userAgentInfo?this.parseMMBVersion(this.userAgentInfo.browserVersion):"undefined"!=typeof process?this.parseMMBVersion(process.version):n.EMPTY_VERSION}getOs(){return this.userAgentInfo?this.userAgentInfo.os:("undefined"!=typeof process&&void 0!==process.versions&&process.versions.node,o.Os.unknown)}getOsVersion(){return this.userAgentInfo?this.parseMMBVersion(this.userAgentInfo.osVersion):"undefined"!=typeof process?this.parseMMBVersion(""):n.EMPTY_VERSION}getIsBrowser(){return!("undefined"==typeof window||"undefined"==typeof document||"undefined"==typeof navigator||!navigator.userAgent)}getIsCI(){return!("undefined"==typeof process||!process.env||!process.env.CI)}getNodeEnv(){return"undefined"!=typeof process&&process.env?"production":""}parseMMBVersion(e){if(!e)return n.EMPTY_VERSION;e.startsWith("v")&&(e=e.substring(1));const t=e.split(".",1e3);let r="",i="",o="",a="";for(let e=0,n=t.length;e<n;e++){const n=t[e];0===e?r=n:1===e?i=n:2===e?a=n:3===e&&(o=n)}return{full:e,major:r,minor:i,patch:a,build:o}}};t.env=s;const l=s.init.bind(s);t.initEnv=l},6989:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ArrayUtils=void 0;const r=new class{asArray(e){if(null!=e)return Array.isArray(e)?e:[e]}asSingle(e,t){if(null!=e)return Array.isArray(e)?e.length>0?t?e[e.length-1]:e[0]:void 0:e}};t.ArrayUtils=r},6991:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.commentTagContentProcessor=function(e,t,r,o){if(!o.internalComments)return;const{value:n}=r,a=i.StringUtils.isString(n)?i.StringUtils.trimmedString(n):void 0;if(!a)return;o.internalComments.push(a)};const i=r(9681)},7112:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.groupConfigKeys=t.GroupConfigKey=void 0;const i=r(4718),o={group_standardAllBits:"group_standardAllBits",group_standardItemLeadInstructionHint:"group_standardItemLeadInstructionHint",group_standardExample:"group_standardExample",group_standardTags:"group_standardTags",group_imageSource:"group_imageSource",group_technicalTerm:"group_technicalTerm",group_person:"group_person",group_gap:"group_gap",group_trueFalse:"group_trueFalse",group_markConfig:"group_markConfig",group_mark:"group_mark",group_bookCommon:"group_bookCommon",group_learningPathCommon:"group_learningPathCommon",group_quizCommon:"group_quizCommon",group_resourceBitTags:"group_resourceBitTags",group_resourceCommon:"group_resourceCommon",group_resourceImageCommon:"group_resourceImageCommon",group_resourceAudioCommon:"group_resourceAudioCommon",group_resourceVideoCommon:"group_resourceVideoCommon",group_resourceIcon:"group_resourceIcon",group_resourceImage:"group_resourceImage",group_resourceImageEmbed:"group_resourceImageEmbed",group_resourceImageLink:"group_resourceImageLink",group_resourceImageResponsive:"group_resourceImageResponsive",group_resourceImagePortrait:"group_resourceImagePortrait",group_resourceImageLandscape:"group_resourceImageLandscape",group_resourceAudio:"group_resourceAudio",group_resourceAudioEmbed:"group_resourceAudioEmbed",group_resourceAudioLink:"group_resourceAudioLink",group_resourceVideo:"group_resourceVideo",group_resourceVideoEmbed:"group_resourceVideoEmbed",group_resourceVideoLink:"group_resourceVideoLink",group_resourceStillImageFilm:"group_resourceStillImageFilm",group_resourceStillImageFilmEmbed:"group_resourceStillImageFilmEmbed",group_resourceStillImageFilmLink:"group_resourceStillImageFilmLink",group_resourceArticle:"group_resourceArticle",group_resourceArticleEmbed:"group_resourceArticleEmbed",group_resourceArticleLink:"group_resourceArticleLink",group_resourceDocument:"group_resourceDocument",group_resourceDocumentEmbed:"group_resourceDocumentEmbed",group_resourceDocumentLink:"group_resourceDocumentLink",group_resourceDocumentDownload:"group_resourceDocumentDownload",group_resourceAppLink:"group_resourceAppLink",group_resourceWebsiteLink:"group_resourceWebsiteLink"};t.groupConfigKeys=o;const n=(0,i.superenum)(o);t.GroupConfigKey=n},7124:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkPegParserProcessor=void 0;const o=r(5809),n=r(7735),a=r(2028),s=r(5854),l=r(6149),p=r(385),u=r(6877),c=r(9681),y=r(4266),g=r(5033),d=r(1083),f=r(4402),m=r(4382),T=r(3904),h=r(9289),b=r(5189),B=r(9647),v=r(3990),C=r(6521),P=r(7667),x=r(9885),k=r(3029),K=!1,w=!0,_=!0,S=!0,A=!0,L=new o.Builder;t.BitmarkPegParserProcessor=class{constructor(e){this.nonFatalWarnings=[],this.nonFatalErrors=[],this.parser={},this.parse=e.parse,this.parserText=e.parserText,this.parserLocation=e.parserLocation,this.context={bitConfig:a.Config.getBitConfig(s.BitType._error),bitType:s.BitType._error,textFormat:p.TextFormat.bitmarkPlusPlus,DEBUG_BIT_RAW:true,DEBUG_BIT_CONTENT_RAW:K,DEBUG_BIT_CONTENT:w,DEBUG_BIT_TAGS:_,DEBUG_BODY:S,DEBUG_FOOTER:A,DEBUG_CHAIN_CONTENT:true,DEBUG_CHAIN_TAGS:true,DEBUG_CARD_SET_CONTENT:true,DEBUG_CARD_SET:true,DEBUG_CARD_TAGS:true,parser:this.parser,parse:this.parse,bitContentProcessor:this.bitContentProcessor.bind(this),splitBitContent:this.splitBitContent.bind(this),addWarning:this.addWarning.bind(this),addError:this.addError.bind(this),debugPrint:this.debugPrint.bind(this),state:{}}}buildBits(e){var t;const r=[];let i=[];for(const o of e){if(!o)continue;const e=o.value;e?r.push(e):i=i.concat(null!==(t=o.errors)&&void 0!==t?t:[])}return L.buildBitmark({bits:r,errors:i.length>0?i:void 0})}buildBit(e,t){var r;const{bitType:o,textFormat:n,resourceType:l,bitLevel:p,isCommented:u}=e;if(!o||a.Config.isOfBitType(o,s.BitType._error))return this.invalidBit();const c=a.Config.getBitConfig(o);this.context.bitConfig=c,this.context.bitType=o,this.context.textFormat=n,this.context.resourceType=l;const g=a.Config.isOfBitType(o,s.BitType.trueFalse1),f=a.Config.isOfBitType(o,s.BitType.multipleChoice1),m=a.Config.isOfBitType(o,s.BitType.multipleResponse1);this.debugPrint("BIT CONTENT",t),this.resetParserState(),t=this.squashUnwantedInlineBodyBits(t),t=y.BitmarkPegParserValidator.validateBitTags(this.context,t);const T=this.bitContentProcessor(k.BitContentLevel.Bit,c.tags,t),{body:h,footer:b,cardSet:B,title:v,statement:x,statements:K,choices:w,responses:_,propertyStyleResources:S,resources:A,posterImage:I,internalComments:F}=T,N=i(T,["body","footer","cardSet","title","statement","statements","choices","responses","propertyStyleResources","resources","posterImage","internalComments"]);this.debugPrint("BIT TAGS",N),this.debugPrint("BIT BODY",h),this.debugPrint("BIT FOOTER",b);const O=(0,P.buildTitles)(this.context,o,v),E=(0,d.buildCards)(this.context,o,n,B,x,K,w,_),R=(0,C.buildResources)(this.context,l,A),V=[...null!=F?F:[],...null!==(r=E.internalComments)&&void 0!==r?r:[]],j=this.buildBitLevelWarnings(),M=this.buildBitLevelErrors();j&&(this.parser.warnings=j),M&&(this.parser.errors=M);return{value:L.buildBit(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({bitType:o,bitLevel:p,isCommented:u,textFormat:n,resourceType:l},O),{posterImage:I,statement:g?x:void 0,choices:f?w:void 0,responses:m?_:void 0}),N),S),{resources:R}),E),{body:h,footer:b,internalComment:V,parser:this.parser}))}}invalidBit(e){e&&this.addError("Invalid bit"),this.parser.errors=this.buildBitLevelErrors();return{value:L.buildBit({bitType:a.Config.getBitType(s.BitType._error),bitLevel:1,parser:this.parser})}}buildBitHeader(e,t,r){const i=n.Breakscape.unbreakscape(e,{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag}),o=a.Config.getBitType(i),c=a.Config.isBitTypeCommented(i);a.Config.isOfBitType(o,s.BitType._error)&&this.addError(`Invalid bit type: '${i}'`);const y=a.Config.getBitConfig(o);t>a.Config.bitLevelMax?(this.addWarning(`Bit level of ${t} too high, setting to max value of ${a.Config.bitLevelMax}`),t=a.Config.bitLevelMax):t<a.Config.bitLevelMin&&(this.addWarning(`Bit level of ${t} too low, setting to min value of ${a.Config.bitLevelMin}`),t=a.Config.bitLevelMin);let g=p.TextFormat.fromValue(r.textFormat);r.textFormat&&!g&&this.addWarning(`Invalid text format '${r.textFormat}', defaulting to '${y.textFormatDefault}'`),g===p.TextFormat.bitmarkMinusMinus&&(g=p.TextFormat.bitmarkPlusPlus,this.addWarning("bitmark-- text format is deprecated. Bit will be parsed as bitmark++")),g=null!=g?g:y.textFormatDefault;const d=l.ResourceTag.fromValue(r.resourceType);return r.resourceType&&!d&&this.addWarning(`Invalid resource type '${r.resourceType}', it will be ignored`),{bitType:o,bitLevel:t,textFormat:null!=g?g:y.textFormatDefault,resourceType:d,isCommented:c}}buildTextAndResourceType(e,t){const r={},i=e=>{if(e){const t=n.Breakscape.unbreakscape(c.StringUtils.string(e.value),{textFormat:p.TextFormat.bitmarkMinusMinus,textLocation:u.TextLocation.tag});e.type===k.TypeKey.TextFormat?r.textFormat=t:r.resourceType=t}};return i(e),i(t),r}resetParserState(){this.context.state={}}squashUnwantedInlineBodyBits(e){const t=[];if(!e)return t;const{textFormat:r}=this.context,i=r===p.TextFormat.bitmarkMinusMinus||r===p.TextFormat.bitmarkPlusPlus,o=(e,t="")=>{const{chain:r,parser:i}=e;if(t+=i.text,r)for(const e of r)t=o(e,t);return t};let n=!1;for(const r of e){const{type:e,value:a}=r,s=null!=a?a:"";let l=!1;if(n||(e===k.TypeKey.BodyText&&!i&&s&&s.trim()&&(n=!0),e===k.TypeKey.PlainTextDivider&&(n=!0,l=!0)),l)t.push({type:k.TypeKey.BodyText,value:"\n"});else if(n)if(e===k.TypeKey.BodyText)t.push({type:k.TypeKey.BodyTextPlain,value:a});else{const e=o(r);t.push({type:k.TypeKey.BodyTextPlain,value:e})}else t.push(r)}return t}bitContentProcessor(e,t,r){const i={};if(!r)return i;const{bitType:o,textFormat:a}=this.context;i.title=[],i.solutions=[],i.__solutionsAst=[],i.statements=[],i.choices=[],i.responses=[],i.propertyStyleResources={},i.resources=[],i.trueFalse=[],i.markConfig=[],i.extraProperties={},i.internalComments=[];let s=!1,l=!1;const p=[];let u=n.Breakscape.EMPTY_STRING,c=n.Breakscape.EMPTY_STRING,d=n.Breakscape.EMPTY_STRING,K=n.Breakscape.EMPTY_STRING;const w=e===k.BitContentLevel.Bit,_=e===k.BitContentLevel.Card,S=e===k.BitContentLevel.Chain,A=()=>{if(u){u=y.BitmarkPegParserValidator.checkBodyPart(this.context,e,u);const t=g.BodyContentProcessor.buildBodyText(u,!1);p.push(t)}u=n.Breakscape.EMPTY_STRING};for(const o of r){const{type:r,value:a}=o;switch(r){case k.TypeKey.ItemLead:(0,h.itemLeadChainContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Instruction:case k.TypeKey.Hint:case k.TypeKey.Anchor:case k.TypeKey.SampleSolution:(0,f.defaultTagContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Reference:(0,v.referenceTagContentProcessor)(this.context,e,t,o,i,s),s=!0;break;case k.TypeKey.Title:(0,P.titleTagContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Property:(0,B.propertyContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.Gap:S||A(),(0,T.gapChainContentProcessor)(this.context,e,t,o,i,p);break;case k.TypeKey.Mark:S||A(),(0,b.markChainContentProcessor)(this.context,e,t,o,i,p);break;case k.TypeKey.True:case k.TypeKey.False:S||A(),(0,x.trueFalseChainContentProcessor)(this.context,e,t,o,i,p);break;case k.TypeKey.Resource:(0,C.resourceContentProcessor)(this.context,e,t,o,i);break;case k.TypeKey.CardSet:i.cardSet=a,l=!0;break;case k.TypeKey.BodyText:case k.TypeKey.CardText:l?c=n.Breakscape.concatenate(c,a):u=n.Breakscape.concatenate(u,a);break;case k.TypeKey.BodyTextPlain:l?K=n.Breakscape.concatenate(K,a):d=n.Breakscape.concatenate(d,a);break;case k.TypeKey.FooterDivider:l&&(c=n.Breakscape.concatenate(c,a)),l=!0}}A();const L=d?g.BodyContentProcessor.buildBodyText(d,!0):void 0;if(L&&p.push(L),i.itemLead){const e=i.itemLead.length;e>0&&(i.item=i.itemLead[0]),e>1&&(i.lead=i.itemLead[1]),e>2&&(i.pageNumber=i.itemLead[2]),e>3&&(i.marginNumber=i.itemLead[e-1])}return w?i.body=g.BodyContentProcessor.process(this.context,e,o,a,t,i,p,!1):_&&(i.cardBody=g.BodyContentProcessor.process(this.context,e,o,a,t,i,p,!0)),i.footer=m.FooterContentProcessor.process(this.context,e,t,i,c,K),0===Object.keys(i.extraProperties).length&&delete i.extraProperties,0===i.title.length&&delete i.title,0===i.solutions.length&&delete i.solutions,0===i.statements.length&&delete i.statements,0===i.choices.length&&delete i.choices,0===i.responses.length&&delete i.responses,0===i.trueFalse.length&&delete i.trueFalse,0===i.markConfig.length&&delete i.markConfig,0===Object.keys(i.propertyStyleResources).length&&delete i.propertyStyleResources,0===i.resources.length&&delete i.resources,0===i.internalComments.length&&delete i.internalComments,i}buildBitLevelWarnings(){let e;return this.nonFatalWarnings.length>0&&(e=this.nonFatalWarnings,this.nonFatalWarnings=[]),e}buildBitLevelErrors(){let e;return this.nonFatalErrors.length>0&&(e=this.nonFatalErrors,this.nonFatalErrors=[]),e}splitBitContent(e,t){const r=[];let i=[];for(const o of e)t.includes(o.type)&&(i.length>0&&r.push(i),i=[]),i.push(o);return i.length>0&&r.push(i),r}addWarning(e,t,r){var i,o,n;const a={message:e,text:null!==(i=null==t?void 0:t.parser.text)&&void 0!==i?i:this.parserText(),location:null!==(o=null==t?void 0:t.parser.location)&&void 0!==o?o:this.parserLocation(),original:null!==(n=null==r?void 0:r.parser)&&void 0!==n?n:void 0};a.original||delete a.original,this.nonFatalWarnings.push(a)}addError(e,t,r){var i,o,n;const a={message:e,text:null!==(i=null==t?void 0:t.parser.text)&&void 0!==i?i:this.parserText(),location:null!==(o=null==t?void 0:t.parser.location)&&void 0!==o?o:this.parserLocation(),original:null!==(n=null==r?void 0:r.parser)&&void 0!==n?n:void 0};a.original||delete a.original,this.nonFatalErrors.push(a)}debugPrint(e,t){}}},7203:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyAstKey=void 0;const i=(0,r(4718).superenum)({ast_isCaseSensitive:"isCaseSensitive",ast_referenceProperty:"referenceProperty",ast_markConfig:"markConfig",ast_productList:"productList",ast_productVideoList:"productVideoList"});t.PropertyAstKey=i},7461:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PeggyGrammarLocation=void 0;t.PeggyGrammarLocation=class{constructor(e,t){this.source=e,this.start=t}toString(){return String(this.source)}offset(e){return{line:e.line+this.start.line-1,column:1===e.line?e.column+this.start.column-1:e.column,offset:e.offset+this.start.offset}}static offsetStart(e){return e.source&&"function"==typeof e.source.offset?e.source.offset(e.start):e.start}static offsetEnd(e){return e.source&&"function"==typeof e.source.offset?e.source.offset(e.end):e.end}}},7667:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.titleTagContentProcessor=function(e,t,r,i,o){const{textFormat:s}=e,{value:l}=i,p=o.title;if(!p)return;const u=l,c=n.StringUtils.trimmedString(u.title),y=u.level.length;p[y]={titleAst:a.toAst(null!=c?c:"",{textFormat:s,isProperty:!0}),titleString:null!=c?c:""}},t.buildTitles=function(e,t,r){var n,a,s,l,p,u,c,y,g,d;if(r=null!=r?r:[],i.Config.isOfBitType(t,o.BitType.chapter)){let e;return r.length>0&&(e=r[r.length-1]),{title:null!==(n=null==e?void 0:e.titleAst)&&void 0!==n?n:[],titleString:null!==(a=null==e?void 0:e.titleString)&&void 0!==a?a:"",level:r.length>0?r.length-1:void 0}}return{title:null!==(l=null===(s=r[1])||void 0===s?void 0:s.titleAst)&&void 0!==l?l:void 0,titleString:null!==(u=null===(p=r[1])||void 0===p?void 0:p.titleString)&&void 0!==u?u:void 0,subtitle:null!==(y=null===(c=r[2])||void 0===c?void 0:c.titleAst)&&void 0!==y?y:void 0,subtitleString:null!==(d=null===(g=r[2])||void 0===g?void 0:g.titleString)&&void 0!==d?d:void 0}};const i=r(2028),o=r(5854),n=r(9681),a=new(r(777).TextParser)},7678:(e,t,r)=>{const{deserialize:i}=r(5005),{serialize:o}=r(5416);Object.defineProperty(t,"__esModule",{value:!0}).default="function"==typeof structuredClone?(e,t)=>t&&("json"in t||"lossy"in t)?i(o(e,t)):structuredClone(e):(e,t)=>i(o(e,t)),t.deserialize=i,t.serialize=o},7735:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Breakscape=void 0;const i=r(385),o=r(6877),n=r(9681),a=/([*`_!=])(?=\1)/,s=/(\[)([.@#▼►%!?+\-$_=&])/,l=/^(~)(~~~[ \t]*)$/,p=/^(\$)(\$\$\$[ \t]*)$/,u=/(\^*])/,c=/(\^+)/,y=`${u.source}|${c.source}`,g=`${a.source}|${s.source}|${l.source}|${p.source}|${c.source}`,d=`${a.source}|${/^(\|)(code[\s]*|code:|image:|[\s]*$)/.source}|${/^([#]{1,3})([^\S\r\n]+)/.source}|${/^(•)([0-9]+[iI]*|[a-zA-Z]{1}|_|\+|-|)([^\S\r\n]+)/.source}|${s.source}|${l.source}|${p.source}|${c.source}`,f=`${/^(\[)(\^*)(\.)/.source}`,m=new RegExp(`${a.source}|${u.source}|${c.source}`,"gm"),T=new RegExp(y,"gm"),h=new RegExp(g,"gm"),b=new RegExp(d,"gm"),B=new RegExp(f,"gm"),v=new RegExp("^(?:(\\[)(\\^*)(\\.))|(\\^+)","gm"),C="$1$4^$2$3",P=new RegExp("\\^([\\^]*)","gm"),x=new RegExp("^(\\[)\\^(\\^*)(\\.)","gm"),k=new RegExp("^(\\||•|#)","gm"),K={textFormat:i.TextFormat.bitmarkMinusMinus,textLocation:o.TextLocation.body};const w=new class{constructor(){this.EMPTY_STRING=""}breakscape(e,t){if(null==e)return e;const r=Object.assign({},K,t),{regex:i,replacer:o}=this.selectBreakscapeRegexAndReplacer(r.textFormat,r.textLocation,r.v2),a=e=>e?e=e.replace(i,o):e;if(Array.isArray(e)){const t=r.modifyArray?e:new Array(e.length);for(let r=0,i=e.length;r<i;r++){const i=e[r];n.StringUtils.isString(i)&&(t[r]=a(i))}e=t}else n.StringUtils.isString(e)&&(e=a(e));return e}unbreakscape(e,t){if(null==e)return e;const r=Object.assign({},K,t),{regex:i,replacer:o}=this.selectUnbreakscapeRegexAndReplacer(r.textFormat,r.textLocation),a=e=>e?e=e.replace(i,o):e;if(Array.isArray(e)){const t=r.modifyArray?e:new Array(e.length);for(let r=0,i=e.length;r<i;r++){const i=e[r];n.StringUtils.isString(i)?t[r]=a(i):t[r]=i}e=t}else n.StringUtils.isString(e)&&(e=a(e));return e}breakscapeCode(e,t){if(null==e)return e;const r=Object.assign({},K,t),i=e=>e?e.replace(k,"$1^"):e;if(Array.isArray(e)){const t=r.modifyArray?e:[e.length];for(let t=0,r=e.length;t<r;t++){const r=e[t];n.StringUtils.isString(r)&&(e[t]=i(r))}e=t}else n.StringUtils.isString(e)&&(e=i(e));return e}selectBreakscapeRegexAndReplacer(e,t,r){let n,a;return t===o.TextLocation.tag?(n=T,a="$2^$1",r||e!==i.TextFormat.bitmarkMinusMinus&&e!==i.TextFormat.bitmarkPlusPlus||(n=m,a="$1$3^$2")):(n=B,a="$1^$2$3",e===i.TextFormat.bitmarkMinusMinus?r?(n=v,a=C):(n=h,a="$1$2$4$6^$3$5$7$8"):e===i.TextFormat.bitmarkPlusPlus&&(r?(n=v,a=C):(n=b,a="$1$2$4$6$9$11$13$15^$3$5$7$8$10$12$14"))),{regex:n,replacer:a}}selectUnbreakscapeRegexAndReplacer(e,t){const r=!(e===i.TextFormat.bitmarkMinusMinus||e===i.TextFormat.bitmarkPlusPlus);let n=P,a="$1";return t===o.TextLocation.body&&r&&(n=x,a="$1$2$3"),{regex:n,replacer:a}}concatenate(e,t){return e+t}};t.Breakscape=w},7797:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.tagConfigKeys=t.TagConfigKey=void 0;const i=r(4718),o={title:"title",anchor:"anchor",tag_reference:"tag_reference",property:"property",itemLead:"itemLead",instruction:"instruction",hint:"hint",true:"true",false:"false",sampleSolution:"sampleSolution",gap:"gap",tag_mark:"tag_mark",resource:"resource"};t.tagConfigKeys=o;const n=(0,i.superenum)(o);t.TagConfigKey=n},7984:function(e,t,r){var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(o,n){function a(e){try{l(i.next(e))}catch(e){n(e)}}function s(e){try{l(i.throw(e))}catch(e){n(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.JsonObjectGenerator=void 0;const o=r(6772),n=r(2497);t.JsonObjectGenerator=class{constructor(e){this.writer=new o.StringWriter,this.generator=new n.JsonGenerator(this.writer,e)}generate(e){return i(this,void 0,void 0,(function*(){return yield this.generator.generate(e),JSON.parse(this.writer.getString())}))}generateSync(e){return this.generator.generateSync(e),JSON.parse(this.writer.getString())}}},8025:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.NumberUtils=void 0;const r=new class{asNumber(e,t){if(null==e)return null!=t?t:void 0;const r=+e;return Number.isNaN(r)||!isFinite(r)?null!=t?t:void 0:r}isNumeric(e){if(null==e)return!1;const t=+e;return!Number.isNaN(t)&&isFinite(t)}};t.NumberUtils=r},8199:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardSetConfigKey=void 0;const i=(0,r(4718).superenum)({_flashcard:"_flashcard",_definitionList:"_definitionList",_elements:"_elements",_statements:"_statements",_quiz:"_quiz",_feedback:"_feedback",_questions:"_questions",_matchPairs:"_matchPairs",_matchAudioPairs:"_matchAudioPairs",_matchImagePairs:"_matchImagePairs",_matchMatrix:"_matchMatrix",_table:"_table",_pronunciationTable:"_pronunciationTable",_botActionResponses:"_botActionResponses",_exampleBitList:"_exampleBitList",_clozeList:"_clozeList",_ingredients:"_ingredients",_bookReferenceList:"_bookReferenceList"});t.CardSetConfigKey=i},8216:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.itemLeadTagContentProcessor=function(e,t,r,n,a){const{textFormat:s}=e,{value:l}=n,p=new o.TextParser,u=i.StringUtils.trimmedString(l);a.itemLead||(a.itemLead=[]);const c=p.toAst(u,{textFormat:s,isProperty:!0});a.itemLead.push(c)};const i=r(9681),o=r(777)},8321:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.StartRules=void 0,t.SyntaxError=p,t.parse=c;const i=r(7735),o="8.32.2";function n(e){return"string"!=typeof e?null:i.Breakscape.unbreakscape(e)}function a(e){e&&"object"==typeof e&&(delete e._tempParsingParent,delete e._tempListStart,Object.keys(e).forEach((t=>{a(e[t])})))}function s(e){function t(e){for(let i=e.length-1;i>=0;i--){const o=e[i];(r=o)&&"text"===r.type&&!r.text?e.splice(i,1):o&&Array.isArray(o.content)&&t(o.content)}var r}return Array.isArray(e)?t(e):e&&Array.isArray(e.content)&&t(e.content),e}function l(e){return"undefined"!=typeof parser?parser.parse(e,{startRule:"bitmarkPlusString"}):c(e,{startRule:"bitmarkPlusString"})}function p(e,t,r,i){var o=Error.call(this,e);return Object.setPrototypeOf&&Object.setPrototypeOf(o,p.prototype),o.expected=t,o.found=r,o.location=i,o.name="SyntaxError",o}function u(e,t,r){return r=r||" ",e.length>t?e:(t-=e.length,e+(r+=r.repeat(t)).slice(0,t))}function c(e,t){var r,i={},u=(t=void 0!==t?t:{}).grammarSource,c={version:qn,bitmarkPlusPlus:function(){var e,t;if(Mn++,e=[],(t=Hn())!==i)for(;t!==i;)e.push(t),t=Hn();else e=i;e===i&&(e=function(){var e,t;return e=En,t="",t=Xi(),e=t,e}());Mn--,e===i&&(t=i,0===Mn&&Wn(wt));return e},bitmarkPlus:function(){var e,t;Mn++,e=En,t=Pa(),t=Do(t),e=t,Mn--,t=i,0===Mn&&Wn(wt);return e},bitmarkMinusMinus:function(){var e,t;Mn++,e=En,t=Ia(),t=Kn(t),e=t,Mn--,t=i,0===Mn&&Wn(wi);return e},bitmarkPlusString:function(){var e;Mn++,e=Pa(),Mn--,0===Mn&&Wn(sr);return e},bitmarkMinusMinusString:Ia},y=qn,g="|",d="### ",f="## ",m="# ",T="code",h=":",b="bitmark++",B="bitmark--",v="JavaScript",C="• ",P="•_ ",x="•",k=" ",K="I ",w="i ",_="•A ",S="•a ",A="•+ ",L="•- ",I="\t",F="image",N="#",O="@",E="width",R="height",V="alignment",j="captionAlign",M="left",D="center",G="right",U="=",$="|latex|",J="|imageInline:",W="alignmentVertical",z="size",q="top",H="middle",Y="bottom",X="baseline",Q="sub",Z="super",ee="text-bottom",te="text-top",re="line-height",ie="font-height",oe="explicit",ne="link:",ae="extref:",se="provider:",le="xref:",pe="►",ue="symbol:",ce="footnote:",ye="footnote*:",ge="var:",de="code:",fe="timer",me="timer:",Te="duration:",he="P",be="color:",Be="|►",ve="bold",Ce="italic",Pe="light",xe="highlight",ke="strike",Ke="subscript",we="superscript",_e="ins",Se="del",Ae="underline",Le="doubleUnderline",Ie="circle",Fe="languageEm",Ne="userUnderline",Oe="userDoubleUnderline",Ee="userStrike",Re="userCircle",Ve="userHighlight",je="notranslate",Me="aqua",De="black",Ge="blue",Ue="pink",$e="fuchsia",Je="lightgrey",We="gray",ze="darkgray",qe="green",He="lime",Ye="magenta",Xe="maroon",Qe="navy",Ze="olive",et="orange",tt="purple",rt="red",it="silver",ot="teal",nt="violet",at="white",st="yellow",lt="*",pt="_",ut="`",ct="!",yt="[!",gt="]",dt="\n",ft="\r\n",mt="http",Tt="s",ht="://",bt="mailto:",Bt=/^[ \t]/,vt=/^[0-9]/,Ct=/^[:|]/,Pt=/^[\r\u2028-\u2029]/,xt=/^[^\n\r\u2028\u2029]/,kt=/^[!#-;=?-[\]-_a-{}-~]/,Kt={type:"any"},wt=Un("StyledText"),_t=Dn("|",!1),St=Dn("### ",!1),At=Dn("## ",!1),Lt=Dn("# ",!1),It=Dn("code",!1),Ft=Gn([" ","\t"],!1,!1),Nt=Dn(":",!1),Ot=Dn("bitmark++",!1),Et=Dn("bitmark--",!1),Rt=Dn("JavaScript",!1),Vt=Dn("• ",!1),jt=Dn("•_ ",!1),Mt=Dn("•",!1),Dt=Gn([["0","9"]],!1,!1),Gt=Dn(" ",!1),Ut=Dn("I ",!1),$t=Dn("i ",!1),Jt=Dn("•A ",!1),Wt=Dn("•a ",!1),zt=Dn("•+ ",!1),qt=Dn("•- ",!1),Ht=Dn("\t",!1),Yt=Dn("image",!1),Xt=Dn("#",!1),Qt=Dn("@",!1),Zt=Gn([":","|"],!1,!1),er=Dn("width",!1),tr=Dn("height",!1),rr=Dn("alignment",!1),ir=Dn("captionAlign",!1),or=Dn("left",!1),nr=Dn("center",!1),ar=Dn("right",!1),sr=Un("StyledString"),lr=Dn("=",!1),pr=Dn("|latex|",!1),ur=Dn("|imageInline:",!1),cr=Dn("alignmentVertical",!1),yr=Dn("size",!1),gr=Dn("top",!1),dr=Dn("middle",!1),fr=Dn("bottom",!1),mr=Dn("baseline",!1),Tr=Dn("sub",!1),hr=Dn("super",!1),br=Dn("text-bottom",!1),Br=Dn("text-top",!1),vr=Dn("line-height",!1),Cr=Dn("font-height",!1),Pr=Dn("explicit",!1),xr=Dn("link:",!1),kr=Dn("extref:",!1),Kr=Dn("provider:",!1),wr=Dn("xref:",!1),_r=Dn("►",!1),Sr=Dn("symbol:",!1),Ar=Dn("footnote:",!1),Lr=Dn("footnote*:",!1),Ir=Dn("var:",!1),Fr=Dn("code:",!1),Nr=Dn("timer",!1),Or=Dn("timer:",!1),Er=Dn("duration:",!1),Rr=Dn("P",!1),Vr=Dn("color:",!1),jr=Dn("|►",!1),Mr=Dn("bold",!1),Dr=Dn("italic",!1),Gr=Dn("light",!1),Ur=Dn("highlight",!1),$r=Dn("strike",!1),Jr=Dn("subscript",!1),Wr=Dn("superscript",!1),zr=Dn("ins",!1),qr=Dn("del",!1),Hr=Dn("underline",!1),Yr=Dn("doubleUnderline",!1),Xr=Dn("circle",!1),Qr=Dn("languageEm",!1),Zr=Dn("userUnderline",!1),ei=Dn("userDoubleUnderline",!1),ti=Dn("userStrike",!1),ri=Dn("userCircle",!1),ii=Dn("userHighlight",!1),oi=Dn("notranslate",!1),ni=Dn("aqua",!1),ai=Dn("black",!1),si=Dn("blue",!1),li=Dn("pink",!1),pi=Dn("fuchsia",!1),ui=Dn("lightgrey",!1),ci=Dn("gray",!1),yi=Dn("darkgray",!1),gi=Dn("green",!1),di=Dn("lime",!1),fi=Dn("magenta",!1),mi=Dn("maroon",!1),Ti=Dn("navy",!1),hi=Dn("olive",!1),bi=Dn("orange",!1),Bi=Dn("purple",!1),vi=Dn("red",!1),Ci=Dn("silver",!1),Pi=Dn("teal",!1),xi=Dn("violet",!1),ki=Dn("white",!1),Ki=Dn("yellow",!1),wi=Un("MinimalStyledText"),_i=Un("MinimalStyledString"),Si=Dn("*",!1),Ai=Dn("_",!1),Li=Dn("`",!1),Ii=Dn("!",!1),Fi=Dn("[!",!1),Ni=Dn("]",!1),Oi=Un("Line Terminator"),Ei=Dn("\n",!1),Ri=Dn("\r\n",!1),Vi=Gn(["\r",["\u2028","\u2029"]],!1,!1),ji=(Un("whitespace in line"),Un("space"),Un("language tag separator"),Un("white space, separator"),Gn(["\t","\v","\f"," "," ","\ufeff"," "," "," ",[" "," "]," "," "," "],!1,!1),Gn(["\n","\r","\u2028","\u2029"],!1,!1),Gn(["\n","\r","\u2028","\u2029"],!0,!1)),Mi=(Gn(["\n","\r","\u2028","\u2029","\t","\v","\f"," "," ","\ufeff"," "," "," ",[" "," "]," "," "," "],!0,!1),Dn("http",!1)),Di=Dn("s",!1),Gi=Dn("://",!1),Ui=Dn("mailto:",!1),$i=Gn(["!",["#",";"],"=",["?","["],["]","_"],["a","{"],["}","~"]],!1,!1),Ji=function(){return o},Wi=function(e){return s(Object.assign({},e))},zi=function(e){let t=Object.assign({},e);a(t);return s(t)},qi=function(e){return Object.assign({},e)},Hi=function(e){return Object.assign({},e)},Yi=function(e){return s(Object.assign({},e))},Xi=function(){return[]},Qi=function(e,t){return{type:"heading",content:l(t),attrs:{level:e.length-1}}},Zi=function(e){return e},eo=function(e,t){return Object.assign(Object.assign({},e),{content:t})},to=function(){return{type:"codeBlock",language:""}},ro=function(e){return{type:"codeBlock",attrs:{language:e.trim().toLowerCase()}}},io=function(e){return[{type:"text",text:n(e.trim())}]},oo=function(e){return e},no=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},ao=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},so=function(e,t){let r=t[0]._tempListStart;return Object.assign(Object.assign({},e),{attrs:{start:r},content:t})},lo=function(e,t){let r=t[0]._tempListStart;return Object.assign(Object.assign({},e),{attrs:{start:r},content:t})},po=function(e,t){let r=t[0]._tempListStart;return Object.assign(Object.assign({},e),{attrs:{start:r},content:t})},uo=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},co=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},yo=function(e,t){return Object.assign(Object.assign({},e),{content:t,attrs:{}})},go=function(){return{type:"bulletList"}},fo=function(){return{type:"noBulletList"}},mo=function(){return{type:"orderedList"}},To=function(){return{type:"orderedListRoman"}},ho=function(){return{type:"orderedListRomanLower"}},bo=function(){return{type:"letteredList"}},Bo=function(){return{type:"letteredListLower"}},vo=function(){return{type:"taskList"}},Co=function(e,t,r,i){return i},Po=function(e,t,r,i){let o="bulletList";const n=e.match(/•([0-9]+)([Ii]?) /);let a=1;if(n&&(o="orderedList",n.length>1&&(a=Number(n[1])),n.length>2)){let e=n[2];"I"==e&&(o="orderedListRoman"),"i"==e&&(o="orderedListRomanLower")}"•_ "==e&&(o="noBulletList"),"•A "==e&&(o="letteredList"),"•a "==e&&(o="letteredListLower"),"•+ "!=e&&"•- "!=e||(o="taskList");let s=[{type:"paragraph",attrs:{},content:l((t+r.join("")).trim())}];if(i&&i[0]&&i[0]._tempParsingParent){let e={type:i[0]._tempParsingParent,attrs:{start:a},content:i};if((e.type.startsWith("orderedList")||e.type.startsWith("letteredList"))&&i[0]._tempListStart){const t=i[0]._tempListStart;t>1&&(e.attrs.start=t)}s.push(e)}let p="listItem",u=null;if("taskList"==o){p="taskItem";let t=!1;"•+ "==e&&(t=!0),u={checked:t}}return u?{type:p,attrs:u,content:s,_tempParsingParent:o,_tempListStart:a}:{type:p,content:s,_tempParsingParent:o,_tempListStart:a}},xo=function(e){return e},ko=function(e){return e.join("")===Qa},Ko=function(e){return e.length>Qa.length},wo=function(e){Xa.push(Qa),Qa=e.join("")},_o=function(){return Qa=Xa.pop(),!0},So=function(e){return{type:"paragraph",content:l(e.trim()),attrs:{}}},Ao=function(e){return{type:"paragraph",content:l(e.trim()),attrs:{}}},Lo=function(e){return{type:"paragraph",content:l(e.trim()),attrs:{}}},Io=function(e){return e},Fo=function(e,t,r){const i=Object.assign({},...r);let o=i.alignment||"center";delete i.alignment;let a=i.captionAlign||"left";delete i.captionAlign;let s=i.alt||null;delete i.alt;let l=i.caption||null;delete i.caption;let p=i.align||"center";delete i.align;let u=i.zoomDisabled||Boolean(i.zoomDisabled);return delete i.zoomDisabled,{type:e,attrs:Object.assign({alignment:o,textAlign:a,src:t,alt:n(s),title:n(l),class:p,zoomDisabled:u},i)}},No=function(e){return e},Oo=function(e){return{comment:e}},Eo=function(e,t){return{[e]:parseInt(t)}},Ro=function(e,t){return{type:"error",msg:e+" must be an positive integer.",found:t}},Vo=function(e,t){return{[e]:t}},jo=function(e,t){return{[e]:t}},Mo=function(e){return{[e]:!0}},Do=function(e){return[{type:"paragraph",content:e,attrs:{}}]},Go=function(e,t){return s(e?[e,...t.flat()]:t.flat())},Uo=function(){return{type:"hardBreak"}},$o=function(e){return{text:n(e),type:"text"}},Jo=function(e){return{index:+e,type:"bit"}},Wo=function(e){return{attrs:{formula:n(e)},type:"latex"}},zo=function(e,t,r){return{attrs:Object.assign(Object.assign({alt:e,src:(t.pr+t.t).trim()},Object.assign({},...r)),{zoomDisabled:!0}),type:"imageInline"}},qo=function(e,t){return t||(t=[]),{marks:t,text:n(e),type:"text"}},Ho=function(e){return{marks:[{type:"bold"}],text:n(e),type:"text"}},Yo=function(e){return{marks:[{type:"italic"}],text:n(e),type:"text"}},Xo=function(e){return{marks:[{type:"light"}],text:n(e),type:"text"}},Qo=function(e){return{marks:[{type:"highlight"}],text:n(e),type:"text"}},Zo=function(e){return{marks:[{type:"link",attrs:{href:(e.pr+e.t).trim(),target:"_blank"}}],text:e.t,type:"text"}},en=function(e){return e},tn=function(e){return e},rn=function(e){return{comment:e}},on=function(e,t){return{[e]:parseInt(t)}},nn=function(e,t){return{type:"error",msg:e+" must be an positive integer.",found:t}},an=function(e,t){return{[e]:t}},sn=function(e,t){return{[e]:t}},ln=function(e){return{type:"link",attrs:{href:e.trim(),target:"_blank"}}},pn=function(e,t,r){return{type:"extref",attrs:{extref:e.trim(),references:t,provider:r.trim()}}},un=function(e,t){return{type:"xref",attrs:{xref:e.trim(),reference:t.trim()}}},cn=function(e){return{type:"xref",attrs:{xref:e.trim(),reference:""}}},yn=function(e){return{type:"ref",attrs:{reference:e.trim()}}},gn=function(e,t){const r=Object.assign({},...t);return{type:"symbol",attrs:Object.assign({src:e.trim()},r)}},dn=function(e){return{type:"footnote",attrs:{content:l(e.trim())}}},fn=function(e){return{type:"footnote*",attrs:{content:l(e.trim())}}},mn=function(e){return{type:"var",attrs:{name:e.trim()}}},Tn=function(){return{type:"code",attrs:{language:"plain text"}}},hn=function(e){return{type:"code",attrs:{language:e.trim().toLowerCase()}}},bn=function(){return{type:"timer",attrs:{name:""}}},Bn=function(e){return{type:"timer",attrs:{name:e.trim()}}},vn=function(e){return{type:"duration",attrs:{duration:e}}},Cn=function(e){return{type:"color",attrs:{color:e}}},Pn=function(e){return{type:e}},xn=function(e){return{type:"comment",comment:e}},kn=function(e){return e.trim()},Kn=function(e){return[{type:"paragraph",content:e,attrs:{}}]},wn=function(e,t){return s(e?[e,...t.flat()]:t.flat())},_n=function(){return{type:"hardBreak"}},Sn=function(e){return{text:n(e),type:"text"}},An=function(e){return{index:+e,type:"bit"}},Ln=function(e){return{marks:[{type:"bold"}],text:n(e),type:"text"}},In=function(e){return{marks:[{type:"italic"}],text:n(e),type:"text"}},Fn=function(e){return{marks:[{type:"light"}],text:n(e),type:"text"}},Nn=function(e){return{marks:[{type:"highlight"}],text:n(e),type:"text"}},On=function(e,t){return{pr:e,t}},En=0|t.peg$currPos,Rn=[{line:1,column:1}],Vn=En,jn=t.peg$maxFailExpected||[],Mn=0|t.peg$silentFails;if(t.startRule){if(!(t.startRule in c))throw new Error("Can't start parsing from rule \""+t.startRule+'".');y=c[t.startRule]}function Dn(e,t){return{type:"literal",text:e,ignoreCase:t}}function Gn(e,t,r){return{type:"class",parts:e,inverted:t,ignoreCase:r}}function Un(e){return{type:"other",description:e}}function $n(t){var r,i=Rn[t];if(i)return i;if(t>=Rn.length)r=Rn.length-1;else for(r=t;!Rn[--r];);for(i={line:(i=Rn[r]).line,column:i.column};r<t;)10===e.charCodeAt(r)?(i.line++,i.column=1):i.column++,r++;return Rn[t]=i,i}function Jn(e,t,r){var i=$n(e),o=$n(t),n={source:u,start:{offset:e,line:i.line,column:i.column},end:{offset:t,line:o.line,column:o.column}};return r&&u&&"function"==typeof u.offset&&(n.start=u.offset(n.start),n.end=u.offset(n.end)),n}function Wn(e){En<Vn||(En>Vn&&(Vn=En,jn=[]),jn.push(e))}function zn(e,t,r){return new p(p.buildMessage(e,t),e,t,r)}function qn(){var t,r,o;for(t=En,r=[],e.length>En?(o=e.charAt(En),En++):(o=i,0===Mn&&Wn(Kt));o!==i;)r.push(o),e.length>En?(o=e.charAt(En),En++):(o=i,0===Mn&&Wn(Kt));return t=r=Ji()}function Hn(){var t,r;return t=En,r=function(){var t,r,o,n,a;if(t=En,r=Qn(),r!==i){for(o=En,n=[],a=za();a!==i;)n.push(a),a=za();o=e.substring(o,En),(n=qa())!==i?((a=Wa())===i&&(a=null),t=Qi(r,o)):(En=t,t=i)}else En=t,t=i;return t}(),r!==i&&(r=Wi(r)),(t=r)===i&&(t=En,r=function(){var e,t,r,o;if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=ra(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=go());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=no(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=ia(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=fo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=ao(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=oa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=mo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=so(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=na(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=To());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=lo(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=aa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=ho());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=po(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=sa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=bo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=uo(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i){if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=la(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=Bo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=co(t,r)):(En=e,e=i)}else En=e,e=i;if(e===i)if(e=En,t=function(){var e,t,r;e=En,t=En,Mn++,r=pa(),Mn--,r!==i?(En=t,t=void 0):t=i;t!==i&&(t=vo());return e=t,e}(),t!==i){if(r=[],(o=ca())!==i)for(;o!==i;)r.push(o),o=ca();else r=i;r!==i?((o=Wa())===i&&(o=null),e=yo(t,r)):(En=e,e=i)}else En=e,e=i}}}}}}return e}(),r!==i&&(r=zi(r)),(t=r)===i&&(t=En,(r=ha())!==i&&(r=qi(r)),(t=r)===i&&(t=En,r=function(){var t,r,o;t=En,r=ea(),r!==i?(o=function(){var t,r,o,n;t=En,r=En,o=[],n=ta();for(;n!==i;)o.push(n),n=ta();return r=e.substring(r,En),r=io(r),t=r,t}(),t=eo(r,o)):(En=t,t=i);return t}(),r!==i&&(r=Hi(r)),(t=r)===i&&(t=En,r=function(){var e,t,r;e=En,t=En,Mn++,r=Yn(),Mn--,r===i?t=void 0:(En=t,t=i);t!==i&&(r=da())!==i?e=So(r):(En=e,e=i);e===i&&(e=En,(t=ma())!==i&&(r=da())!==i?e=Ao(r):(En=e,e=i),e===i&&(e=En,(t=ma())!==i?e=Lo(r=""):(En=e,e=i)));return e}(),r!==i&&(r=Yi(r)),t=r)))),t}function Yn(){var e;return(e=Qn())===i&&(e=ua())===i&&(e=ha())===i&&(e=ea())===i&&(e=ma()),e}function Xn(){var t;return 124===e.charCodeAt(En)?(t=g,En++):(t=i,0===Mn&&Wn(_t)),t}function Qn(){var t;return e.substr(En,4)===d?(t=d,En+=4):(t=i,0===Mn&&Wn(St)),t===i&&(e.substr(En,3)===f?(t=f,En+=3):(t=i,0===Mn&&Wn(At)),t===i&&(e.substr(En,2)===m?(t=m,En+=2):(t=i,0===Mn&&Wn(Lt)))),t}function Zn(){var t,r;return t=En,Xn()!==i?(r=function(){var t;return e.substr(En,4)===T?(t=T,En+=4):(t=i,0===Mn&&Wn(It)),t}(),r!==i?t=Zi(r):(En=t,t=i)):(En=t,t=i),t}function ea(){var t,r,o,n,a,s,l;if(t=En,Zn()!==i){for(r=En,o=En,n=[],a=e.charAt(En),Bt.test(a)?En++:(a=i,0===Mn&&Wn(Ft));a!==i;)n.push(a),a=e.charAt(En),Bt.test(a)?En++:(a=i,0===Mn&&Wn(Ft));(a=qa())!==i?o=n=[n,a]:(En=o,o=i),(r=o!==i?e.substring(r,En):o)!==i?t=to():(En=t,t=i)}else En=t,t=i;if(t===i)if(t=En,Zn()!==i)if(58===e.charCodeAt(En)?(r=h,En++):(r=i,0===Mn&&Wn(Nt)),r!==i)if(o=function(){var t,r,o;e.substr(En,9)===b?(t=b,En+=9):(t=i,0===Mn&&Wn(Ot));if(t===i&&(e.substr(En,9)===B?(t=B,En+=9):(t=i,0===Mn&&Wn(Et)),t===i&&(e.substr(En,10)===v?(t=v,En+=10):(t=i,0===Mn&&Wn(Rt)),t===i))){if(t=En,r=[],(o=za())!==i)for(;o!==i;)r.push(o),o=za();else r=i;(t=r!==i?e.substring(t,En):r)===i&&(t="")}return t}(),o!==i){for(n=En,a=En,s=[],l=e.charAt(En),Bt.test(l)?En++:(l=i,0===Mn&&Wn(Ft));l!==i;)s.push(l),l=e.charAt(En),Bt.test(l)?En++:(l=i,0===Mn&&Wn(Ft));(l=qa())!==i?a=s=[s,l]:(En=a,a=i),(n=a!==i?e.substring(n,En):a)!==i?t=ro(o):(En=t,t=i)}else En=t,t=i;else En=t,t=i;else En=t,t=i;return t}function ta(){var t,r,o,n,a,s;if(t=En,r=En,Mn++,o=Yn(),Mn--,o===i?r=void 0:(En=r,r=i),r!==i){if(o=En,n=En,a=[],(s=za())!==i)for(;s!==i;)a.push(s),s=za();else a=i;a!==i&&(s=qa())!==i?n=a=[a,s]:(En=n,n=i),(o=n!==i?e.substring(o,En):n)!==i?t=oo(o):(En=t,t=i)}else En=t,t=i;return t===i&&(t=Wa()),t}function ra(){var t;return e.substr(En,2)===C?(t=C,En+=2):(t=i,0===Mn&&Wn(Vt)),t}function ia(){var t;return e.substr(En,3)===P?(t=P,En+=3):(t=i,0===Mn&&Wn(jt)),t}function oa(){var t,r,o,n,a;if(t=En,r=En,8226===e.charCodeAt(En)?(o=x,En++):(o=i,0===Mn&&Wn(Mt)),o!==i){if(n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;n!==i?(32===e.charCodeAt(En)?(a=k,En++):(a=i,0===Mn&&Wn(Gt)),a!==i?r=o=[o,n,a]:(En=r,r=i)):(En=r,r=i)}else En=r,r=i;return t=r!==i?e.substring(t,En):r}function na(){var t,r,o,n,a;if(t=En,r=En,8226===e.charCodeAt(En)?(o=x,En++):(o=i,0===Mn&&Wn(Mt)),o!==i){if(n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;n!==i?(e.substr(En,2)===K?(a=K,En+=2):(a=i,0===Mn&&Wn(Ut)),a!==i?r=o=[o,n,a]:(En=r,r=i)):(En=r,r=i)}else En=r,r=i;return t=r!==i?e.substring(t,En):r}function aa(){var t,r,o,n,a;if(t=En,r=En,8226===e.charCodeAt(En)?(o=x,En++):(o=i,0===Mn&&Wn(Mt)),o!==i){if(n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;n!==i?(e.substr(En,2)===w?(a=w,En+=2):(a=i,0===Mn&&Wn($t)),a!==i?r=o=[o,n,a]:(En=r,r=i)):(En=r,r=i)}else En=r,r=i;return t=r!==i?e.substring(t,En):r}function sa(){var t;return e.substr(En,3)===_?(t=_,En+=3):(t=i,0===Mn&&Wn(Jt)),t}function la(){var t;return e.substr(En,3)===S?(t=S,En+=3):(t=i,0===Mn&&Wn(Wt)),t}function pa(){var t;return e.substr(En,3)===A?(t=A,En+=3):(t=i,0===Mn&&Wn(zt)),t===i&&(e.substr(En,3)===L?(t=L,En+=3):(t=i,0===Mn&&Wn(qt))),t}function ua(){var e;return(e=ra())===i&&(e=ia())===i&&(e=oa())===i&&(e=na())===i&&(e=aa())===i&&(e=sa())===i&&(e=la())===i&&(e=pa()),e}function ca(){var t,r,o,n,a,s,l,p;if(t=En,ga()!==i)if((r=ua())!==i){for(o=En,n=En,a=[],s=En,l=En,Mn++,p=Wa(),Mn--,p===i?l=void 0:(En=l,l=i),l!==i?(e.length>En?(p=e.charAt(En),En++):(p=i,0===Mn&&Wn(Kt)),p!==i?s=l=[l,p]:(En=s,s=i)):(En=s,s=i);s!==i;)a.push(s),s=En,l=En,Mn++,p=Wa(),Mn--,p===i?l=void 0:(En=l,l=i),l!==i?(e.length>En?(p=e.charAt(En),En++):(p=i,0===Mn&&Wn(Kt)),p!==i?s=l=[l,p]:(En=s,s=i)):(En=s,s=i);for((s=Wa())===i&&(s=null),n=a=[a,s],o=e.substring(o,En),n=[],a=ya();a!==i;)n.push(a),a=ya();if(a=En,s=function(){var t,r,o,n;t=En,Mn++,r=En,o=[],9===e.charCodeAt(En)?(n=I,En++):(n=i,0===Mn&&Wn(Ht));if(n!==i)for(;n!==i;)o.push(n),9===e.charCodeAt(En)?(n=I,En++):(n=i,0===Mn&&Wn(Ht));else o=i;o!==i?(n=(n=Ko(o))?void 0:i)!==i?r=wo(o):(En=r,r=i):(En=r,r=i);Mn--,r!==i?(En=t,t=void 0):t=i;return t}(),s!==i){for(l=[],p=ca();p!==i;)l.push(p),p=ca();p=function(){var e;e=_o(),e=e?void 0:i;return e}(),p!==i?a=Co(r,o,n,l):(En=a,a=i)}else En=a,a=i;a===i&&(a=null),t=Po(r,o,n,a)}else En=t,t=i;else En=t,t=i;return t}function ya(){var t,r,o,n,a,s,l,p,u,c;if(t=En,r=En,Mn++,o=function(){var t,r,o;t=En,r=[],o=e.charAt(En),Bt.test(o)?En++:(o=i,0===Mn&&Wn(Ft));for(;o!==i;)r.push(o),o=e.charAt(En),Bt.test(o)?En++:(o=i,0===Mn&&Wn(Ft));o=Wa(),o!==i?t=r=[r,o]:(En=t,t=i);return t}(),Mn--,o===i?r=void 0:(En=r,r=i),r!==i)if((o=ga())!==i)if(n=En,Mn++,a=ua(),Mn--,a===i?n=void 0:(En=n,n=i),n!==i){if(a=En,s=En,l=[],p=En,u=En,Mn++,c=Wa(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(e.length>En?(c=e.charAt(En),En++):(c=i,0===Mn&&Wn(Kt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i),p!==i)for(;p!==i;)l.push(p),p=En,u=En,Mn++,c=Wa(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(e.length>En?(c=e.charAt(En),En++):(c=i,0===Mn&&Wn(Kt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i);else l=i;l!==i&&(p=qa())!==i?s=l=[l,p]:(En=s,s=i),(a=s!==i?e.substring(a,En):s)!==i?t=xo(a):(En=t,t=i)}else En=t,t=i;else En=t,t=i;else En=t,t=i;return t}function ga(){var t,r,o;for(t=En,r=[],9===e.charCodeAt(En)?(o=I,En++):(o=i,0===Mn&&Wn(Ht));o!==i;)r.push(o),9===e.charCodeAt(En)?(o=I,En++):(o=i,0===Mn&&Wn(Ht));return(o=(o=ko(r))?void 0:i)!==i?t=r=[r,o]:(En=t,t=i),t}function da(){var t,r,o;if(t=En,r=[],(o=fa())!==i)for(;o!==i;)r.push(o),o=fa();else r=i;return t=r!==i?e.substring(t,En):r}function fa(){var t,r,o,n,a,s;if(t=En,r=En,Mn++,o=Yn(),Mn--,o===i?r=void 0:(En=r,r=i),r!==i){if(o=En,n=En,a=[],(s=za())!==i)for(;s!==i;)a.push(s),s=za();else a=i;a!==i&&(s=qa())!==i?n=a=[a,s]:(En=n,n=i),(o=n!==i?e.substring(o,En):n)!==i?t=r=[r,o]:(En=t,t=i)}else En=t,t=i;return t===i&&(t=Wa()),t}function ma(){var t,r,o,n,a,s;if(t=En,(r=Xn())!==i){for(o=En,n=En,a=[],s=e.charAt(En),Bt.test(s)?En++:(s=i,0===Mn&&Wn(Ft));s!==i;)a.push(s),s=e.charAt(En),Bt.test(s)?En++:(s=i,0===Mn&&Wn(Ft));(s=qa())!==i?n=a=[a,s]:(En=n,n=i),(o=n!==i?e.substring(o,En):n)!==i?((n=Wa())===i&&(n=null),t=r=[r,o,n]):(En=t,t=i)}else En=t,t=i;return t}function Ta(){var t,r;return t=En,Xn()!==i?(r=function(){var t;return e.substr(En,5)===F?(t=F,En+=5):(t=i,0===Mn&&Wn(Yt)),t}(),r!==i?t=Io(r):(En=t,t=i)):(En=t,t=i),t}function ha(){var t,r,o,n,a,s,l,p,u,c;if(t=En,(r=Ta())!==i)if(58===e.charCodeAt(En)?(o=h,En++):(o=i,0===Mn&&Wn(Nt)),o!==i)if(32===e.charCodeAt(En)?(n=k,En++):(n=i,0===Mn&&Wn(Gt)),n===i&&(n=null),a=function(){var t,r,o,n,a,s,l,p,u;t=En,r=En,e.substr(En,4)===mt?(o=mt,En+=4):(o=i,0===Mn&&Wn(Mi));if(o!==i)if(115===e.charCodeAt(En)?(n=Tt,En++):(n=i,0===Mn&&Wn(Di)),n===i&&(n=null),e.substr(En,3)===ht?(a=ht,En+=3):(a=i,0===Mn&&Wn(Gi)),a!==i){for(s=[],l=En,p=En,Mn++,u=Xn(),Mn--,u===i?p=void 0:(En=p,p=i),p!==i&&(u=Ya())!==i?l=p=[p,u]:(En=l,l=i);l!==i;)s.push(l),l=En,p=En,Mn++,u=Xn(),Mn--,u===i?p=void 0:(En=p,p=i),p!==i&&(u=Ya())!==i?l=p=[p,u]:(En=l,l=i);r=o=[o,n,a,s]}else En=r,r=i;else En=r,r=i;t=r!==i?e.substring(t,En):r;return t}(),a!==i)if(Xn()!==i){for(s=ba(),l=En,p=En,u=[],c=e.charAt(En),Bt.test(c)?En++:(c=i,0===Mn&&Wn(Ft));c!==i;)u.push(c),c=e.charAt(En),Bt.test(c)?En++:(c=i,0===Mn&&Wn(Ft));(c=qa())!==i?p=u=[u,c]:(En=p,p=i),(l=p!==i?e.substring(l,En):p)!==i?((p=Wa())===i&&(p=null),t=Fo(r,a,s)):(En=t,t=i)}else En=t,t=i;else En=t,t=i;else En=t,t=i;else En=t,t=i;return t}function ba(){var e,t,r;for(e=En,t=[],r=Ba();r!==i;)t.push(r),r=Ba();return e=t=No(t)}function Ba(){var t,r,o,n,a,s,l,p,u,c;if(t=En,35===e.charCodeAt(En)?(r=N,En++):(r=i,0===Mn&&Wn(Xt)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=Oo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));if(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i),p!==i)for(;p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i);else l=i;(s=l!==i?e.substring(s,En):l)!==i&&(l=Xn())!==i?t=Eo(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=Ro(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=Ca())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s=function(){var t;e.substr(En,4)===M?(t=M,En+=4):(t=i,0===Mn&&Wn(or));t===i&&(e.substr(En,6)===D?(t=D,En+=6):(t=i,0===Mn&&Wn(nr)),t===i&&(e.substr(En,5)===G?(t=G,En+=5):(t=i,0===Mn&&Wn(ar))));return t}(),s!==i&&(l=Xn())!==i?t=Vo(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){for(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),o=En,n=[],a=En,s=En,Mn++,l=e.charAt(En),Ct.test(l)?En++:(l=i,0===Mn&&Wn(Zt)),l===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=e.charAt(En),Ct.test(l)?En++:(l=i,0===Mn&&Wn(Zt)),l===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);if(o=e.substring(o,En),58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(32===e.charCodeAt(En)?(a=k,En++):(a=i,0===Mn&&Wn(Gt)),a===i&&(a=null),s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=jo(o,s):(En=t,t=i)}else En=t,t=i;if(t===i){for(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),o=En,n=[],a=En,s=En,Mn++,(l=Xn())===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,(l=Xn())===i&&(l=En,(p=Ca())!==i?(58===e.charCodeAt(En)?(u=h,En++):(u=i,0===Mn&&Wn(Nt)),u!==i?l=p=[p,u]:(En=l,l=i)):(En=l,l=i)),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=Mo(o):(En=t,t=i)}}}}}return t}function va(){var t;return e.substr(En,5)===E?(t=E,En+=5):(t=i,0===Mn&&Wn(er)),t===i&&(e.substr(En,6)===R?(t=R,En+=6):(t=i,0===Mn&&Wn(tr))),t}function Ca(){var t;return e.substr(En,9)===V?(t=V,En+=9):(t=i,0===Mn&&Wn(rr)),t===i&&(e.substr(En,12)===j?(t=j,En+=12):(t=i,0===Mn&&Wn(ir))),t}function Pa(){var e,t,r,o;for(e=En,(t=xa())===i&&(t=null),r=[],(o=wa())===i&&(o=xa());o!==i;)r.push(o),(o=wa())===i&&(o=xa());return e=Go(t,r)}function xa(){var t,r,o,n,a,s,l;if(t=En,(r=Wa())!==i&&(r=Uo()),(t=r)===i){if(t=En,r=En,o=[],n=En,(a=_a())===i&&(a=null),s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=_a())!==i?(s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i)),n!==i)for(;n!==i;)o.push(n),n=En,(a=_a())===i&&(a=null),s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=_a())!==i?(s=En,Mn++,l=wa(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i));else o=i;(r=o!==i?e.substring(r,En):o)!==i&&(r=$o(r)),t=r}return t}function ka(){var t;return 61===e.charCodeAt(En)?(t=U,En++):(t=i,0===Mn&&Wn(lr)),t}function Ka(){var e,t,r;return e=En,(t=ka())!==i&&(r=ka())!==i?e=t=[t,r]:(En=e,e=i),e}function wa(){var t,r,o,n,a,s,l,p;if(t=En,(r=Ga())!==i){if(o=En,n=[],a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt)),a!==i)for(;a!==i;)n.push(a),a=e.charAt(En),vt.test(a)?En++:(a=i,0===Mn&&Wn(Dt));else n=i;(o=n!==i?e.substring(o,En):n)!==i&&(n=Ua())!==i?t=Jo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ka())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ka())!==i?(e.substr(En,7)===$?(a=$,En+=7):(a=i,0===Mn&&Wn(pr)),a!==i?t=Wo(o):(En=t,t=i)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ka())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ka())!==i?(e.substr(En,13)===J?(a=J,En+=13):(a=i,0===Mn&&Wn(ur)),a!==i&&(s=Ha())!==i?(124===e.charCodeAt(En)?(l=g,En++):(l=i,0===Mn&&Wn(_t)),l!==i?(p=function(){var e,t,r;e=En,t=[],r=Sa();for(;r!==i;)t.push(r),r=Sa();return t=tn(t),e=t,e}(),t=zo(o,s,p)):(En=t,t=i)):(En=t,t=i)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ka())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ka(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ka())!==i?(a=function(){var t,r,o,n;t=En,124===e.charCodeAt(En)?(r=g,En++):(r=i,0===Mn&&Wn(_t));if(r!==i){if(o=[],(n=Aa())!==i)for(;n!==i;)o.push(n),n=Aa();else o=i;o!==i?t=en(o):(En=t,t=i)}else En=t,t=i;return t}(),a!==i?t=qo(o,a):(En=t,t=i)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Va())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Va(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Va(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Va())!==i?t=Ho(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=ja())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=ja(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=ja(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=ja())!==i?t=Yo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Ma())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Ma(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Ma(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Ma())!==i?t=Xo(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,(r=Da())!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Da(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Da(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?(e.length>En?(l=e.charAt(En),En++):(l=i,0===Mn&&Wn(Kt)),l!==i?a=s=[s,l]:(En=a,a=i)):(En=a,a=i);o=e.substring(o,En),(n=Da())!==i?t=Qo(o):(En=t,t=i)}else En=t,t=i;t===i&&(t=En,(r=Ha())!==i&&(r=Zo(r)),t=r)}}}}}}}return t}function _a(){var t,r,o,n,a;if(t=En,r=En,(o=Ka())!==i){if(n=[],(a=ka())!==i)for(;a!==i;)n.push(a),a=ka();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;if((t=r!==i?e.substring(t,En):r)===i){if(t=En,r=En,(o=Ma())!==i){if(n=[],(a=Ea())!==i)for(;a!==i;)n.push(a),a=Ea();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;if((t=r!==i?e.substring(t,En):r)===i){if(t=En,r=En,(o=Da())!==i){if(n=[],(a=Ra())!==i)for(;a!==i;)n.push(a),a=Ra();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;t=r!==i?e.substring(t,En):r}}return t}function Sa(){var t,r,o,n,a,s,l,p,u,c;if(t=En,35===e.charCodeAt(En)?(r=N,En++):(r=i,0===Mn&&Wn(Xt)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=rn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));if(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i),p!==i)for(;p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i?(c=e.charAt(En),vt.test(c)?En++:(c=i,0===Mn&&Wn(Dt)),c!==i?p=u=[u,c]:(En=p,p=i)):(En=p,p=i);else l=i;(s=l!==i?e.substring(s,En):l)!==i&&(l=Xn())!==i?t=on(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),(o=va())!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=nn(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i){if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),e.substr(En,17)===W?(o=W,En+=17):(o=i,0===Mn&&Wn(cr)),o!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s=function(){var t;e.substr(En,3)===q?(t=q,En+=3):(t=i,0===Mn&&Wn(gr));t===i&&(e.substr(En,6)===H?(t=H,En+=6):(t=i,0===Mn&&Wn(dr)),t===i&&(e.substr(En,6)===Y?(t=Y,En+=6):(t=i,0===Mn&&Wn(fr)),t===i&&(e.substr(En,8)===X?(t=X,En+=8):(t=i,0===Mn&&Wn(mr)),t===i&&(e.substr(En,3)===Q?(t=Q,En+=3):(t=i,0===Mn&&Wn(Tr)),t===i&&(e.substr(En,5)===Z?(t=Z,En+=5):(t=i,0===Mn&&Wn(hr)),t===i&&(e.substr(En,11)===ee?(t=ee,En+=11):(t=i,0===Mn&&Wn(br)),t===i&&(e.substr(En,8)===te?(t=te,En+=8):(t=i,0===Mn&&Wn(Br)))))))));return t}(),s!==i&&(l=Xn())!==i?t=an(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i;if(t===i)if(t=En,64===e.charCodeAt(En)?(r=O,En++):(r=i,0===Mn&&Wn(Qt)),r===i&&(r=null),e.substr(En,4)===z?(o=z,En+=4):(o=i,0===Mn&&Wn(yr)),o!==i)if(58===e.charCodeAt(En)?(n=h,En++):(n=i,0===Mn&&Wn(Nt)),n!==i){for(a=[],32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s!==i;)a.push(s),32===e.charCodeAt(En)?(s=k,En++):(s=i,0===Mn&&Wn(Gt));s=function(){var t;e.substr(En,11)===re?(t=re,En+=11):(t=i,0===Mn&&Wn(vr));t===i&&(e.substr(En,11)===ie?(t=ie,En+=11):(t=i,0===Mn&&Wn(Cr)),t===i&&(e.substr(En,5)===Z?(t=Z,En+=5):(t=i,0===Mn&&Wn(hr)),t===i&&(e.substr(En,3)===Q?(t=Q,En+=3):(t=i,0===Mn&&Wn(Tr)),t===i&&(e.substr(En,8)===oe?(t=oe,En+=8):(t=i,0===Mn&&Wn(Pr))))));return t}(),s!==i&&(l=Xn())!==i?t=sn(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i}}}return t}function Aa(){var t,r,o,n,a,s,l,p,u,c,y;if(t=En,e.substr(En,5)===ne?(r=ne,En+=5):(r=i,0===Mn&&Wn(xr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=ln(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,7)===ae?(r=ae,En+=7):(r=i,0===Mn&&Wn(kr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);if(o=e.substring(o,En),n=function(){var e,t;e=[],t=La();for(;t!==i;)e.push(t),t=La();return e}(),(a=Xn())!==i)if(e.substr(En,9)===se?(s=se,En+=9):(s=i,0===Mn&&Wn(Kr)),s!==i){for(l=En,p=[],u=En,c=En,Mn++,y=Xn(),Mn--,y===i?c=void 0:(En=c,c=i),c!==i&&(y=za())!==i?u=c=[c,y]:(En=u,u=i);u!==i;)p.push(u),u=En,c=En,Mn++,y=Xn(),Mn--,y===i?c=void 0:(En=c,c=i),c!==i&&(y=za())!==i?u=c=[c,y]:(En=u,u=i);l=e.substring(l,En),(p=Xn())!==i?t=pn(o,n,l):(En=t,t=i)}else En=t,t=i;else En=t,t=i}else En=t,t=i;if(t===i){if(t=En,e.substr(En,5)===le?(r=le,En+=5):(r=i,0===Mn&&Wn(wr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);if(o=e.substring(o,En),(n=Xn())!==i)if(9658===e.charCodeAt(En)?(a=pe,En++):(a=i,0===Mn&&Wn(_r)),a!==i){for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);s=e.substring(s,En),(l=Xn())!==i?t=un(o,s):(En=t,t=i)}else En=t,t=i;else En=t,t=i}else En=t,t=i;if(t===i){if(t=En,e.substr(En,5)===le?(r=le,En+=5):(r=i,0===Mn&&Wn(wr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=cn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,9658===e.charCodeAt(En)?(r=pe,En++):(r=i,0===Mn&&Wn(_r)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=yn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,7)===ue?(r=ue,En+=7):(r=i,0===Mn&&Wn(Sr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?(a=ba(),t=gn(o,a)):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,9)===ce?(r=ce,En+=9):(r=i,0===Mn&&Wn(Ar)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=dn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,10)===ye?(r=ye,En+=10):(r=i,0===Mn&&Wn(Lr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=fn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,4)===ge?(r=ge,En+=4):(r=i,0===Mn&&Wn(Ir)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=mn(o):(En=t,t=i)}else En=t,t=i;if(t===i&&(t=En,e.substr(En,4)===T?(r=T,En+=4):(r=i,0===Mn&&Wn(It)),r!==i&&(o=Xn())!==i?t=Tn():(En=t,t=i),t===i)){if(t=En,e.substr(En,5)===de?(r=de,En+=5):(r=i,0===Mn&&Wn(Fr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=hn(o):(En=t,t=i)}else En=t,t=i;if(t===i&&(t=En,e.substr(En,5)===fe?(r=fe,En+=5):(r=i,0===Mn&&Wn(Nr)),r!==i&&(o=Xn())!==i?t=bn():(En=t,t=i),t===i)){if(t=En,e.substr(En,6)===me?(r=me,En+=6):(r=i,0===Mn&&Wn(Or)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=Bn(o):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,e.substr(En,9)===Te?(r=Te,En+=9):(r=i,0===Mn&&Wn(Er)),r!==i){if(o=En,n=En,80===e.charCodeAt(En)?(a=he,En++):(a=i,0===Mn&&Wn(Rr)),a!==i){for(s=En,l=[],p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);p!==i;)l.push(p),p=En,u=En,Mn++,c=Xn(),Mn--,c===i?u=void 0:(En=u,u=i),u!==i&&(c=za())!==i?p=u=[u,c]:(En=p,p=i);n=a=[a,s=e.substring(s,En)]}else En=n,n=i;(o=n!==i?e.substring(o,En):n)!==i&&(n=Xn())!==i?t=vn(o):(En=t,t=i)}else En=t,t=i;if(t===i&&(t=En,e.substr(En,6)===be?(r=be,En+=6):(r=i,0===Mn&&Wn(Vr)),r!==i?(o=function(){var t;e.substr(En,4)===Me?(t=Me,En+=4):(t=i,0===Mn&&Wn(ni));t===i&&(e.substr(En,5)===De?(t=De,En+=5):(t=i,0===Mn&&Wn(ai)),t===i&&(e.substr(En,4)===Ge?(t=Ge,En+=4):(t=i,0===Mn&&Wn(si)),t===i&&(e.substr(En,4)===Ue?(t=Ue,En+=4):(t=i,0===Mn&&Wn(li)),t===i&&(e.substr(En,7)===$e?(t=$e,En+=7):(t=i,0===Mn&&Wn(pi)),t===i&&(e.substr(En,9)===Je?(t=Je,En+=9):(t=i,0===Mn&&Wn(ui)),t===i&&(e.substr(En,4)===We?(t=We,En+=4):(t=i,0===Mn&&Wn(ci)),t===i&&(e.substr(En,8)===ze?(t=ze,En+=8):(t=i,0===Mn&&Wn(yi)),t===i&&(e.substr(En,5)===qe?(t=qe,En+=5):(t=i,0===Mn&&Wn(gi)),t===i&&(e.substr(En,4)===He?(t=He,En+=4):(t=i,0===Mn&&Wn(di)),t===i&&(e.substr(En,7)===Ye?(t=Ye,En+=7):(t=i,0===Mn&&Wn(fi)),t===i&&(e.substr(En,6)===Xe?(t=Xe,En+=6):(t=i,0===Mn&&Wn(mi)),t===i&&(e.substr(En,4)===Qe?(t=Qe,En+=4):(t=i,0===Mn&&Wn(Ti)),t===i&&(e.substr(En,5)===Ze?(t=Ze,En+=5):(t=i,0===Mn&&Wn(hi)),t===i&&(e.substr(En,6)===et?(t=et,En+=6):(t=i,0===Mn&&Wn(bi)),t===i&&(e.substr(En,6)===tt?(t=tt,En+=6):(t=i,0===Mn&&Wn(Bi)),t===i&&(e.substr(En,3)===rt?(t=rt,En+=3):(t=i,0===Mn&&Wn(vi)),t===i&&(e.substr(En,6)===it?(t=it,En+=6):(t=i,0===Mn&&Wn(Ci)),t===i&&(e.substr(En,4)===ot?(t=ot,En+=4):(t=i,0===Mn&&Wn(Pi)),t===i&&(e.substr(En,6)===nt?(t=nt,En+=6):(t=i,0===Mn&&Wn(xi)),t===i&&(e.substr(En,5)===at?(t=at,En+=5):(t=i,0===Mn&&Wn(ki)),t===i&&(e.substr(En,6)===st?(t=st,En+=6):(t=i,0===Mn&&Wn(Ki)))))))))))))))))))))));return t}(),o!==i&&(n=Xn())!==i?t=Cn(o):(En=t,t=i)):(En=t,t=i),t===i&&(t=En,r=function(){var t;e.substr(En,4)===ve?(t=ve,En+=4):(t=i,0===Mn&&Wn(Mr));t===i&&(e.substr(En,6)===Ce?(t=Ce,En+=6):(t=i,0===Mn&&Wn(Dr)),t===i&&(e.substr(En,5)===Pe?(t=Pe,En+=5):(t=i,0===Mn&&Wn(Gr)),t===i&&(e.substr(En,9)===xe?(t=xe,En+=9):(t=i,0===Mn&&Wn(Ur)),t===i&&(e.substr(En,6)===ke?(t=ke,En+=6):(t=i,0===Mn&&Wn($r)),t===i&&(e.substr(En,9)===Ke?(t=Ke,En+=9):(t=i,0===Mn&&Wn(Jr)),t===i&&(e.substr(En,11)===we?(t=we,En+=11):(t=i,0===Mn&&Wn(Wr)),t===i&&(e.substr(En,3)===_e?(t=_e,En+=3):(t=i,0===Mn&&Wn(zr)),t===i&&(e.substr(En,3)===Se?(t=Se,En+=3):(t=i,0===Mn&&Wn(qr)),t===i&&(e.substr(En,9)===Ae?(t=Ae,En+=9):(t=i,0===Mn&&Wn(Hr)),t===i&&(e.substr(En,15)===Le?(t=Le,En+=15):(t=i,0===Mn&&Wn(Yr)),t===i&&(e.substr(En,6)===Ie?(t=Ie,En+=6):(t=i,0===Mn&&Wn(Xr)),t===i&&(e.substr(En,10)===Fe?(t=Fe,En+=10):(t=i,0===Mn&&Wn(Qr)),t===i&&(e.substr(En,13)===Ne?(t=Ne,En+=13):(t=i,0===Mn&&Wn(Zr)),t===i&&(e.substr(En,19)===Oe?(t=Oe,En+=19):(t=i,0===Mn&&Wn(ei)),t===i&&(e.substr(En,10)===Ee?(t=Ee,En+=10):(t=i,0===Mn&&Wn(ti)),t===i&&(e.substr(En,10)===Re?(t=Re,En+=10):(t=i,0===Mn&&Wn(ri)),t===i&&(e.substr(En,13)===Ve?(t=Ve,En+=13):(t=i,0===Mn&&Wn(ii)),t===i&&(e.substr(En,11)===je?(t=je,En+=11):(t=i,0===Mn&&Wn(oi))))))))))))))))))));return t}(),r!==i&&(o=Xn())!==i?t=Pn(r):(En=t,t=i),t===i)))if(t=En,35===e.charCodeAt(En)?(r=N,En++):(r=i,0===Mn&&Wn(Xt)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),(n=Xn())!==i?t=xn(o):(En=t,t=i)}else En=t,t=i}}}}}}}}}}}return t}function La(){var t,r,o,n,a,s,l;if(t=En,e.substr(En,2)===Be?(r=Be,En+=2):(r=i,0===Mn&&Wn(jr)),r!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),t=kn(o)}else En=t,t=i;return t}function Ia(){var e,t,r,o;for(Mn++,e=En,(t=Fa())===i&&(t=null),r=[],(o=$a())===i&&(o=Fa());o!==i;)r.push(o),(o=$a())===i&&(o=Fa());return e=wn(t,r),Mn--,t=i,0===Mn&&Wn(_i),e}function Fa(){var t,r,o,n,a,s,l;if(t=En,(r=Wa())!==i&&(r=_n()),(t=r)===i){if(t=En,r=En,o=[],n=En,(a=Ja())===i&&(a=null),s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=Ja())!==i?(s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i)),n!==i)for(;n!==i;)o.push(n),n=En,(a=Ja())===i&&(a=null),s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=za())!==i?n=a=[a,s,l]:(En=n,n=i),n===i&&(n=En,(a=Ja())!==i?(s=En,Mn++,l=$a(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i));else o=i;(r=o!==i?e.substring(r,En):o)!==i&&(r=Sn(r)),t=r}return t}function Na(){var t;return 42===e.charCodeAt(En)?(t=lt,En++):(t=i,0===Mn&&Wn(Si)),t}function Oa(){var t;return 95===e.charCodeAt(En)?(t=pt,En++):(t=i,0===Mn&&Wn(Ai)),t}function Ea(){var t;return 96===e.charCodeAt(En)?(t=ut,En++):(t=i,0===Mn&&Wn(Li)),t}function Ra(){var t;return 33===e.charCodeAt(En)?(t=ct,En++):(t=i,0===Mn&&Wn(Ii)),t}function Va(){var e,t,r;return e=En,(t=Na())!==i&&(r=Na())!==i?e=t=[t,r]:(En=e,e=i),e}function ja(){var e,t,r;return e=En,(t=Oa())!==i&&(r=Oa())!==i?e=t=[t,r]:(En=e,e=i),e}function Ma(){var e,t,r;return e=En,(t=Ea())!==i&&(r=Ea())!==i?e=t=[t,r]:(En=e,e=i),e}function Da(){var e,t,r;return e=En,(t=Ra())!==i&&(r=Ra())!==i?e=t=[t,r]:(En=e,e=i),e}function Ga(){var t;return e.substr(En,2)===yt?(t=yt,En+=2):(t=i,0===Mn&&Wn(Fi)),t}function Ua(){var t;return 93===e.charCodeAt(En)?(t=gt,En++):(t=i,0===Mn&&Wn(Ni)),t}function $a(){var t,r,o,n,a,s;if(t=En,Ga()!==i){if(r=En,o=[],n=e.charAt(En),vt.test(n)?En++:(n=i,0===Mn&&Wn(Dt)),n!==i)for(;n!==i;)o.push(n),n=e.charAt(En),vt.test(n)?En++:(n=i,0===Mn&&Wn(Dt));else o=i;(r=o!==i?e.substring(r,En):o)!==i&&(o=Ua())!==i?t=An(r):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,Va()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=Va(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=Va(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=Va())!==i?t=Ln(r):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,ja()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=ja(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=ja(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=ja())!==i?t=In(r):(En=t,t=i)}else En=t,t=i;if(t===i){if(t=En,Ma()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=Ma(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=Ma(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=Ma())!==i?t=Fn(r):(En=t,t=i)}else En=t,t=i;if(t===i)if(t=En,Da()!==i){for(r=En,o=[],n=En,a=En,Mn++,s=Da(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);n!==i;)o.push(n),n=En,a=En,Mn++,s=Da(),Mn--,s===i?a=void 0:(En=a,a=i),a!==i?(e.length>En?(s=e.charAt(En),En++):(s=i,0===Mn&&Wn(Kt)),s!==i?n=a=[a,s]:(En=n,n=i)):(En=n,n=i);r=e.substring(r,En),(o=Da())!==i?t=Nn(r):(En=t,t=i)}else En=t,t=i}}}return t}function Ja(){var t,r,o,n,a;if(t=En,r=En,(o=Ma())!==i){if(n=[],(a=Ea())!==i)for(;a!==i;)n.push(a),a=Ea();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;if((t=r!==i?e.substring(t,En):r)===i){if(t=En,r=En,(o=Da())!==i){if(n=[],(a=Ra())!==i)for(;a!==i;)n.push(a),a=Ra();else n=i;n!==i?r=o=[o,n]:(En=r,r=i)}else En=r,r=i;t=r!==i?e.substring(t,En):r}return t}function Wa(){var t;return Mn++,10===e.charCodeAt(En)?(t=dt,En++):(t=i,0===Mn&&Wn(Ei)),t===i&&(e.substr(En,2)===ft?(t=ft,En+=2):(t=i,0===Mn&&Wn(Ri)),t===i&&(t=e.charAt(En),Pt.test(t)?En++:(t=i,0===Mn&&Wn(Vi)))),Mn--,t===i&&(0===Mn&&Wn(Oi)),t}function za(){var t;return t=e.charAt(En),xt.test(t)?En++:(t=i,0===Mn&&Wn(ji)),t}function qa(){var t,r;return(t=Wa())===i&&(t=En,Mn++,e.length>En?(r=e.charAt(En),En++):(r=i,0===Mn&&Wn(Kt)),Mn--,r===i?t=void 0:(En=t,t=i)),t}function Ha(){var t,r,o,n,a,s,l;if(t=En,r=En,o=En,e.substr(En,4)===mt?(n=mt,En+=4):(n=i,0===Mn&&Wn(Mi)),n!==i?(115===e.charCodeAt(En)?(a=Tt,En++):(a=i,0===Mn&&Wn(Di)),a===i&&(a=null),e.substr(En,3)===ht?(s=ht,En+=3):(s=i,0===Mn&&Wn(Gi)),s!==i?o=n=[n,a,s]:(En=o,o=i)):(En=o,o=i),o===i&&(e.substr(En,7)===bt?(o=bt,En+=7):(o=i,0===Mn&&Wn(Ui))),(r=o!==i?e.substring(r,En):o)!==i){for(o=En,n=[],a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=Ya())!==i?a=s=[s,l]:(En=a,a=i);a!==i;)n.push(a),a=En,s=En,Mn++,l=Xn(),Mn--,l===i?s=void 0:(En=s,s=i),s!==i&&(l=Ya())!==i?a=s=[s,l]:(En=a,a=i);o=e.substring(o,En),t=On(r,o)}else En=t,t=i;return t}function Ya(){var t;return t=e.charAt(En),kt.test(t)?En++:(t=i,0===Mn&&Wn($i)),t}var Xa=[],Qa="";if(e=e.trimStart(),r=y(),t.peg$library)return{peg$result:r,peg$currPos:En,peg$FAILED:i,peg$maxFailExpected:jn,peg$maxFailPos:Vn};if(r!==i&&En===e.length)return r;throw r!==i&&En<e.length&&Wn({type:"end"}),zn(jn,Vn<e.length?e.charAt(Vn):null,Vn<e.length?Jn(Vn,Vn+1):Jn(Vn,Vn))}!function(e,t){function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r}(p,Error),p.prototype.format=function(e){var t="Error: "+this.message;if(this.location){var r,i=null;for(r=0;r<e.length;r++)if(e[r].source===this.location.source){i=e[r].text.split(/\r\n|\n|\r/g);break}var o=this.location.start,n=this.location.source&&"function"==typeof this.location.source.offset?this.location.source.offset(o):o,a=this.location.source+":"+n.line+":"+n.column;if(i){var s=this.location.end,l=u("",n.line.toString().length," "),p=i[o.line-1],c=(o.line===s.line?s.column:p.length+1)-o.column||1;t+="\n --\x3e "+a+"\n"+l+" |\n"+n.line+" | "+p+"\n"+l+" | "+u("",o.column-1," ")+u("",c,"^")}else t+="\n at "+a}return t},p.buildMessage=function(e,t){var r={literal:function(e){return'"'+o(e.text)+'"'},class:function(e){var t=e.parts.map((function(e){return Array.isArray(e)?n(e[0])+"-"+n(e[1]):n(e)}));return"["+(e.inverted?"^":"")+t.join("")+"]"},any:function(){return"any character"},end:function(){return"end of input"},other:function(e){return e.description}};function i(e){return e.charCodeAt(0).toString(16).toUpperCase()}function o(e){return e.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function n(e){return e.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(e){return"\\x0"+i(e)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(e){return"\\x"+i(e)}))}function a(e){return r[e.type](e)}return"Expected "+function(e){var t,r,i=e.map(a);if(i.sort(),i.length>0){for(t=1,r=1;t<i.length;t++)i[t-1]!==i[t]&&(i[r]=i[t],r++);i.length=r}switch(i.length){case 1:return i[0];case 2:return i[0]+" or "+i[1];default:return i.slice(0,-1).join(", ")+", or "+i[i.length-1]}}(e)+" but "+function(e){return e?'"'+o(e)+'"':"end of input"}(t)+" found."};t.StartRules=["version","bitmarkPlusPlus","bitmarkPlus","bitmarkMinusMinus","bitmarkPlusString","bitmarkMinusMinusString"]},8588:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitmarkParserType=void 0;const i=(0,r(4718).superenum)({peggy:"peggy"});t.BitmarkParserType=i},8848:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.imageSourceChainContentProcessor=function(e,t,r,c,y){t===u.BitContentLevel.Chain?function(e,t,r,i,n){const{value:a}=i,u=o.Breakscape.unbreakscape(p.StringUtils.trimmedString(a),{textFormat:s.TextFormat.bitmarkMinusMinus,textLocation:l.TextLocation.tag});n.imageSourceUrl=u}(0,0,0,c,y):function(e,t,r,o,s){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("imageSource content",o);const{key:l}=o,p=n.Config.getTagConfigForTag(r,a.PropertyTag.fromValue(l)),c=e.bitContentProcessor(u.BitContentLevel.Chain,r,[o]),y=e.bitContentProcessor(u.BitContentLevel.Chain,null==p?void 0:p.chain,o.chain);e.DEBUG_CHAIN_TAGS&&e.debugPrint("imageSource TAGS",y);const{imageSourceUrl:g}=c,{mockupId:d}=y,f=i(y,["mockupId"]);g||e.addWarning("[@imageSource] is missing the image url",o);d||e.addWarning("[@mockupId:xxx] is missing from [@imageSource]",o);const m=Object.assign({url:null!=g?g:"",mockupId:null!=d?d:""},f);s.imageSource=m}(e,0,r,c,y)};const o=r(7735),n=r(2028),a=r(166),s=r(385),l=r(6877),p=r(9681),u=r(3029)},8903:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BitUtils=void 0;const i=r(777),o=r(4078),n=new i.TextParser;const a=new class{fillStringExample(e,t,r,i,o){if(t){Array.isArray(t)||(t=[t]);for(const a of t)if(!a.isExample&&(r?(a.example=a.__defaultExample,a.isExample=!0):a.example=i?n.toAst(i,{textFormat:e,isProperty:!0}):void 0,o))break}}fillBooleanExample(e,t,r,i){if(e){Array.isArray(e)||(e=[e]);for(const n of e)if(!n.isExample&&(!i||n.isCorrect)&&(t?(n.example=n.__defaultExample,n.isExample=!0):n.example=o.BooleanUtils.toBoolean(r),i))break}}};t.BitUtils=a},9248:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TAGS=void 0;const i=r(7797),o=r(9917),n={[i.TagConfigKey.title]:{tag:o.Tag.tag_title},[i.TagConfigKey.anchor]:{tag:o.Tag.tag_anchor},[i.TagConfigKey.tag_reference]:{tag:o.Tag.tag_reference},[i.TagConfigKey.property]:{tag:o.Tag.tag_property},[i.TagConfigKey.itemLead]:{tag:o.Tag.tag_itemLead},[i.TagConfigKey.instruction]:{tag:o.Tag.tag_instruction},[i.TagConfigKey.hint]:{tag:o.Tag.tag_hint},[i.TagConfigKey.true]:{tag:o.Tag.tag_true},[i.TagConfigKey.false]:{tag:o.Tag.tag_false},[i.TagConfigKey.sampleSolution]:{tag:o.Tag.tag_sampleSolution},[i.TagConfigKey.gap]:{tag:o.Tag.tag_gap},[i.TagConfigKey.tag_mark]:{tag:o.Tag.tag_mark},[i.TagConfigKey.resource]:{tag:o.Tag.tag_resource}};t.TAGS=n},9289:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.itemLeadChainContentProcessor=function(e,t,r,s,l){t===a.BitContentLevel.Chain?(0,n.itemLeadTagContentProcessor)(e,t,r,s,l):function(e,t,r,n,s){var l;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("item lead content",n);const p=i.Config.getTagConfigForTag(r,o.Tag.fromValue(n.type)),u=[n,...null!==(l=n.chain)&&void 0!==l?l:[]],c=e.bitContentProcessor(a.BitContentLevel.Chain,null==p?void 0:p.chain,u);e.DEBUG_CHAIN_TAGS&&e.debugPrint("item lead TAGS",c);s.itemLead=c.itemLead}(e,0,r,s,l)};const i=r(2028),o=r(9917),n=r(8216),a=r(3029)},9371:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CardVariantConfig=void 0;t.CardVariantConfig=class{constructor(e,t,r,i){this.tags=e,this.bodyAllowed=t??!0,this.bodyRequired=r,this.repeatCount=i}toString(e){const t=Object.assign({},e);let r="";const i=[];this.bodyAllowed&&i.push("bodyAllowed"),this.bodyRequired&&i.push("bodyRequired"),null!=this.repeatCount&&i.push(`repeatCount=${this.repeatCount}`),r+=`[Flags]\n${i.join(", ")}`,r+="\n\n[Tags]";for(const e of Object.values(this.tags))r+=`\n${e.toString(t)}`;return r}}},9554:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TextNodeType=void 0;const i=(0,r(4718).superenum)({text:"text",hardBreak:"hardBreak",paragraph:"paragraph",heading:"heading",section:"section",noBulletList:"noBulletList",bulletList:"bulletList",orderedList:"orderedList",orderedListRoman:"orderedListRoman",orderedListRomanLower:"orderedListRomanLower",letteredList:"letteredList",letteredListLower:"letteredListLower",taskList:"taskList",listItem:"listItem",taskItem:"taskItem",image:"image",imageInline:"imageInline",codeBlock:"codeBlock",latex:"latex",gap:"gap",select:"select",highlight:"highlight",mark:"mark"});t.TextNodeType=i},9561:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Os=void 0;const i=(0,r(4718).superenum)({unknown:"",macos:"macos",windows:"windows",linux:"linux",android:"android",ios:"ios"});t.Os=i},9600:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceTagConfig=void 0;const i=r(5512),o=r(6634);class n extends o.AbstractTagConfig{constructor(e,t,r,o,n,a,s){super(i.BitTagType.resource,e,t,r,o,n,a,void 0,s),this.type=i.BitTagType.resource}toString(e){const t=Object.assign({},e);let r=`RES[${this.tag}`;if(t.includeConfigs&&(null!=this.deprecated&&(r+=`, deprecated=${this.deprecated}`),null!=this.maxCount&&(r+=`, max=${this.maxCount}`),null!=this.minCount&&(r+=`, min=${this.minCount}`),null!=this.jsonKey&&(r+=`, json=${this.jsonKey}`)),r+="]",this.chain&&t.includeChains){r+="\n|__";let e=!0;for(const i of Object.values(this.chain))e||(r+=" "),r+=`${i.toString(t)}`,e=!1}return r}}t.ResourceTagConfig=n},9647:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.propertyContentProcessor=function(e,t,r,m,S){const{value:A}=m;let{key:L}=m;const I=t===w.BitContentLevel.Chain,F=o.Config.getTagConfigForTag(r,p.PropertyTag.fromValue(L)),N=F?F.configKey:void 0;if(L===p.PropertyTag.internalComment)return void(0,B.commentTagContentProcessor)(e,t,m,S);if(F){if(N===s.PropertyConfigKey.example)return void(0,h.exampleTagContentProcessor)(e,t,m,S);if(N===s.PropertyConfigKey.ratingLevelStart||N===s.PropertyConfigKey.ratingLevelEnd)return void(0,P.ratingLevelChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.technicalTerm)return void(0,K.technicalTermChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.servings)return void(0,k.servingsChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.person||N===s.PropertyConfigKey.partner)return void(0,C.personChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.imageSource)return void(0,b.imageSourceChainContentProcessor)(e,t,r,m,S);if(N===s.PropertyConfigKey.book)return void(0,T.bookChainContentProcessor)(e,t,F.chain,m,S);if(N===s.PropertyConfigKey.markConfig&&!I)return void(0,v.markConfigChainContentProcessor)(e,t,r,m,S);if(N===s.PropertyConfigKey.property_title&&I)L="propertyTitle";else if(N===s.PropertyConfigKey.imagePlaceholder)return void(0,x.propertyStyleResourceContentProcessor)(e,t,r,m,S,u.ResourceTag.image)}const O=(e,t,r,o)=>{if(r=(e=>{if(null!=e){if(o)switch(o.format){case l.PropertyFormat.trimmedString:return i.Breakscape.unbreakscape(f.StringUtils.isString(e)?f.StringUtils.trimmedString(e):void 0,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag});case l.PropertyFormat.number:return d.NumberUtils.asNumber(i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag}));case l.PropertyFormat.boolean:return g.BooleanUtils.toBoolean(i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag}),!0);case l.PropertyFormat.invertedBoolean:return!g.BooleanUtils.toBoolean(i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag}),!0);case l.PropertyFormat.bitmarkMinusMinus:return e=f.StringUtils.isString(e)?e:"",_.toAst(e,{textFormat:c.TextFormat.bitmarkMinusMinus,isProperty:!0});case l.PropertyFormat.bitmarkPlusPlus:return e=f.StringUtils.isString(e)?e:"",_.toAst(e,{textFormat:c.TextFormat.bitmarkPlusPlus,isProperty:!0})}return i.Breakscape.unbreakscape(e,{textFormat:c.TextFormat.bitmarkMinusMinus,textLocation:y.TextLocation.tag})}})(r),(null==o?void 0:o.astKey)&&(t=o.astKey),null==o?void 0:o.single)e[t]=r;else if(Object.prototype.hasOwnProperty.call(e,t)){const i=e[t];e[t]=[...i,r]}else e[t]=[r]};O(F?S:S.extraProperties,L,A,F);L===p.PropertyTag.tag_sampleSolution&&O(S,"__sampleSolutionAst",A,new n.PropertyTagConfig(a.ConfigKey.sampleSolution,p.PropertyTag.tag_sampleSolution,1,1,void 0,void 0,void 0,!0,l.PropertyFormat.bitmarkMinusMinus,void 0,void 0))};const i=r(7735),o=r(2028),n=r(1519),a=r(5591),s=r(9888),l=r(9727),p=r(166),u=r(6149),c=r(385),y=r(6877),g=r(4078),d=r(8025),f=r(9681),m=r(777),T=r(3045),h=r(4091),b=r(8848),B=r(6991),v=r(3063),C=r(21),P=r(3967),x=r(6521),k=r(4953),K=r(4475),w=r(3029),_=new m.TextParser},9681:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.StringUtils=void 0;const r=new class{isString(e){return"string"==typeof e||e instanceof String}string(e){return e?`${e}`:""}trimmedString(e){return this.string(e).trim()}countOccurrences(e,t){return e.split(t).length-1}countOccurrencesAtStart(e,t){let r=0;for(;e.startsWith(t);)r++,e=e.substring(t.length);return r}countOccurrencesAtEnd(e,t){let r=0;for(;e.endsWith(t);)r++,e=e.substring(0,e.length-t.length);return r}splitPlaceholders(e,t){let r=[e];const i=(e,t)=>{const r=[];for(const i of e){const e=i.split(t);for(let i=0,o=e.length;i<o;i++){const n=e[i],a=i===o-1;r.push(n),a||r.push(t)}}return r};for(const e of t)r=i(r,e);return r}firstLine(e,t){const r=e;if(null==t&&(t=e.length),t<1||null==e||e.length<=t)return r;const i=e.split("\n");return i.length>0?i[0].substring(0,t):r}wordWrap(e,t){const r=[];if(t<1||null==e||e.length<=t)return r;const i=e.length,o=i-t;let n,a=0;for(;a<o;){let i;const o=a+t,s=e.indexOf("\n",a);if(s>-1&&s>a&&s<o){i=s-a,n=e.substr(a,i),a=a+i+1,r.push(n);continue}const l=e.lastIndexOf(" ",o);let p=0;l>-1&&l!=a-1?(i=l-a,i>0&&(p=a+i+1)):(i=t,p=a+t),n=e.substr(a,i),a=p,r.push(n.trim())}return a<i&&(n=e.substr(a),r.push(n)),r}};t.StringUtils=r},9727:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PropertyFormat=void 0;const i=(0,r(4718).superenum)({none:"none",trimmedString:"trimmedString",bitmarkMinusMinus:"bitmarkMinusMinus",bitmarkPlusPlus:"bitmarkPlusPlus",number:"number",boolean:"boolean",invertedBoolean:"invertedBoolean"});t.PropertyFormat=i},9788:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.MarkupTagConfig=void 0;const i=r(5512),o=r(6634);class n extends o.AbstractTagConfig{constructor(e,t,r,o,n,a){super(i.BitTagType.tag,e,t,r,o,n,void 0,void 0,a),this.type=i.BitTagType.tag}toString(e){const t=Object.assign({},e);let r=`TAG[${this.tag}`;if(t.includeConfigs&&(null!=this.deprecated&&(r+=`, deprecated=${this.deprecated}`),null!=this.maxCount&&(r+=`, max=${this.maxCount}`),null!=this.minCount&&(r+=`, min=${this.minCount}`)),r+="]",this.chain&&t.includeChains){r+="\n|__";let e=!0;for(const i of Object.values(this.chain))e||(r+=" "),r+=`${i.toString(t)}`,e=!1}return r}}t.MarkupTagConfig=n},9885:function(e,t,r){var i=this&&this.__rest||function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(i=Object.getOwnPropertySymbols(e);o<i.length;o++)t.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(e,i[o])&&(r[i[o]]=e[i[o]])}return r};Object.defineProperty(t,"__esModule",{value:!0}),t.trueFalseChainContentProcessor=function(e,t,r,p,u,c){t===l.BitContentLevel.Chain?(0,s.trueFalseTagContentProcessor)(e,l.BitContentLevel.Chain,p,u):function(e,t,r,s,p,u){var c;const{bitType:y}=e,g=[s,...null!==(c=s.chain)&&void 0!==c?c:[]],d=p.statements,f=p.choices,m=p.responses;if(!(d&&f&&m&&u))return;if(o.Config.isOfBitType(y,n.BitType.trueFalse1))p.statement=function(e,t,r){const{bitType:a}=e;if(!o.Config.isOfBitType(a,n.BitType.trueFalse1))return;e.DEBUG_CHAIN_CONTENT&&e.debugPrint("trueFalse V1 content (statement)",r);const s=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:p}=s,u=i(s,["trueFalse"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("trueFalse V1 tags (statement)",u);let c,y;p&&p.length>0&&(y=p[0]);if(y){const{statement:e}=u,t=i(u,["statement"]);c=Object.assign(Object.assign(Object.assign({},y),{statement:y.text}),t)}return c}(e,r,g);else if(o.Config.isOfBitType(y,[n.BitType.trueFalse,n.BitType.multipleChoice,n.BitType.multipleChoice1,n.BitType.multipleResponse,n.BitType.multipleResponse1,n.BitType.feedback])){const t=function(e,t,r){const{bitType:a}=e,s=o.Config.isOfBitType(a,n.BitType.trueFalse),p=o.Config.isOfBitType(a,[n.BitType.multipleChoice,n.BitType.multipleChoice1,n.BitType.feedback]),u=o.Config.isOfBitType(a,[n.BitType.multipleResponse,n.BitType.multipleResponse1]);if(!s&&!p&&!u)return{};const c=[],y=[],g=[],d=e.splitBitContent(r,[l.TypeKey.True,l.TypeKey.False]);e.DEBUG_CHAIN_CONTENT&&e.debugPrint("trueFalse V1 content (choices/responses)",d);for(const r of d){const o=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:n}=o,a=i(o,["trueFalse"]);let d;if(e.DEBUG_CHAIN_TAGS&&e.debugPrint("trueFalse V1 tags (choices/responses)",a),n&&n.length>0&&(d=n[0]),d)if(s){const{statement:e}=a,t=i(a,["statement"]),r=Object.assign(Object.assign(Object.assign({},d),{statement:d.text}),t);r&&c.push(r)}else if(p){const e=Object.assign(Object.assign(Object.assign({},d),{choice:d.text}),a);e&&y.push(e)}else if(u){const e=Object.assign(Object.assign(Object.assign({},d),{response:d.text}),a);e&&g.push(e)}}const f={};s?f.statements=c:p?f.choices=y:u&&(f.responses=g);return f}(e,r,g);t.statements&&d.push(...t.statements),t.choices&&f.push(...t.choices),t.responses&&m.push(...t.responses)}else if(o.Config.isOfBitType(y,n.BitType.highlightText)){const t=function(e,t,r){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("highlight content",r);const o=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:n}=o,s=i(o,["trueFalse"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("highlight TAGS",Object.assign({trueFalse:n},s));const p=[];if(n)for(const e of n){const t=Object.assign(Object.assign({},e),{isHighlighted:!1});t&&p.push(t)}const u=Object.assign({type:a.BodyBitType.highlight,texts:p},s);return u}(e,r,g);t&&u.push(t)}else{const t=function(e,t,r){e.DEBUG_CHAIN_CONTENT&&e.debugPrint("select content",r);const o=e.bitContentProcessor(l.BitContentLevel.Chain,t,r),{trueFalse:n}=o,s=i(o,["trueFalse"]);e.DEBUG_CHAIN_TAGS&&e.debugPrint("select TAGS",Object.assign({trueFalse:n},s));const p=[];if(n)for(const e of n){const t=e;t&&p.push(t)}const u=Object.assign({type:a.BodyBitType.select,options:p},s);return u}(e,r,g);t&&u.push(t)}}(e,0,r,p,u,c)};const o=r(2028),n=r(5854),a=r(4410),s=r(4020),l=r(3029)},9888:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.propertyConfigKeys=t.PropertyConfigKey=void 0;const i=r(4718),o={action:"action",activityType:"activityType",additionalSolutions:"additionalSolutions",ageRange:"ageRange",aiGenerated:"aiGenerated",analyticsTag:"analyticsTag",allowedBit:"allowedBit",allowSubtitles:"allowSubtitles",alt:"alt",altLangTag:"altLangTag",author:"author",autoplay:"autoplay",availableClassifications:"availableClassifications",backgroundWallpaper:"backgroundWallpaper",blockId:"blockId",book:"book",bookAlias:"bookAlias",bookDiff:"bookDiff",bot:"bot",bubbleTag:"bubbleTag",buttonCaption:"buttonCaption",callToActionUrl:"callToActionUrl",caption:"caption",categoryTag:"categoryTag",chatWithBook:"chatWithBook",chatWithBookBrainKey:"chatWithBookBrainKey",citationStyle:"citationStyle",classification:"classification",codeLineNumbers:"codeLineNumbers",codeMinimap:"codeMinimap",color:"color",colorTag:"colorTag",computerLanguage:"computerLanguage",content2Buy:"content2Buy",copyright:"copyright",coverColor:"coverColor",coverImage:"coverImage",customerExternalId:"customerExternalId",customerId:"customerId",date:"date",dateEnd:"dateEnd",decimalPlaces:"decimalPlaces",deeplink:"deeplink",disableCalculation:"disableCalculation",disableFeedback:"disableFeedback",diffTo:"diffTo",diffOp:"diffOp",diffRef:"diffRef",diffContext:"diffContext",diffTime:"diffTime",duration:"duration",emphasis:"emphasis",example:"example",externalId:"externalId",externalLink:"externalLink",externalLinkText:"externalLinkText",feedbackEngine:"feedbackEngine",feedbackType:"feedbackType",flashcardSet:"flashcardSet",focusX:"focusX",focusY:"focusY",format:"format",handInAcceptFileType:"handInAcceptFileType",handInRequirement:"handInRequirement",handInInstruction:"handInInstruction",hasBookNavigation:"hasBookNavigation",hasMarkAsDone:"hasMarkAsDone",height:"height",icon:"icon",iconTag:"iconTag",id:"id",imageFirst:"imageFirst",imagePlaceholder:"imagePlaceholder",imageSource:"imageSource",index:"index",internalComment:"internalComment",isCaseSensitive:"isCaseSensitive",isInfoOnly:"isInfoOnly",isPublic:"isPublic",isTracked:"isTracked",jupyterExecutionCount:"jupyterExecutionCount",jupyterId:"jupyterId",kind:"kind",label:"label",labelFalse:"labelFalse",labelTrue:"labelTrue",lang:"lang",language:"language",layer:"layer",levelCEFRp:"levelCEFRp",levelCEFR:"levelCEFR",levelILR:"levelILR",levelACTFL:"levelACTFL",license:"license",list:"list",listItemIndent:"listItemIndent",location:"location",machineTranslated:"machineTranslated",mailingList:"mailingList",markConfig:"markConfig",maxCreatedBits:"maxCreatedBits",maxDisplayLevel:"maxDisplayLevel",maxTocChapterLevel:"maxTocChapterLevel",mockupId:"mockupId",mute:"mute",padletId:"padletId",pageNo:"pageNo",partialAnswer:"partialAnswer",partner:"partner",person:"person",path:"path",pointerLeft:"pointerLeft",pointerTop:"pointerTop",posterImage:"posterImage",page:"page",processHandIn:"processHandIn",product:"product",productFolder:"productFolder",productId:"productId",productList:"productList",productVideo:"productVideo",productVideoList:"productVideoList",progress:"progress",property_mark:"property_mark",property_reference:"property_reference",property_sampleSolution:"property_sampleSolution",property_title:"property_title",publications:"publications",publisher:"publisher",publisherName:"publisherName",quizCountItems:"quizCountItems",quizStrikethroughSolutions:"quizStrikethroughSolutions",quotedPerson:"quotedPerson",ratingLevelEnd:"ratingLevelEnd",ratingLevelSelected:"ratingLevelSelected",ratingLevelStart:"ratingLevelStart",reaction:"reaction",reasonableNumOfChars:"reasonableNumOfChars",reductionTag:"reductionTag",refAuthor:"refAuthor",refBookTitle:"refBookTitle",refPublisher:"refPublisher",refPublicationYear:"refPublicationYear",releaseDate:"releaseDate",releaseKind:"releaseKind",releaseVersion:"releaseVersion",resolved:"resolved",resolvedBy:"resolvedBy",resolvedDate:"resolvedDate",revealSolutions:"revealSolutions",scormSource:"scormSource",search:"search",searchIndex:"searchIndex",servings:"servings",showInIndex:"showInIndex",showSubtitles:"showSubtitles",siteName:"siteName",size:"size",slug:"slug",spaceId:"spaceId",src1x:"src1x",src2x:"src2x",src3x:"src3x",src4x:"src4x",stripePricingTableId:"stripePricingTableId",stripePublishableKey:"stripePublishableKey",subject:"subject",subtype:"subtype",tableAutoWidth:"tableAutoWidth",tableFixedHeader:"tableFixedHeader",tableHeight:"tableHeight",tablePagination:"tablePagination",tablePaginationLimit:"tablePaginationLimit",tableResizableColumns:"tableResizableColumns",tableColumnMinWidth:"tableColumnMinWidth",tableSearch:"tableSearch",tableSort:"tableSort",tableWhitespaceNoWrap:"tableWhitespaceNoWrap",tag:"tag",target:"target",technicalTerm:"technicalTerm",textReference:"textReference",theme:"theme",thumbImage:"thumbImage",toc:"toc",topicTag:"topicTag",trim:"trim",unit:"unit",unitAbbr:"unitAbbr",vendorDashboardId:"vendorDashboardId",vendorSurveyId:"vendorSurveyId",vendorUrl:"vendorUrl",videoCallLink:"videoCallLink",width:"width",x:"x",y:"y",zoomDisabled:"zoomDisabled"};t.propertyConfigKeys=o;const n=(0,i.superenum)(o);t.PropertyConfigKey=n},9916:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTIES=void 0;const i=r(9888),o=r(7203),n=r(9727),a=r(166),s={[i.PropertyConfigKey.id]:{tag:a.PropertyTag.id,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.internalComment]:{tag:a.PropertyTag.internalComment,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.customerId]:{tag:a.PropertyTag.customerId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.customerExternalId]:{tag:a.PropertyTag.customerExternalId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.externalId]:{tag:a.PropertyTag.externalId,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.spaceId]:{tag:a.PropertyTag.spaceId,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.padletId]:{tag:a.PropertyTag.padletId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.jupyterId]:{tag:a.PropertyTag.jupyterId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.jupyterExecutionCount]:{tag:a.PropertyTag.jupyterExecutionCount,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.aiGenerated]:{tag:a.PropertyTag.aiGenerated,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.machineTranslated]:{tag:a.PropertyTag.machineTranslated,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.searchIndex]:{tag:a.PropertyTag.searchIndex,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.analyticsTag]:{tag:a.PropertyTag.analyticsTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.categoryTag]:{tag:a.PropertyTag.categoryTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.topicTag]:{tag:a.PropertyTag.topicTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.altLangTag]:{tag:a.PropertyTag.altLangTag,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.feedbackEngine]:{tag:a.PropertyTag.feedbackEngine,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.disableFeedback]:{tag:a.PropertyTag.disableFeedback,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.diffTo]:{tag:a.PropertyTag.diffTo,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffOp]:{tag:a.PropertyTag.diffOp,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffRef]:{tag:a.PropertyTag.diffRef,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffContext]:{tag:a.PropertyTag.diffContext,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.diffTime]:{tag:a.PropertyTag.diffTime,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.path]:{tag:a.PropertyTag.path,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.releaseVersion]:{tag:a.PropertyTag.releaseVersion,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.releaseKind]:{tag:a.PropertyTag.releaseKind,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.releaseDate]:{tag:a.PropertyTag.releaseDate,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.resolved]:{tag:a.PropertyTag.resolved,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.resolvedDate]:{tag:a.PropertyTag.resolvedDate,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.resolvedBy]:{tag:a.PropertyTag.resolvedBy,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.handInAcceptFileType]:{tag:a.PropertyTag.handInAcceptFileType,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.handInRequirement]:{tag:a.PropertyTag.handInRequirement,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.handInInstruction]:{tag:a.PropertyTag.handInInstruction,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.ageRange]:{tag:a.PropertyTag.ageRange,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.lang]:{tag:a.PropertyTag.lang,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.language]:{tag:a.PropertyTag.language,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.computerLanguage]:{tag:a.PropertyTag.computerLanguage,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.target]:{tag:a.PropertyTag.target,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.slug]:{tag:a.PropertyTag.slug,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.tag]:{tag:a.PropertyTag.tag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.reductionTag]:{tag:a.PropertyTag.reductionTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bubbleTag]:{tag:a.PropertyTag.bubbleTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelCEFRp]:{tag:a.PropertyTag.levelCEFRp,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelCEFR]:{tag:a.PropertyTag.levelCEFR,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelILR]:{tag:a.PropertyTag.levelILR,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.levelACTFL]:{tag:a.PropertyTag.levelACTFL,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.icon]:{tag:a.PropertyTag.icon,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.iconTag]:{tag:a.PropertyTag.iconTag,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.colorTag]:{tag:a.PropertyTag.colorTag,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.flashcardSet]:{tag:a.PropertyTag.flashcardSet,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.subtype]:{tag:a.PropertyTag.subtype,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bookAlias]:{tag:a.PropertyTag.bookAlias,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bookDiff]:{tag:a.PropertyTag.bookDiff,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refAuthor]:{tag:a.PropertyTag.refAuthor,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refBookTitle]:{tag:a.PropertyTag.refBookTitle,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refPublisher]:{tag:a.PropertyTag.refPublisher,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.refPublicationYear]:{tag:a.PropertyTag.refPublicationYear,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.citationStyle]:{tag:a.PropertyTag.citationStyle,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.coverImage]:{tag:a.PropertyTag.coverImage,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.coverColor]:{tag:a.PropertyTag.coverColor,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.imagePlaceholder]:{tag:a.PropertyTag.imagePlaceholder,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.publisher]:{tag:a.PropertyTag.publisher,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.publisherName]:{tag:a.PropertyTag.publisherName,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.publications]:{tag:a.PropertyTag.publications,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.author]:{tag:a.PropertyTag.author,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.subject]:{tag:a.PropertyTag.subject,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.date]:{tag:a.PropertyTag.date,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.dateEnd]:{tag:a.PropertyTag.dateEnd,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.location]:{tag:a.PropertyTag.location,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.theme]:{tag:a.PropertyTag.theme,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.kind]:{tag:a.PropertyTag.kind,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.hasMarkAsDone]:{tag:a.PropertyTag.hasMarkAsDone,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.processHandIn]:{tag:a.PropertyTag.processHandIn,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.isPublic]:{tag:a.PropertyTag.isPublic,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.chatWithBook]:{tag:a.PropertyTag.chatWithBook,defaultValue:"false",single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.chatWithBookBrainKey]:{tag:a.PropertyTag.chatWithBookBrainKey,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.action]:{tag:a.PropertyTag.action,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.thumbImage]:{tag:a.PropertyTag.thumbImage,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.scormSource]:{tag:a.PropertyTag.scormSource,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.posterImage]:{tag:a.PropertyTag.posterImage,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.focusX]:{tag:a.PropertyTag.focusX,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.focusY]:{tag:a.PropertyTag.focusY,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.deeplink]:{tag:a.PropertyTag.deeplink,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.externalLink]:{tag:a.PropertyTag.externalLink,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.externalLinkText]:{tag:a.PropertyTag.externalLinkText,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.videoCallLink]:{tag:a.PropertyTag.videoCallLink,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.vendorDashboardId]:{tag:a.PropertyTag.vendorDashboardId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.vendorSurveyId]:{tag:a.PropertyTag.vendorSurveyId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.vendorUrl]:{tag:a.PropertyTag.vendorUrl,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.search]:{tag:a.PropertyTag.search,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.bot]:{tag:a.PropertyTag.bot,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.duration]:{tag:a.PropertyTag.duration,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.property_reference]:{tag:a.PropertyTag.tag_reference,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_referenceProperty},[i.PropertyConfigKey.list]:{tag:a.PropertyTag.list,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.layer]:{tag:a.PropertyTag.layer,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.textReference]:{tag:a.PropertyTag.textReference,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.isTracked]:{tag:a.PropertyTag.isTracked,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.isInfoOnly]:{tag:a.PropertyTag.isInfoOnly,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.labelTrue]:{tag:a.PropertyTag.labelTrue,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.labelFalse]:{tag:a.PropertyTag.labelFalse,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.content2Buy]:{tag:a.PropertyTag.content2Buy,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.quotedPerson]:{tag:a.PropertyTag.quotedPerson,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.partialAnswer]:{tag:a.PropertyTag.partialAnswer,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.reasonableNumOfChars]:{tag:a.PropertyTag.reasonableNumOfChars,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.maxCreatedBits]:{tag:a.PropertyTag.maxCreatedBits,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.maxDisplayLevel]:{tag:a.PropertyTag.maxDisplayLevel,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.maxTocChapterLevel]:{tag:a.PropertyTag.maxTocChapterLevel,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.technicalTerm]:{tag:a.PropertyTag.technicalTerm,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.servings]:{tag:a.PropertyTag.servings,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.unit]:{tag:a.PropertyTag.unit,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.unitAbbr]:{tag:a.PropertyTag.unitAbbr,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.decimalPlaces]:{tag:a.PropertyTag.decimalPlaces,single:!0,format:n.PropertyFormat.number,defaultValue:"1"},[i.PropertyConfigKey.disableCalculation]:{tag:a.PropertyTag.disableCalculation,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.example]:{tag:a.PropertyTag.example,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.toc]:{tag:a.PropertyTag.toc,single:!0,format:n.PropertyFormat.boolean,defaultValue:"true"},[i.PropertyConfigKey.page]:{tag:a.PropertyTag.page,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.product]:{tag:a.PropertyTag.product,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.productId]:{tag:a.PropertyTag.productId,single:!1,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.productList]:{tag:a.PropertyTag.product,single:!1,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_productList},[i.PropertyConfigKey.productVideo]:{tag:a.PropertyTag.productVideo,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.productVideoList]:{tag:a.PropertyTag.productVideo,single:!1,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_productVideoList},[i.PropertyConfigKey.productFolder]:{tag:a.PropertyTag.productFolder,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.progress]:{tag:a.PropertyTag.progress,single:!0,format:n.PropertyFormat.boolean,defaultValue:"true"},[i.PropertyConfigKey.book]:{tag:a.PropertyTag.book,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.person]:{tag:a.PropertyTag.person,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.partner]:{tag:a.PropertyTag.partner,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.property_sampleSolution]:{tag:a.PropertyTag.tag_sampleSolution,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.additionalSolutions]:{tag:a.PropertyTag.additionalSolutions,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.markConfig]:{tag:a.PropertyTag.tag_mark,format:n.PropertyFormat.trimmedString,astKey:o.PropertyAstKey.ast_markConfig},[i.PropertyConfigKey.property_mark]:{tag:a.PropertyTag.tag_mark,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.color]:{tag:a.PropertyTag.color,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.emphasis]:{tag:a.PropertyTag.emphasis,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.isCaseSensitive]:{tag:a.PropertyTag.isCaseSensitive,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.reaction]:{tag:a.PropertyTag.reaction,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.imageSource]:{tag:a.PropertyTag.imageSource,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.mockupId]:{tag:a.PropertyTag.mockupId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.size]:{tag:a.PropertyTag.size,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.format]:{tag:a.PropertyTag.format,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.property_title]:{tag:a.PropertyTag.tag_title,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.trim]:{tag:a.PropertyTag.trim,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.width]:{tag:a.PropertyTag.width,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.height]:{tag:a.PropertyTag.height,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.license]:{tag:a.PropertyTag.license,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.copyright]:{tag:a.PropertyTag.copyright,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.mailingList]:{tag:a.PropertyTag.mailingList,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.buttonCaption]:{tag:a.PropertyTag.buttonCaption,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.callToActionUrl]:{tag:a.PropertyTag.callToActionUrl,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.feedbackType]:{tag:a.PropertyTag.feedbackType,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.caption]:{tag:a.PropertyTag.caption,single:!0,format:n.PropertyFormat.bitmarkMinusMinus},[i.PropertyConfigKey.showInIndex]:{tag:a.PropertyTag.showInIndex,single:!0,format:n.PropertyFormat.boolean,defaultValue:"false"},[i.PropertyConfigKey.alt]:{tag:a.PropertyTag.alt,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.zoomDisabled]:{tag:a.PropertyTag.zoomDisabled,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.src1x]:{tag:a.PropertyTag.src1x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.src2x]:{tag:a.PropertyTag.src2x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.src3x]:{tag:a.PropertyTag.src3x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.src4x]:{tag:a.PropertyTag.src4x,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.mute]:{tag:a.PropertyTag.mute,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.autoplay]:{tag:a.PropertyTag.autoplay,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.allowSubtitles]:{tag:a.PropertyTag.allowSubtitles,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.showSubtitles]:{tag:a.PropertyTag.showSubtitles,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.siteName]:{tag:a.PropertyTag.siteName,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.pointerLeft]:{tag:a.PropertyTag.pointerLeft,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.pointerTop]:{tag:a.PropertyTag.pointerTop,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.listItemIndent]:{tag:a.PropertyTag.listItemIndent,single:!0,defaultValue:"0",format:n.PropertyFormat.number},[i.PropertyConfigKey.backgroundWallpaper]:{tag:a.PropertyTag.backgroundWallpaper,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.hasBookNavigation]:{tag:a.PropertyTag.hasBookNavigation,single:!0,defaultValue:"true",format:n.PropertyFormat.boolean},[i.PropertyConfigKey.blockId]:{tag:a.PropertyTag.blockId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.pageNo]:{tag:a.PropertyTag.pageNo,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.x]:{tag:a.PropertyTag.x,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.y]:{tag:a.PropertyTag.y,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.index]:{tag:a.PropertyTag.index,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.classification]:{tag:a.PropertyTag.classification,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.availableClassifications]:{tag:a.PropertyTag.availableClassifications,single:!1,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.allowedBit]:{tag:a.PropertyTag.allowedBit,single:!1,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.tableFixedHeader]:{tag:a.PropertyTag.tableFixedHeader,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableSearch]:{tag:a.PropertyTag.tableSearch,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableSort]:{tag:a.PropertyTag.tableSort,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tablePagination]:{tag:a.PropertyTag.tablePagination,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tablePaginationLimit]:{tag:a.PropertyTag.tablePaginationLimit,single:!0,format:n.PropertyFormat.number,defaultValue:"0"},[i.PropertyConfigKey.tableHeight]:{tag:a.PropertyTag.tableHeight,single:!0,format:n.PropertyFormat.number,defaultValue:"0"},[i.PropertyConfigKey.tableWhitespaceNoWrap]:{tag:a.PropertyTag.tableWhitespaceNoWrap,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableAutoWidth]:{tag:a.PropertyTag.tableAutoWidth,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableResizableColumns]:{tag:a.PropertyTag.tableResizableColumns,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.tableColumnMinWidth]:{tag:a.PropertyTag.tableColumnMinWidth,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.quizCountItems]:{tag:a.PropertyTag.quizCountItems,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.quizStrikethroughSolutions]:{tag:a.PropertyTag.quizStrikethroughSolutions,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.codeLineNumbers]:{tag:a.PropertyTag.codeLineNumbers,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.codeMinimap]:{tag:a.PropertyTag.codeMinimap,single:!0,format:n.PropertyFormat.boolean},[i.PropertyConfigKey.stripePricingTableId]:{tag:a.PropertyTag.stripePricingTableId,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.stripePublishableKey]:{tag:a.PropertyTag.stripePublishableKey,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.ratingLevelStart]:{tag:a.PropertyTag.ratingLevelStart,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.ratingLevelEnd]:{tag:a.PropertyTag.ratingLevelEnd,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.ratingLevelSelected]:{tag:a.PropertyTag.ratingLevelSelected,single:!0,format:n.PropertyFormat.number},[i.PropertyConfigKey.label]:{tag:a.PropertyTag.label,single:!0,format:n.PropertyFormat.bitmarkMinusMinus},[i.PropertyConfigKey.imageFirst]:{tag:a.PropertyTag.imageFirst,single:!0,format:n.PropertyFormat.boolean,defaultValue:"true"},[i.PropertyConfigKey.activityType]:{tag:a.PropertyTag.activityType,single:!0,format:n.PropertyFormat.trimmedString},[i.PropertyConfigKey.revealSolutions]:{tag:a.PropertyTag.revealSolutions,single:!0,format:n.PropertyFormat.boolean}};t.PROPERTIES=s},9917:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Tag=void 0;const i=(0,r(4718).superenum)({tag_title:"#",tag_anchor:"▼",tag_reference:"►",tag_property:"@",tag_itemLead:"%",tag_instruction:"!",tag_hint:"?",tag_true:"+",tag_false:"-",tag_sampleSolution:"$",tag_gap:"_",tag_mark:"=",tag_resource:"&"});t.Tag=i},9984:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceJsonKey=void 0;const i=(0,r(4718).superenum)({imageResponsive:"imageResponsive",imagePortrait:"imagePortrait",imageLandscape:"imageLandscape",imageEmbed:"imageEmbed",imageLink:"imageLink",audioEmbed:"audioEmbed",audioLink:"audioLink",videoEmbed:"videoEmbed",videoLink:"videoLink",stillImageFilm:"stillImageFilm",stillImageFilmEmbed:"stillImageFilmEmbed",stillImageFilmLink:"stillImageFilmLink",articleEmbed:"articleEmbed",articleLink:"articleLink",documentEmbed:"documentEmbed",documentLink:"documentLink",documentDownload:"documentDownload",appLink:"appLink",websiteLink:"websiteLink"});t.ResourceJsonKey=i}},t={};function r(i){var o=t[i];if(void 0!==o)return o.exports;var n=t[i]={exports:{}};return e[i].call(n.exports,n,n.exports,r),n.exports}r.d=(e,t)=>{for(var i in t)r.o(t,i)&&!r.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{var e=i;Object.defineProperty(e,"__esModule",{value:!0}),e.StreamWriter=e.FileWriter=e.BitmarkFileGenerator=e.JsonFileGenerator=e.bitmarkTextParse=e.InfoFormat=e.InfoType=e.CardSetVersion=e.BitmarkVersion=e.BitmarkParserType=e.NodeType=e.ResourceTag=e.TextFormat=e.BitType=e.StringWriter=e.BitmarkStringGenerator=e.BitmarkGenerator=e.BitmarkParser=e.JsonStringGenerator=e.JsonGenerator=e.JsonParser=e.Ast=e.ResourceBuilder=e.Builder=e.Output=e.Input=e.BitmarkParserGenerator=void 0;const t=r(1412);var o=r(1791);Object.defineProperty(e,"BitmarkParserGenerator",{enumerable:!0,get:function(){return o.BitmarkParserGenerator}}),Object.defineProperty(e,"Input",{enumerable:!0,get:function(){return o.Input}}),Object.defineProperty(e,"Output",{enumerable:!0,get:function(){return o.Output}});var n=r(5809);Object.defineProperty(e,"Builder",{enumerable:!0,get:function(){return n.Builder}});var a=r(5533);Object.defineProperty(e,"ResourceBuilder",{enumerable:!0,get:function(){return a.ResourceBuilder}});var s=r(5126);Object.defineProperty(e,"Ast",{enumerable:!0,get:function(){return s.Ast}});var l=r(5663);Object.defineProperty(e,"JsonParser",{enumerable:!0,get:function(){return l.JsonParser}});var p=r(2497);Object.defineProperty(e,"JsonGenerator",{enumerable:!0,get:function(){return p.JsonGenerator}});var u=r(98);Object.defineProperty(e,"JsonStringGenerator",{enumerable:!0,get:function(){return u.JsonStringGenerator}});var c=r(5633);Object.defineProperty(e,"BitmarkParser",{enumerable:!0,get:function(){return c.BitmarkParser}});var y=r(5087);Object.defineProperty(e,"BitmarkGenerator",{enumerable:!0,get:function(){return y.BitmarkGenerator}});var g=r(3968);Object.defineProperty(e,"BitmarkStringGenerator",{enumerable:!0,get:function(){return g.BitmarkStringGenerator}});var d=r(6772);Object.defineProperty(e,"StringWriter",{enumerable:!0,get:function(){return d.StringWriter}});var f=r(5854);Object.defineProperty(e,"BitType",{enumerable:!0,get:function(){return f.BitType}});var m=r(385);Object.defineProperty(e,"TextFormat",{enumerable:!0,get:function(){return m.TextFormat}});var T=r(6149);Object.defineProperty(e,"ResourceTag",{enumerable:!0,get:function(){return T.ResourceTag}});var h=r(126);Object.defineProperty(e,"NodeType",{enumerable:!0,get:function(){return h.NodeType}});var b=r(8588);Object.defineProperty(e,"BitmarkParserType",{enumerable:!0,get:function(){return b.BitmarkParserType}});var B=r(3811);Object.defineProperty(e,"BitmarkVersion",{enumerable:!0,get:function(){return B.BitmarkVersion}});var v=r(1163);Object.defineProperty(e,"CardSetVersion",{enumerable:!0,get:function(){return v.CardSetVersion}});var C=r(486);Object.defineProperty(e,"InfoType",{enumerable:!0,get:function(){return C.InfoType}});var P=r(3069);Object.defineProperty(e,"InfoFormat",{enumerable:!0,get:function(){return P.InfoFormat}});var x=r(2220);Object.defineProperty(e,"bitmarkTextParse",{enumerable:!0,get:function(){return x.parse}});(0,t.init)()})(),i})()));
|