diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaResources.html b/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaResources.html index fd8585b7..d264d73c 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaResources.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaResources.html @@ -87,7 +87,7 @@
Table of Contents

Class KafkaResources - +

@@ -158,7 +158,7 @@

Methods

LogSavedChanges(IDiagnosticsLogger) - +

Saved {count} entities to Kafka store.

@@ -195,7 +195,7 @@

Returns

LogTransactionsNotSupported(IDiagnosticsLogger) - +

Transactions are not supported by the Kafka store. See http://go.microsoft.com/fwlink/?LinkId=800142

@@ -232,7 +232,7 @@

Returns

diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaStrings.html b/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaStrings.html index 8850aca2..6edf3a26 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaStrings.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.Internal.KafkaStrings.html @@ -222,7 +222,7 @@

Property Value

NoQueryStrings - +

There is no query string because the Kafka provider does not use a string-based query language.

@@ -250,11 +250,43 @@

Property Value

+ + +

+ NonComposedGroupByNotSupported + +

+ +

A 'GroupBy' operation which is not composed into aggregate or projection of elements is not supported.

+
+
+ +
+
public static string NonComposedGroupByNotSupported { get; }
+
+ + + + + +

Property Value

+
+
string
+
+
+ + + + + + + +

SetOperationsNotAllowedAfterClientEvaluation - +

Unable to translate set operation after client projection has been applied. Consider moving the set operation before the last 'Select' call.

@@ -286,7 +318,7 @@

Property Value

UpdateConcurrencyException - +

Attempted to update or delete an entity that does not exist in the store.

@@ -361,7 +393,7 @@

Returns

NullabilityErrorException(object?, object?) - +

Required properties '{requiredProperties}' are missing for the instance of entity type '{entityType}'. Consider using 'DbContextOptionsBuilder.EnableSensitiveDataLogging' to see the entity key value.

@@ -400,7 +432,7 @@

Returns

NullabilityErrorExceptionSensitive(object?, object?, object?) - +

Required properties '{requiredProperties}' are missing for the instance of entity type '{entityType}' with the key value '{keyValue}'.

@@ -441,7 +473,7 @@

Returns

UnableToBindMemberToEntityProjection(object?, object?, object?) - +

Unable to bind '{memberType}' '{member}' to entity projection of '{entityType}'.

@@ -482,7 +514,7 @@

Returns

UpdateConcurrencyTokenException(object?, object?) - +

Conflicts were detected for instance of entity type '{entityType}' on the concurrency token properties {properties}. Consider using 'DbContextOptionsBuilder.EnableSensitiveDataLogging' to see the conflicting values.

@@ -521,7 +553,7 @@

Returns

UpdateConcurrencyTokenExceptionSensitive(object?, object?, object?, object?) - +

Conflicts were detected for instance of entity type '{entityType}' with the key value '{keyValue}' on the concurrency token property values {conflictingValues}, with corresponding database values {databaseValues}.

diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryContext.html b/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryContext.html index 3f81376a..d9989fa9 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryContext.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryContext.html @@ -87,7 +87,7 @@
Table of Contents

Class KafkaQueryContext - +

@@ -210,7 +210,7 @@

Constructors

KafkaQueryContext(QueryContextDependencies, IKafkaCluster) - +

Default initializer

@@ -248,7 +248,7 @@

Methods

GetValueBuffers(IEntityType) - +

Retrieve ValueBuffer for the specified IEntityType

@@ -285,7 +285,7 @@

Returns

diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryableMethodTranslatingExpressionVisitor.html b/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryableMethodTranslatingExpressionVisitor.html index 8f6c4815..f94a0292 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryableMethodTranslatingExpressionVisitor.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.Query.Internal.KafkaQueryableMethodTranslatingExpressionVisitor.html @@ -360,7 +360,7 @@

Methods

CreateShapedQueryExpression(IEntityType) - +

Creates a ShapedQueryExpression for the given entity type.

@@ -407,7 +407,8 @@

-
protected override ShapedQueryExpression CreateShapedQueryExpression(Type elementType)
+
[Obsolete]
+protected override ShapedQueryExpression CreateShapedQueryExpression(Type elementType)

Parameters

@@ -471,7 +472,7 @@

Returns

TranslateAll(ShapedQueryExpression, LambdaExpression) - +

Translates All<TSource>(IQueryable<TSource>, Expression<Func<TSource, bool>>) method over the given source.

@@ -513,7 +514,7 @@

Returns

TranslateAny(ShapedQueryExpression, LambdaExpression?) - +

Translates Any<TSource>(IQueryable<TSource>) method and other overloads over the given source.

@@ -555,7 +556,7 @@

Returns

TranslateAverage(ShapedQueryExpression, LambdaExpression?, Type) - +

Translates Average(IQueryable<decimal>) method and other overloads over the given source.

@@ -600,7 +601,7 @@

Returns

TranslateCast(ShapedQueryExpression, Type) - +

Translates Cast<TResult>(IQueryable) method over the given source.

@@ -641,7 +642,7 @@

Returns

TranslateConcat(ShapedQueryExpression, ShapedQueryExpression) - +

Translates Concat<TSource>(IQueryable<TSource>, IEnumerable<TSource>) method over the given source.

@@ -683,7 +684,7 @@

Returns

TranslateContains(ShapedQueryExpression, Expression) - +

Translates Contains<TSource>(IQueryable<TSource>, TSource) method over the given source.

@@ -725,7 +726,7 @@

Returns

TranslateCount(ShapedQueryExpression, LambdaExpression?) - +

Translates Count<TSource>(IQueryable<TSource>) method and other overloads over the given source.

@@ -767,7 +768,7 @@

Returns

TranslateDefaultIfEmpty(ShapedQueryExpression, Expression?) - +

Translates DefaultIfEmpty<TSource>(IQueryable<TSource>) method and other overloads over the given source.

@@ -809,7 +810,7 @@

Returns

TranslateDistinct(ShapedQueryExpression) - +

Translates Distinct<TSource>(IQueryable<TSource>) method over the given source.

@@ -848,7 +849,7 @@

Returns

TranslateElementAtOrDefault(ShapedQueryExpression, Expression, bool) - +

Translates ElementAt<TSource>(IQueryable<TSource>, int) method or @@ -894,7 +895,7 @@

Returns

TranslateExcept(ShapedQueryExpression, ShapedQueryExpression) - +

Translates Except<TSource>(IQueryable<TSource>, IEnumerable<TSource>) method over the given source.

@@ -936,7 +937,7 @@

Returns

TranslateFirstOrDefault(ShapedQueryExpression, LambdaExpression?, Type, bool) - +

Translates First<TSource>(IQueryable<TSource>) method or @@ -985,7 +986,7 @@

Returns

TranslateGroupBy(ShapedQueryExpression, LambdaExpression, LambdaExpression?, LambdaExpression?) - +

Translates GroupBy<TSource, TKey>(IQueryable<TSource>, Expression<Func<TSource, TKey>>) method and @@ -1034,7 +1035,7 @@

Returns

TranslateGroupJoin(ShapedQueryExpression, ShapedQueryExpression, LambdaExpression, LambdaExpression, LambdaExpression) - +

Translates @@ -1087,7 +1088,7 @@

Returns

TranslateIntersect(ShapedQueryExpression, ShapedQueryExpression) - +

Translates Intersect<TSource>(IQueryable<TSource>, IEnumerable<TSource>) method over the given source.

@@ -1129,7 +1130,7 @@

Returns

TranslateJoin(ShapedQueryExpression, ShapedQueryExpression, LambdaExpression, LambdaExpression, LambdaExpression) - +

Translates @@ -1182,7 +1183,7 @@

Returns

TranslateLastOrDefault(ShapedQueryExpression, LambdaExpression?, Type, bool) - +

Translates Last<TSource>(IQueryable<TSource>) method or @@ -1231,7 +1232,7 @@

Returns

TranslateLeftJoin(ShapedQueryExpression, ShapedQueryExpression, LambdaExpression, LambdaExpression, LambdaExpression) - +

@@ -1288,7 +1289,7 @@

Returns

TranslateLongCount(ShapedQueryExpression, LambdaExpression?) - +

Translates LongCount<TSource>(IQueryable<TSource>) method and other overloads over the given source.

@@ -1330,7 +1331,7 @@

Returns

TranslateMax(ShapedQueryExpression, LambdaExpression?, Type) - +

Translates Max<TSource>(IQueryable<TSource>) method and other overloads over the given source.

@@ -1375,7 +1376,7 @@

Returns

TranslateMin(ShapedQueryExpression, LambdaExpression?, Type) - +

Translates Min<TSource>(IQueryable<TSource>) method and other overloads over the given source.

@@ -1420,7 +1421,7 @@

Returns

TranslateOfType(ShapedQueryExpression, Type) - +

Translates OfType<TResult>(IQueryable) method over the given source.

@@ -1462,7 +1463,7 @@

Returns

TranslateOrderBy(ShapedQueryExpression, LambdaExpression, bool) - +

Translates OrderBy<TSource, TKey>(IQueryable<TSource>, Expression<Func<TSource, TKey>>) or @@ -1509,7 +1510,7 @@

Returns

TranslateReverse(ShapedQueryExpression) - +

Translates Reverse<TSource>(IQueryable<TSource>) method over the given source.

@@ -1548,7 +1549,7 @@

Returns

TranslateSelect(ShapedQueryExpression, LambdaExpression) - +

Translates Select<TSource, TResult>(IQueryable<TSource>, Expression<Func<TSource, TResult>>) method over the @@ -1591,7 +1592,7 @@

Returns

TranslateSelectMany(ShapedQueryExpression, LambdaExpression) - +

Translates SelectMany<TSource, TResult>(IQueryable<TSource>, Expression<Func<TSource, IEnumerable<TResult>>>) @@ -1634,7 +1635,7 @@

Returns

TranslateSelectMany(ShapedQueryExpression, LambdaExpression, LambdaExpression) - +

Translates @@ -1681,7 +1682,7 @@

Returns

TranslateSingleOrDefault(ShapedQueryExpression, LambdaExpression?, Type, bool) - +

Translates Single<TSource>(IQueryable<TSource>) method or @@ -1731,7 +1732,7 @@

Returns

TranslateSkip(ShapedQueryExpression, Expression) - +

Translates Skip<TSource>(IQueryable<TSource>, int) method over the given source.

@@ -1773,7 +1774,7 @@

Returns

TranslateSkipWhile(ShapedQueryExpression, LambdaExpression) - +

Translates SkipWhile<TSource>(IQueryable<TSource>, Expression<Func<TSource, bool>>) method over the given @@ -1816,7 +1817,7 @@

Returns

TranslateSum(ShapedQueryExpression, LambdaExpression?, Type) - +

Translates Sum(IQueryable<decimal>) method and other overloads over the given source.

@@ -1861,7 +1862,7 @@

Returns

TranslateTake(ShapedQueryExpression, Expression) - +

Translates Take<TSource>(IQueryable<TSource>, int) method over the given source.

@@ -1903,7 +1904,7 @@

Returns

TranslateTakeWhile(ShapedQueryExpression, LambdaExpression) - +

Translates TakeWhile<TSource>(IQueryable<TSource>, Expression<Func<TSource, bool>>) method over the given @@ -1946,7 +1947,7 @@

Returns

TranslateThenBy(ShapedQueryExpression, LambdaExpression, bool) - +

Translates ThenBy<TSource, TKey>(IOrderedQueryable<TSource>, Expression<Func<TSource, TKey>>) or @@ -1993,7 +1994,7 @@

Returns

TranslateUnion(ShapedQueryExpression, ShapedQueryExpression) - +

Translates Union<TSource>(IQueryable<TSource>, IEnumerable<TSource>) method over the given source.

@@ -2035,7 +2036,7 @@

Returns

TranslateWhere(ShapedQueryExpression, LambdaExpression) - +

Translates Where<TSource>(IQueryable<TSource>, Expression<Func<TSource, bool>>) method over the given source.

diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.EntityTypeProducer-4.html b/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.EntityTypeProducer-4.html index 9008f288..93ccf431 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.EntityTypeProducer-4.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.EntityTypeProducer-4.html @@ -214,7 +214,7 @@

Properties

EntityType - +

Associated IEntityType

@@ -246,7 +246,7 @@

Property Value

ValueBuffers - +

The current ValueBuffers

@@ -282,7 +282,7 @@

Methods

Commit(IEnumerable<IKafkaRowBag>) - +

Stores an IEnumerable<T>

@@ -320,7 +320,7 @@

Returns

Dispose() - +

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaCluster.html b/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaCluster.html index 7e5882db..4962b0b2 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaCluster.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaCluster.html @@ -271,7 +271,7 @@

Methods

CreateTable(IEntityType) - +

Creates a table for IEntityType on Apache Kafka cluster

@@ -335,7 +335,7 @@

EnsureConnected(IModel, IDiagnosticsLogger<Update>) - +

Execute the EnsureDatabaseConnected()

@@ -374,7 +374,7 @@

Returns

EnsureCreated(IUpdateAdapterFactory, IModel, IDiagnosticsLogger<Update>) - +

Execute the EnsureDatabaseCreated()

@@ -415,7 +415,7 @@

Returns

EnsureDeleted(IUpdateAdapterFactory, IModel, IDiagnosticsLogger<Update>) - +

Execute the EnsureDatabaseDeleted()

@@ -456,7 +456,7 @@

Returns

ExecuteTransaction(IList<IUpdateEntry>, IDiagnosticsLogger<Update>) - +

Executes a transaction

@@ -537,7 +537,7 @@

Type Parameters

GetValueBuffers(IEntityType) - +

Retrieve the ValueBuffer

diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaTypeMapping.html b/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaTypeMapping.html index 56e6d9b9..f8f2e282 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaTypeMapping.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.Storage.Internal.KafkaTypeMapping.html @@ -87,7 +87,7 @@
Table of Contents

Class KafkaTypeMapping - +

@@ -183,7 +183,7 @@

Constructors

KafkaTypeMapping(Type, ValueComparer?, ValueComparer?) - +

Default initializer

@@ -223,7 +223,7 @@

Methods

Clone(ValueConverter?) - +

Returns a new copy of this type mapping with the given ValueConverter @@ -263,7 +263,7 @@

Returns

diff --git a/docs/api/MASES.EntityFrameworkCore.KNet.ValueGeneration.Internal.KafkaValueGeneratorSelector.html b/docs/api/MASES.EntityFrameworkCore.KNet.ValueGeneration.Internal.KafkaValueGeneratorSelector.html index d2812704..06f5a3be 100644 --- a/docs/api/MASES.EntityFrameworkCore.KNet.ValueGeneration.Internal.KafkaValueGeneratorSelector.html +++ b/docs/api/MASES.EntityFrameworkCore.KNet.ValueGeneration.Internal.KafkaValueGeneratorSelector.html @@ -212,7 +212,7 @@

Methods

Select(IProperty, IEntityType) - +

Selects the appropriate value generator for a given property.

diff --git a/docs/articles/intro.html b/docs/articles/intro.html index a1ce62b4..d00cc0d5 100644 --- a/docs/articles/intro.html +++ b/docs/articles/intro.html @@ -131,7 +131,7 @@

Community and Contribution

  • open issues to request features or report bugs 🐛
  • improves the project with Pull Requests
  • -

    This project adheres to the Contributor Covenant code of conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to coc_reporting@masesgroup.com.

    +

    This project adheres to the Contributor Covenant code of conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to coc_reporting@masesgroup.com.

    diff --git a/docs/index.html b/docs/index.html index a7aa1ef1..4a9f38e5 100644 --- a/docs/index.html +++ b/docs/index.html @@ -128,7 +128,7 @@

    Community and Contribution

  • open issues to request features or report bugs 🐛
  • improves the project with Pull Requests
  • -

    This project adheres to the Contributor Covenant code of conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to coc_reporting@masesgroup.com.

    +

    This project adheres to the Contributor Covenant code of conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to coc_reporting@masesgroup.com.


    Summary

      diff --git a/docs/manifest.json b/docs/manifest.json index ec8c05af..acd1d05d 100644 --- a/docs/manifest.json +++ b/docs/manifest.json @@ -1326,9 +1326,6 @@ "version": "" }, { - "log_codes": [ - "InvalidFileLink" - ], "type": "Conceptual", "source_relative_path": "articles/intro.md", "output": { @@ -1462,9 +1459,6 @@ "version": "" }, { - "log_codes": [ - "InvalidFileLink" - ], "type": "Conceptual", "source_relative_path": "index.md", "output": { diff --git a/docs/public/c4Diagram-d0fbc5ce-BO64XHDH.min.js b/docs/public/c4Diagram-817c8e44-DEM7FJ4Q.min.js similarity index 99% rename from docs/public/c4Diagram-d0fbc5ce-BO64XHDH.min.js rename to docs/public/c4Diagram-817c8e44-DEM7FJ4Q.min.js index bfdc0bb7..aab02ffc 100644 --- a/docs/public/c4Diagram-d0fbc5ce-BO64XHDH.min.js +++ b/docs/public/c4Diagram-817c8e44-DEM7FJ4Q.min.js @@ -1,4 +1,4 @@ -import{a as de,f as fe}from"./chunk-RUC4INDL.min.js";import{$a as ge,Ga as $t,Ia as te,J as Ie,La as Bt,Oa as pe,Ua as ye,Va as ee,Wa as At,b as Be,c as Ye,cb as be,db as _e,eb as xe,fb as me,h as Dt,jb as Ot}from"./chunk-65WDIALL.min.js";import{d as Zt}from"./chunk-P42HNYSU.min.js";var ke=Zt(Ye(),1);var B0=Zt(Be(),1),Y0=Zt(Ie(),1);var It=function(){var e=function(bt,_,x,m){for(x=x||{},m=bt.length;m--;x[bt[m]]=_);return x},t=[1,24],a=[1,25],o=[1,26],l=[1,27],i=[1,28],s=[1,63],r=[1,64],n=[1,65],h=[1,66],f=[1,67],d=[1,68],p=[1,69],E=[1,29],O=[1,30],R=[1,31],S=[1,32],N=[1,33],Y=[1,34],Q=[1,35],H=[1,36],q=[1,37],G=[1,38],K=[1,39],J=[1,40],Z=[1,41],$=[1,42],tt=[1,43],et=[1,44],it=[1,45],nt=[1,46],st=[1,47],at=[1,48],rt=[1,50],lt=[1,51],ot=[1,52],ct=[1,53],ht=[1,54],ut=[1,55],dt=[1,56],ft=[1,57],pt=[1,58],yt=[1,59],gt=[1,60],Ct=[14,42],Xt=[14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],Tt=[12,14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],v=[1,82],k=[1,83],A=[1,84],C=[1,85],w=[12,14,42],oe=[12,14,33,42],Mt=[12,14,33,42,76,77,79,80],mt=[12,33],Wt=[34,36,37,38,39,40,41,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],Qt={trace:function(){},yy:{},symbols_:{error:2,start:3,mermaidDoc:4,direction:5,direction_tb:6,direction_bt:7,direction_rl:8,direction_lr:9,graphConfig:10,C4_CONTEXT:11,NEWLINE:12,statements:13,EOF:14,C4_CONTAINER:15,C4_COMPONENT:16,C4_DYNAMIC:17,C4_DEPLOYMENT:18,otherStatements:19,diagramStatements:20,otherStatement:21,title:22,accDescription:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,boundaryStatement:29,boundaryStartStatement:30,boundaryStopStatement:31,boundaryStart:32,LBRACE:33,ENTERPRISE_BOUNDARY:34,attributes:35,SYSTEM_BOUNDARY:36,BOUNDARY:37,CONTAINER_BOUNDARY:38,NODE:39,NODE_L:40,NODE_R:41,RBRACE:42,diagramStatement:43,PERSON:44,PERSON_EXT:45,SYSTEM:46,SYSTEM_DB:47,SYSTEM_QUEUE:48,SYSTEM_EXT:49,SYSTEM_EXT_DB:50,SYSTEM_EXT_QUEUE:51,CONTAINER:52,CONTAINER_DB:53,CONTAINER_QUEUE:54,CONTAINER_EXT:55,CONTAINER_EXT_DB:56,CONTAINER_EXT_QUEUE:57,COMPONENT:58,COMPONENT_DB:59,COMPONENT_QUEUE:60,COMPONENT_EXT:61,COMPONENT_EXT_DB:62,COMPONENT_EXT_QUEUE:63,REL:64,BIREL:65,REL_U:66,REL_D:67,REL_L:68,REL_R:69,REL_B:70,REL_INDEX:71,UPDATE_EL_STYLE:72,UPDATE_REL_STYLE:73,UPDATE_LAYOUT_CONFIG:74,attribute:75,STR:76,STR_KEY:77,STR_VALUE:78,ATTRIBUTE:79,ATTRIBUTE_EMPTY:80,$accept:0,$end:1},terminals_:{2:"error",6:"direction_tb",7:"direction_bt",8:"direction_rl",9:"direction_lr",11:"C4_CONTEXT",12:"NEWLINE",14:"EOF",15:"C4_CONTAINER",16:"C4_COMPONENT",17:"C4_DYNAMIC",18:"C4_DEPLOYMENT",22:"title",23:"accDescription",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"LBRACE",34:"ENTERPRISE_BOUNDARY",36:"SYSTEM_BOUNDARY",37:"BOUNDARY",38:"CONTAINER_BOUNDARY",39:"NODE",40:"NODE_L",41:"NODE_R",42:"RBRACE",44:"PERSON",45:"PERSON_EXT",46:"SYSTEM",47:"SYSTEM_DB",48:"SYSTEM_QUEUE",49:"SYSTEM_EXT",50:"SYSTEM_EXT_DB",51:"SYSTEM_EXT_QUEUE",52:"CONTAINER",53:"CONTAINER_DB",54:"CONTAINER_QUEUE",55:"CONTAINER_EXT",56:"CONTAINER_EXT_DB",57:"CONTAINER_EXT_QUEUE",58:"COMPONENT",59:"COMPONENT_DB",60:"COMPONENT_QUEUE",61:"COMPONENT_EXT",62:"COMPONENT_EXT_DB",63:"COMPONENT_EXT_QUEUE",64:"REL",65:"BIREL",66:"REL_U",67:"REL_D",68:"REL_L",69:"REL_R",70:"REL_B",71:"REL_INDEX",72:"UPDATE_EL_STYLE",73:"UPDATE_REL_STYLE",74:"UPDATE_LAYOUT_CONFIG",76:"STR",77:"STR_KEY",78:"STR_VALUE",79:"ATTRIBUTE",80:"ATTRIBUTE_EMPTY"},productions_:[0,[3,1],[3,1],[5,1],[5,1],[5,1],[5,1],[4,1],[10,4],[10,4],[10,4],[10,4],[10,4],[13,1],[13,1],[13,2],[19,1],[19,2],[19,3],[21,1],[21,1],[21,2],[21,2],[21,1],[29,3],[30,3],[30,3],[30,4],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[31,1],[20,1],[20,2],[20,3],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,1],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[35,1],[35,2],[75,1],[75,2],[75,1],[75,1]],performAction:function(_,x,m,g,T,u,Rt){var y=u.length-1;switch(T){case 3:g.setDirection("TB");break;case 4:g.setDirection("BT");break;case 5:g.setDirection("RL");break;case 6:g.setDirection("LR");break;case 8:case 9:case 10:case 11:case 12:g.setC4Type(u[y-3]);break;case 19:g.setTitle(u[y].substring(6)),this.$=u[y].substring(6);break;case 20:g.setAccDescription(u[y].substring(15)),this.$=u[y].substring(15);break;case 21:this.$=u[y].trim(),g.setTitle(this.$);break;case 22:case 23:this.$=u[y].trim(),g.setAccDescription(this.$);break;case 28:case 29:u[y].splice(2,0,"ENTERPRISE"),g.addPersonOrSystemBoundary(...u[y]),this.$=u[y];break;case 30:g.addPersonOrSystemBoundary(...u[y]),this.$=u[y];break;case 31:u[y].splice(2,0,"CONTAINER"),g.addContainerBoundary(...u[y]),this.$=u[y];break;case 32:g.addDeploymentNode("node",...u[y]),this.$=u[y];break;case 33:g.addDeploymentNode("nodeL",...u[y]),this.$=u[y];break;case 34:g.addDeploymentNode("nodeR",...u[y]),this.$=u[y];break;case 35:g.popBoundaryParseStack();break;case 39:g.addPersonOrSystem("person",...u[y]),this.$=u[y];break;case 40:g.addPersonOrSystem("external_person",...u[y]),this.$=u[y];break;case 41:g.addPersonOrSystem("system",...u[y]),this.$=u[y];break;case 42:g.addPersonOrSystem("system_db",...u[y]),this.$=u[y];break;case 43:g.addPersonOrSystem("system_queue",...u[y]),this.$=u[y];break;case 44:g.addPersonOrSystem("external_system",...u[y]),this.$=u[y];break;case 45:g.addPersonOrSystem("external_system_db",...u[y]),this.$=u[y];break;case 46:g.addPersonOrSystem("external_system_queue",...u[y]),this.$=u[y];break;case 47:g.addContainer("container",...u[y]),this.$=u[y];break;case 48:g.addContainer("container_db",...u[y]),this.$=u[y];break;case 49:g.addContainer("container_queue",...u[y]),this.$=u[y];break;case 50:g.addContainer("external_container",...u[y]),this.$=u[y];break;case 51:g.addContainer("external_container_db",...u[y]),this.$=u[y];break;case 52:g.addContainer("external_container_queue",...u[y]),this.$=u[y];break;case 53:g.addComponent("component",...u[y]),this.$=u[y];break;case 54:g.addComponent("component_db",...u[y]),this.$=u[y];break;case 55:g.addComponent("component_queue",...u[y]),this.$=u[y];break;case 56:g.addComponent("external_component",...u[y]),this.$=u[y];break;case 57:g.addComponent("external_component_db",...u[y]),this.$=u[y];break;case 58:g.addComponent("external_component_queue",...u[y]),this.$=u[y];break;case 60:g.addRel("rel",...u[y]),this.$=u[y];break;case 61:g.addRel("birel",...u[y]),this.$=u[y];break;case 62:g.addRel("rel_u",...u[y]),this.$=u[y];break;case 63:g.addRel("rel_d",...u[y]),this.$=u[y];break;case 64:g.addRel("rel_l",...u[y]),this.$=u[y];break;case 65:g.addRel("rel_r",...u[y]),this.$=u[y];break;case 66:g.addRel("rel_b",...u[y]),this.$=u[y];break;case 67:u[y].splice(0,1),g.addRel("rel",...u[y]),this.$=u[y];break;case 68:g.updateElStyle("update_el_style",...u[y]),this.$=u[y];break;case 69:g.updateRelStyle("update_rel_style",...u[y]),this.$=u[y];break;case 70:g.updateLayoutConfig("update_layout_config",...u[y]),this.$=u[y];break;case 71:this.$=[u[y]];break;case 72:u[y].unshift(u[y-1]),this.$=u[y];break;case 73:case 75:this.$=u[y].trim();break;case 74:let Et={};Et[u[y-1].trim()]=u[y].trim(),this.$=Et;break;case 76:this.$="";break}},table:[{3:1,4:2,5:3,6:[1,5],7:[1,6],8:[1,7],9:[1,8],10:4,11:[1,9],15:[1,10],16:[1,11],17:[1,12],18:[1,13]},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,7]},{1:[2,3]},{1:[2,4]},{1:[2,5]},{1:[2,6]},{12:[1,14]},{12:[1,15]},{12:[1,16]},{12:[1,17]},{12:[1,18]},{13:19,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:70,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:71,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:72,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:73,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{14:[1,74]},e(Ct,[2,13],{43:23,29:49,30:61,32:62,20:75,34:s,36:r,37:n,38:h,39:f,40:d,41:p,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt}),e(Ct,[2,14]),e(Xt,[2,16],{12:[1,76]}),e(Ct,[2,36],{12:[1,77]}),e(Tt,[2,19]),e(Tt,[2,20]),{25:[1,78]},{27:[1,79]},e(Tt,[2,23]),{35:80,75:81,76:v,77:k,79:A,80:C},{35:86,75:81,76:v,77:k,79:A,80:C},{35:87,75:81,76:v,77:k,79:A,80:C},{35:88,75:81,76:v,77:k,79:A,80:C},{35:89,75:81,76:v,77:k,79:A,80:C},{35:90,75:81,76:v,77:k,79:A,80:C},{35:91,75:81,76:v,77:k,79:A,80:C},{35:92,75:81,76:v,77:k,79:A,80:C},{35:93,75:81,76:v,77:k,79:A,80:C},{35:94,75:81,76:v,77:k,79:A,80:C},{35:95,75:81,76:v,77:k,79:A,80:C},{35:96,75:81,76:v,77:k,79:A,80:C},{35:97,75:81,76:v,77:k,79:A,80:C},{35:98,75:81,76:v,77:k,79:A,80:C},{35:99,75:81,76:v,77:k,79:A,80:C},{35:100,75:81,76:v,77:k,79:A,80:C},{35:101,75:81,76:v,77:k,79:A,80:C},{35:102,75:81,76:v,77:k,79:A,80:C},{35:103,75:81,76:v,77:k,79:A,80:C},{35:104,75:81,76:v,77:k,79:A,80:C},e(w,[2,59]),{35:105,75:81,76:v,77:k,79:A,80:C},{35:106,75:81,76:v,77:k,79:A,80:C},{35:107,75:81,76:v,77:k,79:A,80:C},{35:108,75:81,76:v,77:k,79:A,80:C},{35:109,75:81,76:v,77:k,79:A,80:C},{35:110,75:81,76:v,77:k,79:A,80:C},{35:111,75:81,76:v,77:k,79:A,80:C},{35:112,75:81,76:v,77:k,79:A,80:C},{35:113,75:81,76:v,77:k,79:A,80:C},{35:114,75:81,76:v,77:k,79:A,80:C},{35:115,75:81,76:v,77:k,79:A,80:C},{20:116,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{12:[1,118],33:[1,117]},{35:119,75:81,76:v,77:k,79:A,80:C},{35:120,75:81,76:v,77:k,79:A,80:C},{35:121,75:81,76:v,77:k,79:A,80:C},{35:122,75:81,76:v,77:k,79:A,80:C},{35:123,75:81,76:v,77:k,79:A,80:C},{35:124,75:81,76:v,77:k,79:A,80:C},{35:125,75:81,76:v,77:k,79:A,80:C},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},e(Ct,[2,15]),e(Xt,[2,17],{21:22,19:130,22:t,23:a,24:o,26:l,28:i}),e(Ct,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:t,23:a,24:o,26:l,28:i,34:s,36:r,37:n,38:h,39:f,40:d,41:p,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt}),e(Tt,[2,21]),e(Tt,[2,22]),e(w,[2,39]),e(oe,[2,71],{75:81,35:132,76:v,77:k,79:A,80:C}),e(Mt,[2,73]),{78:[1,133]},e(Mt,[2,75]),e(Mt,[2,76]),e(w,[2,40]),e(w,[2,41]),e(w,[2,42]),e(w,[2,43]),e(w,[2,44]),e(w,[2,45]),e(w,[2,46]),e(w,[2,47]),e(w,[2,48]),e(w,[2,49]),e(w,[2,50]),e(w,[2,51]),e(w,[2,52]),e(w,[2,53]),e(w,[2,54]),e(w,[2,55]),e(w,[2,56]),e(w,[2,57]),e(w,[2,58]),e(w,[2,60]),e(w,[2,61]),e(w,[2,62]),e(w,[2,63]),e(w,[2,64]),e(w,[2,65]),e(w,[2,66]),e(w,[2,67]),e(w,[2,68]),e(w,[2,69]),e(w,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},e(mt,[2,28]),e(mt,[2,29]),e(mt,[2,30]),e(mt,[2,31]),e(mt,[2,32]),e(mt,[2,33]),e(mt,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},e(Xt,[2,18]),e(Ct,[2,38]),e(oe,[2,72]),e(Mt,[2,74]),e(w,[2,24]),e(w,[2,35]),e(Wt,[2,25]),e(Wt,[2,26],{12:[1,138]}),e(Wt,[2,27])],defaultActions:{2:[2,1],3:[2,2],4:[2,7],5:[2,3],6:[2,4],7:[2,5],8:[2,6],74:[2,8],126:[2,9],127:[2,10],128:[2,11],129:[2,12]},parseError:function(_,x){if(x.recoverable)this.trace(_);else{var m=new Error(_);throw m.hash=x,m}},parse:function(_){var x=this,m=[0],g=[],T=[null],u=[],Rt=this.table,y="",Et=0,ce=0,Pe=2,he=1,Me=u.slice.call(arguments,1),D=Object.create(this.lexer),vt={yy:{}};for(var qt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,qt)&&(vt.yy[qt]=this.yy[qt]);D.setInput(_,vt.yy),vt.yy.lexer=D,vt.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var Gt=D.yylloc;u.push(Gt);var Le=D.options&&D.options.ranges;typeof vt.yy.parseError=="function"?this.parseError=vt.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Ne(){var X;return X=g.pop()||D.lex()||he,typeof X!="number"&&(X instanceof Array&&(g=X,X=g.pop()),X=x.symbols_[X]||X),X}for(var M,kt,B,Kt,wt={},Lt,z,ue,Nt;;){if(kt=m[m.length-1],this.defaultActions[kt]?B=this.defaultActions[kt]:((M===null||typeof M>"u")&&(M=Ne()),B=Rt[kt]&&Rt[kt][M]),typeof B>"u"||!B.length||!B[0]){var Jt="";Nt=[];for(Lt in Rt[kt])this.terminals_[Lt]&&Lt>Pe&&Nt.push("'"+this.terminals_[Lt]+"'");D.showPosition?Jt="Parse error on line "+(Et+1)+`: +import{a as de,f as fe}from"./chunk-OZIWJXOC.min.js";import{$a as ge,Ga as $t,Ia as te,J as Ie,La as Bt,Oa as pe,Ua as ye,Va as ee,Wa as At,b as Be,c as Ye,cb as be,db as _e,eb as xe,fb as me,h as Dt,jb as Ot}from"./chunk-JUXSCBYR.min.js";import{d as Zt}from"./chunk-P42HNYSU.min.js";var ke=Zt(Ye(),1);var B0=Zt(Be(),1),Y0=Zt(Ie(),1);var It=function(){var e=function(bt,_,x,m){for(x=x||{},m=bt.length;m--;x[bt[m]]=_);return x},t=[1,24],a=[1,25],o=[1,26],l=[1,27],i=[1,28],s=[1,63],r=[1,64],n=[1,65],h=[1,66],f=[1,67],d=[1,68],p=[1,69],E=[1,29],O=[1,30],R=[1,31],S=[1,32],N=[1,33],Y=[1,34],Q=[1,35],H=[1,36],q=[1,37],G=[1,38],K=[1,39],J=[1,40],Z=[1,41],$=[1,42],tt=[1,43],et=[1,44],it=[1,45],nt=[1,46],st=[1,47],at=[1,48],rt=[1,50],lt=[1,51],ot=[1,52],ct=[1,53],ht=[1,54],ut=[1,55],dt=[1,56],ft=[1,57],pt=[1,58],yt=[1,59],gt=[1,60],Ct=[14,42],Xt=[14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],Tt=[12,14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],v=[1,82],k=[1,83],A=[1,84],C=[1,85],w=[12,14,42],oe=[12,14,33,42],Mt=[12,14,33,42,76,77,79,80],mt=[12,33],Wt=[34,36,37,38,39,40,41,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],Qt={trace:function(){},yy:{},symbols_:{error:2,start:3,mermaidDoc:4,direction:5,direction_tb:6,direction_bt:7,direction_rl:8,direction_lr:9,graphConfig:10,C4_CONTEXT:11,NEWLINE:12,statements:13,EOF:14,C4_CONTAINER:15,C4_COMPONENT:16,C4_DYNAMIC:17,C4_DEPLOYMENT:18,otherStatements:19,diagramStatements:20,otherStatement:21,title:22,accDescription:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,boundaryStatement:29,boundaryStartStatement:30,boundaryStopStatement:31,boundaryStart:32,LBRACE:33,ENTERPRISE_BOUNDARY:34,attributes:35,SYSTEM_BOUNDARY:36,BOUNDARY:37,CONTAINER_BOUNDARY:38,NODE:39,NODE_L:40,NODE_R:41,RBRACE:42,diagramStatement:43,PERSON:44,PERSON_EXT:45,SYSTEM:46,SYSTEM_DB:47,SYSTEM_QUEUE:48,SYSTEM_EXT:49,SYSTEM_EXT_DB:50,SYSTEM_EXT_QUEUE:51,CONTAINER:52,CONTAINER_DB:53,CONTAINER_QUEUE:54,CONTAINER_EXT:55,CONTAINER_EXT_DB:56,CONTAINER_EXT_QUEUE:57,COMPONENT:58,COMPONENT_DB:59,COMPONENT_QUEUE:60,COMPONENT_EXT:61,COMPONENT_EXT_DB:62,COMPONENT_EXT_QUEUE:63,REL:64,BIREL:65,REL_U:66,REL_D:67,REL_L:68,REL_R:69,REL_B:70,REL_INDEX:71,UPDATE_EL_STYLE:72,UPDATE_REL_STYLE:73,UPDATE_LAYOUT_CONFIG:74,attribute:75,STR:76,STR_KEY:77,STR_VALUE:78,ATTRIBUTE:79,ATTRIBUTE_EMPTY:80,$accept:0,$end:1},terminals_:{2:"error",6:"direction_tb",7:"direction_bt",8:"direction_rl",9:"direction_lr",11:"C4_CONTEXT",12:"NEWLINE",14:"EOF",15:"C4_CONTAINER",16:"C4_COMPONENT",17:"C4_DYNAMIC",18:"C4_DEPLOYMENT",22:"title",23:"accDescription",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"LBRACE",34:"ENTERPRISE_BOUNDARY",36:"SYSTEM_BOUNDARY",37:"BOUNDARY",38:"CONTAINER_BOUNDARY",39:"NODE",40:"NODE_L",41:"NODE_R",42:"RBRACE",44:"PERSON",45:"PERSON_EXT",46:"SYSTEM",47:"SYSTEM_DB",48:"SYSTEM_QUEUE",49:"SYSTEM_EXT",50:"SYSTEM_EXT_DB",51:"SYSTEM_EXT_QUEUE",52:"CONTAINER",53:"CONTAINER_DB",54:"CONTAINER_QUEUE",55:"CONTAINER_EXT",56:"CONTAINER_EXT_DB",57:"CONTAINER_EXT_QUEUE",58:"COMPONENT",59:"COMPONENT_DB",60:"COMPONENT_QUEUE",61:"COMPONENT_EXT",62:"COMPONENT_EXT_DB",63:"COMPONENT_EXT_QUEUE",64:"REL",65:"BIREL",66:"REL_U",67:"REL_D",68:"REL_L",69:"REL_R",70:"REL_B",71:"REL_INDEX",72:"UPDATE_EL_STYLE",73:"UPDATE_REL_STYLE",74:"UPDATE_LAYOUT_CONFIG",76:"STR",77:"STR_KEY",78:"STR_VALUE",79:"ATTRIBUTE",80:"ATTRIBUTE_EMPTY"},productions_:[0,[3,1],[3,1],[5,1],[5,1],[5,1],[5,1],[4,1],[10,4],[10,4],[10,4],[10,4],[10,4],[13,1],[13,1],[13,2],[19,1],[19,2],[19,3],[21,1],[21,1],[21,2],[21,2],[21,1],[29,3],[30,3],[30,3],[30,4],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[31,1],[20,1],[20,2],[20,3],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,1],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[35,1],[35,2],[75,1],[75,2],[75,1],[75,1]],performAction:function(_,x,m,g,T,u,Rt){var y=u.length-1;switch(T){case 3:g.setDirection("TB");break;case 4:g.setDirection("BT");break;case 5:g.setDirection("RL");break;case 6:g.setDirection("LR");break;case 8:case 9:case 10:case 11:case 12:g.setC4Type(u[y-3]);break;case 19:g.setTitle(u[y].substring(6)),this.$=u[y].substring(6);break;case 20:g.setAccDescription(u[y].substring(15)),this.$=u[y].substring(15);break;case 21:this.$=u[y].trim(),g.setTitle(this.$);break;case 22:case 23:this.$=u[y].trim(),g.setAccDescription(this.$);break;case 28:case 29:u[y].splice(2,0,"ENTERPRISE"),g.addPersonOrSystemBoundary(...u[y]),this.$=u[y];break;case 30:g.addPersonOrSystemBoundary(...u[y]),this.$=u[y];break;case 31:u[y].splice(2,0,"CONTAINER"),g.addContainerBoundary(...u[y]),this.$=u[y];break;case 32:g.addDeploymentNode("node",...u[y]),this.$=u[y];break;case 33:g.addDeploymentNode("nodeL",...u[y]),this.$=u[y];break;case 34:g.addDeploymentNode("nodeR",...u[y]),this.$=u[y];break;case 35:g.popBoundaryParseStack();break;case 39:g.addPersonOrSystem("person",...u[y]),this.$=u[y];break;case 40:g.addPersonOrSystem("external_person",...u[y]),this.$=u[y];break;case 41:g.addPersonOrSystem("system",...u[y]),this.$=u[y];break;case 42:g.addPersonOrSystem("system_db",...u[y]),this.$=u[y];break;case 43:g.addPersonOrSystem("system_queue",...u[y]),this.$=u[y];break;case 44:g.addPersonOrSystem("external_system",...u[y]),this.$=u[y];break;case 45:g.addPersonOrSystem("external_system_db",...u[y]),this.$=u[y];break;case 46:g.addPersonOrSystem("external_system_queue",...u[y]),this.$=u[y];break;case 47:g.addContainer("container",...u[y]),this.$=u[y];break;case 48:g.addContainer("container_db",...u[y]),this.$=u[y];break;case 49:g.addContainer("container_queue",...u[y]),this.$=u[y];break;case 50:g.addContainer("external_container",...u[y]),this.$=u[y];break;case 51:g.addContainer("external_container_db",...u[y]),this.$=u[y];break;case 52:g.addContainer("external_container_queue",...u[y]),this.$=u[y];break;case 53:g.addComponent("component",...u[y]),this.$=u[y];break;case 54:g.addComponent("component_db",...u[y]),this.$=u[y];break;case 55:g.addComponent("component_queue",...u[y]),this.$=u[y];break;case 56:g.addComponent("external_component",...u[y]),this.$=u[y];break;case 57:g.addComponent("external_component_db",...u[y]),this.$=u[y];break;case 58:g.addComponent("external_component_queue",...u[y]),this.$=u[y];break;case 60:g.addRel("rel",...u[y]),this.$=u[y];break;case 61:g.addRel("birel",...u[y]),this.$=u[y];break;case 62:g.addRel("rel_u",...u[y]),this.$=u[y];break;case 63:g.addRel("rel_d",...u[y]),this.$=u[y];break;case 64:g.addRel("rel_l",...u[y]),this.$=u[y];break;case 65:g.addRel("rel_r",...u[y]),this.$=u[y];break;case 66:g.addRel("rel_b",...u[y]),this.$=u[y];break;case 67:u[y].splice(0,1),g.addRel("rel",...u[y]),this.$=u[y];break;case 68:g.updateElStyle("update_el_style",...u[y]),this.$=u[y];break;case 69:g.updateRelStyle("update_rel_style",...u[y]),this.$=u[y];break;case 70:g.updateLayoutConfig("update_layout_config",...u[y]),this.$=u[y];break;case 71:this.$=[u[y]];break;case 72:u[y].unshift(u[y-1]),this.$=u[y];break;case 73:case 75:this.$=u[y].trim();break;case 74:let Et={};Et[u[y-1].trim()]=u[y].trim(),this.$=Et;break;case 76:this.$="";break}},table:[{3:1,4:2,5:3,6:[1,5],7:[1,6],8:[1,7],9:[1,8],10:4,11:[1,9],15:[1,10],16:[1,11],17:[1,12],18:[1,13]},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,7]},{1:[2,3]},{1:[2,4]},{1:[2,5]},{1:[2,6]},{12:[1,14]},{12:[1,15]},{12:[1,16]},{12:[1,17]},{12:[1,18]},{13:19,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:70,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:71,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:72,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{13:73,19:20,20:21,21:22,22:t,23:a,24:o,26:l,28:i,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{14:[1,74]},e(Ct,[2,13],{43:23,29:49,30:61,32:62,20:75,34:s,36:r,37:n,38:h,39:f,40:d,41:p,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt}),e(Ct,[2,14]),e(Xt,[2,16],{12:[1,76]}),e(Ct,[2,36],{12:[1,77]}),e(Tt,[2,19]),e(Tt,[2,20]),{25:[1,78]},{27:[1,79]},e(Tt,[2,23]),{35:80,75:81,76:v,77:k,79:A,80:C},{35:86,75:81,76:v,77:k,79:A,80:C},{35:87,75:81,76:v,77:k,79:A,80:C},{35:88,75:81,76:v,77:k,79:A,80:C},{35:89,75:81,76:v,77:k,79:A,80:C},{35:90,75:81,76:v,77:k,79:A,80:C},{35:91,75:81,76:v,77:k,79:A,80:C},{35:92,75:81,76:v,77:k,79:A,80:C},{35:93,75:81,76:v,77:k,79:A,80:C},{35:94,75:81,76:v,77:k,79:A,80:C},{35:95,75:81,76:v,77:k,79:A,80:C},{35:96,75:81,76:v,77:k,79:A,80:C},{35:97,75:81,76:v,77:k,79:A,80:C},{35:98,75:81,76:v,77:k,79:A,80:C},{35:99,75:81,76:v,77:k,79:A,80:C},{35:100,75:81,76:v,77:k,79:A,80:C},{35:101,75:81,76:v,77:k,79:A,80:C},{35:102,75:81,76:v,77:k,79:A,80:C},{35:103,75:81,76:v,77:k,79:A,80:C},{35:104,75:81,76:v,77:k,79:A,80:C},e(w,[2,59]),{35:105,75:81,76:v,77:k,79:A,80:C},{35:106,75:81,76:v,77:k,79:A,80:C},{35:107,75:81,76:v,77:k,79:A,80:C},{35:108,75:81,76:v,77:k,79:A,80:C},{35:109,75:81,76:v,77:k,79:A,80:C},{35:110,75:81,76:v,77:k,79:A,80:C},{35:111,75:81,76:v,77:k,79:A,80:C},{35:112,75:81,76:v,77:k,79:A,80:C},{35:113,75:81,76:v,77:k,79:A,80:C},{35:114,75:81,76:v,77:k,79:A,80:C},{35:115,75:81,76:v,77:k,79:A,80:C},{20:116,29:49,30:61,32:62,34:s,36:r,37:n,38:h,39:f,40:d,41:p,43:23,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt},{12:[1,118],33:[1,117]},{35:119,75:81,76:v,77:k,79:A,80:C},{35:120,75:81,76:v,77:k,79:A,80:C},{35:121,75:81,76:v,77:k,79:A,80:C},{35:122,75:81,76:v,77:k,79:A,80:C},{35:123,75:81,76:v,77:k,79:A,80:C},{35:124,75:81,76:v,77:k,79:A,80:C},{35:125,75:81,76:v,77:k,79:A,80:C},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},e(Ct,[2,15]),e(Xt,[2,17],{21:22,19:130,22:t,23:a,24:o,26:l,28:i}),e(Ct,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:t,23:a,24:o,26:l,28:i,34:s,36:r,37:n,38:h,39:f,40:d,41:p,44:E,45:O,46:R,47:S,48:N,49:Y,50:Q,51:H,52:q,53:G,54:K,55:J,56:Z,57:$,58:tt,59:et,60:it,61:nt,62:st,63:at,64:rt,65:lt,66:ot,67:ct,68:ht,69:ut,70:dt,71:ft,72:pt,73:yt,74:gt}),e(Tt,[2,21]),e(Tt,[2,22]),e(w,[2,39]),e(oe,[2,71],{75:81,35:132,76:v,77:k,79:A,80:C}),e(Mt,[2,73]),{78:[1,133]},e(Mt,[2,75]),e(Mt,[2,76]),e(w,[2,40]),e(w,[2,41]),e(w,[2,42]),e(w,[2,43]),e(w,[2,44]),e(w,[2,45]),e(w,[2,46]),e(w,[2,47]),e(w,[2,48]),e(w,[2,49]),e(w,[2,50]),e(w,[2,51]),e(w,[2,52]),e(w,[2,53]),e(w,[2,54]),e(w,[2,55]),e(w,[2,56]),e(w,[2,57]),e(w,[2,58]),e(w,[2,60]),e(w,[2,61]),e(w,[2,62]),e(w,[2,63]),e(w,[2,64]),e(w,[2,65]),e(w,[2,66]),e(w,[2,67]),e(w,[2,68]),e(w,[2,69]),e(w,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},e(mt,[2,28]),e(mt,[2,29]),e(mt,[2,30]),e(mt,[2,31]),e(mt,[2,32]),e(mt,[2,33]),e(mt,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},e(Xt,[2,18]),e(Ct,[2,38]),e(oe,[2,72]),e(Mt,[2,74]),e(w,[2,24]),e(w,[2,35]),e(Wt,[2,25]),e(Wt,[2,26],{12:[1,138]}),e(Wt,[2,27])],defaultActions:{2:[2,1],3:[2,2],4:[2,7],5:[2,3],6:[2,4],7:[2,5],8:[2,6],74:[2,8],126:[2,9],127:[2,10],128:[2,11],129:[2,12]},parseError:function(_,x){if(x.recoverable)this.trace(_);else{var m=new Error(_);throw m.hash=x,m}},parse:function(_){var x=this,m=[0],g=[],T=[null],u=[],Rt=this.table,y="",Et=0,ce=0,Pe=2,he=1,Me=u.slice.call(arguments,1),D=Object.create(this.lexer),vt={yy:{}};for(var qt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,qt)&&(vt.yy[qt]=this.yy[qt]);D.setInput(_,vt.yy),vt.yy.lexer=D,vt.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var Gt=D.yylloc;u.push(Gt);var Le=D.options&&D.options.ranges;typeof vt.yy.parseError=="function"?this.parseError=vt.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Ne(){var X;return X=g.pop()||D.lex()||he,typeof X!="number"&&(X instanceof Array&&(g=X,X=g.pop()),X=x.symbols_[X]||X),X}for(var M,kt,B,Kt,wt={},Lt,z,ue,Nt;;){if(kt=m[m.length-1],this.defaultActions[kt]?B=this.defaultActions[kt]:((M===null||typeof M>"u")&&(M=Ne()),B=Rt[kt]&&Rt[kt][M]),typeof B>"u"||!B.length||!B[0]){var Jt="";Nt=[];for(Lt in Rt[kt])this.terminals_[Lt]&&Lt>Pe&&Nt.push("'"+this.terminals_[Lt]+"'");D.showPosition?Jt="Parse error on line "+(Et+1)+`: `+D.showPosition()+` Expecting `+Nt.join(", ")+", got '"+(this.terminals_[M]||M)+"'":Jt="Parse error on line "+(Et+1)+": Unexpected "+(M==he?"end of input":"'"+(this.terminals_[M]||M)+"'"),this.parseError(Jt,{text:D.match,token:this.terminals_[M]||M,line:D.yylineno,loc:Gt,expected:Nt})}if(B[0]instanceof Array&&B.length>1)throw new Error("Parse Error: multiple actions possible at state: "+kt+", token: "+M);switch(B[0]){case 1:m.push(M),T.push(D.yytext),u.push(D.yylloc),m.push(B[1]),M=null,ce=D.yyleng,y=D.yytext,Et=D.yylineno,Gt=D.yylloc;break;case 2:if(z=this.productions_[B[1]][1],wt.$=T[T.length-z],wt._$={first_line:u[u.length-(z||1)].first_line,last_line:u[u.length-1].last_line,first_column:u[u.length-(z||1)].first_column,last_column:u[u.length-1].last_column},Le&&(wt._$.range=[u[u.length-(z||1)].range[0],u[u.length-1].range[1]]),Kt=this.performAction.apply(wt,[y,ce,Et,vt.yy,B[1],T,u].concat(Me)),typeof Kt<"u")return Kt;z&&(m=m.slice(0,-1*z*2),T=T.slice(0,-1*z),u=u.slice(0,-1*z)),m.push(this.productions_[B[1]][0]),T.push(wt.$),u.push(wt._$),ue=Rt[m[m.length-2]][m[m.length-1]],m.push(ue);break;case 3:return!0}}return!0}},Se=function(){var bt={EOF:1,parseError:function(x,m){if(this.yy.parser)this.yy.parser.parseError(x,m);else throw new Error(x)},setInput:function(_,x){return this.yy=x||this.yy||{},this._input=_,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var _=this._input[0];this.yytext+=_,this.yyleng++,this.offset++,this.match+=_,this.matched+=_;var x=_.match(/(?:\r\n?|\n).*/g);return x?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),_},unput:function(_){var x=_.length,m=_.split(/(?:\r\n?|\n)/g);this._input=_+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-x),this.offset-=x;var g=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),m.length-1&&(this.yylineno-=m.length-1);var T=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:m?(m.length===g.length?this.yylloc.first_column:0)+g[g.length-m.length].length-m[0].length:this.yylloc.first_column-x},this.options.ranges&&(this.yylloc.range=[T[0],T[0]+this.yyleng-x]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(_){this.unput(this.match.slice(_))},pastInput:function(){var _=this.matched.substr(0,this.matched.length-this.match.length);return(_.length>20?"...":"")+_.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var _=this.match;return _.length<20&&(_+=this._input.substr(0,20-_.length)),(_.substr(0,20)+(_.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var _=this.pastInput(),x=new Array(_.length+1).join("-");return _+this.upcomingInput()+` @@ -8,4 +8,4 @@ Expecting `+Nt.join(", ")+", got '"+(this.terminals_[M]||M)+"'":Jt="Parse error fill: ${e.personBkg}; } `,S0=D0,I0={parser:je,db:ie,renderer:ve,styles:S0,init:({c4:e,wrap:t})=>{ve.setConf(e),ie.setWrap(t)}};export{I0 as diagram}; -//# sourceMappingURL=c4Diagram-d0fbc5ce-BO64XHDH.min.js.map +//# sourceMappingURL=c4Diagram-817c8e44-DEM7FJ4Q.min.js.map diff --git a/docs/public/c4Diagram-d0fbc5ce-BO64XHDH.min.js.map b/docs/public/c4Diagram-817c8e44-DEM7FJ4Q.min.js.map similarity index 99% rename from docs/public/c4Diagram-d0fbc5ce-BO64XHDH.min.js.map rename to docs/public/c4Diagram-817c8e44-DEM7FJ4Q.min.js.map index 9bfb1dd5..2a86994f 100644 --- a/docs/public/c4Diagram-d0fbc5ce-BO64XHDH.min.js.map +++ b/docs/public/c4Diagram-817c8e44-DEM7FJ4Q.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/c4Diagram-d0fbc5ce.js"], - "sourcesContent": ["import { s as setAccTitle, g as getAccTitle, a as getAccDescription, b as setAccDescription, c as getConfig, d as sanitizeText, e as common, f as assignWithDepth, h as calculateTextWidth, l as log, i as configureSvgSize, w as wrapLabel, j as calculateTextHeight } from \"./mermaid-8af3addd.js\";\nimport { select } from \"d3\";\nimport { d as drawRect$1, g as getNoteRect } from \"./svgDrawCommon-4835440b.js\";\nimport { sanitizeUrl } from \"@braintree/sanitize-url\";\nimport \"ts-dedent\";\nimport \"dayjs\";\nimport \"dompurify\";\nimport \"khroma\";\nimport \"lodash-es/memoize.js\";\nimport \"lodash-es/merge.js\";\nimport \"stylis\";\nimport \"lodash-es/isEmpty.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 24], $V1 = [1, 25], $V2 = [1, 26], $V3 = [1, 27], $V4 = [1, 28], $V5 = [1, 63], $V6 = [1, 64], $V7 = [1, 65], $V8 = [1, 66], $V9 = [1, 67], $Va = [1, 68], $Vb = [1, 69], $Vc = [1, 29], $Vd = [1, 30], $Ve = [1, 31], $Vf = [1, 32], $Vg = [1, 33], $Vh = [1, 34], $Vi = [1, 35], $Vj = [1, 36], $Vk = [1, 37], $Vl = [1, 38], $Vm = [1, 39], $Vn = [1, 40], $Vo = [1, 41], $Vp = [1, 42], $Vq = [1, 43], $Vr = [1, 44], $Vs = [1, 45], $Vt = [1, 46], $Vu = [1, 47], $Vv = [1, 48], $Vw = [1, 50], $Vx = [1, 51], $Vy = [1, 52], $Vz = [1, 53], $VA = [1, 54], $VB = [1, 55], $VC = [1, 56], $VD = [1, 57], $VE = [1, 58], $VF = [1, 59], $VG = [1, 60], $VH = [14, 42], $VI = [14, 34, 36, 37, 38, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74], $VJ = [12, 14, 34, 36, 37, 38, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74], $VK = [1, 82], $VL = [1, 83], $VM = [1, 84], $VN = [1, 85], $VO = [12, 14, 42], $VP = [12, 14, 33, 42], $VQ = [12, 14, 33, 42, 76, 77, 79, 80], $VR = [12, 33], $VS = [34, 36, 37, 38, 39, 40, 41, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"mermaidDoc\": 4, \"direction\": 5, \"direction_tb\": 6, \"direction_bt\": 7, \"direction_rl\": 8, \"direction_lr\": 9, \"graphConfig\": 10, \"C4_CONTEXT\": 11, \"NEWLINE\": 12, \"statements\": 13, \"EOF\": 14, \"C4_CONTAINER\": 15, \"C4_COMPONENT\": 16, \"C4_DYNAMIC\": 17, \"C4_DEPLOYMENT\": 18, \"otherStatements\": 19, \"diagramStatements\": 20, \"otherStatement\": 21, \"title\": 22, \"accDescription\": 23, \"acc_title\": 24, \"acc_title_value\": 25, \"acc_descr\": 26, \"acc_descr_value\": 27, \"acc_descr_multiline_value\": 28, \"boundaryStatement\": 29, \"boundaryStartStatement\": 30, \"boundaryStopStatement\": 31, \"boundaryStart\": 32, \"LBRACE\": 33, \"ENTERPRISE_BOUNDARY\": 34, \"attributes\": 35, \"SYSTEM_BOUNDARY\": 36, \"BOUNDARY\": 37, \"CONTAINER_BOUNDARY\": 38, \"NODE\": 39, \"NODE_L\": 40, \"NODE_R\": 41, \"RBRACE\": 42, \"diagramStatement\": 43, \"PERSON\": 44, \"PERSON_EXT\": 45, \"SYSTEM\": 46, \"SYSTEM_DB\": 47, \"SYSTEM_QUEUE\": 48, \"SYSTEM_EXT\": 49, \"SYSTEM_EXT_DB\": 50, \"SYSTEM_EXT_QUEUE\": 51, \"CONTAINER\": 52, \"CONTAINER_DB\": 53, \"CONTAINER_QUEUE\": 54, \"CONTAINER_EXT\": 55, \"CONTAINER_EXT_DB\": 56, \"CONTAINER_EXT_QUEUE\": 57, \"COMPONENT\": 58, \"COMPONENT_DB\": 59, \"COMPONENT_QUEUE\": 60, \"COMPONENT_EXT\": 61, \"COMPONENT_EXT_DB\": 62, \"COMPONENT_EXT_QUEUE\": 63, \"REL\": 64, \"BIREL\": 65, \"REL_U\": 66, \"REL_D\": 67, \"REL_L\": 68, \"REL_R\": 69, \"REL_B\": 70, \"REL_INDEX\": 71, \"UPDATE_EL_STYLE\": 72, \"UPDATE_REL_STYLE\": 73, \"UPDATE_LAYOUT_CONFIG\": 74, \"attribute\": 75, \"STR\": 76, \"STR_KEY\": 77, \"STR_VALUE\": 78, \"ATTRIBUTE\": 79, \"ATTRIBUTE_EMPTY\": 80, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 6: \"direction_tb\", 7: \"direction_bt\", 8: \"direction_rl\", 9: \"direction_lr\", 11: \"C4_CONTEXT\", 12: \"NEWLINE\", 14: \"EOF\", 15: \"C4_CONTAINER\", 16: \"C4_COMPONENT\", 17: \"C4_DYNAMIC\", 18: \"C4_DEPLOYMENT\", 22: \"title\", 23: \"accDescription\", 24: \"acc_title\", 25: \"acc_title_value\", 26: \"acc_descr\", 27: \"acc_descr_value\", 28: \"acc_descr_multiline_value\", 33: \"LBRACE\", 34: \"ENTERPRISE_BOUNDARY\", 36: \"SYSTEM_BOUNDARY\", 37: \"BOUNDARY\", 38: \"CONTAINER_BOUNDARY\", 39: \"NODE\", 40: \"NODE_L\", 41: \"NODE_R\", 42: \"RBRACE\", 44: \"PERSON\", 45: \"PERSON_EXT\", 46: \"SYSTEM\", 47: \"SYSTEM_DB\", 48: \"SYSTEM_QUEUE\", 49: \"SYSTEM_EXT\", 50: \"SYSTEM_EXT_DB\", 51: \"SYSTEM_EXT_QUEUE\", 52: \"CONTAINER\", 53: \"CONTAINER_DB\", 54: \"CONTAINER_QUEUE\", 55: \"CONTAINER_EXT\", 56: \"CONTAINER_EXT_DB\", 57: \"CONTAINER_EXT_QUEUE\", 58: \"COMPONENT\", 59: \"COMPONENT_DB\", 60: \"COMPONENT_QUEUE\", 61: \"COMPONENT_EXT\", 62: \"COMPONENT_EXT_DB\", 63: \"COMPONENT_EXT_QUEUE\", 64: \"REL\", 65: \"BIREL\", 66: \"REL_U\", 67: \"REL_D\", 68: \"REL_L\", 69: \"REL_R\", 70: \"REL_B\", 71: \"REL_INDEX\", 72: \"UPDATE_EL_STYLE\", 73: \"UPDATE_REL_STYLE\", 74: \"UPDATE_LAYOUT_CONFIG\", 76: \"STR\", 77: \"STR_KEY\", 78: \"STR_VALUE\", 79: \"ATTRIBUTE\", 80: \"ATTRIBUTE_EMPTY\" },\n productions_: [0, [3, 1], [3, 1], [5, 1], [5, 1], [5, 1], [5, 1], [4, 1], [10, 4], [10, 4], [10, 4], [10, 4], [10, 4], [13, 1], [13, 1], [13, 2], [19, 1], [19, 2], [19, 3], [21, 1], [21, 1], [21, 2], [21, 2], [21, 1], [29, 3], [30, 3], [30, 3], [30, 4], [32, 2], [32, 2], [32, 2], [32, 2], [32, 2], [32, 2], [32, 2], [31, 1], [20, 1], [20, 2], [20, 3], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 1], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [35, 1], [35, 2], [75, 1], [75, 2], [75, 1], [75, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 3:\n yy.setDirection(\"TB\");\n break;\n case 4:\n yy.setDirection(\"BT\");\n break;\n case 5:\n yy.setDirection(\"RL\");\n break;\n case 6:\n yy.setDirection(\"LR\");\n break;\n case 8:\n case 9:\n case 10:\n case 11:\n case 12:\n yy.setC4Type($$[$0 - 3]);\n break;\n case 19:\n yy.setTitle($$[$0].substring(6));\n this.$ = $$[$0].substring(6);\n break;\n case 20:\n yy.setAccDescription($$[$0].substring(15));\n this.$ = $$[$0].substring(15);\n break;\n case 21:\n this.$ = $$[$0].trim();\n yy.setTitle(this.$);\n break;\n case 22:\n case 23:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 28:\n case 29:\n $$[$0].splice(2, 0, \"ENTERPRISE\");\n yy.addPersonOrSystemBoundary(...$$[$0]);\n this.$ = $$[$0];\n break;\n case 30:\n yy.addPersonOrSystemBoundary(...$$[$0]);\n this.$ = $$[$0];\n break;\n case 31:\n $$[$0].splice(2, 0, \"CONTAINER\");\n yy.addContainerBoundary(...$$[$0]);\n this.$ = $$[$0];\n break;\n case 32:\n yy.addDeploymentNode(\"node\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 33:\n yy.addDeploymentNode(\"nodeL\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 34:\n yy.addDeploymentNode(\"nodeR\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 35:\n yy.popBoundaryParseStack();\n break;\n case 39:\n yy.addPersonOrSystem(\"person\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 40:\n yy.addPersonOrSystem(\"external_person\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 41:\n yy.addPersonOrSystem(\"system\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 42:\n yy.addPersonOrSystem(\"system_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 43:\n yy.addPersonOrSystem(\"system_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 44:\n yy.addPersonOrSystem(\"external_system\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 45:\n yy.addPersonOrSystem(\"external_system_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 46:\n yy.addPersonOrSystem(\"external_system_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 47:\n yy.addContainer(\"container\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 48:\n yy.addContainer(\"container_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 49:\n yy.addContainer(\"container_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 50:\n yy.addContainer(\"external_container\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 51:\n yy.addContainer(\"external_container_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 52:\n yy.addContainer(\"external_container_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 53:\n yy.addComponent(\"component\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 54:\n yy.addComponent(\"component_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 55:\n yy.addComponent(\"component_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 56:\n yy.addComponent(\"external_component\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 57:\n yy.addComponent(\"external_component_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 58:\n yy.addComponent(\"external_component_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 60:\n yy.addRel(\"rel\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 61:\n yy.addRel(\"birel\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 62:\n yy.addRel(\"rel_u\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 63:\n yy.addRel(\"rel_d\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 64:\n yy.addRel(\"rel_l\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 65:\n yy.addRel(\"rel_r\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 66:\n yy.addRel(\"rel_b\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 67:\n $$[$0].splice(0, 1);\n yy.addRel(\"rel\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 68:\n yy.updateElStyle(\"update_el_style\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 69:\n yy.updateRelStyle(\"update_rel_style\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 70:\n yy.updateLayoutConfig(\"update_layout_config\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 71:\n this.$ = [$$[$0]];\n break;\n case 72:\n $$[$0].unshift($$[$0 - 1]);\n this.$ = $$[$0];\n break;\n case 73:\n case 75:\n this.$ = $$[$0].trim();\n break;\n case 74:\n let kv = {};\n kv[$$[$0 - 1].trim()] = $$[$0].trim();\n this.$ = kv;\n break;\n case 76:\n this.$ = \"\";\n break;\n }\n },\n table: [{ 3: 1, 4: 2, 5: 3, 6: [1, 5], 7: [1, 6], 8: [1, 7], 9: [1, 8], 10: 4, 11: [1, 9], 15: [1, 10], 16: [1, 11], 17: [1, 12], 18: [1, 13] }, { 1: [3] }, { 1: [2, 1] }, { 1: [2, 2] }, { 1: [2, 7] }, { 1: [2, 3] }, { 1: [2, 4] }, { 1: [2, 5] }, { 1: [2, 6] }, { 12: [1, 14] }, { 12: [1, 15] }, { 12: [1, 16] }, { 12: [1, 17] }, { 12: [1, 18] }, { 13: 19, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 70, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 71, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 72, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 73, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 14: [1, 74] }, o($VH, [2, 13], { 43: 23, 29: 49, 30: 61, 32: 62, 20: 75, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }), o($VH, [2, 14]), o($VI, [2, 16], { 12: [1, 76] }), o($VH, [2, 36], { 12: [1, 77] }), o($VJ, [2, 19]), o($VJ, [2, 20]), { 25: [1, 78] }, { 27: [1, 79] }, o($VJ, [2, 23]), { 35: 80, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 86, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 87, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 88, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 89, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 90, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 91, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 92, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 93, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 94, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 95, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 96, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 97, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 98, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 99, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 100, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 101, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 102, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 103, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 104, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, o($VO, [2, 59]), { 35: 105, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 106, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 107, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 108, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 109, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 110, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 111, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 112, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 113, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 114, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 115, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 20: 116, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 12: [1, 118], 33: [1, 117] }, { 35: 119, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 120, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 121, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 122, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 123, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 124, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 125, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 14: [1, 126] }, { 14: [1, 127] }, { 14: [1, 128] }, { 14: [1, 129] }, { 1: [2, 8] }, o($VH, [2, 15]), o($VI, [2, 17], { 21: 22, 19: 130, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4 }), o($VH, [2, 37], { 19: 20, 20: 21, 21: 22, 43: 23, 29: 49, 30: 61, 32: 62, 13: 131, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }), o($VJ, [2, 21]), o($VJ, [2, 22]), o($VO, [2, 39]), o($VP, [2, 71], { 75: 81, 35: 132, 76: $VK, 77: $VL, 79: $VM, 80: $VN }), o($VQ, [2, 73]), { 78: [1, 133] }, o($VQ, [2, 75]), o($VQ, [2, 76]), o($VO, [2, 40]), o($VO, [2, 41]), o($VO, [2, 42]), o($VO, [2, 43]), o($VO, [2, 44]), o($VO, [2, 45]), o($VO, [2, 46]), o($VO, [2, 47]), o($VO, [2, 48]), o($VO, [2, 49]), o($VO, [2, 50]), o($VO, [2, 51]), o($VO, [2, 52]), o($VO, [2, 53]), o($VO, [2, 54]), o($VO, [2, 55]), o($VO, [2, 56]), o($VO, [2, 57]), o($VO, [2, 58]), o($VO, [2, 60]), o($VO, [2, 61]), o($VO, [2, 62]), o($VO, [2, 63]), o($VO, [2, 64]), o($VO, [2, 65]), o($VO, [2, 66]), o($VO, [2, 67]), o($VO, [2, 68]), o($VO, [2, 69]), o($VO, [2, 70]), { 31: 134, 42: [1, 135] }, { 12: [1, 136] }, { 33: [1, 137] }, o($VR, [2, 28]), o($VR, [2, 29]), o($VR, [2, 30]), o($VR, [2, 31]), o($VR, [2, 32]), o($VR, [2, 33]), o($VR, [2, 34]), { 1: [2, 9] }, { 1: [2, 10] }, { 1: [2, 11] }, { 1: [2, 12] }, o($VI, [2, 18]), o($VH, [2, 38]), o($VP, [2, 72]), o($VQ, [2, 74]), o($VO, [2, 24]), o($VO, [2, 35]), o($VS, [2, 25]), o($VS, [2, 26], { 12: [1, 138] }), o($VS, [2, 27])],\n defaultActions: { 2: [2, 1], 3: [2, 2], 4: [2, 7], 5: [2, 3], 6: [2, 4], 7: [2, 5], 8: [2, 6], 74: [2, 8], 126: [2, 9], 127: [2, 10], 128: [2, 11], 129: [2, 12] },\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c2 = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c2 + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: {},\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n return 6;\n case 1:\n return 7;\n case 2:\n return 8;\n case 3:\n return 9;\n case 4:\n return 22;\n case 5:\n return 23;\n case 6:\n this.begin(\"acc_title\");\n return 24;\n case 7:\n this.popState();\n return \"acc_title_value\";\n case 8:\n this.begin(\"acc_descr\");\n return 26;\n case 9:\n this.popState();\n return \"acc_descr_value\";\n case 10:\n this.begin(\"acc_descr_multiline\");\n break;\n case 11:\n this.popState();\n break;\n case 12:\n return \"acc_descr_multiline_value\";\n case 13:\n break;\n case 14:\n c;\n break;\n case 15:\n return 12;\n case 16:\n break;\n case 17:\n return 11;\n case 18:\n return 15;\n case 19:\n return 16;\n case 20:\n return 17;\n case 21:\n return 18;\n case 22:\n this.begin(\"person_ext\");\n return 45;\n case 23:\n this.begin(\"person\");\n return 44;\n case 24:\n this.begin(\"system_ext_queue\");\n return 51;\n case 25:\n this.begin(\"system_ext_db\");\n return 50;\n case 26:\n this.begin(\"system_ext\");\n return 49;\n case 27:\n this.begin(\"system_queue\");\n return 48;\n case 28:\n this.begin(\"system_db\");\n return 47;\n case 29:\n this.begin(\"system\");\n return 46;\n case 30:\n this.begin(\"boundary\");\n return 37;\n case 31:\n this.begin(\"enterprise_boundary\");\n return 34;\n case 32:\n this.begin(\"system_boundary\");\n return 36;\n case 33:\n this.begin(\"container_ext_queue\");\n return 57;\n case 34:\n this.begin(\"container_ext_db\");\n return 56;\n case 35:\n this.begin(\"container_ext\");\n return 55;\n case 36:\n this.begin(\"container_queue\");\n return 54;\n case 37:\n this.begin(\"container_db\");\n return 53;\n case 38:\n this.begin(\"container\");\n return 52;\n case 39:\n this.begin(\"container_boundary\");\n return 38;\n case 40:\n this.begin(\"component_ext_queue\");\n return 63;\n case 41:\n this.begin(\"component_ext_db\");\n return 62;\n case 42:\n this.begin(\"component_ext\");\n return 61;\n case 43:\n this.begin(\"component_queue\");\n return 60;\n case 44:\n this.begin(\"component_db\");\n return 59;\n case 45:\n this.begin(\"component\");\n return 58;\n case 46:\n this.begin(\"node\");\n return 39;\n case 47:\n this.begin(\"node\");\n return 39;\n case 48:\n this.begin(\"node_l\");\n return 40;\n case 49:\n this.begin(\"node_r\");\n return 41;\n case 50:\n this.begin(\"rel\");\n return 64;\n case 51:\n this.begin(\"birel\");\n return 65;\n case 52:\n this.begin(\"rel_u\");\n return 66;\n case 53:\n this.begin(\"rel_u\");\n return 66;\n case 54:\n this.begin(\"rel_d\");\n return 67;\n case 55:\n this.begin(\"rel_d\");\n return 67;\n case 56:\n this.begin(\"rel_l\");\n return 68;\n case 57:\n this.begin(\"rel_l\");\n return 68;\n case 58:\n this.begin(\"rel_r\");\n return 69;\n case 59:\n this.begin(\"rel_r\");\n return 69;\n case 60:\n this.begin(\"rel_b\");\n return 70;\n case 61:\n this.begin(\"rel_index\");\n return 71;\n case 62:\n this.begin(\"update_el_style\");\n return 72;\n case 63:\n this.begin(\"update_rel_style\");\n return 73;\n case 64:\n this.begin(\"update_layout_config\");\n return 74;\n case 65:\n return \"EOF_IN_STRUCT\";\n case 66:\n this.begin(\"attribute\");\n return \"ATTRIBUTE_EMPTY\";\n case 67:\n this.begin(\"attribute\");\n break;\n case 68:\n this.popState();\n this.popState();\n break;\n case 69:\n return 80;\n case 70:\n break;\n case 71:\n return 80;\n case 72:\n this.begin(\"string\");\n break;\n case 73:\n this.popState();\n break;\n case 74:\n return \"STR\";\n case 75:\n this.begin(\"string_kv\");\n break;\n case 76:\n this.begin(\"string_kv_key\");\n return \"STR_KEY\";\n case 77:\n this.popState();\n this.begin(\"string_kv_value\");\n break;\n case 78:\n return \"STR_VALUE\";\n case 79:\n this.popState();\n this.popState();\n break;\n case 80:\n return \"STR\";\n case 81:\n return \"LBRACE\";\n case 82:\n return \"RBRACE\";\n case 83:\n return \"SPACE\";\n case 84:\n return \"EOL\";\n case 85:\n return 14;\n }\n },\n rules: [/^(?:.*direction\\s+TB[^\\n]*)/, /^(?:.*direction\\s+BT[^\\n]*)/, /^(?:.*direction\\s+RL[^\\n]*)/, /^(?:.*direction\\s+LR[^\\n]*)/, /^(?:title\\s[^#\\n;]+)/, /^(?:accDescription\\s[^#\\n;]+)/, /^(?:accTitle\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*\\{\\s*)/, /^(?:[\\}])/, /^(?:[^\\}]*)/, /^(?:%%(?!\\{)*[^\\n]*(\\r?\\n?)+)/, /^(?:%%[^\\n]*(\\r?\\n)*)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:C4Context\\b)/, /^(?:C4Container\\b)/, /^(?:C4Component\\b)/, /^(?:C4Dynamic\\b)/, /^(?:C4Deployment\\b)/, /^(?:Person_Ext\\b)/, /^(?:Person\\b)/, /^(?:SystemQueue_Ext\\b)/, /^(?:SystemDb_Ext\\b)/, /^(?:System_Ext\\b)/, /^(?:SystemQueue\\b)/, /^(?:SystemDb\\b)/, /^(?:System\\b)/, /^(?:Boundary\\b)/, /^(?:Enterprise_Boundary\\b)/, /^(?:System_Boundary\\b)/, /^(?:ContainerQueue_Ext\\b)/, /^(?:ContainerDb_Ext\\b)/, /^(?:Container_Ext\\b)/, /^(?:ContainerQueue\\b)/, /^(?:ContainerDb\\b)/, /^(?:Container\\b)/, /^(?:Container_Boundary\\b)/, /^(?:ComponentQueue_Ext\\b)/, /^(?:ComponentDb_Ext\\b)/, /^(?:Component_Ext\\b)/, /^(?:ComponentQueue\\b)/, /^(?:ComponentDb\\b)/, /^(?:Component\\b)/, /^(?:Deployment_Node\\b)/, /^(?:Node\\b)/, /^(?:Node_L\\b)/, /^(?:Node_R\\b)/, /^(?:Rel\\b)/, /^(?:BiRel\\b)/, /^(?:Rel_Up\\b)/, /^(?:Rel_U\\b)/, /^(?:Rel_Down\\b)/, /^(?:Rel_D\\b)/, /^(?:Rel_Left\\b)/, /^(?:Rel_L\\b)/, /^(?:Rel_Right\\b)/, /^(?:Rel_R\\b)/, /^(?:Rel_Back\\b)/, /^(?:RelIndex\\b)/, /^(?:UpdateElementStyle\\b)/, /^(?:UpdateRelStyle\\b)/, /^(?:UpdateLayoutConfig\\b)/, /^(?:$)/, /^(?:[(][ ]*[,])/, /^(?:[(])/, /^(?:[)])/, /^(?:,,)/, /^(?:,)/, /^(?:[ ]*[\"][\"])/, /^(?:[ ]*[\"])/, /^(?:[\"])/, /^(?:[^\"]*)/, /^(?:[ ]*[\\$])/, /^(?:[^=]*)/, /^(?:[=][ ]*[\"])/, /^(?:[^\"]+)/, /^(?:[\"])/, /^(?:[^,]+)/, /^(?:\\{)/, /^(?:\\})/, /^(?:[\\s]+)/, /^(?:[\\n\\r]+)/, /^(?:$)/],\n conditions: { \"acc_descr_multiline\": { \"rules\": [11, 12], \"inclusive\": false }, \"acc_descr\": { \"rules\": [9], \"inclusive\": false }, \"acc_title\": { \"rules\": [7], \"inclusive\": false }, \"string_kv_value\": { \"rules\": [78, 79], \"inclusive\": false }, \"string_kv_key\": { \"rules\": [77], \"inclusive\": false }, \"string_kv\": { \"rules\": [76], \"inclusive\": false }, \"string\": { \"rules\": [73, 74], \"inclusive\": false }, \"attribute\": { \"rules\": [68, 69, 70, 71, 72, 75, 80], \"inclusive\": false }, \"update_layout_config\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"update_rel_style\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"update_el_style\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_b\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_r\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_l\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_d\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_u\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_bi\": { \"rules\": [], \"inclusive\": false }, \"rel\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"node_r\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"node_l\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"node\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"index\": { \"rules\": [], \"inclusive\": false }, \"rel_index\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_ext_queue\": { \"rules\": [], \"inclusive\": false }, \"component_ext_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_ext_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_ext_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"birel\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"enterprise_boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_ext_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_ext_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"person_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"person\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 1, 2, 3, 4, 5, 6, 8, 10, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 81, 82, 83, 84, 85], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nlet c4ShapeArray = [];\nlet boundaryParseStack = [\"\"];\nlet currentBoundaryParse = \"global\";\nlet parentBoundaryParse = \"\";\nlet boundarys = [\n {\n alias: \"global\",\n label: { text: \"global\" },\n type: { text: \"global\" },\n tags: null,\n link: null,\n parentBoundary: \"\"\n }\n];\nlet rels = [];\nlet title = \"\";\nlet wrapEnabled = false;\nlet c4ShapeInRow$1 = 4;\nlet c4BoundaryInRow$1 = 2;\nvar c4Type;\nconst getC4Type = function() {\n return c4Type;\n};\nconst setC4Type = function(c4TypeParam) {\n let sanitizedText = sanitizeText(c4TypeParam, getConfig());\n c4Type = sanitizedText;\n};\nconst addRel = function(type, from, to, label, techn, descr, sprite, tags, link) {\n if (type === void 0 || type === null || from === void 0 || from === null || to === void 0 || to === null || label === void 0 || label === null) {\n return;\n }\n let rel = {};\n const old = rels.find((rel2) => rel2.from === from && rel2.to === to);\n if (old) {\n rel = old;\n } else {\n rels.push(rel);\n }\n rel.type = type;\n rel.from = from;\n rel.to = to;\n rel.label = { text: label };\n if (techn === void 0 || techn === null) {\n rel.techn = { text: \"\" };\n } else {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n rel[key] = { text: value };\n } else {\n rel.techn = { text: techn };\n }\n }\n if (descr === void 0 || descr === null) {\n rel.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n rel[key] = { text: value };\n } else {\n rel.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n rel[key] = value;\n } else {\n rel.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n rel[key] = value;\n } else {\n rel.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n rel[key] = value;\n } else {\n rel.link = link;\n }\n rel.wrap = autoWrap();\n};\nconst addPersonOrSystem = function(typeC4Shape, alias, label, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let personOrSystem = {};\n const old = c4ShapeArray.find((personOrSystem2) => personOrSystem2.alias === alias);\n if (old && alias === old.alias) {\n personOrSystem = old;\n } else {\n personOrSystem.alias = alias;\n c4ShapeArray.push(personOrSystem);\n }\n if (label === void 0 || label === null) {\n personOrSystem.label = { text: \"\" };\n } else {\n personOrSystem.label = { text: label };\n }\n if (descr === void 0 || descr === null) {\n personOrSystem.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n personOrSystem[key] = { text: value };\n } else {\n personOrSystem.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n personOrSystem[key] = value;\n } else {\n personOrSystem.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n personOrSystem[key] = value;\n } else {\n personOrSystem.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n personOrSystem[key] = value;\n } else {\n personOrSystem.link = link;\n }\n personOrSystem.typeC4Shape = { text: typeC4Shape };\n personOrSystem.parentBoundary = currentBoundaryParse;\n personOrSystem.wrap = autoWrap();\n};\nconst addContainer = function(typeC4Shape, alias, label, techn, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let container = {};\n const old = c4ShapeArray.find((container2) => container2.alias === alias);\n if (old && alias === old.alias) {\n container = old;\n } else {\n container.alias = alias;\n c4ShapeArray.push(container);\n }\n if (label === void 0 || label === null) {\n container.label = { text: \"\" };\n } else {\n container.label = { text: label };\n }\n if (techn === void 0 || techn === null) {\n container.techn = { text: \"\" };\n } else {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n container[key] = { text: value };\n } else {\n container.techn = { text: techn };\n }\n }\n if (descr === void 0 || descr === null) {\n container.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n container[key] = { text: value };\n } else {\n container.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n container[key] = value;\n } else {\n container.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n container[key] = value;\n } else {\n container.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n container[key] = value;\n } else {\n container.link = link;\n }\n container.wrap = autoWrap();\n container.typeC4Shape = { text: typeC4Shape };\n container.parentBoundary = currentBoundaryParse;\n};\nconst addComponent = function(typeC4Shape, alias, label, techn, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let component = {};\n const old = c4ShapeArray.find((component2) => component2.alias === alias);\n if (old && alias === old.alias) {\n component = old;\n } else {\n component.alias = alias;\n c4ShapeArray.push(component);\n }\n if (label === void 0 || label === null) {\n component.label = { text: \"\" };\n } else {\n component.label = { text: label };\n }\n if (techn === void 0 || techn === null) {\n component.techn = { text: \"\" };\n } else {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n component[key] = { text: value };\n } else {\n component.techn = { text: techn };\n }\n }\n if (descr === void 0 || descr === null) {\n component.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n component[key] = { text: value };\n } else {\n component.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n component[key] = value;\n } else {\n component.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n component[key] = value;\n } else {\n component.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n component[key] = value;\n } else {\n component.link = link;\n }\n component.wrap = autoWrap();\n component.typeC4Shape = { text: typeC4Shape };\n component.parentBoundary = currentBoundaryParse;\n};\nconst addPersonOrSystemBoundary = function(alias, label, type, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let boundary = {};\n const old = boundarys.find((boundary2) => boundary2.alias === alias);\n if (old && alias === old.alias) {\n boundary = old;\n } else {\n boundary.alias = alias;\n boundarys.push(boundary);\n }\n if (label === void 0 || label === null) {\n boundary.label = { text: \"\" };\n } else {\n boundary.label = { text: label };\n }\n if (type === void 0 || type === null) {\n boundary.type = { text: \"system\" };\n } else {\n if (typeof type === \"object\") {\n let [key, value] = Object.entries(type)[0];\n boundary[key] = { text: value };\n } else {\n boundary.type = { text: type };\n }\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n boundary[key] = value;\n } else {\n boundary.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n boundary[key] = value;\n } else {\n boundary.link = link;\n }\n boundary.parentBoundary = currentBoundaryParse;\n boundary.wrap = autoWrap();\n parentBoundaryParse = currentBoundaryParse;\n currentBoundaryParse = alias;\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst addContainerBoundary = function(alias, label, type, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let boundary = {};\n const old = boundarys.find((boundary2) => boundary2.alias === alias);\n if (old && alias === old.alias) {\n boundary = old;\n } else {\n boundary.alias = alias;\n boundarys.push(boundary);\n }\n if (label === void 0 || label === null) {\n boundary.label = { text: \"\" };\n } else {\n boundary.label = { text: label };\n }\n if (type === void 0 || type === null) {\n boundary.type = { text: \"container\" };\n } else {\n if (typeof type === \"object\") {\n let [key, value] = Object.entries(type)[0];\n boundary[key] = { text: value };\n } else {\n boundary.type = { text: type };\n }\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n boundary[key] = value;\n } else {\n boundary.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n boundary[key] = value;\n } else {\n boundary.link = link;\n }\n boundary.parentBoundary = currentBoundaryParse;\n boundary.wrap = autoWrap();\n parentBoundaryParse = currentBoundaryParse;\n currentBoundaryParse = alias;\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst addDeploymentNode = function(nodeType, alias, label, type, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let boundary = {};\n const old = boundarys.find((boundary2) => boundary2.alias === alias);\n if (old && alias === old.alias) {\n boundary = old;\n } else {\n boundary.alias = alias;\n boundarys.push(boundary);\n }\n if (label === void 0 || label === null) {\n boundary.label = { text: \"\" };\n } else {\n boundary.label = { text: label };\n }\n if (type === void 0 || type === null) {\n boundary.type = { text: \"node\" };\n } else {\n if (typeof type === \"object\") {\n let [key, value] = Object.entries(type)[0];\n boundary[key] = { text: value };\n } else {\n boundary.type = { text: type };\n }\n }\n if (descr === void 0 || descr === null) {\n boundary.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n boundary[key] = { text: value };\n } else {\n boundary.descr = { text: descr };\n }\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n boundary[key] = value;\n } else {\n boundary.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n boundary[key] = value;\n } else {\n boundary.link = link;\n }\n boundary.nodeType = nodeType;\n boundary.parentBoundary = currentBoundaryParse;\n boundary.wrap = autoWrap();\n parentBoundaryParse = currentBoundaryParse;\n currentBoundaryParse = alias;\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst popBoundaryParseStack = function() {\n currentBoundaryParse = parentBoundaryParse;\n boundaryParseStack.pop();\n parentBoundaryParse = boundaryParseStack.pop();\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst updateElStyle = function(typeC4Shape, elementName, bgColor, fontColor, borderColor, shadowing, shape, sprite, techn, legendText, legendSprite) {\n let old = c4ShapeArray.find((element) => element.alias === elementName);\n if (old === void 0) {\n old = boundarys.find((element) => element.alias === elementName);\n if (old === void 0) {\n return;\n }\n }\n if (bgColor !== void 0 && bgColor !== null) {\n if (typeof bgColor === \"object\") {\n let [key, value] = Object.entries(bgColor)[0];\n old[key] = value;\n } else {\n old.bgColor = bgColor;\n }\n }\n if (fontColor !== void 0 && fontColor !== null) {\n if (typeof fontColor === \"object\") {\n let [key, value] = Object.entries(fontColor)[0];\n old[key] = value;\n } else {\n old.fontColor = fontColor;\n }\n }\n if (borderColor !== void 0 && borderColor !== null) {\n if (typeof borderColor === \"object\") {\n let [key, value] = Object.entries(borderColor)[0];\n old[key] = value;\n } else {\n old.borderColor = borderColor;\n }\n }\n if (shadowing !== void 0 && shadowing !== null) {\n if (typeof shadowing === \"object\") {\n let [key, value] = Object.entries(shadowing)[0];\n old[key] = value;\n } else {\n old.shadowing = shadowing;\n }\n }\n if (shape !== void 0 && shape !== null) {\n if (typeof shape === \"object\") {\n let [key, value] = Object.entries(shape)[0];\n old[key] = value;\n } else {\n old.shape = shape;\n }\n }\n if (sprite !== void 0 && sprite !== null) {\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n old[key] = value;\n } else {\n old.sprite = sprite;\n }\n }\n if (techn !== void 0 && techn !== null) {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n old[key] = value;\n } else {\n old.techn = techn;\n }\n }\n if (legendText !== void 0 && legendText !== null) {\n if (typeof legendText === \"object\") {\n let [key, value] = Object.entries(legendText)[0];\n old[key] = value;\n } else {\n old.legendText = legendText;\n }\n }\n if (legendSprite !== void 0 && legendSprite !== null) {\n if (typeof legendSprite === \"object\") {\n let [key, value] = Object.entries(legendSprite)[0];\n old[key] = value;\n } else {\n old.legendSprite = legendSprite;\n }\n }\n};\nconst updateRelStyle = function(typeC4Shape, from, to, textColor, lineColor, offsetX, offsetY) {\n const old = rels.find((rel) => rel.from === from && rel.to === to);\n if (old === void 0) {\n return;\n }\n if (textColor !== void 0 && textColor !== null) {\n if (typeof textColor === \"object\") {\n let [key, value] = Object.entries(textColor)[0];\n old[key] = value;\n } else {\n old.textColor = textColor;\n }\n }\n if (lineColor !== void 0 && lineColor !== null) {\n if (typeof lineColor === \"object\") {\n let [key, value] = Object.entries(lineColor)[0];\n old[key] = value;\n } else {\n old.lineColor = lineColor;\n }\n }\n if (offsetX !== void 0 && offsetX !== null) {\n if (typeof offsetX === \"object\") {\n let [key, value] = Object.entries(offsetX)[0];\n old[key] = parseInt(value);\n } else {\n old.offsetX = parseInt(offsetX);\n }\n }\n if (offsetY !== void 0 && offsetY !== null) {\n if (typeof offsetY === \"object\") {\n let [key, value] = Object.entries(offsetY)[0];\n old[key] = parseInt(value);\n } else {\n old.offsetY = parseInt(offsetY);\n }\n }\n};\nconst updateLayoutConfig = function(typeC4Shape, c4ShapeInRowParam, c4BoundaryInRowParam) {\n let c4ShapeInRowValue = c4ShapeInRow$1;\n let c4BoundaryInRowValue = c4BoundaryInRow$1;\n if (typeof c4ShapeInRowParam === \"object\") {\n const value = Object.values(c4ShapeInRowParam)[0];\n c4ShapeInRowValue = parseInt(value);\n } else {\n c4ShapeInRowValue = parseInt(c4ShapeInRowParam);\n }\n if (typeof c4BoundaryInRowParam === \"object\") {\n const value = Object.values(c4BoundaryInRowParam)[0];\n c4BoundaryInRowValue = parseInt(value);\n } else {\n c4BoundaryInRowValue = parseInt(c4BoundaryInRowParam);\n }\n if (c4ShapeInRowValue >= 1) {\n c4ShapeInRow$1 = c4ShapeInRowValue;\n }\n if (c4BoundaryInRowValue >= 1) {\n c4BoundaryInRow$1 = c4BoundaryInRowValue;\n }\n};\nconst getC4ShapeInRow = function() {\n return c4ShapeInRow$1;\n};\nconst getC4BoundaryInRow = function() {\n return c4BoundaryInRow$1;\n};\nconst getCurrentBoundaryParse = function() {\n return currentBoundaryParse;\n};\nconst getParentBoundaryParse = function() {\n return parentBoundaryParse;\n};\nconst getC4ShapeArray = function(parentBoundary) {\n if (parentBoundary === void 0 || parentBoundary === null) {\n return c4ShapeArray;\n } else {\n return c4ShapeArray.filter((personOrSystem) => {\n return personOrSystem.parentBoundary === parentBoundary;\n });\n }\n};\nconst getC4Shape = function(alias) {\n return c4ShapeArray.find((personOrSystem) => personOrSystem.alias === alias);\n};\nconst getC4ShapeKeys = function(parentBoundary) {\n return Object.keys(getC4ShapeArray(parentBoundary));\n};\nconst getBoundarys = function(parentBoundary) {\n if (parentBoundary === void 0 || parentBoundary === null) {\n return boundarys;\n } else {\n return boundarys.filter((boundary) => boundary.parentBoundary === parentBoundary);\n }\n};\nconst getRels = function() {\n return rels;\n};\nconst getTitle = function() {\n return title;\n};\nconst setWrap = function(wrapSetting) {\n wrapEnabled = wrapSetting;\n};\nconst autoWrap = function() {\n return wrapEnabled;\n};\nconst clear = function() {\n c4ShapeArray = [];\n boundarys = [\n {\n alias: \"global\",\n label: { text: \"global\" },\n type: { text: \"global\" },\n tags: null,\n link: null,\n parentBoundary: \"\"\n }\n ];\n parentBoundaryParse = \"\";\n currentBoundaryParse = \"global\";\n boundaryParseStack = [\"\"];\n rels = [];\n boundaryParseStack = [\"\"];\n title = \"\";\n wrapEnabled = false;\n c4ShapeInRow$1 = 4;\n c4BoundaryInRow$1 = 2;\n};\nconst LINETYPE = {\n SOLID: 0,\n DOTTED: 1,\n NOTE: 2,\n SOLID_CROSS: 3,\n DOTTED_CROSS: 4,\n SOLID_OPEN: 5,\n DOTTED_OPEN: 6,\n LOOP_START: 10,\n LOOP_END: 11,\n ALT_START: 12,\n ALT_ELSE: 13,\n ALT_END: 14,\n OPT_START: 15,\n OPT_END: 16,\n ACTIVE_START: 17,\n ACTIVE_END: 18,\n PAR_START: 19,\n PAR_AND: 20,\n PAR_END: 21,\n RECT_START: 22,\n RECT_END: 23,\n SOLID_POINT: 24,\n DOTTED_POINT: 25\n};\nconst ARROWTYPE = {\n FILLED: 0,\n OPEN: 1\n};\nconst PLACEMENT = {\n LEFTOF: 0,\n RIGHTOF: 1,\n OVER: 2\n};\nconst setTitle = function(txt) {\n let sanitizedText = sanitizeText(txt, getConfig());\n title = sanitizedText;\n};\nconst db = {\n addPersonOrSystem,\n addPersonOrSystemBoundary,\n addContainer,\n addContainerBoundary,\n addComponent,\n addDeploymentNode,\n popBoundaryParseStack,\n addRel,\n updateElStyle,\n updateRelStyle,\n updateLayoutConfig,\n autoWrap,\n setWrap,\n getC4ShapeArray,\n getC4Shape,\n getC4ShapeKeys,\n getBoundarys,\n getCurrentBoundaryParse,\n getParentBoundaryParse,\n getRels,\n getTitle,\n getC4Type,\n getC4ShapeInRow,\n getC4BoundaryInRow,\n setAccTitle,\n getAccTitle,\n getAccDescription,\n setAccDescription,\n getConfig: () => getConfig().c4,\n clear,\n LINETYPE,\n ARROWTYPE,\n PLACEMENT,\n setTitle,\n setC4Type\n // apply,\n};\nconst drawRect = function(elem, rectData) {\n return drawRect$1(elem, rectData);\n};\nconst drawImage = function(elem, width, height, x, y, link) {\n const imageElem = elem.append(\"image\");\n imageElem.attr(\"width\", width);\n imageElem.attr(\"height\", height);\n imageElem.attr(\"x\", x);\n imageElem.attr(\"y\", y);\n let sanitizedLink = link.startsWith(\"data:image/png;base64\") ? link : sanitizeUrl(link);\n imageElem.attr(\"xlink:href\", sanitizedLink);\n};\nconst drawRels$1 = (elem, rels2, conf2) => {\n const relsElem = elem.append(\"g\");\n let i = 0;\n for (let rel of rels2) {\n let textColor = rel.textColor ? rel.textColor : \"#444444\";\n let strokeColor = rel.lineColor ? rel.lineColor : \"#444444\";\n let offsetX = rel.offsetX ? parseInt(rel.offsetX) : 0;\n let offsetY = rel.offsetY ? parseInt(rel.offsetY) : 0;\n let url = \"\";\n if (i === 0) {\n let line = relsElem.append(\"line\");\n line.attr(\"x1\", rel.startPoint.x);\n line.attr(\"y1\", rel.startPoint.y);\n line.attr(\"x2\", rel.endPoint.x);\n line.attr(\"y2\", rel.endPoint.y);\n line.attr(\"stroke-width\", \"1\");\n line.attr(\"stroke\", strokeColor);\n line.style(\"fill\", \"none\");\n if (rel.type !== \"rel_b\") {\n line.attr(\"marker-end\", \"url(\" + url + \"#arrowhead)\");\n }\n if (rel.type === \"birel\" || rel.type === \"rel_b\") {\n line.attr(\"marker-start\", \"url(\" + url + \"#arrowend)\");\n }\n i = -1;\n } else {\n let line = relsElem.append(\"path\");\n line.attr(\"fill\", \"none\").attr(\"stroke-width\", \"1\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,starty Qcontrolx,controly stopx,stopy \".replaceAll(\"startx\", rel.startPoint.x).replaceAll(\"starty\", rel.startPoint.y).replaceAll(\n \"controlx\",\n rel.startPoint.x + (rel.endPoint.x - rel.startPoint.x) / 2 - (rel.endPoint.x - rel.startPoint.x) / 4\n ).replaceAll(\"controly\", rel.startPoint.y + (rel.endPoint.y - rel.startPoint.y) / 2).replaceAll(\"stopx\", rel.endPoint.x).replaceAll(\"stopy\", rel.endPoint.y)\n );\n if (rel.type !== \"rel_b\") {\n line.attr(\"marker-end\", \"url(\" + url + \"#arrowhead)\");\n }\n if (rel.type === \"birel\" || rel.type === \"rel_b\") {\n line.attr(\"marker-start\", \"url(\" + url + \"#arrowend)\");\n }\n }\n let messageConf = conf2.messageFont();\n _drawTextCandidateFunc(conf2)(\n rel.label.text,\n relsElem,\n Math.min(rel.startPoint.x, rel.endPoint.x) + Math.abs(rel.endPoint.x - rel.startPoint.x) / 2 + offsetX,\n Math.min(rel.startPoint.y, rel.endPoint.y) + Math.abs(rel.endPoint.y - rel.startPoint.y) / 2 + offsetY,\n rel.label.width,\n rel.label.height,\n { fill: textColor },\n messageConf\n );\n if (rel.techn && rel.techn.text !== \"\") {\n messageConf = conf2.messageFont();\n _drawTextCandidateFunc(conf2)(\n \"[\" + rel.techn.text + \"]\",\n relsElem,\n Math.min(rel.startPoint.x, rel.endPoint.x) + Math.abs(rel.endPoint.x - rel.startPoint.x) / 2 + offsetX,\n Math.min(rel.startPoint.y, rel.endPoint.y) + Math.abs(rel.endPoint.y - rel.startPoint.y) / 2 + conf2.messageFontSize + 5 + offsetY,\n Math.max(rel.label.width, rel.techn.width),\n rel.techn.height,\n { fill: textColor, \"font-style\": \"italic\" },\n messageConf\n );\n }\n }\n};\nconst drawBoundary$1 = function(elem, boundary, conf2) {\n const boundaryElem = elem.append(\"g\");\n let fillColor = boundary.bgColor ? boundary.bgColor : \"none\";\n let strokeColor = boundary.borderColor ? boundary.borderColor : \"#444444\";\n let fontColor = boundary.fontColor ? boundary.fontColor : \"black\";\n let attrsValue = { \"stroke-width\": 1, \"stroke-dasharray\": \"7.0,7.0\" };\n if (boundary.nodeType) {\n attrsValue = { \"stroke-width\": 1 };\n }\n let rectData = {\n x: boundary.x,\n y: boundary.y,\n fill: fillColor,\n stroke: strokeColor,\n width: boundary.width,\n height: boundary.height,\n rx: 2.5,\n ry: 2.5,\n attrs: attrsValue\n };\n drawRect(boundaryElem, rectData);\n let boundaryConf = conf2.boundaryFont();\n boundaryConf.fontWeight = \"bold\";\n boundaryConf.fontSize = boundaryConf.fontSize + 2;\n boundaryConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n boundary.label.text,\n boundaryElem,\n boundary.x,\n boundary.y + boundary.label.Y,\n boundary.width,\n boundary.height,\n { fill: \"#444444\" },\n boundaryConf\n );\n if (boundary.type && boundary.type.text !== \"\") {\n boundaryConf = conf2.boundaryFont();\n boundaryConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n boundary.type.text,\n boundaryElem,\n boundary.x,\n boundary.y + boundary.type.Y,\n boundary.width,\n boundary.height,\n { fill: \"#444444\" },\n boundaryConf\n );\n }\n if (boundary.descr && boundary.descr.text !== \"\") {\n boundaryConf = conf2.boundaryFont();\n boundaryConf.fontSize = boundaryConf.fontSize - 2;\n boundaryConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n boundary.descr.text,\n boundaryElem,\n boundary.x,\n boundary.y + boundary.descr.Y,\n boundary.width,\n boundary.height,\n { fill: \"#444444\" },\n boundaryConf\n );\n }\n};\nconst drawC4Shape = function(elem, c4Shape, conf2) {\n var _a;\n let fillColor = c4Shape.bgColor ? c4Shape.bgColor : conf2[c4Shape.typeC4Shape.text + \"_bg_color\"];\n let strokeColor = c4Shape.borderColor ? c4Shape.borderColor : conf2[c4Shape.typeC4Shape.text + \"_border_color\"];\n let fontColor = c4Shape.fontColor ? c4Shape.fontColor : \"#FFFFFF\";\n let personImg = \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=\";\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n personImg = \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=\";\n break;\n case \"external_person\":\n personImg = \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAAB6ElEQVR4Xu2YLY+EMBCG9+dWr0aj0Wg0Go1Go0+j8Xdv2uTCvv1gpt0ebHKPuhDaeW4605Z9mJvx4AdXUyTUdd08z+u6flmWZRnHsWkafk9DptAwDPu+f0eAYtu2PEaGWuj5fCIZrBAC2eLBAnRCsEkkxmeaJp7iDJ2QMDdHsLg8SxKFEJaAo8lAXnmuOFIhTMpxxKATebo4UiFknuNo4OniSIXQyRxEA3YsnjGCVEjVXD7yLUAqxBGUyPv/Y4W2beMgGuS7kVQIBycH0fD+oi5pezQETxdHKmQKGk1eQEYldK+jw5GxPfZ9z7Mk0Qnhf1W1m3w//EUn5BDmSZsbR44QQLBEqrBHqOrmSKaQAxdnLArCrxZcM7A7ZKs4ioRq8LFC+NpC3WCBJsvpVw5edm9iEXFuyNfxXAgSwfrFQ1c0iNda8AdejvUgnktOtJQQxmcfFzGglc5WVCj7oDgFqU18boeFSs52CUh8LE8BIVQDT1ABrB0HtgSEYlX5doJnCwv9TXocKCaKbnwhdDKPq4lf3SwU3HLq4V/+WYhHVMa/3b4IlfyikAduCkcBc7mQ3/z/Qq/cTuikhkzB12Ae/mcJC9U+Vo8Ej1gWAtgbeGgFsAMHr50BIWOLCbezvhpBFUdY6EJuJ/QDW0XoMX60zZ0AAAAASUVORK5CYII=\";\n break;\n }\n const c4ShapeElem = elem.append(\"g\");\n c4ShapeElem.attr(\"class\", \"person-man\");\n const rect = getNoteRect();\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n case \"external_person\":\n case \"system\":\n case \"external_system\":\n case \"container\":\n case \"external_container\":\n case \"component\":\n case \"external_component\":\n rect.x = c4Shape.x;\n rect.y = c4Shape.y;\n rect.fill = fillColor;\n rect.width = c4Shape.width;\n rect.height = c4Shape.height;\n rect.stroke = strokeColor;\n rect.rx = 2.5;\n rect.ry = 2.5;\n rect.attrs = { \"stroke-width\": 0.5 };\n drawRect(c4ShapeElem, rect);\n break;\n case \"system_db\":\n case \"external_system_db\":\n case \"container_db\":\n case \"external_container_db\":\n case \"component_db\":\n case \"external_component_db\":\n c4ShapeElem.append(\"path\").attr(\"fill\", fillColor).attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startyc0,-10 half,-10 half,-10c0,0 half,0 half,10l0,heightc0,10 -half,10 -half,10c0,0 -half,0 -half,-10l0,-height\".replaceAll(\"startx\", c4Shape.x).replaceAll(\"starty\", c4Shape.y).replaceAll(\"half\", c4Shape.width / 2).replaceAll(\"height\", c4Shape.height)\n );\n c4ShapeElem.append(\"path\").attr(\"fill\", \"none\").attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startyc0,10 half,10 half,10c0,0 half,0 half,-10\".replaceAll(\"startx\", c4Shape.x).replaceAll(\"starty\", c4Shape.y).replaceAll(\"half\", c4Shape.width / 2)\n );\n break;\n case \"system_queue\":\n case \"external_system_queue\":\n case \"container_queue\":\n case \"external_container_queue\":\n case \"component_queue\":\n case \"external_component_queue\":\n c4ShapeElem.append(\"path\").attr(\"fill\", fillColor).attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startylwidth,0c5,0 5,half 5,halfc0,0 0,half -5,halfl-width,0c-5,0 -5,-half -5,-halfc0,0 0,-half 5,-half\".replaceAll(\"startx\", c4Shape.x).replaceAll(\"starty\", c4Shape.y).replaceAll(\"width\", c4Shape.width).replaceAll(\"half\", c4Shape.height / 2)\n );\n c4ShapeElem.append(\"path\").attr(\"fill\", \"none\").attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startyc-5,0 -5,half -5,halfc0,half 5,half 5,half\".replaceAll(\"startx\", c4Shape.x + c4Shape.width).replaceAll(\"starty\", c4Shape.y).replaceAll(\"half\", c4Shape.height / 2)\n );\n break;\n }\n let c4ShapeFontConf = getC4ShapeFont(conf2, c4Shape.typeC4Shape.text);\n c4ShapeElem.append(\"text\").attr(\"fill\", fontColor).attr(\"font-family\", c4ShapeFontConf.fontFamily).attr(\"font-size\", c4ShapeFontConf.fontSize - 2).attr(\"font-style\", \"italic\").attr(\"lengthAdjust\", \"spacing\").attr(\"textLength\", c4Shape.typeC4Shape.width).attr(\"x\", c4Shape.x + c4Shape.width / 2 - c4Shape.typeC4Shape.width / 2).attr(\"y\", c4Shape.y + c4Shape.typeC4Shape.Y).text(\"<<\" + c4Shape.typeC4Shape.text + \">>\");\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n case \"external_person\":\n drawImage(\n c4ShapeElem,\n 48,\n 48,\n c4Shape.x + c4Shape.width / 2 - 24,\n c4Shape.y + c4Shape.image.Y,\n personImg\n );\n break;\n }\n let textFontConf = conf2[c4Shape.typeC4Shape.text + \"Font\"]();\n textFontConf.fontWeight = \"bold\";\n textFontConf.fontSize = textFontConf.fontSize + 2;\n textFontConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n c4Shape.label.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.label.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor },\n textFontConf\n );\n textFontConf = conf2[c4Shape.typeC4Shape.text + \"Font\"]();\n textFontConf.fontColor = fontColor;\n if (c4Shape.techn && ((_a = c4Shape.techn) == null ? void 0 : _a.text) !== \"\") {\n _drawTextCandidateFunc(conf2)(\n c4Shape.techn.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.techn.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor, \"font-style\": \"italic\" },\n textFontConf\n );\n } else if (c4Shape.type && c4Shape.type.text !== \"\") {\n _drawTextCandidateFunc(conf2)(\n c4Shape.type.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.type.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor, \"font-style\": \"italic\" },\n textFontConf\n );\n }\n if (c4Shape.descr && c4Shape.descr.text !== \"\") {\n textFontConf = conf2.personFont();\n textFontConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n c4Shape.descr.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.descr.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor },\n textFontConf\n );\n }\n return c4Shape.height;\n};\nconst insertDatabaseIcon = function(elem) {\n elem.append(\"defs\").append(\"symbol\").attr(\"id\", \"database\").attr(\"fill-rule\", \"evenodd\").attr(\"clip-rule\", \"evenodd\").append(\"path\").attr(\"transform\", \"scale(.5)\").attr(\n \"d\",\n \"M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z\"\n );\n};\nconst insertComputerIcon = function(elem) {\n elem.append(\"defs\").append(\"symbol\").attr(\"id\", \"computer\").attr(\"width\", \"24\").attr(\"height\", \"24\").append(\"path\").attr(\"transform\", \"scale(.5)\").attr(\n \"d\",\n \"M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z\"\n );\n};\nconst insertClockIcon = function(elem) {\n elem.append(\"defs\").append(\"symbol\").attr(\"id\", \"clock\").attr(\"width\", \"24\").attr(\"height\", \"24\").append(\"path\").attr(\"transform\", \"scale(.5)\").attr(\n \"d\",\n \"M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z\"\n );\n};\nconst insertArrowHead = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"arrowhead\").attr(\"refX\", 9).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 0 0 L 10 5 L 0 10 z\");\n};\nconst insertArrowEnd = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"arrowend\").attr(\"refX\", 1).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 10 0 L 0 5 L 10 10 z\");\n};\nconst insertArrowFilledHead = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"filled-head\").attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L14,7 L9,1 Z\");\n};\nconst insertDynamicNumber = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"sequencenumber\").attr(\"refX\", 15).attr(\"refY\", 15).attr(\"markerWidth\", 60).attr(\"markerHeight\", 40).attr(\"orient\", \"auto\").append(\"circle\").attr(\"cx\", 15).attr(\"cy\", 15).attr(\"r\", 6);\n};\nconst insertArrowCrossHead = function(elem) {\n const defs = elem.append(\"defs\");\n const marker = defs.append(\"marker\").attr(\"id\", \"crosshead\").attr(\"markerWidth\", 15).attr(\"markerHeight\", 8).attr(\"orient\", \"auto\").attr(\"refX\", 16).attr(\"refY\", 4);\n marker.append(\"path\").attr(\"fill\", \"black\").attr(\"stroke\", \"#000000\").style(\"stroke-dasharray\", \"0, 0\").attr(\"stroke-width\", \"1px\").attr(\"d\", \"M 9,2 V 6 L16,4 Z\");\n marker.append(\"path\").attr(\"fill\", \"none\").attr(\"stroke\", \"#000000\").style(\"stroke-dasharray\", \"0, 0\").attr(\"stroke-width\", \"1px\").attr(\"d\", \"M 0,1 L 6,7 M 6,1 L 0,7\");\n};\nconst getC4ShapeFont = (cnf, typeC4Shape) => {\n return {\n fontFamily: cnf[typeC4Shape + \"FontFamily\"],\n fontSize: cnf[typeC4Shape + \"FontSize\"],\n fontWeight: cnf[typeC4Shape + \"FontWeight\"]\n };\n};\nconst _drawTextCandidateFunc = function() {\n function byText(content, g, x, y, width, height, textAttrs) {\n const text = g.append(\"text\").attr(\"x\", x + width / 2).attr(\"y\", y + height / 2 + 5).style(\"text-anchor\", \"middle\").text(content);\n _setTextAttrs(text, textAttrs);\n }\n function byTspan(content, g, x, y, width, height, textAttrs, conf2) {\n const { fontSize, fontFamily, fontWeight } = conf2;\n const lines = content.split(common.lineBreakRegex);\n for (let i = 0; i < lines.length; i++) {\n const dy = i * fontSize - fontSize * (lines.length - 1) / 2;\n const text = g.append(\"text\").attr(\"x\", x + width / 2).attr(\"y\", y).style(\"text-anchor\", \"middle\").attr(\"dominant-baseline\", \"middle\").style(\"font-size\", fontSize).style(\"font-weight\", fontWeight).style(\"font-family\", fontFamily);\n text.append(\"tspan\").attr(\"dy\", dy).text(lines[i]).attr(\"alignment-baseline\", \"mathematical\");\n _setTextAttrs(text, textAttrs);\n }\n }\n function byFo(content, g, x, y, width, height, textAttrs, conf2) {\n const s = g.append(\"switch\");\n const f = s.append(\"foreignObject\").attr(\"x\", x).attr(\"y\", y).attr(\"width\", width).attr(\"height\", height);\n const text = f.append(\"xhtml:div\").style(\"display\", \"table\").style(\"height\", \"100%\").style(\"width\", \"100%\");\n text.append(\"div\").style(\"display\", \"table-cell\").style(\"text-align\", \"center\").style(\"vertical-align\", \"middle\").text(content);\n byTspan(content, s, x, y, width, height, textAttrs, conf2);\n _setTextAttrs(text, textAttrs);\n }\n function _setTextAttrs(toText, fromTextAttrsDict) {\n for (const key in fromTextAttrsDict) {\n if (fromTextAttrsDict.hasOwnProperty(key)) {\n toText.attr(key, fromTextAttrsDict[key]);\n }\n }\n }\n return function(conf2) {\n return conf2.textPlacement === \"fo\" ? byFo : conf2.textPlacement === \"old\" ? byText : byTspan;\n };\n}();\nconst svgDraw = {\n drawRect,\n drawBoundary: drawBoundary$1,\n drawC4Shape,\n drawRels: drawRels$1,\n drawImage,\n insertArrowHead,\n insertArrowEnd,\n insertArrowFilledHead,\n insertDynamicNumber,\n insertArrowCrossHead,\n insertDatabaseIcon,\n insertComputerIcon,\n insertClockIcon\n};\nlet globalBoundaryMaxX = 0, globalBoundaryMaxY = 0;\nlet c4ShapeInRow = 4;\nlet c4BoundaryInRow = 2;\nparser.yy = db;\nlet conf = {};\nclass Bounds {\n constructor(diagObj) {\n this.name = \"\";\n this.data = {};\n this.data.startx = void 0;\n this.data.stopx = void 0;\n this.data.starty = void 0;\n this.data.stopy = void 0;\n this.data.widthLimit = void 0;\n this.nextData = {};\n this.nextData.startx = void 0;\n this.nextData.stopx = void 0;\n this.nextData.starty = void 0;\n this.nextData.stopy = void 0;\n this.nextData.cnt = 0;\n setConf(diagObj.db.getConfig());\n }\n setData(startx, stopx, starty, stopy) {\n this.nextData.startx = this.data.startx = startx;\n this.nextData.stopx = this.data.stopx = stopx;\n this.nextData.starty = this.data.starty = starty;\n this.nextData.stopy = this.data.stopy = stopy;\n }\n updateVal(obj, key, val, fun) {\n if (obj[key] === void 0) {\n obj[key] = val;\n } else {\n obj[key] = fun(val, obj[key]);\n }\n }\n insert(c4Shape) {\n this.nextData.cnt = this.nextData.cnt + 1;\n let _startx = this.nextData.startx === this.nextData.stopx ? this.nextData.stopx + c4Shape.margin : this.nextData.stopx + c4Shape.margin * 2;\n let _stopx = _startx + c4Shape.width;\n let _starty = this.nextData.starty + c4Shape.margin * 2;\n let _stopy = _starty + c4Shape.height;\n if (_startx >= this.data.widthLimit || _stopx >= this.data.widthLimit || this.nextData.cnt > c4ShapeInRow) {\n _startx = this.nextData.startx + c4Shape.margin + conf.nextLinePaddingX;\n _starty = this.nextData.stopy + c4Shape.margin * 2;\n this.nextData.stopx = _stopx = _startx + c4Shape.width;\n this.nextData.starty = this.nextData.stopy;\n this.nextData.stopy = _stopy = _starty + c4Shape.height;\n this.nextData.cnt = 1;\n }\n c4Shape.x = _startx;\n c4Shape.y = _starty;\n this.updateVal(this.data, \"startx\", _startx, Math.min);\n this.updateVal(this.data, \"starty\", _starty, Math.min);\n this.updateVal(this.data, \"stopx\", _stopx, Math.max);\n this.updateVal(this.data, \"stopy\", _stopy, Math.max);\n this.updateVal(this.nextData, \"startx\", _startx, Math.min);\n this.updateVal(this.nextData, \"starty\", _starty, Math.min);\n this.updateVal(this.nextData, \"stopx\", _stopx, Math.max);\n this.updateVal(this.nextData, \"stopy\", _stopy, Math.max);\n }\n init(diagObj) {\n this.name = \"\";\n this.data = {\n startx: void 0,\n stopx: void 0,\n starty: void 0,\n stopy: void 0,\n widthLimit: void 0\n };\n this.nextData = {\n startx: void 0,\n stopx: void 0,\n starty: void 0,\n stopy: void 0,\n cnt: 0\n };\n setConf(diagObj.db.getConfig());\n }\n bumpLastMargin(margin) {\n this.data.stopx += margin;\n this.data.stopy += margin;\n }\n}\nconst setConf = function(cnf) {\n assignWithDepth(conf, cnf);\n if (cnf.fontFamily) {\n conf.personFontFamily = conf.systemFontFamily = conf.messageFontFamily = cnf.fontFamily;\n }\n if (cnf.fontSize) {\n conf.personFontSize = conf.systemFontSize = conf.messageFontSize = cnf.fontSize;\n }\n if (cnf.fontWeight) {\n conf.personFontWeight = conf.systemFontWeight = conf.messageFontWeight = cnf.fontWeight;\n }\n};\nconst c4ShapeFont = (cnf, typeC4Shape) => {\n return {\n fontFamily: cnf[typeC4Shape + \"FontFamily\"],\n fontSize: cnf[typeC4Shape + \"FontSize\"],\n fontWeight: cnf[typeC4Shape + \"FontWeight\"]\n };\n};\nconst boundaryFont = (cnf) => {\n return {\n fontFamily: cnf.boundaryFontFamily,\n fontSize: cnf.boundaryFontSize,\n fontWeight: cnf.boundaryFontWeight\n };\n};\nconst messageFont = (cnf) => {\n return {\n fontFamily: cnf.messageFontFamily,\n fontSize: cnf.messageFontSize,\n fontWeight: cnf.messageFontWeight\n };\n};\nfunction calcC4ShapeTextWH(textType, c4Shape, c4ShapeTextWrap, textConf, textLimitWidth) {\n if (!c4Shape[textType].width) {\n if (c4ShapeTextWrap) {\n c4Shape[textType].text = wrapLabel(c4Shape[textType].text, textLimitWidth, textConf);\n c4Shape[textType].textLines = c4Shape[textType].text.split(common.lineBreakRegex).length;\n c4Shape[textType].width = textLimitWidth;\n c4Shape[textType].height = calculateTextHeight(c4Shape[textType].text, textConf);\n } else {\n let lines = c4Shape[textType].text.split(common.lineBreakRegex);\n c4Shape[textType].textLines = lines.length;\n let lineHeight = 0;\n c4Shape[textType].height = 0;\n c4Shape[textType].width = 0;\n for (const line of lines) {\n c4Shape[textType].width = Math.max(\n calculateTextWidth(line, textConf),\n c4Shape[textType].width\n );\n lineHeight = calculateTextHeight(line, textConf);\n c4Shape[textType].height = c4Shape[textType].height + lineHeight;\n }\n }\n }\n}\nconst drawBoundary = function(diagram2, boundary, bounds) {\n boundary.x = bounds.data.startx;\n boundary.y = bounds.data.starty;\n boundary.width = bounds.data.stopx - bounds.data.startx;\n boundary.height = bounds.data.stopy - bounds.data.starty;\n boundary.label.y = conf.c4ShapeMargin - 35;\n let boundaryTextWrap = boundary.wrap && conf.wrap;\n let boundaryLabelConf = boundaryFont(conf);\n boundaryLabelConf.fontSize = boundaryLabelConf.fontSize + 2;\n boundaryLabelConf.fontWeight = \"bold\";\n let textLimitWidth = calculateTextWidth(boundary.label.text, boundaryLabelConf);\n calcC4ShapeTextWH(\"label\", boundary, boundaryTextWrap, boundaryLabelConf, textLimitWidth);\n svgDraw.drawBoundary(diagram2, boundary, conf);\n};\nconst drawC4ShapeArray = function(currentBounds, diagram2, c4ShapeArray2, c4ShapeKeys) {\n let Y = 0;\n for (const c4ShapeKey of c4ShapeKeys) {\n Y = 0;\n const c4Shape = c4ShapeArray2[c4ShapeKey];\n let c4ShapeTypeConf = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n c4ShapeTypeConf.fontSize = c4ShapeTypeConf.fontSize - 2;\n c4Shape.typeC4Shape.width = calculateTextWidth(\n \"\u00AB\" + c4Shape.typeC4Shape.text + \"\u00BB\",\n c4ShapeTypeConf\n );\n c4Shape.typeC4Shape.height = c4ShapeTypeConf.fontSize + 2;\n c4Shape.typeC4Shape.Y = conf.c4ShapePadding;\n Y = c4Shape.typeC4Shape.Y + c4Shape.typeC4Shape.height - 4;\n c4Shape.image = { width: 0, height: 0, Y: 0 };\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n case \"external_person\":\n c4Shape.image.width = 48;\n c4Shape.image.height = 48;\n c4Shape.image.Y = Y;\n Y = c4Shape.image.Y + c4Shape.image.height;\n break;\n }\n if (c4Shape.sprite) {\n c4Shape.image.width = 48;\n c4Shape.image.height = 48;\n c4Shape.image.Y = Y;\n Y = c4Shape.image.Y + c4Shape.image.height;\n }\n let c4ShapeTextWrap = c4Shape.wrap && conf.wrap;\n let textLimitWidth = conf.width - conf.c4ShapePadding * 2;\n let c4ShapeLabelConf = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n c4ShapeLabelConf.fontSize = c4ShapeLabelConf.fontSize + 2;\n c4ShapeLabelConf.fontWeight = \"bold\";\n calcC4ShapeTextWH(\"label\", c4Shape, c4ShapeTextWrap, c4ShapeLabelConf, textLimitWidth);\n c4Shape[\"label\"].Y = Y + 8;\n Y = c4Shape[\"label\"].Y + c4Shape[\"label\"].height;\n if (c4Shape.type && c4Shape.type.text !== \"\") {\n c4Shape.type.text = \"[\" + c4Shape.type.text + \"]\";\n let c4ShapeTypeConf2 = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n calcC4ShapeTextWH(\"type\", c4Shape, c4ShapeTextWrap, c4ShapeTypeConf2, textLimitWidth);\n c4Shape[\"type\"].Y = Y + 5;\n Y = c4Shape[\"type\"].Y + c4Shape[\"type\"].height;\n } else if (c4Shape.techn && c4Shape.techn.text !== \"\") {\n c4Shape.techn.text = \"[\" + c4Shape.techn.text + \"]\";\n let c4ShapeTechnConf = c4ShapeFont(conf, c4Shape.techn.text);\n calcC4ShapeTextWH(\"techn\", c4Shape, c4ShapeTextWrap, c4ShapeTechnConf, textLimitWidth);\n c4Shape[\"techn\"].Y = Y + 5;\n Y = c4Shape[\"techn\"].Y + c4Shape[\"techn\"].height;\n }\n let rectHeight = Y;\n let rectWidth = c4Shape.label.width;\n if (c4Shape.descr && c4Shape.descr.text !== \"\") {\n let c4ShapeDescrConf = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n calcC4ShapeTextWH(\"descr\", c4Shape, c4ShapeTextWrap, c4ShapeDescrConf, textLimitWidth);\n c4Shape[\"descr\"].Y = Y + 20;\n Y = c4Shape[\"descr\"].Y + c4Shape[\"descr\"].height;\n rectWidth = Math.max(c4Shape.label.width, c4Shape.descr.width);\n rectHeight = Y - c4Shape[\"descr\"].textLines * 5;\n }\n rectWidth = rectWidth + conf.c4ShapePadding;\n c4Shape.width = Math.max(c4Shape.width || conf.width, rectWidth, conf.width);\n c4Shape.height = Math.max(c4Shape.height || conf.height, rectHeight, conf.height);\n c4Shape.margin = c4Shape.margin || conf.c4ShapeMargin;\n currentBounds.insert(c4Shape);\n svgDraw.drawC4Shape(diagram2, c4Shape, conf);\n }\n currentBounds.bumpLastMargin(conf.c4ShapeMargin);\n};\nclass Point {\n constructor(x, y) {\n this.x = x;\n this.y = y;\n }\n}\nlet getIntersectPoint = function(fromNode, endPoint) {\n let x1 = fromNode.x;\n let y1 = fromNode.y;\n let x2 = endPoint.x;\n let y2 = endPoint.y;\n let fromCenterX = x1 + fromNode.width / 2;\n let fromCenterY = y1 + fromNode.height / 2;\n let dx = Math.abs(x1 - x2);\n let dy = Math.abs(y1 - y2);\n let tanDYX = dy / dx;\n let fromDYX = fromNode.height / fromNode.width;\n let returnPoint = null;\n if (y1 == y2 && x1 < x2) {\n returnPoint = new Point(x1 + fromNode.width, fromCenterY);\n } else if (y1 == y2 && x1 > x2) {\n returnPoint = new Point(x1, fromCenterY);\n } else if (x1 == x2 && y1 < y2) {\n returnPoint = new Point(fromCenterX, y1 + fromNode.height);\n } else if (x1 == x2 && y1 > y2) {\n returnPoint = new Point(fromCenterX, y1);\n }\n if (x1 > x2 && y1 < y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1, fromCenterY + tanDYX * fromNode.width / 2);\n } else {\n returnPoint = new Point(\n fromCenterX - dx / dy * fromNode.height / 2,\n y1 + fromNode.height\n );\n }\n } else if (x1 < x2 && y1 < y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1 + fromNode.width, fromCenterY + tanDYX * fromNode.width / 2);\n } else {\n returnPoint = new Point(\n fromCenterX + dx / dy * fromNode.height / 2,\n y1 + fromNode.height\n );\n }\n } else if (x1 < x2 && y1 > y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1 + fromNode.width, fromCenterY - tanDYX * fromNode.width / 2);\n } else {\n returnPoint = new Point(fromCenterX + fromNode.height / 2 * dx / dy, y1);\n }\n } else if (x1 > x2 && y1 > y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1, fromCenterY - fromNode.width / 2 * tanDYX);\n } else {\n returnPoint = new Point(fromCenterX - fromNode.height / 2 * dx / dy, y1);\n }\n }\n return returnPoint;\n};\nlet getIntersectPoints = function(fromNode, endNode) {\n let endIntersectPoint = { x: 0, y: 0 };\n endIntersectPoint.x = endNode.x + endNode.width / 2;\n endIntersectPoint.y = endNode.y + endNode.height / 2;\n let startPoint = getIntersectPoint(fromNode, endIntersectPoint);\n endIntersectPoint.x = fromNode.x + fromNode.width / 2;\n endIntersectPoint.y = fromNode.y + fromNode.height / 2;\n let endPoint = getIntersectPoint(endNode, endIntersectPoint);\n return { startPoint, endPoint };\n};\nconst drawRels = function(diagram2, rels2, getC4ShapeObj, diagObj) {\n let i = 0;\n for (let rel of rels2) {\n i = i + 1;\n let relTextWrap = rel.wrap && conf.wrap;\n let relConf = messageFont(conf);\n let diagramType = diagObj.db.getC4Type();\n if (diagramType === \"C4Dynamic\") {\n rel.label.text = i + \": \" + rel.label.text;\n }\n let textLimitWidth = calculateTextWidth(rel.label.text, relConf);\n calcC4ShapeTextWH(\"label\", rel, relTextWrap, relConf, textLimitWidth);\n if (rel.techn && rel.techn.text !== \"\") {\n textLimitWidth = calculateTextWidth(rel.techn.text, relConf);\n calcC4ShapeTextWH(\"techn\", rel, relTextWrap, relConf, textLimitWidth);\n }\n if (rel.descr && rel.descr.text !== \"\") {\n textLimitWidth = calculateTextWidth(rel.descr.text, relConf);\n calcC4ShapeTextWH(\"descr\", rel, relTextWrap, relConf, textLimitWidth);\n }\n let fromNode = getC4ShapeObj(rel.from);\n let endNode = getC4ShapeObj(rel.to);\n let points = getIntersectPoints(fromNode, endNode);\n rel.startPoint = points.startPoint;\n rel.endPoint = points.endPoint;\n }\n svgDraw.drawRels(diagram2, rels2, conf);\n};\nfunction drawInsideBoundary(diagram2, parentBoundaryAlias, parentBounds, currentBoundaries, diagObj) {\n let currentBounds = new Bounds(diagObj);\n currentBounds.data.widthLimit = parentBounds.data.widthLimit / Math.min(c4BoundaryInRow, currentBoundaries.length);\n for (let [i, currentBoundary] of currentBoundaries.entries()) {\n let Y = 0;\n currentBoundary.image = { width: 0, height: 0, Y: 0 };\n if (currentBoundary.sprite) {\n currentBoundary.image.width = 48;\n currentBoundary.image.height = 48;\n currentBoundary.image.Y = Y;\n Y = currentBoundary.image.Y + currentBoundary.image.height;\n }\n let currentBoundaryTextWrap = currentBoundary.wrap && conf.wrap;\n let currentBoundaryLabelConf = boundaryFont(conf);\n currentBoundaryLabelConf.fontSize = currentBoundaryLabelConf.fontSize + 2;\n currentBoundaryLabelConf.fontWeight = \"bold\";\n calcC4ShapeTextWH(\n \"label\",\n currentBoundary,\n currentBoundaryTextWrap,\n currentBoundaryLabelConf,\n currentBounds.data.widthLimit\n );\n currentBoundary[\"label\"].Y = Y + 8;\n Y = currentBoundary[\"label\"].Y + currentBoundary[\"label\"].height;\n if (currentBoundary.type && currentBoundary.type.text !== \"\") {\n currentBoundary.type.text = \"[\" + currentBoundary.type.text + \"]\";\n let currentBoundaryTypeConf = boundaryFont(conf);\n calcC4ShapeTextWH(\n \"type\",\n currentBoundary,\n currentBoundaryTextWrap,\n currentBoundaryTypeConf,\n currentBounds.data.widthLimit\n );\n currentBoundary[\"type\"].Y = Y + 5;\n Y = currentBoundary[\"type\"].Y + currentBoundary[\"type\"].height;\n }\n if (currentBoundary.descr && currentBoundary.descr.text !== \"\") {\n let currentBoundaryDescrConf = boundaryFont(conf);\n currentBoundaryDescrConf.fontSize = currentBoundaryDescrConf.fontSize - 2;\n calcC4ShapeTextWH(\n \"descr\",\n currentBoundary,\n currentBoundaryTextWrap,\n currentBoundaryDescrConf,\n currentBounds.data.widthLimit\n );\n currentBoundary[\"descr\"].Y = Y + 20;\n Y = currentBoundary[\"descr\"].Y + currentBoundary[\"descr\"].height;\n }\n if (i == 0 || i % c4BoundaryInRow === 0) {\n let _x = parentBounds.data.startx + conf.diagramMarginX;\n let _y = parentBounds.data.stopy + conf.diagramMarginY + Y;\n currentBounds.setData(_x, _x, _y, _y);\n } else {\n let _x = currentBounds.data.stopx !== currentBounds.data.startx ? currentBounds.data.stopx + conf.diagramMarginX : currentBounds.data.startx;\n let _y = currentBounds.data.starty;\n currentBounds.setData(_x, _x, _y, _y);\n }\n currentBounds.name = currentBoundary.alias;\n let currentPersonOrSystemArray = diagObj.db.getC4ShapeArray(currentBoundary.alias);\n let currentPersonOrSystemKeys = diagObj.db.getC4ShapeKeys(currentBoundary.alias);\n if (currentPersonOrSystemKeys.length > 0) {\n drawC4ShapeArray(\n currentBounds,\n diagram2,\n currentPersonOrSystemArray,\n currentPersonOrSystemKeys\n );\n }\n parentBoundaryAlias = currentBoundary.alias;\n let nextCurrentBoundarys = diagObj.db.getBoundarys(parentBoundaryAlias);\n if (nextCurrentBoundarys.length > 0) {\n drawInsideBoundary(\n diagram2,\n parentBoundaryAlias,\n currentBounds,\n nextCurrentBoundarys,\n diagObj\n );\n }\n if (currentBoundary.alias !== \"global\") {\n drawBoundary(diagram2, currentBoundary, currentBounds);\n }\n parentBounds.data.stopy = Math.max(\n currentBounds.data.stopy + conf.c4ShapeMargin,\n parentBounds.data.stopy\n );\n parentBounds.data.stopx = Math.max(\n currentBounds.data.stopx + conf.c4ShapeMargin,\n parentBounds.data.stopx\n );\n globalBoundaryMaxX = Math.max(globalBoundaryMaxX, parentBounds.data.stopx);\n globalBoundaryMaxY = Math.max(globalBoundaryMaxY, parentBounds.data.stopy);\n }\n}\nconst draw = function(_text, id, _version, diagObj) {\n conf = getConfig().c4;\n const securityLevel = getConfig().securityLevel;\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n let db2 = diagObj.db;\n diagObj.db.setWrap(conf.wrap);\n c4ShapeInRow = db2.getC4ShapeInRow();\n c4BoundaryInRow = db2.getC4BoundaryInRow();\n log.debug(`C:${JSON.stringify(conf, null, 2)}`);\n const diagram2 = securityLevel === \"sandbox\" ? root.select(`[id=\"${id}\"]`) : select(`[id=\"${id}\"]`);\n svgDraw.insertComputerIcon(diagram2);\n svgDraw.insertDatabaseIcon(diagram2);\n svgDraw.insertClockIcon(diagram2);\n let screenBounds = new Bounds(diagObj);\n screenBounds.setData(\n conf.diagramMarginX,\n conf.diagramMarginX,\n conf.diagramMarginY,\n conf.diagramMarginY\n );\n screenBounds.data.widthLimit = screen.availWidth;\n globalBoundaryMaxX = conf.diagramMarginX;\n globalBoundaryMaxY = conf.diagramMarginY;\n const title2 = diagObj.db.getTitle();\n let currentBoundaries = diagObj.db.getBoundarys(\"\");\n drawInsideBoundary(diagram2, \"\", screenBounds, currentBoundaries, diagObj);\n svgDraw.insertArrowHead(diagram2);\n svgDraw.insertArrowEnd(diagram2);\n svgDraw.insertArrowCrossHead(diagram2);\n svgDraw.insertArrowFilledHead(diagram2);\n drawRels(diagram2, diagObj.db.getRels(), diagObj.db.getC4Shape, diagObj);\n screenBounds.data.stopx = globalBoundaryMaxX;\n screenBounds.data.stopy = globalBoundaryMaxY;\n const box = screenBounds.data;\n let boxHeight = box.stopy - box.starty;\n let height = boxHeight + 2 * conf.diagramMarginY;\n let boxWidth = box.stopx - box.startx;\n const width = boxWidth + 2 * conf.diagramMarginX;\n if (title2) {\n diagram2.append(\"text\").text(title2).attr(\"x\", (box.stopx - box.startx) / 2 - 4 * conf.diagramMarginX).attr(\"y\", box.starty + conf.diagramMarginY);\n }\n configureSvgSize(diagram2, height, width, conf.useMaxWidth);\n const extraVertForTitle = title2 ? 60 : 0;\n diagram2.attr(\n \"viewBox\",\n box.startx - conf.diagramMarginX + \" -\" + (conf.diagramMarginY + extraVertForTitle) + \" \" + width + \" \" + (height + extraVertForTitle)\n );\n log.debug(`models:`, box);\n};\nconst renderer = {\n drawPersonOrSystemArray: drawC4ShapeArray,\n drawBoundary,\n setConf,\n draw\n};\nconst getStyles = (options) => `.person {\n stroke: ${options.personBorder};\n fill: ${options.personBkg};\n }\n`;\nconst styles = getStyles;\nconst diagram = {\n parser: parser$1,\n db,\n renderer,\n styles,\n init: ({ c4, wrap }) => {\n renderer.setConf(c4);\n db.setWrap(wrap);\n }\n};\nexport {\n diagram\n};\n"], + "sources": ["../../node_modules/mermaid/dist/c4Diagram-817c8e44.js"], + "sourcesContent": ["import { s as setAccTitle, g as getAccTitle, a as getAccDescription, b as setAccDescription, c as getConfig, d as sanitizeText, e as common, f as assignWithDepth, h as calculateTextWidth, l as log, i as configureSvgSize, w as wrapLabel, j as calculateTextHeight } from \"./mermaid-934d9bea.js\";\nimport { select } from \"d3\";\nimport { d as drawRect$1, g as getNoteRect } from \"./svgDrawCommon-ad5ef572.js\";\nimport { sanitizeUrl } from \"@braintree/sanitize-url\";\nimport \"ts-dedent\";\nimport \"dayjs\";\nimport \"dompurify\";\nimport \"khroma\";\nimport \"lodash-es/memoize.js\";\nimport \"lodash-es/merge.js\";\nimport \"stylis\";\nimport \"lodash-es/isEmpty.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 24], $V1 = [1, 25], $V2 = [1, 26], $V3 = [1, 27], $V4 = [1, 28], $V5 = [1, 63], $V6 = [1, 64], $V7 = [1, 65], $V8 = [1, 66], $V9 = [1, 67], $Va = [1, 68], $Vb = [1, 69], $Vc = [1, 29], $Vd = [1, 30], $Ve = [1, 31], $Vf = [1, 32], $Vg = [1, 33], $Vh = [1, 34], $Vi = [1, 35], $Vj = [1, 36], $Vk = [1, 37], $Vl = [1, 38], $Vm = [1, 39], $Vn = [1, 40], $Vo = [1, 41], $Vp = [1, 42], $Vq = [1, 43], $Vr = [1, 44], $Vs = [1, 45], $Vt = [1, 46], $Vu = [1, 47], $Vv = [1, 48], $Vw = [1, 50], $Vx = [1, 51], $Vy = [1, 52], $Vz = [1, 53], $VA = [1, 54], $VB = [1, 55], $VC = [1, 56], $VD = [1, 57], $VE = [1, 58], $VF = [1, 59], $VG = [1, 60], $VH = [14, 42], $VI = [14, 34, 36, 37, 38, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74], $VJ = [12, 14, 34, 36, 37, 38, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74], $VK = [1, 82], $VL = [1, 83], $VM = [1, 84], $VN = [1, 85], $VO = [12, 14, 42], $VP = [12, 14, 33, 42], $VQ = [12, 14, 33, 42, 76, 77, 79, 80], $VR = [12, 33], $VS = [34, 36, 37, 38, 39, 40, 41, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"mermaidDoc\": 4, \"direction\": 5, \"direction_tb\": 6, \"direction_bt\": 7, \"direction_rl\": 8, \"direction_lr\": 9, \"graphConfig\": 10, \"C4_CONTEXT\": 11, \"NEWLINE\": 12, \"statements\": 13, \"EOF\": 14, \"C4_CONTAINER\": 15, \"C4_COMPONENT\": 16, \"C4_DYNAMIC\": 17, \"C4_DEPLOYMENT\": 18, \"otherStatements\": 19, \"diagramStatements\": 20, \"otherStatement\": 21, \"title\": 22, \"accDescription\": 23, \"acc_title\": 24, \"acc_title_value\": 25, \"acc_descr\": 26, \"acc_descr_value\": 27, \"acc_descr_multiline_value\": 28, \"boundaryStatement\": 29, \"boundaryStartStatement\": 30, \"boundaryStopStatement\": 31, \"boundaryStart\": 32, \"LBRACE\": 33, \"ENTERPRISE_BOUNDARY\": 34, \"attributes\": 35, \"SYSTEM_BOUNDARY\": 36, \"BOUNDARY\": 37, \"CONTAINER_BOUNDARY\": 38, \"NODE\": 39, \"NODE_L\": 40, \"NODE_R\": 41, \"RBRACE\": 42, \"diagramStatement\": 43, \"PERSON\": 44, \"PERSON_EXT\": 45, \"SYSTEM\": 46, \"SYSTEM_DB\": 47, \"SYSTEM_QUEUE\": 48, \"SYSTEM_EXT\": 49, \"SYSTEM_EXT_DB\": 50, \"SYSTEM_EXT_QUEUE\": 51, \"CONTAINER\": 52, \"CONTAINER_DB\": 53, \"CONTAINER_QUEUE\": 54, \"CONTAINER_EXT\": 55, \"CONTAINER_EXT_DB\": 56, \"CONTAINER_EXT_QUEUE\": 57, \"COMPONENT\": 58, \"COMPONENT_DB\": 59, \"COMPONENT_QUEUE\": 60, \"COMPONENT_EXT\": 61, \"COMPONENT_EXT_DB\": 62, \"COMPONENT_EXT_QUEUE\": 63, \"REL\": 64, \"BIREL\": 65, \"REL_U\": 66, \"REL_D\": 67, \"REL_L\": 68, \"REL_R\": 69, \"REL_B\": 70, \"REL_INDEX\": 71, \"UPDATE_EL_STYLE\": 72, \"UPDATE_REL_STYLE\": 73, \"UPDATE_LAYOUT_CONFIG\": 74, \"attribute\": 75, \"STR\": 76, \"STR_KEY\": 77, \"STR_VALUE\": 78, \"ATTRIBUTE\": 79, \"ATTRIBUTE_EMPTY\": 80, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 6: \"direction_tb\", 7: \"direction_bt\", 8: \"direction_rl\", 9: \"direction_lr\", 11: \"C4_CONTEXT\", 12: \"NEWLINE\", 14: \"EOF\", 15: \"C4_CONTAINER\", 16: \"C4_COMPONENT\", 17: \"C4_DYNAMIC\", 18: \"C4_DEPLOYMENT\", 22: \"title\", 23: \"accDescription\", 24: \"acc_title\", 25: \"acc_title_value\", 26: \"acc_descr\", 27: \"acc_descr_value\", 28: \"acc_descr_multiline_value\", 33: \"LBRACE\", 34: \"ENTERPRISE_BOUNDARY\", 36: \"SYSTEM_BOUNDARY\", 37: \"BOUNDARY\", 38: \"CONTAINER_BOUNDARY\", 39: \"NODE\", 40: \"NODE_L\", 41: \"NODE_R\", 42: \"RBRACE\", 44: \"PERSON\", 45: \"PERSON_EXT\", 46: \"SYSTEM\", 47: \"SYSTEM_DB\", 48: \"SYSTEM_QUEUE\", 49: \"SYSTEM_EXT\", 50: \"SYSTEM_EXT_DB\", 51: \"SYSTEM_EXT_QUEUE\", 52: \"CONTAINER\", 53: \"CONTAINER_DB\", 54: \"CONTAINER_QUEUE\", 55: \"CONTAINER_EXT\", 56: \"CONTAINER_EXT_DB\", 57: \"CONTAINER_EXT_QUEUE\", 58: \"COMPONENT\", 59: \"COMPONENT_DB\", 60: \"COMPONENT_QUEUE\", 61: \"COMPONENT_EXT\", 62: \"COMPONENT_EXT_DB\", 63: \"COMPONENT_EXT_QUEUE\", 64: \"REL\", 65: \"BIREL\", 66: \"REL_U\", 67: \"REL_D\", 68: \"REL_L\", 69: \"REL_R\", 70: \"REL_B\", 71: \"REL_INDEX\", 72: \"UPDATE_EL_STYLE\", 73: \"UPDATE_REL_STYLE\", 74: \"UPDATE_LAYOUT_CONFIG\", 76: \"STR\", 77: \"STR_KEY\", 78: \"STR_VALUE\", 79: \"ATTRIBUTE\", 80: \"ATTRIBUTE_EMPTY\" },\n productions_: [0, [3, 1], [3, 1], [5, 1], [5, 1], [5, 1], [5, 1], [4, 1], [10, 4], [10, 4], [10, 4], [10, 4], [10, 4], [13, 1], [13, 1], [13, 2], [19, 1], [19, 2], [19, 3], [21, 1], [21, 1], [21, 2], [21, 2], [21, 1], [29, 3], [30, 3], [30, 3], [30, 4], [32, 2], [32, 2], [32, 2], [32, 2], [32, 2], [32, 2], [32, 2], [31, 1], [20, 1], [20, 2], [20, 3], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 1], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [43, 2], [35, 1], [35, 2], [75, 1], [75, 2], [75, 1], [75, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 3:\n yy.setDirection(\"TB\");\n break;\n case 4:\n yy.setDirection(\"BT\");\n break;\n case 5:\n yy.setDirection(\"RL\");\n break;\n case 6:\n yy.setDirection(\"LR\");\n break;\n case 8:\n case 9:\n case 10:\n case 11:\n case 12:\n yy.setC4Type($$[$0 - 3]);\n break;\n case 19:\n yy.setTitle($$[$0].substring(6));\n this.$ = $$[$0].substring(6);\n break;\n case 20:\n yy.setAccDescription($$[$0].substring(15));\n this.$ = $$[$0].substring(15);\n break;\n case 21:\n this.$ = $$[$0].trim();\n yy.setTitle(this.$);\n break;\n case 22:\n case 23:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 28:\n case 29:\n $$[$0].splice(2, 0, \"ENTERPRISE\");\n yy.addPersonOrSystemBoundary(...$$[$0]);\n this.$ = $$[$0];\n break;\n case 30:\n yy.addPersonOrSystemBoundary(...$$[$0]);\n this.$ = $$[$0];\n break;\n case 31:\n $$[$0].splice(2, 0, \"CONTAINER\");\n yy.addContainerBoundary(...$$[$0]);\n this.$ = $$[$0];\n break;\n case 32:\n yy.addDeploymentNode(\"node\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 33:\n yy.addDeploymentNode(\"nodeL\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 34:\n yy.addDeploymentNode(\"nodeR\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 35:\n yy.popBoundaryParseStack();\n break;\n case 39:\n yy.addPersonOrSystem(\"person\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 40:\n yy.addPersonOrSystem(\"external_person\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 41:\n yy.addPersonOrSystem(\"system\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 42:\n yy.addPersonOrSystem(\"system_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 43:\n yy.addPersonOrSystem(\"system_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 44:\n yy.addPersonOrSystem(\"external_system\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 45:\n yy.addPersonOrSystem(\"external_system_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 46:\n yy.addPersonOrSystem(\"external_system_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 47:\n yy.addContainer(\"container\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 48:\n yy.addContainer(\"container_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 49:\n yy.addContainer(\"container_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 50:\n yy.addContainer(\"external_container\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 51:\n yy.addContainer(\"external_container_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 52:\n yy.addContainer(\"external_container_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 53:\n yy.addComponent(\"component\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 54:\n yy.addComponent(\"component_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 55:\n yy.addComponent(\"component_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 56:\n yy.addComponent(\"external_component\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 57:\n yy.addComponent(\"external_component_db\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 58:\n yy.addComponent(\"external_component_queue\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 60:\n yy.addRel(\"rel\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 61:\n yy.addRel(\"birel\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 62:\n yy.addRel(\"rel_u\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 63:\n yy.addRel(\"rel_d\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 64:\n yy.addRel(\"rel_l\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 65:\n yy.addRel(\"rel_r\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 66:\n yy.addRel(\"rel_b\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 67:\n $$[$0].splice(0, 1);\n yy.addRel(\"rel\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 68:\n yy.updateElStyle(\"update_el_style\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 69:\n yy.updateRelStyle(\"update_rel_style\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 70:\n yy.updateLayoutConfig(\"update_layout_config\", ...$$[$0]);\n this.$ = $$[$0];\n break;\n case 71:\n this.$ = [$$[$0]];\n break;\n case 72:\n $$[$0].unshift($$[$0 - 1]);\n this.$ = $$[$0];\n break;\n case 73:\n case 75:\n this.$ = $$[$0].trim();\n break;\n case 74:\n let kv = {};\n kv[$$[$0 - 1].trim()] = $$[$0].trim();\n this.$ = kv;\n break;\n case 76:\n this.$ = \"\";\n break;\n }\n },\n table: [{ 3: 1, 4: 2, 5: 3, 6: [1, 5], 7: [1, 6], 8: [1, 7], 9: [1, 8], 10: 4, 11: [1, 9], 15: [1, 10], 16: [1, 11], 17: [1, 12], 18: [1, 13] }, { 1: [3] }, { 1: [2, 1] }, { 1: [2, 2] }, { 1: [2, 7] }, { 1: [2, 3] }, { 1: [2, 4] }, { 1: [2, 5] }, { 1: [2, 6] }, { 12: [1, 14] }, { 12: [1, 15] }, { 12: [1, 16] }, { 12: [1, 17] }, { 12: [1, 18] }, { 13: 19, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 70, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 71, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 72, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 13: 73, 19: 20, 20: 21, 21: 22, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 14: [1, 74] }, o($VH, [2, 13], { 43: 23, 29: 49, 30: 61, 32: 62, 20: 75, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }), o($VH, [2, 14]), o($VI, [2, 16], { 12: [1, 76] }), o($VH, [2, 36], { 12: [1, 77] }), o($VJ, [2, 19]), o($VJ, [2, 20]), { 25: [1, 78] }, { 27: [1, 79] }, o($VJ, [2, 23]), { 35: 80, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 86, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 87, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 88, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 89, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 90, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 91, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 92, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 93, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 94, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 95, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 96, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 97, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 98, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 99, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 100, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 101, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 102, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 103, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 104, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, o($VO, [2, 59]), { 35: 105, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 106, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 107, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 108, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 109, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 110, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 111, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 112, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 113, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 114, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 115, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 20: 116, 29: 49, 30: 61, 32: 62, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 43: 23, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }, { 12: [1, 118], 33: [1, 117] }, { 35: 119, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 120, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 121, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 122, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 123, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 124, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 35: 125, 75: 81, 76: $VK, 77: $VL, 79: $VM, 80: $VN }, { 14: [1, 126] }, { 14: [1, 127] }, { 14: [1, 128] }, { 14: [1, 129] }, { 1: [2, 8] }, o($VH, [2, 15]), o($VI, [2, 17], { 21: 22, 19: 130, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4 }), o($VH, [2, 37], { 19: 20, 20: 21, 21: 22, 43: 23, 29: 49, 30: 61, 32: 62, 13: 131, 22: $V0, 23: $V1, 24: $V2, 26: $V3, 28: $V4, 34: $V5, 36: $V6, 37: $V7, 38: $V8, 39: $V9, 40: $Va, 41: $Vb, 44: $Vc, 45: $Vd, 46: $Ve, 47: $Vf, 48: $Vg, 49: $Vh, 50: $Vi, 51: $Vj, 52: $Vk, 53: $Vl, 54: $Vm, 55: $Vn, 56: $Vo, 57: $Vp, 58: $Vq, 59: $Vr, 60: $Vs, 61: $Vt, 62: $Vu, 63: $Vv, 64: $Vw, 65: $Vx, 66: $Vy, 67: $Vz, 68: $VA, 69: $VB, 70: $VC, 71: $VD, 72: $VE, 73: $VF, 74: $VG }), o($VJ, [2, 21]), o($VJ, [2, 22]), o($VO, [2, 39]), o($VP, [2, 71], { 75: 81, 35: 132, 76: $VK, 77: $VL, 79: $VM, 80: $VN }), o($VQ, [2, 73]), { 78: [1, 133] }, o($VQ, [2, 75]), o($VQ, [2, 76]), o($VO, [2, 40]), o($VO, [2, 41]), o($VO, [2, 42]), o($VO, [2, 43]), o($VO, [2, 44]), o($VO, [2, 45]), o($VO, [2, 46]), o($VO, [2, 47]), o($VO, [2, 48]), o($VO, [2, 49]), o($VO, [2, 50]), o($VO, [2, 51]), o($VO, [2, 52]), o($VO, [2, 53]), o($VO, [2, 54]), o($VO, [2, 55]), o($VO, [2, 56]), o($VO, [2, 57]), o($VO, [2, 58]), o($VO, [2, 60]), o($VO, [2, 61]), o($VO, [2, 62]), o($VO, [2, 63]), o($VO, [2, 64]), o($VO, [2, 65]), o($VO, [2, 66]), o($VO, [2, 67]), o($VO, [2, 68]), o($VO, [2, 69]), o($VO, [2, 70]), { 31: 134, 42: [1, 135] }, { 12: [1, 136] }, { 33: [1, 137] }, o($VR, [2, 28]), o($VR, [2, 29]), o($VR, [2, 30]), o($VR, [2, 31]), o($VR, [2, 32]), o($VR, [2, 33]), o($VR, [2, 34]), { 1: [2, 9] }, { 1: [2, 10] }, { 1: [2, 11] }, { 1: [2, 12] }, o($VI, [2, 18]), o($VH, [2, 38]), o($VP, [2, 72]), o($VQ, [2, 74]), o($VO, [2, 24]), o($VO, [2, 35]), o($VS, [2, 25]), o($VS, [2, 26], { 12: [1, 138] }), o($VS, [2, 27])],\n defaultActions: { 2: [2, 1], 3: [2, 2], 4: [2, 7], 5: [2, 3], 6: [2, 4], 7: [2, 5], 8: [2, 6], 74: [2, 8], 126: [2, 9], 127: [2, 10], 128: [2, 11], 129: [2, 12] },\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c2 = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c2 + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: {},\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n return 6;\n case 1:\n return 7;\n case 2:\n return 8;\n case 3:\n return 9;\n case 4:\n return 22;\n case 5:\n return 23;\n case 6:\n this.begin(\"acc_title\");\n return 24;\n case 7:\n this.popState();\n return \"acc_title_value\";\n case 8:\n this.begin(\"acc_descr\");\n return 26;\n case 9:\n this.popState();\n return \"acc_descr_value\";\n case 10:\n this.begin(\"acc_descr_multiline\");\n break;\n case 11:\n this.popState();\n break;\n case 12:\n return \"acc_descr_multiline_value\";\n case 13:\n break;\n case 14:\n c;\n break;\n case 15:\n return 12;\n case 16:\n break;\n case 17:\n return 11;\n case 18:\n return 15;\n case 19:\n return 16;\n case 20:\n return 17;\n case 21:\n return 18;\n case 22:\n this.begin(\"person_ext\");\n return 45;\n case 23:\n this.begin(\"person\");\n return 44;\n case 24:\n this.begin(\"system_ext_queue\");\n return 51;\n case 25:\n this.begin(\"system_ext_db\");\n return 50;\n case 26:\n this.begin(\"system_ext\");\n return 49;\n case 27:\n this.begin(\"system_queue\");\n return 48;\n case 28:\n this.begin(\"system_db\");\n return 47;\n case 29:\n this.begin(\"system\");\n return 46;\n case 30:\n this.begin(\"boundary\");\n return 37;\n case 31:\n this.begin(\"enterprise_boundary\");\n return 34;\n case 32:\n this.begin(\"system_boundary\");\n return 36;\n case 33:\n this.begin(\"container_ext_queue\");\n return 57;\n case 34:\n this.begin(\"container_ext_db\");\n return 56;\n case 35:\n this.begin(\"container_ext\");\n return 55;\n case 36:\n this.begin(\"container_queue\");\n return 54;\n case 37:\n this.begin(\"container_db\");\n return 53;\n case 38:\n this.begin(\"container\");\n return 52;\n case 39:\n this.begin(\"container_boundary\");\n return 38;\n case 40:\n this.begin(\"component_ext_queue\");\n return 63;\n case 41:\n this.begin(\"component_ext_db\");\n return 62;\n case 42:\n this.begin(\"component_ext\");\n return 61;\n case 43:\n this.begin(\"component_queue\");\n return 60;\n case 44:\n this.begin(\"component_db\");\n return 59;\n case 45:\n this.begin(\"component\");\n return 58;\n case 46:\n this.begin(\"node\");\n return 39;\n case 47:\n this.begin(\"node\");\n return 39;\n case 48:\n this.begin(\"node_l\");\n return 40;\n case 49:\n this.begin(\"node_r\");\n return 41;\n case 50:\n this.begin(\"rel\");\n return 64;\n case 51:\n this.begin(\"birel\");\n return 65;\n case 52:\n this.begin(\"rel_u\");\n return 66;\n case 53:\n this.begin(\"rel_u\");\n return 66;\n case 54:\n this.begin(\"rel_d\");\n return 67;\n case 55:\n this.begin(\"rel_d\");\n return 67;\n case 56:\n this.begin(\"rel_l\");\n return 68;\n case 57:\n this.begin(\"rel_l\");\n return 68;\n case 58:\n this.begin(\"rel_r\");\n return 69;\n case 59:\n this.begin(\"rel_r\");\n return 69;\n case 60:\n this.begin(\"rel_b\");\n return 70;\n case 61:\n this.begin(\"rel_index\");\n return 71;\n case 62:\n this.begin(\"update_el_style\");\n return 72;\n case 63:\n this.begin(\"update_rel_style\");\n return 73;\n case 64:\n this.begin(\"update_layout_config\");\n return 74;\n case 65:\n return \"EOF_IN_STRUCT\";\n case 66:\n this.begin(\"attribute\");\n return \"ATTRIBUTE_EMPTY\";\n case 67:\n this.begin(\"attribute\");\n break;\n case 68:\n this.popState();\n this.popState();\n break;\n case 69:\n return 80;\n case 70:\n break;\n case 71:\n return 80;\n case 72:\n this.begin(\"string\");\n break;\n case 73:\n this.popState();\n break;\n case 74:\n return \"STR\";\n case 75:\n this.begin(\"string_kv\");\n break;\n case 76:\n this.begin(\"string_kv_key\");\n return \"STR_KEY\";\n case 77:\n this.popState();\n this.begin(\"string_kv_value\");\n break;\n case 78:\n return \"STR_VALUE\";\n case 79:\n this.popState();\n this.popState();\n break;\n case 80:\n return \"STR\";\n case 81:\n return \"LBRACE\";\n case 82:\n return \"RBRACE\";\n case 83:\n return \"SPACE\";\n case 84:\n return \"EOL\";\n case 85:\n return 14;\n }\n },\n rules: [/^(?:.*direction\\s+TB[^\\n]*)/, /^(?:.*direction\\s+BT[^\\n]*)/, /^(?:.*direction\\s+RL[^\\n]*)/, /^(?:.*direction\\s+LR[^\\n]*)/, /^(?:title\\s[^#\\n;]+)/, /^(?:accDescription\\s[^#\\n;]+)/, /^(?:accTitle\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*\\{\\s*)/, /^(?:[\\}])/, /^(?:[^\\}]*)/, /^(?:%%(?!\\{)*[^\\n]*(\\r?\\n?)+)/, /^(?:%%[^\\n]*(\\r?\\n)*)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:C4Context\\b)/, /^(?:C4Container\\b)/, /^(?:C4Component\\b)/, /^(?:C4Dynamic\\b)/, /^(?:C4Deployment\\b)/, /^(?:Person_Ext\\b)/, /^(?:Person\\b)/, /^(?:SystemQueue_Ext\\b)/, /^(?:SystemDb_Ext\\b)/, /^(?:System_Ext\\b)/, /^(?:SystemQueue\\b)/, /^(?:SystemDb\\b)/, /^(?:System\\b)/, /^(?:Boundary\\b)/, /^(?:Enterprise_Boundary\\b)/, /^(?:System_Boundary\\b)/, /^(?:ContainerQueue_Ext\\b)/, /^(?:ContainerDb_Ext\\b)/, /^(?:Container_Ext\\b)/, /^(?:ContainerQueue\\b)/, /^(?:ContainerDb\\b)/, /^(?:Container\\b)/, /^(?:Container_Boundary\\b)/, /^(?:ComponentQueue_Ext\\b)/, /^(?:ComponentDb_Ext\\b)/, /^(?:Component_Ext\\b)/, /^(?:ComponentQueue\\b)/, /^(?:ComponentDb\\b)/, /^(?:Component\\b)/, /^(?:Deployment_Node\\b)/, /^(?:Node\\b)/, /^(?:Node_L\\b)/, /^(?:Node_R\\b)/, /^(?:Rel\\b)/, /^(?:BiRel\\b)/, /^(?:Rel_Up\\b)/, /^(?:Rel_U\\b)/, /^(?:Rel_Down\\b)/, /^(?:Rel_D\\b)/, /^(?:Rel_Left\\b)/, /^(?:Rel_L\\b)/, /^(?:Rel_Right\\b)/, /^(?:Rel_R\\b)/, /^(?:Rel_Back\\b)/, /^(?:RelIndex\\b)/, /^(?:UpdateElementStyle\\b)/, /^(?:UpdateRelStyle\\b)/, /^(?:UpdateLayoutConfig\\b)/, /^(?:$)/, /^(?:[(][ ]*[,])/, /^(?:[(])/, /^(?:[)])/, /^(?:,,)/, /^(?:,)/, /^(?:[ ]*[\"][\"])/, /^(?:[ ]*[\"])/, /^(?:[\"])/, /^(?:[^\"]*)/, /^(?:[ ]*[\\$])/, /^(?:[^=]*)/, /^(?:[=][ ]*[\"])/, /^(?:[^\"]+)/, /^(?:[\"])/, /^(?:[^,]+)/, /^(?:\\{)/, /^(?:\\})/, /^(?:[\\s]+)/, /^(?:[\\n\\r]+)/, /^(?:$)/],\n conditions: { \"acc_descr_multiline\": { \"rules\": [11, 12], \"inclusive\": false }, \"acc_descr\": { \"rules\": [9], \"inclusive\": false }, \"acc_title\": { \"rules\": [7], \"inclusive\": false }, \"string_kv_value\": { \"rules\": [78, 79], \"inclusive\": false }, \"string_kv_key\": { \"rules\": [77], \"inclusive\": false }, \"string_kv\": { \"rules\": [76], \"inclusive\": false }, \"string\": { \"rules\": [73, 74], \"inclusive\": false }, \"attribute\": { \"rules\": [68, 69, 70, 71, 72, 75, 80], \"inclusive\": false }, \"update_layout_config\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"update_rel_style\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"update_el_style\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_b\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_r\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_l\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_d\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_u\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"rel_bi\": { \"rules\": [], \"inclusive\": false }, \"rel\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"node_r\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"node_l\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"node\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"index\": { \"rules\": [], \"inclusive\": false }, \"rel_index\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_ext_queue\": { \"rules\": [], \"inclusive\": false }, \"component_ext_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"component\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_ext_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_ext_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"container\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"birel\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"enterprise_boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"boundary\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_ext_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_ext_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_queue\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system_db\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"system\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"person_ext\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"person\": { \"rules\": [65, 66, 67, 68], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 1, 2, 3, 4, 5, 6, 8, 10, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 81, 82, 83, 84, 85], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nlet c4ShapeArray = [];\nlet boundaryParseStack = [\"\"];\nlet currentBoundaryParse = \"global\";\nlet parentBoundaryParse = \"\";\nlet boundarys = [\n {\n alias: \"global\",\n label: { text: \"global\" },\n type: { text: \"global\" },\n tags: null,\n link: null,\n parentBoundary: \"\"\n }\n];\nlet rels = [];\nlet title = \"\";\nlet wrapEnabled = false;\nlet c4ShapeInRow$1 = 4;\nlet c4BoundaryInRow$1 = 2;\nvar c4Type;\nconst getC4Type = function() {\n return c4Type;\n};\nconst setC4Type = function(c4TypeParam) {\n let sanitizedText = sanitizeText(c4TypeParam, getConfig());\n c4Type = sanitizedText;\n};\nconst addRel = function(type, from, to, label, techn, descr, sprite, tags, link) {\n if (type === void 0 || type === null || from === void 0 || from === null || to === void 0 || to === null || label === void 0 || label === null) {\n return;\n }\n let rel = {};\n const old = rels.find((rel2) => rel2.from === from && rel2.to === to);\n if (old) {\n rel = old;\n } else {\n rels.push(rel);\n }\n rel.type = type;\n rel.from = from;\n rel.to = to;\n rel.label = { text: label };\n if (techn === void 0 || techn === null) {\n rel.techn = { text: \"\" };\n } else {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n rel[key] = { text: value };\n } else {\n rel.techn = { text: techn };\n }\n }\n if (descr === void 0 || descr === null) {\n rel.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n rel[key] = { text: value };\n } else {\n rel.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n rel[key] = value;\n } else {\n rel.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n rel[key] = value;\n } else {\n rel.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n rel[key] = value;\n } else {\n rel.link = link;\n }\n rel.wrap = autoWrap();\n};\nconst addPersonOrSystem = function(typeC4Shape, alias, label, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let personOrSystem = {};\n const old = c4ShapeArray.find((personOrSystem2) => personOrSystem2.alias === alias);\n if (old && alias === old.alias) {\n personOrSystem = old;\n } else {\n personOrSystem.alias = alias;\n c4ShapeArray.push(personOrSystem);\n }\n if (label === void 0 || label === null) {\n personOrSystem.label = { text: \"\" };\n } else {\n personOrSystem.label = { text: label };\n }\n if (descr === void 0 || descr === null) {\n personOrSystem.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n personOrSystem[key] = { text: value };\n } else {\n personOrSystem.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n personOrSystem[key] = value;\n } else {\n personOrSystem.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n personOrSystem[key] = value;\n } else {\n personOrSystem.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n personOrSystem[key] = value;\n } else {\n personOrSystem.link = link;\n }\n personOrSystem.typeC4Shape = { text: typeC4Shape };\n personOrSystem.parentBoundary = currentBoundaryParse;\n personOrSystem.wrap = autoWrap();\n};\nconst addContainer = function(typeC4Shape, alias, label, techn, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let container = {};\n const old = c4ShapeArray.find((container2) => container2.alias === alias);\n if (old && alias === old.alias) {\n container = old;\n } else {\n container.alias = alias;\n c4ShapeArray.push(container);\n }\n if (label === void 0 || label === null) {\n container.label = { text: \"\" };\n } else {\n container.label = { text: label };\n }\n if (techn === void 0 || techn === null) {\n container.techn = { text: \"\" };\n } else {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n container[key] = { text: value };\n } else {\n container.techn = { text: techn };\n }\n }\n if (descr === void 0 || descr === null) {\n container.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n container[key] = { text: value };\n } else {\n container.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n container[key] = value;\n } else {\n container.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n container[key] = value;\n } else {\n container.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n container[key] = value;\n } else {\n container.link = link;\n }\n container.wrap = autoWrap();\n container.typeC4Shape = { text: typeC4Shape };\n container.parentBoundary = currentBoundaryParse;\n};\nconst addComponent = function(typeC4Shape, alias, label, techn, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let component = {};\n const old = c4ShapeArray.find((component2) => component2.alias === alias);\n if (old && alias === old.alias) {\n component = old;\n } else {\n component.alias = alias;\n c4ShapeArray.push(component);\n }\n if (label === void 0 || label === null) {\n component.label = { text: \"\" };\n } else {\n component.label = { text: label };\n }\n if (techn === void 0 || techn === null) {\n component.techn = { text: \"\" };\n } else {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n component[key] = { text: value };\n } else {\n component.techn = { text: techn };\n }\n }\n if (descr === void 0 || descr === null) {\n component.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n component[key] = { text: value };\n } else {\n component.descr = { text: descr };\n }\n }\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n component[key] = value;\n } else {\n component.sprite = sprite;\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n component[key] = value;\n } else {\n component.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n component[key] = value;\n } else {\n component.link = link;\n }\n component.wrap = autoWrap();\n component.typeC4Shape = { text: typeC4Shape };\n component.parentBoundary = currentBoundaryParse;\n};\nconst addPersonOrSystemBoundary = function(alias, label, type, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let boundary = {};\n const old = boundarys.find((boundary2) => boundary2.alias === alias);\n if (old && alias === old.alias) {\n boundary = old;\n } else {\n boundary.alias = alias;\n boundarys.push(boundary);\n }\n if (label === void 0 || label === null) {\n boundary.label = { text: \"\" };\n } else {\n boundary.label = { text: label };\n }\n if (type === void 0 || type === null) {\n boundary.type = { text: \"system\" };\n } else {\n if (typeof type === \"object\") {\n let [key, value] = Object.entries(type)[0];\n boundary[key] = { text: value };\n } else {\n boundary.type = { text: type };\n }\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n boundary[key] = value;\n } else {\n boundary.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n boundary[key] = value;\n } else {\n boundary.link = link;\n }\n boundary.parentBoundary = currentBoundaryParse;\n boundary.wrap = autoWrap();\n parentBoundaryParse = currentBoundaryParse;\n currentBoundaryParse = alias;\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst addContainerBoundary = function(alias, label, type, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let boundary = {};\n const old = boundarys.find((boundary2) => boundary2.alias === alias);\n if (old && alias === old.alias) {\n boundary = old;\n } else {\n boundary.alias = alias;\n boundarys.push(boundary);\n }\n if (label === void 0 || label === null) {\n boundary.label = { text: \"\" };\n } else {\n boundary.label = { text: label };\n }\n if (type === void 0 || type === null) {\n boundary.type = { text: \"container\" };\n } else {\n if (typeof type === \"object\") {\n let [key, value] = Object.entries(type)[0];\n boundary[key] = { text: value };\n } else {\n boundary.type = { text: type };\n }\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n boundary[key] = value;\n } else {\n boundary.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n boundary[key] = value;\n } else {\n boundary.link = link;\n }\n boundary.parentBoundary = currentBoundaryParse;\n boundary.wrap = autoWrap();\n parentBoundaryParse = currentBoundaryParse;\n currentBoundaryParse = alias;\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst addDeploymentNode = function(nodeType, alias, label, type, descr, sprite, tags, link) {\n if (alias === null || label === null) {\n return;\n }\n let boundary = {};\n const old = boundarys.find((boundary2) => boundary2.alias === alias);\n if (old && alias === old.alias) {\n boundary = old;\n } else {\n boundary.alias = alias;\n boundarys.push(boundary);\n }\n if (label === void 0 || label === null) {\n boundary.label = { text: \"\" };\n } else {\n boundary.label = { text: label };\n }\n if (type === void 0 || type === null) {\n boundary.type = { text: \"node\" };\n } else {\n if (typeof type === \"object\") {\n let [key, value] = Object.entries(type)[0];\n boundary[key] = { text: value };\n } else {\n boundary.type = { text: type };\n }\n }\n if (descr === void 0 || descr === null) {\n boundary.descr = { text: \"\" };\n } else {\n if (typeof descr === \"object\") {\n let [key, value] = Object.entries(descr)[0];\n boundary[key] = { text: value };\n } else {\n boundary.descr = { text: descr };\n }\n }\n if (typeof tags === \"object\") {\n let [key, value] = Object.entries(tags)[0];\n boundary[key] = value;\n } else {\n boundary.tags = tags;\n }\n if (typeof link === \"object\") {\n let [key, value] = Object.entries(link)[0];\n boundary[key] = value;\n } else {\n boundary.link = link;\n }\n boundary.nodeType = nodeType;\n boundary.parentBoundary = currentBoundaryParse;\n boundary.wrap = autoWrap();\n parentBoundaryParse = currentBoundaryParse;\n currentBoundaryParse = alias;\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst popBoundaryParseStack = function() {\n currentBoundaryParse = parentBoundaryParse;\n boundaryParseStack.pop();\n parentBoundaryParse = boundaryParseStack.pop();\n boundaryParseStack.push(parentBoundaryParse);\n};\nconst updateElStyle = function(typeC4Shape, elementName, bgColor, fontColor, borderColor, shadowing, shape, sprite, techn, legendText, legendSprite) {\n let old = c4ShapeArray.find((element) => element.alias === elementName);\n if (old === void 0) {\n old = boundarys.find((element) => element.alias === elementName);\n if (old === void 0) {\n return;\n }\n }\n if (bgColor !== void 0 && bgColor !== null) {\n if (typeof bgColor === \"object\") {\n let [key, value] = Object.entries(bgColor)[0];\n old[key] = value;\n } else {\n old.bgColor = bgColor;\n }\n }\n if (fontColor !== void 0 && fontColor !== null) {\n if (typeof fontColor === \"object\") {\n let [key, value] = Object.entries(fontColor)[0];\n old[key] = value;\n } else {\n old.fontColor = fontColor;\n }\n }\n if (borderColor !== void 0 && borderColor !== null) {\n if (typeof borderColor === \"object\") {\n let [key, value] = Object.entries(borderColor)[0];\n old[key] = value;\n } else {\n old.borderColor = borderColor;\n }\n }\n if (shadowing !== void 0 && shadowing !== null) {\n if (typeof shadowing === \"object\") {\n let [key, value] = Object.entries(shadowing)[0];\n old[key] = value;\n } else {\n old.shadowing = shadowing;\n }\n }\n if (shape !== void 0 && shape !== null) {\n if (typeof shape === \"object\") {\n let [key, value] = Object.entries(shape)[0];\n old[key] = value;\n } else {\n old.shape = shape;\n }\n }\n if (sprite !== void 0 && sprite !== null) {\n if (typeof sprite === \"object\") {\n let [key, value] = Object.entries(sprite)[0];\n old[key] = value;\n } else {\n old.sprite = sprite;\n }\n }\n if (techn !== void 0 && techn !== null) {\n if (typeof techn === \"object\") {\n let [key, value] = Object.entries(techn)[0];\n old[key] = value;\n } else {\n old.techn = techn;\n }\n }\n if (legendText !== void 0 && legendText !== null) {\n if (typeof legendText === \"object\") {\n let [key, value] = Object.entries(legendText)[0];\n old[key] = value;\n } else {\n old.legendText = legendText;\n }\n }\n if (legendSprite !== void 0 && legendSprite !== null) {\n if (typeof legendSprite === \"object\") {\n let [key, value] = Object.entries(legendSprite)[0];\n old[key] = value;\n } else {\n old.legendSprite = legendSprite;\n }\n }\n};\nconst updateRelStyle = function(typeC4Shape, from, to, textColor, lineColor, offsetX, offsetY) {\n const old = rels.find((rel) => rel.from === from && rel.to === to);\n if (old === void 0) {\n return;\n }\n if (textColor !== void 0 && textColor !== null) {\n if (typeof textColor === \"object\") {\n let [key, value] = Object.entries(textColor)[0];\n old[key] = value;\n } else {\n old.textColor = textColor;\n }\n }\n if (lineColor !== void 0 && lineColor !== null) {\n if (typeof lineColor === \"object\") {\n let [key, value] = Object.entries(lineColor)[0];\n old[key] = value;\n } else {\n old.lineColor = lineColor;\n }\n }\n if (offsetX !== void 0 && offsetX !== null) {\n if (typeof offsetX === \"object\") {\n let [key, value] = Object.entries(offsetX)[0];\n old[key] = parseInt(value);\n } else {\n old.offsetX = parseInt(offsetX);\n }\n }\n if (offsetY !== void 0 && offsetY !== null) {\n if (typeof offsetY === \"object\") {\n let [key, value] = Object.entries(offsetY)[0];\n old[key] = parseInt(value);\n } else {\n old.offsetY = parseInt(offsetY);\n }\n }\n};\nconst updateLayoutConfig = function(typeC4Shape, c4ShapeInRowParam, c4BoundaryInRowParam) {\n let c4ShapeInRowValue = c4ShapeInRow$1;\n let c4BoundaryInRowValue = c4BoundaryInRow$1;\n if (typeof c4ShapeInRowParam === \"object\") {\n const value = Object.values(c4ShapeInRowParam)[0];\n c4ShapeInRowValue = parseInt(value);\n } else {\n c4ShapeInRowValue = parseInt(c4ShapeInRowParam);\n }\n if (typeof c4BoundaryInRowParam === \"object\") {\n const value = Object.values(c4BoundaryInRowParam)[0];\n c4BoundaryInRowValue = parseInt(value);\n } else {\n c4BoundaryInRowValue = parseInt(c4BoundaryInRowParam);\n }\n if (c4ShapeInRowValue >= 1) {\n c4ShapeInRow$1 = c4ShapeInRowValue;\n }\n if (c4BoundaryInRowValue >= 1) {\n c4BoundaryInRow$1 = c4BoundaryInRowValue;\n }\n};\nconst getC4ShapeInRow = function() {\n return c4ShapeInRow$1;\n};\nconst getC4BoundaryInRow = function() {\n return c4BoundaryInRow$1;\n};\nconst getCurrentBoundaryParse = function() {\n return currentBoundaryParse;\n};\nconst getParentBoundaryParse = function() {\n return parentBoundaryParse;\n};\nconst getC4ShapeArray = function(parentBoundary) {\n if (parentBoundary === void 0 || parentBoundary === null) {\n return c4ShapeArray;\n } else {\n return c4ShapeArray.filter((personOrSystem) => {\n return personOrSystem.parentBoundary === parentBoundary;\n });\n }\n};\nconst getC4Shape = function(alias) {\n return c4ShapeArray.find((personOrSystem) => personOrSystem.alias === alias);\n};\nconst getC4ShapeKeys = function(parentBoundary) {\n return Object.keys(getC4ShapeArray(parentBoundary));\n};\nconst getBoundarys = function(parentBoundary) {\n if (parentBoundary === void 0 || parentBoundary === null) {\n return boundarys;\n } else {\n return boundarys.filter((boundary) => boundary.parentBoundary === parentBoundary);\n }\n};\nconst getRels = function() {\n return rels;\n};\nconst getTitle = function() {\n return title;\n};\nconst setWrap = function(wrapSetting) {\n wrapEnabled = wrapSetting;\n};\nconst autoWrap = function() {\n return wrapEnabled;\n};\nconst clear = function() {\n c4ShapeArray = [];\n boundarys = [\n {\n alias: \"global\",\n label: { text: \"global\" },\n type: { text: \"global\" },\n tags: null,\n link: null,\n parentBoundary: \"\"\n }\n ];\n parentBoundaryParse = \"\";\n currentBoundaryParse = \"global\";\n boundaryParseStack = [\"\"];\n rels = [];\n boundaryParseStack = [\"\"];\n title = \"\";\n wrapEnabled = false;\n c4ShapeInRow$1 = 4;\n c4BoundaryInRow$1 = 2;\n};\nconst LINETYPE = {\n SOLID: 0,\n DOTTED: 1,\n NOTE: 2,\n SOLID_CROSS: 3,\n DOTTED_CROSS: 4,\n SOLID_OPEN: 5,\n DOTTED_OPEN: 6,\n LOOP_START: 10,\n LOOP_END: 11,\n ALT_START: 12,\n ALT_ELSE: 13,\n ALT_END: 14,\n OPT_START: 15,\n OPT_END: 16,\n ACTIVE_START: 17,\n ACTIVE_END: 18,\n PAR_START: 19,\n PAR_AND: 20,\n PAR_END: 21,\n RECT_START: 22,\n RECT_END: 23,\n SOLID_POINT: 24,\n DOTTED_POINT: 25\n};\nconst ARROWTYPE = {\n FILLED: 0,\n OPEN: 1\n};\nconst PLACEMENT = {\n LEFTOF: 0,\n RIGHTOF: 1,\n OVER: 2\n};\nconst setTitle = function(txt) {\n let sanitizedText = sanitizeText(txt, getConfig());\n title = sanitizedText;\n};\nconst db = {\n addPersonOrSystem,\n addPersonOrSystemBoundary,\n addContainer,\n addContainerBoundary,\n addComponent,\n addDeploymentNode,\n popBoundaryParseStack,\n addRel,\n updateElStyle,\n updateRelStyle,\n updateLayoutConfig,\n autoWrap,\n setWrap,\n getC4ShapeArray,\n getC4Shape,\n getC4ShapeKeys,\n getBoundarys,\n getCurrentBoundaryParse,\n getParentBoundaryParse,\n getRels,\n getTitle,\n getC4Type,\n getC4ShapeInRow,\n getC4BoundaryInRow,\n setAccTitle,\n getAccTitle,\n getAccDescription,\n setAccDescription,\n getConfig: () => getConfig().c4,\n clear,\n LINETYPE,\n ARROWTYPE,\n PLACEMENT,\n setTitle,\n setC4Type\n // apply,\n};\nconst drawRect = function(elem, rectData) {\n return drawRect$1(elem, rectData);\n};\nconst drawImage = function(elem, width, height, x, y, link) {\n const imageElem = elem.append(\"image\");\n imageElem.attr(\"width\", width);\n imageElem.attr(\"height\", height);\n imageElem.attr(\"x\", x);\n imageElem.attr(\"y\", y);\n let sanitizedLink = link.startsWith(\"data:image/png;base64\") ? link : sanitizeUrl(link);\n imageElem.attr(\"xlink:href\", sanitizedLink);\n};\nconst drawRels$1 = (elem, rels2, conf2) => {\n const relsElem = elem.append(\"g\");\n let i = 0;\n for (let rel of rels2) {\n let textColor = rel.textColor ? rel.textColor : \"#444444\";\n let strokeColor = rel.lineColor ? rel.lineColor : \"#444444\";\n let offsetX = rel.offsetX ? parseInt(rel.offsetX) : 0;\n let offsetY = rel.offsetY ? parseInt(rel.offsetY) : 0;\n let url = \"\";\n if (i === 0) {\n let line = relsElem.append(\"line\");\n line.attr(\"x1\", rel.startPoint.x);\n line.attr(\"y1\", rel.startPoint.y);\n line.attr(\"x2\", rel.endPoint.x);\n line.attr(\"y2\", rel.endPoint.y);\n line.attr(\"stroke-width\", \"1\");\n line.attr(\"stroke\", strokeColor);\n line.style(\"fill\", \"none\");\n if (rel.type !== \"rel_b\") {\n line.attr(\"marker-end\", \"url(\" + url + \"#arrowhead)\");\n }\n if (rel.type === \"birel\" || rel.type === \"rel_b\") {\n line.attr(\"marker-start\", \"url(\" + url + \"#arrowend)\");\n }\n i = -1;\n } else {\n let line = relsElem.append(\"path\");\n line.attr(\"fill\", \"none\").attr(\"stroke-width\", \"1\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,starty Qcontrolx,controly stopx,stopy \".replaceAll(\"startx\", rel.startPoint.x).replaceAll(\"starty\", rel.startPoint.y).replaceAll(\n \"controlx\",\n rel.startPoint.x + (rel.endPoint.x - rel.startPoint.x) / 2 - (rel.endPoint.x - rel.startPoint.x) / 4\n ).replaceAll(\"controly\", rel.startPoint.y + (rel.endPoint.y - rel.startPoint.y) / 2).replaceAll(\"stopx\", rel.endPoint.x).replaceAll(\"stopy\", rel.endPoint.y)\n );\n if (rel.type !== \"rel_b\") {\n line.attr(\"marker-end\", \"url(\" + url + \"#arrowhead)\");\n }\n if (rel.type === \"birel\" || rel.type === \"rel_b\") {\n line.attr(\"marker-start\", \"url(\" + url + \"#arrowend)\");\n }\n }\n let messageConf = conf2.messageFont();\n _drawTextCandidateFunc(conf2)(\n rel.label.text,\n relsElem,\n Math.min(rel.startPoint.x, rel.endPoint.x) + Math.abs(rel.endPoint.x - rel.startPoint.x) / 2 + offsetX,\n Math.min(rel.startPoint.y, rel.endPoint.y) + Math.abs(rel.endPoint.y - rel.startPoint.y) / 2 + offsetY,\n rel.label.width,\n rel.label.height,\n { fill: textColor },\n messageConf\n );\n if (rel.techn && rel.techn.text !== \"\") {\n messageConf = conf2.messageFont();\n _drawTextCandidateFunc(conf2)(\n \"[\" + rel.techn.text + \"]\",\n relsElem,\n Math.min(rel.startPoint.x, rel.endPoint.x) + Math.abs(rel.endPoint.x - rel.startPoint.x) / 2 + offsetX,\n Math.min(rel.startPoint.y, rel.endPoint.y) + Math.abs(rel.endPoint.y - rel.startPoint.y) / 2 + conf2.messageFontSize + 5 + offsetY,\n Math.max(rel.label.width, rel.techn.width),\n rel.techn.height,\n { fill: textColor, \"font-style\": \"italic\" },\n messageConf\n );\n }\n }\n};\nconst drawBoundary$1 = function(elem, boundary, conf2) {\n const boundaryElem = elem.append(\"g\");\n let fillColor = boundary.bgColor ? boundary.bgColor : \"none\";\n let strokeColor = boundary.borderColor ? boundary.borderColor : \"#444444\";\n let fontColor = boundary.fontColor ? boundary.fontColor : \"black\";\n let attrsValue = { \"stroke-width\": 1, \"stroke-dasharray\": \"7.0,7.0\" };\n if (boundary.nodeType) {\n attrsValue = { \"stroke-width\": 1 };\n }\n let rectData = {\n x: boundary.x,\n y: boundary.y,\n fill: fillColor,\n stroke: strokeColor,\n width: boundary.width,\n height: boundary.height,\n rx: 2.5,\n ry: 2.5,\n attrs: attrsValue\n };\n drawRect(boundaryElem, rectData);\n let boundaryConf = conf2.boundaryFont();\n boundaryConf.fontWeight = \"bold\";\n boundaryConf.fontSize = boundaryConf.fontSize + 2;\n boundaryConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n boundary.label.text,\n boundaryElem,\n boundary.x,\n boundary.y + boundary.label.Y,\n boundary.width,\n boundary.height,\n { fill: \"#444444\" },\n boundaryConf\n );\n if (boundary.type && boundary.type.text !== \"\") {\n boundaryConf = conf2.boundaryFont();\n boundaryConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n boundary.type.text,\n boundaryElem,\n boundary.x,\n boundary.y + boundary.type.Y,\n boundary.width,\n boundary.height,\n { fill: \"#444444\" },\n boundaryConf\n );\n }\n if (boundary.descr && boundary.descr.text !== \"\") {\n boundaryConf = conf2.boundaryFont();\n boundaryConf.fontSize = boundaryConf.fontSize - 2;\n boundaryConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n boundary.descr.text,\n boundaryElem,\n boundary.x,\n boundary.y + boundary.descr.Y,\n boundary.width,\n boundary.height,\n { fill: \"#444444\" },\n boundaryConf\n );\n }\n};\nconst drawC4Shape = function(elem, c4Shape, conf2) {\n var _a;\n let fillColor = c4Shape.bgColor ? c4Shape.bgColor : conf2[c4Shape.typeC4Shape.text + \"_bg_color\"];\n let strokeColor = c4Shape.borderColor ? c4Shape.borderColor : conf2[c4Shape.typeC4Shape.text + \"_border_color\"];\n let fontColor = c4Shape.fontColor ? c4Shape.fontColor : \"#FFFFFF\";\n let personImg = \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=\";\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n personImg = \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c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bR44QQLBEqrBHqOrmSKaQAxdnLArCrxZcM7A7ZKs4ioRq8LFC+NpC3WCBJsvpVw5edm9iEXFuyNfxXAgSwfrFQ1c0iNda8AdejvUgnktOtJQQxmcfFzGglc5WVCj7oDgFqU18boeFSs52CUh8LE8BIVQDT1ABrB0HtgSEYlX5doJnCwv9TXocKCaKbnwhdDKPq4lf3SwU3HLq4V/+WYhHVMa/3b4IlfyikAduCkcBc7mQ3/z/Qq/cTuikhkzB12Ae/mcJC9U+Vo8Ej1gWAtgbeGgFsAMHr50BIWOLCbezvhpBFUdY6EJuJ/QDW0XoMX60zZ0AAAAASUVORK5CYII=\";\n break;\n }\n const c4ShapeElem = elem.append(\"g\");\n c4ShapeElem.attr(\"class\", \"person-man\");\n const rect = getNoteRect();\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n case \"external_person\":\n case \"system\":\n case \"external_system\":\n case \"container\":\n case \"external_container\":\n case \"component\":\n case \"external_component\":\n rect.x = c4Shape.x;\n rect.y = c4Shape.y;\n rect.fill = fillColor;\n rect.width = c4Shape.width;\n rect.height = c4Shape.height;\n rect.stroke = strokeColor;\n rect.rx = 2.5;\n rect.ry = 2.5;\n rect.attrs = { \"stroke-width\": 0.5 };\n drawRect(c4ShapeElem, rect);\n break;\n case \"system_db\":\n case \"external_system_db\":\n case \"container_db\":\n case \"external_container_db\":\n case \"component_db\":\n case \"external_component_db\":\n c4ShapeElem.append(\"path\").attr(\"fill\", fillColor).attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startyc0,-10 half,-10 half,-10c0,0 half,0 half,10l0,heightc0,10 -half,10 -half,10c0,0 -half,0 -half,-10l0,-height\".replaceAll(\"startx\", c4Shape.x).replaceAll(\"starty\", c4Shape.y).replaceAll(\"half\", c4Shape.width / 2).replaceAll(\"height\", c4Shape.height)\n );\n c4ShapeElem.append(\"path\").attr(\"fill\", \"none\").attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startyc0,10 half,10 half,10c0,0 half,0 half,-10\".replaceAll(\"startx\", c4Shape.x).replaceAll(\"starty\", c4Shape.y).replaceAll(\"half\", c4Shape.width / 2)\n );\n break;\n case \"system_queue\":\n case \"external_system_queue\":\n case \"container_queue\":\n case \"external_container_queue\":\n case \"component_queue\":\n case \"external_component_queue\":\n c4ShapeElem.append(\"path\").attr(\"fill\", fillColor).attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startylwidth,0c5,0 5,half 5,halfc0,0 0,half -5,halfl-width,0c-5,0 -5,-half -5,-halfc0,0 0,-half 5,-half\".replaceAll(\"startx\", c4Shape.x).replaceAll(\"starty\", c4Shape.y).replaceAll(\"width\", c4Shape.width).replaceAll(\"half\", c4Shape.height / 2)\n );\n c4ShapeElem.append(\"path\").attr(\"fill\", \"none\").attr(\"stroke-width\", \"0.5\").attr(\"stroke\", strokeColor).attr(\n \"d\",\n \"Mstartx,startyc-5,0 -5,half -5,halfc0,half 5,half 5,half\".replaceAll(\"startx\", c4Shape.x + c4Shape.width).replaceAll(\"starty\", c4Shape.y).replaceAll(\"half\", c4Shape.height / 2)\n );\n break;\n }\n let c4ShapeFontConf = getC4ShapeFont(conf2, c4Shape.typeC4Shape.text);\n c4ShapeElem.append(\"text\").attr(\"fill\", fontColor).attr(\"font-family\", c4ShapeFontConf.fontFamily).attr(\"font-size\", c4ShapeFontConf.fontSize - 2).attr(\"font-style\", \"italic\").attr(\"lengthAdjust\", \"spacing\").attr(\"textLength\", c4Shape.typeC4Shape.width).attr(\"x\", c4Shape.x + c4Shape.width / 2 - c4Shape.typeC4Shape.width / 2).attr(\"y\", c4Shape.y + c4Shape.typeC4Shape.Y).text(\"<<\" + c4Shape.typeC4Shape.text + \">>\");\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n case \"external_person\":\n drawImage(\n c4ShapeElem,\n 48,\n 48,\n c4Shape.x + c4Shape.width / 2 - 24,\n c4Shape.y + c4Shape.image.Y,\n personImg\n );\n break;\n }\n let textFontConf = conf2[c4Shape.typeC4Shape.text + \"Font\"]();\n textFontConf.fontWeight = \"bold\";\n textFontConf.fontSize = textFontConf.fontSize + 2;\n textFontConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n c4Shape.label.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.label.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor },\n textFontConf\n );\n textFontConf = conf2[c4Shape.typeC4Shape.text + \"Font\"]();\n textFontConf.fontColor = fontColor;\n if (c4Shape.techn && ((_a = c4Shape.techn) == null ? void 0 : _a.text) !== \"\") {\n _drawTextCandidateFunc(conf2)(\n c4Shape.techn.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.techn.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor, \"font-style\": \"italic\" },\n textFontConf\n );\n } else if (c4Shape.type && c4Shape.type.text !== \"\") {\n _drawTextCandidateFunc(conf2)(\n c4Shape.type.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.type.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor, \"font-style\": \"italic\" },\n textFontConf\n );\n }\n if (c4Shape.descr && c4Shape.descr.text !== \"\") {\n textFontConf = conf2.personFont();\n textFontConf.fontColor = fontColor;\n _drawTextCandidateFunc(conf2)(\n c4Shape.descr.text,\n c4ShapeElem,\n c4Shape.x,\n c4Shape.y + c4Shape.descr.Y,\n c4Shape.width,\n c4Shape.height,\n { fill: fontColor },\n textFontConf\n );\n }\n return c4Shape.height;\n};\nconst insertDatabaseIcon = function(elem) {\n elem.append(\"defs\").append(\"symbol\").attr(\"id\", \"database\").attr(\"fill-rule\", \"evenodd\").attr(\"clip-rule\", \"evenodd\").append(\"path\").attr(\"transform\", \"scale(.5)\").attr(\n \"d\",\n \"M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z\"\n );\n};\nconst insertComputerIcon = function(elem) {\n elem.append(\"defs\").append(\"symbol\").attr(\"id\", \"computer\").attr(\"width\", \"24\").attr(\"height\", \"24\").append(\"path\").attr(\"transform\", \"scale(.5)\").attr(\n \"d\",\n \"M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z\"\n );\n};\nconst insertClockIcon = function(elem) {\n elem.append(\"defs\").append(\"symbol\").attr(\"id\", \"clock\").attr(\"width\", \"24\").attr(\"height\", \"24\").append(\"path\").attr(\"transform\", \"scale(.5)\").attr(\n \"d\",\n \"M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z\"\n );\n};\nconst insertArrowHead = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"arrowhead\").attr(\"refX\", 9).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 0 0 L 10 5 L 0 10 z\");\n};\nconst insertArrowEnd = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"arrowend\").attr(\"refX\", 1).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 10 0 L 0 5 L 10 10 z\");\n};\nconst insertArrowFilledHead = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"filled-head\").attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L14,7 L9,1 Z\");\n};\nconst insertDynamicNumber = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"sequencenumber\").attr(\"refX\", 15).attr(\"refY\", 15).attr(\"markerWidth\", 60).attr(\"markerHeight\", 40).attr(\"orient\", \"auto\").append(\"circle\").attr(\"cx\", 15).attr(\"cy\", 15).attr(\"r\", 6);\n};\nconst insertArrowCrossHead = function(elem) {\n const defs = elem.append(\"defs\");\n const marker = defs.append(\"marker\").attr(\"id\", \"crosshead\").attr(\"markerWidth\", 15).attr(\"markerHeight\", 8).attr(\"orient\", \"auto\").attr(\"refX\", 16).attr(\"refY\", 4);\n marker.append(\"path\").attr(\"fill\", \"black\").attr(\"stroke\", \"#000000\").style(\"stroke-dasharray\", \"0, 0\").attr(\"stroke-width\", \"1px\").attr(\"d\", \"M 9,2 V 6 L16,4 Z\");\n marker.append(\"path\").attr(\"fill\", \"none\").attr(\"stroke\", \"#000000\").style(\"stroke-dasharray\", \"0, 0\").attr(\"stroke-width\", \"1px\").attr(\"d\", \"M 0,1 L 6,7 M 6,1 L 0,7\");\n};\nconst getC4ShapeFont = (cnf, typeC4Shape) => {\n return {\n fontFamily: cnf[typeC4Shape + \"FontFamily\"],\n fontSize: cnf[typeC4Shape + \"FontSize\"],\n fontWeight: cnf[typeC4Shape + \"FontWeight\"]\n };\n};\nconst _drawTextCandidateFunc = function() {\n function byText(content, g, x, y, width, height, textAttrs) {\n const text = g.append(\"text\").attr(\"x\", x + width / 2).attr(\"y\", y + height / 2 + 5).style(\"text-anchor\", \"middle\").text(content);\n _setTextAttrs(text, textAttrs);\n }\n function byTspan(content, g, x, y, width, height, textAttrs, conf2) {\n const { fontSize, fontFamily, fontWeight } = conf2;\n const lines = content.split(common.lineBreakRegex);\n for (let i = 0; i < lines.length; i++) {\n const dy = i * fontSize - fontSize * (lines.length - 1) / 2;\n const text = g.append(\"text\").attr(\"x\", x + width / 2).attr(\"y\", y).style(\"text-anchor\", \"middle\").attr(\"dominant-baseline\", \"middle\").style(\"font-size\", fontSize).style(\"font-weight\", fontWeight).style(\"font-family\", fontFamily);\n text.append(\"tspan\").attr(\"dy\", dy).text(lines[i]).attr(\"alignment-baseline\", \"mathematical\");\n _setTextAttrs(text, textAttrs);\n }\n }\n function byFo(content, g, x, y, width, height, textAttrs, conf2) {\n const s = g.append(\"switch\");\n const f = s.append(\"foreignObject\").attr(\"x\", x).attr(\"y\", y).attr(\"width\", width).attr(\"height\", height);\n const text = f.append(\"xhtml:div\").style(\"display\", \"table\").style(\"height\", \"100%\").style(\"width\", \"100%\");\n text.append(\"div\").style(\"display\", \"table-cell\").style(\"text-align\", \"center\").style(\"vertical-align\", \"middle\").text(content);\n byTspan(content, s, x, y, width, height, textAttrs, conf2);\n _setTextAttrs(text, textAttrs);\n }\n function _setTextAttrs(toText, fromTextAttrsDict) {\n for (const key in fromTextAttrsDict) {\n if (fromTextAttrsDict.hasOwnProperty(key)) {\n toText.attr(key, fromTextAttrsDict[key]);\n }\n }\n }\n return function(conf2) {\n return conf2.textPlacement === \"fo\" ? byFo : conf2.textPlacement === \"old\" ? byText : byTspan;\n };\n}();\nconst svgDraw = {\n drawRect,\n drawBoundary: drawBoundary$1,\n drawC4Shape,\n drawRels: drawRels$1,\n drawImage,\n insertArrowHead,\n insertArrowEnd,\n insertArrowFilledHead,\n insertDynamicNumber,\n insertArrowCrossHead,\n insertDatabaseIcon,\n insertComputerIcon,\n insertClockIcon\n};\nlet globalBoundaryMaxX = 0, globalBoundaryMaxY = 0;\nlet c4ShapeInRow = 4;\nlet c4BoundaryInRow = 2;\nparser.yy = db;\nlet conf = {};\nclass Bounds {\n constructor(diagObj) {\n this.name = \"\";\n this.data = {};\n this.data.startx = void 0;\n this.data.stopx = void 0;\n this.data.starty = void 0;\n this.data.stopy = void 0;\n this.data.widthLimit = void 0;\n this.nextData = {};\n this.nextData.startx = void 0;\n this.nextData.stopx = void 0;\n this.nextData.starty = void 0;\n this.nextData.stopy = void 0;\n this.nextData.cnt = 0;\n setConf(diagObj.db.getConfig());\n }\n setData(startx, stopx, starty, stopy) {\n this.nextData.startx = this.data.startx = startx;\n this.nextData.stopx = this.data.stopx = stopx;\n this.nextData.starty = this.data.starty = starty;\n this.nextData.stopy = this.data.stopy = stopy;\n }\n updateVal(obj, key, val, fun) {\n if (obj[key] === void 0) {\n obj[key] = val;\n } else {\n obj[key] = fun(val, obj[key]);\n }\n }\n insert(c4Shape) {\n this.nextData.cnt = this.nextData.cnt + 1;\n let _startx = this.nextData.startx === this.nextData.stopx ? this.nextData.stopx + c4Shape.margin : this.nextData.stopx + c4Shape.margin * 2;\n let _stopx = _startx + c4Shape.width;\n let _starty = this.nextData.starty + c4Shape.margin * 2;\n let _stopy = _starty + c4Shape.height;\n if (_startx >= this.data.widthLimit || _stopx >= this.data.widthLimit || this.nextData.cnt > c4ShapeInRow) {\n _startx = this.nextData.startx + c4Shape.margin + conf.nextLinePaddingX;\n _starty = this.nextData.stopy + c4Shape.margin * 2;\n this.nextData.stopx = _stopx = _startx + c4Shape.width;\n this.nextData.starty = this.nextData.stopy;\n this.nextData.stopy = _stopy = _starty + c4Shape.height;\n this.nextData.cnt = 1;\n }\n c4Shape.x = _startx;\n c4Shape.y = _starty;\n this.updateVal(this.data, \"startx\", _startx, Math.min);\n this.updateVal(this.data, \"starty\", _starty, Math.min);\n this.updateVal(this.data, \"stopx\", _stopx, Math.max);\n this.updateVal(this.data, \"stopy\", _stopy, Math.max);\n this.updateVal(this.nextData, \"startx\", _startx, Math.min);\n this.updateVal(this.nextData, \"starty\", _starty, Math.min);\n this.updateVal(this.nextData, \"stopx\", _stopx, Math.max);\n this.updateVal(this.nextData, \"stopy\", _stopy, Math.max);\n }\n init(diagObj) {\n this.name = \"\";\n this.data = {\n startx: void 0,\n stopx: void 0,\n starty: void 0,\n stopy: void 0,\n widthLimit: void 0\n };\n this.nextData = {\n startx: void 0,\n stopx: void 0,\n starty: void 0,\n stopy: void 0,\n cnt: 0\n };\n setConf(diagObj.db.getConfig());\n }\n bumpLastMargin(margin) {\n this.data.stopx += margin;\n this.data.stopy += margin;\n }\n}\nconst setConf = function(cnf) {\n assignWithDepth(conf, cnf);\n if (cnf.fontFamily) {\n conf.personFontFamily = conf.systemFontFamily = conf.messageFontFamily = cnf.fontFamily;\n }\n if (cnf.fontSize) {\n conf.personFontSize = conf.systemFontSize = conf.messageFontSize = cnf.fontSize;\n }\n if (cnf.fontWeight) {\n conf.personFontWeight = conf.systemFontWeight = conf.messageFontWeight = cnf.fontWeight;\n }\n};\nconst c4ShapeFont = (cnf, typeC4Shape) => {\n return {\n fontFamily: cnf[typeC4Shape + \"FontFamily\"],\n fontSize: cnf[typeC4Shape + \"FontSize\"],\n fontWeight: cnf[typeC4Shape + \"FontWeight\"]\n };\n};\nconst boundaryFont = (cnf) => {\n return {\n fontFamily: cnf.boundaryFontFamily,\n fontSize: cnf.boundaryFontSize,\n fontWeight: cnf.boundaryFontWeight\n };\n};\nconst messageFont = (cnf) => {\n return {\n fontFamily: cnf.messageFontFamily,\n fontSize: cnf.messageFontSize,\n fontWeight: cnf.messageFontWeight\n };\n};\nfunction calcC4ShapeTextWH(textType, c4Shape, c4ShapeTextWrap, textConf, textLimitWidth) {\n if (!c4Shape[textType].width) {\n if (c4ShapeTextWrap) {\n c4Shape[textType].text = wrapLabel(c4Shape[textType].text, textLimitWidth, textConf);\n c4Shape[textType].textLines = c4Shape[textType].text.split(common.lineBreakRegex).length;\n c4Shape[textType].width = textLimitWidth;\n c4Shape[textType].height = calculateTextHeight(c4Shape[textType].text, textConf);\n } else {\n let lines = c4Shape[textType].text.split(common.lineBreakRegex);\n c4Shape[textType].textLines = lines.length;\n let lineHeight = 0;\n c4Shape[textType].height = 0;\n c4Shape[textType].width = 0;\n for (const line of lines) {\n c4Shape[textType].width = Math.max(\n calculateTextWidth(line, textConf),\n c4Shape[textType].width\n );\n lineHeight = calculateTextHeight(line, textConf);\n c4Shape[textType].height = c4Shape[textType].height + lineHeight;\n }\n }\n }\n}\nconst drawBoundary = function(diagram2, boundary, bounds) {\n boundary.x = bounds.data.startx;\n boundary.y = bounds.data.starty;\n boundary.width = bounds.data.stopx - bounds.data.startx;\n boundary.height = bounds.data.stopy - bounds.data.starty;\n boundary.label.y = conf.c4ShapeMargin - 35;\n let boundaryTextWrap = boundary.wrap && conf.wrap;\n let boundaryLabelConf = boundaryFont(conf);\n boundaryLabelConf.fontSize = boundaryLabelConf.fontSize + 2;\n boundaryLabelConf.fontWeight = \"bold\";\n let textLimitWidth = calculateTextWidth(boundary.label.text, boundaryLabelConf);\n calcC4ShapeTextWH(\"label\", boundary, boundaryTextWrap, boundaryLabelConf, textLimitWidth);\n svgDraw.drawBoundary(diagram2, boundary, conf);\n};\nconst drawC4ShapeArray = function(currentBounds, diagram2, c4ShapeArray2, c4ShapeKeys) {\n let Y = 0;\n for (const c4ShapeKey of c4ShapeKeys) {\n Y = 0;\n const c4Shape = c4ShapeArray2[c4ShapeKey];\n let c4ShapeTypeConf = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n c4ShapeTypeConf.fontSize = c4ShapeTypeConf.fontSize - 2;\n c4Shape.typeC4Shape.width = calculateTextWidth(\n \"\u00AB\" + c4Shape.typeC4Shape.text + \"\u00BB\",\n c4ShapeTypeConf\n );\n c4Shape.typeC4Shape.height = c4ShapeTypeConf.fontSize + 2;\n c4Shape.typeC4Shape.Y = conf.c4ShapePadding;\n Y = c4Shape.typeC4Shape.Y + c4Shape.typeC4Shape.height - 4;\n c4Shape.image = { width: 0, height: 0, Y: 0 };\n switch (c4Shape.typeC4Shape.text) {\n case \"person\":\n case \"external_person\":\n c4Shape.image.width = 48;\n c4Shape.image.height = 48;\n c4Shape.image.Y = Y;\n Y = c4Shape.image.Y + c4Shape.image.height;\n break;\n }\n if (c4Shape.sprite) {\n c4Shape.image.width = 48;\n c4Shape.image.height = 48;\n c4Shape.image.Y = Y;\n Y = c4Shape.image.Y + c4Shape.image.height;\n }\n let c4ShapeTextWrap = c4Shape.wrap && conf.wrap;\n let textLimitWidth = conf.width - conf.c4ShapePadding * 2;\n let c4ShapeLabelConf = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n c4ShapeLabelConf.fontSize = c4ShapeLabelConf.fontSize + 2;\n c4ShapeLabelConf.fontWeight = \"bold\";\n calcC4ShapeTextWH(\"label\", c4Shape, c4ShapeTextWrap, c4ShapeLabelConf, textLimitWidth);\n c4Shape[\"label\"].Y = Y + 8;\n Y = c4Shape[\"label\"].Y + c4Shape[\"label\"].height;\n if (c4Shape.type && c4Shape.type.text !== \"\") {\n c4Shape.type.text = \"[\" + c4Shape.type.text + \"]\";\n let c4ShapeTypeConf2 = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n calcC4ShapeTextWH(\"type\", c4Shape, c4ShapeTextWrap, c4ShapeTypeConf2, textLimitWidth);\n c4Shape[\"type\"].Y = Y + 5;\n Y = c4Shape[\"type\"].Y + c4Shape[\"type\"].height;\n } else if (c4Shape.techn && c4Shape.techn.text !== \"\") {\n c4Shape.techn.text = \"[\" + c4Shape.techn.text + \"]\";\n let c4ShapeTechnConf = c4ShapeFont(conf, c4Shape.techn.text);\n calcC4ShapeTextWH(\"techn\", c4Shape, c4ShapeTextWrap, c4ShapeTechnConf, textLimitWidth);\n c4Shape[\"techn\"].Y = Y + 5;\n Y = c4Shape[\"techn\"].Y + c4Shape[\"techn\"].height;\n }\n let rectHeight = Y;\n let rectWidth = c4Shape.label.width;\n if (c4Shape.descr && c4Shape.descr.text !== \"\") {\n let c4ShapeDescrConf = c4ShapeFont(conf, c4Shape.typeC4Shape.text);\n calcC4ShapeTextWH(\"descr\", c4Shape, c4ShapeTextWrap, c4ShapeDescrConf, textLimitWidth);\n c4Shape[\"descr\"].Y = Y + 20;\n Y = c4Shape[\"descr\"].Y + c4Shape[\"descr\"].height;\n rectWidth = Math.max(c4Shape.label.width, c4Shape.descr.width);\n rectHeight = Y - c4Shape[\"descr\"].textLines * 5;\n }\n rectWidth = rectWidth + conf.c4ShapePadding;\n c4Shape.width = Math.max(c4Shape.width || conf.width, rectWidth, conf.width);\n c4Shape.height = Math.max(c4Shape.height || conf.height, rectHeight, conf.height);\n c4Shape.margin = c4Shape.margin || conf.c4ShapeMargin;\n currentBounds.insert(c4Shape);\n svgDraw.drawC4Shape(diagram2, c4Shape, conf);\n }\n currentBounds.bumpLastMargin(conf.c4ShapeMargin);\n};\nclass Point {\n constructor(x, y) {\n this.x = x;\n this.y = y;\n }\n}\nlet getIntersectPoint = function(fromNode, endPoint) {\n let x1 = fromNode.x;\n let y1 = fromNode.y;\n let x2 = endPoint.x;\n let y2 = endPoint.y;\n let fromCenterX = x1 + fromNode.width / 2;\n let fromCenterY = y1 + fromNode.height / 2;\n let dx = Math.abs(x1 - x2);\n let dy = Math.abs(y1 - y2);\n let tanDYX = dy / dx;\n let fromDYX = fromNode.height / fromNode.width;\n let returnPoint = null;\n if (y1 == y2 && x1 < x2) {\n returnPoint = new Point(x1 + fromNode.width, fromCenterY);\n } else if (y1 == y2 && x1 > x2) {\n returnPoint = new Point(x1, fromCenterY);\n } else if (x1 == x2 && y1 < y2) {\n returnPoint = new Point(fromCenterX, y1 + fromNode.height);\n } else if (x1 == x2 && y1 > y2) {\n returnPoint = new Point(fromCenterX, y1);\n }\n if (x1 > x2 && y1 < y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1, fromCenterY + tanDYX * fromNode.width / 2);\n } else {\n returnPoint = new Point(\n fromCenterX - dx / dy * fromNode.height / 2,\n y1 + fromNode.height\n );\n }\n } else if (x1 < x2 && y1 < y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1 + fromNode.width, fromCenterY + tanDYX * fromNode.width / 2);\n } else {\n returnPoint = new Point(\n fromCenterX + dx / dy * fromNode.height / 2,\n y1 + fromNode.height\n );\n }\n } else if (x1 < x2 && y1 > y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1 + fromNode.width, fromCenterY - tanDYX * fromNode.width / 2);\n } else {\n returnPoint = new Point(fromCenterX + fromNode.height / 2 * dx / dy, y1);\n }\n } else if (x1 > x2 && y1 > y2) {\n if (fromDYX >= tanDYX) {\n returnPoint = new Point(x1, fromCenterY - fromNode.width / 2 * tanDYX);\n } else {\n returnPoint = new Point(fromCenterX - fromNode.height / 2 * dx / dy, y1);\n }\n }\n return returnPoint;\n};\nlet getIntersectPoints = function(fromNode, endNode) {\n let endIntersectPoint = { x: 0, y: 0 };\n endIntersectPoint.x = endNode.x + endNode.width / 2;\n endIntersectPoint.y = endNode.y + endNode.height / 2;\n let startPoint = getIntersectPoint(fromNode, endIntersectPoint);\n endIntersectPoint.x = fromNode.x + fromNode.width / 2;\n endIntersectPoint.y = fromNode.y + fromNode.height / 2;\n let endPoint = getIntersectPoint(endNode, endIntersectPoint);\n return { startPoint, endPoint };\n};\nconst drawRels = function(diagram2, rels2, getC4ShapeObj, diagObj) {\n let i = 0;\n for (let rel of rels2) {\n i = i + 1;\n let relTextWrap = rel.wrap && conf.wrap;\n let relConf = messageFont(conf);\n let diagramType = diagObj.db.getC4Type();\n if (diagramType === \"C4Dynamic\") {\n rel.label.text = i + \": \" + rel.label.text;\n }\n let textLimitWidth = calculateTextWidth(rel.label.text, relConf);\n calcC4ShapeTextWH(\"label\", rel, relTextWrap, relConf, textLimitWidth);\n if (rel.techn && rel.techn.text !== \"\") {\n textLimitWidth = calculateTextWidth(rel.techn.text, relConf);\n calcC4ShapeTextWH(\"techn\", rel, relTextWrap, relConf, textLimitWidth);\n }\n if (rel.descr && rel.descr.text !== \"\") {\n textLimitWidth = calculateTextWidth(rel.descr.text, relConf);\n calcC4ShapeTextWH(\"descr\", rel, relTextWrap, relConf, textLimitWidth);\n }\n let fromNode = getC4ShapeObj(rel.from);\n let endNode = getC4ShapeObj(rel.to);\n let points = getIntersectPoints(fromNode, endNode);\n rel.startPoint = points.startPoint;\n rel.endPoint = points.endPoint;\n }\n svgDraw.drawRels(diagram2, rels2, conf);\n};\nfunction drawInsideBoundary(diagram2, parentBoundaryAlias, parentBounds, currentBoundaries, diagObj) {\n let currentBounds = new Bounds(diagObj);\n currentBounds.data.widthLimit = parentBounds.data.widthLimit / Math.min(c4BoundaryInRow, currentBoundaries.length);\n for (let [i, currentBoundary] of currentBoundaries.entries()) {\n let Y = 0;\n currentBoundary.image = { width: 0, height: 0, Y: 0 };\n if (currentBoundary.sprite) {\n currentBoundary.image.width = 48;\n currentBoundary.image.height = 48;\n currentBoundary.image.Y = Y;\n Y = currentBoundary.image.Y + currentBoundary.image.height;\n }\n let currentBoundaryTextWrap = currentBoundary.wrap && conf.wrap;\n let currentBoundaryLabelConf = boundaryFont(conf);\n currentBoundaryLabelConf.fontSize = currentBoundaryLabelConf.fontSize + 2;\n currentBoundaryLabelConf.fontWeight = \"bold\";\n calcC4ShapeTextWH(\n \"label\",\n currentBoundary,\n currentBoundaryTextWrap,\n currentBoundaryLabelConf,\n currentBounds.data.widthLimit\n );\n currentBoundary[\"label\"].Y = Y + 8;\n Y = currentBoundary[\"label\"].Y + currentBoundary[\"label\"].height;\n if (currentBoundary.type && currentBoundary.type.text !== \"\") {\n currentBoundary.type.text = \"[\" + currentBoundary.type.text + \"]\";\n let currentBoundaryTypeConf = boundaryFont(conf);\n calcC4ShapeTextWH(\n \"type\",\n currentBoundary,\n currentBoundaryTextWrap,\n currentBoundaryTypeConf,\n currentBounds.data.widthLimit\n );\n currentBoundary[\"type\"].Y = Y + 5;\n Y = currentBoundary[\"type\"].Y + currentBoundary[\"type\"].height;\n }\n if (currentBoundary.descr && currentBoundary.descr.text !== \"\") {\n let currentBoundaryDescrConf = boundaryFont(conf);\n currentBoundaryDescrConf.fontSize = currentBoundaryDescrConf.fontSize - 2;\n calcC4ShapeTextWH(\n \"descr\",\n currentBoundary,\n currentBoundaryTextWrap,\n currentBoundaryDescrConf,\n currentBounds.data.widthLimit\n );\n currentBoundary[\"descr\"].Y = Y + 20;\n Y = currentBoundary[\"descr\"].Y + currentBoundary[\"descr\"].height;\n }\n if (i == 0 || i % c4BoundaryInRow === 0) {\n let _x = parentBounds.data.startx + conf.diagramMarginX;\n let _y = parentBounds.data.stopy + conf.diagramMarginY + Y;\n currentBounds.setData(_x, _x, _y, _y);\n } else {\n let _x = currentBounds.data.stopx !== currentBounds.data.startx ? currentBounds.data.stopx + conf.diagramMarginX : currentBounds.data.startx;\n let _y = currentBounds.data.starty;\n currentBounds.setData(_x, _x, _y, _y);\n }\n currentBounds.name = currentBoundary.alias;\n let currentPersonOrSystemArray = diagObj.db.getC4ShapeArray(currentBoundary.alias);\n let currentPersonOrSystemKeys = diagObj.db.getC4ShapeKeys(currentBoundary.alias);\n if (currentPersonOrSystemKeys.length > 0) {\n drawC4ShapeArray(\n currentBounds,\n diagram2,\n currentPersonOrSystemArray,\n currentPersonOrSystemKeys\n );\n }\n parentBoundaryAlias = currentBoundary.alias;\n let nextCurrentBoundarys = diagObj.db.getBoundarys(parentBoundaryAlias);\n if (nextCurrentBoundarys.length > 0) {\n drawInsideBoundary(\n diagram2,\n parentBoundaryAlias,\n currentBounds,\n nextCurrentBoundarys,\n diagObj\n );\n }\n if (currentBoundary.alias !== \"global\") {\n drawBoundary(diagram2, currentBoundary, currentBounds);\n }\n parentBounds.data.stopy = Math.max(\n currentBounds.data.stopy + conf.c4ShapeMargin,\n parentBounds.data.stopy\n );\n parentBounds.data.stopx = Math.max(\n currentBounds.data.stopx + conf.c4ShapeMargin,\n parentBounds.data.stopx\n );\n globalBoundaryMaxX = Math.max(globalBoundaryMaxX, parentBounds.data.stopx);\n globalBoundaryMaxY = Math.max(globalBoundaryMaxY, parentBounds.data.stopy);\n }\n}\nconst draw = function(_text, id, _version, diagObj) {\n conf = getConfig().c4;\n const securityLevel = getConfig().securityLevel;\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n let db2 = diagObj.db;\n diagObj.db.setWrap(conf.wrap);\n c4ShapeInRow = db2.getC4ShapeInRow();\n c4BoundaryInRow = db2.getC4BoundaryInRow();\n log.debug(`C:${JSON.stringify(conf, null, 2)}`);\n const diagram2 = securityLevel === \"sandbox\" ? root.select(`[id=\"${id}\"]`) : select(`[id=\"${id}\"]`);\n svgDraw.insertComputerIcon(diagram2);\n svgDraw.insertDatabaseIcon(diagram2);\n svgDraw.insertClockIcon(diagram2);\n let screenBounds = new Bounds(diagObj);\n screenBounds.setData(\n conf.diagramMarginX,\n conf.diagramMarginX,\n conf.diagramMarginY,\n conf.diagramMarginY\n );\n screenBounds.data.widthLimit = screen.availWidth;\n globalBoundaryMaxX = conf.diagramMarginX;\n globalBoundaryMaxY = conf.diagramMarginY;\n const title2 = diagObj.db.getTitle();\n let currentBoundaries = diagObj.db.getBoundarys(\"\");\n drawInsideBoundary(diagram2, \"\", screenBounds, currentBoundaries, diagObj);\n svgDraw.insertArrowHead(diagram2);\n svgDraw.insertArrowEnd(diagram2);\n svgDraw.insertArrowCrossHead(diagram2);\n svgDraw.insertArrowFilledHead(diagram2);\n drawRels(diagram2, diagObj.db.getRels(), diagObj.db.getC4Shape, diagObj);\n screenBounds.data.stopx = globalBoundaryMaxX;\n screenBounds.data.stopy = globalBoundaryMaxY;\n const box = screenBounds.data;\n let boxHeight = box.stopy - box.starty;\n let height = boxHeight + 2 * conf.diagramMarginY;\n let boxWidth = box.stopx - box.startx;\n const width = boxWidth + 2 * conf.diagramMarginX;\n if (title2) {\n diagram2.append(\"text\").text(title2).attr(\"x\", (box.stopx - box.startx) / 2 - 4 * conf.diagramMarginX).attr(\"y\", box.starty + conf.diagramMarginY);\n }\n configureSvgSize(diagram2, height, width, conf.useMaxWidth);\n const extraVertForTitle = title2 ? 60 : 0;\n diagram2.attr(\n \"viewBox\",\n box.startx - conf.diagramMarginX + \" -\" + (conf.diagramMarginY + extraVertForTitle) + \" \" + width + \" \" + (height + extraVertForTitle)\n );\n log.debug(`models:`, box);\n};\nconst renderer = {\n drawPersonOrSystemArray: drawC4ShapeArray,\n drawBoundary,\n setConf,\n draw\n};\nconst getStyles = (options) => `.person {\n stroke: ${options.personBorder};\n fill: ${options.personBkg};\n }\n`;\nconst styles = getStyles;\nconst diagram = {\n parser: parser$1,\n db,\n renderer,\n styles,\n init: ({ c4, wrap }) => {\n renderer.setConf(c4);\n db.setWrap(wrap);\n }\n};\nexport {\n diagram\n};\n"], "mappings": "4RAGA,IAAAA,GAA4B,WAE5B,IAAAC,GAAO,WACPC,GAAO,WAMP,IAAIC,GAAS,UAAW,CACtB,IAAIC,EAAI,SAASC,GAAGC,EAAGC,EAAIC,EAAG,CAC5B,IAAKD,EAAKA,GAAM,CAAC,EAAGC,EAAIH,GAAE,OAAQG,IAAKD,EAAGF,GAAEG,CAAC,CAAC,EAAIF,EAChD,CACF,OAAOC,CACT,EAAGE,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EA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AAc,EAAE,KAAK,IAAKgG,EAAI,OAAShG,EAAK,cAAc,EAEnJiG,GAAiBnE,EAAU1F,EAAQD,EAAO6D,EAAK,WAAW,EAC1D,IAAMkG,EAAoBH,EAAS,GAAK,EACxCjE,EAAS,KACP,UACAkE,EAAI,OAAShG,EAAK,eAAiB,MAAQA,EAAK,eAAiBkG,GAAqB,IAAM/J,EAAQ,KAAOC,EAAS8J,EACtH,EACAL,GAAI,MAAM,UAAWG,CAAG,CAC1B,EACMG,GAAW,CACf,wBAAyBjE,GACzB,aAAAL,GACA,QAAA1B,GACA,KAAAiF,EACF,EACMgB,GAAaC,GAAY;AAAA,cACjBA,EAAQ,YAAY;AAAA,YACtBA,EAAQ,SAAS;AAAA;AAAA,EAGvBC,GAASF,GACTG,GAAU,CACd,OAAQvQ,GACR,GAAA0F,GACA,SAAAyK,GACA,OAAAG,GACA,KAAM,CAAC,CAAE,GAAAE,EAAI,KAAAC,CAAK,IAAM,CACtBN,GAAS,QAAQK,CAAE,EACnB9K,GAAG,QAAQ+K,CAAI,CACjB,CACF", "names": ["import_sanitize_url", "import_dayjs", "import_dompurify", "parser", "o", "k", "v", "o2", "l", "$V0", "$V1", "$V2", "$V3", "$V4", "$V5", "$V6", "$V7", "$V8", "$V9", "$Va", "$Vb", "$Vc", "$Vd", "$Ve", "$Vf", "$Vg", "$Vh", "$Vi", "$Vj", "$Vk", "$Vl", "$Vm", "$Vn", "$Vo", "$Vp", "$Vq", "$Vr", "$Vs", "$Vt", "$Vu", "$Vv", "$Vw", "$Vx", "$Vy", "$Vz", "$VA", "$VB", "$VC", "$VD", "$VE", "$VF", "$VG", "$VH", "$VI", "$VJ", "$VK", "$VL", "$VM", "$VN", "$VO", "$VP", "$VQ", "$VR", "$VS", "parser2", "yytext", "yyleng", "yylineno", "yy", "yystate", "$$", "_$", "$0", "kv", "str", "hash", "error", "input", "self", "stack", "tstack", "vstack", "lstack", "table", "TERROR", "EOF", "args", "lexer2", "sharedState", "yyloc", "ranges", "lex", "token", "symbol", "state", "action", "r", "yyval", "p", "len", "newState", "expected", "errStr", "lexer", "ch", "lines", "oldLines", "n", "past", "next", "pre", "c2", "match", "indexed_rule", "backup", "tempMatch", "index", "rules", "i", "condition", "yy_", "$avoiding_name_collisions", "YY_START", "Parser", "parser$1", "c4ShapeArray", "boundaryParseStack", "currentBoundaryParse", "parentBoundaryParse", "boundarys", "rels", "title", "wrapEnabled", "c4ShapeInRow$1", "c4BoundaryInRow$1", "c4Type", "getC4Type", "setC4Type", "c4TypeParam", "sanitizeText$2", "getConfig", "addRel", "type", "from", "to", "label", "techn", "descr", "sprite", "tags", "link", "rel", "old", "rel2", "key", "value", "autoWrap", "addPersonOrSystem", "typeC4Shape", "alias", "personOrSystem", "personOrSystem2", "addContainer", "container", "container2", "addComponent", "component", "component2", "addPersonOrSystemBoundary", "boundary", "boundary2", "addContainerBoundary", "addDeploymentNode", "nodeType", "popBoundaryParseStack", "updateElStyle", "elementName", "bgColor", "fontColor", "borderColor", "shadowing", "shape", "legendText", "legendSprite", "element", "updateRelStyle", "textColor", "lineColor", "offsetX", "offsetY", "updateLayoutConfig", "c4ShapeInRowParam", "c4BoundaryInRowParam", "c4ShapeInRowValue", "c4BoundaryInRowValue", "getC4ShapeInRow", "getC4BoundaryInRow", "getCurrentBoundaryParse", "getParentBoundaryParse", "getC4ShapeArray", "parentBoundary", "getC4Shape", "getC4ShapeKeys", "getBoundarys", "getRels", "getTitle", "setWrap", "wrapSetting", "clear", "LINETYPE", "ARROWTYPE", "PLACEMENT", "setTitle", "txt", "db", "setAccTitle", "getAccTitle", "getAccDescription", "setAccDescription", "drawRect", "elem", "rectData", "drawImage", "width", "height", "x", "y", "imageElem", "sanitizedLink", "drawRels$1", "rels2", "conf2", "relsElem", "strokeColor", "url", "line", "messageConf", "_drawTextCandidateFunc", "drawBoundary$1", "boundaryElem", "fillColor", "attrsValue", "boundaryConf", "drawC4Shape", "c4Shape", "_a", "personImg", "c4ShapeElem", "rect", "getNoteRect", "c4ShapeFontConf", "getC4ShapeFont", "textFontConf", "insertDatabaseIcon", "insertComputerIcon", "insertClockIcon", "insertArrowHead", "insertArrowEnd", "insertArrowFilledHead", "insertDynamicNumber", "insertArrowCrossHead", "marker", "cnf", "byText", "content", "g", "textAttrs", "text", "_setTextAttrs", "byTspan", "fontSize", "fontFamily", "fontWeight", "common$1", "dy", "byFo", "s", "toText", "fromTextAttrsDict", "svgDraw", "globalBoundaryMaxX", "globalBoundaryMaxY", "c4ShapeInRow", "c4BoundaryInRow", "conf", "Bounds", "diagObj", "setConf", "startx", "stopx", "starty", "stopy", "obj", "val", "fun", "_startx", "_stopx", "_starty", "_stopy", "margin", "assignWithDepth$1", "c4ShapeFont", "boundaryFont", "messageFont", "calcC4ShapeTextWH", "textType", "c4ShapeTextWrap", "textConf", "textLimitWidth", "wrapLabel", "calculateTextHeight", "lineHeight", "calculateTextWidth", "drawBoundary", "diagram2", "bounds", "boundaryTextWrap", "boundaryLabelConf", "drawC4ShapeArray", "currentBounds", "c4ShapeArray2", "c4ShapeKeys", "Y", "c4ShapeKey", "c4ShapeTypeConf", "c4ShapeLabelConf", "c4ShapeTypeConf2", "c4ShapeTechnConf", "rectHeight", "rectWidth", "c4ShapeDescrConf", "Point", "getIntersectPoint", "fromNode", "endPoint", "x1", "y1", "x2", "y2", "fromCenterX", "fromCenterY", "dx", "tanDYX", "fromDYX", "returnPoint", "getIntersectPoints", "endNode", "endIntersectPoint", "startPoint", "drawRels", "getC4ShapeObj", "relTextWrap", "relConf", "points", "drawInsideBoundary", "parentBoundaryAlias", "parentBounds", "currentBoundaries", "currentBoundary", "currentBoundaryTextWrap", "currentBoundaryLabelConf", "currentBoundaryTypeConf", "currentBoundaryDescrConf", "_x", "_y", "currentPersonOrSystemArray", "currentPersonOrSystemKeys", "nextCurrentBoundarys", "draw", "_text", "id", "_version", "securityLevel", "sandboxElement", "select_default", "root", "db2", "log$1", "screenBounds", "title2", "box", "configureSvgSize", "extraVertForTitle", "renderer", "getStyles", "options", "styles", "diagram", "c4", "wrap"] } diff --git a/docs/public/chunk-DVIJHK6F.min.js b/docs/public/chunk-6B5KH4YS.min.js similarity index 97% rename from docs/public/chunk-DVIJHK6F.min.js rename to docs/public/chunk-6B5KH4YS.min.js index ba16535e..e5a69006 100644 --- a/docs/public/chunk-DVIJHK6F.min.js +++ b/docs/public/chunk-6B5KH4YS.min.js @@ -1,4 +1,4 @@ -import{a as q}from"./chunk-2DSXJIGN.min.js";import{j as R}from"./chunk-3BJWU2V2.min.js";import{F as $,Ga as u,Ja as F,K as G,L as P,La as N,Qa as E,Ra as L,T as V,Za as H,ab as U,h as T,i as z,jb as _,ma as M}from"./chunk-65WDIALL.min.js";function oe(e,l){return!!e.children(l).length}function ne(e){return A(e.v)+":"+A(e.w)+":"+A(e.name)}var Q=/:/g;function A(e){return e?String(e).replace(Q,"\\:"):""}function j(e,l){l&&e.attr("style",l)}function se(e,l,c){l&&e.attr("class",l).attr("class",c+" "+e.attr("class"))}function ie(e,l){var c=l.graph();if(M(c)){var a=c.transition;if(V(a))return a(e)}return e}function W(e,l){var c=e.append("foreignObject").attr("width","100000"),a=c.append("xhtml:div");a.attr("xmlns","http://www.w3.org/1999/xhtml");var i=l.label;switch(typeof i){case"function":a.insert(i);break;case"object":a.insert(function(){return i});break;default:a.html(i)}j(a,l.labelStyle),a.style("display","inline-block"),a.style("white-space","nowrap");var d=a.node().getBoundingClientRect();return c.attr("width",d.width).attr("height",d.height),c}var X={},Z=function(e){let l=Object.keys(e);for(let c of l)X[c]=e[c]},J=function(e,l,c,a,i,d){let h=a.select(`[id="${c}"]`);Object.keys(e).forEach(function(p){let r=e[p],g="default";r.classes.length>0&&(g=r.classes.join(" ")),g=g+" flowchart-label";let w=L(r.styles),t=r.text!==void 0?r.text:r.id,s;if(u.info("vertex",r,r.labelType),r.labelType==="markdown")u.info("vertex",r,r.labelType);else if(F(_().flowchart.htmlLabels)){let m={label:t.replace(/fa[blrs]?:fa-[\w-]+/g,k=>``)};s=W(h,m).node(),s.parentNode.removeChild(s)}else{let m=i.createElementNS("http://www.w3.org/2000/svg","text");m.setAttribute("style",w.labelStyle.replace("color:","fill:"));let k=t.split(N.lineBreakRegex);for(let C of k){let v=i.createElementNS("http://www.w3.org/2000/svg","tspan");v.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),v.setAttribute("dy","1em"),v.setAttribute("x","1"),v.textContent=C,m.appendChild(v)}s=m}let b=0,o="";switch(r.type){case"round":b=5,o="rect";break;case"square":o="rect";break;case"diamond":o="question";break;case"hexagon":o="hexagon";break;case"odd":o="rect_left_inv_arrow";break;case"lean_right":o="lean_right";break;case"lean_left":o="lean_left";break;case"trapezoid":o="trapezoid";break;case"inv_trapezoid":o="inv_trapezoid";break;case"odd_right":o="rect_left_inv_arrow";break;case"circle":o="circle";break;case"ellipse":o="ellipse";break;case"stadium":o="stadium";break;case"subroutine":o="subroutine";break;case"cylinder":o="cylinder";break;case"group":o="rect";break;case"doublecircle":o="doublecircle";break;default:o="rect"}l.setNode(r.id,{labelStyle:w.labelStyle,shape:o,labelText:t,labelType:r.labelType,rx:b,ry:b,class:g,style:w.style,id:r.id,link:r.link,linkTarget:r.linkTarget,tooltip:d.db.getTooltip(r.id)||"",domId:d.db.lookUpDomId(r.id),haveCallback:r.haveCallback,width:r.type==="group"?500:void 0,dir:r.dir,type:r.type,props:r.props,padding:_().flowchart.padding}),u.info("setNode",{labelStyle:w.labelStyle,labelType:r.labelType,shape:o,labelText:t,rx:b,ry:b,class:g,style:w.style,id:r.id,domId:d.db.lookUpDomId(r.id),width:r.type==="group"?500:void 0,type:r.type,dir:r.dir,props:r.props,padding:_().flowchart.padding})})},K=function(e,l,c){u.info("abc78 edges = ",e);let a=0,i={},d,h;if(e.defaultStyle!==void 0){let n=L(e.defaultStyle);d=n.style,h=n.labelStyle}e.forEach(function(n){a++;let p="L-"+n.start+"-"+n.end;i[p]===void 0?(i[p]=0,u.info("abc78 new entry",p,i[p])):(i[p]++,u.info("abc78 new entry",p,i[p]));let r=p+"-"+i[p];u.info("abc78 new link id to be used is",p,r,i[p]);let g="LS-"+n.start,w="LE-"+n.end,t={style:"",labelStyle:""};switch(t.minlen=n.length||1,n.type==="arrow_open"?t.arrowhead="none":t.arrowhead="normal",t.arrowTypeStart="arrow_open",t.arrowTypeEnd="arrow_open",n.type){case"double_arrow_cross":t.arrowTypeStart="arrow_cross";case"arrow_cross":t.arrowTypeEnd="arrow_cross";break;case"double_arrow_point":t.arrowTypeStart="arrow_point";case"arrow_point":t.arrowTypeEnd="arrow_point";break;case"double_arrow_circle":t.arrowTypeStart="arrow_circle";case"arrow_circle":t.arrowTypeEnd="arrow_circle";break}let s="",b="";switch(n.stroke){case"normal":s="fill:none;",d!==void 0&&(s=d),h!==void 0&&(b=h),t.thickness="normal",t.pattern="solid";break;case"dotted":t.thickness="normal",t.pattern="dotted",t.style="fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":t.thickness="thick",t.pattern="solid",t.style="stroke-width: 3.5px;fill:none;";break;case"invisible":t.thickness="invisible",t.pattern="solid",t.style="stroke-width: 0;fill:none;";break}if(n.style!==void 0){let o=L(n.style);s=o.style,b=o.labelStyle}t.style=t.style+=s,t.labelStyle=t.labelStyle+=b,n.interpolate!==void 0?t.curve=E(n.interpolate,$):e.defaultInterpolate!==void 0?t.curve=E(e.defaultInterpolate,$):t.curve=E(X.curve,$),n.text===void 0?n.style!==void 0&&(t.arrowheadStyle="fill: #333"):(t.arrowheadStyle="fill: #333",t.labelpos="c"),t.labelType=n.labelType,t.label=n.text.replace(N.lineBreakRegex,` +import{a as q}from"./chunk-VHIEHVUL.min.js";import{j as R}from"./chunk-NAH225X5.min.js";import{F as $,Ga as u,Ja as F,K as G,L as P,La as N,Qa as E,Ra as L,T as V,Za as H,ab as U,h as T,i as z,jb as _,ma as M}from"./chunk-JUXSCBYR.min.js";function oe(e,l){return!!e.children(l).length}function ne(e){return A(e.v)+":"+A(e.w)+":"+A(e.name)}var Q=/:/g;function A(e){return e?String(e).replace(Q,"\\:"):""}function j(e,l){l&&e.attr("style",l)}function se(e,l,c){l&&e.attr("class",l).attr("class",c+" "+e.attr("class"))}function ie(e,l){var c=l.graph();if(M(c)){var a=c.transition;if(V(a))return a(e)}return e}function W(e,l){var c=e.append("foreignObject").attr("width","100000"),a=c.append("xhtml:div");a.attr("xmlns","http://www.w3.org/1999/xhtml");var i=l.label;switch(typeof i){case"function":a.insert(i);break;case"object":a.insert(function(){return i});break;default:a.html(i)}j(a,l.labelStyle),a.style("display","inline-block"),a.style("white-space","nowrap");var d=a.node().getBoundingClientRect();return c.attr("width",d.width).attr("height",d.height),c}var X={},Z=function(e){let l=Object.keys(e);for(let c of l)X[c]=e[c]},J=function(e,l,c,a,i,d){let h=a.select(`[id="${c}"]`);Object.keys(e).forEach(function(p){let r=e[p],g="default";r.classes.length>0&&(g=r.classes.join(" ")),g=g+" flowchart-label";let w=L(r.styles),t=r.text!==void 0?r.text:r.id,s;if(u.info("vertex",r,r.labelType),r.labelType==="markdown")u.info("vertex",r,r.labelType);else if(F(_().flowchart.htmlLabels)){let m={label:t.replace(/fa[blrs]?:fa-[\w-]+/g,k=>``)};s=W(h,m).node(),s.parentNode.removeChild(s)}else{let m=i.createElementNS("http://www.w3.org/2000/svg","text");m.setAttribute("style",w.labelStyle.replace("color:","fill:"));let k=t.split(N.lineBreakRegex);for(let C of k){let v=i.createElementNS("http://www.w3.org/2000/svg","tspan");v.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),v.setAttribute("dy","1em"),v.setAttribute("x","1"),v.textContent=C,m.appendChild(v)}s=m}let b=0,o="";switch(r.type){case"round":b=5,o="rect";break;case"square":o="rect";break;case"diamond":o="question";break;case"hexagon":o="hexagon";break;case"odd":o="rect_left_inv_arrow";break;case"lean_right":o="lean_right";break;case"lean_left":o="lean_left";break;case"trapezoid":o="trapezoid";break;case"inv_trapezoid":o="inv_trapezoid";break;case"odd_right":o="rect_left_inv_arrow";break;case"circle":o="circle";break;case"ellipse":o="ellipse";break;case"stadium":o="stadium";break;case"subroutine":o="subroutine";break;case"cylinder":o="cylinder";break;case"group":o="rect";break;case"doublecircle":o="doublecircle";break;default:o="rect"}l.setNode(r.id,{labelStyle:w.labelStyle,shape:o,labelText:t,labelType:r.labelType,rx:b,ry:b,class:g,style:w.style,id:r.id,link:r.link,linkTarget:r.linkTarget,tooltip:d.db.getTooltip(r.id)||"",domId:d.db.lookUpDomId(r.id),haveCallback:r.haveCallback,width:r.type==="group"?500:void 0,dir:r.dir,type:r.type,props:r.props,padding:_().flowchart.padding}),u.info("setNode",{labelStyle:w.labelStyle,labelType:r.labelType,shape:o,labelText:t,rx:b,ry:b,class:g,style:w.style,id:r.id,domId:d.db.lookUpDomId(r.id),width:r.type==="group"?500:void 0,type:r.type,dir:r.dir,props:r.props,padding:_().flowchart.padding})})},K=function(e,l,c){u.info("abc78 edges = ",e);let a=0,i={},d,h;if(e.defaultStyle!==void 0){let n=L(e.defaultStyle);d=n.style,h=n.labelStyle}e.forEach(function(n){a++;let p="L-"+n.start+"-"+n.end;i[p]===void 0?(i[p]=0,u.info("abc78 new entry",p,i[p])):(i[p]++,u.info("abc78 new entry",p,i[p]));let r=p+"-"+i[p];u.info("abc78 new link id to be used is",p,r,i[p]);let g="LS-"+n.start,w="LE-"+n.end,t={style:"",labelStyle:""};switch(t.minlen=n.length||1,n.type==="arrow_open"?t.arrowhead="none":t.arrowhead="normal",t.arrowTypeStart="arrow_open",t.arrowTypeEnd="arrow_open",n.type){case"double_arrow_cross":t.arrowTypeStart="arrow_cross";case"arrow_cross":t.arrowTypeEnd="arrow_cross";break;case"double_arrow_point":t.arrowTypeStart="arrow_point";case"arrow_point":t.arrowTypeEnd="arrow_point";break;case"double_arrow_circle":t.arrowTypeStart="arrow_circle";case"arrow_circle":t.arrowTypeEnd="arrow_circle";break}let s="",b="";switch(n.stroke){case"normal":s="fill:none;",d!==void 0&&(s=d),h!==void 0&&(b=h),t.thickness="normal",t.pattern="solid";break;case"dotted":t.thickness="normal",t.pattern="dotted",t.style="fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":t.thickness="thick",t.pattern="solid",t.style="stroke-width: 3.5px;fill:none;";break;case"invisible":t.thickness="invisible",t.pattern="solid",t.style="stroke-width: 0;fill:none;";break}if(n.style!==void 0){let o=L(n.style);s=o.style,b=o.labelStyle}t.style=t.style+=s,t.labelStyle=t.labelStyle+=b,n.interpolate!==void 0?t.curve=E(n.interpolate,$):e.defaultInterpolate!==void 0?t.curve=E(e.defaultInterpolate,$):t.curve=E(X.curve,$),n.text===void 0?n.style!==void 0&&(t.arrowheadStyle="fill: #333"):(t.arrowheadStyle="fill: #333",t.labelpos="c"),t.labelType=n.labelType,t.label=n.text.replace(N.lineBreakRegex,` `),n.style===void 0&&(t.style=t.style||"stroke: #333; stroke-width: 1.5px;fill:none;"),t.labelStyle=t.labelStyle.replace("color:","fill:"),t.id=r,t.classes="flowchart-link "+g+" "+w,l.setEdge(n.start,n.end,t,a)})},O=function(e,l){return l.db.getClasses()},ee=async function(e,l,c,a){u.info("Drawing flowchart");let i=a.db.getDirection();i===void 0&&(i="TD");let{securityLevel:d,flowchart:h}=_(),n=h.nodeSpacing||50,p=h.rankSpacing||50,r;d==="sandbox"&&(r=T("#i"+l));let g=d==="sandbox"?T(r.nodes()[0].contentDocument.body):T("body"),w=d==="sandbox"?r.nodes()[0].contentDocument:document,t=new R({multigraph:!0,compound:!0}).setGraph({rankdir:i,nodesep:n,ranksep:p,marginx:0,marginy:0}).setDefaultEdgeLabel(function(){return{}}),s,b=a.db.getSubGraphs();u.info("Subgraphs - ",b);for(let f=b.length-1;f>=0;f--)s=b[f],u.info("Subgraph - ",s),a.db.addVertex(s.id,{text:s.title,type:s.labelType},"group",void 0,s.classes,s.dir);let o=a.db.getVertices(),m=a.db.getEdges();u.info("Edges",m);let k=0;for(k=b.length-1;k>=0;k--){s=b[k],z("cluster").append("text");for(let f=0;f{let c=P,a=c(e,"r"),i=c(e,"g"),d=c(e,"b");return G(a,i,d,l)},re=e=>`.label { font-family: ${e.fontFamily}; color: ${e.nodeTextColor||e.textColor}; @@ -108,4 +108,4 @@ import{a as q}from"./chunk-2DSXJIGN.min.js";import{j as R}from"./chunk-3BJWU2V2. fill: ${e.textColor}; } `,ye=re;export{oe as a,ne as b,j as c,se as d,ie as e,W as f,we as g,ye as h}; -//# sourceMappingURL=chunk-DVIJHK6F.min.js.map +//# sourceMappingURL=chunk-6B5KH4YS.min.js.map diff --git a/docs/public/chunk-DVIJHK6F.min.js.map b/docs/public/chunk-6B5KH4YS.min.js.map similarity index 99% rename from docs/public/chunk-DVIJHK6F.min.js.map rename to docs/public/chunk-6B5KH4YS.min.js.map index 20f90d40..4efb6fc8 100644 --- a/docs/public/chunk-DVIJHK6F.min.js.map +++ b/docs/public/chunk-6B5KH4YS.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/dagre-d3-es/src/dagre-js/util.js", "../../node_modules/dagre-d3-es/src/dagre-js/label/add-html-label.js", "../../node_modules/mermaid/dist/styles-080da4f6.js"], - "sourcesContent": ["import * as _ from 'lodash-es';\n\n// Public utility functions\nexport { isSubgraph, edgeToId, applyStyle, applyClass, applyTransition };\n\n/*\n * Returns true if the specified node in the graph is a subgraph node. A\n * subgraph node is one that contains other nodes.\n */\nfunction isSubgraph(g, v) {\n return !!g.children(v).length;\n}\n\nfunction edgeToId(e) {\n return escapeId(e.v) + ':' + escapeId(e.w) + ':' + escapeId(e.name);\n}\n\nvar ID_DELIM = /:/g;\nfunction escapeId(str) {\n return str ? String(str).replace(ID_DELIM, '\\\\:') : '';\n}\n\nfunction applyStyle(dom, styleFn) {\n if (styleFn) {\n dom.attr('style', styleFn);\n }\n}\n\nfunction applyClass(dom, classFn, otherClasses) {\n if (classFn) {\n dom.attr('class', classFn).attr('class', otherClasses + ' ' + dom.attr('class'));\n }\n}\n\nfunction applyTransition(selection, g) {\n var graph = g.graph();\n\n if (_.isPlainObject(graph)) {\n var transition = graph.transition;\n if (_.isFunction(transition)) {\n return transition(selection);\n }\n }\n\n return selection;\n}\n", "import * as util from '../util.js';\n\nexport { addHtmlLabel };\n\nfunction addHtmlLabel(root, node) {\n var fo = root.append('foreignObject').attr('width', '100000');\n\n var div = fo.append('xhtml:div');\n div.attr('xmlns', 'http://www.w3.org/1999/xhtml');\n\n var label = node.label;\n switch (typeof label) {\n case 'function':\n div.insert(label);\n break;\n case 'object':\n // Currently we assume this is a DOM object.\n div.insert(function () {\n return label;\n });\n break;\n default:\n div.html(label);\n }\n\n util.applyStyle(div, node.labelStyle);\n div.style('display', 'inline-block');\n // Fix for firefox\n div.style('white-space', 'nowrap');\n\n var client = div.node().getBoundingClientRect();\n fo.attr('width', client.width).attr('height', client.height);\n\n return fo;\n}\n", "import * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { curveLinear, select, selectAll } from \"d3\";\nimport { k as getStylesFromArray, l as log, m as evaluate, c as getConfig, e as common, n as interpolateToCurve, u as utils, o as setupGraphViewbox } from \"./mermaid-8af3addd.js\";\nimport { r as render } from \"./index-2c4b9a3b.js\";\nimport { addHtmlLabel } from \"dagre-d3-es/src/dagre-js/label/add-html-label.js\";\nimport * as khroma from \"khroma\";\nconst conf = {};\nconst setConf = function(cnf) {\n const keys = Object.keys(cnf);\n for (const key of keys) {\n conf[key] = cnf[key];\n }\n};\nconst addVertices = function(vert, g, svgId, root, doc, diagObj) {\n const svg = root.select(`[id=\"${svgId}\"]`);\n const keys = Object.keys(vert);\n keys.forEach(function(id) {\n const vertex = vert[id];\n let classStr = \"default\";\n if (vertex.classes.length > 0) {\n classStr = vertex.classes.join(\" \");\n }\n classStr = classStr + \" flowchart-label\";\n const styles = getStylesFromArray(vertex.styles);\n let vertexText = vertex.text !== void 0 ? vertex.text : vertex.id;\n let vertexNode;\n log.info(\"vertex\", vertex, vertex.labelType);\n if (vertex.labelType === \"markdown\") {\n log.info(\"vertex\", vertex, vertex.labelType);\n } else {\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const node = {\n label: vertexText.replace(\n /fa[blrs]?:fa-[\\w-]+/g,\n (s) => ``\n )\n };\n vertexNode = addHtmlLabel(svg, node).node();\n vertexNode.parentNode.removeChild(vertexNode);\n } else {\n const svgLabel = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"text\");\n svgLabel.setAttribute(\"style\", styles.labelStyle.replace(\"color:\", \"fill:\"));\n const rows = vertexText.split(common.lineBreakRegex);\n for (const row of rows) {\n const tspan = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"tspan\");\n tspan.setAttributeNS(\"http://www.w3.org/XML/1998/namespace\", \"xml:space\", \"preserve\");\n tspan.setAttribute(\"dy\", \"1em\");\n tspan.setAttribute(\"x\", \"1\");\n tspan.textContent = row;\n svgLabel.appendChild(tspan);\n }\n vertexNode = svgLabel;\n }\n }\n let radious = 0;\n let _shape = \"\";\n switch (vertex.type) {\n case \"round\":\n radious = 5;\n _shape = \"rect\";\n break;\n case \"square\":\n _shape = \"rect\";\n break;\n case \"diamond\":\n _shape = \"question\";\n break;\n case \"hexagon\":\n _shape = \"hexagon\";\n break;\n case \"odd\":\n _shape = \"rect_left_inv_arrow\";\n break;\n case \"lean_right\":\n _shape = \"lean_right\";\n break;\n case \"lean_left\":\n _shape = \"lean_left\";\n break;\n case \"trapezoid\":\n _shape = \"trapezoid\";\n break;\n case \"inv_trapezoid\":\n _shape = \"inv_trapezoid\";\n break;\n case \"odd_right\":\n _shape = \"rect_left_inv_arrow\";\n break;\n case \"circle\":\n _shape = \"circle\";\n break;\n case \"ellipse\":\n _shape = \"ellipse\";\n break;\n case \"stadium\":\n _shape = \"stadium\";\n break;\n case \"subroutine\":\n _shape = \"subroutine\";\n break;\n case \"cylinder\":\n _shape = \"cylinder\";\n break;\n case \"group\":\n _shape = \"rect\";\n break;\n case \"doublecircle\":\n _shape = \"doublecircle\";\n break;\n default:\n _shape = \"rect\";\n }\n g.setNode(vertex.id, {\n labelStyle: styles.labelStyle,\n shape: _shape,\n labelText: vertexText,\n labelType: vertex.labelType,\n rx: radious,\n ry: radious,\n class: classStr,\n style: styles.style,\n id: vertex.id,\n link: vertex.link,\n linkTarget: vertex.linkTarget,\n tooltip: diagObj.db.getTooltip(vertex.id) || \"\",\n domId: diagObj.db.lookUpDomId(vertex.id),\n haveCallback: vertex.haveCallback,\n width: vertex.type === \"group\" ? 500 : void 0,\n dir: vertex.dir,\n type: vertex.type,\n props: vertex.props,\n padding: getConfig().flowchart.padding\n });\n log.info(\"setNode\", {\n labelStyle: styles.labelStyle,\n labelType: vertex.labelType,\n shape: _shape,\n labelText: vertexText,\n rx: radious,\n ry: radious,\n class: classStr,\n style: styles.style,\n id: vertex.id,\n domId: diagObj.db.lookUpDomId(vertex.id),\n width: vertex.type === \"group\" ? 500 : void 0,\n type: vertex.type,\n dir: vertex.dir,\n props: vertex.props,\n padding: getConfig().flowchart.padding\n });\n });\n};\nconst addEdges = function(edges, g, diagObj) {\n log.info(\"abc78 edges = \", edges);\n let cnt = 0;\n let linkIdCnt = {};\n let defaultStyle;\n let defaultLabelStyle;\n if (edges.defaultStyle !== void 0) {\n const defaultStyles = getStylesFromArray(edges.defaultStyle);\n defaultStyle = defaultStyles.style;\n defaultLabelStyle = defaultStyles.labelStyle;\n }\n edges.forEach(function(edge) {\n cnt++;\n const linkIdBase = \"L-\" + edge.start + \"-\" + edge.end;\n if (linkIdCnt[linkIdBase] === void 0) {\n linkIdCnt[linkIdBase] = 0;\n log.info(\"abc78 new entry\", linkIdBase, linkIdCnt[linkIdBase]);\n } else {\n linkIdCnt[linkIdBase]++;\n log.info(\"abc78 new entry\", linkIdBase, linkIdCnt[linkIdBase]);\n }\n let linkId = linkIdBase + \"-\" + linkIdCnt[linkIdBase];\n log.info(\"abc78 new link id to be used is\", linkIdBase, linkId, linkIdCnt[linkIdBase]);\n const linkNameStart = \"LS-\" + edge.start;\n const linkNameEnd = \"LE-\" + edge.end;\n const edgeData = { style: \"\", labelStyle: \"\" };\n edgeData.minlen = edge.length || 1;\n if (edge.type === \"arrow_open\") {\n edgeData.arrowhead = \"none\";\n } else {\n edgeData.arrowhead = \"normal\";\n }\n edgeData.arrowTypeStart = \"arrow_open\";\n edgeData.arrowTypeEnd = \"arrow_open\";\n switch (edge.type) {\n case \"double_arrow_cross\":\n edgeData.arrowTypeStart = \"arrow_cross\";\n case \"arrow_cross\":\n edgeData.arrowTypeEnd = \"arrow_cross\";\n break;\n case \"double_arrow_point\":\n edgeData.arrowTypeStart = \"arrow_point\";\n case \"arrow_point\":\n edgeData.arrowTypeEnd = \"arrow_point\";\n break;\n case \"double_arrow_circle\":\n edgeData.arrowTypeStart = \"arrow_circle\";\n case \"arrow_circle\":\n edgeData.arrowTypeEnd = \"arrow_circle\";\n break;\n }\n let style = \"\";\n let labelStyle = \"\";\n switch (edge.stroke) {\n case \"normal\":\n style = \"fill:none;\";\n if (defaultStyle !== void 0) {\n style = defaultStyle;\n }\n if (defaultLabelStyle !== void 0) {\n labelStyle = defaultLabelStyle;\n }\n edgeData.thickness = \"normal\";\n edgeData.pattern = \"solid\";\n break;\n case \"dotted\":\n edgeData.thickness = \"normal\";\n edgeData.pattern = \"dotted\";\n edgeData.style = \"fill:none;stroke-width:2px;stroke-dasharray:3;\";\n break;\n case \"thick\":\n edgeData.thickness = \"thick\";\n edgeData.pattern = \"solid\";\n edgeData.style = \"stroke-width: 3.5px;fill:none;\";\n break;\n case \"invisible\":\n edgeData.thickness = \"invisible\";\n edgeData.pattern = \"solid\";\n edgeData.style = \"stroke-width: 0;fill:none;\";\n break;\n }\n if (edge.style !== void 0) {\n const styles = getStylesFromArray(edge.style);\n style = styles.style;\n labelStyle = styles.labelStyle;\n }\n edgeData.style = edgeData.style += style;\n edgeData.labelStyle = edgeData.labelStyle += labelStyle;\n if (edge.interpolate !== void 0) {\n edgeData.curve = interpolateToCurve(edge.interpolate, curveLinear);\n } else if (edges.defaultInterpolate !== void 0) {\n edgeData.curve = interpolateToCurve(edges.defaultInterpolate, curveLinear);\n } else {\n edgeData.curve = interpolateToCurve(conf.curve, curveLinear);\n }\n if (edge.text === void 0) {\n if (edge.style !== void 0) {\n edgeData.arrowheadStyle = \"fill: #333\";\n }\n } else {\n edgeData.arrowheadStyle = \"fill: #333\";\n edgeData.labelpos = \"c\";\n }\n edgeData.labelType = edge.labelType;\n edgeData.label = edge.text.replace(common.lineBreakRegex, \"\\n\");\n if (edge.style === void 0) {\n edgeData.style = edgeData.style || \"stroke: #333; stroke-width: 1.5px;fill:none;\";\n }\n edgeData.labelStyle = edgeData.labelStyle.replace(\"color:\", \"fill:\");\n edgeData.id = linkId;\n edgeData.classes = \"flowchart-link \" + linkNameStart + \" \" + linkNameEnd;\n g.setEdge(edge.start, edge.end, edgeData, cnt);\n });\n};\nconst getClasses = function(text, diagObj) {\n return diagObj.db.getClasses();\n};\nconst draw = async function(text, id, _version, diagObj) {\n log.info(\"Drawing flowchart\");\n let dir = diagObj.db.getDirection();\n if (dir === void 0) {\n dir = \"TD\";\n }\n const { securityLevel, flowchart: conf2 } = getConfig();\n const nodeSpacing = conf2.nodeSpacing || 50;\n const rankSpacing = conf2.rankSpacing || 50;\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n const doc = securityLevel === \"sandbox\" ? sandboxElement.nodes()[0].contentDocument : document;\n const g = new graphlib.Graph({\n multigraph: true,\n compound: true\n }).setGraph({\n rankdir: dir,\n nodesep: nodeSpacing,\n ranksep: rankSpacing,\n marginx: 0,\n marginy: 0\n }).setDefaultEdgeLabel(function() {\n return {};\n });\n let subG;\n const subGraphs = diagObj.db.getSubGraphs();\n log.info(\"Subgraphs - \", subGraphs);\n for (let i2 = subGraphs.length - 1; i2 >= 0; i2--) {\n subG = subGraphs[i2];\n log.info(\"Subgraph - \", subG);\n diagObj.db.addVertex(\n subG.id,\n { text: subG.title, type: subG.labelType },\n \"group\",\n void 0,\n subG.classes,\n subG.dir\n );\n }\n const vert = diagObj.db.getVertices();\n const edges = diagObj.db.getEdges();\n log.info(\"Edges\", edges);\n let i = 0;\n for (i = subGraphs.length - 1; i >= 0; i--) {\n subG = subGraphs[i];\n selectAll(\"cluster\").append(\"text\");\n for (let j = 0; j < subG.nodes.length; j++) {\n log.info(\"Setting up subgraphs\", subG.nodes[j], subG.id);\n g.setParent(subG.nodes[j], subG.id);\n }\n }\n addVertices(vert, g, id, root, doc, diagObj);\n addEdges(edges, g);\n const svg = root.select(`[id=\"${id}\"]`);\n const element = root.select(\"#\" + id + \" g\");\n await render(element, g, [\"point\", \"circle\", \"cross\"], \"flowchart\", id);\n utils.insertTitle(svg, \"flowchartTitleText\", conf2.titleTopMargin, diagObj.db.getDiagramTitle());\n setupGraphViewbox(g, svg, conf2.diagramPadding, conf2.useMaxWidth);\n diagObj.db.indexNodes(\"subGraph\" + i);\n if (!conf2.htmlLabels) {\n const labels = doc.querySelectorAll('[id=\"' + id + '\"] .edgeLabel .label');\n for (const label of labels) {\n const dim = label.getBBox();\n const rect = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"rect\");\n rect.setAttribute(\"rx\", 0);\n rect.setAttribute(\"ry\", 0);\n rect.setAttribute(\"width\", dim.width);\n rect.setAttribute(\"height\", dim.height);\n label.insertBefore(rect, label.firstChild);\n }\n }\n const keys = Object.keys(vert);\n keys.forEach(function(key) {\n const vertex = vert[key];\n if (vertex.link) {\n const node = select(\"#\" + id + ' [id=\"' + key + '\"]');\n if (node) {\n const link = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"a\");\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"class\", vertex.classes.join(\" \"));\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"href\", vertex.link);\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"rel\", \"noopener\");\n if (securityLevel === \"sandbox\") {\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"target\", \"_top\");\n } else if (vertex.linkTarget) {\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"target\", vertex.linkTarget);\n }\n const linkNode = node.insert(function() {\n return link;\n }, \":first-child\");\n const shape = node.select(\".label-container\");\n if (shape) {\n linkNode.append(function() {\n return shape.node();\n });\n }\n const label = node.select(\".label\");\n if (label) {\n linkNode.append(function() {\n return label.node();\n });\n }\n }\n }\n });\n};\nconst flowRendererV2 = {\n setConf,\n addVertices,\n addEdges,\n getClasses,\n draw\n};\nconst fade = (color, opacity) => {\n const channel = khroma.channel;\n const r = channel(color, \"r\");\n const g = channel(color, \"g\");\n const b = channel(color, \"b\");\n return khroma.rgba(r, g, b, opacity);\n};\nconst getStyles = (options) => `.label {\n font-family: ${options.fontFamily};\n color: ${options.nodeTextColor || options.textColor};\n }\n .cluster-label text {\n fill: ${options.titleColor};\n }\n .cluster-label span,p {\n color: ${options.titleColor};\n }\n\n .label text,span,p {\n fill: ${options.nodeTextColor || options.textColor};\n color: ${options.nodeTextColor || options.textColor};\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n stroke-width: 1px;\n }\n .flowchart-label text {\n text-anchor: middle;\n }\n // .flowchart-label .text-outer-tspan {\n // text-anchor: middle;\n // }\n // .flowchart-label .text-inner-tspan {\n // text-anchor: start;\n // }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ${options.arrowheadColor};\n }\n\n .edgePath .path {\n stroke: ${options.lineColor};\n stroke-width: 2.0px;\n }\n\n .flowchart-link {\n stroke: ${options.lineColor};\n fill: none;\n }\n\n .edgeLabel {\n background-color: ${options.edgeLabelBackground};\n rect {\n opacity: 0.5;\n background-color: ${options.edgeLabelBackground};\n fill: ${options.edgeLabelBackground};\n }\n text-align: center;\n }\n\n /* For html labels only */\n .labelBkg {\n background-color: ${fade(options.edgeLabelBackground, 0.5)};\n // background-color: \n }\n\n .cluster rect {\n fill: ${options.clusterBkg};\n stroke: ${options.clusterBorder};\n stroke-width: 1px;\n }\n\n .cluster text {\n fill: ${options.titleColor};\n }\n\n .cluster span,p {\n color: ${options.titleColor};\n }\n /* .cluster div {\n color: ${options.titleColor};\n } */\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ${options.fontFamily};\n font-size: 12px;\n background: ${options.tertiaryColor};\n border: 1px solid ${options.border2};\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .flowchartTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${options.textColor};\n }\n`;\nconst flowStyles = getStyles;\nexport {\n flowStyles as a,\n flowRendererV2 as f\n};\n"], + "sources": ["../../node_modules/dagre-d3-es/src/dagre-js/util.js", "../../node_modules/dagre-d3-es/src/dagre-js/label/add-html-label.js", "../../node_modules/mermaid/dist/styles-b966c4ae.js"], + "sourcesContent": ["import * as _ from 'lodash-es';\n\n// Public utility functions\nexport { isSubgraph, edgeToId, applyStyle, applyClass, applyTransition };\n\n/*\n * Returns true if the specified node in the graph is a subgraph node. A\n * subgraph node is one that contains other nodes.\n */\nfunction isSubgraph(g, v) {\n return !!g.children(v).length;\n}\n\nfunction edgeToId(e) {\n return escapeId(e.v) + ':' + escapeId(e.w) + ':' + escapeId(e.name);\n}\n\nvar ID_DELIM = /:/g;\nfunction escapeId(str) {\n return str ? String(str).replace(ID_DELIM, '\\\\:') : '';\n}\n\nfunction applyStyle(dom, styleFn) {\n if (styleFn) {\n dom.attr('style', styleFn);\n }\n}\n\nfunction applyClass(dom, classFn, otherClasses) {\n if (classFn) {\n dom.attr('class', classFn).attr('class', otherClasses + ' ' + dom.attr('class'));\n }\n}\n\nfunction applyTransition(selection, g) {\n var graph = g.graph();\n\n if (_.isPlainObject(graph)) {\n var transition = graph.transition;\n if (_.isFunction(transition)) {\n return transition(selection);\n }\n }\n\n return selection;\n}\n", "import * as util from '../util.js';\n\nexport { addHtmlLabel };\n\nfunction addHtmlLabel(root, node) {\n var fo = root.append('foreignObject').attr('width', '100000');\n\n var div = fo.append('xhtml:div');\n div.attr('xmlns', 'http://www.w3.org/1999/xhtml');\n\n var label = node.label;\n switch (typeof label) {\n case 'function':\n div.insert(label);\n break;\n case 'object':\n // Currently we assume this is a DOM object.\n div.insert(function () {\n return label;\n });\n break;\n default:\n div.html(label);\n }\n\n util.applyStyle(div, node.labelStyle);\n div.style('display', 'inline-block');\n // Fix for firefox\n div.style('white-space', 'nowrap');\n\n var client = div.node().getBoundingClientRect();\n fo.attr('width', client.width).attr('height', client.height);\n\n return fo;\n}\n", "import * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { curveLinear, select, selectAll } from \"d3\";\nimport { k as getStylesFromArray, l as log, m as evaluate, c as getConfig, e as common, n as interpolateToCurve, u as utils, o as setupGraphViewbox } from \"./mermaid-934d9bea.js\";\nimport { r as render } from \"./index-67a42d7d.js\";\nimport { addHtmlLabel } from \"dagre-d3-es/src/dagre-js/label/add-html-label.js\";\nimport * as khroma from \"khroma\";\nconst conf = {};\nconst setConf = function(cnf) {\n const keys = Object.keys(cnf);\n for (const key of keys) {\n conf[key] = cnf[key];\n }\n};\nconst addVertices = function(vert, g, svgId, root, doc, diagObj) {\n const svg = root.select(`[id=\"${svgId}\"]`);\n const keys = Object.keys(vert);\n keys.forEach(function(id) {\n const vertex = vert[id];\n let classStr = \"default\";\n if (vertex.classes.length > 0) {\n classStr = vertex.classes.join(\" \");\n }\n classStr = classStr + \" flowchart-label\";\n const styles = getStylesFromArray(vertex.styles);\n let vertexText = vertex.text !== void 0 ? vertex.text : vertex.id;\n let vertexNode;\n log.info(\"vertex\", vertex, vertex.labelType);\n if (vertex.labelType === \"markdown\") {\n log.info(\"vertex\", vertex, vertex.labelType);\n } else {\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const node = {\n label: vertexText.replace(\n /fa[blrs]?:fa-[\\w-]+/g,\n (s) => ``\n )\n };\n vertexNode = addHtmlLabel(svg, node).node();\n vertexNode.parentNode.removeChild(vertexNode);\n } else {\n const svgLabel = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"text\");\n svgLabel.setAttribute(\"style\", styles.labelStyle.replace(\"color:\", \"fill:\"));\n const rows = vertexText.split(common.lineBreakRegex);\n for (const row of rows) {\n const tspan = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"tspan\");\n tspan.setAttributeNS(\"http://www.w3.org/XML/1998/namespace\", \"xml:space\", \"preserve\");\n tspan.setAttribute(\"dy\", \"1em\");\n tspan.setAttribute(\"x\", \"1\");\n tspan.textContent = row;\n svgLabel.appendChild(tspan);\n }\n vertexNode = svgLabel;\n }\n }\n let radious = 0;\n let _shape = \"\";\n switch (vertex.type) {\n case \"round\":\n radious = 5;\n _shape = \"rect\";\n break;\n case \"square\":\n _shape = \"rect\";\n break;\n case \"diamond\":\n _shape = \"question\";\n break;\n case \"hexagon\":\n _shape = \"hexagon\";\n break;\n case \"odd\":\n _shape = \"rect_left_inv_arrow\";\n break;\n case \"lean_right\":\n _shape = \"lean_right\";\n break;\n case \"lean_left\":\n _shape = \"lean_left\";\n break;\n case \"trapezoid\":\n _shape = \"trapezoid\";\n break;\n case \"inv_trapezoid\":\n _shape = \"inv_trapezoid\";\n break;\n case \"odd_right\":\n _shape = \"rect_left_inv_arrow\";\n break;\n case \"circle\":\n _shape = \"circle\";\n break;\n case \"ellipse\":\n _shape = \"ellipse\";\n break;\n case \"stadium\":\n _shape = \"stadium\";\n break;\n case \"subroutine\":\n _shape = \"subroutine\";\n break;\n case \"cylinder\":\n _shape = \"cylinder\";\n break;\n case \"group\":\n _shape = \"rect\";\n break;\n case \"doublecircle\":\n _shape = \"doublecircle\";\n break;\n default:\n _shape = \"rect\";\n }\n g.setNode(vertex.id, {\n labelStyle: styles.labelStyle,\n shape: _shape,\n labelText: vertexText,\n labelType: vertex.labelType,\n rx: radious,\n ry: radious,\n class: classStr,\n style: styles.style,\n id: vertex.id,\n link: vertex.link,\n linkTarget: vertex.linkTarget,\n tooltip: diagObj.db.getTooltip(vertex.id) || \"\",\n domId: diagObj.db.lookUpDomId(vertex.id),\n haveCallback: vertex.haveCallback,\n width: vertex.type === \"group\" ? 500 : void 0,\n dir: vertex.dir,\n type: vertex.type,\n props: vertex.props,\n padding: getConfig().flowchart.padding\n });\n log.info(\"setNode\", {\n labelStyle: styles.labelStyle,\n labelType: vertex.labelType,\n shape: _shape,\n labelText: vertexText,\n rx: radious,\n ry: radious,\n class: classStr,\n style: styles.style,\n id: vertex.id,\n domId: diagObj.db.lookUpDomId(vertex.id),\n width: vertex.type === \"group\" ? 500 : void 0,\n type: vertex.type,\n dir: vertex.dir,\n props: vertex.props,\n padding: getConfig().flowchart.padding\n });\n });\n};\nconst addEdges = function(edges, g, diagObj) {\n log.info(\"abc78 edges = \", edges);\n let cnt = 0;\n let linkIdCnt = {};\n let defaultStyle;\n let defaultLabelStyle;\n if (edges.defaultStyle !== void 0) {\n const defaultStyles = getStylesFromArray(edges.defaultStyle);\n defaultStyle = defaultStyles.style;\n defaultLabelStyle = defaultStyles.labelStyle;\n }\n edges.forEach(function(edge) {\n cnt++;\n const linkIdBase = \"L-\" + edge.start + \"-\" + edge.end;\n if (linkIdCnt[linkIdBase] === void 0) {\n linkIdCnt[linkIdBase] = 0;\n log.info(\"abc78 new entry\", linkIdBase, linkIdCnt[linkIdBase]);\n } else {\n linkIdCnt[linkIdBase]++;\n log.info(\"abc78 new entry\", linkIdBase, linkIdCnt[linkIdBase]);\n }\n let linkId = linkIdBase + \"-\" + linkIdCnt[linkIdBase];\n log.info(\"abc78 new link id to be used is\", linkIdBase, linkId, linkIdCnt[linkIdBase]);\n const linkNameStart = \"LS-\" + edge.start;\n const linkNameEnd = \"LE-\" + edge.end;\n const edgeData = { style: \"\", labelStyle: \"\" };\n edgeData.minlen = edge.length || 1;\n if (edge.type === \"arrow_open\") {\n edgeData.arrowhead = \"none\";\n } else {\n edgeData.arrowhead = \"normal\";\n }\n edgeData.arrowTypeStart = \"arrow_open\";\n edgeData.arrowTypeEnd = \"arrow_open\";\n switch (edge.type) {\n case \"double_arrow_cross\":\n edgeData.arrowTypeStart = \"arrow_cross\";\n case \"arrow_cross\":\n edgeData.arrowTypeEnd = \"arrow_cross\";\n break;\n case \"double_arrow_point\":\n edgeData.arrowTypeStart = \"arrow_point\";\n case \"arrow_point\":\n edgeData.arrowTypeEnd = \"arrow_point\";\n break;\n case \"double_arrow_circle\":\n edgeData.arrowTypeStart = \"arrow_circle\";\n case \"arrow_circle\":\n edgeData.arrowTypeEnd = \"arrow_circle\";\n break;\n }\n let style = \"\";\n let labelStyle = \"\";\n switch (edge.stroke) {\n case \"normal\":\n style = \"fill:none;\";\n if (defaultStyle !== void 0) {\n style = defaultStyle;\n }\n if (defaultLabelStyle !== void 0) {\n labelStyle = defaultLabelStyle;\n }\n edgeData.thickness = \"normal\";\n edgeData.pattern = \"solid\";\n break;\n case \"dotted\":\n edgeData.thickness = \"normal\";\n edgeData.pattern = \"dotted\";\n edgeData.style = \"fill:none;stroke-width:2px;stroke-dasharray:3;\";\n break;\n case \"thick\":\n edgeData.thickness = \"thick\";\n edgeData.pattern = \"solid\";\n edgeData.style = \"stroke-width: 3.5px;fill:none;\";\n break;\n case \"invisible\":\n edgeData.thickness = \"invisible\";\n edgeData.pattern = \"solid\";\n edgeData.style = \"stroke-width: 0;fill:none;\";\n break;\n }\n if (edge.style !== void 0) {\n const styles = getStylesFromArray(edge.style);\n style = styles.style;\n labelStyle = styles.labelStyle;\n }\n edgeData.style = edgeData.style += style;\n edgeData.labelStyle = edgeData.labelStyle += labelStyle;\n if (edge.interpolate !== void 0) {\n edgeData.curve = interpolateToCurve(edge.interpolate, curveLinear);\n } else if (edges.defaultInterpolate !== void 0) {\n edgeData.curve = interpolateToCurve(edges.defaultInterpolate, curveLinear);\n } else {\n edgeData.curve = interpolateToCurve(conf.curve, curveLinear);\n }\n if (edge.text === void 0) {\n if (edge.style !== void 0) {\n edgeData.arrowheadStyle = \"fill: #333\";\n }\n } else {\n edgeData.arrowheadStyle = \"fill: #333\";\n edgeData.labelpos = \"c\";\n }\n edgeData.labelType = edge.labelType;\n edgeData.label = edge.text.replace(common.lineBreakRegex, \"\\n\");\n if (edge.style === void 0) {\n edgeData.style = edgeData.style || \"stroke: #333; stroke-width: 1.5px;fill:none;\";\n }\n edgeData.labelStyle = edgeData.labelStyle.replace(\"color:\", \"fill:\");\n edgeData.id = linkId;\n edgeData.classes = \"flowchart-link \" + linkNameStart + \" \" + linkNameEnd;\n g.setEdge(edge.start, edge.end, edgeData, cnt);\n });\n};\nconst getClasses = function(text, diagObj) {\n return diagObj.db.getClasses();\n};\nconst draw = async function(text, id, _version, diagObj) {\n log.info(\"Drawing flowchart\");\n let dir = diagObj.db.getDirection();\n if (dir === void 0) {\n dir = \"TD\";\n }\n const { securityLevel, flowchart: conf2 } = getConfig();\n const nodeSpacing = conf2.nodeSpacing || 50;\n const rankSpacing = conf2.rankSpacing || 50;\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n const doc = securityLevel === \"sandbox\" ? sandboxElement.nodes()[0].contentDocument : document;\n const g = new graphlib.Graph({\n multigraph: true,\n compound: true\n }).setGraph({\n rankdir: dir,\n nodesep: nodeSpacing,\n ranksep: rankSpacing,\n marginx: 0,\n marginy: 0\n }).setDefaultEdgeLabel(function() {\n return {};\n });\n let subG;\n const subGraphs = diagObj.db.getSubGraphs();\n log.info(\"Subgraphs - \", subGraphs);\n for (let i2 = subGraphs.length - 1; i2 >= 0; i2--) {\n subG = subGraphs[i2];\n log.info(\"Subgraph - \", subG);\n diagObj.db.addVertex(\n subG.id,\n { text: subG.title, type: subG.labelType },\n \"group\",\n void 0,\n subG.classes,\n subG.dir\n );\n }\n const vert = diagObj.db.getVertices();\n const edges = diagObj.db.getEdges();\n log.info(\"Edges\", edges);\n let i = 0;\n for (i = subGraphs.length - 1; i >= 0; i--) {\n subG = subGraphs[i];\n selectAll(\"cluster\").append(\"text\");\n for (let j = 0; j < subG.nodes.length; j++) {\n log.info(\"Setting up subgraphs\", subG.nodes[j], subG.id);\n g.setParent(subG.nodes[j], subG.id);\n }\n }\n addVertices(vert, g, id, root, doc, diagObj);\n addEdges(edges, g);\n const svg = root.select(`[id=\"${id}\"]`);\n const element = root.select(\"#\" + id + \" g\");\n await render(element, g, [\"point\", \"circle\", \"cross\"], \"flowchart\", id);\n utils.insertTitle(svg, \"flowchartTitleText\", conf2.titleTopMargin, diagObj.db.getDiagramTitle());\n setupGraphViewbox(g, svg, conf2.diagramPadding, conf2.useMaxWidth);\n diagObj.db.indexNodes(\"subGraph\" + i);\n if (!conf2.htmlLabels) {\n const labels = doc.querySelectorAll('[id=\"' + id + '\"] .edgeLabel .label');\n for (const label of labels) {\n const dim = label.getBBox();\n const rect = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"rect\");\n rect.setAttribute(\"rx\", 0);\n rect.setAttribute(\"ry\", 0);\n rect.setAttribute(\"width\", dim.width);\n rect.setAttribute(\"height\", dim.height);\n label.insertBefore(rect, label.firstChild);\n }\n }\n const keys = Object.keys(vert);\n keys.forEach(function(key) {\n const vertex = vert[key];\n if (vertex.link) {\n const node = select(\"#\" + id + ' [id=\"' + key + '\"]');\n if (node) {\n const link = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"a\");\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"class\", vertex.classes.join(\" \"));\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"href\", vertex.link);\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"rel\", \"noopener\");\n if (securityLevel === \"sandbox\") {\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"target\", \"_top\");\n } else if (vertex.linkTarget) {\n link.setAttributeNS(\"http://www.w3.org/2000/svg\", \"target\", vertex.linkTarget);\n }\n const linkNode = node.insert(function() {\n return link;\n }, \":first-child\");\n const shape = node.select(\".label-container\");\n if (shape) {\n linkNode.append(function() {\n return shape.node();\n });\n }\n const label = node.select(\".label\");\n if (label) {\n linkNode.append(function() {\n return label.node();\n });\n }\n }\n }\n });\n};\nconst flowRendererV2 = {\n setConf,\n addVertices,\n addEdges,\n getClasses,\n draw\n};\nconst fade = (color, opacity) => {\n const channel = khroma.channel;\n const r = channel(color, \"r\");\n const g = channel(color, \"g\");\n const b = channel(color, \"b\");\n return khroma.rgba(r, g, b, opacity);\n};\nconst getStyles = (options) => `.label {\n font-family: ${options.fontFamily};\n color: ${options.nodeTextColor || options.textColor};\n }\n .cluster-label text {\n fill: ${options.titleColor};\n }\n .cluster-label span,p {\n color: ${options.titleColor};\n }\n\n .label text,span,p {\n fill: ${options.nodeTextColor || options.textColor};\n color: ${options.nodeTextColor || options.textColor};\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n stroke-width: 1px;\n }\n .flowchart-label text {\n text-anchor: middle;\n }\n // .flowchart-label .text-outer-tspan {\n // text-anchor: middle;\n // }\n // .flowchart-label .text-inner-tspan {\n // text-anchor: start;\n // }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ${options.arrowheadColor};\n }\n\n .edgePath .path {\n stroke: ${options.lineColor};\n stroke-width: 2.0px;\n }\n\n .flowchart-link {\n stroke: ${options.lineColor};\n fill: none;\n }\n\n .edgeLabel {\n background-color: ${options.edgeLabelBackground};\n rect {\n opacity: 0.5;\n background-color: ${options.edgeLabelBackground};\n fill: ${options.edgeLabelBackground};\n }\n text-align: center;\n }\n\n /* For html labels only */\n .labelBkg {\n background-color: ${fade(options.edgeLabelBackground, 0.5)};\n // background-color: \n }\n\n .cluster rect {\n fill: ${options.clusterBkg};\n stroke: ${options.clusterBorder};\n stroke-width: 1px;\n }\n\n .cluster text {\n fill: ${options.titleColor};\n }\n\n .cluster span,p {\n color: ${options.titleColor};\n }\n /* .cluster div {\n color: ${options.titleColor};\n } */\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ${options.fontFamily};\n font-size: 12px;\n background: ${options.tertiaryColor};\n border: 1px solid ${options.border2};\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .flowchartTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${options.textColor};\n }\n`;\nconst flowStyles = getStyles;\nexport {\n flowStyles as a,\n flowRendererV2 as f\n};\n"], "mappings": "+OASA,SAASA,GAAWC,EAAGC,EAAG,CACxB,MAAO,CAAC,CAACD,EAAE,SAASC,CAAC,EAAE,MACzB,CAEA,SAASC,GAAS,EAAG,CACnB,OAAOC,EAAS,EAAE,CAAC,EAAI,IAAMA,EAAS,EAAE,CAAC,EAAI,IAAMA,EAAS,EAAE,IAAI,CACpE,CAEA,IAAIC,EAAW,KACf,SAASD,EAASE,EAAK,CACrB,OAAOA,EAAM,OAAOA,CAAG,EAAE,QAAQD,EAAU,KAAK,EAAI,EACtD,CAEA,SAASE,EAAWC,EAAKC,EAAS,CAC5BA,GACFD,EAAI,KAAK,QAASC,CAAO,CAE7B,CAEA,SAASC,GAAWF,EAAKG,EAASC,EAAc,CAC1CD,GACFH,EAAI,KAAK,QAASG,CAAO,EAAE,KAAK,QAASC,EAAe,IAAMJ,EAAI,KAAK,OAAO,CAAC,CAEnF,CAEA,SAASK,GAAgBC,EAAWb,EAAG,CACrC,IAAIc,EAAQd,EAAE,MAAM,EAEpB,GAAMe,EAAcD,CAAK,EAAG,CAC1B,IAAIE,EAAaF,EAAM,WACvB,GAAMG,EAAWD,CAAU,EACzB,OAAOA,EAAWH,CAAS,CAE/B,CAEA,OAAOA,CACT,CCzCA,SAASK,EAAaC,EAAMC,EAAM,CAChC,IAAIC,EAAKF,EAAK,OAAO,eAAe,EAAE,KAAK,QAAS,QAAQ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;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,wBAOjBT,GAAKS,EAAQ,oBAAqB,EAAG,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA,YAKlDA,EAAQ,UAAU;AAAA,cAChBA,EAAQ,aAAa;AAAA;AAAA;AAAA;AAAA;AAAA,YAKvBA,EAAQ,UAAU;AAAA;AAAA;AAAA;AAAA,aAIjBA,EAAQ,UAAU;AAAA;AAAA;AAAA,aAGlBA,EAAQ,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAQZA,EAAQ,UAAU;AAAA;AAAA,kBAEnBA,EAAQ,aAAa;AAAA,wBACfA,EAAQ,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,YAS3BA,EAAQ,SAAS;AAAA;AAAA,EAGvBC,GAAaF", "names": ["isSubgraph", "g", "v", "edgeToId", "escapeId", "ID_DELIM", "str", "applyStyle", "dom", "styleFn", "applyClass", "classFn", "otherClasses", "applyTransition", "selection", "graph", "isPlainObject_default", "transition", "isFunction_default", "addHtmlLabel", "root", "node", "fo", "div", "label", "applyStyle", "client", "conf", "setConf", "cnf", "keys", "key", "addVertices", "vert", "g", "svgId", "root", "doc", "diagObj", "svg", "id", "vertex", "classStr", "styles", "getStylesFromArray", "vertexText", "vertexNode", "log$1", "evaluate", "getConfig", "node", "s", "addHtmlLabel", "svgLabel", "rows", "common$1", "row", "tspan", "radious", "_shape", "addEdges", "edges", "cnt", "linkIdCnt", "defaultStyle", "defaultLabelStyle", "defaultStyles", "edge", "linkIdBase", "linkId", "linkNameStart", "linkNameEnd", "edgeData", "style", "labelStyle", "interpolateToCurve", "linear_default", "getClasses", "text", "draw", "_version", "dir", "securityLevel", "conf2", "nodeSpacing", "rankSpacing", "sandboxElement", "select_default", "Graph", "subG", "subGraphs", "i2", "i", "selectAll_default", "j", "element", "render", "utils", "setupGraphViewbox$1", "labels", "label", "dim", "rect", "link", "linkNode", "shape", "flowRendererV2", "fade", "color", "opacity", "channel", "channel_default", "r", "b", "rgba_default", "getStyles", "options", "flowStyles"] } diff --git a/docs/public/chunk-SLGVIWBJ.min.js b/docs/public/chunk-I7FFVXYK.min.js similarity index 99% rename from docs/public/chunk-SLGVIWBJ.min.js rename to docs/public/chunk-I7FFVXYK.min.js index 4e991b3b..adb17d46 100644 --- a/docs/public/chunk-SLGVIWBJ.min.js +++ b/docs/public/chunk-I7FFVXYK.min.js @@ -1,4 +1,4 @@ -import{Ga as k,La as F,Sa as vt,bb as At,cb as Lt,db as It,eb as Ot,fb as Nt,gb as Rt,hb as wt,jb as R}from"./chunk-65WDIALL.min.js";var gt=function(){var t=function(C,r,n,i){for(n=n||{},i=C.length;i--;n[C[i]]=r);return n},s=[1,2],a=[1,3],h=[1,4],f=[2,4],d=[1,9],y=[1,11],E=[1,15],u=[1,16],b=[1,17],T=[1,18],w=[1,30],j=[1,19],U=[1,20],z=[1,21],M=[1,22],H=[1,23],X=[1,25],K=[1,26],W=[1,27],J=[1,28],q=[1,29],Q=[1,32],Z=[1,33],tt=[1,34],et=[1,35],$=[1,31],c=[1,4,5,15,16,18,20,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],st=[1,4,5,13,14,15,16,18,20,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],Dt=[4,5,15,16,18,20,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],ht={trace:function(){},yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,cssClassStatement:11,idStatement:12,DESCR:13,"-->":14,HIDE_EMPTY:15,scale:16,WIDTH:17,COMPOSIT_STATE:18,STRUCT_START:19,STRUCT_STOP:20,STATE_DESCR:21,AS:22,ID:23,FORK:24,JOIN:25,CHOICE:26,CONCURRENT:27,note:28,notePosition:29,NOTE_TEXT:30,direction:31,acc_title:32,acc_title_value:33,acc_descr:34,acc_descr_value:35,acc_descr_multiline_value:36,classDef:37,CLASSDEF_ID:38,CLASSDEF_STYLEOPTS:39,DEFAULT:40,class:41,CLASSENTITY_IDS:42,STYLECLASS:43,direction_tb:44,direction_bt:45,direction_rl:46,direction_lr:47,eol:48,";":49,EDGE_STATE:50,STYLE_SEPARATOR:51,left_of:52,right_of:53,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",6:"SD",13:"DESCR",14:"-->",15:"HIDE_EMPTY",16:"scale",17:"WIDTH",18:"COMPOSIT_STATE",19:"STRUCT_START",20:"STRUCT_STOP",21:"STATE_DESCR",22:"AS",23:"ID",24:"FORK",25:"JOIN",26:"CHOICE",27:"CONCURRENT",28:"note",30:"NOTE_TEXT",32:"acc_title",33:"acc_title_value",34:"acc_descr",35:"acc_descr_value",36:"acc_descr_multiline_value",37:"classDef",38:"CLASSDEF_ID",39:"CLASSDEF_STYLEOPTS",40:"DEFAULT",41:"class",42:"CLASSENTITY_IDS",43:"STYLECLASS",44:"direction_tb",45:"direction_bt",46:"direction_rl",47:"direction_lr",49:";",50:"EDGE_STATE",51:"STYLE_SEPARATOR",52:"left_of",53:"right_of"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[10,3],[10,3],[11,3],[31,1],[31,1],[31,1],[31,1],[48,1],[48,1],[12,1],[12,1],[12,3],[12,3],[29,1],[29,1]],performAction:function(r,n,i,o,p,e,B){var l=e.length-1;switch(p){case 3:return o.setRootDoc(e[l]),e[l];case 4:this.$=[];break;case 5:e[l]!="nl"&&(e[l-1].push(e[l]),this.$=e[l-1]);break;case 6:case 7:this.$=e[l];break;case 8:this.$="nl";break;case 11:this.$=e[l];break;case 12:let P=e[l-1];P.description=o.trimColon(e[l]),this.$=P;break;case 13:this.$={stmt:"relation",state1:e[l-2],state2:e[l]};break;case 14:let ft=o.trimColon(e[l]);this.$={stmt:"relation",state1:e[l-3],state2:e[l-1],description:ft};break;case 18:this.$={stmt:"state",id:e[l-3],type:"default",description:"",doc:e[l-1]};break;case 19:var v=e[l],O=e[l-2].trim();if(e[l].match(":")){var it=e[l].split(":");v=it[0],O=[O,it[1]]}this.$={stmt:"state",id:v,type:"default",description:O};break;case 20:this.$={stmt:"state",id:e[l-3],type:"default",description:e[l-5],doc:e[l-1]};break;case 21:this.$={stmt:"state",id:e[l],type:"fork"};break;case 22:this.$={stmt:"state",id:e[l],type:"join"};break;case 23:this.$={stmt:"state",id:e[l],type:"choice"};break;case 24:this.$={stmt:"state",id:o.getDividerId(),type:"divider"};break;case 25:this.$={stmt:"state",id:e[l-1].trim(),note:{position:e[l-2].trim(),text:e[l].trim()}};break;case 28:this.$=e[l].trim(),o.setAccTitle(this.$);break;case 29:case 30:this.$=e[l].trim(),o.setAccDescription(this.$);break;case 31:case 32:this.$={stmt:"classDef",id:e[l-1].trim(),classes:e[l].trim()};break;case 33:this.$={stmt:"applyClass",id:e[l-1].trim(),styleClass:e[l].trim()};break;case 34:o.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 35:o.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 36:o.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 37:o.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 40:case 41:this.$={stmt:"state",id:e[l].trim(),type:"default",description:""};break;case 42:this.$={stmt:"state",id:e[l-2].trim(),classes:[e[l].trim()],type:"default",description:""};break;case 43:this.$={stmt:"state",id:e[l-2].trim(),classes:[e[l].trim()],type:"default",description:""};break}},table:[{3:1,4:s,5:a,6:h},{1:[3]},{3:5,4:s,5:a,6:h},{3:6,4:s,5:a,6:h},t([1,4,5,15,16,18,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],f,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:d,5:y,8:8,9:10,10:12,11:13,12:14,15:E,16:u,18:b,21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,5]),{9:36,10:12,11:13,12:14,15:E,16:u,18:b,21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,7]),t(c,[2,8]),t(c,[2,9]),t(c,[2,10]),t(c,[2,11],{13:[1,37],14:[1,38]}),t(c,[2,15]),{17:[1,39]},t(c,[2,17],{19:[1,40]}),{22:[1,41]},t(c,[2,21]),t(c,[2,22]),t(c,[2,23]),t(c,[2,24]),{29:42,30:[1,43],52:[1,44],53:[1,45]},t(c,[2,27]),{33:[1,46]},{35:[1,47]},t(c,[2,30]),{38:[1,48],40:[1,49]},{42:[1,50]},t(st,[2,40],{51:[1,51]}),t(st,[2,41],{51:[1,52]}),t(c,[2,34]),t(c,[2,35]),t(c,[2,36]),t(c,[2,37]),t(c,[2,6]),t(c,[2,12]),{12:53,23:w,50:$},t(c,[2,16]),t(Dt,f,{7:54}),{23:[1,55]},{23:[1,56]},{22:[1,57]},{23:[2,44]},{23:[2,45]},t(c,[2,28]),t(c,[2,29]),{39:[1,58]},{39:[1,59]},{43:[1,60]},{23:[1,61]},{23:[1,62]},t(c,[2,13],{13:[1,63]}),{4:d,5:y,8:8,9:10,10:12,11:13,12:14,15:E,16:u,18:b,20:[1,64],21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,19],{19:[1,65]}),{30:[1,66]},{23:[1,67]},t(c,[2,31]),t(c,[2,32]),t(c,[2,33]),t(st,[2,42]),t(st,[2,43]),t(c,[2,14]),t(c,[2,18]),t(Dt,f,{7:68}),t(c,[2,25]),t(c,[2,26]),{4:d,5:y,8:8,9:10,10:12,11:13,12:14,15:E,16:u,18:b,20:[1,69],21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,20])],defaultActions:{5:[2,1],6:[2,2],44:[2,44],45:[2,45]},parseError:function(r,n){if(n.recoverable)this.trace(r);else{var i=new Error(r);throw i.hash=n,i}},parse:function(r){var n=this,i=[0],o=[],p=[null],e=[],B=this.table,l="",v=0,O=0,it=2,P=1,ft=e.slice.call(arguments,1),S=Object.create(this.lexer),A={yy:{}};for(var dt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,dt)&&(A.yy[dt]=this.yy[dt]);S.setInput(r,A.yy),A.yy.lexer=S,A.yy.parser=this,typeof S.yylloc>"u"&&(S.yylloc={});var yt=S.yylloc;e.push(yt);var Wt=S.options&&S.options.ranges;typeof A.yy.parseError=="function"?this.parseError=A.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Jt(){var D;return D=o.pop()||S.lex()||P,typeof D!="number"&&(D instanceof Array&&(o=D,D=o.pop()),D=n.symbols_[D]||D),D}for(var _,L,m,pt,N={},rt,x,Ct,nt;;){if(L=i[i.length-1],this.defaultActions[L]?m=this.defaultActions[L]:((_===null||typeof _>"u")&&(_=Jt()),m=B[L]&&B[L][_]),typeof m>"u"||!m.length||!m[0]){var St="";nt=[];for(rt in B[L])this.terminals_[rt]&&rt>it&&nt.push("'"+this.terminals_[rt]+"'");S.showPosition?St="Parse error on line "+(v+1)+`: +import{Ga as k,La as F,Sa as vt,bb as At,cb as Lt,db as It,eb as Ot,fb as Nt,gb as Rt,hb as wt,jb as R}from"./chunk-JUXSCBYR.min.js";var gt=function(){var t=function(C,r,n,i){for(n=n||{},i=C.length;i--;n[C[i]]=r);return n},s=[1,2],a=[1,3],h=[1,4],f=[2,4],d=[1,9],y=[1,11],E=[1,15],u=[1,16],b=[1,17],T=[1,18],w=[1,30],j=[1,19],U=[1,20],z=[1,21],M=[1,22],H=[1,23],X=[1,25],K=[1,26],W=[1,27],J=[1,28],q=[1,29],Q=[1,32],Z=[1,33],tt=[1,34],et=[1,35],$=[1,31],c=[1,4,5,15,16,18,20,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],st=[1,4,5,13,14,15,16,18,20,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],Dt=[4,5,15,16,18,20,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],ht={trace:function(){},yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,cssClassStatement:11,idStatement:12,DESCR:13,"-->":14,HIDE_EMPTY:15,scale:16,WIDTH:17,COMPOSIT_STATE:18,STRUCT_START:19,STRUCT_STOP:20,STATE_DESCR:21,AS:22,ID:23,FORK:24,JOIN:25,CHOICE:26,CONCURRENT:27,note:28,notePosition:29,NOTE_TEXT:30,direction:31,acc_title:32,acc_title_value:33,acc_descr:34,acc_descr_value:35,acc_descr_multiline_value:36,classDef:37,CLASSDEF_ID:38,CLASSDEF_STYLEOPTS:39,DEFAULT:40,class:41,CLASSENTITY_IDS:42,STYLECLASS:43,direction_tb:44,direction_bt:45,direction_rl:46,direction_lr:47,eol:48,";":49,EDGE_STATE:50,STYLE_SEPARATOR:51,left_of:52,right_of:53,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",6:"SD",13:"DESCR",14:"-->",15:"HIDE_EMPTY",16:"scale",17:"WIDTH",18:"COMPOSIT_STATE",19:"STRUCT_START",20:"STRUCT_STOP",21:"STATE_DESCR",22:"AS",23:"ID",24:"FORK",25:"JOIN",26:"CHOICE",27:"CONCURRENT",28:"note",30:"NOTE_TEXT",32:"acc_title",33:"acc_title_value",34:"acc_descr",35:"acc_descr_value",36:"acc_descr_multiline_value",37:"classDef",38:"CLASSDEF_ID",39:"CLASSDEF_STYLEOPTS",40:"DEFAULT",41:"class",42:"CLASSENTITY_IDS",43:"STYLECLASS",44:"direction_tb",45:"direction_bt",46:"direction_rl",47:"direction_lr",49:";",50:"EDGE_STATE",51:"STYLE_SEPARATOR",52:"left_of",53:"right_of"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[10,3],[10,3],[11,3],[31,1],[31,1],[31,1],[31,1],[48,1],[48,1],[12,1],[12,1],[12,3],[12,3],[29,1],[29,1]],performAction:function(r,n,i,o,p,e,B){var l=e.length-1;switch(p){case 3:return o.setRootDoc(e[l]),e[l];case 4:this.$=[];break;case 5:e[l]!="nl"&&(e[l-1].push(e[l]),this.$=e[l-1]);break;case 6:case 7:this.$=e[l];break;case 8:this.$="nl";break;case 11:this.$=e[l];break;case 12:let P=e[l-1];P.description=o.trimColon(e[l]),this.$=P;break;case 13:this.$={stmt:"relation",state1:e[l-2],state2:e[l]};break;case 14:let ft=o.trimColon(e[l]);this.$={stmt:"relation",state1:e[l-3],state2:e[l-1],description:ft};break;case 18:this.$={stmt:"state",id:e[l-3],type:"default",description:"",doc:e[l-1]};break;case 19:var v=e[l],O=e[l-2].trim();if(e[l].match(":")){var it=e[l].split(":");v=it[0],O=[O,it[1]]}this.$={stmt:"state",id:v,type:"default",description:O};break;case 20:this.$={stmt:"state",id:e[l-3],type:"default",description:e[l-5],doc:e[l-1]};break;case 21:this.$={stmt:"state",id:e[l],type:"fork"};break;case 22:this.$={stmt:"state",id:e[l],type:"join"};break;case 23:this.$={stmt:"state",id:e[l],type:"choice"};break;case 24:this.$={stmt:"state",id:o.getDividerId(),type:"divider"};break;case 25:this.$={stmt:"state",id:e[l-1].trim(),note:{position:e[l-2].trim(),text:e[l].trim()}};break;case 28:this.$=e[l].trim(),o.setAccTitle(this.$);break;case 29:case 30:this.$=e[l].trim(),o.setAccDescription(this.$);break;case 31:case 32:this.$={stmt:"classDef",id:e[l-1].trim(),classes:e[l].trim()};break;case 33:this.$={stmt:"applyClass",id:e[l-1].trim(),styleClass:e[l].trim()};break;case 34:o.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 35:o.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 36:o.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 37:o.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 40:case 41:this.$={stmt:"state",id:e[l].trim(),type:"default",description:""};break;case 42:this.$={stmt:"state",id:e[l-2].trim(),classes:[e[l].trim()],type:"default",description:""};break;case 43:this.$={stmt:"state",id:e[l-2].trim(),classes:[e[l].trim()],type:"default",description:""};break}},table:[{3:1,4:s,5:a,6:h},{1:[3]},{3:5,4:s,5:a,6:h},{3:6,4:s,5:a,6:h},t([1,4,5,15,16,18,21,23,24,25,26,27,28,32,34,36,37,41,44,45,46,47,50],f,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:d,5:y,8:8,9:10,10:12,11:13,12:14,15:E,16:u,18:b,21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,5]),{9:36,10:12,11:13,12:14,15:E,16:u,18:b,21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,7]),t(c,[2,8]),t(c,[2,9]),t(c,[2,10]),t(c,[2,11],{13:[1,37],14:[1,38]}),t(c,[2,15]),{17:[1,39]},t(c,[2,17],{19:[1,40]}),{22:[1,41]},t(c,[2,21]),t(c,[2,22]),t(c,[2,23]),t(c,[2,24]),{29:42,30:[1,43],52:[1,44],53:[1,45]},t(c,[2,27]),{33:[1,46]},{35:[1,47]},t(c,[2,30]),{38:[1,48],40:[1,49]},{42:[1,50]},t(st,[2,40],{51:[1,51]}),t(st,[2,41],{51:[1,52]}),t(c,[2,34]),t(c,[2,35]),t(c,[2,36]),t(c,[2,37]),t(c,[2,6]),t(c,[2,12]),{12:53,23:w,50:$},t(c,[2,16]),t(Dt,f,{7:54}),{23:[1,55]},{23:[1,56]},{22:[1,57]},{23:[2,44]},{23:[2,45]},t(c,[2,28]),t(c,[2,29]),{39:[1,58]},{39:[1,59]},{43:[1,60]},{23:[1,61]},{23:[1,62]},t(c,[2,13],{13:[1,63]}),{4:d,5:y,8:8,9:10,10:12,11:13,12:14,15:E,16:u,18:b,20:[1,64],21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,19],{19:[1,65]}),{30:[1,66]},{23:[1,67]},t(c,[2,31]),t(c,[2,32]),t(c,[2,33]),t(st,[2,42]),t(st,[2,43]),t(c,[2,14]),t(c,[2,18]),t(Dt,f,{7:68}),t(c,[2,25]),t(c,[2,26]),{4:d,5:y,8:8,9:10,10:12,11:13,12:14,15:E,16:u,18:b,20:[1,69],21:T,23:w,24:j,25:U,26:z,27:M,28:H,31:24,32:X,34:K,36:W,37:J,41:q,44:Q,45:Z,46:tt,47:et,50:$},t(c,[2,20])],defaultActions:{5:[2,1],6:[2,2],44:[2,44],45:[2,45]},parseError:function(r,n){if(n.recoverable)this.trace(r);else{var i=new Error(r);throw i.hash=n,i}},parse:function(r){var n=this,i=[0],o=[],p=[null],e=[],B=this.table,l="",v=0,O=0,it=2,P=1,ft=e.slice.call(arguments,1),S=Object.create(this.lexer),A={yy:{}};for(var dt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,dt)&&(A.yy[dt]=this.yy[dt]);S.setInput(r,A.yy),A.yy.lexer=S,A.yy.parser=this,typeof S.yylloc>"u"&&(S.yylloc={});var yt=S.yylloc;e.push(yt);var Wt=S.options&&S.options.ranges;typeof A.yy.parseError=="function"?this.parseError=A.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Jt(){var D;return D=o.pop()||S.lex()||P,typeof D!="number"&&(D instanceof Array&&(o=D,D=o.pop()),D=n.symbols_[D]||D),D}for(var _,L,m,pt,N={},rt,x,Ct,nt;;){if(L=i[i.length-1],this.defaultActions[L]?m=this.defaultActions[L]:((_===null||typeof _>"u")&&(_=Jt()),m=B[L]&&B[L][_]),typeof m>"u"||!m.length||!m[0]){var St="";nt=[];for(rt in B[L])this.terminals_[rt]&&rt>it&&nt.push("'"+this.terminals_[rt]+"'");S.showPosition?St="Parse error on line "+(v+1)+`: `+S.showPosition()+` Expecting `+nt.join(", ")+", got '"+(this.terminals_[_]||_)+"'":St="Parse error on line "+(v+1)+": Unexpected "+(_==P?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(St,{text:S.match,token:this.terminals_[_]||_,line:S.yylineno,loc:yt,expected:nt})}if(m[0]instanceof Array&&m.length>1)throw new Error("Parse Error: multiple actions possible at state: "+L+", token: "+_);switch(m[0]){case 1:i.push(_),p.push(S.yytext),e.push(S.yylloc),i.push(m[1]),_=null,O=S.yyleng,l=S.yytext,v=S.yylineno,yt=S.yylloc;break;case 2:if(x=this.productions_[m[1]][1],N.$=p[p.length-x],N._$={first_line:e[e.length-(x||1)].first_line,last_line:e[e.length-1].last_line,first_column:e[e.length-(x||1)].first_column,last_column:e[e.length-1].last_column},Wt&&(N._$.range=[e[e.length-(x||1)].range[0],e[e.length-1].range[1]]),pt=this.performAction.apply(N,[l,O,v,A.yy,m[1],p,e].concat(ft)),typeof pt<"u")return pt;x&&(i=i.slice(0,-1*x*2),p=p.slice(0,-1*x),e=e.slice(0,-1*x)),i.push(this.productions_[m[1]][0]),p.push(N.$),e.push(N._$),Ct=B[i[i.length-2]][i[i.length-1]],i.push(Ct);break;case 3:return!0}}return!0}},Kt=function(){var C={EOF:1,parseError:function(n,i){if(this.yy.parser)this.yy.parser.parseError(n,i);else throw new Error(n)},setInput:function(r,n){return this.yy=n||this.yy||{},this._input=r,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var r=this._input[0];this.yytext+=r,this.yyleng++,this.offset++,this.match+=r,this.matched+=r;var n=r.match(/(?:\r\n?|\n).*/g);return n?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),r},unput:function(r){var n=r.length,i=r.split(/(?:\r\n?|\n)/g);this._input=r+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-n),this.offset-=n;var o=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),i.length-1&&(this.yylineno-=i.length-1);var p=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:i?(i.length===o.length?this.yylloc.first_column:0)+o[o.length-i.length].length-i[0].length:this.yylloc.first_column-n},this.options.ranges&&(this.yylloc.range=[p[0],p[0]+this.yyleng-n]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(r){this.unput(this.match.slice(r))},pastInput:function(){var r=this.matched.substr(0,this.matched.length-this.match.length);return(r.length>20?"...":"")+r.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var r=this.match;return r.length<20&&(r+=this._input.substr(0,20-r.length)),(r.substr(0,20)+(r.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var r=this.pastInput(),n=new Array(r.length+1).join("-");return r+this.upcomingInput()+` @@ -205,4 +205,4 @@ g.stateGroup line { fill: ${t.textColor}; } `,Ae=be;export{De as a,Ce as b,_t as c,Ft as d,Et as e,te as f,ve as g,Ae as h}; -//# sourceMappingURL=chunk-SLGVIWBJ.min.js.map +//# sourceMappingURL=chunk-I7FFVXYK.min.js.map diff --git a/docs/public/chunk-SLGVIWBJ.min.js.map b/docs/public/chunk-I7FFVXYK.min.js.map similarity index 99% rename from docs/public/chunk-SLGVIWBJ.min.js.map rename to docs/public/chunk-I7FFVXYK.min.js.map index 5cd769f8..83ef2c8d 100644 --- a/docs/public/chunk-SLGVIWBJ.min.js.map +++ b/docs/public/chunk-I7FFVXYK.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/styles-9c745c82.js"], - "sourcesContent": ["import { c as getConfig, g as getAccTitle, s as setAccTitle, a as getAccDescription, b as setAccDescription, q as setDiagramTitle, r as getDiagramTitle, l as log, e as common, t as clear$1, G as generateId } from \"./mermaid-8af3addd.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 2], $V1 = [1, 3], $V2 = [1, 4], $V3 = [2, 4], $V4 = [1, 9], $V5 = [1, 11], $V6 = [1, 15], $V7 = [1, 16], $V8 = [1, 17], $V9 = [1, 18], $Va = [1, 30], $Vb = [1, 19], $Vc = [1, 20], $Vd = [1, 21], $Ve = [1, 22], $Vf = [1, 23], $Vg = [1, 25], $Vh = [1, 26], $Vi = [1, 27], $Vj = [1, 28], $Vk = [1, 29], $Vl = [1, 32], $Vm = [1, 33], $Vn = [1, 34], $Vo = [1, 35], $Vp = [1, 31], $Vq = [1, 4, 5, 15, 16, 18, 20, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50], $Vr = [1, 4, 5, 13, 14, 15, 16, 18, 20, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50], $Vs = [4, 5, 15, 16, 18, 20, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"SPACE\": 4, \"NL\": 5, \"SD\": 6, \"document\": 7, \"line\": 8, \"statement\": 9, \"classDefStatement\": 10, \"cssClassStatement\": 11, \"idStatement\": 12, \"DESCR\": 13, \"-->\": 14, \"HIDE_EMPTY\": 15, \"scale\": 16, \"WIDTH\": 17, \"COMPOSIT_STATE\": 18, \"STRUCT_START\": 19, \"STRUCT_STOP\": 20, \"STATE_DESCR\": 21, \"AS\": 22, \"ID\": 23, \"FORK\": 24, \"JOIN\": 25, \"CHOICE\": 26, \"CONCURRENT\": 27, \"note\": 28, \"notePosition\": 29, \"NOTE_TEXT\": 30, \"direction\": 31, \"acc_title\": 32, \"acc_title_value\": 33, \"acc_descr\": 34, \"acc_descr_value\": 35, \"acc_descr_multiline_value\": 36, \"classDef\": 37, \"CLASSDEF_ID\": 38, \"CLASSDEF_STYLEOPTS\": 39, \"DEFAULT\": 40, \"class\": 41, \"CLASSENTITY_IDS\": 42, \"STYLECLASS\": 43, \"direction_tb\": 44, \"direction_bt\": 45, \"direction_rl\": 46, \"direction_lr\": 47, \"eol\": 48, \";\": 49, \"EDGE_STATE\": 50, \"STYLE_SEPARATOR\": 51, \"left_of\": 52, \"right_of\": 53, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 4: \"SPACE\", 5: \"NL\", 6: \"SD\", 13: \"DESCR\", 14: \"-->\", 15: \"HIDE_EMPTY\", 16: \"scale\", 17: \"WIDTH\", 18: \"COMPOSIT_STATE\", 19: \"STRUCT_START\", 20: \"STRUCT_STOP\", 21: \"STATE_DESCR\", 22: \"AS\", 23: \"ID\", 24: \"FORK\", 25: \"JOIN\", 26: \"CHOICE\", 27: \"CONCURRENT\", 28: \"note\", 30: \"NOTE_TEXT\", 32: \"acc_title\", 33: \"acc_title_value\", 34: \"acc_descr\", 35: \"acc_descr_value\", 36: \"acc_descr_multiline_value\", 37: \"classDef\", 38: \"CLASSDEF_ID\", 39: \"CLASSDEF_STYLEOPTS\", 40: \"DEFAULT\", 41: \"class\", 42: \"CLASSENTITY_IDS\", 43: \"STYLECLASS\", 44: \"direction_tb\", 45: \"direction_bt\", 46: \"direction_rl\", 47: \"direction_lr\", 49: \";\", 50: \"EDGE_STATE\", 51: \"STYLE_SEPARATOR\", 52: \"left_of\", 53: \"right_of\" },\n productions_: [0, [3, 2], [3, 2], [3, 2], [7, 0], [7, 2], [8, 2], [8, 1], [8, 1], [9, 1], [9, 1], [9, 1], [9, 2], [9, 3], [9, 4], [9, 1], [9, 2], [9, 1], [9, 4], [9, 3], [9, 6], [9, 1], [9, 1], [9, 1], [9, 1], [9, 4], [9, 4], [9, 1], [9, 2], [9, 2], [9, 1], [10, 3], [10, 3], [11, 3], [31, 1], [31, 1], [31, 1], [31, 1], [48, 1], [48, 1], [12, 1], [12, 1], [12, 3], [12, 3], [29, 1], [29, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 3:\n yy.setRootDoc($$[$0]);\n return $$[$0];\n case 4:\n this.$ = [];\n break;\n case 5:\n if ($$[$0] != \"nl\") {\n $$[$0 - 1].push($$[$0]);\n this.$ = $$[$0 - 1];\n }\n break;\n case 6:\n case 7:\n this.$ = $$[$0];\n break;\n case 8:\n this.$ = \"nl\";\n break;\n case 11:\n this.$ = $$[$0];\n break;\n case 12:\n const stateStmt = $$[$0 - 1];\n stateStmt.description = yy.trimColon($$[$0]);\n this.$ = stateStmt;\n break;\n case 13:\n this.$ = { stmt: \"relation\", state1: $$[$0 - 2], state2: $$[$0] };\n break;\n case 14:\n const relDescription = yy.trimColon($$[$0]);\n this.$ = { stmt: \"relation\", state1: $$[$0 - 3], state2: $$[$0 - 1], description: relDescription };\n break;\n case 18:\n this.$ = { stmt: \"state\", id: $$[$0 - 3], type: \"default\", description: \"\", doc: $$[$0 - 1] };\n break;\n case 19:\n var id = $$[$0];\n var description = $$[$0 - 2].trim();\n if ($$[$0].match(\":\")) {\n var parts = $$[$0].split(\":\");\n id = parts[0];\n description = [description, parts[1]];\n }\n this.$ = { stmt: \"state\", id, type: \"default\", description };\n break;\n case 20:\n this.$ = { stmt: \"state\", id: $$[$0 - 3], type: \"default\", description: $$[$0 - 5], doc: $$[$0 - 1] };\n break;\n case 21:\n this.$ = { stmt: \"state\", id: $$[$0], type: \"fork\" };\n break;\n case 22:\n this.$ = { stmt: \"state\", id: $$[$0], type: \"join\" };\n break;\n case 23:\n this.$ = { stmt: \"state\", id: $$[$0], type: \"choice\" };\n break;\n case 24:\n this.$ = { stmt: \"state\", id: yy.getDividerId(), type: \"divider\" };\n break;\n case 25:\n this.$ = { stmt: \"state\", id: $$[$0 - 1].trim(), note: { position: $$[$0 - 2].trim(), text: $$[$0].trim() } };\n break;\n case 28:\n this.$ = $$[$0].trim();\n yy.setAccTitle(this.$);\n break;\n case 29:\n case 30:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 31:\n case 32:\n this.$ = { stmt: \"classDef\", id: $$[$0 - 1].trim(), classes: $$[$0].trim() };\n break;\n case 33:\n this.$ = { stmt: \"applyClass\", id: $$[$0 - 1].trim(), styleClass: $$[$0].trim() };\n break;\n case 34:\n yy.setDirection(\"TB\");\n this.$ = { stmt: \"dir\", value: \"TB\" };\n break;\n case 35:\n yy.setDirection(\"BT\");\n this.$ = { stmt: \"dir\", value: \"BT\" };\n break;\n case 36:\n yy.setDirection(\"RL\");\n this.$ = { stmt: \"dir\", value: \"RL\" };\n break;\n case 37:\n yy.setDirection(\"LR\");\n this.$ = { stmt: \"dir\", value: \"LR\" };\n break;\n case 40:\n case 41:\n this.$ = { stmt: \"state\", id: $$[$0].trim(), type: \"default\", description: \"\" };\n break;\n case 42:\n this.$ = { stmt: \"state\", id: $$[$0 - 2].trim(), classes: [$$[$0].trim()], type: \"default\", description: \"\" };\n break;\n case 43:\n this.$ = { stmt: \"state\", id: $$[$0 - 2].trim(), classes: [$$[$0].trim()], type: \"default\", description: \"\" };\n break;\n }\n },\n table: [{ 3: 1, 4: $V0, 5: $V1, 6: $V2 }, { 1: [3] }, { 3: 5, 4: $V0, 5: $V1, 6: $V2 }, { 3: 6, 4: $V0, 5: $V1, 6: $V2 }, o([1, 4, 5, 15, 16, 18, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50], $V3, { 7: 7 }), { 1: [2, 1] }, { 1: [2, 2] }, { 1: [2, 3], 4: $V4, 5: $V5, 8: 8, 9: 10, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 5]), { 9: 36, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 7]), o($Vq, [2, 8]), o($Vq, [2, 9]), o($Vq, [2, 10]), o($Vq, [2, 11], { 13: [1, 37], 14: [1, 38] }), o($Vq, [2, 15]), { 17: [1, 39] }, o($Vq, [2, 17], { 19: [1, 40] }), { 22: [1, 41] }, o($Vq, [2, 21]), o($Vq, [2, 22]), o($Vq, [2, 23]), o($Vq, [2, 24]), { 29: 42, 30: [1, 43], 52: [1, 44], 53: [1, 45] }, o($Vq, [2, 27]), { 33: [1, 46] }, { 35: [1, 47] }, o($Vq, [2, 30]), { 38: [1, 48], 40: [1, 49] }, { 42: [1, 50] }, o($Vr, [2, 40], { 51: [1, 51] }), o($Vr, [2, 41], { 51: [1, 52] }), o($Vq, [2, 34]), o($Vq, [2, 35]), o($Vq, [2, 36]), o($Vq, [2, 37]), o($Vq, [2, 6]), o($Vq, [2, 12]), { 12: 53, 23: $Va, 50: $Vp }, o($Vq, [2, 16]), o($Vs, $V3, { 7: 54 }), { 23: [1, 55] }, { 23: [1, 56] }, { 22: [1, 57] }, { 23: [2, 44] }, { 23: [2, 45] }, o($Vq, [2, 28]), o($Vq, [2, 29]), { 39: [1, 58] }, { 39: [1, 59] }, { 43: [1, 60] }, { 23: [1, 61] }, { 23: [1, 62] }, o($Vq, [2, 13], { 13: [1, 63] }), { 4: $V4, 5: $V5, 8: 8, 9: 10, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 20: [1, 64], 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 19], { 19: [1, 65] }), { 30: [1, 66] }, { 23: [1, 67] }, o($Vq, [2, 31]), o($Vq, [2, 32]), o($Vq, [2, 33]), o($Vr, [2, 42]), o($Vr, [2, 43]), o($Vq, [2, 14]), o($Vq, [2, 18]), o($Vs, $V3, { 7: 68 }), o($Vq, [2, 25]), o($Vq, [2, 26]), { 4: $V4, 5: $V5, 8: 8, 9: 10, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 20: [1, 69], 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 20])],\n defaultActions: { 5: [2, 1], 6: [2, 2], 44: [2, 44], 45: [2, 45] },\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: { \"case-insensitive\": true },\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n return 40;\n case 1:\n return 44;\n case 2:\n return 45;\n case 3:\n return 46;\n case 4:\n return 47;\n case 5:\n break;\n case 6:\n break;\n case 7:\n return 5;\n case 8:\n break;\n case 9:\n break;\n case 10:\n break;\n case 11:\n break;\n case 12:\n this.pushState(\"SCALE\");\n return 16;\n case 13:\n return 17;\n case 14:\n this.popState();\n break;\n case 15:\n this.begin(\"acc_title\");\n return 32;\n case 16:\n this.popState();\n return \"acc_title_value\";\n case 17:\n this.begin(\"acc_descr\");\n return 34;\n case 18:\n this.popState();\n return \"acc_descr_value\";\n case 19:\n this.begin(\"acc_descr_multiline\");\n break;\n case 20:\n this.popState();\n break;\n case 21:\n return \"acc_descr_multiline_value\";\n case 22:\n this.pushState(\"CLASSDEF\");\n return 37;\n case 23:\n this.popState();\n this.pushState(\"CLASSDEFID\");\n return \"DEFAULT_CLASSDEF_ID\";\n case 24:\n this.popState();\n this.pushState(\"CLASSDEFID\");\n return 38;\n case 25:\n this.popState();\n return 39;\n case 26:\n this.pushState(\"CLASS\");\n return 41;\n case 27:\n this.popState();\n this.pushState(\"CLASS_STYLE\");\n return 42;\n case 28:\n this.popState();\n return 43;\n case 29:\n this.pushState(\"SCALE\");\n return 16;\n case 30:\n return 17;\n case 31:\n this.popState();\n break;\n case 32:\n this.pushState(\"STATE\");\n break;\n case 33:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 24;\n case 34:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 25;\n case 35:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -10).trim();\n return 26;\n case 36:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 24;\n case 37:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 25;\n case 38:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -10).trim();\n return 26;\n case 39:\n return 44;\n case 40:\n return 45;\n case 41:\n return 46;\n case 42:\n return 47;\n case 43:\n this.pushState(\"STATE_STRING\");\n break;\n case 44:\n this.pushState(\"STATE_ID\");\n return \"AS\";\n case 45:\n this.popState();\n return \"ID\";\n case 46:\n this.popState();\n break;\n case 47:\n return \"STATE_DESCR\";\n case 48:\n return 18;\n case 49:\n this.popState();\n break;\n case 50:\n this.popState();\n this.pushState(\"struct\");\n return 19;\n case 51:\n break;\n case 52:\n this.popState();\n return 20;\n case 53:\n break;\n case 54:\n this.begin(\"NOTE\");\n return 28;\n case 55:\n this.popState();\n this.pushState(\"NOTE_ID\");\n return 52;\n case 56:\n this.popState();\n this.pushState(\"NOTE_ID\");\n return 53;\n case 57:\n this.popState();\n this.pushState(\"FLOATING_NOTE\");\n break;\n case 58:\n this.popState();\n this.pushState(\"FLOATING_NOTE_ID\");\n return \"AS\";\n case 59:\n break;\n case 60:\n return \"NOTE_TEXT\";\n case 61:\n this.popState();\n return \"ID\";\n case 62:\n this.popState();\n this.pushState(\"NOTE_TEXT\");\n return 23;\n case 63:\n this.popState();\n yy_.yytext = yy_.yytext.substr(2).trim();\n return 30;\n case 64:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 30;\n case 65:\n return 6;\n case 66:\n return 6;\n case 67:\n return 15;\n case 68:\n return 50;\n case 69:\n return 23;\n case 70:\n yy_.yytext = yy_.yytext.trim();\n return 13;\n case 71:\n return 14;\n case 72:\n return 27;\n case 73:\n return 51;\n case 74:\n return 5;\n case 75:\n return \"INVALID\";\n }\n },\n rules: [/^(?:default\\b)/i, /^(?:.*direction\\s+TB[^\\n]*)/i, /^(?:.*direction\\s+BT[^\\n]*)/i, /^(?:.*direction\\s+RL[^\\n]*)/i, /^(?:.*direction\\s+LR[^\\n]*)/i, /^(?:%%(?!\\{)[^\\n]*)/i, /^(?:[^\\}]%%[^\\n]*)/i, /^(?:[\\n]+)/i, /^(?:[\\s]+)/i, /^(?:((?!\\n)\\s)+)/i, /^(?:#[^\\n]*)/i, /^(?:%[^\\n]*)/i, /^(?:scale\\s+)/i, /^(?:\\d+)/i, /^(?:\\s+width\\b)/i, /^(?:accTitle\\s*:\\s*)/i, /^(?:(?!\\n||)*[^\\n]*)/i, /^(?:accDescr\\s*:\\s*)/i, /^(?:(?!\\n||)*[^\\n]*)/i, /^(?:accDescr\\s*\\{\\s*)/i, /^(?:[\\}])/i, /^(?:[^\\}]*)/i, /^(?:classDef\\s+)/i, /^(?:DEFAULT\\s+)/i, /^(?:\\w+\\s+)/i, /^(?:[^\\n]*)/i, /^(?:class\\s+)/i, /^(?:(\\w+)+((,\\s*\\w+)*))/i, /^(?:[^\\n]*)/i, /^(?:scale\\s+)/i, /^(?:\\d+)/i, /^(?:\\s+width\\b)/i, /^(?:state\\s+)/i, /^(?:.*<>)/i, /^(?:.*<>)/i, /^(?:.*<>)/i, /^(?:.*\\[\\[fork\\]\\])/i, /^(?:.*\\[\\[join\\]\\])/i, /^(?:.*\\[\\[choice\\]\\])/i, /^(?:.*direction\\s+TB[^\\n]*)/i, /^(?:.*direction\\s+BT[^\\n]*)/i, /^(?:.*direction\\s+RL[^\\n]*)/i, /^(?:.*direction\\s+LR[^\\n]*)/i, /^(?:[\"])/i, /^(?:\\s*as\\s+)/i, /^(?:[^\\n\\{]*)/i, /^(?:[\"])/i, /^(?:[^\"]*)/i, /^(?:[^\\n\\s\\{]+)/i, /^(?:\\n)/i, /^(?:\\{)/i, /^(?:%%(?!\\{)[^\\n]*)/i, /^(?:\\})/i, /^(?:[\\n])/i, /^(?:note\\s+)/i, /^(?:left of\\b)/i, /^(?:right of\\b)/i, /^(?:\")/i, /^(?:\\s*as\\s*)/i, /^(?:[\"])/i, /^(?:[^\"]*)/i, /^(?:[^\\n]*)/i, /^(?:\\s*[^:\\n\\s\\-]+)/i, /^(?:\\s*:[^:\\n;]+)/i, /^(?:[\\s\\S]*?end note\\b)/i, /^(?:stateDiagram\\s+)/i, /^(?:stateDiagram-v2\\s+)/i, /^(?:hide empty description\\b)/i, /^(?:\\[\\*\\])/i, /^(?:[^:\\n\\s\\-\\{]+)/i, /^(?:\\s*:[^:\\n;]+)/i, /^(?:-->)/i, /^(?:--)/i, /^(?::::)/i, /^(?:$)/i, /^(?:.)/i],\n conditions: { \"LINE\": { \"rules\": [9, 10], \"inclusive\": false }, \"struct\": { \"rules\": [9, 10, 22, 26, 32, 39, 40, 41, 42, 51, 52, 53, 54, 68, 69, 70, 71, 72], \"inclusive\": false }, \"FLOATING_NOTE_ID\": { \"rules\": [61], \"inclusive\": false }, \"FLOATING_NOTE\": { \"rules\": [58, 59, 60], \"inclusive\": false }, \"NOTE_TEXT\": { \"rules\": [63, 64], \"inclusive\": false }, \"NOTE_ID\": { \"rules\": [62], \"inclusive\": false }, \"NOTE\": { \"rules\": [55, 56, 57], \"inclusive\": false }, \"CLASS_STYLE\": { \"rules\": [28], \"inclusive\": false }, \"CLASS\": { \"rules\": [27], \"inclusive\": false }, \"CLASSDEFID\": { \"rules\": [25], \"inclusive\": false }, \"CLASSDEF\": { \"rules\": [23, 24], \"inclusive\": false }, \"acc_descr_multiline\": { \"rules\": [20, 21], \"inclusive\": false }, \"acc_descr\": { \"rules\": [18], \"inclusive\": false }, \"acc_title\": { \"rules\": [16], \"inclusive\": false }, \"SCALE\": { \"rules\": [13, 14, 30, 31], \"inclusive\": false }, \"ALIAS\": { \"rules\": [], \"inclusive\": false }, \"STATE_ID\": { \"rules\": [45], \"inclusive\": false }, \"STATE_STRING\": { \"rules\": [46, 47], \"inclusive\": false }, \"FORK_STATE\": { \"rules\": [], \"inclusive\": false }, \"STATE\": { \"rules\": [9, 10, 33, 34, 35, 36, 37, 38, 43, 44, 48, 49, 50], \"inclusive\": false }, \"ID\": { \"rules\": [9, 10], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 15, 17, 19, 22, 26, 29, 32, 50, 54, 65, 66, 67, 68, 69, 70, 71, 73, 74, 75], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nconst DEFAULT_DIAGRAM_DIRECTION = \"LR\";\nconst DEFAULT_NESTED_DOC_DIR = \"TB\";\nconst STMT_STATE = \"state\";\nconst STMT_RELATION = \"relation\";\nconst STMT_CLASSDEF = \"classDef\";\nconst STMT_APPLYCLASS = \"applyClass\";\nconst DEFAULT_STATE_TYPE = \"default\";\nconst DIVIDER_TYPE = \"divider\";\nconst START_NODE = \"[*]\";\nconst START_TYPE = \"start\";\nconst END_NODE = START_NODE;\nconst END_TYPE = \"end\";\nconst COLOR_KEYWORD = \"color\";\nconst FILL_KEYWORD = \"fill\";\nconst BG_FILL = \"bgFill\";\nconst STYLECLASS_SEP = \",\";\nfunction newClassesList() {\n return {};\n}\nlet direction = DEFAULT_DIAGRAM_DIRECTION;\nlet rootDoc = [];\nlet classes = newClassesList();\nconst newDoc = () => {\n return {\n relations: [],\n states: {},\n documents: {}\n };\n};\nlet documents = {\n root: newDoc()\n};\nlet currentDocument = documents.root;\nlet startEndCount = 0;\nlet dividerCnt = 0;\nconst lineType = {\n LINE: 0,\n DOTTED_LINE: 1\n};\nconst relationType = {\n AGGREGATION: 0,\n EXTENSION: 1,\n COMPOSITION: 2,\n DEPENDENCY: 3\n};\nconst clone = (o) => JSON.parse(JSON.stringify(o));\nconst setRootDoc = (o) => {\n log.info(\"Setting root doc\", o);\n rootDoc = o;\n};\nconst getRootDoc = () => rootDoc;\nconst docTranslator = (parent, node, first) => {\n if (node.stmt === STMT_RELATION) {\n docTranslator(parent, node.state1, true);\n docTranslator(parent, node.state2, false);\n } else {\n if (node.stmt === STMT_STATE) {\n if (node.id === \"[*]\") {\n node.id = first ? parent.id + \"_start\" : parent.id + \"_end\";\n node.start = first;\n } else {\n node.id = node.id.trim();\n }\n }\n if (node.doc) {\n const doc = [];\n let currentDoc = [];\n let i;\n for (i = 0; i < node.doc.length; i++) {\n if (node.doc[i].type === DIVIDER_TYPE) {\n const newNode = clone(node.doc[i]);\n newNode.doc = clone(currentDoc);\n doc.push(newNode);\n currentDoc = [];\n } else {\n currentDoc.push(node.doc[i]);\n }\n }\n if (doc.length > 0 && currentDoc.length > 0) {\n const newNode = {\n stmt: STMT_STATE,\n id: generateId(),\n type: \"divider\",\n doc: clone(currentDoc)\n };\n doc.push(clone(newNode));\n node.doc = doc;\n }\n node.doc.forEach((docNode) => docTranslator(node, docNode, true));\n }\n }\n};\nconst getRootDocV2 = () => {\n docTranslator({ id: \"root\" }, { id: \"root\", doc: rootDoc }, true);\n return { id: \"root\", doc: rootDoc };\n};\nconst extract = (_doc) => {\n let doc;\n if (_doc.doc) {\n doc = _doc.doc;\n } else {\n doc = _doc;\n }\n log.info(doc);\n clear(true);\n log.info(\"Extract\", doc);\n doc.forEach((item) => {\n switch (item.stmt) {\n case STMT_STATE:\n addState(\n item.id.trim(),\n item.type,\n item.doc,\n item.description,\n item.note,\n item.classes,\n item.styles,\n item.textStyles\n );\n break;\n case STMT_RELATION:\n addRelation(item.state1, item.state2, item.description);\n break;\n case STMT_CLASSDEF:\n addStyleClass(item.id.trim(), item.classes);\n break;\n case STMT_APPLYCLASS:\n setCssClass(item.id.trim(), item.styleClass);\n break;\n }\n });\n};\nconst addState = function(id, type = DEFAULT_STATE_TYPE, doc = null, descr = null, note = null, classes2 = null, styles2 = null, textStyles = null) {\n const trimmedId = id == null ? void 0 : id.trim();\n if (currentDocument.states[trimmedId] === void 0) {\n log.info(\"Adding state \", trimmedId, descr);\n currentDocument.states[trimmedId] = {\n id: trimmedId,\n descriptions: [],\n type,\n doc,\n note,\n classes: [],\n styles: [],\n textStyles: []\n };\n } else {\n if (!currentDocument.states[trimmedId].doc) {\n currentDocument.states[trimmedId].doc = doc;\n }\n if (!currentDocument.states[trimmedId].type) {\n currentDocument.states[trimmedId].type = type;\n }\n }\n if (descr) {\n log.info(\"Setting state description\", trimmedId, descr);\n if (typeof descr === \"string\") {\n addDescription(trimmedId, descr.trim());\n }\n if (typeof descr === \"object\") {\n descr.forEach((des) => addDescription(trimmedId, des.trim()));\n }\n }\n if (note) {\n currentDocument.states[trimmedId].note = note;\n currentDocument.states[trimmedId].note.text = common.sanitizeText(\n currentDocument.states[trimmedId].note.text,\n getConfig()\n );\n }\n if (classes2) {\n log.info(\"Setting state classes\", trimmedId, classes2);\n const classesList = typeof classes2 === \"string\" ? [classes2] : classes2;\n classesList.forEach((klass) => setCssClass(trimmedId, klass.trim()));\n }\n if (styles2) {\n log.info(\"Setting state styles\", trimmedId, styles2);\n const stylesList = typeof styles2 === \"string\" ? [styles2] : styles2;\n stylesList.forEach((style) => setStyle(trimmedId, style.trim()));\n }\n if (textStyles) {\n log.info(\"Setting state styles\", trimmedId, styles2);\n const textStylesList = typeof textStyles === \"string\" ? [textStyles] : textStyles;\n textStylesList.forEach((textStyle) => setTextStyle(trimmedId, textStyle.trim()));\n }\n};\nconst clear = function(saveCommon) {\n documents = {\n root: newDoc()\n };\n currentDocument = documents.root;\n startEndCount = 0;\n classes = newClassesList();\n if (!saveCommon) {\n clear$1();\n }\n};\nconst getState = function(id) {\n return currentDocument.states[id];\n};\nconst getStates = function() {\n return currentDocument.states;\n};\nconst logDocuments = function() {\n log.info(\"Documents = \", documents);\n};\nconst getRelations = function() {\n return currentDocument.relations;\n};\nfunction startIdIfNeeded(id = \"\") {\n let fixedId = id;\n if (id === START_NODE) {\n startEndCount++;\n fixedId = `${START_TYPE}${startEndCount}`;\n }\n return fixedId;\n}\nfunction startTypeIfNeeded(id = \"\", type = DEFAULT_STATE_TYPE) {\n return id === START_NODE ? START_TYPE : type;\n}\nfunction endIdIfNeeded(id = \"\") {\n let fixedId = id;\n if (id === END_NODE) {\n startEndCount++;\n fixedId = `${END_TYPE}${startEndCount}`;\n }\n return fixedId;\n}\nfunction endTypeIfNeeded(id = \"\", type = DEFAULT_STATE_TYPE) {\n return id === END_NODE ? END_TYPE : type;\n}\nfunction addRelationObjs(item1, item2, relationTitle) {\n let id1 = startIdIfNeeded(item1.id.trim());\n let type1 = startTypeIfNeeded(item1.id.trim(), item1.type);\n let id2 = startIdIfNeeded(item2.id.trim());\n let type2 = startTypeIfNeeded(item2.id.trim(), item2.type);\n addState(\n id1,\n type1,\n item1.doc,\n item1.description,\n item1.note,\n item1.classes,\n item1.styles,\n item1.textStyles\n );\n addState(\n id2,\n type2,\n item2.doc,\n item2.description,\n item2.note,\n item2.classes,\n item2.styles,\n item2.textStyles\n );\n currentDocument.relations.push({\n id1,\n id2,\n relationTitle: common.sanitizeText(relationTitle, getConfig())\n });\n}\nconst addRelation = function(item1, item2, title) {\n if (typeof item1 === \"object\") {\n addRelationObjs(item1, item2, title);\n } else {\n const id1 = startIdIfNeeded(item1.trim());\n const type1 = startTypeIfNeeded(item1);\n const id2 = endIdIfNeeded(item2.trim());\n const type2 = endTypeIfNeeded(item2);\n addState(id1, type1);\n addState(id2, type2);\n currentDocument.relations.push({\n id1,\n id2,\n title: common.sanitizeText(title, getConfig())\n });\n }\n};\nconst addDescription = function(id, descr) {\n const theState = currentDocument.states[id];\n const _descr = descr.startsWith(\":\") ? descr.replace(\":\", \"\").trim() : descr;\n theState.descriptions.push(common.sanitizeText(_descr, getConfig()));\n};\nconst cleanupLabel = function(label) {\n if (label.substring(0, 1) === \":\") {\n return label.substr(2).trim();\n } else {\n return label.trim();\n }\n};\nconst getDividerId = () => {\n dividerCnt++;\n return \"divider-id-\" + dividerCnt;\n};\nconst addStyleClass = function(id, styleAttributes = \"\") {\n if (classes[id] === void 0) {\n classes[id] = { id, styles: [], textStyles: [] };\n }\n const foundClass = classes[id];\n if (styleAttributes !== void 0 && styleAttributes !== null) {\n styleAttributes.split(STYLECLASS_SEP).forEach((attrib) => {\n const fixedAttrib = attrib.replace(/([^;]*);/, \"$1\").trim();\n if (attrib.match(COLOR_KEYWORD)) {\n const newStyle1 = fixedAttrib.replace(FILL_KEYWORD, BG_FILL);\n const newStyle2 = newStyle1.replace(COLOR_KEYWORD, FILL_KEYWORD);\n foundClass.textStyles.push(newStyle2);\n }\n foundClass.styles.push(fixedAttrib);\n });\n }\n};\nconst getClasses = function() {\n return classes;\n};\nconst setCssClass = function(itemIds, cssClassName) {\n itemIds.split(\",\").forEach(function(id) {\n let foundState = getState(id);\n if (foundState === void 0) {\n const trimmedId = id.trim();\n addState(trimmedId);\n foundState = getState(trimmedId);\n }\n foundState.classes.push(cssClassName);\n });\n};\nconst setStyle = function(itemId, styleText) {\n const item = getState(itemId);\n if (item !== void 0) {\n item.textStyles.push(styleText);\n }\n};\nconst setTextStyle = function(itemId, cssClassName) {\n const item = getState(itemId);\n if (item !== void 0) {\n item.textStyles.push(cssClassName);\n }\n};\nconst getDirection = () => direction;\nconst setDirection = (dir) => {\n direction = dir;\n};\nconst trimColon = (str) => str && str[0] === \":\" ? str.substr(1).trim() : str.trim();\nconst db = {\n getConfig: () => getConfig().state,\n addState,\n clear,\n getState,\n getStates,\n getRelations,\n getClasses,\n getDirection,\n addRelation,\n getDividerId,\n setDirection,\n cleanupLabel,\n lineType,\n relationType,\n logDocuments,\n getRootDoc,\n setRootDoc,\n getRootDocV2,\n extract,\n trimColon,\n getAccTitle,\n setAccTitle,\n getAccDescription,\n setAccDescription,\n addStyleClass,\n setCssClass,\n addDescription,\n setDiagramTitle,\n getDiagramTitle\n};\nconst getStyles = (options) => `\ndefs #statediagram-barbEnd {\n fill: ${options.transitionColor};\n stroke: ${options.transitionColor};\n }\ng.stateGroup text {\n fill: ${options.nodeBorder};\n stroke: none;\n font-size: 10px;\n}\ng.stateGroup text {\n fill: ${options.textColor};\n stroke: none;\n font-size: 10px;\n\n}\ng.stateGroup .state-title {\n font-weight: bolder;\n fill: ${options.stateLabelColor};\n}\n\ng.stateGroup rect {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n}\n\ng.stateGroup line {\n stroke: ${options.lineColor};\n stroke-width: 1;\n}\n\n.transition {\n stroke: ${options.transitionColor};\n stroke-width: 1;\n fill: none;\n}\n\n.stateGroup .composit {\n fill: ${options.background};\n border-bottom: 1px\n}\n\n.stateGroup .alt-composit {\n fill: #e0e0e0;\n border-bottom: 1px\n}\n\n.state-note {\n stroke: ${options.noteBorderColor};\n fill: ${options.noteBkgColor};\n\n text {\n fill: ${options.noteTextColor};\n stroke: none;\n font-size: 10px;\n }\n}\n\n.stateLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ${options.mainBkg};\n opacity: 0.5;\n}\n\n.edgeLabel .label rect {\n fill: ${options.labelBackgroundColor};\n opacity: 0.5;\n}\n.edgeLabel .label text {\n fill: ${options.transitionLabelColor || options.tertiaryTextColor};\n}\n.label div .edgeLabel {\n color: ${options.transitionLabelColor || options.tertiaryTextColor};\n}\n\n.stateLabel text {\n fill: ${options.stateLabelColor};\n font-size: 10px;\n font-weight: bold;\n}\n\n.node circle.state-start {\n fill: ${options.specialStateColor};\n stroke: ${options.specialStateColor};\n}\n\n.node .fork-join {\n fill: ${options.specialStateColor};\n stroke: ${options.specialStateColor};\n}\n\n.node circle.state-end {\n fill: ${options.innerEndBackground};\n stroke: ${options.background};\n stroke-width: 1.5\n}\n.end-state-inner {\n fill: ${options.compositeBackground || options.background};\n // stroke: ${options.background};\n stroke-width: 1.5\n}\n\n.node rect {\n fill: ${options.stateBkg || options.mainBkg};\n stroke: ${options.stateBorder || options.nodeBorder};\n stroke-width: 1px;\n}\n.node polygon {\n fill: ${options.mainBkg};\n stroke: ${options.stateBorder || options.nodeBorder};;\n stroke-width: 1px;\n}\n#statediagram-barbEnd {\n fill: ${options.lineColor};\n}\n\n.statediagram-cluster rect {\n fill: ${options.compositeTitleBackground};\n stroke: ${options.stateBorder || options.nodeBorder};\n stroke-width: 1px;\n}\n\n.cluster-label, .nodeLabel {\n color: ${options.stateLabelColor};\n}\n\n.statediagram-cluster rect.outer {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state .divider {\n stroke: ${options.stateBorder || options.nodeBorder};\n}\n\n.statediagram-state .title-state {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-cluster.statediagram-cluster .inner {\n fill: ${options.compositeBackground || options.background};\n}\n.statediagram-cluster.statediagram-cluster-alt .inner {\n fill: ${options.altBackground ? options.altBackground : \"#efefef\"};\n}\n\n.statediagram-cluster .inner {\n rx:0;\n ry:0;\n}\n\n.statediagram-state rect.basic {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state rect.divider {\n stroke-dasharray: 10,10;\n fill: ${options.altBackground ? options.altBackground : \"#efefef\"};\n}\n\n.note-edge {\n stroke-dasharray: 5;\n}\n\n.statediagram-note rect {\n fill: ${options.noteBkgColor};\n stroke: ${options.noteBorderColor};\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n.statediagram-note rect {\n fill: ${options.noteBkgColor};\n stroke: ${options.noteBorderColor};\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n\n.statediagram-note text {\n fill: ${options.noteTextColor};\n}\n\n.statediagram-note .nodeLabel {\n color: ${options.noteTextColor};\n}\n.statediagram .edgeLabel {\n color: red; // ${options.noteTextColor};\n}\n\n#dependencyStart, #dependencyEnd {\n fill: ${options.lineColor};\n stroke: ${options.lineColor};\n stroke-width: 1;\n}\n\n.statediagramTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${options.textColor};\n}\n`;\nconst styles = getStyles;\nexport {\n DEFAULT_STATE_TYPE as D,\n STMT_RELATION as S,\n DIVIDER_TYPE as a,\n STMT_STATE as b,\n DEFAULT_NESTED_DOC_DIR as c,\n db as d,\n parser$1 as p,\n styles as s\n};\n"], + "sources": ["../../node_modules/mermaid/dist/styles-bbc3fe3b.js"], + "sourcesContent": ["import { c as getConfig, g as getAccTitle, s as setAccTitle, a as getAccDescription, b as setAccDescription, q as setDiagramTitle, r as getDiagramTitle, l as log, e as common, t as clear$1, G as generateId } from \"./mermaid-934d9bea.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 2], $V1 = [1, 3], $V2 = [1, 4], $V3 = [2, 4], $V4 = [1, 9], $V5 = [1, 11], $V6 = [1, 15], $V7 = [1, 16], $V8 = [1, 17], $V9 = [1, 18], $Va = [1, 30], $Vb = [1, 19], $Vc = [1, 20], $Vd = [1, 21], $Ve = [1, 22], $Vf = [1, 23], $Vg = [1, 25], $Vh = [1, 26], $Vi = [1, 27], $Vj = [1, 28], $Vk = [1, 29], $Vl = [1, 32], $Vm = [1, 33], $Vn = [1, 34], $Vo = [1, 35], $Vp = [1, 31], $Vq = [1, 4, 5, 15, 16, 18, 20, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50], $Vr = [1, 4, 5, 13, 14, 15, 16, 18, 20, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50], $Vs = [4, 5, 15, 16, 18, 20, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"SPACE\": 4, \"NL\": 5, \"SD\": 6, \"document\": 7, \"line\": 8, \"statement\": 9, \"classDefStatement\": 10, \"cssClassStatement\": 11, \"idStatement\": 12, \"DESCR\": 13, \"-->\": 14, \"HIDE_EMPTY\": 15, \"scale\": 16, \"WIDTH\": 17, \"COMPOSIT_STATE\": 18, \"STRUCT_START\": 19, \"STRUCT_STOP\": 20, \"STATE_DESCR\": 21, \"AS\": 22, \"ID\": 23, \"FORK\": 24, \"JOIN\": 25, \"CHOICE\": 26, \"CONCURRENT\": 27, \"note\": 28, \"notePosition\": 29, \"NOTE_TEXT\": 30, \"direction\": 31, \"acc_title\": 32, \"acc_title_value\": 33, \"acc_descr\": 34, \"acc_descr_value\": 35, \"acc_descr_multiline_value\": 36, \"classDef\": 37, \"CLASSDEF_ID\": 38, \"CLASSDEF_STYLEOPTS\": 39, \"DEFAULT\": 40, \"class\": 41, \"CLASSENTITY_IDS\": 42, \"STYLECLASS\": 43, \"direction_tb\": 44, \"direction_bt\": 45, \"direction_rl\": 46, \"direction_lr\": 47, \"eol\": 48, \";\": 49, \"EDGE_STATE\": 50, \"STYLE_SEPARATOR\": 51, \"left_of\": 52, \"right_of\": 53, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 4: \"SPACE\", 5: \"NL\", 6: \"SD\", 13: \"DESCR\", 14: \"-->\", 15: \"HIDE_EMPTY\", 16: \"scale\", 17: \"WIDTH\", 18: \"COMPOSIT_STATE\", 19: \"STRUCT_START\", 20: \"STRUCT_STOP\", 21: \"STATE_DESCR\", 22: \"AS\", 23: \"ID\", 24: \"FORK\", 25: \"JOIN\", 26: \"CHOICE\", 27: \"CONCURRENT\", 28: \"note\", 30: \"NOTE_TEXT\", 32: \"acc_title\", 33: \"acc_title_value\", 34: \"acc_descr\", 35: \"acc_descr_value\", 36: \"acc_descr_multiline_value\", 37: \"classDef\", 38: \"CLASSDEF_ID\", 39: \"CLASSDEF_STYLEOPTS\", 40: \"DEFAULT\", 41: \"class\", 42: \"CLASSENTITY_IDS\", 43: \"STYLECLASS\", 44: \"direction_tb\", 45: \"direction_bt\", 46: \"direction_rl\", 47: \"direction_lr\", 49: \";\", 50: \"EDGE_STATE\", 51: \"STYLE_SEPARATOR\", 52: \"left_of\", 53: \"right_of\" },\n productions_: [0, [3, 2], [3, 2], [3, 2], [7, 0], [7, 2], [8, 2], [8, 1], [8, 1], [9, 1], [9, 1], [9, 1], [9, 2], [9, 3], [9, 4], [9, 1], [9, 2], [9, 1], [9, 4], [9, 3], [9, 6], [9, 1], [9, 1], [9, 1], [9, 1], [9, 4], [9, 4], [9, 1], [9, 2], [9, 2], [9, 1], [10, 3], [10, 3], [11, 3], [31, 1], [31, 1], [31, 1], [31, 1], [48, 1], [48, 1], [12, 1], [12, 1], [12, 3], [12, 3], [29, 1], [29, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 3:\n yy.setRootDoc($$[$0]);\n return $$[$0];\n case 4:\n this.$ = [];\n break;\n case 5:\n if ($$[$0] != \"nl\") {\n $$[$0 - 1].push($$[$0]);\n this.$ = $$[$0 - 1];\n }\n break;\n case 6:\n case 7:\n this.$ = $$[$0];\n break;\n case 8:\n this.$ = \"nl\";\n break;\n case 11:\n this.$ = $$[$0];\n break;\n case 12:\n const stateStmt = $$[$0 - 1];\n stateStmt.description = yy.trimColon($$[$0]);\n this.$ = stateStmt;\n break;\n case 13:\n this.$ = { stmt: \"relation\", state1: $$[$0 - 2], state2: $$[$0] };\n break;\n case 14:\n const relDescription = yy.trimColon($$[$0]);\n this.$ = { stmt: \"relation\", state1: $$[$0 - 3], state2: $$[$0 - 1], description: relDescription };\n break;\n case 18:\n this.$ = { stmt: \"state\", id: $$[$0 - 3], type: \"default\", description: \"\", doc: $$[$0 - 1] };\n break;\n case 19:\n var id = $$[$0];\n var description = $$[$0 - 2].trim();\n if ($$[$0].match(\":\")) {\n var parts = $$[$0].split(\":\");\n id = parts[0];\n description = [description, parts[1]];\n }\n this.$ = { stmt: \"state\", id, type: \"default\", description };\n break;\n case 20:\n this.$ = { stmt: \"state\", id: $$[$0 - 3], type: \"default\", description: $$[$0 - 5], doc: $$[$0 - 1] };\n break;\n case 21:\n this.$ = { stmt: \"state\", id: $$[$0], type: \"fork\" };\n break;\n case 22:\n this.$ = { stmt: \"state\", id: $$[$0], type: \"join\" };\n break;\n case 23:\n this.$ = { stmt: \"state\", id: $$[$0], type: \"choice\" };\n break;\n case 24:\n this.$ = { stmt: \"state\", id: yy.getDividerId(), type: \"divider\" };\n break;\n case 25:\n this.$ = { stmt: \"state\", id: $$[$0 - 1].trim(), note: { position: $$[$0 - 2].trim(), text: $$[$0].trim() } };\n break;\n case 28:\n this.$ = $$[$0].trim();\n yy.setAccTitle(this.$);\n break;\n case 29:\n case 30:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 31:\n case 32:\n this.$ = { stmt: \"classDef\", id: $$[$0 - 1].trim(), classes: $$[$0].trim() };\n break;\n case 33:\n this.$ = { stmt: \"applyClass\", id: $$[$0 - 1].trim(), styleClass: $$[$0].trim() };\n break;\n case 34:\n yy.setDirection(\"TB\");\n this.$ = { stmt: \"dir\", value: \"TB\" };\n break;\n case 35:\n yy.setDirection(\"BT\");\n this.$ = { stmt: \"dir\", value: \"BT\" };\n break;\n case 36:\n yy.setDirection(\"RL\");\n this.$ = { stmt: \"dir\", value: \"RL\" };\n break;\n case 37:\n yy.setDirection(\"LR\");\n this.$ = { stmt: \"dir\", value: \"LR\" };\n break;\n case 40:\n case 41:\n this.$ = { stmt: \"state\", id: $$[$0].trim(), type: \"default\", description: \"\" };\n break;\n case 42:\n this.$ = { stmt: \"state\", id: $$[$0 - 2].trim(), classes: [$$[$0].trim()], type: \"default\", description: \"\" };\n break;\n case 43:\n this.$ = { stmt: \"state\", id: $$[$0 - 2].trim(), classes: [$$[$0].trim()], type: \"default\", description: \"\" };\n break;\n }\n },\n table: [{ 3: 1, 4: $V0, 5: $V1, 6: $V2 }, { 1: [3] }, { 3: 5, 4: $V0, 5: $V1, 6: $V2 }, { 3: 6, 4: $V0, 5: $V1, 6: $V2 }, o([1, 4, 5, 15, 16, 18, 21, 23, 24, 25, 26, 27, 28, 32, 34, 36, 37, 41, 44, 45, 46, 47, 50], $V3, { 7: 7 }), { 1: [2, 1] }, { 1: [2, 2] }, { 1: [2, 3], 4: $V4, 5: $V5, 8: 8, 9: 10, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 5]), { 9: 36, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 7]), o($Vq, [2, 8]), o($Vq, [2, 9]), o($Vq, [2, 10]), o($Vq, [2, 11], { 13: [1, 37], 14: [1, 38] }), o($Vq, [2, 15]), { 17: [1, 39] }, o($Vq, [2, 17], { 19: [1, 40] }), { 22: [1, 41] }, o($Vq, [2, 21]), o($Vq, [2, 22]), o($Vq, [2, 23]), o($Vq, [2, 24]), { 29: 42, 30: [1, 43], 52: [1, 44], 53: [1, 45] }, o($Vq, [2, 27]), { 33: [1, 46] }, { 35: [1, 47] }, o($Vq, [2, 30]), { 38: [1, 48], 40: [1, 49] }, { 42: [1, 50] }, o($Vr, [2, 40], { 51: [1, 51] }), o($Vr, [2, 41], { 51: [1, 52] }), o($Vq, [2, 34]), o($Vq, [2, 35]), o($Vq, [2, 36]), o($Vq, [2, 37]), o($Vq, [2, 6]), o($Vq, [2, 12]), { 12: 53, 23: $Va, 50: $Vp }, o($Vq, [2, 16]), o($Vs, $V3, { 7: 54 }), { 23: [1, 55] }, { 23: [1, 56] }, { 22: [1, 57] }, { 23: [2, 44] }, { 23: [2, 45] }, o($Vq, [2, 28]), o($Vq, [2, 29]), { 39: [1, 58] }, { 39: [1, 59] }, { 43: [1, 60] }, { 23: [1, 61] }, { 23: [1, 62] }, o($Vq, [2, 13], { 13: [1, 63] }), { 4: $V4, 5: $V5, 8: 8, 9: 10, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 20: [1, 64], 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 19], { 19: [1, 65] }), { 30: [1, 66] }, { 23: [1, 67] }, o($Vq, [2, 31]), o($Vq, [2, 32]), o($Vq, [2, 33]), o($Vr, [2, 42]), o($Vr, [2, 43]), o($Vq, [2, 14]), o($Vq, [2, 18]), o($Vs, $V3, { 7: 68 }), o($Vq, [2, 25]), o($Vq, [2, 26]), { 4: $V4, 5: $V5, 8: 8, 9: 10, 10: 12, 11: 13, 12: 14, 15: $V6, 16: $V7, 18: $V8, 20: [1, 69], 21: $V9, 23: $Va, 24: $Vb, 25: $Vc, 26: $Vd, 27: $Ve, 28: $Vf, 31: 24, 32: $Vg, 34: $Vh, 36: $Vi, 37: $Vj, 41: $Vk, 44: $Vl, 45: $Vm, 46: $Vn, 47: $Vo, 50: $Vp }, o($Vq, [2, 20])],\n defaultActions: { 5: [2, 1], 6: [2, 2], 44: [2, 44], 45: [2, 45] },\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: { \"case-insensitive\": true },\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n return 40;\n case 1:\n return 44;\n case 2:\n return 45;\n case 3:\n return 46;\n case 4:\n return 47;\n case 5:\n break;\n case 6:\n break;\n case 7:\n return 5;\n case 8:\n break;\n case 9:\n break;\n case 10:\n break;\n case 11:\n break;\n case 12:\n this.pushState(\"SCALE\");\n return 16;\n case 13:\n return 17;\n case 14:\n this.popState();\n break;\n case 15:\n this.begin(\"acc_title\");\n return 32;\n case 16:\n this.popState();\n return \"acc_title_value\";\n case 17:\n this.begin(\"acc_descr\");\n return 34;\n case 18:\n this.popState();\n return \"acc_descr_value\";\n case 19:\n this.begin(\"acc_descr_multiline\");\n break;\n case 20:\n this.popState();\n break;\n case 21:\n return \"acc_descr_multiline_value\";\n case 22:\n this.pushState(\"CLASSDEF\");\n return 37;\n case 23:\n this.popState();\n this.pushState(\"CLASSDEFID\");\n return \"DEFAULT_CLASSDEF_ID\";\n case 24:\n this.popState();\n this.pushState(\"CLASSDEFID\");\n return 38;\n case 25:\n this.popState();\n return 39;\n case 26:\n this.pushState(\"CLASS\");\n return 41;\n case 27:\n this.popState();\n this.pushState(\"CLASS_STYLE\");\n return 42;\n case 28:\n this.popState();\n return 43;\n case 29:\n this.pushState(\"SCALE\");\n return 16;\n case 30:\n return 17;\n case 31:\n this.popState();\n break;\n case 32:\n this.pushState(\"STATE\");\n break;\n case 33:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 24;\n case 34:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 25;\n case 35:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -10).trim();\n return 26;\n case 36:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 24;\n case 37:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 25;\n case 38:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -10).trim();\n return 26;\n case 39:\n return 44;\n case 40:\n return 45;\n case 41:\n return 46;\n case 42:\n return 47;\n case 43:\n this.pushState(\"STATE_STRING\");\n break;\n case 44:\n this.pushState(\"STATE_ID\");\n return \"AS\";\n case 45:\n this.popState();\n return \"ID\";\n case 46:\n this.popState();\n break;\n case 47:\n return \"STATE_DESCR\";\n case 48:\n return 18;\n case 49:\n this.popState();\n break;\n case 50:\n this.popState();\n this.pushState(\"struct\");\n return 19;\n case 51:\n break;\n case 52:\n this.popState();\n return 20;\n case 53:\n break;\n case 54:\n this.begin(\"NOTE\");\n return 28;\n case 55:\n this.popState();\n this.pushState(\"NOTE_ID\");\n return 52;\n case 56:\n this.popState();\n this.pushState(\"NOTE_ID\");\n return 53;\n case 57:\n this.popState();\n this.pushState(\"FLOATING_NOTE\");\n break;\n case 58:\n this.popState();\n this.pushState(\"FLOATING_NOTE_ID\");\n return \"AS\";\n case 59:\n break;\n case 60:\n return \"NOTE_TEXT\";\n case 61:\n this.popState();\n return \"ID\";\n case 62:\n this.popState();\n this.pushState(\"NOTE_TEXT\");\n return 23;\n case 63:\n this.popState();\n yy_.yytext = yy_.yytext.substr(2).trim();\n return 30;\n case 64:\n this.popState();\n yy_.yytext = yy_.yytext.slice(0, -8).trim();\n return 30;\n case 65:\n return 6;\n case 66:\n return 6;\n case 67:\n return 15;\n case 68:\n return 50;\n case 69:\n return 23;\n case 70:\n yy_.yytext = yy_.yytext.trim();\n return 13;\n case 71:\n return 14;\n case 72:\n return 27;\n case 73:\n return 51;\n case 74:\n return 5;\n case 75:\n return \"INVALID\";\n }\n },\n rules: [/^(?:default\\b)/i, /^(?:.*direction\\s+TB[^\\n]*)/i, /^(?:.*direction\\s+BT[^\\n]*)/i, /^(?:.*direction\\s+RL[^\\n]*)/i, /^(?:.*direction\\s+LR[^\\n]*)/i, /^(?:%%(?!\\{)[^\\n]*)/i, /^(?:[^\\}]%%[^\\n]*)/i, /^(?:[\\n]+)/i, /^(?:[\\s]+)/i, /^(?:((?!\\n)\\s)+)/i, /^(?:#[^\\n]*)/i, /^(?:%[^\\n]*)/i, /^(?:scale\\s+)/i, /^(?:\\d+)/i, /^(?:\\s+width\\b)/i, /^(?:accTitle\\s*:\\s*)/i, /^(?:(?!\\n||)*[^\\n]*)/i, /^(?:accDescr\\s*:\\s*)/i, /^(?:(?!\\n||)*[^\\n]*)/i, /^(?:accDescr\\s*\\{\\s*)/i, /^(?:[\\}])/i, /^(?:[^\\}]*)/i, /^(?:classDef\\s+)/i, /^(?:DEFAULT\\s+)/i, /^(?:\\w+\\s+)/i, /^(?:[^\\n]*)/i, /^(?:class\\s+)/i, /^(?:(\\w+)+((,\\s*\\w+)*))/i, /^(?:[^\\n]*)/i, /^(?:scale\\s+)/i, /^(?:\\d+)/i, /^(?:\\s+width\\b)/i, /^(?:state\\s+)/i, /^(?:.*<>)/i, /^(?:.*<>)/i, /^(?:.*<>)/i, /^(?:.*\\[\\[fork\\]\\])/i, /^(?:.*\\[\\[join\\]\\])/i, /^(?:.*\\[\\[choice\\]\\])/i, /^(?:.*direction\\s+TB[^\\n]*)/i, /^(?:.*direction\\s+BT[^\\n]*)/i, /^(?:.*direction\\s+RL[^\\n]*)/i, /^(?:.*direction\\s+LR[^\\n]*)/i, /^(?:[\"])/i, /^(?:\\s*as\\s+)/i, /^(?:[^\\n\\{]*)/i, /^(?:[\"])/i, /^(?:[^\"]*)/i, /^(?:[^\\n\\s\\{]+)/i, /^(?:\\n)/i, /^(?:\\{)/i, /^(?:%%(?!\\{)[^\\n]*)/i, /^(?:\\})/i, /^(?:[\\n])/i, /^(?:note\\s+)/i, /^(?:left of\\b)/i, /^(?:right of\\b)/i, /^(?:\")/i, /^(?:\\s*as\\s*)/i, /^(?:[\"])/i, /^(?:[^\"]*)/i, /^(?:[^\\n]*)/i, /^(?:\\s*[^:\\n\\s\\-]+)/i, /^(?:\\s*:[^:\\n;]+)/i, /^(?:[\\s\\S]*?end note\\b)/i, /^(?:stateDiagram\\s+)/i, /^(?:stateDiagram-v2\\s+)/i, /^(?:hide empty description\\b)/i, /^(?:\\[\\*\\])/i, /^(?:[^:\\n\\s\\-\\{]+)/i, /^(?:\\s*:[^:\\n;]+)/i, /^(?:-->)/i, /^(?:--)/i, /^(?::::)/i, /^(?:$)/i, /^(?:.)/i],\n conditions: { \"LINE\": { \"rules\": [9, 10], \"inclusive\": false }, \"struct\": { \"rules\": [9, 10, 22, 26, 32, 39, 40, 41, 42, 51, 52, 53, 54, 68, 69, 70, 71, 72], \"inclusive\": false }, \"FLOATING_NOTE_ID\": { \"rules\": [61], \"inclusive\": false }, \"FLOATING_NOTE\": { \"rules\": [58, 59, 60], \"inclusive\": false }, \"NOTE_TEXT\": { \"rules\": [63, 64], \"inclusive\": false }, \"NOTE_ID\": { \"rules\": [62], \"inclusive\": false }, \"NOTE\": { \"rules\": [55, 56, 57], \"inclusive\": false }, \"CLASS_STYLE\": { \"rules\": [28], \"inclusive\": false }, \"CLASS\": { \"rules\": [27], \"inclusive\": false }, \"CLASSDEFID\": { \"rules\": [25], \"inclusive\": false }, \"CLASSDEF\": { \"rules\": [23, 24], \"inclusive\": false }, \"acc_descr_multiline\": { \"rules\": [20, 21], \"inclusive\": false }, \"acc_descr\": { \"rules\": [18], \"inclusive\": false }, \"acc_title\": { \"rules\": [16], \"inclusive\": false }, \"SCALE\": { \"rules\": [13, 14, 30, 31], \"inclusive\": false }, \"ALIAS\": { \"rules\": [], \"inclusive\": false }, \"STATE_ID\": { \"rules\": [45], \"inclusive\": false }, \"STATE_STRING\": { \"rules\": [46, 47], \"inclusive\": false }, \"FORK_STATE\": { \"rules\": [], \"inclusive\": false }, \"STATE\": { \"rules\": [9, 10, 33, 34, 35, 36, 37, 38, 43, 44, 48, 49, 50], \"inclusive\": false }, \"ID\": { \"rules\": [9, 10], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 15, 17, 19, 22, 26, 29, 32, 50, 54, 65, 66, 67, 68, 69, 70, 71, 73, 74, 75], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nconst DEFAULT_DIAGRAM_DIRECTION = \"LR\";\nconst DEFAULT_NESTED_DOC_DIR = \"TB\";\nconst STMT_STATE = \"state\";\nconst STMT_RELATION = \"relation\";\nconst STMT_CLASSDEF = \"classDef\";\nconst STMT_APPLYCLASS = \"applyClass\";\nconst DEFAULT_STATE_TYPE = \"default\";\nconst DIVIDER_TYPE = \"divider\";\nconst START_NODE = \"[*]\";\nconst START_TYPE = \"start\";\nconst END_NODE = START_NODE;\nconst END_TYPE = \"end\";\nconst COLOR_KEYWORD = \"color\";\nconst FILL_KEYWORD = \"fill\";\nconst BG_FILL = \"bgFill\";\nconst STYLECLASS_SEP = \",\";\nfunction newClassesList() {\n return {};\n}\nlet direction = DEFAULT_DIAGRAM_DIRECTION;\nlet rootDoc = [];\nlet classes = newClassesList();\nconst newDoc = () => {\n return {\n relations: [],\n states: {},\n documents: {}\n };\n};\nlet documents = {\n root: newDoc()\n};\nlet currentDocument = documents.root;\nlet startEndCount = 0;\nlet dividerCnt = 0;\nconst lineType = {\n LINE: 0,\n DOTTED_LINE: 1\n};\nconst relationType = {\n AGGREGATION: 0,\n EXTENSION: 1,\n COMPOSITION: 2,\n DEPENDENCY: 3\n};\nconst clone = (o) => JSON.parse(JSON.stringify(o));\nconst setRootDoc = (o) => {\n log.info(\"Setting root doc\", o);\n rootDoc = o;\n};\nconst getRootDoc = () => rootDoc;\nconst docTranslator = (parent, node, first) => {\n if (node.stmt === STMT_RELATION) {\n docTranslator(parent, node.state1, true);\n docTranslator(parent, node.state2, false);\n } else {\n if (node.stmt === STMT_STATE) {\n if (node.id === \"[*]\") {\n node.id = first ? parent.id + \"_start\" : parent.id + \"_end\";\n node.start = first;\n } else {\n node.id = node.id.trim();\n }\n }\n if (node.doc) {\n const doc = [];\n let currentDoc = [];\n let i;\n for (i = 0; i < node.doc.length; i++) {\n if (node.doc[i].type === DIVIDER_TYPE) {\n const newNode = clone(node.doc[i]);\n newNode.doc = clone(currentDoc);\n doc.push(newNode);\n currentDoc = [];\n } else {\n currentDoc.push(node.doc[i]);\n }\n }\n if (doc.length > 0 && currentDoc.length > 0) {\n const newNode = {\n stmt: STMT_STATE,\n id: generateId(),\n type: \"divider\",\n doc: clone(currentDoc)\n };\n doc.push(clone(newNode));\n node.doc = doc;\n }\n node.doc.forEach((docNode) => docTranslator(node, docNode, true));\n }\n }\n};\nconst getRootDocV2 = () => {\n docTranslator({ id: \"root\" }, { id: \"root\", doc: rootDoc }, true);\n return { id: \"root\", doc: rootDoc };\n};\nconst extract = (_doc) => {\n let doc;\n if (_doc.doc) {\n doc = _doc.doc;\n } else {\n doc = _doc;\n }\n log.info(doc);\n clear(true);\n log.info(\"Extract\", doc);\n doc.forEach((item) => {\n switch (item.stmt) {\n case STMT_STATE:\n addState(\n item.id.trim(),\n item.type,\n item.doc,\n item.description,\n item.note,\n item.classes,\n item.styles,\n item.textStyles\n );\n break;\n case STMT_RELATION:\n addRelation(item.state1, item.state2, item.description);\n break;\n case STMT_CLASSDEF:\n addStyleClass(item.id.trim(), item.classes);\n break;\n case STMT_APPLYCLASS:\n setCssClass(item.id.trim(), item.styleClass);\n break;\n }\n });\n};\nconst addState = function(id, type = DEFAULT_STATE_TYPE, doc = null, descr = null, note = null, classes2 = null, styles2 = null, textStyles = null) {\n const trimmedId = id == null ? void 0 : id.trim();\n if (currentDocument.states[trimmedId] === void 0) {\n log.info(\"Adding state \", trimmedId, descr);\n currentDocument.states[trimmedId] = {\n id: trimmedId,\n descriptions: [],\n type,\n doc,\n note,\n classes: [],\n styles: [],\n textStyles: []\n };\n } else {\n if (!currentDocument.states[trimmedId].doc) {\n currentDocument.states[trimmedId].doc = doc;\n }\n if (!currentDocument.states[trimmedId].type) {\n currentDocument.states[trimmedId].type = type;\n }\n }\n if (descr) {\n log.info(\"Setting state description\", trimmedId, descr);\n if (typeof descr === \"string\") {\n addDescription(trimmedId, descr.trim());\n }\n if (typeof descr === \"object\") {\n descr.forEach((des) => addDescription(trimmedId, des.trim()));\n }\n }\n if (note) {\n currentDocument.states[trimmedId].note = note;\n currentDocument.states[trimmedId].note.text = common.sanitizeText(\n currentDocument.states[trimmedId].note.text,\n getConfig()\n );\n }\n if (classes2) {\n log.info(\"Setting state classes\", trimmedId, classes2);\n const classesList = typeof classes2 === \"string\" ? [classes2] : classes2;\n classesList.forEach((klass) => setCssClass(trimmedId, klass.trim()));\n }\n if (styles2) {\n log.info(\"Setting state styles\", trimmedId, styles2);\n const stylesList = typeof styles2 === \"string\" ? [styles2] : styles2;\n stylesList.forEach((style) => setStyle(trimmedId, style.trim()));\n }\n if (textStyles) {\n log.info(\"Setting state styles\", trimmedId, styles2);\n const textStylesList = typeof textStyles === \"string\" ? [textStyles] : textStyles;\n textStylesList.forEach((textStyle) => setTextStyle(trimmedId, textStyle.trim()));\n }\n};\nconst clear = function(saveCommon) {\n documents = {\n root: newDoc()\n };\n currentDocument = documents.root;\n startEndCount = 0;\n classes = newClassesList();\n if (!saveCommon) {\n clear$1();\n }\n};\nconst getState = function(id) {\n return currentDocument.states[id];\n};\nconst getStates = function() {\n return currentDocument.states;\n};\nconst logDocuments = function() {\n log.info(\"Documents = \", documents);\n};\nconst getRelations = function() {\n return currentDocument.relations;\n};\nfunction startIdIfNeeded(id = \"\") {\n let fixedId = id;\n if (id === START_NODE) {\n startEndCount++;\n fixedId = `${START_TYPE}${startEndCount}`;\n }\n return fixedId;\n}\nfunction startTypeIfNeeded(id = \"\", type = DEFAULT_STATE_TYPE) {\n return id === START_NODE ? START_TYPE : type;\n}\nfunction endIdIfNeeded(id = \"\") {\n let fixedId = id;\n if (id === END_NODE) {\n startEndCount++;\n fixedId = `${END_TYPE}${startEndCount}`;\n }\n return fixedId;\n}\nfunction endTypeIfNeeded(id = \"\", type = DEFAULT_STATE_TYPE) {\n return id === END_NODE ? END_TYPE : type;\n}\nfunction addRelationObjs(item1, item2, relationTitle) {\n let id1 = startIdIfNeeded(item1.id.trim());\n let type1 = startTypeIfNeeded(item1.id.trim(), item1.type);\n let id2 = startIdIfNeeded(item2.id.trim());\n let type2 = startTypeIfNeeded(item2.id.trim(), item2.type);\n addState(\n id1,\n type1,\n item1.doc,\n item1.description,\n item1.note,\n item1.classes,\n item1.styles,\n item1.textStyles\n );\n addState(\n id2,\n type2,\n item2.doc,\n item2.description,\n item2.note,\n item2.classes,\n item2.styles,\n item2.textStyles\n );\n currentDocument.relations.push({\n id1,\n id2,\n relationTitle: common.sanitizeText(relationTitle, getConfig())\n });\n}\nconst addRelation = function(item1, item2, title) {\n if (typeof item1 === \"object\") {\n addRelationObjs(item1, item2, title);\n } else {\n const id1 = startIdIfNeeded(item1.trim());\n const type1 = startTypeIfNeeded(item1);\n const id2 = endIdIfNeeded(item2.trim());\n const type2 = endTypeIfNeeded(item2);\n addState(id1, type1);\n addState(id2, type2);\n currentDocument.relations.push({\n id1,\n id2,\n title: common.sanitizeText(title, getConfig())\n });\n }\n};\nconst addDescription = function(id, descr) {\n const theState = currentDocument.states[id];\n const _descr = descr.startsWith(\":\") ? descr.replace(\":\", \"\").trim() : descr;\n theState.descriptions.push(common.sanitizeText(_descr, getConfig()));\n};\nconst cleanupLabel = function(label) {\n if (label.substring(0, 1) === \":\") {\n return label.substr(2).trim();\n } else {\n return label.trim();\n }\n};\nconst getDividerId = () => {\n dividerCnt++;\n return \"divider-id-\" + dividerCnt;\n};\nconst addStyleClass = function(id, styleAttributes = \"\") {\n if (classes[id] === void 0) {\n classes[id] = { id, styles: [], textStyles: [] };\n }\n const foundClass = classes[id];\n if (styleAttributes !== void 0 && styleAttributes !== null) {\n styleAttributes.split(STYLECLASS_SEP).forEach((attrib) => {\n const fixedAttrib = attrib.replace(/([^;]*);/, \"$1\").trim();\n if (attrib.match(COLOR_KEYWORD)) {\n const newStyle1 = fixedAttrib.replace(FILL_KEYWORD, BG_FILL);\n const newStyle2 = newStyle1.replace(COLOR_KEYWORD, FILL_KEYWORD);\n foundClass.textStyles.push(newStyle2);\n }\n foundClass.styles.push(fixedAttrib);\n });\n }\n};\nconst getClasses = function() {\n return classes;\n};\nconst setCssClass = function(itemIds, cssClassName) {\n itemIds.split(\",\").forEach(function(id) {\n let foundState = getState(id);\n if (foundState === void 0) {\n const trimmedId = id.trim();\n addState(trimmedId);\n foundState = getState(trimmedId);\n }\n foundState.classes.push(cssClassName);\n });\n};\nconst setStyle = function(itemId, styleText) {\n const item = getState(itemId);\n if (item !== void 0) {\n item.textStyles.push(styleText);\n }\n};\nconst setTextStyle = function(itemId, cssClassName) {\n const item = getState(itemId);\n if (item !== void 0) {\n item.textStyles.push(cssClassName);\n }\n};\nconst getDirection = () => direction;\nconst setDirection = (dir) => {\n direction = dir;\n};\nconst trimColon = (str) => str && str[0] === \":\" ? str.substr(1).trim() : str.trim();\nconst db = {\n getConfig: () => getConfig().state,\n addState,\n clear,\n getState,\n getStates,\n getRelations,\n getClasses,\n getDirection,\n addRelation,\n getDividerId,\n setDirection,\n cleanupLabel,\n lineType,\n relationType,\n logDocuments,\n getRootDoc,\n setRootDoc,\n getRootDocV2,\n extract,\n trimColon,\n getAccTitle,\n setAccTitle,\n getAccDescription,\n setAccDescription,\n addStyleClass,\n setCssClass,\n addDescription,\n setDiagramTitle,\n getDiagramTitle\n};\nconst getStyles = (options) => `\ndefs #statediagram-barbEnd {\n fill: ${options.transitionColor};\n stroke: ${options.transitionColor};\n }\ng.stateGroup text {\n fill: ${options.nodeBorder};\n stroke: none;\n font-size: 10px;\n}\ng.stateGroup text {\n fill: ${options.textColor};\n stroke: none;\n font-size: 10px;\n\n}\ng.stateGroup .state-title {\n font-weight: bolder;\n fill: ${options.stateLabelColor};\n}\n\ng.stateGroup rect {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n}\n\ng.stateGroup line {\n stroke: ${options.lineColor};\n stroke-width: 1;\n}\n\n.transition {\n stroke: ${options.transitionColor};\n stroke-width: 1;\n fill: none;\n}\n\n.stateGroup .composit {\n fill: ${options.background};\n border-bottom: 1px\n}\n\n.stateGroup .alt-composit {\n fill: #e0e0e0;\n border-bottom: 1px\n}\n\n.state-note {\n stroke: ${options.noteBorderColor};\n fill: ${options.noteBkgColor};\n\n text {\n fill: ${options.noteTextColor};\n stroke: none;\n font-size: 10px;\n }\n}\n\n.stateLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ${options.mainBkg};\n opacity: 0.5;\n}\n\n.edgeLabel .label rect {\n fill: ${options.labelBackgroundColor};\n opacity: 0.5;\n}\n.edgeLabel .label text {\n fill: ${options.transitionLabelColor || options.tertiaryTextColor};\n}\n.label div .edgeLabel {\n color: ${options.transitionLabelColor || options.tertiaryTextColor};\n}\n\n.stateLabel text {\n fill: ${options.stateLabelColor};\n font-size: 10px;\n font-weight: bold;\n}\n\n.node circle.state-start {\n fill: ${options.specialStateColor};\n stroke: ${options.specialStateColor};\n}\n\n.node .fork-join {\n fill: ${options.specialStateColor};\n stroke: ${options.specialStateColor};\n}\n\n.node circle.state-end {\n fill: ${options.innerEndBackground};\n stroke: ${options.background};\n stroke-width: 1.5\n}\n.end-state-inner {\n fill: ${options.compositeBackground || options.background};\n // stroke: ${options.background};\n stroke-width: 1.5\n}\n\n.node rect {\n fill: ${options.stateBkg || options.mainBkg};\n stroke: ${options.stateBorder || options.nodeBorder};\n stroke-width: 1px;\n}\n.node polygon {\n fill: ${options.mainBkg};\n stroke: ${options.stateBorder || options.nodeBorder};;\n stroke-width: 1px;\n}\n#statediagram-barbEnd {\n fill: ${options.lineColor};\n}\n\n.statediagram-cluster rect {\n fill: ${options.compositeTitleBackground};\n stroke: ${options.stateBorder || options.nodeBorder};\n stroke-width: 1px;\n}\n\n.cluster-label, .nodeLabel {\n color: ${options.stateLabelColor};\n}\n\n.statediagram-cluster rect.outer {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state .divider {\n stroke: ${options.stateBorder || options.nodeBorder};\n}\n\n.statediagram-state .title-state {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-cluster.statediagram-cluster .inner {\n fill: ${options.compositeBackground || options.background};\n}\n.statediagram-cluster.statediagram-cluster-alt .inner {\n fill: ${options.altBackground ? options.altBackground : \"#efefef\"};\n}\n\n.statediagram-cluster .inner {\n rx:0;\n ry:0;\n}\n\n.statediagram-state rect.basic {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state rect.divider {\n stroke-dasharray: 10,10;\n fill: ${options.altBackground ? options.altBackground : \"#efefef\"};\n}\n\n.note-edge {\n stroke-dasharray: 5;\n}\n\n.statediagram-note rect {\n fill: ${options.noteBkgColor};\n stroke: ${options.noteBorderColor};\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n.statediagram-note rect {\n fill: ${options.noteBkgColor};\n stroke: ${options.noteBorderColor};\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n\n.statediagram-note text {\n fill: ${options.noteTextColor};\n}\n\n.statediagram-note .nodeLabel {\n color: ${options.noteTextColor};\n}\n.statediagram .edgeLabel {\n color: red; // ${options.noteTextColor};\n}\n\n#dependencyStart, #dependencyEnd {\n fill: ${options.lineColor};\n stroke: ${options.lineColor};\n stroke-width: 1;\n}\n\n.statediagramTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${options.textColor};\n}\n`;\nconst styles = getStyles;\nexport {\n DEFAULT_STATE_TYPE as D,\n STMT_R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"$Vs", "parser2", "yytext", "yyleng", "yylineno", "yy", "yystate", "$$", "_$", "$0", "stateStmt", "relDescription", "id", "description", "parts", "str", "hash", "error", "input", "self", "stack", "tstack", "vstack", "lstack", "table", "TERROR", "EOF", "args", "lexer2", "sharedState", "yyloc", "ranges", "lex", "token", "symbol", "state", "action", "r", "yyval", "p", "len", "newState", "expected", "errStr", "lexer", "ch", "lines", "oldLines", "n", "past", "next", "pre", "c", "match", "indexed_rule", "backup", "tempMatch", "index", "rules", "i", "condition", "yy_", "$avoiding_name_collisions", "YY_START", "Parser", "parser$1", "DEFAULT_DIAGRAM_DIRECTION", "DEFAULT_NESTED_DOC_DIR", "STMT_STATE", "STMT_RELATION", "STMT_CLASSDEF", "STMT_APPLYCLASS", "DEFAULT_STATE_TYPE", "DIVIDER_TYPE", "START_NODE", "START_TYPE", "END_NODE", "END_TYPE", "COLOR_KEYWORD", "FILL_KEYWORD", "BG_FILL", "STYLECLASS_SEP", "newClassesList", "direction", "rootDoc", "classes", "newDoc", "documents", "currentDocument", "startEndCount", "dividerCnt", "lineType", "relationType", "clone", "setRootDoc", "log$1", "getRootDoc", "docTranslator", "parent", "node", "first", "doc", "currentDoc", "newNode", "generateId", "docNode", "getRootDocV2", "extract", "_doc", "clear", "item", "addState", "addRelation", "addStyleClass", "setCssClass", "type", "descr", "note", "classes2", "styles2", "textStyles", "trimmedId", "addDescription", "des", "common$1", "getConfig", "klass", "style", "setStyle", "textStyle", "setTextStyle", "saveCommon", "getState", "getStates", "logDocuments", "getRelations", "startIdIfNeeded", "fixedId", "startTypeIfNeeded", "endIdIfNeeded", "endTypeIfNeeded", "addRelationObjs", "item1", "item2", "relationTitle", "id1", "type1", "id2", "type2", "title", "theState", "_descr", "cleanupLabel", "label", "getDividerId", "styleAttributes", "foundClass", "attrib", "fixedAttrib", "newStyle2", "getClasses", "itemIds", "cssClassName", "foundState", "itemId", "styleText", "getDirection", "setDirection", "dir", "trimColon", "db", "getAccTitle", "setAccTitle", "getAccDescription", "setAccDescription", "setDiagramTitle", "getDiagramTitle", "getStyles", "options", "styles"] } diff --git a/docs/public/chunk-65WDIALL.min.js b/docs/public/chunk-JUXSCBYR.min.js similarity index 99% rename from docs/public/chunk-65WDIALL.min.js rename to docs/public/chunk-JUXSCBYR.min.js index 1a0d35bb..ea33b710 100644 --- a/docs/public/chunk-65WDIALL.min.js +++ b/docs/public/chunk-JUXSCBYR.min.js @@ -6,7 +6,7 @@ import{b as za,d as qa}from"./chunk-P42HNYSU.min.js";var Tc=za((Wa,Ua)=>{(functi `).map(function(u,p){return p===0?u:""+h+u}).join(` `)),a+=f+i[l+1]}),a}function kc(t,e){let r;if(e===void 0)for(let i of t)i!=null&&(r=i)&&(r=i);else{let i=-1;for(let o of t)(o=e(o,++i,t))!=null&&(r=o)&&(r=o)}return r}function Sc(t,e){let r;if(e===void 0)for(let i of t)i!=null&&(r>i||r===void 0&&i>=i)&&(r=i);else{let i=-1;for(let o of t)(o=e(o,++i,t))!=null&&(r>o||r===void 0&&o>=o)&&(r=o)}return r}function nr(t,e){return t==null||e==null?NaN:te?1:t>=e?0:NaN}function Ha(t,e){return t==null||e==null?NaN:et?1:e>=t?0:NaN}function ar(t){let e,r,i;t.length!==2?(e=nr,r=(s,l)=>nr(t(s),l),i=(s,l)=>t(s)-l):(e=t===nr||t===Ha?t:Jg,r=t,i=t);function o(s,l,c=0,h=s.length){if(c>>1;r(s[f],l)<0?c=f+1:h=f}while(c>>1;r(s[f],l)<=0?c=f+1:h=f}while(cc&&i(s[f-1],l)>-i(s[f],l)?f-1:f}return{left:o,center:a,right:n}}function Jg(){return 0}function Ya(t){return t===null?NaN:+t}var wc=ar(nr),Bc=wc.right,t0=wc.left,e0=ar(Ya).center,ja=Bc;var zr=class extends Map{constructor(e,r=o0){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(let[i,o]of e)this.set(i,o)}get(e){return super.get(Ac(this,e))}has(e){return super.has(Ac(this,e))}set(e,r){return super.set(r0(this,e),r)}delete(e){return super.delete(i0(this,e))}};function Ac({_intern:t,_key:e},r){let i=e(r);return t.has(i)?t.get(i):r}function r0({_intern:t,_key:e},r){let i=e(r);return t.has(i)?t.get(i):(t.set(i,r),r)}function i0({_intern:t,_key:e},r){let i=e(r);return t.has(i)&&(r=t.get(i),t.delete(i)),r}function o0(t){return t!==null&&typeof t=="object"?t.valueOf():t}var n0=Math.sqrt(50),a0=Math.sqrt(10),s0=Math.sqrt(2);function Ao(t,e,r){let i=(e-t)/Math.max(0,r),o=Math.floor(Math.log10(i)),n=i/Math.pow(10,o),a=n>=n0?10:n>=a0?5:n>=s0?2:1,s,l,c;return o<0?(c=Math.pow(10,-o)/a,s=Math.round(t*c),l=Math.round(e*c),s/ce&&--l,c=-c):(c=Math.pow(10,o)*a,s=Math.round(t/c),l=Math.round(e/c),s*ce&&--l),l0))return[];if(t===e)return[t];let i=e=o))return[];let s=n-o+1,l=new Array(s);if(i)if(a<0)for(let c=0;c+t(e)}function h0(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),r=>+t(r)+e}function f0(){return!this.__axis}function Mc(t,e){var r=[],i=null,o=null,n=6,a=6,s=3,l=typeof window<"u"&&window.devicePixelRatio>1?0:.5,c=t===Eo||t===Mo?-1:1,h=t===Mo||t===Ga?"x":"y",f=t===Eo||t===Va?l0:c0;function u(p){var x=i??(e.ticks?e.ticks.apply(e,r):e.domain()),_=o??(e.tickFormat?e.tickFormat.apply(e,r):Fc),b=Math.max(n,0)+s,w=e.range(),v=+w[0]+l,L=+w[w.length-1]+l,E=(e.bandwidth?h0:u0)(e.copy(),l),I=p.selection?p.selection():p,A=I.selectAll(".domain").data([null]),y=I.selectAll(".tick").data(x,e).order(),$=y.exit(),et=y.enter().append("g").attr("class","tick"),rt=y.select("line"),T=y.select("text");A=A.merge(A.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),y=y.merge(et),rt=rt.merge(et.append("line").attr("stroke","currentColor").attr(h+"2",c*n)),T=T.merge(et.append("text").attr("fill","currentColor").attr(h,c*b).attr("dy",t===Eo?"0em":t===Va?"0.71em":"0.32em")),p!==I&&(A=A.transition(p),y=y.transition(p),rt=rt.transition(p),T=T.transition(p),$=$.transition(p).attr("opacity",Lc).attr("transform",function(C){return isFinite(C=E(C))?f(C+l):this.getAttribute("transform")}),et.attr("opacity",Lc).attr("transform",function(C){var g=this.parentNode.__axis;return f((g&&isFinite(g=g(C))?g:E(C))+l)})),$.remove(),A.attr("d",t===Mo||t===Ga?a?"M"+c*a+","+v+"H"+l+"V"+L+"H"+c*a:"M"+l+","+v+"V"+L:a?"M"+v+","+c*a+"V"+l+"H"+L+"V"+c*a:"M"+v+","+l+"H"+L),y.attr("opacity",1).attr("transform",function(C){return f(E(C)+l)}),rt.attr(h+"2",c*n),T.attr(h,c*b).text(_),I.filter(f0).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===Ga?"start":t===Mo?"end":"middle"),I.each(function(){this.__axis=E})}return u.scale=function(p){return arguments.length?(e=p,u):e},u.ticks=function(){return r=Array.from(arguments),u},u.tickArguments=function(p){return arguments.length?(r=p==null?[]:Array.from(p),u):r.slice()},u.tickValues=function(p){return arguments.length?(i=p==null?null:Array.from(p),u):i&&i.slice()},u.tickFormat=function(p){return arguments.length?(o=p,u):o},u.tickSize=function(p){return arguments.length?(n=a=+p,u):n},u.tickSizeInner=function(p){return arguments.length?(n=+p,u):n},u.tickSizeOuter=function(p){return arguments.length?(a=+p,u):a},u.tickPadding=function(p){return arguments.length?(s=+p,u):s},u.offset=function(p){return arguments.length?(l=+p,u):l},u}function p0(t){return Mc(Eo,t)}function d0(t){return Mc(Va,t)}function m0(){}function sr(t){return t==null?m0:function(){return this.querySelector(t)}}function Ec(t){typeof t!="function"&&(t=sr(t));for(var e=this._groups,r=e.length,i=new Array(r),o=0;o=L&&(L=v+1);!(I=b[L])&&++L=0;)(a=i[o])&&(n&&a.compareDocumentPosition(n)^4&&n.parentNode.insertBefore(a,n),n=a);return this}function Hc(t){t||(t=A0);function e(f,u){return f&&u?t(f.__data__,u.__data__):!f-!u}for(var r=this._groups,i=r.length,o=new Array(i),n=0;ne?1:t>=e?0:NaN}function Yc(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function jc(){return Array.from(this)}function Gc(){for(var t=this._groups,e=0,r=t.length;e=0&&(e=t.slice(0,r))!=="xmlns"&&(t=t.slice(r+1)),Xa.hasOwnProperty(e)?{space:Xa[e],local:t}:t}function F0(t){return function(){this.removeAttribute(t)}}function L0(t){return function(){this.removeAttributeNS(t.space,t.local)}}function M0(t,e){return function(){this.setAttribute(t,e)}}function E0(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function O0(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttribute(t):this.setAttribute(t,r)}}function I0(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}function Zc(t,e){var r=be(t);if(arguments.length<2){var i=this.node();return r.local?i.getAttributeNS(r.space,r.local):i.getAttribute(r)}return this.each((e==null?r.local?L0:F0:typeof e=="function"?r.local?I0:O0:r.local?E0:M0)(r,e))}function No(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function D0(t){return function(){this.style.removeProperty(t)}}function N0(t,e,r){return function(){this.style.setProperty(t,e,r)}}function P0(t,e,r){return function(){var i=e.apply(this,arguments);i==null?this.style.removeProperty(t):this.style.setProperty(t,i,r)}}function Qc(t,e,r){return arguments.length>1?this.each((e==null?D0:typeof e=="function"?P0:N0)(t,e,r??"")):De(this.node(),t)}function De(t,e){return t.style.getPropertyValue(e)||No(t).getComputedStyle(t,null).getPropertyValue(e)}function R0(t){return function(){delete this[t]}}function $0(t,e){return function(){this[t]=e}}function z0(t,e){return function(){var r=e.apply(this,arguments);r==null?delete this[t]:this[t]=r}}function Jc(t,e){return arguments.length>1?this.each((e==null?R0:typeof e=="function"?z0:$0)(t,e)):this.node()[t]}function tu(t){return t.trim().split(/^|\s+/)}function Ka(t){return t.classList||new eu(t)}function eu(t){this._node=t,this._names=tu(t.getAttribute("class")||"")}eu.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function ru(t,e){for(var r=Ka(t),i=-1,o=e.length;++i=0&&(r=e.slice(i+1),e=e.slice(0,i)),{type:e,name:r}})}function ax(t){return function(){var e=this.__on;if(e){for(var r=0,i=-1,o=e.length,n;r>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):r===8?Ro(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):r===4?Ro(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=px.exec(t))?new Lt(e[1],e[2],e[3],1):(e=dx.exec(t))?new Lt(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=mx.exec(t))?Ro(e[1],e[2],e[3],e[4]):(e=gx.exec(t))?Ro(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=xx.exec(t))?Su(e[1],e[2]/100,e[3]/100,1):(e=yx.exec(t))?Su(e[1],e[2]/100,e[3]/100,e[4]):_u.hasOwnProperty(t)?Tu(_u[t]):t==="transparent"?new Lt(NaN,NaN,NaN,0):null}function Tu(t){return new Lt(t>>16&255,t>>8&255,t&255,1)}function Ro(t,e,r,i){return i<=0&&(t=e=r=NaN),new Lt(t,e,r,i)}function Qa(t){return t instanceof Ne||(t=re(t)),t?(t=t.rgb(),new Lt(t.r,t.g,t.b,t.opacity)):new Lt}function Hr(t,e,r,i){return arguments.length===1?Qa(t):new Lt(t,e,r,i??1)}function Lt(t,e,r,i){this.r=+t,this.g=+e,this.b=+r,this.opacity=+i}lr(Lt,Hr,Wr(Ne,{brighter(t){return t=t==null?zo:Math.pow(zo,t),new Lt(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Ii:Math.pow(Ii,t),new Lt(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new Lt(ur(this.r),ur(this.g),ur(this.b),qo(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:vu,formatHex:vu,formatHex8:bx,formatRgb:ku,toString:ku}));function vu(){return`#${cr(this.r)}${cr(this.g)}${cr(this.b)}`}function bx(){return`#${cr(this.r)}${cr(this.g)}${cr(this.b)}${cr((isNaN(this.opacity)?1:this.opacity)*255)}`}function ku(){let t=qo(this.opacity);return`${t===1?"rgb(":"rgba("}${ur(this.r)}, ${ur(this.g)}, ${ur(this.b)}${t===1?")":`, ${t})`}`}function qo(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function ur(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function cr(t){return t=ur(t),(t<16?"0":"")+t.toString(16)}function Su(t,e,r,i){return i<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new ee(t,e,r,i)}function Bu(t){if(t instanceof ee)return new ee(t.h,t.s,t.l,t.opacity);if(t instanceof Ne||(t=re(t)),!t)return new ee;if(t instanceof ee)return t;t=t.rgb();var e=t.r/255,r=t.g/255,i=t.b/255,o=Math.min(e,r,i),n=Math.max(e,r,i),a=NaN,s=n-o,l=(n+o)/2;return s?(e===n?a=(r-i)/s+(r0&&l<1?0:a,new ee(a,s,l,t.opacity)}function Au(t,e,r,i){return arguments.length===1?Bu(t):new ee(t,e,r,i??1)}function ee(t,e,r,i){this.h=+t,this.s=+e,this.l=+r,this.opacity=+i}lr(ee,Au,Wr(Ne,{brighter(t){return t=t==null?zo:Math.pow(zo,t),new ee(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Ii:Math.pow(Ii,t),new ee(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,i=r+(r<.5?r:1-r)*e,o=2*r-i;return new Lt(Za(t>=240?t-240:t+120,o,i),Za(t,o,i),Za(t<120?t+240:t-120,o,i),this.opacity)},clamp(){return new ee(wu(this.h),$o(this.s),$o(this.l),qo(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let t=qo(this.opacity);return`${t===1?"hsl(":"hsla("}${wu(this.h)}, ${$o(this.s)*100}%, ${$o(this.l)*100}%${t===1?")":`, ${t})`}`}}));function wu(t){return t=(t||0)%360,t<0?t+360:t}function $o(t){return Math.max(0,Math.min(1,t||0))}function Za(t,e,r){return(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)*255}var Fu=Math.PI/180,Lu=180/Math.PI;var Wo=18,Mu=.96422,Eu=1,Ou=.82521,Iu=4/29,Yr=6/29,Du=3*Yr*Yr,Tx=Yr*Yr*Yr;function Nu(t){if(t instanceof he)return new he(t.l,t.a,t.b,t.opacity);if(t instanceof ve)return Pu(t);t instanceof Lt||(t=Qa(t));var e=rs(t.r),r=rs(t.g),i=rs(t.b),o=Ja((.2225045*e+.7168786*r+.0606169*i)/Eu),n,a;return e===r&&r===i?n=a=o:(n=Ja((.4360747*e+.3850649*r+.1430804*i)/Mu),a=Ja((.0139322*e+.0971045*r+.7141733*i)/Ou)),new he(116*o-16,500*(n-o),200*(o-a),t.opacity)}function is(t,e,r,i){return arguments.length===1?Nu(t):new he(t,e,r,i??1)}function he(t,e,r,i){this.l=+t,this.a=+e,this.b=+r,this.opacity=+i}lr(he,is,Wr(Ne,{brighter(t){return new he(this.l+Wo*(t??1),this.a,this.b,this.opacity)},darker(t){return new he(this.l-Wo*(t??1),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,r=isNaN(this.b)?t:t-this.b/200;return e=Mu*ts(e),t=Eu*ts(t),r=Ou*ts(r),new Lt(es(3.1338561*e-1.6168667*t-.4906146*r),es(-.9787684*e+1.9161415*t+.033454*r),es(.0719453*e-.2289914*t+1.4052427*r),this.opacity)}}));function Ja(t){return t>Tx?Math.pow(t,1/3):t/Du+Iu}function ts(t){return t>Yr?t*t*t:Du*(t-Iu)}function es(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function rs(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function vx(t){if(t instanceof ve)return new ve(t.h,t.c,t.l,t.opacity);if(t instanceof he||(t=Nu(t)),t.a===0&&t.b===0)return new ve(NaN,0()=>t;function Ru(t,e){return function(r){return t+r*e}}function kx(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(i){return Math.pow(t+i*e,r)}}function $u(t,e){var r=e-t;return r?Ru(t,r>180||r<-180?r-360*Math.round(r/360):r):jr(isNaN(t)?e:t)}function zu(t){return(t=+t)==1?ke:function(e,r){return r-e?kx(e,r,t):jr(isNaN(e)?r:e)}}function ke(t,e){var r=e-t;return r?Ru(t,r):jr(isNaN(t)?e:t)}function qu(t){return function(e,r){var i=t((e=Ni(e)).h,(r=Ni(r)).h),o=ke(e.c,r.c),n=ke(e.l,r.l),a=ke(e.opacity,r.opacity);return function(s){return e.h=i(s),e.c=o(s),e.l=n(s),e.opacity=a(s),e+""}}}var Sx=qu($u),wx=qu(ke);function os(t,e,r,i,o){var n=t*t,a=n*t;return((1-3*t+3*n-a)*e+(4-6*n+3*a)*r+(1+3*t+3*n-3*a)*i+a*o)/6}function Wu(t){var e=t.length-1;return function(r){var i=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),o=t[i],n=t[i+1],a=i>0?t[i-1]:2*o-n,s=ir&&(n=e.slice(r,n),s[a]?s[a]+=n:s[++a]=n),(i=i[0])===(o=o[0])?s[a]?s[a]+=o:s[++a]=o:(s[++a]=null,l.push({i:a,x:Mt(i,o)})),r=ns.lastIndex;return r180?h+=360:h-c>180&&(c+=360),u.push({i:f.push(o(f)+"rotate(",null,i)-2,x:Mt(c,h)})):h&&f.push(o(f)+"rotate("+h+i)}function s(c,h,f,u){c!==h?u.push({i:f.push(o(f)+"skewX(",null,i)-2,x:Mt(c,h)}):h&&f.push(o(f)+"skewX("+h+i)}function l(c,h,f,u,p,x){if(c!==f||h!==u){var _=p.push(o(p)+"scale(",null,",",null,")");x.push({i:_-4,x:Mt(c,f)},{i:_-2,x:Mt(h,u)})}else(f!==1||u!==1)&&p.push(o(p)+"scale("+f+","+u+")")}return function(c,h){var f=[],u=[];return c=t(c),h=t(h),n(c.translateX,c.translateY,h.translateX,h.translateY,f,u),a(c.rotate,h.rotate,f,u),s(c.skewX,h.skewX,f,u),l(c.scaleX,c.scaleY,h.scaleX,h.scaleY,f,u),c=h=null,function(p){for(var x=-1,_=u.length,b;++x<_;)f[(b=u[x]).i]=b.x(p);return f.join("")}}}var cs=Ju(Zu,"px, ","px)","deg)"),us=Ju(Qu,", ",")",")");function Pe(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}var hs=Symbol("implicit");function Ri(){var t=new zr,e=[],r=[],i=hs;function o(n){let a=t.get(n);if(a===void 0){if(i!==hs)return i;t.set(n,a=e.push(n)-1)}return r[a%r.length]}return o.domain=function(n){if(!arguments.length)return e.slice();e=[],t=new zr;for(let a of n)t.has(a)||t.set(a,e.push(a)-1);return o},o.range=function(n){return arguments.length?(r=Array.from(n),o):r.slice()},o.unknown=function(n){return arguments.length?(i=n,o):i},o.copy=function(){return Ri(e,r).unknown(i)},Pe.apply(o,arguments),o}function fs(){var t=Ri().unknown(void 0),e=t.domain,r=t.range,i=0,o=1,n,a,s=!1,l=0,c=0,h=.5;delete t.unknown;function f(){var u=e().length,p=oe&&(r=t,t=e,e=r),function(i){return Math.max(t,Math.min(e,i))}}function Ex(t,e,r){var i=t[0],o=t[1],n=e[0],a=e[1];return o2?Ox:Ex,l=c=null,f}function f(u){return u==null||isNaN(u=+u)?n:(l||(l=s(t.map(i),e,r)))(i(a(u)))}return f.invert=function(u){return a(o((c||(c=s(e,t.map(i),Mt)))(u)))},f.domain=function(u){return arguments.length?(t=Array.from(u,ds),h()):t.slice()},f.range=function(u){return arguments.length?(e=Array.from(u),h()):e.slice()},f.rangeRound=function(u){return e=Array.from(u),r=ss,h()},f.clamp=function(u){return arguments.length?(a=u?!0:Gr,h()):a!==Gr},f.interpolate=function(u){return arguments.length?(r=u,h()):r},f.unknown=function(u){return arguments.length?(n=u,f):n},function(u,p){return i=u,o=p,h()}}function $i(){return Ix()(Gr,Gr)}function eh(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}function pr(t,e){if((r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var r,i=t.slice(0,r);return[i.length>1?i[0]+i.slice(2):i,+t.slice(r+1)]}function fe(t){return t=pr(Math.abs(t)),t?t[1]:NaN}function rh(t,e){return function(r,i){for(var o=r.length,n=[],a=0,s=t[0],l=0;o>0&&s>0&&(l+s+1>i&&(s=Math.max(1,i-l)),n.push(r.substring(o-=s,o+s)),!((l+=s+1)>i));)s=t[a=(a+1)%t.length];return n.reverse().join(e)}}function ih(t){return function(e){return e.replace(/[0-9]/g,function(r){return t[+r]})}}var Dx=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Re(t){if(!(e=Dx.exec(t)))throw new Error("invalid format: "+t);var e;return new jo({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}Re.prototype=jo.prototype;function jo(t){this.fill=t.fill===void 0?" ":t.fill+"",this.align=t.align===void 0?">":t.align+"",this.sign=t.sign===void 0?"-":t.sign+"",this.symbol=t.symbol===void 0?"":t.symbol+"",this.zero=!!t.zero,this.width=t.width===void 0?void 0:+t.width,this.comma=!!t.comma,this.precision=t.precision===void 0?void 0:+t.precision,this.trim=!!t.trim,this.type=t.type===void 0?"":t.type+""}jo.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function oh(t){t:for(var e=t.length,r=1,i=-1,o;r0&&(i=0);break}return i>0?t.slice(0,i)+t.slice(o+1):t}var gs;function nh(t,e){var r=pr(t,e);if(!r)return t+"";var i=r[0],o=r[1],n=o-(gs=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,a=i.length;return n===a?i:n>a?i+new Array(n-a+1).join("0"):n>0?i.slice(0,n)+"."+i.slice(n):"0."+new Array(1-n).join("0")+pr(t,Math.max(0,e+n-1))[0]}function xs(t,e){var r=pr(t,e);if(!r)return t+"";var i=r[0],o=r[1];return o<0?"0."+new Array(-o).join("0")+i:i.length>o+1?i.slice(0,o+1)+"."+i.slice(o+1):i+new Array(o-i.length+2).join("0")}var ys={"%":(t,e)=>(t*100).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:eh,e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>xs(t*100,e),r:xs,s:nh,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function _s(t){return t}var ah=Array.prototype.map,sh=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function lh(t){var e=t.grouping===void 0||t.thousands===void 0?_s:rh(ah.call(t.grouping,Number),t.thousands+""),r=t.currency===void 0?"":t.currency[0]+"",i=t.currency===void 0?"":t.currency[1]+"",o=t.decimal===void 0?".":t.decimal+"",n=t.numerals===void 0?_s:ih(ah.call(t.numerals,String)),a=t.percent===void 0?"%":t.percent+"",s=t.minus===void 0?"\u2212":t.minus+"",l=t.nan===void 0?"NaN":t.nan+"";function c(f){f=Re(f);var u=f.fill,p=f.align,x=f.sign,_=f.symbol,b=f.zero,w=f.width,v=f.comma,L=f.precision,E=f.trim,I=f.type;I==="n"?(v=!0,I="g"):ys[I]||(L===void 0&&(L=12),E=!0,I="g"),(b||u==="0"&&p==="=")&&(b=!0,u="0",p="=");var A=_==="$"?r:_==="#"&&/[boxX]/.test(I)?"0"+I.toLowerCase():"",y=_==="$"?i:/[%p]/.test(I)?a:"",$=ys[I],et=/[defgprs%]/.test(I);L=L===void 0?6:/[gprs]/.test(I)?Math.max(1,Math.min(21,L)):Math.max(0,Math.min(20,L));function rt(T){var C=A,g=y,B,F,N;if(I==="c")g=$(T)+g,T="";else{T=+T;var R=T<0||1/T<0;if(T=isNaN(T)?l:$(Math.abs(T),L),E&&(T=oh(T)),R&&+T==0&&x!=="+"&&(R=!1),C=(R?x==="("?x:s:x==="-"||x==="("?"":x)+C,g=(I==="s"?sh[8+gs/3]:"")+g+(R&&x==="("?")":""),et){for(B=-1,F=T.length;++BN||N>57){g=(N===46?o+T.slice(B+1):T.slice(B))+g,T=T.slice(0,B);break}}}v&&!b&&(T=e(T,1/0));var j=C.length+T.length+g.length,G=j>1)+C+T+g+G.slice(j);break;default:T=G+C+T+g;break}return n(T)}return rt.toString=function(){return f+""},rt}function h(f,u){var p=c((f=Re(f),f.type="f",f)),x=Math.max(-8,Math.min(8,Math.floor(fe(u)/3)))*3,_=Math.pow(10,-x),b=sh[8+x/3];return function(w){return p(_*w)+b}}return{format:c,formatPrefix:h}}var Go,Vo,Xo;Cs({thousands:",",grouping:[3],currency:["$",""]});function Cs(t){return Go=lh(t),Vo=Go.format,Xo=Go.formatPrefix,Go}function bs(t){return Math.max(0,-fe(Math.abs(t)))}function Ts(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(fe(e)/3)))*3-fe(Math.abs(t)))}function vs(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,fe(e)-fe(t))+1}function ks(t,e,r,i){var o=qr(t,e,r),n;switch(i=Re(i??",f"),i.type){case"s":{var a=Math.max(Math.abs(t),Math.abs(e));return i.precision==null&&!isNaN(n=Ts(o,a))&&(i.precision=n),Xo(i,a)}case"":case"e":case"g":case"p":case"r":{i.precision==null&&!isNaN(n=vs(o,Math.max(Math.abs(t),Math.abs(e))))&&(i.precision=n-(i.type==="e"));break}case"f":case"%":{i.precision==null&&!isNaN(n=bs(o))&&(i.precision=n-(i.type==="%")*2);break}}return Vo(i)}function Nx(t){var e=t.domain;return t.ticks=function(r){var i=e();return Fo(i[0],i[i.length-1],r??10)},t.tickFormat=function(r,i){var o=e();return ks(o[0],o[o.length-1],r??10,i)},t.nice=function(r){r==null&&(r=10);var i=e(),o=0,n=i.length-1,a=i[o],s=i[n],l,c,h=10;for(s0;){if(c=Ai(a,s,r),c===l)return i[o]=a,i[n]=s,e(i);if(c>0)a=Math.floor(a/c)*c,s=Math.ceil(s/c)*c;else if(c<0)a=Math.ceil(a*c)/c,s=Math.floor(s*c)/c;else break;l=c}return t},t}function Ss(){var t=$i();return t.copy=function(){return Yo(t,Ss())},Pe.apply(t,arguments),Nx(t)}var ws=new Date,Bs=new Date;function nt(t,e,r,i){function o(n){return t(n=arguments.length===0?new Date:new Date(+n)),n}return o.floor=n=>(t(n=new Date(+n)),n),o.ceil=n=>(t(n=new Date(n-1)),e(n,1),t(n),n),o.round=n=>{let a=o(n),s=o.ceil(n);return n-a(e(n=new Date(+n),a==null?1:Math.floor(a)),n),o.range=(n,a,s)=>{let l=[];if(n=o.ceil(n),s=s==null?1:Math.floor(s),!(n0))return l;let c;do l.push(c=new Date(+n)),e(n,s),t(n);while(cnt(a=>{if(a>=a)for(;t(a),!n(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;e(a,-1),!n(a););else for(;--s>=0;)for(;e(a,1),!n(a););}),r&&(o.count=(n,a)=>(ws.setTime(+n),Bs.setTime(+a),t(ws),t(Bs),Math.floor(r(ws,Bs))),o.every=n=>(n=Math.floor(n),!isFinite(n)||!(n>0)?null:n>1?o.filter(i?a=>i(a)%n===0:a=>o.count(0,a)%n===0):o)),o}var dr=nt(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);dr.every=t=>(t=Math.floor(t),!isFinite(t)||!(t>0)?null:t>1?nt(e=>{e.setTime(Math.floor(e/t)*t)},(e,r)=>{e.setTime(+e+r*t)},(e,r)=>(r-e)/t):dr);var ch=dr.range;var pe=nt(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*1e3)},(t,e)=>(e-t)/1e3,t=>t.getUTCSeconds()),uh=pe.range;var Vr=nt(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getMinutes()),Px=Vr.range,Ko=nt(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getUTCMinutes()),Rx=Ko.range;var Xr=nt(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3-t.getMinutes()*6e4)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getHours()),$x=Xr.range,Zo=nt(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getUTCHours()),zx=Zo.range;var Se=nt(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*6e4)/864e5,t=>t.getDate()-1),qx=Se.range,qi=nt(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>t.getUTCDate()-1),Wx=qi.range,Qo=nt(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>Math.floor(t/864e5)),Ux=Qo.range;function xr(t){return nt(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(e,r)=>{e.setDate(e.getDate()+r*7)},(e,r)=>(r-e-(r.getTimezoneOffset()-e.getTimezoneOffset())*6e4)/6048e5)}var we=xr(0),Kr=xr(1),fh=xr(2),ph=xr(3),$e=xr(4),dh=xr(5),mh=xr(6),gh=we.range,Hx=Kr.range,Yx=fh.range,jx=ph.range,Gx=$e.range,Vx=dh.range,Xx=mh.range;function yr(t){return nt(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCDate(e.getUTCDate()+r*7)},(e,r)=>(r-e)/6048e5)}var _r=yr(0),Zr=yr(1),xh=yr(2),yh=yr(3),ze=yr(4),_h=yr(5),Ch=yr(6),bh=_r.range,Kx=Zr.range,Zx=xh.range,Qx=yh.range,Jx=ze.range,ty=_h.range,ey=Ch.range;var Qr=nt(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+(e.getFullYear()-t.getFullYear())*12,t=>t.getMonth()),ry=Qr.range,Jo=nt(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+(e.getUTCFullYear()-t.getUTCFullYear())*12,t=>t.getUTCMonth()),iy=Jo.range;var Vt=nt(t=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,e)=>{t.setFullYear(t.getFullYear()+e)},(t,e)=>e.getFullYear()-t.getFullYear(),t=>t.getFullYear());Vt.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:nt(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,r)=>{e.setFullYear(e.getFullYear()+r*t)});var oy=Vt.range,ie=nt(t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)},(t,e)=>e.getUTCFullYear()-t.getUTCFullYear(),t=>t.getUTCFullYear());ie.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:nt(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCFullYear(e.getUTCFullYear()+r*t)});var ny=ie.range;function vh(t,e,r,i,o,n){let a=[[pe,1,1e3],[pe,5,5*1e3],[pe,15,15*1e3],[pe,30,30*1e3],[n,1,6e4],[n,5,5*6e4],[n,15,15*6e4],[n,30,30*6e4],[o,1,36e5],[o,3,3*36e5],[o,6,6*36e5],[o,12,12*36e5],[i,1,864e5],[i,2,2*864e5],[r,1,6048e5],[e,1,2592e6],[e,3,3*2592e6],[t,1,31536e6]];function s(c,h,f){let u=hb).right(a,u);if(p===a.length)return t.every(qr(c/31536e6,h/31536e6,f));if(p===0)return dr.every(Math.max(qr(c,h,f),1));let[x,_]=a[u/a[p-1][2]53)return null;"w"in k||(k.w=1),"Z"in k?(it=Ms(Wi(k.y,0,1)),X=it.getUTCDay(),it=X>4||X===0?Zr.ceil(it):Zr(it),it=qi.offset(it,(k.V-1)*7),k.y=it.getUTCFullYear(),k.m=it.getUTCMonth(),k.d=it.getUTCDate()+(k.w+6)%7):(it=Ls(Wi(k.y,0,1)),X=it.getDay(),it=X>4||X===0?Kr.ceil(it):Kr(it),it=Se.offset(it,(k.V-1)*7),k.y=it.getFullYear(),k.m=it.getMonth(),k.d=it.getDate()+(k.w+6)%7)}else("W"in k||"U"in k)&&("w"in k||(k.w="u"in k?k.u%7:"W"in k?1:0),X="Z"in k?Ms(Wi(k.y,0,1)).getUTCDay():Ls(Wi(k.y,0,1)).getDay(),k.m=0,k.d="W"in k?(k.w+6)%7+k.W*7-(X+5)%7:k.w+k.U*7-(X+6)%7);return"Z"in k?(k.H+=k.Z/100|0,k.M+=k.Z%100,Ms(k)):Ls(k)}}function $(O,V,K,k){for(var Ft=0,it=V.length,X=K.length,P,Q;Ft=X)return-1;if(P=V.charCodeAt(Ft++),P===37){if(P=V.charAt(Ft++),Q=I[P in kh?V.charAt(Ft++):P],!Q||(k=Q(O,K,k))<0)return-1}else if(P!=K.charCodeAt(k++))return-1}return k}function et(O,V,K){var k=c.exec(V.slice(K));return k?(O.p=h.get(k[0].toLowerCase()),K+k[0].length):-1}function rt(O,V,K){var k=p.exec(V.slice(K));return k?(O.w=x.get(k[0].toLowerCase()),K+k[0].length):-1}function T(O,V,K){var k=f.exec(V.slice(K));return k?(O.w=u.get(k[0].toLowerCase()),K+k[0].length):-1}function C(O,V,K){var k=w.exec(V.slice(K));return k?(O.m=v.get(k[0].toLowerCase()),K+k[0].length):-1}function g(O,V,K){var k=_.exec(V.slice(K));return k?(O.m=b.get(k[0].toLowerCase()),K+k[0].length):-1}function B(O,V,K){return $(O,e,V,K)}function F(O,V,K){return $(O,r,V,K)}function N(O,V,K){return $(O,i,V,K)}function R(O){return a[O.getDay()]}function j(O){return n[O.getDay()]}function G(O){return l[O.getMonth()]}function Z(O){return s[O.getMonth()]}function at(O){return o[+(O.getHours()>=12)]}function Bt(O){return 1+~~(O.getMonth()/3)}function At(O){return a[O.getUTCDay()]}function Gt(O){return n[O.getUTCDay()]}function gt(O){return l[O.getUTCMonth()]}function Pt(O){return s[O.getUTCMonth()]}function ht(O){return o[+(O.getUTCHours()>=12)]}function It(O){return 1+~~(O.getUTCMonth()/3)}return{format:function(O){var V=A(O+="",L);return V.toString=function(){return O},V},parse:function(O){var V=y(O+="",!1);return V.toString=function(){return O},V},utcFormat:function(O){var V=A(O+="",E);return V.toString=function(){return O},V},utcParse:function(O){var V=y(O+="",!0);return V.toString=function(){return O},V}}}var kh={"-":"",_:" ",0:"0"},St=/^\s*\d+/,cy=/^%/,uy=/[\\^$*+?|[\]().{}]/g;function tt(t,e,r){var i=t<0?"-":"",o=(i?-t:t)+"",n=o.length;return i+(n[e.toLowerCase(),r]))}function fy(t,e,r){var i=St.exec(e.slice(r,r+1));return i?(t.w=+i[0],r+i[0].length):-1}function py(t,e,r){var i=St.exec(e.slice(r,r+1));return i?(t.u=+i[0],r+i[0].length):-1}function dy(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.U=+i[0],r+i[0].length):-1}function my(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.V=+i[0],r+i[0].length):-1}function gy(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.W=+i[0],r+i[0].length):-1}function Sh(t,e,r){var i=St.exec(e.slice(r,r+4));return i?(t.y=+i[0],r+i[0].length):-1}function wh(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.y=+i[0]+(+i[0]>68?1900:2e3),r+i[0].length):-1}function xy(t,e,r){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return i?(t.Z=i[1]?0:-(i[2]+(i[3]||"00")),r+i[0].length):-1}function yy(t,e,r){var i=St.exec(e.slice(r,r+1));return i?(t.q=i[0]*3-3,r+i[0].length):-1}function _y(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.m=i[0]-1,r+i[0].length):-1}function Bh(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.d=+i[0],r+i[0].length):-1}function Cy(t,e,r){var i=St.exec(e.slice(r,r+3));return i?(t.m=0,t.d=+i[0],r+i[0].length):-1}function Ah(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.H=+i[0],r+i[0].length):-1}function by(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.M=+i[0],r+i[0].length):-1}function Ty(t,e,r){var i=St.exec(e.slice(r,r+2));return i?(t.S=+i[0],r+i[0].length):-1}function vy(t,e,r){var i=St.exec(e.slice(r,r+3));return i?(t.L=+i[0],r+i[0].length):-1}function ky(t,e,r){var i=St.exec(e.slice(r,r+6));return i?(t.L=Math.floor(i[0]/1e3),r+i[0].length):-1}function Sy(t,e,r){var i=cy.exec(e.slice(r,r+1));return i?r+i[0].length:-1}function wy(t,e,r){var i=St.exec(e.slice(r));return i?(t.Q=+i[0],r+i[0].length):-1}function By(t,e,r){var i=St.exec(e.slice(r));return i?(t.s=+i[0],r+i[0].length):-1}function Fh(t,e){return tt(t.getDate(),e,2)}function Ay(t,e){return tt(t.getHours(),e,2)}function Fy(t,e){return tt(t.getHours()%12||12,e,2)}function Ly(t,e){return tt(1+Se.count(Vt(t),t),e,3)}function Ih(t,e){return tt(t.getMilliseconds(),e,3)}function My(t,e){return Ih(t,e)+"000"}function Ey(t,e){return tt(t.getMonth()+1,e,2)}function Oy(t,e){return tt(t.getMinutes(),e,2)}function Iy(t,e){return tt(t.getSeconds(),e,2)}function Dy(t){var e=t.getDay();return e===0?7:e}function Ny(t,e){return tt(we.count(Vt(t)-1,t),e,2)}function Dh(t){var e=t.getDay();return e>=4||e===0?$e(t):$e.ceil(t)}function Py(t,e){return t=Dh(t),tt($e.count(Vt(t),t)+(Vt(t).getDay()===4),e,2)}function Ry(t){return t.getDay()}function $y(t,e){return tt(Kr.count(Vt(t)-1,t),e,2)}function zy(t,e){return tt(t.getFullYear()%100,e,2)}function qy(t,e){return t=Dh(t),tt(t.getFullYear()%100,e,2)}function Wy(t,e){return tt(t.getFullYear()%1e4,e,4)}function Uy(t,e){var r=t.getDay();return t=r>=4||r===0?$e(t):$e.ceil(t),tt(t.getFullYear()%1e4,e,4)}function Hy(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+tt(e/60|0,"0",2)+tt(e%60,"0",2)}function Lh(t,e){return tt(t.getUTCDate(),e,2)}function Yy(t,e){return tt(t.getUTCHours(),e,2)}function jy(t,e){return tt(t.getUTCHours()%12||12,e,2)}function Gy(t,e){return tt(1+qi.count(ie(t),t),e,3)}function Nh(t,e){return tt(t.getUTCMilliseconds(),e,3)}function Vy(t,e){return Nh(t,e)+"000"}function Xy(t,e){return tt(t.getUTCMonth()+1,e,2)}function Ky(t,e){return tt(t.getUTCMinutes(),e,2)}function Zy(t,e){return tt(t.getUTCSeconds(),e,2)}function Qy(t){var e=t.getUTCDay();return e===0?7:e}function Jy(t,e){return tt(_r.count(ie(t)-1,t),e,2)}function Ph(t){var e=t.getUTCDay();return e>=4||e===0?ze(t):ze.ceil(t)}function t_(t,e){return t=Ph(t),tt(ze.count(ie(t),t)+(ie(t).getUTCDay()===4),e,2)}function e_(t){return t.getUTCDay()}function r_(t,e){return tt(Zr.count(ie(t)-1,t),e,2)}function i_(t,e){return tt(t.getUTCFullYear()%100,e,2)}function o_(t,e){return t=Ph(t),tt(t.getUTCFullYear()%100,e,2)}function n_(t,e){return tt(t.getUTCFullYear()%1e4,e,4)}function a_(t,e){var r=t.getUTCDay();return t=r>=4||r===0?ze(t):ze.ceil(t),tt(t.getUTCFullYear()%1e4,e,4)}function s_(){return"+0000"}function Mh(){return"%"}function Eh(t){return+t}function Oh(t){return Math.floor(+t/1e3)}var Jr,tn,Rh,$h,zh;Os({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Os(t){return Jr=Es(t),tn=Jr.format,Rh=Jr.parse,$h=Jr.utcFormat,zh=Jr.utcParse,Jr}function Is(t,e){t=t.slice();var r=0,i=t.length-1,o=t[r],n=t[i],a;return n1?0:t<-1?ti:Math.acos(t)}function Ns(t){return t>=1?Yi:t<=-1?-Yi:Math.asin(t)}var Ps=Math.PI,Rs=2*Ps,br=1e-6,h_=Rs-br;function jh(t){this._+=t[0];for(let e=1,r=t.length;e=0))throw new Error(`invalid digits: ${t}`);if(e>15)return jh;let r=10**e;return function(i){this._+=i[0];for(let o=1,n=i.length;obr)if(!(Math.abs(f*l-c*h)>br)||!n)this._append`L${this._x1=e},${this._y1=r}`;else{let p=i-a,x=o-s,_=l*l+c*c,b=p*p+x*x,w=Math.sqrt(_),v=Math.sqrt(u),L=n*Math.tan((Ps-Math.acos((_+u-b)/(2*w*v)))/2),E=L/v,I=L/w;Math.abs(E-1)>br&&this._append`L${e+E*h},${r+E*f}`,this._append`A${n},${n},0,0,${+(f*p>h*x)},${this._x1=e+I*l},${this._y1=r+I*c}`}}arc(e,r,i,o,n,a){if(e=+e,r=+r,i=+i,a=!!a,i<0)throw new Error(`negative radius: ${i}`);let s=i*Math.cos(o),l=i*Math.sin(o),c=e+s,h=r+l,f=1^a,u=a?o-n:n-o;this._x1===null?this._append`M${c},${h}`:(Math.abs(this._x1-c)>br||Math.abs(this._y1-h)>br)&&this._append`L${c},${h}`,i&&(u<0&&(u=u%Rs+Rs),u>h_?this._append`A${i},${i},0,1,${f},${e-s},${r-l}A${i},${i},0,1,${f},${this._x1=c},${this._y1=h}`:u>br&&this._append`A${i},${i},0,${+(u>=Ps)},${f},${this._x1=e+i*Math.cos(n)},${this._y1=r+i*Math.sin(n)}`)}rect(e,r,i,o){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}h${i=+i}v${+o}h${-i}Z`}toString(){return this._}};function Gh(){return new Tr}Gh.prototype=Tr.prototype;function rn(t){let e=3;return t.digits=function(r){if(!arguments.length)return e;if(r==null)e=null;else{let i=Math.floor(r);if(!(i>=0))throw new RangeError(`invalid digits: ${r}`);e=i}return t},()=>new Tr(e)}function p_(t){return t.innerRadius}function d_(t){return t.outerRadius}function m_(t){return t.startAngle}function g_(t){return t.endAngle}function x_(t){return t&&t.padAngle}function y_(t,e,r,i,o,n,a,s){var l=r-t,c=i-e,h=a-o,f=s-n,u=f*l-h*c;if(!(u*uB*B+F*F&&($=rt,et=T),{cx:$,cy:et,x01:-h,y01:-f,x11:$*(o/I-1),y11:et*(o/I-1)}}function __(){var t=p_,e=d_,r=ct(0),i=null,o=m_,n=g_,a=x_,s=null,l=rn(c);function c(){var h,f,u=+t.apply(this,arguments),p=+e.apply(this,arguments),x=o.apply(this,arguments)-Yi,_=n.apply(this,arguments)-Yi,b=Ds(_-x),w=_>x;if(s||(s=h=l()),pwt))s.moveTo(0,0);else if(b>ei-wt)s.moveTo(p*qe(x),p*oe(x)),s.arc(0,0,p,x,_,!w),u>wt&&(s.moveTo(u*qe(_),u*oe(_)),s.arc(0,0,u,_,x,w));else{var v=x,L=_,E=x,I=_,A=b,y=b,$=a.apply(this,arguments)/2,et=$>wt&&(i?+i.apply(this,arguments):Cr(u*u+p*p)),rt=en(Ds(p-u)/2,+r.apply(this,arguments)),T=rt,C=rt,g,B;if(et>wt){var F=Ns(et/u*oe($)),N=Ns(et/p*oe($));(A-=F*2)>wt?(F*=w?1:-1,E+=F,I-=F):(A=0,E=I=(x+_)/2),(y-=N*2)>wt?(N*=w?1:-1,v+=N,L-=N):(y=0,v=L=(x+_)/2)}var R=p*qe(v),j=p*oe(v),G=u*qe(I),Z=u*oe(I);if(rt>wt){var at=p*qe(L),Bt=p*oe(L),At=u*qe(E),Gt=u*oe(E),gt;if(bwt?C>wt?(g=on(At,Gt,R,j,p,C,w),B=on(at,Bt,G,Z,p,C,w),s.moveTo(g.cx+g.x01,g.cy+g.y01),Cwt)||!(A>wt)?s.lineTo(G,Z):T>wt?(g=on(G,Z,at,Bt,u,-T,w),B=on(R,j,At,Gt,u,-T,w),s.lineTo(g.cx+g.x01,g.cy+g.y01),Tt?1:e>=t?0:NaN}function Qh(t){return t}function b_(){var t=Qh,e=Zh,r=null,i=ct(0),o=ct(ei),n=ct(0);function a(s){var l,c=(s=nn(s)).length,h,f,u=0,p=new Array(c),x=new Array(c),_=+i.apply(this,arguments),b=Math.min(ei,Math.max(-ei,o.apply(this,arguments)-_)),w,v=Math.min(Math.abs(b)/c,n.apply(this,arguments)),L=v*(b<0?-1:1),E;for(l=0;l0&&(u+=E);for(e!=null?p.sort(function(I,A){return e(x[I],x[A])}):r!=null&&p.sort(function(I,A){return r(s[I],s[A])}),l=0,f=u?(b-c*L)/u:0;l0?E*f:0)+L,x[h]={data:s[h],index:l,value:E,startAngle:_,endAngle:w,padAngle:v};return x}return a.value=function(s){return arguments.length?(t=typeof s=="function"?s:ct(+s),a):t},a.sortValues=function(s){return arguments.length?(e=s,r=null,a):e},a.sort=function(s){return arguments.length?(r=s,e=null,a):r},a.startAngle=function(s){return arguments.length?(i=typeof s=="function"?s:ct(+s),a):i},a.endAngle=function(s){return arguments.length?(o=typeof s=="function"?s:ct(+s),a):o},a.padAngle=function(s){return arguments.length?(n=typeof s=="function"?s:ct(+s),a):n},a}function ri(t,e,r){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+r)/6)}function Gi(t){this._context=t}Gi.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:ri(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:ri(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function $s(t){return new Gi(t)}var an=class{constructor(e,r){this._context=e,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(e,r){switch(e=+e,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(e,r):this._context.moveTo(e,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,r,e,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,e,this._y0,e,r);break}}this._x0=e,this._y0=r}};function zs(t){return new an(t,!0)}function qs(t){return new an(t,!1)}function Kt(){}function Jh(t){this._context=t}Jh.prototype={areaStart:Kt,areaEnd:Kt,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:ri(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Ws(t){return new Jh(t)}function tf(t){this._context=t}tf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+t)/6,i=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(r,i):this._context.moveTo(r,i);break;case 3:this._point=4;default:ri(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Us(t){return new tf(t)}function ef(t,e){this._basis=new Gi(t),this._beta=e}ef.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,r=t.length-1;if(r>0)for(var i=t[0],o=e[0],n=t[r]-i,a=e[r]-o,s=-1,l;++s<=r;)l=s/r,this._basis.point(this._beta*t[s]+(1-this._beta)*(i+l*n),this._beta*e[s]+(1-this._beta)*(o+l*a));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var Hs=function t(e){function r(i){return e===1?new Gi(i):new ef(i,e)}return r.beta=function(i){return t(+i)},r}(.85);function ii(t,e,r){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-r),t._x2,t._y2)}function sn(t,e){this._context=t,this._k=(1-e)/6}sn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:ii(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:ii(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Ys=function t(e){function r(i){return new sn(i,e)}return r.tension=function(i){return t(+i)},r}(0);function ln(t,e){this._context=t,this._k=(1-e)/6}ln.prototype={areaStart:Kt,areaEnd:Kt,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:ii(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var js=function t(e){function r(i){return new ln(i,e)}return r.tension=function(i){return t(+i)},r}(0);function cn(t,e){this._context=t,this._k=(1-e)/6}cn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:ii(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Gs=function t(e){function r(i){return new cn(i,e)}return r.tension=function(i){return t(+i)},r}(0);function Vi(t,e,r){var i=t._x1,o=t._y1,n=t._x2,a=t._y2;if(t._l01_a>wt){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,l=3*t._l01_a*(t._l01_a+t._l12_a);i=(i*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/l,o=(o*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/l}if(t._l23_a>wt){var c=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,h=3*t._l23_a*(t._l23_a+t._l12_a);n=(n*c+t._x1*t._l23_2a-e*t._l12_2a)/h,a=(a*c+t._y1*t._l23_2a-r*t._l12_2a)/h}t._context.bezierCurveTo(i,o,n,a,t._x2,t._y2)}function rf(t,e){this._context=t,this._alpha=e}rf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:Vi(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Vs=function t(e){function r(i){return e?new rf(i,e):new sn(i,0)}return r.alpha=function(i){return t(+i)},r}(.5);function of(t,e){this._context=t,this._alpha=e}of.prototype={areaStart:Kt,areaEnd:Kt,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:Vi(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Xs=function t(e){function r(i){return e?new of(i,e):new ln(i,0)}return r.alpha=function(i){return t(+i)},r}(.5);function nf(t,e){this._context=t,this._alpha=e}nf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,i=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Vi(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Ks=function t(e){function r(i){return e?new nf(i,e):new cn(i,0)}return r.alpha=function(i){return t(+i)},r}(.5);function af(t){this._context=t}af.prototype={areaStart:Kt,areaEnd:Kt,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}};function Zs(t){return new af(t)}function sf(t){return t<0?-1:1}function lf(t,e,r){var i=t._x1-t._x0,o=e-t._x1,n=(t._y1-t._y0)/(i||o<0&&-0),a=(r-t._y1)/(o||i<0&&-0),s=(n*o+a*i)/(i+o);return(sf(n)+sf(a))*Math.min(Math.abs(n),Math.abs(a),.5*Math.abs(s))||0}function cf(t,e){var r=t._x1-t._x0;return r?(3*(t._y1-t._y0)/r-e)/2:e}function Qs(t,e,r){var i=t._x0,o=t._y0,n=t._x1,a=t._y1,s=(n-i)/3;t._context.bezierCurveTo(i+s,o+s*e,n-s,a-s*r,n,a)}function un(t){this._context=t}un.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:Qs(this,this._t0,cf(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var r=NaN;if(t=+t,e=+e,!(t===this._x1&&e===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,Qs(this,cf(this,r=lf(this,t,e)),r);break;default:Qs(this,this._t0,r=lf(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=r}}};function uf(t){this._context=new hf(t)}(uf.prototype=Object.create(un.prototype)).point=function(t,e){un.prototype.point.call(this,e,t)};function hf(t){this._context=t}hf.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,r,i,o,n){this._context.bezierCurveTo(e,t,i,r,n,o)}};function Js(t){return new un(t)}function tl(t){return new uf(t)}function pf(t){this._context=t}pf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,r=t.length;if(r)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),r===2)this._context.lineTo(t[1],e[1]);else for(var i=ff(t),o=ff(e),n=0,a=1;a=0;--e)o[e]=(a[e]-o[e+1])/n[e];for(n[r-1]=(t[r]+o[r-1])/2,e=0;e=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var r=this._x*(1-this._t)+t*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,e)}break}}this._x=t,this._y=e}};function rl(t){return new hn(t,.5)}function il(t){return new hn(t,0)}function ol(t){return new hn(t,1)}var T_={value:()=>{}};function mf(){for(var t=0,e=arguments.length,r={},i;t=0&&(i=r.slice(o+1),r=r.slice(0,o)),r&&!e.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:i}})}fn.prototype=mf.prototype={constructor:fn,on:function(t,e){var r=this._,i=v_(t+"",r),o,n=-1,a=i.length;if(arguments.length<2){for(;++n0)for(var r=new Array(o),i=0,o,n;i=0&&t._call.call(void 0,e),t=t._next;--oi}function gf(){vr=(dn=Qi.now())+mn,oi=Ki=0;try{_f()}finally{oi=0,B_(),vr=0}}function w_(){var t=Qi.now(),e=t-dn;e>xf&&(mn-=e,dn=t)}function B_(){for(var t,e=pn,r,i=1/0;e;)e._call?(i>e._time&&(i=e._time),t=e,e=e._next):(r=e._next,e._next=null,e=t?t._next=r:pn=r);Zi=t,al(i)}function al(t){if(!oi){Ki&&(Ki=clearTimeout(Ki));var e=t-vr;e>24?(t<1/0&&(Ki=setTimeout(gf,t-Qi.now()-mn)),Xi&&(Xi=clearInterval(Xi))):(Xi||(dn=Qi.now(),Xi=setInterval(w_,xf)),oi=1,yf(gf))}}function xn(t,e,r){var i=new Ji;return e=e==null?0:+e,i.restart(o=>{i.stop(),t(o+e)},e,r),i}var A_=nl("start","end","cancel","interrupt"),F_=[],Tf=0,Cf=1,_n=2,yn=3,bf=4,Cn=5,eo=6;function We(t,e,r,i,o,n){var a=t.__transition;if(!a)t.__transition={};else if(r in a)return;L_(t,r,{name:e,index:i,group:o,on:A_,tween:F_,time:n.time,delay:n.delay,duration:n.duration,ease:n.ease,timer:null,state:Tf})}function ro(t,e){var r=xt(t,e);if(r.state>Tf)throw new Error("too late; already scheduled");return r}function Ot(t,e){var r=xt(t,e);if(r.state>yn)throw new Error("too late; already running");return r}function xt(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}function L_(t,e,r){var i=t.__transition,o;i[e]=r,r.timer=gn(n,0,r.time);function n(c){r.state=Cf,r.timer.restart(a,r.delay,r.time),r.delay<=c&&a(c-r.delay)}function a(c){var h,f,u,p;if(r.state!==Cf)return l();for(h in i)if(p=i[h],p.name===r.name){if(p.state===yn)return xn(a);p.state===bf?(p.state=eo,p.timer.stop(),p.on.call("interrupt",t,t.__data__,p.index,p.group),delete i[h]):+h_n&&i.state=0&&(e=e.slice(0,r)),!e||e==="start"})}function K_(t,e,r){var i,o,n=X_(e)?ro:Ot;return function(){var a=n(this,t),s=a.on;s!==i&&(o=(i=s).copy()).on(e,r),a.on=o}}function Of(t,e){var r=this._id;return arguments.length<2?xt(this.node(),r).on.on(t):this.each(K_(r,t,e))}function Z_(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}function If(){return this.on("end.remove",Z_(this._id))}function Df(t){var e=this._name,r=this._id;typeof t!="function"&&(t=sr(t));for(var i=this._groups,o=i.length,n=new Array(o),a=0;aVf(e,r).then(i=>new DOMParser().parseFromString(i,t))}var dC=ll("application/xml"),mC=ll("text/html"),gC=ll("image/svg+xml");function Ue(t,e,r){this.k=t,this.x=e,this.y=r}Ue.prototype={constructor:Ue,scale:function(t){return t===1?this:new Ue(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new Ue(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var cl=new Ue(1,0,0);ul.prototype=Ue.prototype;function ul(t){for(;!t.__zoom;)if(!(t=t.parentNode))return cl;return t.__zoom}var Sn={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:t=>t>=255?255:t<0?0:t,g:t=>t>=255?255:t<0?0:t,b:t=>t>=255?255:t<0?0:t,h:t=>t%360,s:t=>t>=100?100:t<0?0:t,l:t=>t>=100?100:t<0?0:t,a:t=>t>=1?1:t<0?0:t},toLinear:t=>{let e=t/255;return t>.03928?Math.pow((e+.055)/1.055,2.4):e/12.92},hue2rgb:(t,e,r)=>(r<0&&(r+=1),r>1&&(r-=1),r<.16666666666666666?t+(e-t)*6*r:r<.5?e:r<.6666666666666666?t+(e-t)*(.6666666666666666-r)*6:t),hsl2rgb:({h:t,s:e,l:r},i)=>{if(!e)return r*2.55;t/=360,e/=100,r/=100;let o=r<.5?r*(1+e):r+e-r*e,n=2*r-o;switch(i){case"r":return Sn.hue2rgb(n,o,t+.3333333333333333)*255;case"g":return Sn.hue2rgb(n,o,t)*255;case"b":return Sn.hue2rgb(n,o,t-.3333333333333333)*255}},rgb2hsl:({r:t,g:e,b:r},i)=>{t/=255,e/=255,r/=255;let o=Math.max(t,e,r),n=Math.min(t,e,r),a=(o+n)/2;if(i==="l")return a*100;if(o===n)return 0;let s=o-n,l=a>.5?s/(2-o-n):s/(o+n);if(i==="s")return l*100;switch(o){case t:return((e-r)/s+(ee>r?Math.min(e,Math.max(r,t)):Math.min(r,Math.max(e,t)),round:t=>Math.round(t*1e10)/1e10},Zf=xC;var yC={dec2hex:t=>{let e=Math.round(t).toString(16);return e.length>1?e:`0${e}`}},Qf=yC;var _C={channel:Kf,lang:Zf,unit:Qf},q=_C;var Ae={};for(let t=0;t<=255;t++)Ae[t]=q.unit.dec2hex(t);var yt={ALL:0,RGB:1,HSL:2};var pl=class{constructor(){this.type=yt.ALL}get(){return this.type}set(e){if(this.type&&this.type!==e)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=e}reset(){this.type=yt.ALL}is(e){return this.type===e}},Jf=pl;var dl=class{constructor(e,r){this.color=r,this.changed=!1,this.data=e,this.type=new Jf}set(e,r){return this.color=r,this.changed=!1,this.data=e,this.type.type=yt.ALL,this}_ensureHSL(){let e=this.data,{h:r,s:i,l:o}=e;r===void 0&&(e.h=q.channel.rgb2hsl(e,"h")),i===void 0&&(e.s=q.channel.rgb2hsl(e,"s")),o===void 0&&(e.l=q.channel.rgb2hsl(e,"l"))}_ensureRGB(){let e=this.data,{r,g:i,b:o}=e;r===void 0&&(e.r=q.channel.hsl2rgb(e,"r")),i===void 0&&(e.g=q.channel.hsl2rgb(e,"g")),o===void 0&&(e.b=q.channel.hsl2rgb(e,"b"))}get r(){let e=this.data,r=e.r;return!this.type.is(yt.HSL)&&r!==void 0?r:(this._ensureHSL(),q.channel.hsl2rgb(e,"r"))}get g(){let e=this.data,r=e.g;return!this.type.is(yt.HSL)&&r!==void 0?r:(this._ensureHSL(),q.channel.hsl2rgb(e,"g"))}get b(){let e=this.data,r=e.b;return!this.type.is(yt.HSL)&&r!==void 0?r:(this._ensureHSL(),q.channel.hsl2rgb(e,"b"))}get h(){let e=this.data,r=e.h;return!this.type.is(yt.RGB)&&r!==void 0?r:(this._ensureRGB(),q.channel.rgb2hsl(e,"h"))}get s(){let e=this.data,r=e.s;return!this.type.is(yt.RGB)&&r!==void 0?r:(this._ensureRGB(),q.channel.rgb2hsl(e,"s"))}get l(){let e=this.data,r=e.l;return!this.type.is(yt.RGB)&&r!==void 0?r:(this._ensureRGB(),q.channel.rgb2hsl(e,"l"))}get a(){return this.data.a}set r(e){this.type.set(yt.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(yt.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(yt.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(yt.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(yt.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(yt.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}},tp=dl;var CC=new tp({r:0,g:0,b:0,a:0},"transparent"),He=CC;var ep={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:t=>{if(t.charCodeAt(0)!==35)return;let e=t.match(ep.re);if(!e)return;let r=e[1],i=parseInt(r,16),o=r.length,n=o%4===0,a=o>4,s=a?1:17,l=a?8:4,c=n?0:-1,h=a?255:15;return He.set({r:(i>>l*(c+3)&h)*s,g:(i>>l*(c+2)&h)*s,b:(i>>l*(c+1)&h)*s,a:n?(i&h)*s/255:1},t)},stringify:t=>{let{r:e,g:r,b:i,a:o}=t;return o<1?`#${Ae[Math.round(e)]}${Ae[Math.round(r)]}${Ae[Math.round(i)]}${Ae[Math.round(o*255)]}`:`#${Ae[Math.round(e)]}${Ae[Math.round(r)]}${Ae[Math.round(i)]}`}},kr=ep;var wn={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:t=>{let e=t.match(wn.hueRe);if(e){let[,r,i]=e;switch(i){case"grad":return q.channel.clamp.h(parseFloat(r)*.9);case"rad":return q.channel.clamp.h(parseFloat(r)*180/Math.PI);case"turn":return q.channel.clamp.h(parseFloat(r)*360)}}return q.channel.clamp.h(parseFloat(t))},parse:t=>{let e=t.charCodeAt(0);if(e!==104&&e!==72)return;let r=t.match(wn.re);if(!r)return;let[,i,o,n,a,s]=r;return He.set({h:wn._hue2deg(i),s:q.channel.clamp.s(parseFloat(o)),l:q.channel.clamp.l(parseFloat(n)),a:a?q.channel.clamp.a(s?parseFloat(a)/100:parseFloat(a)):1},t)},stringify:t=>{let{h:e,s:r,l:i,a:o}=t;return o<1?`hsla(${q.lang.round(e)}, ${q.lang.round(r)}%, ${q.lang.round(i)}%, ${o})`:`hsl(${q.lang.round(e)}, ${q.lang.round(r)}%, ${q.lang.round(i)}%)`}},io=wn;var Bn={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:t=>{t=t.toLowerCase();let e=Bn.colors[t];if(e)return kr.parse(e)},stringify:t=>{let e=kr.stringify(t);for(let r in Bn.colors)if(Bn.colors[r]===e)return r}},ml=Bn;var rp={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:t=>{let e=t.charCodeAt(0);if(e!==114&&e!==82)return;let r=t.match(rp.re);if(!r)return;let[,i,o,n,a,s,l,c,h]=r;return He.set({r:q.channel.clamp.r(o?parseFloat(i)*2.55:parseFloat(i)),g:q.channel.clamp.g(a?parseFloat(n)*2.55:parseFloat(n)),b:q.channel.clamp.b(l?parseFloat(s)*2.55:parseFloat(s)),a:c?q.channel.clamp.a(h?parseFloat(c)/100:parseFloat(c)):1},t)},stringify:t=>{let{r:e,g:r,b:i,a:o}=t;return o<1?`rgba(${q.lang.round(e)}, ${q.lang.round(r)}, ${q.lang.round(i)}, ${q.lang.round(o)})`:`rgb(${q.lang.round(e)}, ${q.lang.round(r)}, ${q.lang.round(i)})`}},oo=rp;var bC={format:{keyword:ml,hex:kr,rgb:oo,rgba:oo,hsl:io,hsla:io},parse:t=>{if(typeof t!="string")return t;let e=kr.parse(t)||oo.parse(t)||io.parse(t)||ml.parse(t);if(e)return e;throw new Error(`Unsupported color format: "${t}"`)},stringify:t=>!t.changed&&t.color?t.color:t.type.is(yt.HSL)||t.data.r===void 0?io.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?oo.stringify(t):kr.stringify(t)},_t=bC;var TC=t=>{let{r:e,g:r,b:i}=_t.parse(t),o=.2126*q.channel.toLinear(e)+.7152*q.channel.toLinear(r)+.0722*q.channel.toLinear(i);return q.lang.round(o)},ip=TC;var vC=t=>ip(t)>=.5,op=vC;var kC=t=>!op(t),Sr=kC;var SC=(t,e,r)=>{let i=_t.parse(t),o=i[e],n=q.channel.clamp[e](o+r);return o!==n&&(i[e]=n),_t.stringify(i)},An=SC;var wC=(t,e)=>An(t,"l",e),z=wC;var BC=(t,e)=>An(t,"l",-e),H=BC;var AC=(t,e)=>{let r=_t.parse(t);for(let i in e)r[i]=q.channel.clamp[i](e[i]);return _t.stringify(r)},Fn=AC;var FC=(t,e,r=0,i=1)=>{if(typeof t!="number")return Fn(t,{a:e});let o=He.set({r:q.channel.clamp.r(t),g:q.channel.clamp.g(e),b:q.channel.clamp.b(r),a:q.channel.clamp.a(i)});return _t.stringify(o)},Ye=FC;var LC=(t,e)=>q.lang.round(_t.parse(t)[e]),MC=LC;var EC=(t,e)=>{let r=_t.parse(t),i={};for(let o in e)e[o]&&(i[o]=r[o]+e[o]);return Fn(t,i)},m=EC;var OC=(t,e,r=50)=>{let{r:i,g:o,b:n,a}=_t.parse(t),{r:s,g:l,b:c,a:h}=_t.parse(e),f=r/100,u=f*2-1,p=a-h,_=((u*p===-1?u:(u+p)/(1+u*p))+1)/2,b=1-_,w=i*_+s*b,v=o*_+l*b,L=n*_+c*b,E=a*f+h*(1-f);return Ye(w,v,L,E)},np=OC;var IC=(t,e=100)=>{let r=_t.parse(t);return r.r=255-r.r,r.g=255-r.g,r.b=255-r.b,np(r,t,e)},M=IC;var DC=typeof global=="object"&&global&&global.Object===Object&&global,Ln=DC;var NC=typeof self=="object"&&self&&self.Object===Object&&self,PC=Ln||NC||Function("return this")(),pt=PC;var RC=pt.Symbol,ai=RC;var ap=Object.prototype,$C=ap.hasOwnProperty,zC=ap.toString,no=ai?ai.toStringTag:void 0;function qC(t){var e=$C.call(t,no),r=t[no];try{t[no]=void 0;var i=!0}catch{}var o=zC.call(t);return i&&(e?t[no]=r:delete t[no]),o}var sp=qC;var WC=Object.prototype,UC=WC.toString;function HC(t){return UC.call(t)}var lp=HC;var YC="[object Null]",jC="[object Undefined]",cp=ai?ai.toStringTag:void 0;function GC(t){return t==null?t===void 0?jC:YC:cp&&cp in Object(t)?sp(t):lp(t)}var ne=GC;function VC(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var Ut=VC;var XC="[object AsyncFunction]",KC="[object Function]",ZC="[object GeneratorFunction]",QC="[object Proxy]";function JC(t){if(!Ut(t))return!1;var e=ne(t);return e==KC||e==ZC||e==XC||e==QC}var si=JC;var t1=pt["__core-js_shared__"],Mn=t1;var up=function(){var t=/[^.]+$/.exec(Mn&&Mn.keys&&Mn.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function e1(t){return!!up&&up in t}var hp=e1;var r1=Function.prototype,i1=r1.toString;function o1(t){if(t!=null){try{return i1.call(t)}catch{}try{return t+""}catch{}}return""}var Fe=o1;var n1=/[\\^$.*+?()[\]{}|]/g,a1=/^\[object .+?Constructor\]$/,s1=Function.prototype,l1=Object.prototype,c1=s1.toString,u1=l1.hasOwnProperty,h1=RegExp("^"+c1.call(u1).replace(n1,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function f1(t){if(!Ut(t)||hp(t))return!1;var e=si(t)?h1:a1;return e.test(Fe(t))}var fp=f1;function p1(t,e){return t?.[e]}var pp=p1;function d1(t,e){var r=pp(t,e);return fp(r)?r:void 0}var Ht=d1;var m1=Ht(Object,"create"),Le=m1;function g1(){this.__data__=Le?Le(null):{},this.size=0}var dp=g1;function x1(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var mp=x1;var y1="__lodash_hash_undefined__",_1=Object.prototype,C1=_1.hasOwnProperty;function b1(t){var e=this.__data__;if(Le){var r=e[t];return r===y1?void 0:r}return C1.call(e,t)?e[t]:void 0}var gp=b1;var T1=Object.prototype,v1=T1.hasOwnProperty;function k1(t){var e=this.__data__;return Le?e[t]!==void 0:v1.call(e,t)}var xp=k1;var S1="__lodash_hash_undefined__";function w1(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Le&&e===void 0?S1:e,this}var yp=w1;function li(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e-1}var Tp=I1;function D1(t,e){var r=this.__data__,i=Ge(r,t);return i<0?(++this.size,r.push([t,e])):r[i][1]=e,this}var vp=D1;function ci(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e-1&&t%1==0&&t<=bb}var Dn=Tb;function vb(t){return t!=null&&Dn(t.length)&&!si(t)}var Qe=vb;function kb(t){return me(t)&&Qe(t)}var Kp=kb;function Sb(){return!1}var Zp=Sb;var td=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Qp=td&&typeof module=="object"&&module&&!module.nodeType&&module,wb=Qp&&Qp.exports===td,Jp=wb?pt.Buffer:void 0,Bb=Jp?Jp.isBuffer:void 0,Ab=Bb||Zp,di=Ab;var Fb="[object Object]",Lb=Function.prototype,Mb=Object.prototype,ed=Lb.toString,Eb=Mb.hasOwnProperty,Ob=ed.call(Object);function Ib(t){if(!me(t)||ne(t)!=Fb)return!1;var e=In(t);if(e===null)return!0;var r=Eb.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&ed.call(r)==Ob}var rd=Ib;var Db="[object Arguments]",Nb="[object Array]",Pb="[object Boolean]",Rb="[object Date]",$b="[object Error]",zb="[object Function]",qb="[object Map]",Wb="[object Number]",Ub="[object Object]",Hb="[object RegExp]",Yb="[object Set]",jb="[object String]",Gb="[object WeakMap]",Vb="[object ArrayBuffer]",Xb="[object DataView]",Kb="[object Float32Array]",Zb="[object Float64Array]",Qb="[object Int8Array]",Jb="[object Int16Array]",tT="[object Int32Array]",eT="[object Uint8Array]",rT="[object Uint8ClampedArray]",iT="[object Uint16Array]",oT="[object Uint32Array]",lt={};lt[Kb]=lt[Zb]=lt[Qb]=lt[Jb]=lt[tT]=lt[eT]=lt[rT]=lt[iT]=lt[oT]=!0;lt[Db]=lt[Nb]=lt[Vb]=lt[Pb]=lt[Xb]=lt[Rb]=lt[$b]=lt[zb]=lt[qb]=lt[Wb]=lt[Ub]=lt[Hb]=lt[Yb]=lt[jb]=lt[Gb]=!1;function nT(t){return me(t)&&Dn(t.length)&&!!lt[ne(t)]}var id=nT;function aT(t){return function(e){return t(e)}}var od=aT;var nd=typeof exports=="object"&&exports&&!exports.nodeType&&exports,lo=nd&&typeof module=="object"&&module&&!module.nodeType&&module,sT=lo&&lo.exports===nd,Cl=sT&&Ln.process,lT=function(){try{var t=lo&&lo.require&&lo.require("util").types;return t||Cl&&Cl.binding&&Cl.binding("util")}catch{}}(),bl=lT;var ad=bl&&bl.isTypedArray,cT=ad?od(ad):id,mi=cT;function uT(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}var co=uT;var hT=Object.prototype,fT=hT.hasOwnProperty;function pT(t,e,r){var i=t[e];(!(fT.call(t,e)&&je(i,r))||r===void 0&&!(e in t))&&pi(t,e,r)}var sd=pT;function dT(t,e,r,i){var o=!r;r||(r={});for(var n=-1,a=e.length;++n-1&&t%1==0&&t0){if(++e>=IT)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var Td=PT;var RT=Td(bd),vd=RT;function $T(t,e){return vd(_d(t,e,Rn),t+"")}var kd=$T;function zT(t,e,r){if(!Ut(r))return!1;var i=typeof e;return(i=="number"?Qe(r)&&Nn(e,r.length):i=="string"&&e in r)?je(r[e],t):!1}var Sd=zT;function qT(t){return kd(function(e,r){var i=-1,o=r.length,n=o>1?r[o-1]:void 0,a=o>2?r[2]:void 0;for(n=t.length>3&&typeof n=="function"?(o--,n):void 0,a&&Sd(r[0],r[1],a)&&(n=o<3?void 0:n,o=1),e=Object(e);++i0?Fr(yi,--Zt):0,xi--,dt===10&&(xi=1,Kn--),dt}function Qt(){return dt=Zt2||Tl(dt)>3?"":" "}function jd(t,e){for(;--e&&Qt()&&!(dt<48||dt>102||dt>57&&dt<65||dt>70&&dt<97););return Qn(t,ho()+(e<6&&Je()==32&&Qt()==32))}function vl(t){for(;Qt();)switch(dt){case t:return Zt;case 34:case 39:t!==34&&t!==39&&vl(dt);break;case 40:t===41&&vl(t);break;case 92:Qt();break}return Zt}function Gd(t,e){for(;Qt()&&t+dt!==47+10;)if(t+dt===42+42&&Je()===47)break;return"/*"+Qn(e,Zt-1)+"*"+uo(t===47?t:Qt())}function Vd(t){for(;!Tl(Je());)Qt();return Qn(t,Zt)}function Zd(t){return Hd(ta("",null,null,null,[""],t=Ud(t),0,[0],t))}function ta(t,e,r,i,o,n,a,s,l){for(var c=0,h=0,f=a,u=0,p=0,x=0,_=1,b=1,w=1,v=0,L="",E=o,I=n,A=i,y=L;b;)switch(x=v,v=Qt()){case 40:if(x!=108&&Fr(y,f-1)==58){$d(y+=Vn(Jn(v),"&","&\f"),"&\f")!=-1&&(w=-1);break}case 34:case 39:case 91:y+=Jn(v);break;case 9:case 10:case 13:case 32:y+=Yd(x);break;case 92:y+=jd(ho()-1,7);continue;case 47:switch(Je()){case 42:case 47:gi(lv(Gd(Qt(),ho()),e,r),l);break;default:y+="/"}break;case 123*_:s[c++]=ae(y)*w;case 125*_:case 59:case 0:switch(v){case 0:case 125:b=0;case 59+h:p>0&&ae(y)-f&&gi(p>32?Kd(y+";",i,r,f-1):Kd(Vn(y," ","")+";",i,r,f-2),l);break;case 59:y+=";";default:if(gi(A=Xd(y,e,r,c,h,o,s,L,E=[],I=[],f),n),v===123)if(h===0)ta(y,e,A,A,E,n,f,s,I);else switch(u===99&&Fr(y,3)===110?100:u){case 100:case 109:case 115:ta(t,A,A,i&&gi(Xd(t,A,A,0,0,o,s,L,o,E=[],f),I),o,I,f,s,i?E:I);break;default:ta(y,A,A,A,[""],I,0,s,I)}}c=h=p=0,_=w=1,L=y="",f=a;break;case 58:f=1+ae(y),p=x;default:if(_<1){if(v==123)--_;else if(v==125&&_++==0&&Wd()==125)continue}switch(y+=uo(v),v*_){case 38:w=h>0?1:(y+="\f",-1);break;case 44:s[c++]=(ae(y)-1)*w,w=1;break;case 64:Je()===45&&(y+=Jn(Qt())),u=Je(),h=f=ae(L=y+=Vd(ho())),v++;break;case 45:x===45&&ae(y)==2&&(_=0)}}return n}function Xd(t,e,r,i,o,n,a,s,l,c,h){for(var f=o-1,u=o===0?n:[""],p=Xn(u),x=0,_=0,b=0;x0?u[w]+" "+v:Vn(v,/&\f/g,u[w])))&&(l[b++]=L);return Zn(t,e,r,o===0?Yn:s,l,c,h)}function lv(t,e,r){return Zn(t,e,r,Hn,uo(qd()),Lr(t,2,-2),0)}function Kd(t,e,r,i){return Zn(t,e,r,jn,Lr(t,0,i),Lr(t,i+1,-1),i)}function ea(t,e){for(var r="",i=Xn(t),o=0;o{},debug:(...t)=>{},info:(...t)=>{},warn:(...t)=>{},error:(...t)=>{},fatal:(...t)=>{}},Dl=function(t="fatal"){let e=Me.fatal;typeof t=="string"?(t=t.toLowerCase(),t in Me&&(e=Me[t])):typeof t=="number"&&(e=t),Y.trace=()=>{},Y.debug=()=>{},Y.info=()=>{},Y.warn=()=>{},Y.error=()=>{},Y.fatal=()=>{},e<=Me.fatal&&(Y.fatal=console.error?console.error.bind(console,Jt("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",Jt("FATAL"))),e<=Me.error&&(Y.error=console.error?console.error.bind(console,Jt("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",Jt("ERROR"))),e<=Me.warn&&(Y.warn=console.warn?console.warn.bind(console,Jt("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",Jt("WARN"))),e<=Me.info&&(Y.info=console.info?console.info.bind(console,Jt("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",Jt("INFO"))),e<=Me.debug&&(Y.debug=console.debug?console.debug.bind(console,Jt("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Jt("DEBUG"))),e<=Me.trace&&(Y.trace=console.debug?console.debug.bind(console,Jt("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Jt("TRACE")))},Jt=t=>`%c${(0,mm.default)().format("ss.SSS")} : ${t} : `,ma=//gi,cv=t=>t?ym(t).replace(/\\n/g,"#br#").split("#br#"):[""],xm=t=>go.default.sanitize(t),Jd=(t,e)=>{var r;if(((r=e.flowchart)==null?void 0:r.htmlLabels)!==!1){let i=e.securityLevel;i==="antiscript"||i==="strict"?t=xm(t):i!=="loose"&&(t=ym(t),t=t.replace(//g,">"),t=t.replace(/=/g,"="),t=pv(t))}return t},xo=(t,e)=>t&&(e.dompurifyConfig?t=go.default.sanitize(Jd(t,e),e.dompurifyConfig).toString():t=go.default.sanitize(Jd(t,e),{FORBID_TAGS:["style"]}).toString(),t),uv=(t,e)=>typeof t=="string"?xo(t,e):t.flat().map(r=>xo(r,e)),hv=t=>ma.test(t),fv=t=>t.split(ma),pv=t=>t.replace(/#br#/g,"
      "),ym=t=>t.replace(ma,"#br#"),dv=t=>{let e="";return t&&(e=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,e=e.replaceAll(/\(/g,"\\("),e=e.replaceAll(/\)/g,"\\)")),e},_m=t=>!(t===!1||["false","null","0"].includes(String(t).trim().toLowerCase())),mv=function(...t){let e=t.filter(r=>!isNaN(r));return Math.max(...e)},gv=function(...t){let e=t.filter(r=>!isNaN(r));return Math.min(...e)},Xz=function(t){let e=t.split(/(,)/),r=[];for(let i=0;i0&&i+1Math.max(0,t.split(e).length-1),xv=(t,e)=>{let r=Al(t,"~"),i=Al(e,"~");return r===1&&i===1},yv=t=>{let e=Al(t,"~"),r=!1;if(e<=1)return t;e%2!==0&&t.startsWith("~")&&(t=t.substring(1),r=!0);let i=[...t],o=i.indexOf("~"),n=i.lastIndexOf("~");for(;o!==-1&&n!==-1&&o!==n;)i[o]="<",i[n]=">",o=i.indexOf("~"),n=i.lastIndexOf("~");return r&&i.unshift("~"),i.join("")},Nl={getRows:cv,sanitizeText:xo,sanitizeTextOrArray:uv,hasBreaks:hv,splitBreaks:fv,lineBreakRegex:ma,removeScript:xm,getUrl:dv,evaluate:_m,getMax:mv,getMin:gv},qt=(t,e)=>e?m(t,{s:-40,l:10}):m(t,{s:-40,l:-10}),ga="#ffffff",xa="#f2f2f2",_v=class{constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){var e,r,i,o,n,a,s,l,c,h,f;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||m(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||m(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||qt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||qt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||qt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||qt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||M(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||M(this.tertiaryColor),this.lineColor=this.lineColor||M(this.background),this.arrowheadColor=this.arrowheadColor||M(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?H(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||"grey",this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||H(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||M(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||z(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||m(this.primaryColor,{h:30}),this.cScale4=this.cScale4||m(this.primaryColor,{h:60}),this.cScale5=this.cScale5||m(this.primaryColor,{h:90}),this.cScale6=this.cScale6||m(this.primaryColor,{h:120}),this.cScale7=this.cScale7||m(this.primaryColor,{h:150}),this.cScale8=this.cScale8||m(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||m(this.primaryColor,{h:270}),this.cScale10=this.cScale10||m(this.primaryColor,{h:300}),this.cScale11=this.cScale11||m(this.primaryColor,{h:330}),this.darkMode)for(let p=0;p{this[i]=e[i]}),this.updateColors(),r.forEach(i=>{this[i]=e[i]})}},Cv=t=>{let e=new _v;return e.calculate(t),e},bv=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=z(this.primaryColor,16),this.tertiaryColor=m(this.primaryColor,{h:-160}),this.primaryBorderColor=M(this.background),this.secondaryBorderColor=qt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=qt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.lineColor=M(this.background),this.textColor=M(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=z(M("#323D47"),10),this.lineColor="calculated",this.border1="#81B1DB",this.border2=Ye(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.sectionBkgColor=H("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=H(this.sectionBkgColor,10),this.taskBorderColor=Ye(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=Ye(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){var e,r,i,o,n,a,s,l,c,h,f;this.secondBkg=z(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=z(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.mainContrastColor,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=z(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=this.darkTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=m(this.primaryColor,{h:64}),this.fillType3=m(this.secondaryColor,{h:64}),this.fillType4=m(this.primaryColor,{h:-64}),this.fillType5=m(this.secondaryColor,{h:-64}),this.fillType6=m(this.primaryColor,{h:128}),this.fillType7=m(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||m(this.primaryColor,{h:30}),this.cScale4=this.cScale4||m(this.primaryColor,{h:60}),this.cScale5=this.cScale5||m(this.primaryColor,{h:90}),this.cScale6=this.cScale6||m(this.primaryColor,{h:120}),this.cScale7=this.cScale7||m(this.primaryColor,{h:150}),this.cScale8=this.cScale8||m(this.primaryColor,{h:210}),this.cScale9=this.cScale9||m(this.primaryColor,{h:270}),this.cScale10=this.cScale10||m(this.primaryColor,{h:300}),this.cScale11=this.cScale11||m(this.primaryColor,{h:330});for(let u=0;u{this[i]=e[i]}),this.updateColors(),r.forEach(i=>{this[i]=e[i]})}},Tv=t=>{let e=new bv;return e.calculate(t),e},vv=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=m(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=m(this.primaryColor,{h:-160}),this.primaryBorderColor=qt(this.primaryColor,this.darkMode),this.secondaryBorderColor=qt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=qt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.lineColor=M(this.background),this.textColor=M(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#e8e8e8",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="grey",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.sectionBkgColor=Ye(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){var e,r,i,o,n,a,s,l,c,h,f;this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||m(this.primaryColor,{h:30}),this.cScale4=this.cScale4||m(this.primaryColor,{h:60}),this.cScale5=this.cScale5||m(this.primaryColor,{h:90}),this.cScale6=this.cScale6||m(this.primaryColor,{h:120}),this.cScale7=this.cScale7||m(this.primaryColor,{h:150}),this.cScale8=this.cScale8||m(this.primaryColor,{h:210}),this.cScale9=this.cScale9||m(this.primaryColor,{h:270}),this.cScale10=this.cScale10||m(this.primaryColor,{h:300}),this.cScale11=this.cScale11||m(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||H(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||H(this.tertiaryColor,40);for(let u=0;u{this[i]=e[i]}),this.updateColors(),r.forEach(i=>{this[i]=e[i]})}},kv=t=>{let e=new vv;return e.calculate(t),e},Sv=class{constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=z("#cde498",10),this.primaryBorderColor=qt(this.primaryColor,this.darkMode),this.secondaryBorderColor=qt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=qt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.primaryColor),this.lineColor=M(this.background),this.textColor=M(this.background),this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="grey",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,r,i,o,n,a,s,l,c,h,f;this.actorBorder=H(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||m(this.primaryColor,{h:30}),this.cScale4=this.cScale4||m(this.primaryColor,{h:60}),this.cScale5=this.cScale5||m(this.primaryColor,{h:90}),this.cScale6=this.cScale6||m(this.primaryColor,{h:120}),this.cScale7=this.cScale7||m(this.primaryColor,{h:150}),this.cScale8=this.cScale8||m(this.primaryColor,{h:210}),this.cScale9=this.cScale9||m(this.primaryColor,{h:270}),this.cScale10=this.cScale10||m(this.primaryColor,{h:300}),this.cScale11=this.cScale11||m(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||H(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||H(this.tertiaryColor,40);for(let u=0;u{this[i]=e[i]}),this.updateColors(),r.forEach(i=>{this[i]=e[i]})}},wv=t=>{let e=new Sv;return e.calculate(t),e},Fl=class{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=z(this.contrast,55),this.background="#ffffff",this.tertiaryColor=m(this.primaryColor,{h:-160}),this.primaryBorderColor=qt(this.primaryColor,this.darkMode),this.secondaryBorderColor=qt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=qt(this.tertiaryColor,this.darkMode),this.primaryTextColor=M(this.primaryColor),this.secondaryTextColor=M(this.secondaryColor),this.tertiaryTextColor=M(this.tertiaryColor),this.lineColor=M(this.background),this.textColor=M(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,r,i,o,n,a,s,l,c,h,f;this.secondBkg=z(this.contrast,55),this.border2=this.contrast,this.actorBorder=z(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.lineColor,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let u=0;u{this[i]=e[i]}),this.updateColors(),r.forEach(i=>{this[i]=e[i]})}},Bv=t=>{let e=new Fl;return e.calculate(t),e},Ie={base:{getThemeVariables:Cv},dark:{getThemeVariables:Tv},default:{getThemeVariables:kv},forest:{getThemeVariables:wv},neutral:{getThemeVariables:Bv}},Ee={flowchart:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,defaultRenderer:"dagre-wrapper",wrappingWidth:200},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"]},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:.75},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showTitle:!0,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},theme:"default",maxTextSize:5e4,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize"],deterministicIds:!1,fontSize:16},Cm={...Ee,deterministicIDSeed:void 0,themeCSS:void 0,themeVariables:Ie.default.getThemeVariables(),sequence:{...Ee.sequence,messageFont:function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},noteFont:function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},actorFont:function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}}},gantt:{...Ee.gantt,tickInterval:void 0,useWidth:void 0},c4:{...Ee.c4,useWidth:void 0,personFont:function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},external_personFont:function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},systemFont:function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},external_systemFont:function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},system_dbFont:function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},external_system_dbFont:function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},system_queueFont:function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},external_system_queueFont:function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},containerFont:function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},external_containerFont:function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},container_dbFont:function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},external_container_dbFont:function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},container_queueFont:function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},external_container_queueFont:function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},componentFont:function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},external_componentFont:function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},component_dbFont:function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},external_component_dbFont:function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},component_queueFont:function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},external_component_queueFont:function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},boundaryFont:function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},messageFont:function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}}},pie:{...Ee.pie,useWidth:984},xyChart:{...Ee.xyChart,useWidth:void 0},requirement:{...Ee.requirement,useWidth:void 0},gitGraph:{...Ee.gitGraph,useMaxWidth:!1},sankey:{...Ee.sankey,useMaxWidth:!1}},bm=(t,e="")=>Object.keys(t).reduce((r,i)=>Array.isArray(t[i])?r:typeof t[i]=="object"&&t[i]!==null?[...r,e+i,...bm(t[i],"")]:[...r,e+i],[]),Av=new Set(bm(Cm,"")),Fv=Cm,oa=t=>{if(Y.debug("sanitizeDirective called with",t),!(typeof t!="object"||t==null)){if(Array.isArray(t)){t.forEach(e=>oa(e));return}for(let e of Object.keys(t)){if(Y.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!Av.has(e)||t[e]==null){Y.debug("sanitize deleting key: ",e),delete t[e];continue}if(typeof t[e]=="object"){Y.debug("sanitizing object",e),oa(t[e]);continue}let r=["themeCSS","fontFamily","altFontFamily"];for(let i of r)e.includes(i)&&(Y.debug("sanitizing css option",e),t[e]=Lv(t[e]))}if(t.themeVariables)for(let e of Object.keys(t.themeVariables)){let r=t.themeVariables[e];r?.match&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(t.themeVariables[e]="")}Y.debug("After sanitization",t)}},Lv=t=>{let e=0,r=0;for(let i of t){if(e{for(let{id:e,detector:r,loader:i}of t)km(e,r,i)},km=(t,e,r)=>{bi[t]?Y.error(`Detector with key ${t} already exists`):bi[t]={detector:e,loader:r},Y.debug(`Detector with key ${t} added${r?" with loader":""}`)},Ev=t=>bi[t].loader,Ll=(t,e,{depth:r=2,clobber:i=!1}={})=>{let o={depth:r,clobber:i};return Array.isArray(e)&&!Array.isArray(t)?(e.forEach(n=>Ll(t,n,o)),t):Array.isArray(e)&&Array.isArray(t)?(e.forEach(n=>{t.includes(n)||t.push(n)}),t):t===void 0||r<=0?t!=null&&typeof t=="object"&&typeof e=="object"?Object.assign(t,e):e:(e!==void 0&&typeof t=="object"&&typeof e=="object"&&Object.keys(e).forEach(n=>{typeof e[n]=="object"&&(t[n]===void 0||typeof t[n]=="object")?(t[n]===void 0&&(t[n]=Array.isArray(e[n])?[]:{}),t[n]=Ll(t[n],e[n],{depth:r-1,clobber:i})):(i||typeof t[n]!="object"&&typeof e[n]!="object")&&(t[n]=e[n])}),t)},Dt=Ll,Ov="\u200B",Iv={curveBasis:$s,curveBasisClosed:Ws,curveBasisOpen:Us,curveBumpX:zs,curveBumpY:qs,curveBundle:Hs,curveCardinalClosed:js,curveCardinalOpen:Gs,curveCardinal:Ys,curveCatmullRomClosed:Xs,curveCatmullRomOpen:Ks,curveCatmullRom:Vs,curveLinear:ji,curveLinearClosed:Zs,curveMonotoneX:Js,curveMonotoneY:tl,curveNatural:el,curveStep:rl,curveStepAfter:ol,curveStepBefore:il},Dv=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Nv=function(t,e){let r=Sm(t,/(?:init\b)|(?:initialize\b)/),i={};if(Array.isArray(r)){let a=r.map(s=>s.args);oa(a),i=Dt(i,[...a])}else i=r.args;if(!i)return;let o=ya(t,e),n="config";return i[n]!==void 0&&(o==="flowchart-v2"&&(o="flowchart"),i[o]=i[n],delete i[n]),i},Sm=function(t,e=null){try{let r=new RegExp(`[%]{2}(?![{]${Dv.source})(?=[}][%]{2}).* -`,"ig");t=t.trim().replace(r,"").replace(/'/gm,'"'),Y.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${t}`);let i,o=[];for(;(i=fo.exec(t))!==null;)if(i.index===fo.lastIndex&&fo.lastIndex++,i&&!e||e&&i[1]&&i[1].match(e)||e&&i[2]&&i[2].match(e)){let n=i[1]?i[1]:i[2],a=i[3]?i[3].trim():i[4]?JSON.parse(i[4].trim()):null;o.push({type:n,args:a})}return o.length===0?{type:t,args:null}:o.length===1?o[0]:o}catch(r){return Y.error(`ERROR: ${r.message} - Unable to parse directive type: '${e}' based on the text: '${t}'`),{type:void 0,args:null}}},Pv=function(t){return t.replace(fo,"")},Rv=function(t,e){for(let[r,i]of e.entries())if(i.match(t))return r;return-1};function $v(t,e){if(!t)return e;let r=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return Iv[r]??e}function zv(t,e){let r=t.trim();if(r)return e.securityLevel!=="loose"?(0,gm.sanitizeUrl)(r):r}var qv=(t,...e)=>{let r=t.split("."),i=r.length-1,o=r[i],n=window;for(let a=0;a{r+=wm(o,e),e=o});let i=r/2;return Pl(t,i)}function Uv(t){return t.length===1?t[0]:Wv(t)}var tm=(t,e=2)=>{let r=Math.pow(10,e);return Math.round(t*r)/r},Pl=(t,e)=>{let r,i=e;for(let o of t){if(r){let n=wm(o,r);if(n=1)return{x:o.x,y:o.y};if(a>0&&a<1)return{x:tm((1-a)*r.x+a*o.x,5),y:tm((1-a)*r.y+a*o.y,5)}}}r=o}throw new Error("Could not find a suitable point for the given distance")},Hv=(t,e,r)=>{Y.info(`our points ${JSON.stringify(e)}`),e[0]!==r&&(e=e.reverse());let o=Pl(e,25),n=t?10:5,a=Math.atan2(e[0].y-o.y,e[0].x-o.x),s={x:0,y:0};return s.x=Math.sin(a)*n+(e[0].x+o.x)/2,s.y=-Math.cos(a)*n+(e[0].y+o.y)/2,s};function Yv(t,e,r){let i=structuredClone(r);Y.info("our points",i),e!=="start_left"&&e!=="start_right"&&i.reverse();let o=25+t,n=Pl(i,o),a=10+t*.5,s=Math.atan2(i[0].y-n.y,i[0].x-n.x),l={x:0,y:0};return e==="start_left"?(l.x=Math.sin(s+Math.PI)*a+(i[0].x+n.x)/2,l.y=-Math.cos(s+Math.PI)*a+(i[0].y+n.y)/2):e==="end_right"?(l.x=Math.sin(s-Math.PI)*a+(i[0].x+n.x)/2-5,l.y=-Math.cos(s-Math.PI)*a+(i[0].y+n.y)/2-5):e==="end_left"?(l.x=Math.sin(s)*a+(i[0].x+n.x)/2-5,l.y=-Math.cos(s)*a+(i[0].y+n.y)/2-5):(l.x=Math.sin(s)*a+(i[0].x+n.x)/2,l.y=-Math.cos(s)*a+(i[0].y+n.y)/2),l}function jv(t){let e="",r="";for(let i of t)i!==void 0&&(i.startsWith("color:")||i.startsWith("text-align:")?r=r+i+";":e=e+i+";");return{style:e,labelStyle:r}}var em=0,Gv=()=>(em++,"id-"+Math.random().toString(36).substr(2,12)+"-"+em);function Vv(t){let e="",r="0123456789abcdef",i=r.length;for(let o=0;oVv(t.length),Kv=function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},Zv=function(t,e){let r=e.text.replace(Nl.lineBreakRegex," "),[,i]=$l(e.fontSize),o=t.append("text");o.attr("x",e.x),o.attr("y",e.y),o.style("text-anchor",e.anchor),o.style("font-family",e.fontFamily),o.style("font-size",i),o.style("font-weight",e.fontWeight),o.attr("fill",e.fill),e.class!==void 0&&o.attr("class",e.class);let n=o.append("tspan");return n.attr("x",e.x+e.textMargin*2),n.attr("fill",e.fill),n.text(r),o},Qv=En((t,e,r)=>{if(!t||(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"
      "},r),Nl.lineBreakRegex.test(t)))return t;let i=t.split(" "),o=[],n="";return i.forEach((a,s)=>{let l=aa(`${a} `,r),c=aa(n,r);if(l>e){let{hyphenatedStrings:u,remainingWord:p}=Jv(a,e,"-",r);o.push(n,...u),n=p}else c+l>=e?(o.push(n),n=a):n=[n,a].filter(Boolean).join(" ");s+1===i.length&&o.push(n)}),o.filter(a=>a!=="").join(r.joinWith)},(t,e,r)=>`${t}${e}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),Jv=En((t,e,r="-",i)=>{i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},i);let o=[...t],n=[],a="";return o.forEach((s,l)=>{let c=`${a}${s}`;if(aa(c,i)>=e){let f=l+1,u=o.length===f,p=`${c}${r}`;n.push(u?c:p),a=""}else a=c}),{hyphenatedStrings:n,remainingWord:a}},(t,e,r="-",i)=>`${t}${e}${r}${i.fontSize}${i.fontWeight}${i.fontFamily}`);function tk(t,e){return Rl(t,e).height}function aa(t,e){return Rl(t,e).width}var Rl=En((t,e)=>{let{fontSize:r=12,fontFamily:i="Arial",fontWeight:o=400}=e;if(!t)return{width:0,height:0};let[,n]=$l(r),a=["sans-serif",i],s=t.split(Nl.lineBreakRegex),l=[],c=Wt("body");if(!c.remove)return{width:0,height:0,lineHeight:0};let h=c.append("svg");for(let u of a){let p=0,x={width:0,height:0,lineHeight:0};for(let _ of s){let b=Kv();b.text=_||Ov;let w=Zv(h,b).style("font-size",n).style("font-weight",o).style("font-family",u),v=(w._groups||w)[0][0].getBBox();if(v.width===0&&v.height===0)throw new Error("svg element not in render tree");x.width=Math.round(Math.max(x.width,v.width)),p=Math.round(v.height),x.height+=p,x.lineHeight=Math.round(Math.max(x.lineHeight,p))}l.push(x)}h.remove();let f=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[f]},(t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`),Ml=class{constructor(e=!1,r){this.count=0,this.count=r?r.length:0,this.next=e?()=>this.count++:()=>Date.now()}},ra,ek=function(t){return ra=ra||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),ra.innerHTML=t,unescape(ra.textContent)};function Bm(t){return"str"in t}var rk=(t,e,r,i)=>{var o;if(!i)return;let n=(o=t.node())==null?void 0:o.getBBox();n&&t.append("text").text(i).attr("x",n.x+n.width/2).attr("y",-r).attr("class",e)},$l=t=>{if(typeof t=="number")return[t,t+"px"];let e=parseInt(t??"",10);return Number.isNaN(e)?[void 0,void 0]:t===String(e)?[e,t+"px"]:[e,t]};function Am(t,e){return Bd({},t,e)}var po={assignWithDepth:Dt,wrapLabel:Qv,calculateTextHeight:tk,calculateTextWidth:aa,calculateTextDimensions:Rl,cleanAndMerge:Am,detectInit:Nv,detectDirective:Sm,isSubstringInArray:Rv,interpolateToCurve:$v,calcLabelPosition:Uv,calcCardinalityPosition:Hv,calcTerminalLabelPosition:Yv,formatUrl:zv,getStylesFromArray:jv,generateId:Gv,random:Xv,runFunc:qv,entityDecode:ek,insertTitle:rk,parseFontSize:$l,InitIDGenerator:Ml},rm="10.6.0",Ti=Object.freeze(Fv),Yt=Dt({},Ti),Fm,vi=[],mo=Dt({},Ti),_a=(t,e)=>{let r=Dt({},t),i={};for(let o of e)Em(o),i=Dt(i,o);if(r=Dt(r,i),i.theme&&i.theme in Ie){let o=Dt({},Fm),n=Dt(o.themeVariables||{},i.themeVariables);r.theme&&r.theme in Ie&&(r.themeVariables=Ie[r.theme].getThemeVariables(n))}return mo=r,Om(mo),mo},ik=t=>(Yt=Dt({},Ti),Yt=Dt(Yt,t),t.theme&&Ie[t.theme]&&(Yt.themeVariables=Ie[t.theme].getThemeVariables(t.themeVariables)),_a(Yt,vi),Yt),ok=t=>{Fm=Dt({},t)},nk=t=>(Yt=Dt(Yt,t),_a(Yt,vi),Yt),Lm=()=>Dt({},Yt),Mm=t=>(Om(t),Dt(mo,t),xe()),xe=()=>Dt({},mo),Em=t=>{t&&(["secure",...Yt.secure??[]].forEach(e=>{Object.hasOwn(t,e)&&(Y.debug(`Denied attempt to modify a secure key ${e}`,t[e]),delete t[e])}),Object.keys(t).forEach(e=>{e.startsWith("__")&&delete t[e]}),Object.keys(t).forEach(e=>{typeof t[e]=="string"&&(t[e].includes("<")||t[e].includes(">")||t[e].includes("url(data:"))&&delete t[e],typeof t[e]=="object"&&Em(t[e])}))},ak=t=>{oa(t),t.fontFamily&&(!t.themeVariables||!t.themeVariables.fontFamily)&&(t.themeVariables={fontFamily:t.fontFamily}),vi.push(t),_a(Yt,vi)},sa=(t=Yt)=>{vi=[],_a(t,vi)},sk={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},im={},lk=t=>{im[t]||(Y.warn(sk[t]),im[t]=!0)},Om=t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&&lk("LAZY_LOAD_DEPRECATED")},Im="c4",ck=t=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(t),uk=async()=>{let{diagram:t}=await import("./c4Diagram-d0fbc5ce-BO64XHDH.min.js");return{id:Im,diagram:t}},hk={id:Im,detector:ck,loader:uk},fk=hk,Dm="flowchart",pk=(t,e)=>{var r,i;return((r=e?.flowchart)==null?void 0:r.defaultRenderer)==="dagre-wrapper"||((i=e?.flowchart)==null?void 0:i.defaultRenderer)==="elk"?!1:/^\s*graph/.test(t)},dk=async()=>{let{diagram:t}=await import("./flowDiagram-7ea5b25a-BASH27KO.min.js");return{id:Dm,diagram:t}},mk={id:Dm,detector:pk,loader:dk},gk=mk,Nm="flowchart-v2",xk=(t,e)=>{var r,i,o;return((r=e?.flowchart)==null?void 0:r.defaultRenderer)==="dagre-d3"||((i=e?.flowchart)==null?void 0:i.defaultRenderer)==="elk"?!1:/^\s*graph/.test(t)&&((o=e?.flowchart)==null?void 0:o.defaultRenderer)==="dagre-wrapper"?!0:/^\s*flowchart/.test(t)},yk=async()=>{let{diagram:t}=await import("./flowDiagram-v2-855bc5b3-D2CE3C4X.min.js");return{id:Nm,diagram:t}},_k={id:Nm,detector:xk,loader:yk},Ck=_k,Pm="er",bk=t=>/^\s*erDiagram/.test(t),Tk=async()=>{let{diagram:t}=await import("./erDiagram-9d236eb7-DEGG5JSY.min.js");return{id:Pm,diagram:t}},vk={id:Pm,detector:bk,loader:Tk},kk=vk,Rm="gitGraph",Sk=t=>/^\s*gitGraph/.test(t),wk=async()=>{let{diagram:t}=await import("./gitGraphDiagram-99d0ae7c-FHU6ER43.min.js");return{id:Rm,diagram:t}},Bk={id:Rm,detector:Sk,loader:wk},Ak=Bk,$m="gantt",Fk=t=>/^\s*gantt/.test(t),Lk=async()=>{let{diagram:t}=await import("./ganttDiagram-9b5ea136-4ILWAMFW.min.js");return{id:$m,diagram:t}},Mk={id:$m,detector:Fk,loader:Lk},Ek=Mk,zm="info",Ok=t=>/^\s*info/.test(t),Ik=async()=>{let{diagram:t}=await import("./infoDiagram-736b4530-NKVZQFCX.min.js");return{id:zm,diagram:t}},Dk={id:zm,detector:Ok,loader:Ik},qm="pie",Nk=t=>/^\s*pie/.test(t),Pk=async()=>{let{diagram:t}=await import("./pieDiagram-dbbf0591-BNRC6QVC.min.js");return{id:qm,diagram:t}},Rk={id:qm,detector:Nk,loader:Pk},Wm="quadrantChart",$k=t=>/^\s*quadrantChart/.test(t),zk=async()=>{let{diagram:t}=await import("./quadrantDiagram-4d7f4fd6-MBHVARO6.min.js");return{id:Wm,diagram:t}},qk={id:Wm,detector:$k,loader:zk},Wk=qk,Um="xychart",Uk=t=>/^\s*xychart-beta/.test(t),Hk=async()=>{let{diagram:t}=await import("./xychartDiagram-2b33534f-MU4MD3QO.min.js");return{id:Um,diagram:t}},Yk={id:Um,detector:Uk,loader:Hk},jk=Yk,Hm="requirement",Gk=t=>/^\s*requirement(Diagram)?/.test(t),Vk=async()=>{let{diagram:t}=await import("./requirementDiagram-6fc4c22a-YME22P5Q.min.js");return{id:Hm,diagram:t}},Xk={id:Hm,detector:Gk,loader:Vk},Kk=Xk,Ym="sequence",Zk=t=>/^\s*sequenceDiagram/.test(t),Qk=async()=>{let{diagram:t}=await import("./sequenceDiagram-b655622a-SKWXQXA7.min.js");return{id:Ym,diagram:t}},Jk={id:Ym,detector:Zk,loader:Qk},tS=Jk,jm="class",eS=(t,e)=>{var r;return((r=e?.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*classDiagram/.test(t)},rS=async()=>{let{diagram:t}=await import("./classDiagram-936ed81e-YM34DHJU.min.js");return{id:jm,diagram:t}},iS={id:jm,detector:eS,loader:rS},oS=iS,Gm="classDiagram",nS=(t,e)=>{var r;return/^\s*classDiagram/.test(t)&&((r=e?.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!0:/^\s*classDiagram-v2/.test(t)},aS=async()=>{let{diagram:t}=await import("./classDiagram-v2-c3cb15f1-KNJLQSSI.min.js");return{id:Gm,diagram:t}},sS={id:Gm,detector:nS,loader:aS},lS=sS,Vm="state",cS=(t,e)=>{var r;return((r=e?.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(t)},uS=async()=>{let{diagram:t}=await import("./stateDiagram-59f0c015-YODGNLI6.min.js");return{id:Vm,diagram:t}},hS={id:Vm,detector:cS,loader:uS},fS=hS,Xm="stateDiagram",pS=(t,e)=>{var r;return!!(/^\s*stateDiagram-v2/.test(t)||/^\s*stateDiagram/.test(t)&&((r=e?.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper")},dS=async()=>{let{diagram:t}=await import("./stateDiagram-v2-2b26beab-JPDPS7HM.min.js");return{id:Xm,diagram:t}},mS={id:Xm,detector:pS,loader:dS},gS=mS,Km="journey",xS=t=>/^\s*journey/.test(t),yS=async()=>{let{diagram:t}=await import("./journeyDiagram-df861f2b-HF6YCQV7.min.js");return{id:Km,diagram:t}},_S={id:Km,detector:xS,loader:yS},CS=_S,bS=function(t,e){for(let r of e)t.attr(r[0],r[1])},TS=function(t,e,r){let i=new Map;return r?(i.set("width","100%"),i.set("style",`max-width: ${e}px;`)):(i.set("height",t),i.set("width",e)),i},Zm=function(t,e,r,i){let o=TS(e,r,i);bS(t,o)},vS=function(t,e,r,i){let o=e.node().getBBox(),n=o.width,a=o.height;Y.info(`SVG bounds: ${n}x${a}`,o);let s=0,l=0;Y.info(`Graph bounds: ${s}x${l}`,t),s=n+r*2,l=a+r*2,Y.info(`Calculated bounds: ${s}x${l}`),Zm(e,l,s,i);let c=`${o.x-r} ${o.y-r} ${o.width+2*r} ${o.height+2*r}`;e.attr("viewBox",c)},ia={},kS=(t,e,r)=>{let i="";return t in ia&&ia[t]?i=ia[t](r):Y.warn(`No theme found for ${t}`),` & { +`,"ig");t=t.trim().replace(r,"").replace(/'/gm,'"'),Y.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${t}`);let i,o=[];for(;(i=fo.exec(t))!==null;)if(i.index===fo.lastIndex&&fo.lastIndex++,i&&!e||e&&i[1]&&i[1].match(e)||e&&i[2]&&i[2].match(e)){let n=i[1]?i[1]:i[2],a=i[3]?i[3].trim():i[4]?JSON.parse(i[4].trim()):null;o.push({type:n,args:a})}return o.length===0?{type:t,args:null}:o.length===1?o[0]:o}catch(r){return Y.error(`ERROR: ${r.message} - Unable to parse directive type: '${e}' based on the text: '${t}'`),{type:void 0,args:null}}},Pv=function(t){return t.replace(fo,"")},Rv=function(t,e){for(let[r,i]of e.entries())if(i.match(t))return r;return-1};function $v(t,e){if(!t)return e;let r=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return Iv[r]??e}function zv(t,e){let r=t.trim();if(r)return e.securityLevel!=="loose"?(0,gm.sanitizeUrl)(r):r}var qv=(t,...e)=>{let r=t.split("."),i=r.length-1,o=r[i],n=window;for(let a=0;a{r+=wm(o,e),e=o});let i=r/2;return Pl(t,i)}function Uv(t){return t.length===1?t[0]:Wv(t)}var tm=(t,e=2)=>{let r=Math.pow(10,e);return Math.round(t*r)/r},Pl=(t,e)=>{let r,i=e;for(let o of t){if(r){let n=wm(o,r);if(n=1)return{x:o.x,y:o.y};if(a>0&&a<1)return{x:tm((1-a)*r.x+a*o.x,5),y:tm((1-a)*r.y+a*o.y,5)}}}r=o}throw new Error("Could not find a suitable point for the given distance")},Hv=(t,e,r)=>{Y.info(`our points ${JSON.stringify(e)}`),e[0]!==r&&(e=e.reverse());let o=Pl(e,25),n=t?10:5,a=Math.atan2(e[0].y-o.y,e[0].x-o.x),s={x:0,y:0};return s.x=Math.sin(a)*n+(e[0].x+o.x)/2,s.y=-Math.cos(a)*n+(e[0].y+o.y)/2,s};function Yv(t,e,r){let i=structuredClone(r);Y.info("our points",i),e!=="start_left"&&e!=="start_right"&&i.reverse();let o=25+t,n=Pl(i,o),a=10+t*.5,s=Math.atan2(i[0].y-n.y,i[0].x-n.x),l={x:0,y:0};return e==="start_left"?(l.x=Math.sin(s+Math.PI)*a+(i[0].x+n.x)/2,l.y=-Math.cos(s+Math.PI)*a+(i[0].y+n.y)/2):e==="end_right"?(l.x=Math.sin(s-Math.PI)*a+(i[0].x+n.x)/2-5,l.y=-Math.cos(s-Math.PI)*a+(i[0].y+n.y)/2-5):e==="end_left"?(l.x=Math.sin(s)*a+(i[0].x+n.x)/2-5,l.y=-Math.cos(s)*a+(i[0].y+n.y)/2-5):(l.x=Math.sin(s)*a+(i[0].x+n.x)/2,l.y=-Math.cos(s)*a+(i[0].y+n.y)/2),l}function jv(t){let e="",r="";for(let i of t)i!==void 0&&(i.startsWith("color:")||i.startsWith("text-align:")?r=r+i+";":e=e+i+";");return{style:e,labelStyle:r}}var em=0,Gv=()=>(em++,"id-"+Math.random().toString(36).substr(2,12)+"-"+em);function Vv(t){let e="",r="0123456789abcdef",i=r.length;for(let o=0;oVv(t.length),Kv=function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},Zv=function(t,e){let r=e.text.replace(Nl.lineBreakRegex," "),[,i]=$l(e.fontSize),o=t.append("text");o.attr("x",e.x),o.attr("y",e.y),o.style("text-anchor",e.anchor),o.style("font-family",e.fontFamily),o.style("font-size",i),o.style("font-weight",e.fontWeight),o.attr("fill",e.fill),e.class!==void 0&&o.attr("class",e.class);let n=o.append("tspan");return n.attr("x",e.x+e.textMargin*2),n.attr("fill",e.fill),n.text(r),o},Qv=En((t,e,r)=>{if(!t||(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"
      "},r),Nl.lineBreakRegex.test(t)))return t;let i=t.split(" "),o=[],n="";return i.forEach((a,s)=>{let l=aa(`${a} `,r),c=aa(n,r);if(l>e){let{hyphenatedStrings:u,remainingWord:p}=Jv(a,e,"-",r);o.push(n,...u),n=p}else c+l>=e?(o.push(n),n=a):n=[n,a].filter(Boolean).join(" ");s+1===i.length&&o.push(n)}),o.filter(a=>a!=="").join(r.joinWith)},(t,e,r)=>`${t}${e}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),Jv=En((t,e,r="-",i)=>{i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},i);let o=[...t],n=[],a="";return o.forEach((s,l)=>{let c=`${a}${s}`;if(aa(c,i)>=e){let f=l+1,u=o.length===f,p=`${c}${r}`;n.push(u?c:p),a=""}else a=c}),{hyphenatedStrings:n,remainingWord:a}},(t,e,r="-",i)=>`${t}${e}${r}${i.fontSize}${i.fontWeight}${i.fontFamily}`);function tk(t,e){return Rl(t,e).height}function aa(t,e){return Rl(t,e).width}var Rl=En((t,e)=>{let{fontSize:r=12,fontFamily:i="Arial",fontWeight:o=400}=e;if(!t)return{width:0,height:0};let[,n]=$l(r),a=["sans-serif",i],s=t.split(Nl.lineBreakRegex),l=[],c=Wt("body");if(!c.remove)return{width:0,height:0,lineHeight:0};let h=c.append("svg");for(let u of a){let p=0,x={width:0,height:0,lineHeight:0};for(let _ of s){let b=Kv();b.text=_||Ov;let w=Zv(h,b).style("font-size",n).style("font-weight",o).style("font-family",u),v=(w._groups||w)[0][0].getBBox();if(v.width===0&&v.height===0)throw new Error("svg element not in render tree");x.width=Math.round(Math.max(x.width,v.width)),p=Math.round(v.height),x.height+=p,x.lineHeight=Math.round(Math.max(x.lineHeight,p))}l.push(x)}h.remove();let f=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[f]},(t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`),Ml=class{constructor(e=!1,r){this.count=0,this.count=r?r.length:0,this.next=e?()=>this.count++:()=>Date.now()}},ra,ek=function(t){return ra=ra||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),ra.innerHTML=t,unescape(ra.textContent)};function Bm(t){return"str"in t}var rk=(t,e,r,i)=>{var o;if(!i)return;let n=(o=t.node())==null?void 0:o.getBBox();n&&t.append("text").text(i).attr("x",n.x+n.width/2).attr("y",-r).attr("class",e)},$l=t=>{if(typeof t=="number")return[t,t+"px"];let e=parseInt(t??"",10);return Number.isNaN(e)?[void 0,void 0]:t===String(e)?[e,t+"px"]:[e,t]};function Am(t,e){return Bd({},t,e)}var po={assignWithDepth:Dt,wrapLabel:Qv,calculateTextHeight:tk,calculateTextWidth:aa,calculateTextDimensions:Rl,cleanAndMerge:Am,detectInit:Nv,detectDirective:Sm,isSubstringInArray:Rv,interpolateToCurve:$v,calcLabelPosition:Uv,calcCardinalityPosition:Hv,calcTerminalLabelPosition:Yv,formatUrl:zv,getStylesFromArray:jv,generateId:Gv,random:Xv,runFunc:qv,entityDecode:ek,insertTitle:rk,parseFontSize:$l,InitIDGenerator:Ml},rm="10.6.1",Ti=Object.freeze(Fv),Yt=Dt({},Ti),Fm,vi=[],mo=Dt({},Ti),_a=(t,e)=>{let r=Dt({},t),i={};for(let o of e)Em(o),i=Dt(i,o);if(r=Dt(r,i),i.theme&&i.theme in Ie){let o=Dt({},Fm),n=Dt(o.themeVariables||{},i.themeVariables);r.theme&&r.theme in Ie&&(r.themeVariables=Ie[r.theme].getThemeVariables(n))}return mo=r,Om(mo),mo},ik=t=>(Yt=Dt({},Ti),Yt=Dt(Yt,t),t.theme&&Ie[t.theme]&&(Yt.themeVariables=Ie[t.theme].getThemeVariables(t.themeVariables)),_a(Yt,vi),Yt),ok=t=>{Fm=Dt({},t)},nk=t=>(Yt=Dt(Yt,t),_a(Yt,vi),Yt),Lm=()=>Dt({},Yt),Mm=t=>(Om(t),Dt(mo,t),xe()),xe=()=>Dt({},mo),Em=t=>{t&&(["secure",...Yt.secure??[]].forEach(e=>{Object.hasOwn(t,e)&&(Y.debug(`Denied attempt to modify a secure key ${e}`,t[e]),delete t[e])}),Object.keys(t).forEach(e=>{e.startsWith("__")&&delete t[e]}),Object.keys(t).forEach(e=>{typeof t[e]=="string"&&(t[e].includes("<")||t[e].includes(">")||t[e].includes("url(data:"))&&delete t[e],typeof t[e]=="object"&&Em(t[e])}))},ak=t=>{oa(t),t.fontFamily&&(!t.themeVariables||!t.themeVariables.fontFamily)&&(t.themeVariables={fontFamily:t.fontFamily}),vi.push(t),_a(Yt,vi)},sa=(t=Yt)=>{vi=[],_a(t,vi)},sk={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},im={},lk=t=>{im[t]||(Y.warn(sk[t]),im[t]=!0)},Om=t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&&lk("LAZY_LOAD_DEPRECATED")},Im="c4",ck=t=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(t),uk=async()=>{let{diagram:t}=await import("./c4Diagram-817c8e44-DEM7FJ4Q.min.js");return{id:Im,diagram:t}},hk={id:Im,detector:ck,loader:uk},fk=hk,Dm="flowchart",pk=(t,e)=>{var r,i;return((r=e?.flowchart)==null?void 0:r.defaultRenderer)==="dagre-wrapper"||((i=e?.flowchart)==null?void 0:i.defaultRenderer)==="elk"?!1:/^\s*graph/.test(t)},dk=async()=>{let{diagram:t}=await import("./flowDiagram-61eb444c-S7V4ZUD5.min.js");return{id:Dm,diagram:t}},mk={id:Dm,detector:pk,loader:dk},gk=mk,Nm="flowchart-v2",xk=(t,e)=>{var r,i,o;return((r=e?.flowchart)==null?void 0:r.defaultRenderer)==="dagre-d3"||((i=e?.flowchart)==null?void 0:i.defaultRenderer)==="elk"?!1:/^\s*graph/.test(t)&&((o=e?.flowchart)==null?void 0:o.defaultRenderer)==="dagre-wrapper"?!0:/^\s*flowchart/.test(t)},yk=async()=>{let{diagram:t}=await import("./flowDiagram-v2-2f8f667a-QXWUVY6B.min.js");return{id:Nm,diagram:t}},_k={id:Nm,detector:xk,loader:yk},Ck=_k,Pm="er",bk=t=>/^\s*erDiagram/.test(t),Tk=async()=>{let{diagram:t}=await import("./erDiagram-9cfc3649-YLLW2FE4.min.js");return{id:Pm,diagram:t}},vk={id:Pm,detector:bk,loader:Tk},kk=vk,Rm="gitGraph",Sk=t=>/^\s*gitGraph/.test(t),wk=async()=>{let{diagram:t}=await import("./gitGraphDiagram-6b463803-STHEHXBB.min.js");return{id:Rm,diagram:t}},Bk={id:Rm,detector:Sk,loader:wk},Ak=Bk,$m="gantt",Fk=t=>/^\s*gantt/.test(t),Lk=async()=>{let{diagram:t}=await import("./ganttDiagram-db6931fb-2YH7L6GA.min.js");return{id:$m,diagram:t}},Mk={id:$m,detector:Fk,loader:Lk},Ek=Mk,zm="info",Ok=t=>/^\s*info/.test(t),Ik=async()=>{let{diagram:t}=await import("./infoDiagram-a336098b-BUO4526A.min.js");return{id:zm,diagram:t}},Dk={id:zm,detector:Ok,loader:Ik},qm="pie",Nk=t=>/^\s*pie/.test(t),Pk=async()=>{let{diagram:t}=await import("./pieDiagram-a5166659-D5OB26DI.min.js");return{id:qm,diagram:t}},Rk={id:qm,detector:Nk,loader:Pk},Wm="quadrantChart",$k=t=>/^\s*quadrantChart/.test(t),zk=async()=>{let{diagram:t}=await import("./quadrantDiagram-6c355bbc-72UBHSWW.min.js");return{id:Wm,diagram:t}},qk={id:Wm,detector:$k,loader:zk},Wk=qk,Um="xychart",Uk=t=>/^\s*xychart-beta/.test(t),Hk=async()=>{let{diagram:t}=await import("./xychartDiagram-f746c04c-4VQWTKKE.min.js");return{id:Um,diagram:t}},Yk={id:Um,detector:Uk,loader:Hk},jk=Yk,Hm="requirement",Gk=t=>/^\s*requirement(Diagram)?/.test(t),Vk=async()=>{let{diagram:t}=await import("./requirementDiagram-4038b16c-AE4CLIVN.min.js");return{id:Hm,diagram:t}},Xk={id:Hm,detector:Gk,loader:Vk},Kk=Xk,Ym="sequence",Zk=t=>/^\s*sequenceDiagram/.test(t),Qk=async()=>{let{diagram:t}=await import("./sequenceDiagram-465a088a-SRYNR4EQ.min.js");return{id:Ym,diagram:t}},Jk={id:Ym,detector:Zk,loader:Qk},tS=Jk,jm="class",eS=(t,e)=>{var r;return((r=e?.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*classDiagram/.test(t)},rS=async()=>{let{diagram:t}=await import("./classDiagram-48ab76fb-DDANGYBP.min.js");return{id:jm,diagram:t}},iS={id:jm,detector:eS,loader:rS},oS=iS,Gm="classDiagram",nS=(t,e)=>{var r;return/^\s*classDiagram/.test(t)&&((r=e?.class)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!0:/^\s*classDiagram-v2/.test(t)},aS=async()=>{let{diagram:t}=await import("./classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js");return{id:Gm,diagram:t}},sS={id:Gm,detector:nS,loader:aS},lS=sS,Vm="state",cS=(t,e)=>{var r;return((r=e?.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(t)},uS=async()=>{let{diagram:t}=await import("./stateDiagram-b620d43f-JKLORD4W.min.js");return{id:Vm,diagram:t}},hS={id:Vm,detector:cS,loader:uS},fS=hS,Xm="stateDiagram",pS=(t,e)=>{var r;return!!(/^\s*stateDiagram-v2/.test(t)||/^\s*stateDiagram/.test(t)&&((r=e?.state)==null?void 0:r.defaultRenderer)==="dagre-wrapper")},dS=async()=>{let{diagram:t}=await import("./stateDiagram-v2-2671c3d1-TFICO4HL.min.js");return{id:Xm,diagram:t}},mS={id:Xm,detector:pS,loader:dS},gS=mS,Km="journey",xS=t=>/^\s*journey/.test(t),yS=async()=>{let{diagram:t}=await import("./journeyDiagram-deae3313-3I2YX5JS.min.js");return{id:Km,diagram:t}},_S={id:Km,detector:xS,loader:yS},CS=_S,bS=function(t,e){for(let r of e)t.attr(r[0],r[1])},TS=function(t,e,r){let i=new Map;return r?(i.set("width","100%"),i.set("style",`max-width: ${e}px;`)):(i.set("height",t),i.set("width",e)),i},Zm=function(t,e,r,i){let o=TS(e,r,i);bS(t,o)},vS=function(t,e,r,i){let o=e.node().getBBox(),n=o.width,a=o.height;Y.info(`SVG bounds: ${n}x${a}`,o);let s=0,l=0;Y.info(`Graph bounds: ${s}x${l}`,t),s=n+r*2,l=a+r*2,Y.info(`Calculated bounds: ${s}x${l}`),Zm(e,l,s,i);let c=`${o.x-r} ${o.y-r} ${o.width+2*r} ${o.height+2*r}`;e.attr("viewBox",c)},ia={},kS=(t,e,r)=>{let i="";return t in ia&&ia[t]?i=ia[t](r):Y.warn(`No theme found for ${t}`),` & { font-family: ${r.fontFamily}; font-size: ${r.fontSize}; fill: ${r.textColor} @@ -57,7 +57,7 @@ import{b as za,d as qa}from"./chunk-P42HNYSU.min.js";var Tc=za((Wa,Ua)=>{(functi ${e} `},SS=(t,e)=>{e!==void 0&&(ia[t]=e)},wS=kS,zl="",ql="",Wl="",Ul=t=>xo(t,xe()),BS=()=>{zl="",Wl="",ql=""},AS=t=>{zl=Ul(t).replace(/^\s+/g,"")},FS=()=>zl,LS=t=>{Wl=Ul(t).replace(/\n\s+/g,` `)},MS=()=>Wl,ES=t=>{ql=Ul(t)},OS=()=>ql,IS=Object.freeze(Object.defineProperty({__proto__:null,clear:BS,getAccDescription:MS,getAccTitle:FS,getDiagramTitle:OS,setAccDescription:LS,setAccTitle:AS,setDiagramTitle:ES},Symbol.toStringTag,{value:"Module"})),DS=Y,NS=Dl,Hl=xe,tq=Mm,eq=Ti,PS=t=>xo(t,Hl()),RS=vS,$S=()=>IS,la={},ca=(t,e,r)=>{var i;if(la[t])throw new Error(`Diagram ${t} already registered.`);la[t]=e,r&&km(t,r),SS(t,e.styles),(i=e.injectUtils)==null||i.call(e,DS,NS,Hl,PS,RS,$S(),()=>{})},Yl=t=>{if(t in la)return la[t];throw new El(t)},El=class extends Error{constructor(e){super(`Diagram ${e} not found.`)}},zS=t=>{var e;let{securityLevel:r}=Hl(),i=Wt("body");if(r==="sandbox"){let a=((e=Wt(`#i${t}`).node())==null?void 0:e.contentDocument)??document;i=Wt(a.body)}return i.select(`#${t}`)},qS=(t,e,r)=>{Y.debug(`renering svg for syntax error -`);let i=zS(e);i.attr("viewBox","0 0 2412 512"),Zm(i,100,512,!0);let o=i.append("g");o.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),o.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),o.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),o.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),o.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),o.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),o.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),o.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${r}`)},Qm={draw:qS},WS=Qm,US={db:{},renderer:Qm,parser:{parser:{yy:{}},parse:()=>{}}},HS=US,Jm="flowchart-elk",YS=(t,e)=>{var r;return!!(/^\s*flowchart-elk/.test(t)||/^\s*flowchart|graph/.test(t)&&((r=e?.flowchart)==null?void 0:r.defaultRenderer)==="elk")},jS=async()=>{let{diagram:t}=await import("./flowchart-elk-definition-abe16c3d-CIXNS2P7.min.js");return{id:Jm,diagram:t}},GS={id:Jm,detector:YS,loader:jS},VS=GS,tg="timeline",XS=t=>/^\s*timeline/.test(t),KS=async()=>{let{diagram:t}=await import("./timeline-definition-5b62e21b-MGZADENC.min.js");return{id:tg,diagram:t}},ZS={id:tg,detector:XS,loader:KS},QS=ZS,eg="mindmap",JS=t=>/^\s*mindmap/.test(t),tw=async()=>{let{diagram:t}=await import("./mindmap-definition-beec6740-WEW6M5U7.min.js");return{id:eg,diagram:t}},ew={id:eg,detector:JS,loader:tw},rw=ew,rg="sankey",iw=t=>/^\s*sankey-beta/.test(t),ow=async()=>{let{diagram:t}=await import("./sankeyDiagram-8f13d901-NT2YQJYC.min.js");return{id:rg,diagram:t}},nw={id:rg,detector:iw,loader:ow},aw=nw,om=!1,jl=()=>{om||(om=!0,ca("error",HS,t=>t.toLowerCase().trim()==="error"),ca("---",{db:{clear:()=>{}},styles:{},renderer:{draw:()=>{}},parser:{parser:{yy:{}},parse:()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")}},init:()=>null},t=>t.toLowerCase().trimStart().startsWith("---")),vm(fk,lS,oS,kk,Ek,Dk,Rk,Kk,tS,VS,Ck,gk,rw,QS,Ak,gS,fS,CS,Wk,aw,jk))},ua=class{constructor(e,r={}){this.text=e,this.metadata=r,this.type="graph",this.text+=` +`);let i=zS(e);i.attr("viewBox","0 0 2412 512"),Zm(i,100,512,!0);let o=i.append("g");o.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),o.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),o.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),o.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),o.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),o.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),o.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),o.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${r}`)},Qm={draw:qS},WS=Qm,US={db:{},renderer:Qm,parser:{parser:{yy:{}},parse:()=>{}}},HS=US,Jm="flowchart-elk",YS=(t,e)=>{var r;return!!(/^\s*flowchart-elk/.test(t)||/^\s*flowchart|graph/.test(t)&&((r=e?.flowchart)==null?void 0:r.defaultRenderer)==="elk")},jS=async()=>{let{diagram:t}=await import("./flowchart-elk-definition-e097735e-ML73PEN2.min.js");return{id:Jm,diagram:t}},GS={id:Jm,detector:YS,loader:jS},VS=GS,tg="timeline",XS=t=>/^\s*timeline/.test(t),KS=async()=>{let{diagram:t}=await import("./timeline-definition-732a2638-CQETYKGJ.min.js");return{id:tg,diagram:t}},ZS={id:tg,detector:XS,loader:KS},QS=ZS,eg="mindmap",JS=t=>/^\s*mindmap/.test(t),tw=async()=>{let{diagram:t}=await import("./mindmap-definition-617cf8dd-VAOL4CGI.min.js");return{id:eg,diagram:t}},ew={id:eg,detector:JS,loader:tw},rw=ew,rg="sankey",iw=t=>/^\s*sankey-beta/.test(t),ow=async()=>{let{diagram:t}=await import("./sankeyDiagram-6db3d513-B6X2KUV4.min.js");return{id:rg,diagram:t}},nw={id:rg,detector:iw,loader:ow},aw=nw,om=!1,jl=()=>{om||(om=!0,ca("error",HS,t=>t.toLowerCase().trim()==="error"),ca("---",{db:{clear:()=>{}},styles:{},renderer:{draw:()=>{}},parser:{parser:{yy:{}},parse:()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")}},init:()=>null},t=>t.toLowerCase().trimStart().startsWith("---")),vm(fk,lS,oS,kk,Ek,Dk,Rk,Kk,tS,VS,Ck,gk,rw,QS,Ak,gS,fS,CS,Wk,aw,jk))},ua=class{constructor(e,r={}){this.text=e,this.metadata=r,this.type="graph",this.text+=` `;let i=xe();try{this.type=ya(e,i)}catch(n){this.type="error",this.detectError=n}let o=Yl(this.type);Y.debug("Type "+this.type),this.db=o.db,this.renderer=o.renderer,this.parser=o.parser,this.parser.parser.yy=this.db,this.init=o.init,this.parse()}parse(){var e,r,i,o,n;if(this.detectError)throw this.detectError;(r=(e=this.db).clear)==null||r.call(e);let a=xe();(i=this.init)==null||i.call(this,a),this.metadata.title&&((n=(o=this.db).setDiagramTitle)==null||n.call(o,this.metadata.title)),this.parser.parse(this.text)}async render(e,r){await this.renderer.draw(this.text,e,r,this)}getParser(){return this.parser}getType(){return this.type}},Gl=async(t,e={})=>{let r=ya(t,xe());try{Yl(r)}catch{let o=Ev(r);if(!o)throw new na(`Diagram ${r} not found.`);let{id:n,diagram:a}=await o();ca(n,a)}return new ua(t,e)},Ol=[],rq=t=>{Ol.push(t)},sw=()=>{Ol.forEach(t=>{t()}),Ol=[]},lw="graphics-document document";function cw(t,e){t.attr("role",lw),e!==""&&t.attr("aria-roledescription",e)}function uw(t,e,r,i){if(t.insert!==void 0){if(r){let o=`chart-desc-${i}`;t.attr("aria-describedby",o),t.insert("desc",":first-child").attr("id",o).text(r)}if(e){let o=`chart-title-${i}`;t.attr("aria-labelledby",o),t.insert("title",":first-child").attr("id",o).text(e)}}}var hw=t=>t.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart();function ig(t){return typeof t>"u"||t===null}function fw(t){return typeof t=="object"&&t!==null}function pw(t){return Array.isArray(t)?t:ig(t)?[]:[t]}function dw(t,e){var r,i,o,n;if(e)for(n=Object.keys(e),r=0,i=n.length;rs&&(n=" ... ",e=i-s+n.length),r-i>s&&(a=" ...",r=i+s-a.length),{str:n+t.slice(e,r).replace(/\t/g,"\u2192")+a,pos:i-e+n.length}}function Sl(t,e){return zt.repeat(" ",e-t.length)+t}function vw(t,e){if(e=Object.create(e||null),!t.buffer)return null;e.maxLength||(e.maxLength=79),typeof e.indent!="number"&&(e.indent=1),typeof e.linesBefore!="number"&&(e.linesBefore=3),typeof e.linesAfter!="number"&&(e.linesAfter=2);for(var r=/\r?\n|\r|\0/g,i=[0],o=[],n,a=-1;n=r.exec(t.buffer);)o.push(n.index),i.push(n.index+n[0].length),t.position<=n.index&&a<0&&(a=i.length-2);a<0&&(a=i.length-1);var s="",l,c,h=Math.min(t.line+e.linesAfter,o.length).toString().length,f=e.maxLength-(e.indent+h+3);for(l=1;l<=e.linesBefore&&!(a-l<0);l++)c=kl(t.buffer,i[a-l],o[a-l],t.position-(i[a]-i[a-l]),f),s=zt.repeat(" ",e.indent)+Sl((t.line-l+1).toString(),h)+" | "+c.str+` @@ -87,11 +87,11 @@ ${t.themeCSS}`),t.fontFamily!==void 0&&(i+=` dompurify/dist/purify.js: (*! @license DOMPurify 3.0.5 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.5/LICENSE *) -mermaid/dist/mermaid-8af3addd.js: +mermaid/dist/mermaid-934d9bea.js: (*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT *) (*! Check if previously processed *) (*! * Wait for document loaded before starting the execution *) */ -//# sourceMappingURL=chunk-65WDIALL.min.js.map +//# sourceMappingURL=chunk-JUXSCBYR.min.js.map diff --git a/docs/public/chunk-65WDIALL.min.js.map b/docs/public/chunk-JUXSCBYR.min.js.map similarity index 99% rename from docs/public/chunk-65WDIALL.min.js.map rename to docs/public/chunk-JUXSCBYR.min.js.map index 10993cef..12b16bf5 100644 --- a/docs/public/chunk-65WDIALL.min.js.map +++ b/docs/public/chunk-JUXSCBYR.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/dayjs/dayjs.min.js", "../../node_modules/@braintree/sanitize-url/dist/index.js", "../../node_modules/dompurify/src/utils.js", "../../node_modules/dompurify/src/tags.js", "../../node_modules/dompurify/src/attrs.js", "../../node_modules/dompurify/src/regexp.js", "../../node_modules/dompurify/src/purify.js", "../../node_modules/ts-dedent/src/index.ts", "../../node_modules/d3-array/src/max.js", "../../node_modules/d3-array/src/min.js", "../../node_modules/d3-array/src/ascending.js", "../../node_modules/d3-array/src/descending.js", "../../node_modules/d3-array/src/bisector.js", "../../node_modules/d3-array/src/number.js", "../../node_modules/d3-array/src/bisect.js", "../../node_modules/internmap/src/index.js", "../../node_modules/d3-array/src/ticks.js", "../../node_modules/d3-array/src/range.js", "../../node_modules/d3-axis/src/identity.js", "../../node_modules/d3-axis/src/axis.js", "../../node_modules/d3-selection/src/selector.js", "../../node_modules/d3-selection/src/selection/select.js", "../../node_modules/d3-selection/src/array.js", "../../node_modules/d3-selection/src/selectorAll.js", "../../node_modules/d3-selection/src/selection/selectAll.js", "../../node_modules/d3-selection/src/matcher.js", "../../node_modules/d3-selection/src/selection/selectChild.js", "../../node_modules/d3-selection/src/selection/selectChildren.js", "../../node_modules/d3-selection/src/selection/filter.js", "../../node_modules/d3-selection/src/selection/sparse.js", "../../node_modules/d3-selection/src/selection/enter.js", "../../node_modules/d3-selection/src/constant.js", "../../node_modules/d3-selection/src/selection/data.js", "../../node_modules/d3-selection/src/selection/exit.js", "../../node_modules/d3-selection/src/selection/join.js", "../../node_modules/d3-selection/src/selection/merge.js", "../../node_modules/d3-selection/src/selection/order.js", "../../node_modules/d3-selection/src/selection/sort.js", "../../node_modules/d3-selection/src/selection/call.js", "../../node_modules/d3-selection/src/selection/nodes.js", "../../node_modules/d3-selection/src/selection/node.js", "../../node_modules/d3-selection/src/selection/size.js", "../../node_modules/d3-selection/src/selection/empty.js", "../../node_modules/d3-selection/src/selection/each.js", "../../node_modules/d3-selection/src/namespaces.js", "../../node_modules/d3-selection/src/namespace.js", "../../node_modules/d3-selection/src/selection/attr.js", "../../node_modules/d3-selection/src/window.js", "../../node_modules/d3-selection/src/selection/style.js", "../../node_modules/d3-selection/src/selection/property.js", "../../node_modules/d3-selection/src/selection/classed.js", "../../node_modules/d3-selection/src/selection/text.js", "../../node_modules/d3-selection/src/selection/html.js", "../../node_modules/d3-selection/src/selection/raise.js", "../../node_modules/d3-selection/src/selection/lower.js", "../../node_modules/d3-selection/src/creator.js", "../../node_modules/d3-selection/src/selection/append.js", "../../node_modules/d3-selection/src/selection/insert.js", "../../node_modules/d3-selection/src/selection/remove.js", "../../node_modules/d3-selection/src/selection/clone.js", "../../node_modules/d3-selection/src/selection/datum.js", "../../node_modules/d3-selection/src/selection/on.js", "../../node_modules/d3-selection/src/selection/dispatch.js", "../../node_modules/d3-selection/src/selection/iterator.js", "../../node_modules/d3-selection/src/selection/index.js", "../../node_modules/d3-selection/src/select.js", "../../node_modules/d3-selection/src/selectAll.js", "../../node_modules/d3-color/src/define.js", "../../node_modules/d3-color/src/color.js", "../../node_modules/d3-color/src/math.js", "../../node_modules/d3-color/src/lab.js", "../../node_modules/d3-interpolate/src/constant.js", "../../node_modules/d3-interpolate/src/color.js", "../../node_modules/d3-interpolate/src/hcl.js", "../../node_modules/d3-interpolate/src/basis.js", "../../node_modules/d3-interpolate/src/basisClosed.js", "../../node_modules/d3-interpolate/src/rgb.js", "../../node_modules/d3-interpolate/src/numberArray.js", "../../node_modules/d3-interpolate/src/array.js", "../../node_modules/d3-interpolate/src/date.js", "../../node_modules/d3-interpolate/src/number.js", "../../node_modules/d3-interpolate/src/object.js", "../../node_modules/d3-interpolate/src/string.js", "../../node_modules/d3-interpolate/src/value.js", "../../node_modules/d3-interpolate/src/round.js", "../../node_modules/d3-interpolate/src/transform/decompose.js", "../../node_modules/d3-interpolate/src/transform/parse.js", "../../node_modules/d3-interpolate/src/transform/index.js", "../../node_modules/d3-scale/src/init.js", "../../node_modules/d3-scale/src/ordinal.js", "../../node_modules/d3-scale/src/band.js", "../../node_modules/d3-scale/src/constant.js", "../../node_modules/d3-scale/src/number.js", "../../node_modules/d3-scale/src/continuous.js", "../../node_modules/d3-format/src/formatDecimal.js", "../../node_modules/d3-format/src/exponent.js", "../../node_modules/d3-format/src/formatGroup.js", "../../node_modules/d3-format/src/formatNumerals.js", "../../node_modules/d3-format/src/formatSpecifier.js", "../../node_modules/d3-format/src/formatTrim.js", "../../node_modules/d3-format/src/formatPrefixAuto.js", "../../node_modules/d3-format/src/formatRounded.js", "../../node_modules/d3-format/src/formatTypes.js", "../../node_modules/d3-format/src/identity.js", "../../node_modules/d3-format/src/locale.js", "../../node_modules/d3-format/src/defaultLocale.js", "../../node_modules/d3-format/src/precisionFixed.js", "../../node_modules/d3-format/src/precisionPrefix.js", "../../node_modules/d3-format/src/precisionRound.js", "../../node_modules/d3-scale/src/tickFormat.js", "../../node_modules/d3-scale/src/linear.js", "../../node_modules/d3-time/src/interval.js", "../../node_modules/d3-time/src/millisecond.js", "../../node_modules/d3-time/src/second.js", "../../node_modules/d3-time/src/minute.js", "../../node_modules/d3-time/src/hour.js", "../../node_modules/d3-time/src/day.js", "../../node_modules/d3-time/src/week.js", "../../node_modules/d3-time/src/month.js", "../../node_modules/d3-time/src/year.js", "../../node_modules/d3-time/src/ticks.js", "../../node_modules/d3-time-format/src/locale.js", "../../node_modules/d3-time-format/src/defaultLocale.js", "../../node_modules/d3-scale/src/nice.js", "../../node_modules/d3-scale/src/time.js", "../../node_modules/d3-scale-chromatic/src/colors.js", "../../node_modules/d3-scale-chromatic/src/categorical/Tableau10.js", "../../node_modules/d3-shape/src/constant.js", "../../node_modules/d3-shape/src/math.js", "../../node_modules/d3-path/src/path.js", "../../node_modules/d3-shape/src/path.js", "../../node_modules/d3-shape/src/arc.js", "../../node_modules/d3-shape/src/curve/linear.js", "../../node_modules/d3-shape/src/array.js", "../../node_modules/d3-shape/src/point.js", "../../node_modules/d3-shape/src/line.js", "../../node_modules/d3-shape/src/descending.js", "../../node_modules/d3-shape/src/identity.js", "../../node_modules/d3-shape/src/pie.js", "../../node_modules/d3-shape/src/curve/basis.js", "../../node_modules/d3-shape/src/curve/bump.js", "../../node_modules/d3-shape/src/noop.js", "../../node_modules/d3-shape/src/curve/basisClosed.js", "../../node_modules/d3-shape/src/curve/basisOpen.js", "../../node_modules/d3-shape/src/curve/bundle.js", "../../node_modules/d3-shape/src/curve/cardinal.js", "../../node_modules/d3-shape/src/curve/cardinalClosed.js", "../../node_modules/d3-shape/src/curve/cardinalOpen.js", "../../node_modules/d3-shape/src/curve/catmullRom.js", "../../node_modules/d3-shape/src/curve/catmullRomClosed.js", "../../node_modules/d3-shape/src/curve/catmullRomOpen.js", "../../node_modules/d3-shape/src/curve/linearClosed.js", "../../node_modules/d3-shape/src/curve/monotone.js", "../../node_modules/d3-shape/src/curve/natural.js", "../../node_modules/d3-shape/src/curve/step.js", "../../node_modules/d3-dispatch/src/dispatch.js", "../../node_modules/d3-timer/src/timer.js", "../../node_modules/d3-timer/src/timeout.js", "../../node_modules/d3-transition/src/transition/schedule.js", "../../node_modules/d3-transition/src/interrupt.js", "../../node_modules/d3-transition/src/selection/interrupt.js", "../../node_modules/d3-transition/src/transition/tween.js", "../../node_modules/d3-transition/src/transition/interpolate.js", "../../node_modules/d3-transition/src/transition/attr.js", "../../node_modules/d3-transition/src/transition/attrTween.js", "../../node_modules/d3-transition/src/transition/delay.js", "../../node_modules/d3-transition/src/transition/duration.js", "../../node_modules/d3-transition/src/transition/ease.js", "../../node_modules/d3-transition/src/transition/easeVarying.js", "../../node_modules/d3-transition/src/transition/filter.js", "../../node_modules/d3-transition/src/transition/merge.js", "../../node_modules/d3-transition/src/transition/on.js", "../../node_modules/d3-transition/src/transition/remove.js", "../../node_modules/d3-transition/src/transition/select.js", "../../node_modules/d3-transition/src/transition/selectAll.js", "../../node_modules/d3-transition/src/transition/selection.js", "../../node_modules/d3-transition/src/transition/style.js", "../../node_modules/d3-transition/src/transition/styleTween.js", "../../node_modules/d3-transition/src/transition/text.js", "../../node_modules/d3-transition/src/transition/textTween.js", "../../node_modules/d3-transition/src/transition/transition.js", "../../node_modules/d3-transition/src/transition/end.js", "../../node_modules/d3-transition/src/transition/index.js", "../../node_modules/d3-ease/src/cubic.js", "../../node_modules/d3-transition/src/selection/transition.js", "../../node_modules/d3-transition/src/selection/index.js", "../../node_modules/d3-brush/src/brush.js", "../../node_modules/d3-fetch/src/text.js", "../../node_modules/d3-fetch/src/xml.js", "../../node_modules/d3-zoom/src/transform.js", "../../node_modules/khroma/dist/utils/channel.js", "../../node_modules/khroma/dist/utils/lang.js", "../../node_modules/khroma/dist/utils/unit.js", "../../node_modules/khroma/dist/utils/index.js", "../../node_modules/khroma/dist/constants.js", "../../node_modules/khroma/dist/channels/type.js", "../../node_modules/khroma/dist/channels/index.js", "../../node_modules/khroma/dist/channels/reusable.js", "../../node_modules/khroma/dist/color/hex.js", "../../node_modules/khroma/dist/color/hsl.js", "../../node_modules/khroma/dist/color/keyword.js", "../../node_modules/khroma/dist/color/rgb.js", "../../node_modules/khroma/dist/color/index.js", "../../node_modules/khroma/dist/methods/luminance.js", "../../node_modules/khroma/dist/methods/is_light.js", "../../node_modules/khroma/dist/methods/is_dark.js", "../../node_modules/khroma/dist/methods/adjust_channel.js", "../../node_modules/khroma/dist/methods/lighten.js", "../../node_modules/khroma/dist/methods/darken.js", "../../node_modules/khroma/dist/methods/change.js", "../../node_modules/khroma/dist/methods/rgba.js", "../../node_modules/khroma/dist/methods/channel.js", "../../node_modules/khroma/dist/methods/adjust.js", "../../node_modules/khroma/dist/methods/mix.js", "../../node_modules/khroma/dist/methods/invert.js", "../../node_modules/lodash-es/_freeGlobal.js", "../../node_modules/lodash-es/_root.js", "../../node_modules/lodash-es/_Symbol.js", "../../node_modules/lodash-es/_getRawTag.js", "../../node_modules/lodash-es/_objectToString.js", "../../node_modules/lodash-es/_baseGetTag.js", "../../node_modules/lodash-es/isObject.js", "../../node_modules/lodash-es/isFunction.js", "../../node_modules/lodash-es/_coreJsData.js", "../../node_modules/lodash-es/_isMasked.js", "../../node_modules/lodash-es/_toSource.js", "../../node_modules/lodash-es/_baseIsNative.js", "../../node_modules/lodash-es/_getValue.js", "../../node_modules/lodash-es/_getNative.js", "../../node_modules/lodash-es/_nativeCreate.js", "../../node_modules/lodash-es/_hashClear.js", "../../node_modules/lodash-es/_hashDelete.js", "../../node_modules/lodash-es/_hashGet.js", "../../node_modules/lodash-es/_hashHas.js", "../../node_modules/lodash-es/_hashSet.js", "../../node_modules/lodash-es/_Hash.js", "../../node_modules/lodash-es/_listCacheClear.js", "../../node_modules/lodash-es/eq.js", "../../node_modules/lodash-es/_assocIndexOf.js", "../../node_modules/lodash-es/_listCacheDelete.js", "../../node_modules/lodash-es/_listCacheGet.js", "../../node_modules/lodash-es/_listCacheHas.js", "../../node_modules/lodash-es/_listCacheSet.js", "../../node_modules/lodash-es/_ListCache.js", "../../node_modules/lodash-es/_Map.js", "../../node_modules/lodash-es/_mapCacheClear.js", "../../node_modules/lodash-es/_isKeyable.js", "../../node_modules/lodash-es/_getMapData.js", "../../node_modules/lodash-es/_mapCacheDelete.js", "../../node_modules/lodash-es/_mapCacheGet.js", "../../node_modules/lodash-es/_mapCacheHas.js", "../../node_modules/lodash-es/_mapCacheSet.js", "../../node_modules/lodash-es/_MapCache.js", "../../node_modules/lodash-es/memoize.js", "../../node_modules/lodash-es/_stackClear.js", "../../node_modules/lodash-es/_stackDelete.js", "../../node_modules/lodash-es/_stackGet.js", "../../node_modules/lodash-es/_stackHas.js", "../../node_modules/lodash-es/_stackSet.js", "../../node_modules/lodash-es/_Stack.js", "../../node_modules/lodash-es/_defineProperty.js", "../../node_modules/lodash-es/_baseAssignValue.js", "../../node_modules/lodash-es/_assignMergeValue.js", "../../node_modules/lodash-es/_createBaseFor.js", "../../node_modules/lodash-es/_baseFor.js", "../../node_modules/lodash-es/_cloneBuffer.js", "../../node_modules/lodash-es/_Uint8Array.js", "../../node_modules/lodash-es/_cloneArrayBuffer.js", "../../node_modules/lodash-es/_cloneTypedArray.js", "../../node_modules/lodash-es/_copyArray.js", "../../node_modules/lodash-es/_baseCreate.js", "../../node_modules/lodash-es/_overArg.js", "../../node_modules/lodash-es/_getPrototype.js", "../../node_modules/lodash-es/_isPrototype.js", "../../node_modules/lodash-es/_initCloneObject.js", "../../node_modules/lodash-es/isObjectLike.js", "../../node_modules/lodash-es/_baseIsArguments.js", "../../node_modules/lodash-es/isArguments.js", "../../node_modules/lodash-es/isArray.js", "../../node_modules/lodash-es/isLength.js", "../../node_modules/lodash-es/isArrayLike.js", "../../node_modules/lodash-es/isArrayLikeObject.js", "../../node_modules/lodash-es/stubFalse.js", "../../node_modules/lodash-es/isBuffer.js", "../../node_modules/lodash-es/isPlainObject.js", "../../node_modules/lodash-es/_baseIsTypedArray.js", "../../node_modules/lodash-es/_baseUnary.js", "../../node_modules/lodash-es/_nodeUtil.js", "../../node_modules/lodash-es/isTypedArray.js", "../../node_modules/lodash-es/_safeGet.js", "../../node_modules/lodash-es/_assignValue.js", "../../node_modules/lodash-es/_copyObject.js", "../../node_modules/lodash-es/_baseTimes.js", "../../node_modules/lodash-es/_isIndex.js", "../../node_modules/lodash-es/_arrayLikeKeys.js", "../../node_modules/lodash-es/_nativeKeysIn.js", "../../node_modules/lodash-es/_baseKeysIn.js", "../../node_modules/lodash-es/keysIn.js", "../../node_modules/lodash-es/toPlainObject.js", "../../node_modules/lodash-es/_baseMergeDeep.js", "../../node_modules/lodash-es/_baseMerge.js", "../../node_modules/lodash-es/identity.js", "../../node_modules/lodash-es/_apply.js", "../../node_modules/lodash-es/_overRest.js", "../../node_modules/lodash-es/constant.js", "../../node_modules/lodash-es/_baseSetToString.js", "../../node_modules/lodash-es/_shortOut.js", "../../node_modules/lodash-es/_setToString.js", "../../node_modules/lodash-es/_baseRest.js", "../../node_modules/lodash-es/_isIterateeCall.js", "../../node_modules/lodash-es/_createAssigner.js", "../../node_modules/lodash-es/merge.js", "../../node_modules/lodash-es/_nativeKeys.js", "../../node_modules/lodash-es/_baseKeys.js", "../../node_modules/lodash-es/_DataView.js", "../../node_modules/lodash-es/_Promise.js", "../../node_modules/lodash-es/_Set.js", "../../node_modules/lodash-es/_WeakMap.js", "../../node_modules/lodash-es/_getTag.js", "../../node_modules/lodash-es/isEmpty.js", "../../node_modules/mermaid/dist/mermaid-8af3addd.js", "../../node_modules/stylis/src/Enum.js", "../../node_modules/stylis/src/Utility.js", "../../node_modules/stylis/src/Tokenizer.js", "../../node_modules/stylis/src/Parser.js", "../../node_modules/stylis/src/Serializer.js"], - "sourcesContent": ["!function(t,e){\"object\"==typeof exports&&\"undefined\"!=typeof module?module.exports=e():\"function\"==typeof define&&define.amd?define(e):(t=\"undefined\"!=typeof globalThis?globalThis:t||self).dayjs=e()}(this,(function(){\"use strict\";var t=1e3,e=6e4,n=36e5,r=\"millisecond\",i=\"second\",s=\"minute\",u=\"hour\",a=\"day\",o=\"week\",f=\"month\",h=\"quarter\",c=\"year\",d=\"date\",l=\"Invalid Date\",$=/^(\\d{4})[-/]?(\\d{1,2})?[-/]?(\\d{0,2})[Tt\\s]*(\\d{1,2})?:?(\\d{1,2})?:?(\\d{1,2})?[.:]?(\\d+)?$/,y=/\\[([^\\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:\"en\",weekdays:\"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday\".split(\"_\"),months:\"January_February_March_April_May_June_July_August_September_October_November_December\".split(\"_\"),ordinal:function(t){var e=[\"th\",\"st\",\"nd\",\"rd\"],n=t%100;return\"[\"+t+(e[(n-20)%10]||e[n]||e[0])+\"]\"}},m=function(t,e,n){var r=String(t);return!r||r.length>=e?t:\"\"+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?\"+\":\"-\")+m(r,2,\"0\")+\":\"+m(i,2,\"0\")},m:function t(e,n){if(e.date()1)return t(u[0])}else{var a=e.name;D[a]=e,i=a}return!r&&i&&(g=i),i||!r&&g},w=function(t,e){if(p(t))return t.clone();var n=\"object\"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},O=v;O.l=S,O.i=p,O.w=function(t,e){return w(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function M(t){this.$L=S(t.locale,null,!0),this.parse(t)}var m=M.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(O.u(e))return new Date;if(e instanceof Date)return new Date(e);if(\"string\"==typeof e&&!/Z$/i.test(e)){var r=e.match($);if(r){var i=r[2]-1||0,s=(r[7]||\"0\").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.$x=t.x||{},this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return O},m.isValid=function(){return!(this.$d.toString()===l)},m.isSame=function(t,e){var n=w(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return w(t) -1;\n}\n// adapted from https://stackoverflow.com/a/29824550/2601552\nfunction decodeHtmlCharacters(str) {\n return str.replace(htmlEntitiesRegex, function (match, dec) {\n return String.fromCharCode(dec);\n });\n}\nfunction sanitizeUrl(url) {\n var sanitizedUrl = decodeHtmlCharacters(url || \"\")\n .replace(htmlCtrlEntityRegex, \"\")\n .replace(ctrlCharactersRegex, \"\")\n .trim();\n if (!sanitizedUrl) {\n return \"about:blank\";\n }\n if (isRelativeUrlWithoutProtocol(sanitizedUrl)) {\n return sanitizedUrl;\n }\n var urlSchemeParseResults = sanitizedUrl.match(urlSchemeRegex);\n if (!urlSchemeParseResults) {\n return sanitizedUrl;\n }\n var urlScheme = urlSchemeParseResults[0];\n if (invalidProtocolRegex.test(urlScheme)) {\n return \"about:blank\";\n }\n return sanitizedUrl;\n}\nexports.sanitizeUrl = sanitizeUrl;\n", "const {\n entries,\n setPrototypeOf,\n isFrozen,\n getPrototypeOf,\n getOwnPropertyDescriptor,\n} = Object;\n\nlet { freeze, seal, create } = Object; // eslint-disable-line import/no-mutable-exports\nlet { apply, construct } = typeof Reflect !== 'undefined' && Reflect;\n\nif (!apply) {\n apply = function (fun, thisValue, args) {\n return fun.apply(thisValue, args);\n };\n}\n\nif (!freeze) {\n freeze = function (x) {\n return x;\n };\n}\n\nif (!seal) {\n seal = function (x) {\n return x;\n };\n}\n\nif (!construct) {\n construct = function (Func, args) {\n return new Func(...args);\n };\n}\n\nconst arrayForEach = unapply(Array.prototype.forEach);\nconst arrayIndexOf = unapply(Array.prototype.indexOf);\nconst arrayPop = unapply(Array.prototype.pop);\nconst arrayPush = unapply(Array.prototype.push);\nconst arraySlice = unapply(Array.prototype.slice);\n\nconst stringToLowerCase = unapply(String.prototype.toLowerCase);\nconst stringToString = unapply(String.prototype.toString);\nconst stringMatch = unapply(String.prototype.match);\nconst stringReplace = unapply(String.prototype.replace);\nconst stringIndexOf = unapply(String.prototype.indexOf);\nconst stringTrim = unapply(String.prototype.trim);\n\nconst regExpTest = unapply(RegExp.prototype.test);\n\nconst typeErrorCreate = unconstruct(TypeError);\n\nexport function unapply(func) {\n return (thisArg, ...args) => apply(func, thisArg, args);\n}\n\nexport function unconstruct(func) {\n return (...args) => construct(func, args);\n}\n\n/* Add properties to a lookup table */\nexport function addToSet(set, array, transformCaseFunc) {\n transformCaseFunc = transformCaseFunc ?? stringToLowerCase;\n if (setPrototypeOf) {\n // Make 'in' and truthy checks like Boolean(set.constructor)\n // independent of any properties defined on Object.prototype.\n // Prevent prototype setters from intercepting set as a this value.\n setPrototypeOf(set, null);\n }\n\n let l = array.length;\n while (l--) {\n let element = array[l];\n if (typeof element === 'string') {\n const lcElement = transformCaseFunc(element);\n if (lcElement !== element) {\n // Config presets (e.g. tags.js, attrs.js) are immutable.\n if (!isFrozen(array)) {\n array[l] = lcElement;\n }\n\n element = lcElement;\n }\n }\n\n set[element] = true;\n }\n\n return set;\n}\n\n/* Shallow clone an object */\nexport function clone(object) {\n const newObject = create(null);\n\n for (const [property, value] of entries(object)) {\n newObject[property] = value;\n }\n\n return newObject;\n}\n\n/* This method automatically checks if the prop is function\n * or getter and behaves accordingly. */\nfunction lookupGetter(object, prop) {\n while (object !== null) {\n const desc = getOwnPropertyDescriptor(object, prop);\n if (desc) {\n if (desc.get) {\n return unapply(desc.get);\n }\n\n if (typeof desc.value === 'function') {\n return unapply(desc.value);\n }\n }\n\n object = getPrototypeOf(object);\n }\n\n function fallbackValue(element) {\n console.warn('fallback value for', element);\n return null;\n }\n\n return fallbackValue;\n}\n\nexport {\n // Array\n arrayForEach,\n arrayIndexOf,\n arrayPop,\n arrayPush,\n arraySlice,\n // Object\n entries,\n freeze,\n getPrototypeOf,\n getOwnPropertyDescriptor,\n isFrozen,\n setPrototypeOf,\n seal,\n // RegExp\n regExpTest,\n // String\n stringIndexOf,\n stringMatch,\n stringReplace,\n stringToLowerCase,\n stringToString,\n stringTrim,\n // Errors\n typeErrorCreate,\n // Other\n lookupGetter,\n};\n", "import { freeze } from './utils.js';\n\nexport const html = freeze([\n 'a',\n 'abbr',\n 'acronym',\n 'address',\n 'area',\n 'article',\n 'aside',\n 'audio',\n 'b',\n 'bdi',\n 'bdo',\n 'big',\n 'blink',\n 'blockquote',\n 'body',\n 'br',\n 'button',\n 'canvas',\n 'caption',\n 'center',\n 'cite',\n 'code',\n 'col',\n 'colgroup',\n 'content',\n 'data',\n 'datalist',\n 'dd',\n 'decorator',\n 'del',\n 'details',\n 'dfn',\n 'dialog',\n 'dir',\n 'div',\n 'dl',\n 'dt',\n 'element',\n 'em',\n 'fieldset',\n 'figcaption',\n 'figure',\n 'font',\n 'footer',\n 'form',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'head',\n 'header',\n 'hgroup',\n 'hr',\n 'html',\n 'i',\n 'img',\n 'input',\n 'ins',\n 'kbd',\n 'label',\n 'legend',\n 'li',\n 'main',\n 'map',\n 'mark',\n 'marquee',\n 'menu',\n 'menuitem',\n 'meter',\n 'nav',\n 'nobr',\n 'ol',\n 'optgroup',\n 'option',\n 'output',\n 'p',\n 'picture',\n 'pre',\n 'progress',\n 'q',\n 'rp',\n 'rt',\n 'ruby',\n 's',\n 'samp',\n 'section',\n 'select',\n 'shadow',\n 'small',\n 'source',\n 'spacer',\n 'span',\n 'strike',\n 'strong',\n 'style',\n 'sub',\n 'summary',\n 'sup',\n 'table',\n 'tbody',\n 'td',\n 'template',\n 'textarea',\n 'tfoot',\n 'th',\n 'thead',\n 'time',\n 'tr',\n 'track',\n 'tt',\n 'u',\n 'ul',\n 'var',\n 'video',\n 'wbr',\n]);\n\n// SVG\nexport const svg = freeze([\n 'svg',\n 'a',\n 'altglyph',\n 'altglyphdef',\n 'altglyphitem',\n 'animatecolor',\n 'animatemotion',\n 'animatetransform',\n 'circle',\n 'clippath',\n 'defs',\n 'desc',\n 'ellipse',\n 'filter',\n 'font',\n 'g',\n 'glyph',\n 'glyphref',\n 'hkern',\n 'image',\n 'line',\n 'lineargradient',\n 'marker',\n 'mask',\n 'metadata',\n 'mpath',\n 'path',\n 'pattern',\n 'polygon',\n 'polyline',\n 'radialgradient',\n 'rect',\n 'stop',\n 'style',\n 'switch',\n 'symbol',\n 'text',\n 'textpath',\n 'title',\n 'tref',\n 'tspan',\n 'view',\n 'vkern',\n]);\n\nexport const svgFilters = freeze([\n 'feBlend',\n 'feColorMatrix',\n 'feComponentTransfer',\n 'feComposite',\n 'feConvolveMatrix',\n 'feDiffuseLighting',\n 'feDisplacementMap',\n 'feDistantLight',\n 'feDropShadow',\n 'feFlood',\n 'feFuncA',\n 'feFuncB',\n 'feFuncG',\n 'feFuncR',\n 'feGaussianBlur',\n 'feImage',\n 'feMerge',\n 'feMergeNode',\n 'feMorphology',\n 'feOffset',\n 'fePointLight',\n 'feSpecularLighting',\n 'feSpotLight',\n 'feTile',\n 'feTurbulence',\n]);\n\n// List of SVG elements that are disallowed by default.\n// We still need to know them so that we can do namespace\n// checks properly in case one wants to add them to\n// allow-list.\nexport const svgDisallowed = freeze([\n 'animate',\n 'color-profile',\n 'cursor',\n 'discard',\n 'font-face',\n 'font-face-format',\n 'font-face-name',\n 'font-face-src',\n 'font-face-uri',\n 'foreignobject',\n 'hatch',\n 'hatchpath',\n 'mesh',\n 'meshgradient',\n 'meshpatch',\n 'meshrow',\n 'missing-glyph',\n 'script',\n 'set',\n 'solidcolor',\n 'unknown',\n 'use',\n]);\n\nexport const mathMl = freeze([\n 'math',\n 'menclose',\n 'merror',\n 'mfenced',\n 'mfrac',\n 'mglyph',\n 'mi',\n 'mlabeledtr',\n 'mmultiscripts',\n 'mn',\n 'mo',\n 'mover',\n 'mpadded',\n 'mphantom',\n 'mroot',\n 'mrow',\n 'ms',\n 'mspace',\n 'msqrt',\n 'mstyle',\n 'msub',\n 'msup',\n 'msubsup',\n 'mtable',\n 'mtd',\n 'mtext',\n 'mtr',\n 'munder',\n 'munderover',\n 'mprescripts',\n]);\n\n// Similarly to SVG, we want to know all MathML elements,\n// even those that we disallow by default.\nexport const mathMlDisallowed = freeze([\n 'maction',\n 'maligngroup',\n 'malignmark',\n 'mlongdiv',\n 'mscarries',\n 'mscarry',\n 'msgroup',\n 'mstack',\n 'msline',\n 'msrow',\n 'semantics',\n 'annotation',\n 'annotation-xml',\n 'mprescripts',\n 'none',\n]);\n\nexport const text = freeze(['#text']);\n", "import { freeze } from './utils.js';\n\nexport const html = freeze([\n 'accept',\n 'action',\n 'align',\n 'alt',\n 'autocapitalize',\n 'autocomplete',\n 'autopictureinpicture',\n 'autoplay',\n 'background',\n 'bgcolor',\n 'border',\n 'capture',\n 'cellpadding',\n 'cellspacing',\n 'checked',\n 'cite',\n 'class',\n 'clear',\n 'color',\n 'cols',\n 'colspan',\n 'controls',\n 'controlslist',\n 'coords',\n 'crossorigin',\n 'datetime',\n 'decoding',\n 'default',\n 'dir',\n 'disabled',\n 'disablepictureinpicture',\n 'disableremoteplayback',\n 'download',\n 'draggable',\n 'enctype',\n 'enterkeyhint',\n 'face',\n 'for',\n 'headers',\n 'height',\n 'hidden',\n 'high',\n 'href',\n 'hreflang',\n 'id',\n 'inputmode',\n 'integrity',\n 'ismap',\n 'kind',\n 'label',\n 'lang',\n 'list',\n 'loading',\n 'loop',\n 'low',\n 'max',\n 'maxlength',\n 'media',\n 'method',\n 'min',\n 'minlength',\n 'multiple',\n 'muted',\n 'name',\n 'nonce',\n 'noshade',\n 'novalidate',\n 'nowrap',\n 'open',\n 'optimum',\n 'pattern',\n 'placeholder',\n 'playsinline',\n 'poster',\n 'preload',\n 'pubdate',\n 'radiogroup',\n 'readonly',\n 'rel',\n 'required',\n 'rev',\n 'reversed',\n 'role',\n 'rows',\n 'rowspan',\n 'spellcheck',\n 'scope',\n 'selected',\n 'shape',\n 'size',\n 'sizes',\n 'span',\n 'srclang',\n 'start',\n 'src',\n 'srcset',\n 'step',\n 'style',\n 'summary',\n 'tabindex',\n 'title',\n 'translate',\n 'type',\n 'usemap',\n 'valign',\n 'value',\n 'width',\n 'xmlns',\n 'slot',\n]);\n\nexport const svg = freeze([\n 'accent-height',\n 'accumulate',\n 'additive',\n 'alignment-baseline',\n 'ascent',\n 'attributename',\n 'attributetype',\n 'azimuth',\n 'basefrequency',\n 'baseline-shift',\n 'begin',\n 'bias',\n 'by',\n 'class',\n 'clip',\n 'clippathunits',\n 'clip-path',\n 'clip-rule',\n 'color',\n 'color-interpolation',\n 'color-interpolation-filters',\n 'color-profile',\n 'color-rendering',\n 'cx',\n 'cy',\n 'd',\n 'dx',\n 'dy',\n 'diffuseconstant',\n 'direction',\n 'display',\n 'divisor',\n 'dur',\n 'edgemode',\n 'elevation',\n 'end',\n 'fill',\n 'fill-opacity',\n 'fill-rule',\n 'filter',\n 'filterunits',\n 'flood-color',\n 'flood-opacity',\n 'font-family',\n 'font-size',\n 'font-size-adjust',\n 'font-stretch',\n 'font-style',\n 'font-variant',\n 'font-weight',\n 'fx',\n 'fy',\n 'g1',\n 'g2',\n 'glyph-name',\n 'glyphref',\n 'gradientunits',\n 'gradienttransform',\n 'height',\n 'href',\n 'id',\n 'image-rendering',\n 'in',\n 'in2',\n 'k',\n 'k1',\n 'k2',\n 'k3',\n 'k4',\n 'kerning',\n 'keypoints',\n 'keysplines',\n 'keytimes',\n 'lang',\n 'lengthadjust',\n 'letter-spacing',\n 'kernelmatrix',\n 'kernelunitlength',\n 'lighting-color',\n 'local',\n 'marker-end',\n 'marker-mid',\n 'marker-start',\n 'markerheight',\n 'markerunits',\n 'markerwidth',\n 'maskcontentunits',\n 'maskunits',\n 'max',\n 'mask',\n 'media',\n 'method',\n 'mode',\n 'min',\n 'name',\n 'numoctaves',\n 'offset',\n 'operator',\n 'opacity',\n 'order',\n 'orient',\n 'orientation',\n 'origin',\n 'overflow',\n 'paint-order',\n 'path',\n 'pathlength',\n 'patterncontentunits',\n 'patterntransform',\n 'patternunits',\n 'points',\n 'preservealpha',\n 'preserveaspectratio',\n 'primitiveunits',\n 'r',\n 'rx',\n 'ry',\n 'radius',\n 'refx',\n 'refy',\n 'repeatcount',\n 'repeatdur',\n 'restart',\n 'result',\n 'rotate',\n 'scale',\n 'seed',\n 'shape-rendering',\n 'specularconstant',\n 'specularexponent',\n 'spreadmethod',\n 'startoffset',\n 'stddeviation',\n 'stitchtiles',\n 'stop-color',\n 'stop-opacity',\n 'stroke-dasharray',\n 'stroke-dashoffset',\n 'stroke-linecap',\n 'stroke-linejoin',\n 'stroke-miterlimit',\n 'stroke-opacity',\n 'stroke',\n 'stroke-width',\n 'style',\n 'surfacescale',\n 'systemlanguage',\n 'tabindex',\n 'targetx',\n 'targety',\n 'transform',\n 'transform-origin',\n 'text-anchor',\n 'text-decoration',\n 'text-rendering',\n 'textlength',\n 'type',\n 'u1',\n 'u2',\n 'unicode',\n 'values',\n 'viewbox',\n 'visibility',\n 'version',\n 'vert-adv-y',\n 'vert-origin-x',\n 'vert-origin-y',\n 'width',\n 'word-spacing',\n 'wrap',\n 'writing-mode',\n 'xchannelselector',\n 'ychannelselector',\n 'x',\n 'x1',\n 'x2',\n 'xmlns',\n 'y',\n 'y1',\n 'y2',\n 'z',\n 'zoomandpan',\n]);\n\nexport const mathMl = freeze([\n 'accent',\n 'accentunder',\n 'align',\n 'bevelled',\n 'close',\n 'columnsalign',\n 'columnlines',\n 'columnspan',\n 'denomalign',\n 'depth',\n 'dir',\n 'display',\n 'displaystyle',\n 'encoding',\n 'fence',\n 'frame',\n 'height',\n 'href',\n 'id',\n 'largeop',\n 'length',\n 'linethickness',\n 'lspace',\n 'lquote',\n 'mathbackground',\n 'mathcolor',\n 'mathsize',\n 'mathvariant',\n 'maxsize',\n 'minsize',\n 'movablelimits',\n 'notation',\n 'numalign',\n 'open',\n 'rowalign',\n 'rowlines',\n 'rowspacing',\n 'rowspan',\n 'rspace',\n 'rquote',\n 'scriptlevel',\n 'scriptminsize',\n 'scriptsizemultiplier',\n 'selection',\n 'separator',\n 'separators',\n 'stretchy',\n 'subscriptshift',\n 'supscriptshift',\n 'symmetric',\n 'voffset',\n 'width',\n 'xmlns',\n]);\n\nexport const xml = freeze([\n 'xlink:href',\n 'xml:id',\n 'xlink:title',\n 'xml:space',\n 'xmlns:xlink',\n]);\n", "import { seal } from './utils.js';\n\n// eslint-disable-next-line unicorn/better-regex\nexport const MUSTACHE_EXPR = seal(/\\{\\{[\\w\\W]*|[\\w\\W]*\\}\\}/gm); // Specify template detection regex for SAFE_FOR_TEMPLATES mode\nexport const ERB_EXPR = seal(/<%[\\w\\W]*|[\\w\\W]*%>/gm);\nexport const TMPLIT_EXPR = seal(/\\${[\\w\\W]*}/gm);\nexport const DATA_ATTR = seal(/^data-[\\-\\w.\\u00B7-\\uFFFF]/); // eslint-disable-line no-useless-escape\nexport const ARIA_ATTR = seal(/^aria-[\\-\\w]+$/); // eslint-disable-line no-useless-escape\nexport const IS_ALLOWED_URI = seal(\n /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\\-]+(?:[^a-z+.\\-:]|$))/i // eslint-disable-line no-useless-escape\n);\nexport const IS_SCRIPT_OR_DATA = seal(/^(?:\\w+script|data):/i);\nexport const ATTR_WHITESPACE = seal(\n /[\\u0000-\\u0020\\u00A0\\u1680\\u180E\\u2000-\\u2029\\u205F\\u3000]/g // eslint-disable-line no-control-regex\n);\nexport const DOCTYPE_NAME = seal(/^html$/i);\n", "import * as TAGS from './tags.js';\nimport * as ATTRS from './attrs.js';\nimport * as EXPRESSIONS from './regexp.js';\nimport {\n addToSet,\n clone,\n entries,\n freeze,\n arrayForEach,\n arrayPop,\n arrayPush,\n stringMatch,\n stringReplace,\n stringToLowerCase,\n stringToString,\n stringIndexOf,\n stringTrim,\n regExpTest,\n typeErrorCreate,\n lookupGetter,\n} from './utils.js';\n\nconst getGlobal = () => (typeof window === 'undefined' ? null : window);\n\n/**\n * Creates a no-op policy for internal use only.\n * Don't export this function outside this module!\n * @param {?TrustedTypePolicyFactory} trustedTypes The policy factory.\n * @param {HTMLScriptElement} purifyHostElement The Script element used to load DOMPurify (to determine policy name suffix).\n * @return {?TrustedTypePolicy} The policy created (or null, if Trusted Types\n * are not supported or creating the policy failed).\n */\nconst _createTrustedTypesPolicy = function (trustedTypes, purifyHostElement) {\n if (\n typeof trustedTypes !== 'object' ||\n typeof trustedTypes.createPolicy !== 'function'\n ) {\n return null;\n }\n\n // Allow the callers to control the unique policy name\n // by adding a data-tt-policy-suffix to the script element with the DOMPurify.\n // Policy creation with duplicate names throws in Trusted Types.\n let suffix = null;\n const ATTR_NAME = 'data-tt-policy-suffix';\n if (purifyHostElement && purifyHostElement.hasAttribute(ATTR_NAME)) {\n suffix = purifyHostElement.getAttribute(ATTR_NAME);\n }\n\n const policyName = 'dompurify' + (suffix ? '#' + suffix : '');\n\n try {\n return trustedTypes.createPolicy(policyName, {\n createHTML(html) {\n return html;\n },\n createScriptURL(scriptUrl) {\n return scriptUrl;\n },\n });\n } catch (_) {\n // Policy creation failed (most likely another DOMPurify script has\n // already run). Skip creating the policy, as this will only cause errors\n // if TT are enforced.\n console.warn(\n 'TrustedTypes policy ' + policyName + ' could not be created.'\n );\n return null;\n }\n};\n\nfunction createDOMPurify(window = getGlobal()) {\n const DOMPurify = (root) => createDOMPurify(root);\n\n /**\n * Version label, exposed for easier checks\n * if DOMPurify is up to date or not\n */\n DOMPurify.version = VERSION;\n\n /**\n * Array of elements that DOMPurify removed during sanitation.\n * Empty if nothing was removed.\n */\n DOMPurify.removed = [];\n\n if (!window || !window.document || window.document.nodeType !== 9) {\n // Not running in a browser, provide a factory function\n // so that you can pass your own Window\n DOMPurify.isSupported = false;\n\n return DOMPurify;\n }\n\n const originalDocument = window.document;\n const currentScript = originalDocument.currentScript;\n\n let { document } = window;\n const {\n DocumentFragment,\n HTMLTemplateElement,\n Node,\n Element,\n NodeFilter,\n NamedNodeMap = window.NamedNodeMap || window.MozNamedAttrMap,\n HTMLFormElement,\n DOMParser,\n trustedTypes,\n } = window;\n\n const ElementPrototype = Element.prototype;\n\n const cloneNode = lookupGetter(ElementPrototype, 'cloneNode');\n const getNextSibling = lookupGetter(ElementPrototype, 'nextSibling');\n const getChildNodes = lookupGetter(ElementPrototype, 'childNodes');\n const getParentNode = lookupGetter(ElementPrototype, 'parentNode');\n\n // As per issue #47, the web-components registry is inherited by a\n // new document created via createHTMLDocument. As per the spec\n // (http://w3c.github.io/webcomponents/spec/custom/#creating-and-passing-registries)\n // a new empty registry is used when creating a template contents owner\n // document, so we use that as our parent document to ensure nothing\n // is inherited.\n if (typeof HTMLTemplateElement === 'function') {\n const template = document.createElement('template');\n if (template.content && template.content.ownerDocument) {\n document = template.content.ownerDocument;\n }\n }\n\n let trustedTypesPolicy;\n let emptyHTML = '';\n\n const {\n implementation,\n createNodeIterator,\n createDocumentFragment,\n getElementsByTagName,\n } = document;\n const { importNode } = originalDocument;\n\n let hooks = {};\n\n /**\n * Expose whether this browser supports running the full DOMPurify.\n */\n DOMPurify.isSupported =\n typeof entries === 'function' &&\n typeof getParentNode === 'function' &&\n implementation &&\n implementation.createHTMLDocument !== undefined;\n\n const {\n MUSTACHE_EXPR,\n ERB_EXPR,\n TMPLIT_EXPR,\n DATA_ATTR,\n ARIA_ATTR,\n IS_SCRIPT_OR_DATA,\n ATTR_WHITESPACE,\n } = EXPRESSIONS;\n\n let { IS_ALLOWED_URI } = EXPRESSIONS;\n\n /**\n * We consider the elements and attributes below to be safe. Ideally\n * don't add any new ones but feel free to remove unwanted ones.\n */\n\n /* allowed element names */\n let ALLOWED_TAGS = null;\n const DEFAULT_ALLOWED_TAGS = addToSet({}, [\n ...TAGS.html,\n ...TAGS.svg,\n ...TAGS.svgFilters,\n ...TAGS.mathMl,\n ...TAGS.text,\n ]);\n\n /* Allowed attribute names */\n let ALLOWED_ATTR = null;\n const DEFAULT_ALLOWED_ATTR = addToSet({}, [\n ...ATTRS.html,\n ...ATTRS.svg,\n ...ATTRS.mathMl,\n ...ATTRS.xml,\n ]);\n\n /*\n * Configure how DOMPUrify should handle custom elements and their attributes as well as customized built-in elements.\n * @property {RegExp|Function|null} tagNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any custom elements)\n * @property {RegExp|Function|null} attributeNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any attributes not on the allow list)\n * @property {boolean} allowCustomizedBuiltInElements allow custom elements derived from built-ins if they pass CUSTOM_ELEMENT_HANDLING.tagNameCheck. Default: `false`.\n */\n let CUSTOM_ELEMENT_HANDLING = Object.seal(\n Object.create(null, {\n tagNameCheck: {\n writable: true,\n configurable: false,\n enumerable: true,\n value: null,\n },\n attributeNameCheck: {\n writable: true,\n configurable: false,\n enumerable: true,\n value: null,\n },\n allowCustomizedBuiltInElements: {\n writable: true,\n configurable: false,\n enumerable: true,\n value: false,\n },\n })\n );\n\n /* Explicitly forbidden tags (overrides ALLOWED_TAGS/ADD_TAGS) */\n let FORBID_TAGS = null;\n\n /* Explicitly forbidden attributes (overrides ALLOWED_ATTR/ADD_ATTR) */\n let FORBID_ATTR = null;\n\n /* Decide if ARIA attributes are okay */\n let ALLOW_ARIA_ATTR = true;\n\n /* Decide if custom data attributes are okay */\n let ALLOW_DATA_ATTR = true;\n\n /* Decide if unknown protocols are okay */\n let ALLOW_UNKNOWN_PROTOCOLS = false;\n\n /* Decide if self-closing tags in attributes are allowed.\n * Usually removed due to a mXSS issue in jQuery 3.0 */\n let ALLOW_SELF_CLOSE_IN_ATTR = true;\n\n /* Output should be safe for common template engines.\n * This means, DOMPurify removes data attributes, mustaches and ERB\n */\n let SAFE_FOR_TEMPLATES = false;\n\n /* Decide if document with ... should be returned */\n let WHOLE_DOCUMENT = false;\n\n /* Track whether config is already set on this instance of DOMPurify. */\n let SET_CONFIG = false;\n\n /* Decide if all elements (e.g. style, script) must be children of\n * document.body. By default, browsers might move them to document.head */\n let FORCE_BODY = false;\n\n /* Decide if a DOM `HTMLBodyElement` should be returned, instead of a html\n * string (or a TrustedHTML object if Trusted Types are supported).\n * If `WHOLE_DOCUMENT` is enabled a `HTMLHtmlElement` will be returned instead\n */\n let RETURN_DOM = false;\n\n /* Decide if a DOM `DocumentFragment` should be returned, instead of a html\n * string (or a TrustedHTML object if Trusted Types are supported) */\n let RETURN_DOM_FRAGMENT = false;\n\n /* Try to return a Trusted Type object instead of a string, return a string in\n * case Trusted Types are not supported */\n let RETURN_TRUSTED_TYPE = false;\n\n /* Output should be free from DOM clobbering attacks?\n * This sanitizes markups named with colliding, clobberable built-in DOM APIs.\n */\n let SANITIZE_DOM = true;\n\n /* Achieve full DOM Clobbering protection by isolating the namespace of named\n * properties and JS variables, mitigating attacks that abuse the HTML/DOM spec rules.\n *\n * HTML/DOM spec rules that enable DOM Clobbering:\n * - Named Access on Window (§7.3.3)\n * - DOM Tree Accessors (§3.1.5)\n * - Form Element Parent-Child Relations (§4.10.3)\n * - Iframe srcdoc / Nested WindowProxies (§4.8.5)\n * - HTMLCollection (§4.2.10.2)\n *\n * Namespace isolation is implemented by prefixing `id` and `name` attributes\n * with a constant string, i.e., `user-content-`\n */\n let SANITIZE_NAMED_PROPS = false;\n const SANITIZE_NAMED_PROPS_PREFIX = 'user-content-';\n\n /* Keep element content when removing element? */\n let KEEP_CONTENT = true;\n\n /* If a `Node` is passed to sanitize(), then performs sanitization in-place instead\n * of importing it into a new Document and returning a sanitized copy */\n let IN_PLACE = false;\n\n /* Allow usage of profiles like html, svg and mathMl */\n let USE_PROFILES = {};\n\n /* Tags to ignore content of when KEEP_CONTENT is true */\n let FORBID_CONTENTS = null;\n const DEFAULT_FORBID_CONTENTS = addToSet({}, [\n 'annotation-xml',\n 'audio',\n 'colgroup',\n 'desc',\n 'foreignobject',\n 'head',\n 'iframe',\n 'math',\n 'mi',\n 'mn',\n 'mo',\n 'ms',\n 'mtext',\n 'noembed',\n 'noframes',\n 'noscript',\n 'plaintext',\n 'script',\n 'style',\n 'svg',\n 'template',\n 'thead',\n 'title',\n 'video',\n 'xmp',\n ]);\n\n /* Tags that are safe for data: URIs */\n let DATA_URI_TAGS = null;\n const DEFAULT_DATA_URI_TAGS = addToSet({}, [\n 'audio',\n 'video',\n 'img',\n 'source',\n 'image',\n 'track',\n ]);\n\n /* Attributes safe for values like \"javascript:\" */\n let URI_SAFE_ATTRIBUTES = null;\n const DEFAULT_URI_SAFE_ATTRIBUTES = addToSet({}, [\n 'alt',\n 'class',\n 'for',\n 'id',\n 'label',\n 'name',\n 'pattern',\n 'placeholder',\n 'role',\n 'summary',\n 'title',\n 'value',\n 'style',\n 'xmlns',\n ]);\n\n const MATHML_NAMESPACE = 'http://www.w3.org/1998/Math/MathML';\n const SVG_NAMESPACE = 'http://www.w3.org/2000/svg';\n const HTML_NAMESPACE = 'http://www.w3.org/1999/xhtml';\n /* Document namespace */\n let NAMESPACE = HTML_NAMESPACE;\n let IS_EMPTY_INPUT = false;\n\n /* Allowed XHTML+XML namespaces */\n let ALLOWED_NAMESPACES = null;\n const DEFAULT_ALLOWED_NAMESPACES = addToSet(\n {},\n [MATHML_NAMESPACE, SVG_NAMESPACE, HTML_NAMESPACE],\n stringToString\n );\n\n /* Parsing of strict XHTML documents */\n let PARSER_MEDIA_TYPE;\n const SUPPORTED_PARSER_MEDIA_TYPES = ['application/xhtml+xml', 'text/html'];\n const DEFAULT_PARSER_MEDIA_TYPE = 'text/html';\n let transformCaseFunc;\n\n /* Keep a reference to config to pass to hooks */\n let CONFIG = null;\n\n /* Ideally, do not touch anything below this line */\n /* ______________________________________________ */\n\n const formElement = document.createElement('form');\n\n const isRegexOrFunction = function (testValue) {\n return testValue instanceof RegExp || testValue instanceof Function;\n };\n\n /**\n * _parseConfig\n *\n * @param {Object} cfg optional config literal\n */\n // eslint-disable-next-line complexity\n const _parseConfig = function (cfg) {\n if (CONFIG && CONFIG === cfg) {\n return;\n }\n\n /* Shield configuration object from tampering */\n if (!cfg || typeof cfg !== 'object') {\n cfg = {};\n }\n\n /* Shield configuration object from prototype pollution */\n cfg = clone(cfg);\n\n PARSER_MEDIA_TYPE =\n // eslint-disable-next-line unicorn/prefer-includes\n SUPPORTED_PARSER_MEDIA_TYPES.indexOf(cfg.PARSER_MEDIA_TYPE) === -1\n ? (PARSER_MEDIA_TYPE = DEFAULT_PARSER_MEDIA_TYPE)\n : (PARSER_MEDIA_TYPE = cfg.PARSER_MEDIA_TYPE);\n\n // HTML tags and attributes are not case-sensitive, converting to lowercase. Keeping XHTML as is.\n transformCaseFunc =\n PARSER_MEDIA_TYPE === 'application/xhtml+xml'\n ? stringToString\n : stringToLowerCase;\n\n /* Set configuration parameters */\n ALLOWED_TAGS =\n 'ALLOWED_TAGS' in cfg\n ? addToSet({}, cfg.ALLOWED_TAGS, transformCaseFunc)\n : DEFAULT_ALLOWED_TAGS;\n ALLOWED_ATTR =\n 'ALLOWED_ATTR' in cfg\n ? addToSet({}, cfg.ALLOWED_ATTR, transformCaseFunc)\n : DEFAULT_ALLOWED_ATTR;\n ALLOWED_NAMESPACES =\n 'ALLOWED_NAMESPACES' in cfg\n ? addToSet({}, cfg.ALLOWED_NAMESPACES, stringToString)\n : DEFAULT_ALLOWED_NAMESPACES;\n URI_SAFE_ATTRIBUTES =\n 'ADD_URI_SAFE_ATTR' in cfg\n ? addToSet(\n clone(DEFAULT_URI_SAFE_ATTRIBUTES), // eslint-disable-line indent\n cfg.ADD_URI_SAFE_ATTR, // eslint-disable-line indent\n transformCaseFunc // eslint-disable-line indent\n ) // eslint-disable-line indent\n : DEFAULT_URI_SAFE_ATTRIBUTES;\n DATA_URI_TAGS =\n 'ADD_DATA_URI_TAGS' in cfg\n ? addToSet(\n clone(DEFAULT_DATA_URI_TAGS), // eslint-disable-line indent\n cfg.ADD_DATA_URI_TAGS, // eslint-disable-line indent\n transformCaseFunc // eslint-disable-line indent\n ) // eslint-disable-line indent\n : DEFAULT_DATA_URI_TAGS;\n FORBID_CONTENTS =\n 'FORBID_CONTENTS' in cfg\n ? addToSet({}, cfg.FORBID_CONTENTS, transformCaseFunc)\n : DEFAULT_FORBID_CONTENTS;\n FORBID_TAGS =\n 'FORBID_TAGS' in cfg\n ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc)\n : {};\n FORBID_ATTR =\n 'FORBID_ATTR' in cfg\n ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc)\n : {};\n USE_PROFILES = 'USE_PROFILES' in cfg ? cfg.USE_PROFILES : false;\n ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false; // Default true\n ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false; // Default true\n ALLOW_UNKNOWN_PROTOCOLS = cfg.ALLOW_UNKNOWN_PROTOCOLS || false; // Default false\n ALLOW_SELF_CLOSE_IN_ATTR = cfg.ALLOW_SELF_CLOSE_IN_ATTR !== false; // Default true\n SAFE_FOR_TEMPLATES = cfg.SAFE_FOR_TEMPLATES || false; // Default false\n WHOLE_DOCUMENT = cfg.WHOLE_DOCUMENT || false; // Default false\n RETURN_DOM = cfg.RETURN_DOM || false; // Default false\n RETURN_DOM_FRAGMENT = cfg.RETURN_DOM_FRAGMENT || false; // Default false\n RETURN_TRUSTED_TYPE = cfg.RETURN_TRUSTED_TYPE || false; // Default false\n FORCE_BODY = cfg.FORCE_BODY || false; // Default false\n SANITIZE_DOM = cfg.SANITIZE_DOM !== false; // Default true\n SANITIZE_NAMED_PROPS = cfg.SANITIZE_NAMED_PROPS || false; // Default false\n KEEP_CONTENT = cfg.KEEP_CONTENT !== false; // Default true\n IN_PLACE = cfg.IN_PLACE || false; // Default false\n IS_ALLOWED_URI = cfg.ALLOWED_URI_REGEXP || EXPRESSIONS.IS_ALLOWED_URI;\n NAMESPACE = cfg.NAMESPACE || HTML_NAMESPACE;\n CUSTOM_ELEMENT_HANDLING = cfg.CUSTOM_ELEMENT_HANDLING || {};\n if (\n cfg.CUSTOM_ELEMENT_HANDLING &&\n isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck)\n ) {\n CUSTOM_ELEMENT_HANDLING.tagNameCheck =\n cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck;\n }\n\n if (\n cfg.CUSTOM_ELEMENT_HANDLING &&\n isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)\n ) {\n CUSTOM_ELEMENT_HANDLING.attributeNameCheck =\n cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck;\n }\n\n if (\n cfg.CUSTOM_ELEMENT_HANDLING &&\n typeof cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements ===\n 'boolean'\n ) {\n CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements =\n cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements;\n }\n\n if (SAFE_FOR_TEMPLATES) {\n ALLOW_DATA_ATTR = false;\n }\n\n if (RETURN_DOM_FRAGMENT) {\n RETURN_DOM = true;\n }\n\n /* Parse profile info */\n if (USE_PROFILES) {\n ALLOWED_TAGS = addToSet({}, [...TAGS.text]);\n ALLOWED_ATTR = [];\n if (USE_PROFILES.html === true) {\n addToSet(ALLOWED_TAGS, TAGS.html);\n addToSet(ALLOWED_ATTR, ATTRS.html);\n }\n\n if (USE_PROFILES.svg === true) {\n addToSet(ALLOWED_TAGS, TAGS.svg);\n addToSet(ALLOWED_ATTR, ATTRS.svg);\n addToSet(ALLOWED_ATTR, ATTRS.xml);\n }\n\n if (USE_PROFILES.svgFilters === true) {\n addToSet(ALLOWED_TAGS, TAGS.svgFilters);\n addToSet(ALLOWED_ATTR, ATTRS.svg);\n addToSet(ALLOWED_ATTR, ATTRS.xml);\n }\n\n if (USE_PROFILES.mathMl === true) {\n addToSet(ALLOWED_TAGS, TAGS.mathMl);\n addToSet(ALLOWED_ATTR, ATTRS.mathMl);\n addToSet(ALLOWED_ATTR, ATTRS.xml);\n }\n }\n\n /* Merge configuration parameters */\n if (cfg.ADD_TAGS) {\n if (ALLOWED_TAGS === DEFAULT_ALLOWED_TAGS) {\n ALLOWED_TAGS = clone(ALLOWED_TAGS);\n }\n\n addToSet(ALLOWED_TAGS, cfg.ADD_TAGS, transformCaseFunc);\n }\n\n if (cfg.ADD_ATTR) {\n if (ALLOWED_ATTR === DEFAULT_ALLOWED_ATTR) {\n ALLOWED_ATTR = clone(ALLOWED_ATTR);\n }\n\n addToSet(ALLOWED_ATTR, cfg.ADD_ATTR, transformCaseFunc);\n }\n\n if (cfg.ADD_URI_SAFE_ATTR) {\n addToSet(URI_SAFE_ATTRIBUTES, cfg.ADD_URI_SAFE_ATTR, transformCaseFunc);\n }\n\n if (cfg.FORBID_CONTENTS) {\n if (FORBID_CONTENTS === DEFAULT_FORBID_CONTENTS) {\n FORBID_CONTENTS = clone(FORBID_CONTENTS);\n }\n\n addToSet(FORBID_CONTENTS, cfg.FORBID_CONTENTS, transformCaseFunc);\n }\n\n /* Add #text in case KEEP_CONTENT is set to true */\n if (KEEP_CONTENT) {\n ALLOWED_TAGS['#text'] = true;\n }\n\n /* Add html, head and body to ALLOWED_TAGS in case WHOLE_DOCUMENT is true */\n if (WHOLE_DOCUMENT) {\n addToSet(ALLOWED_TAGS, ['html', 'head', 'body']);\n }\n\n /* Add tbody to ALLOWED_TAGS in case tables are permitted, see #286, #365 */\n if (ALLOWED_TAGS.table) {\n addToSet(ALLOWED_TAGS, ['tbody']);\n delete FORBID_TAGS.tbody;\n }\n\n if (cfg.TRUSTED_TYPES_POLICY) {\n if (typeof cfg.TRUSTED_TYPES_POLICY.createHTML !== 'function') {\n throw typeErrorCreate(\n 'TRUSTED_TYPES_POLICY configuration option must provide a \"createHTML\" hook.'\n );\n }\n\n if (typeof cfg.TRUSTED_TYPES_POLICY.createScriptURL !== 'function') {\n throw typeErrorCreate(\n 'TRUSTED_TYPES_POLICY configuration option must provide a \"createScriptURL\" hook.'\n );\n }\n\n // Overwrite existing TrustedTypes policy.\n trustedTypesPolicy = cfg.TRUSTED_TYPES_POLICY;\n\n // Sign local variables required by `sanitize`.\n emptyHTML = trustedTypesPolicy.createHTML('');\n } else {\n // Uninitialized policy, attempt to initialize the internal dompurify policy.\n if (trustedTypesPolicy === undefined) {\n trustedTypesPolicy = _createTrustedTypesPolicy(\n trustedTypes,\n currentScript\n );\n }\n\n // If creating the internal policy succeeded sign internal variables.\n if (trustedTypesPolicy !== null && typeof emptyHTML === 'string') {\n emptyHTML = trustedTypesPolicy.createHTML('');\n }\n }\n\n // Prevent further manipulation of configuration.\n // Not available in IE8, Safari 5, etc.\n if (freeze) {\n freeze(cfg);\n }\n\n CONFIG = cfg;\n };\n\n const MATHML_TEXT_INTEGRATION_POINTS = addToSet({}, [\n 'mi',\n 'mo',\n 'mn',\n 'ms',\n 'mtext',\n ]);\n\n const HTML_INTEGRATION_POINTS = addToSet({}, [\n 'foreignobject',\n 'desc',\n 'title',\n 'annotation-xml',\n ]);\n\n // Certain elements are allowed in both SVG and HTML\n // namespace. We need to specify them explicitly\n // so that they don't get erroneously deleted from\n // HTML namespace.\n const COMMON_SVG_AND_HTML_ELEMENTS = addToSet({}, [\n 'title',\n 'style',\n 'font',\n 'a',\n 'script',\n ]);\n\n /* Keep track of all possible SVG and MathML tags\n * so that we can perform the namespace checks\n * correctly. */\n const ALL_SVG_TAGS = addToSet({}, TAGS.svg);\n addToSet(ALL_SVG_TAGS, TAGS.svgFilters);\n addToSet(ALL_SVG_TAGS, TAGS.svgDisallowed);\n\n const ALL_MATHML_TAGS = addToSet({}, TAGS.mathMl);\n addToSet(ALL_MATHML_TAGS, TAGS.mathMlDisallowed);\n\n /**\n *\n *\n * @param {Element} element a DOM element whose namespace is being checked\n * @returns {boolean} Return false if the element has a\n * namespace that a spec-compliant parser would never\n * return. Return true otherwise.\n */\n const _checkValidNamespace = function (element) {\n let parent = getParentNode(element);\n\n // In JSDOM, if we're inside shadow DOM, then parentNode\n // can be null. We just simulate parent in this case.\n if (!parent || !parent.tagName) {\n parent = {\n namespaceURI: NAMESPACE,\n tagName: 'template',\n };\n }\n\n const tagName = stringToLowerCase(element.tagName);\n const parentTagName = stringToLowerCase(parent.tagName);\n\n if (!ALLOWED_NAMESPACES[element.namespaceURI]) {\n return false;\n }\n\n if (element.namespaceURI === SVG_NAMESPACE) {\n // The only way to switch from HTML namespace to SVG\n // is via . If it happens via any other tag, then\n // it should be killed.\n if (parent.namespaceURI === HTML_NAMESPACE) {\n return tagName === 'svg';\n }\n\n // The only way to switch from MathML to SVG is via`\n // svg if parent is either or MathML\n // text integration points.\n if (parent.namespaceURI === MATHML_NAMESPACE) {\n return (\n tagName === 'svg' &&\n (parentTagName === 'annotation-xml' ||\n MATHML_TEXT_INTEGRATION_POINTS[parentTagName])\n );\n }\n\n // We only allow elements that are defined in SVG\n // spec. All others are disallowed in SVG namespace.\n return Boolean(ALL_SVG_TAGS[tagName]);\n }\n\n if (element.namespaceURI === MATHML_NAMESPACE) {\n // The only way to switch from HTML namespace to MathML\n // is via . If it happens via any other tag, then\n // it should be killed.\n if (parent.namespaceURI === HTML_NAMESPACE) {\n return tagName === 'math';\n }\n\n // The only way to switch from SVG to MathML is via\n // and HTML integration points\n if (parent.namespaceURI === SVG_NAMESPACE) {\n return tagName === 'math' && HTML_INTEGRATION_POINTS[parentTagName];\n }\n\n // We only allow elements that are defined in MathML\n // spec. All others are disallowed in MathML namespace.\n return Boolean(ALL_MATHML_TAGS[tagName]);\n }\n\n if (element.namespaceURI === HTML_NAMESPACE) {\n // The only way to switch from SVG to HTML is via\n // HTML integration points, and from MathML to HTML\n // is via MathML text integration points\n if (\n parent.namespaceURI === SVG_NAMESPACE &&\n !HTML_INTEGRATION_POINTS[parentTagName]\n ) {\n return false;\n }\n\n if (\n parent.namespaceURI === MATHML_NAMESPACE &&\n !MATHML_TEXT_INTEGRATION_POINTS[parentTagName]\n ) {\n return false;\n }\n\n // We disallow tags that are specific for MathML\n // or SVG and should never appear in HTML namespace\n return (\n !ALL_MATHML_TAGS[tagName] &&\n (COMMON_SVG_AND_HTML_ELEMENTS[tagName] || !ALL_SVG_TAGS[tagName])\n );\n }\n\n // For XHTML and XML documents that support custom namespaces\n if (\n PARSER_MEDIA_TYPE === 'application/xhtml+xml' &&\n ALLOWED_NAMESPACES[element.namespaceURI]\n ) {\n return true;\n }\n\n // The code should never reach this place (this means\n // that the element somehow got namespace that is not\n // HTML, SVG, MathML or allowed via ALLOWED_NAMESPACES).\n // Return false just in case.\n return false;\n };\n\n /**\n * _forceRemove\n *\n * @param {Node} node a DOM node\n */\n const _forceRemove = function (node) {\n arrayPush(DOMPurify.removed, { element: node });\n try {\n // eslint-disable-next-line unicorn/prefer-dom-node-remove\n node.parentNode.removeChild(node);\n } catch (_) {\n node.remove();\n }\n };\n\n /**\n * _removeAttribute\n *\n * @param {String} name an Attribute name\n * @param {Node} node a DOM node\n */\n const _removeAttribute = function (name, node) {\n try {\n arrayPush(DOMPurify.removed, {\n attribute: node.getAttributeNode(name),\n from: node,\n });\n } catch (_) {\n arrayPush(DOMPurify.removed, {\n attribute: null,\n from: node,\n });\n }\n\n node.removeAttribute(name);\n\n // We void attribute values for unremovable \"is\"\" attributes\n if (name === 'is' && !ALLOWED_ATTR[name]) {\n if (RETURN_DOM || RETURN_DOM_FRAGMENT) {\n try {\n _forceRemove(node);\n } catch (_) {}\n } else {\n try {\n node.setAttribute(name, '');\n } catch (_) {}\n }\n }\n };\n\n /**\n * _initDocument\n *\n * @param {String} dirty a string of dirty markup\n * @return {Document} a DOM, filled with the dirty markup\n */\n const _initDocument = function (dirty) {\n /* Create a HTML document */\n let doc;\n let leadingWhitespace;\n\n if (FORCE_BODY) {\n dirty = '' + dirty;\n } else {\n /* If FORCE_BODY isn't used, leading whitespace needs to be preserved manually */\n const matches = stringMatch(dirty, /^[\\r\\n\\t ]+/);\n leadingWhitespace = matches && matches[0];\n }\n\n if (\n PARSER_MEDIA_TYPE === 'application/xhtml+xml' &&\n NAMESPACE === HTML_NAMESPACE\n ) {\n // Root of XHTML doc must contain xmlns declaration (see https://www.w3.org/TR/xhtml1/normative.html#strict)\n dirty =\n '' +\n dirty +\n '';\n }\n\n const dirtyPayload = trustedTypesPolicy\n ? trustedTypesPolicy.createHTML(dirty)\n : dirty;\n /*\n * Use the DOMParser API by default, fallback later if needs be\n * DOMParser not work for svg when has multiple root element.\n */\n if (NAMESPACE === HTML_NAMESPACE) {\n try {\n doc = new DOMParser().parseFromString(dirtyPayload, PARSER_MEDIA_TYPE);\n } catch (_) {}\n }\n\n /* Use createHTMLDocument in case DOMParser is not available */\n if (!doc || !doc.documentElement) {\n doc = implementation.createDocument(NAMESPACE, 'template', null);\n try {\n doc.documentElement.innerHTML = IS_EMPTY_INPUT\n ? emptyHTML\n : dirtyPayload;\n } catch (_) {\n // Syntax error if dirtyPayload is invalid xml\n }\n }\n\n const body = doc.body || doc.documentElement;\n\n if (dirty && leadingWhitespace) {\n body.insertBefore(\n document.createTextNode(leadingWhitespace),\n body.childNodes[0] || null\n );\n }\n\n /* Work on whole document or just its body */\n if (NAMESPACE === HTML_NAMESPACE) {\n return getElementsByTagName.call(\n doc,\n WHOLE_DOCUMENT ? 'html' : 'body'\n )[0];\n }\n\n return WHOLE_DOCUMENT ? doc.documentElement : body;\n };\n\n /**\n * _createIterator\n *\n * @param {Document} root document/fragment to create iterator for\n * @return {Iterator} iterator instance\n */\n const _createIterator = function (root) {\n return createNodeIterator.call(\n root.ownerDocument || root,\n root,\n // eslint-disable-next-line no-bitwise\n NodeFilter.SHOW_ELEMENT | NodeFilter.SHOW_COMMENT | NodeFilter.SHOW_TEXT,\n null,\n false\n );\n };\n\n /**\n * _isClobbered\n *\n * @param {Node} elm element to check for clobbering attacks\n * @return {Boolean} true if clobbered, false if safe\n */\n const _isClobbered = function (elm) {\n return (\n elm instanceof HTMLFormElement &&\n (typeof elm.nodeName !== 'string' ||\n typeof elm.textContent !== 'string' ||\n typeof elm.removeChild !== 'function' ||\n !(elm.attributes instanceof NamedNodeMap) ||\n typeof elm.removeAttribute !== 'function' ||\n typeof elm.setAttribute !== 'function' ||\n typeof elm.namespaceURI !== 'string' ||\n typeof elm.insertBefore !== 'function' ||\n typeof elm.hasChildNodes !== 'function')\n );\n };\n\n /**\n * _isNode\n *\n * @param {Node} obj object to check whether it's a DOM node\n * @return {Boolean} true is object is a DOM node\n */\n const _isNode = function (object) {\n return typeof Node === 'object'\n ? object instanceof Node\n : object &&\n typeof object === 'object' &&\n typeof object.nodeType === 'number' &&\n typeof object.nodeName === 'string';\n };\n\n /**\n * _executeHook\n * Execute user configurable hooks\n *\n * @param {String} entryPoint Name of the hook's entry point\n * @param {Node} currentNode node to work on with the hook\n * @param {Object} data additional hook parameters\n */\n const _executeHook = function (entryPoint, currentNode, data) {\n if (!hooks[entryPoint]) {\n return;\n }\n\n arrayForEach(hooks[entryPoint], (hook) => {\n hook.call(DOMPurify, currentNode, data, CONFIG);\n });\n };\n\n /**\n * _sanitizeElements\n *\n * @protect nodeName\n * @protect textContent\n * @protect removeChild\n *\n * @param {Node} currentNode to check for permission to exist\n * @return {Boolean} true if node was killed, false if left alive\n */\n const _sanitizeElements = function (currentNode) {\n let content;\n\n /* Execute a hook if present */\n _executeHook('beforeSanitizeElements', currentNode, null);\n\n /* Check if element is clobbered or can clobber */\n if (_isClobbered(currentNode)) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Now let's check the element's type and name */\n const tagName = transformCaseFunc(currentNode.nodeName);\n\n /* Execute a hook if present */\n _executeHook('uponSanitizeElement', currentNode, {\n tagName,\n allowedTags: ALLOWED_TAGS,\n });\n\n /* Detect mXSS attempts abusing namespace confusion */\n if (\n currentNode.hasChildNodes() &&\n !_isNode(currentNode.firstElementChild) &&\n (!_isNode(currentNode.content) ||\n !_isNode(currentNode.content.firstElementChild)) &&\n regExpTest(/<[/\\w]/g, currentNode.innerHTML) &&\n regExpTest(/<[/\\w]/g, currentNode.textContent)\n ) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Remove element if anything forbids its presence */\n if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {\n /* Check if we have a custom element to handle */\n if (!FORBID_TAGS[tagName] && _basicCustomElementTest(tagName)) {\n if (\n CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, tagName)\n )\n return false;\n if (\n CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.tagNameCheck(tagName)\n )\n return false;\n }\n\n /* Keep content except for bad-listed elements */\n if (KEEP_CONTENT && !FORBID_CONTENTS[tagName]) {\n const parentNode = getParentNode(currentNode) || currentNode.parentNode;\n const childNodes = getChildNodes(currentNode) || currentNode.childNodes;\n\n if (childNodes && parentNode) {\n const childCount = childNodes.length;\n\n for (let i = childCount - 1; i >= 0; --i) {\n parentNode.insertBefore(\n cloneNode(childNodes[i], true),\n getNextSibling(currentNode)\n );\n }\n }\n }\n\n _forceRemove(currentNode);\n return true;\n }\n\n /* Check whether element has a valid namespace */\n if (currentNode instanceof Element && !_checkValidNamespace(currentNode)) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Make sure that older browsers don't get fallback-tag mXSS */\n if (\n (tagName === 'noscript' ||\n tagName === 'noembed' ||\n tagName === 'noframes') &&\n regExpTest(/<\\/no(script|embed|frames)/i, currentNode.innerHTML)\n ) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Sanitize element content to be template-safe */\n if (SAFE_FOR_TEMPLATES && currentNode.nodeType === 3) {\n /* Get the element's text content */\n content = currentNode.textContent;\n content = stringReplace(content, MUSTACHE_EXPR, ' ');\n content = stringReplace(content, ERB_EXPR, ' ');\n content = stringReplace(content, TMPLIT_EXPR, ' ');\n if (currentNode.textContent !== content) {\n arrayPush(DOMPurify.removed, { element: currentNode.cloneNode() });\n currentNode.textContent = content;\n }\n }\n\n /* Execute a hook if present */\n _executeHook('afterSanitizeElements', currentNode, null);\n\n return false;\n };\n\n /**\n * _isValidAttribute\n *\n * @param {string} lcTag Lowercase tag name of containing element.\n * @param {string} lcName Lowercase attribute name.\n * @param {string} value Attribute value.\n * @return {Boolean} Returns true if `value` is valid, otherwise false.\n */\n // eslint-disable-next-line complexity\n const _isValidAttribute = function (lcTag, lcName, value) {\n /* Make sure attribute cannot clobber */\n if (\n SANITIZE_DOM &&\n (lcName === 'id' || lcName === 'name') &&\n (value in document || value in formElement)\n ) {\n return false;\n }\n\n /* Allow valid data-* attributes: At least one character after \"-\"\n (https://html.spec.whatwg.org/multipage/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes)\n XML-compatible (https://html.spec.whatwg.org/multipage/infrastructure.html#xml-compatible and http://www.w3.org/TR/xml/#d0e804)\n We don't need to check the value; it's always URI safe. */\n if (\n ALLOW_DATA_ATTR &&\n !FORBID_ATTR[lcName] &&\n regExpTest(DATA_ATTR, lcName)\n ) {\n // This attribute is safe\n } else if (ALLOW_ARIA_ATTR && regExpTest(ARIA_ATTR, lcName)) {\n // This attribute is safe\n /* Otherwise, check the name is permitted */\n } else if (!ALLOWED_ATTR[lcName] || FORBID_ATTR[lcName]) {\n if (\n // First condition does a very basic check if a) it's basically a valid custom element tagname AND\n // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck\n // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck\n (_basicCustomElementTest(lcTag) &&\n ((CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, lcTag)) ||\n (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.tagNameCheck(lcTag))) &&\n ((CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.attributeNameCheck, lcName)) ||\n (CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.attributeNameCheck(lcName)))) ||\n // Alternative, second condition checks if it's an `is`-attribute, AND\n // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck\n (lcName === 'is' &&\n CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements &&\n ((CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, value)) ||\n (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.tagNameCheck(value))))\n ) {\n // If user has supplied a regexp or function in CUSTOM_ELEMENT_HANDLING.tagNameCheck, we need to also allow derived custom elements using the same tagName test.\n // Additionally, we need to allow attributes passing the CUSTOM_ELEMENT_HANDLING.attributeNameCheck user has configured, as custom elements can define these at their own discretion.\n } else {\n return false;\n }\n /* Check value is safe. First, is attr inert? If so, is safe */\n } else if (URI_SAFE_ATTRIBUTES[lcName]) {\n // This attribute is safe\n /* Check no script, data or unknown possibly unsafe URI\n unless we know URI values are safe for that attribute */\n } else if (\n regExpTest(IS_ALLOWED_URI, stringReplace(value, ATTR_WHITESPACE, ''))\n ) {\n // This attribute is safe\n /* Keep image data URIs alive if src/xlink:href is allowed */\n /* Further prevent gadget XSS for dynamically built script tags */\n } else if (\n (lcName === 'src' || lcName === 'xlink:href' || lcName === 'href') &&\n lcTag !== 'script' &&\n stringIndexOf(value, 'data:') === 0 &&\n DATA_URI_TAGS[lcTag]\n ) {\n // This attribute is safe\n /* Allow unknown protocols: This provides support for links that\n are handled by protocol handlers which may be unknown ahead of\n time, e.g. fb:, spotify: */\n } else if (\n ALLOW_UNKNOWN_PROTOCOLS &&\n !regExpTest(IS_SCRIPT_OR_DATA, stringReplace(value, ATTR_WHITESPACE, ''))\n ) {\n // This attribute is safe\n /* Check for binary attributes */\n } else if (value) {\n return false;\n } else {\n // Binary attributes are safe at this point\n /* Anything else, presume unsafe, do not add it back */\n }\n\n return true;\n };\n\n /**\n * _basicCustomElementCheck\n * checks if at least one dash is included in tagName, and it's not the first char\n * for more sophisticated checking see https://github.com/sindresorhus/validate-element-name\n * @param {string} tagName name of the tag of the node to sanitize\n */\n const _basicCustomElementTest = function (tagName) {\n return tagName.indexOf('-') > 0;\n };\n\n /**\n * _sanitizeAttributes\n *\n * @protect attributes\n * @protect nodeName\n * @protect removeAttribute\n * @protect setAttribute\n *\n * @param {Node} currentNode to sanitize\n */\n const _sanitizeAttributes = function (currentNode) {\n let attr;\n let value;\n let lcName;\n let l;\n /* Execute a hook if present */\n _executeHook('beforeSanitizeAttributes', currentNode, null);\n\n const { attributes } = currentNode;\n\n /* Check if we have attributes; if not we might have a text node */\n if (!attributes) {\n return;\n }\n\n const hookEvent = {\n attrName: '',\n attrValue: '',\n keepAttr: true,\n allowedAttributes: ALLOWED_ATTR,\n };\n l = attributes.length;\n\n /* Go backwards over all attributes; safely remove bad ones */\n while (l--) {\n attr = attributes[l];\n const { name, namespaceURI } = attr;\n value = name === 'value' ? attr.value : stringTrim(attr.value);\n lcName = transformCaseFunc(name);\n\n /* Execute a hook if present */\n hookEvent.attrName = lcName;\n hookEvent.attrValue = value;\n hookEvent.keepAttr = true;\n hookEvent.forceKeepAttr = undefined; // Allows developers to see this is a property they can set\n _executeHook('uponSanitizeAttribute', currentNode, hookEvent);\n value = hookEvent.attrValue;\n /* Did the hooks approve of the attribute? */\n if (hookEvent.forceKeepAttr) {\n continue;\n }\n\n /* Remove attribute */\n _removeAttribute(name, currentNode);\n\n /* Did the hooks approve of the attribute? */\n if (!hookEvent.keepAttr) {\n continue;\n }\n\n /* Work around a security issue in jQuery 3.0 */\n if (!ALLOW_SELF_CLOSE_IN_ATTR && regExpTest(/\\/>/i, value)) {\n _removeAttribute(name, currentNode);\n continue;\n }\n\n /* Sanitize attribute content to be template-safe */\n if (SAFE_FOR_TEMPLATES) {\n value = stringReplace(value, MUSTACHE_EXPR, ' ');\n value = stringReplace(value, ERB_EXPR, ' ');\n value = stringReplace(value, TMPLIT_EXPR, ' ');\n }\n\n /* Is `value` valid for this attribute? */\n const lcTag = transformCaseFunc(currentNode.nodeName);\n if (!_isValidAttribute(lcTag, lcName, value)) {\n continue;\n }\n\n /* Full DOM Clobbering protection via namespace isolation,\n * Prefix id and name attributes with `user-content-`\n */\n if (SANITIZE_NAMED_PROPS && (lcName === 'id' || lcName === 'name')) {\n // Remove the attribute with this value\n _removeAttribute(name, currentNode);\n\n // Prefix the value and later re-create the attribute with the sanitized value\n value = SANITIZE_NAMED_PROPS_PREFIX + value;\n }\n\n /* Handle attributes that require Trusted Types */\n if (\n trustedTypesPolicy &&\n typeof trustedTypes === 'object' &&\n typeof trustedTypes.getAttributeType === 'function'\n ) {\n if (namespaceURI) {\n /* Namespaces are not yet supported, see https://bugs.chromium.org/p/chromium/issues/detail?id=1305293 */\n } else {\n switch (trustedTypes.getAttributeType(lcTag, lcName)) {\n case 'TrustedHTML': {\n value = trustedTypesPolicy.createHTML(value);\n break;\n }\n\n case 'TrustedScriptURL': {\n value = trustedTypesPolicy.createScriptURL(value);\n break;\n }\n\n default: {\n break;\n }\n }\n }\n }\n\n /* Handle invalid data-* attribute set by try-catching it */\n try {\n if (namespaceURI) {\n currentNode.setAttributeNS(namespaceURI, name, value);\n } else {\n /* Fallback to setAttribute() for browser-unrecognized namespaces e.g. \"x-schema\". */\n currentNode.setAttribute(name, value);\n }\n\n arrayPop(DOMPurify.removed);\n } catch (_) {}\n }\n\n /* Execute a hook if present */\n _executeHook('afterSanitizeAttributes', currentNode, null);\n };\n\n /**\n * _sanitizeShadowDOM\n *\n * @param {DocumentFragment} fragment to iterate over recursively\n */\n const _sanitizeShadowDOM = function (fragment) {\n let shadowNode;\n const shadowIterator = _createIterator(fragment);\n\n /* Execute a hook if present */\n _executeHook('beforeSanitizeShadowDOM', fragment, null);\n\n while ((shadowNode = shadowIterator.nextNode())) {\n /* Execute a hook if present */\n _executeHook('uponSanitizeShadowNode', shadowNode, null);\n\n /* Sanitize tags and elements */\n if (_sanitizeElements(shadowNode)) {\n continue;\n }\n\n /* Deep shadow DOM detected */\n if (shadowNode.content instanceof DocumentFragment) {\n _sanitizeShadowDOM(shadowNode.content);\n }\n\n /* Check attributes, sanitize if necessary */\n _sanitizeAttributes(shadowNode);\n }\n\n /* Execute a hook if present */\n _executeHook('afterSanitizeShadowDOM', fragment, null);\n };\n\n /**\n * Sanitize\n * Public method providing core sanitation functionality\n *\n * @param {String|Node} dirty string or DOM node\n * @param {Object} configuration object\n */\n // eslint-disable-next-line complexity\n DOMPurify.sanitize = function (dirty, cfg = {}) {\n let body;\n let importedNode;\n let currentNode;\n let returnNode;\n /* Make sure we have a string to sanitize.\n DO NOT return early, as this will return the wrong type if\n the user has requested a DOM object rather than a string */\n IS_EMPTY_INPUT = !dirty;\n if (IS_EMPTY_INPUT) {\n dirty = '';\n }\n\n /* Stringify, in case dirty is an object */\n if (typeof dirty !== 'string' && !_isNode(dirty)) {\n if (typeof dirty.toString === 'function') {\n dirty = dirty.toString();\n if (typeof dirty !== 'string') {\n throw typeErrorCreate('dirty is not a string, aborting');\n }\n } else {\n throw typeErrorCreate('toString is not a function');\n }\n }\n\n /* Return dirty HTML if DOMPurify cannot run */\n if (!DOMPurify.isSupported) {\n return dirty;\n }\n\n /* Assign config vars */\n if (!SET_CONFIG) {\n _parseConfig(cfg);\n }\n\n /* Clean up removed elements */\n DOMPurify.removed = [];\n\n /* Check if dirty is correctly typed for IN_PLACE */\n if (typeof dirty === 'string') {\n IN_PLACE = false;\n }\n\n if (IN_PLACE) {\n /* Do some early pre-sanitization to avoid unsafe root nodes */\n if (dirty.nodeName) {\n const tagName = transformCaseFunc(dirty.nodeName);\n if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {\n throw typeErrorCreate(\n 'root node is forbidden and cannot be sanitized in-place'\n );\n }\n }\n } else if (dirty instanceof Node) {\n /* If dirty is a DOM element, append to an empty document to avoid\n elements being stripped by the parser */\n body = _initDocument('');\n importedNode = body.ownerDocument.importNode(dirty, true);\n if (importedNode.nodeType === 1 && importedNode.nodeName === 'BODY') {\n /* Node is already a body, use as is */\n body = importedNode;\n } else if (importedNode.nodeName === 'HTML') {\n body = importedNode;\n } else {\n // eslint-disable-next-line unicorn/prefer-dom-node-append\n body.appendChild(importedNode);\n }\n } else {\n /* Exit directly if we have nothing to do */\n if (\n !RETURN_DOM &&\n !SAFE_FOR_TEMPLATES &&\n !WHOLE_DOCUMENT &&\n // eslint-disable-next-line unicorn/prefer-includes\n dirty.indexOf('<') === -1\n ) {\n return trustedTypesPolicy && RETURN_TRUSTED_TYPE\n ? trustedTypesPolicy.createHTML(dirty)\n : dirty;\n }\n\n /* Initialize the document to work on */\n body = _initDocument(dirty);\n\n /* Check we have a DOM node from the data */\n if (!body) {\n return RETURN_DOM ? null : RETURN_TRUSTED_TYPE ? emptyHTML : '';\n }\n }\n\n /* Remove first element node (ours) if FORCE_BODY is set */\n if (body && FORCE_BODY) {\n _forceRemove(body.firstChild);\n }\n\n /* Get node iterator */\n const nodeIterator = _createIterator(IN_PLACE ? dirty : body);\n\n /* Now start iterating over the created document */\n while ((currentNode = nodeIterator.nextNode())) {\n /* Sanitize tags and elements */\n if (_sanitizeElements(currentNode)) {\n continue;\n }\n\n /* Shadow DOM detected, sanitize it */\n if (currentNode.content instanceof DocumentFragment) {\n _sanitizeShadowDOM(currentNode.content);\n }\n\n /* Check attributes, sanitize if necessary */\n _sanitizeAttributes(currentNode);\n }\n\n /* If we sanitized `dirty` in-place, return it. */\n if (IN_PLACE) {\n return dirty;\n }\n\n /* Return sanitized string or DOM */\n if (RETURN_DOM) {\n if (RETURN_DOM_FRAGMENT) {\n returnNode = createDocumentFragment.call(body.ownerDocument);\n\n while (body.firstChild) {\n // eslint-disable-next-line unicorn/prefer-dom-node-append\n returnNode.appendChild(body.firstChild);\n }\n } else {\n returnNode = body;\n }\n\n if (ALLOWED_ATTR.shadowroot || ALLOWED_ATTR.shadowrootmode) {\n /*\n AdoptNode() is not used because internal state is not reset\n (e.g. the past names map of a HTMLFormElement), this is safe\n in theory but we would rather not risk another attack vector.\n The state that is cloned by importNode() is explicitly defined\n by the specs.\n */\n returnNode = importNode.call(originalDocument, returnNode, true);\n }\n\n return returnNode;\n }\n\n let serializedHTML = WHOLE_DOCUMENT ? body.outerHTML : body.innerHTML;\n\n /* Serialize doctype if allowed */\n if (\n WHOLE_DOCUMENT &&\n ALLOWED_TAGS['!doctype'] &&\n body.ownerDocument &&\n body.ownerDocument.doctype &&\n body.ownerDocument.doctype.name &&\n regExpTest(EXPRESSIONS.DOCTYPE_NAME, body.ownerDocument.doctype.name)\n ) {\n serializedHTML =\n '\\n' + serializedHTML;\n }\n\n /* Sanitize final string template-safe */\n if (SAFE_FOR_TEMPLATES) {\n serializedHTML = stringReplace(serializedHTML, MUSTACHE_EXPR, ' ');\n serializedHTML = stringReplace(serializedHTML, ERB_EXPR, ' ');\n serializedHTML = stringReplace(serializedHTML, TMPLIT_EXPR, ' ');\n }\n\n return trustedTypesPolicy && RETURN_TRUSTED_TYPE\n ? trustedTypesPolicy.createHTML(serializedHTML)\n : serializedHTML;\n };\n\n /**\n * Public method to set the configuration once\n * setConfig\n *\n * @param {Object} cfg configuration object\n */\n DOMPurify.setConfig = function (cfg) {\n _parseConfig(cfg);\n SET_CONFIG = true;\n };\n\n /**\n * Public method to remove the configuration\n * clearConfig\n *\n */\n DOMPurify.clearConfig = function () {\n CONFIG = null;\n SET_CONFIG = false;\n };\n\n /**\n * Public method to check if an attribute value is valid.\n * Uses last set config, if any. Otherwise, uses config defaults.\n * isValidAttribute\n *\n * @param {string} tag Tag name of containing element.\n * @param {string} attr Attribute name.\n * @param {string} value Attribute value.\n * @return {Boolean} Returns true if `value` is valid. Otherwise, returns false.\n */\n DOMPurify.isValidAttribute = function (tag, attr, value) {\n /* Initialize shared config vars if necessary. */\n if (!CONFIG) {\n _parseConfig({});\n }\n\n const lcTag = transformCaseFunc(tag);\n const lcName = transformCaseFunc(attr);\n return _isValidAttribute(lcTag, lcName, value);\n };\n\n /**\n * AddHook\n * Public method to add DOMPurify hooks\n *\n * @param {String} entryPoint entry point for the hook to add\n * @param {Function} hookFunction function to execute\n */\n DOMPurify.addHook = function (entryPoint, hookFunction) {\n if (typeof hookFunction !== 'function') {\n return;\n }\n\n hooks[entryPoint] = hooks[entryPoint] || [];\n arrayPush(hooks[entryPoint], hookFunction);\n };\n\n /**\n * RemoveHook\n * Public method to remove a DOMPurify hook at a given entryPoint\n * (pops it from the stack of hooks if more are present)\n *\n * @param {String} entryPoint entry point for the hook to remove\n * @return {Function} removed(popped) hook\n */\n DOMPurify.removeHook = function (entryPoint) {\n if (hooks[entryPoint]) {\n return arrayPop(hooks[entryPoint]);\n }\n };\n\n /**\n * RemoveHooks\n * Public method to remove all DOMPurify hooks at a given entryPoint\n *\n * @param {String} entryPoint entry point for the hooks to remove\n */\n DOMPurify.removeHooks = function (entryPoint) {\n if (hooks[entryPoint]) {\n hooks[entryPoint] = [];\n }\n };\n\n /**\n * RemoveAllHooks\n * Public method to remove all DOMPurify hooks\n *\n */\n DOMPurify.removeAllHooks = function () {\n hooks = {};\n };\n\n return DOMPurify;\n}\n\nexport default createDOMPurify();\n", "export function dedent(\n templ: TemplateStringsArray | string,\n ...values: unknown[]\n): string {\n let strings = Array.from(typeof templ === 'string' ? [templ] : templ);\n\n // 1. Remove trailing whitespace.\n strings[strings.length - 1] = strings[strings.length - 1].replace(\n /\\r?\\n([\\t ]*)$/,\n '',\n );\n\n // 2. Find all line breaks to determine the highest common indentation level.\n const indentLengths = strings.reduce((arr, str) => {\n const matches = str.match(/\\n([\\t ]+|(?!\\s).)/g);\n if (matches) {\n return arr.concat(\n matches.map((match) => match.match(/[\\t ]/g)?.length ?? 0),\n );\n }\n return arr;\n }, []);\n\n // 3. Remove the common indentation from all strings.\n if (indentLengths.length) {\n const pattern = new RegExp(`\\n[\\t ]{${Math.min(...indentLengths)}}`, 'g');\n\n strings = strings.map((str) => str.replace(pattern, '\\n'));\n }\n\n // 4. Remove leading whitespace.\n strings[0] = strings[0].replace(/^\\r?\\n/, '');\n\n // 5. Perform interpolation.\n let string = strings[0];\n\n values.forEach((value, i) => {\n // 5.1 Read current indentation level\n const endentations = string.match(/(?:^|\\n)( *)$/)\n const endentation = endentations ? endentations[1] : ''\n let indentedValue = value\n // 5.2 Add indentation to values with multiline strings\n if (typeof value === 'string' && value.includes('\\n')) {\n indentedValue = String(value)\n .split('\\n')\n .map((str, i) => {\n return i === 0 ? str : `${endentation}${str}`\n })\n .join('\\n');\n }\n\n string += indentedValue + strings[i + 1];\n });\n\n return string;\n}\n\nexport default dedent;\n", "export default function max(values, valueof) {\n let max;\n if (valueof === undefined) {\n for (const value of values) {\n if (value != null\n && (max < value || (max === undefined && value >= value))) {\n max = value;\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null\n && (max < value || (max === undefined && value >= value))) {\n max = value;\n }\n }\n }\n return max;\n}\n", "export default function min(values, valueof) {\n let min;\n if (valueof === undefined) {\n for (const value of values) {\n if (value != null\n && (min > value || (min === undefined && value >= value))) {\n min = value;\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null\n && (min > value || (min === undefined && value >= value))) {\n min = value;\n }\n }\n }\n return min;\n}\n", "export default function ascending(a, b) {\n return a == null || b == null ? NaN : a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;\n}\n", "export default function descending(a, b) {\n return a == null || b == null ? NaN\n : b < a ? -1\n : b > a ? 1\n : b >= a ? 0\n : NaN;\n}\n", "import ascending from \"./ascending.js\";\nimport descending from \"./descending.js\";\n\nexport default function bisector(f) {\n let compare1, compare2, delta;\n\n // If an accessor is specified, promote it to a comparator. In this case we\n // can test whether the search value is (self-) comparable. We can\u2019t do this\n // for a comparator (except for specific, known comparators) because we can\u2019t\n // tell if the comparator is symmetric, and an asymmetric comparator can\u2019t be\n // used to test whether a single value is comparable.\n if (f.length !== 2) {\n compare1 = ascending;\n compare2 = (d, x) => ascending(f(d), x);\n delta = (d, x) => f(d) - x;\n } else {\n compare1 = f === ascending || f === descending ? f : zero;\n compare2 = f;\n delta = f;\n }\n\n function left(a, x, lo = 0, hi = a.length) {\n if (lo < hi) {\n if (compare1(x, x) !== 0) return hi;\n do {\n const mid = (lo + hi) >>> 1;\n if (compare2(a[mid], x) < 0) lo = mid + 1;\n else hi = mid;\n } while (lo < hi);\n }\n return lo;\n }\n\n function right(a, x, lo = 0, hi = a.length) {\n if (lo < hi) {\n if (compare1(x, x) !== 0) return hi;\n do {\n const mid = (lo + hi) >>> 1;\n if (compare2(a[mid], x) <= 0) lo = mid + 1;\n else hi = mid;\n } while (lo < hi);\n }\n return lo;\n }\n\n function center(a, x, lo = 0, hi = a.length) {\n const i = left(a, x, lo, hi - 1);\n return i > lo && delta(a[i - 1], x) > -delta(a[i], x) ? i - 1 : i;\n }\n\n return {left, center, right};\n}\n\nfunction zero() {\n return 0;\n}\n", "export default function number(x) {\n return x === null ? NaN : +x;\n}\n\nexport function* numbers(values, valueof) {\n if (valueof === undefined) {\n for (let value of values) {\n if (value != null && (value = +value) >= value) {\n yield value;\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null && (value = +value) >= value) {\n yield value;\n }\n }\n }\n}\n", "import ascending from \"./ascending.js\";\nimport bisector from \"./bisector.js\";\nimport number from \"./number.js\";\n\nconst ascendingBisect = bisector(ascending);\nexport const bisectRight = ascendingBisect.right;\nexport const bisectLeft = ascendingBisect.left;\nexport const bisectCenter = bisector(number).center;\nexport default bisectRight;\n", "export class InternMap extends Map {\n constructor(entries, key = keyof) {\n super();\n Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}});\n if (entries != null) for (const [key, value] of entries) this.set(key, value);\n }\n get(key) {\n return super.get(intern_get(this, key));\n }\n has(key) {\n return super.has(intern_get(this, key));\n }\n set(key, value) {\n return super.set(intern_set(this, key), value);\n }\n delete(key) {\n return super.delete(intern_delete(this, key));\n }\n}\n\nexport class InternSet extends Set {\n constructor(values, key = keyof) {\n super();\n Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}});\n if (values != null) for (const value of values) this.add(value);\n }\n has(value) {\n return super.has(intern_get(this, value));\n }\n add(value) {\n return super.add(intern_set(this, value));\n }\n delete(value) {\n return super.delete(intern_delete(this, value));\n }\n}\n\nfunction intern_get({_intern, _key}, value) {\n const key = _key(value);\n return _intern.has(key) ? _intern.get(key) : value;\n}\n\nfunction intern_set({_intern, _key}, value) {\n const key = _key(value);\n if (_intern.has(key)) return _intern.get(key);\n _intern.set(key, value);\n return value;\n}\n\nfunction intern_delete({_intern, _key}, value) {\n const key = _key(value);\n if (_intern.has(key)) {\n value = _intern.get(key);\n _intern.delete(key);\n }\n return value;\n}\n\nfunction keyof(value) {\n return value !== null && typeof value === \"object\" ? value.valueOf() : value;\n}\n", "const e10 = Math.sqrt(50),\n e5 = Math.sqrt(10),\n e2 = Math.sqrt(2);\n\nfunction tickSpec(start, stop, count) {\n const step = (stop - start) / Math.max(0, count),\n power = Math.floor(Math.log10(step)),\n error = step / Math.pow(10, power),\n factor = error >= e10 ? 10 : error >= e5 ? 5 : error >= e2 ? 2 : 1;\n let i1, i2, inc;\n if (power < 0) {\n inc = Math.pow(10, -power) / factor;\n i1 = Math.round(start * inc);\n i2 = Math.round(stop * inc);\n if (i1 / inc < start) ++i1;\n if (i2 / inc > stop) --i2;\n inc = -inc;\n } else {\n inc = Math.pow(10, power) * factor;\n i1 = Math.round(start / inc);\n i2 = Math.round(stop / inc);\n if (i1 * inc < start) ++i1;\n if (i2 * inc > stop) --i2;\n }\n if (i2 < i1 && 0.5 <= count && count < 2) return tickSpec(start, stop, count * 2);\n return [i1, i2, inc];\n}\n\nexport default function ticks(start, stop, count) {\n stop = +stop, start = +start, count = +count;\n if (!(count > 0)) return [];\n if (start === stop) return [start];\n const reverse = stop < start, [i1, i2, inc] = reverse ? tickSpec(stop, start, count) : tickSpec(start, stop, count);\n if (!(i2 >= i1)) return [];\n const n = i2 - i1 + 1, ticks = new Array(n);\n if (reverse) {\n if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) / -inc;\n else for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) * inc;\n } else {\n if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) / -inc;\n else for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) * inc;\n }\n return ticks;\n}\n\nexport function tickIncrement(start, stop, count) {\n stop = +stop, start = +start, count = +count;\n return tickSpec(start, stop, count)[2];\n}\n\nexport function tickStep(start, stop, count) {\n stop = +stop, start = +start, count = +count;\n const reverse = stop < start, inc = reverse ? tickIncrement(stop, start, count) : tickIncrement(start, stop, count);\n return (reverse ? -1 : 1) * (inc < 0 ? 1 / -inc : inc);\n}\n", "export default function range(start, stop, step) {\n start = +start, stop = +stop, step = (n = arguments.length) < 2 ? (stop = start, start = 0, 1) : n < 3 ? 1 : +step;\n\n var i = -1,\n n = Math.max(0, Math.ceil((stop - start) / step)) | 0,\n range = new Array(n);\n\n while (++i < n) {\n range[i] = start + i * step;\n }\n\n return range;\n}\n", "export default function(x) {\n return x;\n}\n", "import identity from \"./identity.js\";\n\nvar top = 1,\n right = 2,\n bottom = 3,\n left = 4,\n epsilon = 1e-6;\n\nfunction translateX(x) {\n return \"translate(\" + x + \",0)\";\n}\n\nfunction translateY(y) {\n return \"translate(0,\" + y + \")\";\n}\n\nfunction number(scale) {\n return d => +scale(d);\n}\n\nfunction center(scale, offset) {\n offset = Math.max(0, scale.bandwidth() - offset * 2) / 2;\n if (scale.round()) offset = Math.round(offset);\n return d => +scale(d) + offset;\n}\n\nfunction entering() {\n return !this.__axis;\n}\n\nfunction axis(orient, scale) {\n var tickArguments = [],\n tickValues = null,\n tickFormat = null,\n tickSizeInner = 6,\n tickSizeOuter = 6,\n tickPadding = 3,\n offset = typeof window !== \"undefined\" && window.devicePixelRatio > 1 ? 0 : 0.5,\n k = orient === top || orient === left ? -1 : 1,\n x = orient === left || orient === right ? \"x\" : \"y\",\n transform = orient === top || orient === bottom ? translateX : translateY;\n\n function axis(context) {\n var values = tickValues == null ? (scale.ticks ? scale.ticks.apply(scale, tickArguments) : scale.domain()) : tickValues,\n format = tickFormat == null ? (scale.tickFormat ? scale.tickFormat.apply(scale, tickArguments) : identity) : tickFormat,\n spacing = Math.max(tickSizeInner, 0) + tickPadding,\n range = scale.range(),\n range0 = +range[0] + offset,\n range1 = +range[range.length - 1] + offset,\n position = (scale.bandwidth ? center : number)(scale.copy(), offset),\n selection = context.selection ? context.selection() : context,\n path = selection.selectAll(\".domain\").data([null]),\n tick = selection.selectAll(\".tick\").data(values, scale).order(),\n tickExit = tick.exit(),\n tickEnter = tick.enter().append(\"g\").attr(\"class\", \"tick\"),\n line = tick.select(\"line\"),\n text = tick.select(\"text\");\n\n path = path.merge(path.enter().insert(\"path\", \".tick\")\n .attr(\"class\", \"domain\")\n .attr(\"stroke\", \"currentColor\"));\n\n tick = tick.merge(tickEnter);\n\n line = line.merge(tickEnter.append(\"line\")\n .attr(\"stroke\", \"currentColor\")\n .attr(x + \"2\", k * tickSizeInner));\n\n text = text.merge(tickEnter.append(\"text\")\n .attr(\"fill\", \"currentColor\")\n .attr(x, k * spacing)\n .attr(\"dy\", orient === top ? \"0em\" : orient === bottom ? \"0.71em\" : \"0.32em\"));\n\n if (context !== selection) {\n path = path.transition(context);\n tick = tick.transition(context);\n line = line.transition(context);\n text = text.transition(context);\n\n tickExit = tickExit.transition(context)\n .attr(\"opacity\", epsilon)\n .attr(\"transform\", function(d) { return isFinite(d = position(d)) ? transform(d + offset) : this.getAttribute(\"transform\"); });\n\n tickEnter\n .attr(\"opacity\", epsilon)\n .attr(\"transform\", function(d) { var p = this.parentNode.__axis; return transform((p && isFinite(p = p(d)) ? p : position(d)) + offset); });\n }\n\n tickExit.remove();\n\n path\n .attr(\"d\", orient === left || orient === right\n ? (tickSizeOuter ? \"M\" + k * tickSizeOuter + \",\" + range0 + \"H\" + offset + \"V\" + range1 + \"H\" + k * tickSizeOuter : \"M\" + offset + \",\" + range0 + \"V\" + range1)\n : (tickSizeOuter ? \"M\" + range0 + \",\" + k * tickSizeOuter + \"V\" + offset + \"H\" + range1 + \"V\" + k * tickSizeOuter : \"M\" + range0 + \",\" + offset + \"H\" + range1));\n\n tick\n .attr(\"opacity\", 1)\n .attr(\"transform\", function(d) { return transform(position(d) + offset); });\n\n line\n .attr(x + \"2\", k * tickSizeInner);\n\n text\n .attr(x, k * spacing)\n .text(format);\n\n selection.filter(entering)\n .attr(\"fill\", \"none\")\n .attr(\"font-size\", 10)\n .attr(\"font-family\", \"sans-serif\")\n .attr(\"text-anchor\", orient === right ? \"start\" : orient === left ? \"end\" : \"middle\");\n\n selection\n .each(function() { this.__axis = position; });\n }\n\n axis.scale = function(_) {\n return arguments.length ? (scale = _, axis) : scale;\n };\n\n axis.ticks = function() {\n return tickArguments = Array.from(arguments), axis;\n };\n\n axis.tickArguments = function(_) {\n return arguments.length ? (tickArguments = _ == null ? [] : Array.from(_), axis) : tickArguments.slice();\n };\n\n axis.tickValues = function(_) {\n return arguments.length ? (tickValues = _ == null ? null : Array.from(_), axis) : tickValues && tickValues.slice();\n };\n\n axis.tickFormat = function(_) {\n return arguments.length ? (tickFormat = _, axis) : tickFormat;\n };\n\n axis.tickSize = function(_) {\n return arguments.length ? (tickSizeInner = tickSizeOuter = +_, axis) : tickSizeInner;\n };\n\n axis.tickSizeInner = function(_) {\n return arguments.length ? (tickSizeInner = +_, axis) : tickSizeInner;\n };\n\n axis.tickSizeOuter = function(_) {\n return arguments.length ? (tickSizeOuter = +_, axis) : tickSizeOuter;\n };\n\n axis.tickPadding = function(_) {\n return arguments.length ? (tickPadding = +_, axis) : tickPadding;\n };\n\n axis.offset = function(_) {\n return arguments.length ? (offset = +_, axis) : offset;\n };\n\n return axis;\n}\n\nexport function axisTop(scale) {\n return axis(top, scale);\n}\n\nexport function axisRight(scale) {\n return axis(right, scale);\n}\n\nexport function axisBottom(scale) {\n return axis(bottom, scale);\n}\n\nexport function axisLeft(scale) {\n return axis(left, scale);\n}\n", "function none() {}\n\nexport default function(selector) {\n return selector == null ? none : function() {\n return this.querySelector(selector);\n };\n}\n", "import {Selection} from \"./index.js\";\nimport selector from \"../selector.js\";\n\nexport default function(select) {\n if (typeof select !== \"function\") select = selector(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = new Array(n), node, subnode, i = 0; i < n; ++i) {\n if ((node = group[i]) && (subnode = select.call(node, node.__data__, i, group))) {\n if (\"__data__\" in node) subnode.__data__ = node.__data__;\n subgroup[i] = subnode;\n }\n }\n }\n\n return new Selection(subgroups, this._parents);\n}\n", "// Given something array like (or null), returns something that is strictly an\n// array. This is used to ensure that array-like objects passed to d3.selectAll\n// or selection.selectAll are converted into proper arrays when creating a\n// selection; we don\u2019t ever want to create a selection backed by a live\n// HTMLCollection or NodeList. However, note that selection.selectAll will use a\n// static NodeList as a group, since it safely derived from querySelectorAll.\nexport default function array(x) {\n return x == null ? [] : Array.isArray(x) ? x : Array.from(x);\n}\n", "function empty() {\n return [];\n}\n\nexport default function(selector) {\n return selector == null ? empty : function() {\n return this.querySelectorAll(selector);\n };\n}\n", "import {Selection} from \"./index.js\";\nimport array from \"../array.js\";\nimport selectorAll from \"../selectorAll.js\";\n\nfunction arrayAll(select) {\n return function() {\n return array(select.apply(this, arguments));\n };\n}\n\nexport default function(select) {\n if (typeof select === \"function\") select = arrayAll(select);\n else select = selectorAll(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = [], parents = [], j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n subgroups.push(select.call(node, node.__data__, i, group));\n parents.push(node);\n }\n }\n }\n\n return new Selection(subgroups, parents);\n}\n", "export default function(selector) {\n return function() {\n return this.matches(selector);\n };\n}\n\nexport function childMatcher(selector) {\n return function(node) {\n return node.matches(selector);\n };\n}\n\n", "import {childMatcher} from \"../matcher.js\";\n\nvar find = Array.prototype.find;\n\nfunction childFind(match) {\n return function() {\n return find.call(this.children, match);\n };\n}\n\nfunction childFirst() {\n return this.firstElementChild;\n}\n\nexport default function(match) {\n return this.select(match == null ? childFirst\n : childFind(typeof match === \"function\" ? match : childMatcher(match)));\n}\n", "import {childMatcher} from \"../matcher.js\";\n\nvar filter = Array.prototype.filter;\n\nfunction children() {\n return Array.from(this.children);\n}\n\nfunction childrenFilter(match) {\n return function() {\n return filter.call(this.children, match);\n };\n}\n\nexport default function(match) {\n return this.selectAll(match == null ? children\n : childrenFilter(typeof match === \"function\" ? match : childMatcher(match)));\n}\n", "import {Selection} from \"./index.js\";\nimport matcher from \"../matcher.js\";\n\nexport default function(match) {\n if (typeof match !== \"function\") match = matcher(match);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = [], node, i = 0; i < n; ++i) {\n if ((node = group[i]) && match.call(node, node.__data__, i, group)) {\n subgroup.push(node);\n }\n }\n }\n\n return new Selection(subgroups, this._parents);\n}\n", "export default function(update) {\n return new Array(update.length);\n}\n", "import sparse from \"./sparse.js\";\nimport {Selection} from \"./index.js\";\n\nexport default function() {\n return new Selection(this._enter || this._groups.map(sparse), this._parents);\n}\n\nexport function EnterNode(parent, datum) {\n this.ownerDocument = parent.ownerDocument;\n this.namespaceURI = parent.namespaceURI;\n this._next = null;\n this._parent = parent;\n this.__data__ = datum;\n}\n\nEnterNode.prototype = {\n constructor: EnterNode,\n appendChild: function(child) { return this._parent.insertBefore(child, this._next); },\n insertBefore: function(child, next) { return this._parent.insertBefore(child, next); },\n querySelector: function(selector) { return this._parent.querySelector(selector); },\n querySelectorAll: function(selector) { return this._parent.querySelectorAll(selector); }\n};\n", "export default function(x) {\n return function() {\n return x;\n };\n}\n", "import {Selection} from \"./index.js\";\nimport {EnterNode} from \"./enter.js\";\nimport constant from \"../constant.js\";\n\nfunction bindIndex(parent, group, enter, update, exit, data) {\n var i = 0,\n node,\n groupLength = group.length,\n dataLength = data.length;\n\n // Put any non-null nodes that fit into update.\n // Put any null nodes into enter.\n // Put any remaining data into enter.\n for (; i < dataLength; ++i) {\n if (node = group[i]) {\n node.__data__ = data[i];\n update[i] = node;\n } else {\n enter[i] = new EnterNode(parent, data[i]);\n }\n }\n\n // Put any non-null nodes that don\u2019t fit into exit.\n for (; i < groupLength; ++i) {\n if (node = group[i]) {\n exit[i] = node;\n }\n }\n}\n\nfunction bindKey(parent, group, enter, update, exit, data, key) {\n var i,\n node,\n nodeByKeyValue = new Map,\n groupLength = group.length,\n dataLength = data.length,\n keyValues = new Array(groupLength),\n keyValue;\n\n // Compute the key for each node.\n // If multiple nodes have the same key, the duplicates are added to exit.\n for (i = 0; i < groupLength; ++i) {\n if (node = group[i]) {\n keyValues[i] = keyValue = key.call(node, node.__data__, i, group) + \"\";\n if (nodeByKeyValue.has(keyValue)) {\n exit[i] = node;\n } else {\n nodeByKeyValue.set(keyValue, node);\n }\n }\n }\n\n // Compute the key for each datum.\n // If there a node associated with this key, join and add it to update.\n // If there is not (or the key is a duplicate), add it to enter.\n for (i = 0; i < dataLength; ++i) {\n keyValue = key.call(parent, data[i], i, data) + \"\";\n if (node = nodeByKeyValue.get(keyValue)) {\n update[i] = node;\n node.__data__ = data[i];\n nodeByKeyValue.delete(keyValue);\n } else {\n enter[i] = new EnterNode(parent, data[i]);\n }\n }\n\n // Add any remaining nodes that were not bound to data to exit.\n for (i = 0; i < groupLength; ++i) {\n if ((node = group[i]) && (nodeByKeyValue.get(keyValues[i]) === node)) {\n exit[i] = node;\n }\n }\n}\n\nfunction datum(node) {\n return node.__data__;\n}\n\nexport default function(value, key) {\n if (!arguments.length) return Array.from(this, datum);\n\n var bind = key ? bindKey : bindIndex,\n parents = this._parents,\n groups = this._groups;\n\n if (typeof value !== \"function\") value = constant(value);\n\n for (var m = groups.length, update = new Array(m), enter = new Array(m), exit = new Array(m), j = 0; j < m; ++j) {\n var parent = parents[j],\n group = groups[j],\n groupLength = group.length,\n data = arraylike(value.call(parent, parent && parent.__data__, j, parents)),\n dataLength = data.length,\n enterGroup = enter[j] = new Array(dataLength),\n updateGroup = update[j] = new Array(dataLength),\n exitGroup = exit[j] = new Array(groupLength);\n\n bind(parent, group, enterGroup, updateGroup, exitGroup, data, key);\n\n // Now connect the enter nodes to their following update node, such that\n // appendChild can insert the materialized enter node before this node,\n // rather than at the end of the parent node.\n for (var i0 = 0, i1 = 0, previous, next; i0 < dataLength; ++i0) {\n if (previous = enterGroup[i0]) {\n if (i0 >= i1) i1 = i0 + 1;\n while (!(next = updateGroup[i1]) && ++i1 < dataLength);\n previous._next = next || null;\n }\n }\n }\n\n update = new Selection(update, parents);\n update._enter = enter;\n update._exit = exit;\n return update;\n}\n\n// Given some data, this returns an array-like view of it: an object that\n// exposes a length property and allows numeric indexing. Note that unlike\n// selectAll, this isn\u2019t worried about \u201Clive\u201D collections because the resulting\n// array will only be used briefly while data is being bound. (It is possible to\n// cause the data to change while iterating by using a key function, but please\n// don\u2019t; we\u2019d rather avoid a gratuitous copy.)\nfunction arraylike(data) {\n return typeof data === \"object\" && \"length\" in data\n ? data // Array, TypedArray, NodeList, array-like\n : Array.from(data); // Map, Set, iterable, string, or anything else\n}\n", "import sparse from \"./sparse.js\";\nimport {Selection} from \"./index.js\";\n\nexport default function() {\n return new Selection(this._exit || this._groups.map(sparse), this._parents);\n}\n", "export default function(onenter, onupdate, onexit) {\n var enter = this.enter(), update = this, exit = this.exit();\n if (typeof onenter === \"function\") {\n enter = onenter(enter);\n if (enter) enter = enter.selection();\n } else {\n enter = enter.append(onenter + \"\");\n }\n if (onupdate != null) {\n update = onupdate(update);\n if (update) update = update.selection();\n }\n if (onexit == null) exit.remove(); else onexit(exit);\n return enter && update ? enter.merge(update).order() : update;\n}\n", "import {Selection} from \"./index.js\";\n\nexport default function(context) {\n var selection = context.selection ? context.selection() : context;\n\n for (var groups0 = this._groups, groups1 = selection._groups, m0 = groups0.length, m1 = groups1.length, m = Math.min(m0, m1), merges = new Array(m0), j = 0; j < m; ++j) {\n for (var group0 = groups0[j], group1 = groups1[j], n = group0.length, merge = merges[j] = new Array(n), node, i = 0; i < n; ++i) {\n if (node = group0[i] || group1[i]) {\n merge[i] = node;\n }\n }\n }\n\n for (; j < m0; ++j) {\n merges[j] = groups0[j];\n }\n\n return new Selection(merges, this._parents);\n}\n", "export default function() {\n\n for (var groups = this._groups, j = -1, m = groups.length; ++j < m;) {\n for (var group = groups[j], i = group.length - 1, next = group[i], node; --i >= 0;) {\n if (node = group[i]) {\n if (next && node.compareDocumentPosition(next) ^ 4) next.parentNode.insertBefore(node, next);\n next = node;\n }\n }\n }\n\n return this;\n}\n", "import {Selection} from \"./index.js\";\n\nexport default function(compare) {\n if (!compare) compare = ascending;\n\n function compareNode(a, b) {\n return a && b ? compare(a.__data__, b.__data__) : !a - !b;\n }\n\n for (var groups = this._groups, m = groups.length, sortgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, sortgroup = sortgroups[j] = new Array(n), node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n sortgroup[i] = node;\n }\n }\n sortgroup.sort(compareNode);\n }\n\n return new Selection(sortgroups, this._parents).order();\n}\n\nfunction ascending(a, b) {\n return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;\n}\n", "export default function() {\n var callback = arguments[0];\n arguments[0] = this;\n callback.apply(null, arguments);\n return this;\n}\n", "export default function() {\n return Array.from(this);\n}\n", "export default function() {\n\n for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {\n for (var group = groups[j], i = 0, n = group.length; i < n; ++i) {\n var node = group[i];\n if (node) return node;\n }\n }\n\n return null;\n}\n", "export default function() {\n let size = 0;\n for (const node of this) ++size; // eslint-disable-line no-unused-vars\n return size;\n}\n", "export default function() {\n return !this.node();\n}\n", "export default function(callback) {\n\n for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {\n for (var group = groups[j], i = 0, n = group.length, node; i < n; ++i) {\n if (node = group[i]) callback.call(node, node.__data__, i, group);\n }\n }\n\n return this;\n}\n", "export var xhtml = \"http://www.w3.org/1999/xhtml\";\n\nexport default {\n svg: \"http://www.w3.org/2000/svg\",\n xhtml: xhtml,\n xlink: \"http://www.w3.org/1999/xlink\",\n xml: \"http://www.w3.org/XML/1998/namespace\",\n xmlns: \"http://www.w3.org/2000/xmlns/\"\n};\n", "import namespaces from \"./namespaces.js\";\n\nexport default function(name) {\n var prefix = name += \"\", i = prefix.indexOf(\":\");\n if (i >= 0 && (prefix = name.slice(0, i)) !== \"xmlns\") name = name.slice(i + 1);\n return namespaces.hasOwnProperty(prefix) ? {space: namespaces[prefix], local: name} : name; // eslint-disable-line no-prototype-builtins\n}\n", "import namespace from \"../namespace.js\";\n\nfunction attrRemove(name) {\n return function() {\n this.removeAttribute(name);\n };\n}\n\nfunction attrRemoveNS(fullname) {\n return function() {\n this.removeAttributeNS(fullname.space, fullname.local);\n };\n}\n\nfunction attrConstant(name, value) {\n return function() {\n this.setAttribute(name, value);\n };\n}\n\nfunction attrConstantNS(fullname, value) {\n return function() {\n this.setAttributeNS(fullname.space, fullname.local, value);\n };\n}\n\nfunction attrFunction(name, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) this.removeAttribute(name);\n else this.setAttribute(name, v);\n };\n}\n\nfunction attrFunctionNS(fullname, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) this.removeAttributeNS(fullname.space, fullname.local);\n else this.setAttributeNS(fullname.space, fullname.local, v);\n };\n}\n\nexport default function(name, value) {\n var fullname = namespace(name);\n\n if (arguments.length < 2) {\n var node = this.node();\n return fullname.local\n ? node.getAttributeNS(fullname.space, fullname.local)\n : node.getAttribute(fullname);\n }\n\n return this.each((value == null\n ? (fullname.local ? attrRemoveNS : attrRemove) : (typeof value === \"function\"\n ? (fullname.local ? attrFunctionNS : attrFunction)\n : (fullname.local ? attrConstantNS : attrConstant)))(fullname, value));\n}\n", "export default function(node) {\n return (node.ownerDocument && node.ownerDocument.defaultView) // node is a Node\n || (node.document && node) // node is a Window\n || node.defaultView; // node is a Document\n}\n", "import defaultView from \"../window.js\";\n\nfunction styleRemove(name) {\n return function() {\n this.style.removeProperty(name);\n };\n}\n\nfunction styleConstant(name, value, priority) {\n return function() {\n this.style.setProperty(name, value, priority);\n };\n}\n\nfunction styleFunction(name, value, priority) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) this.style.removeProperty(name);\n else this.style.setProperty(name, v, priority);\n };\n}\n\nexport default function(name, value, priority) {\n return arguments.length > 1\n ? this.each((value == null\n ? styleRemove : typeof value === \"function\"\n ? styleFunction\n : styleConstant)(name, value, priority == null ? \"\" : priority))\n : styleValue(this.node(), name);\n}\n\nexport function styleValue(node, name) {\n return node.style.getPropertyValue(name)\n || defaultView(node).getComputedStyle(node, null).getPropertyValue(name);\n}\n", "function propertyRemove(name) {\n return function() {\n delete this[name];\n };\n}\n\nfunction propertyConstant(name, value) {\n return function() {\n this[name] = value;\n };\n}\n\nfunction propertyFunction(name, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) delete this[name];\n else this[name] = v;\n };\n}\n\nexport default function(name, value) {\n return arguments.length > 1\n ? this.each((value == null\n ? propertyRemove : typeof value === \"function\"\n ? propertyFunction\n : propertyConstant)(name, value))\n : this.node()[name];\n}\n", "function classArray(string) {\n return string.trim().split(/^|\\s+/);\n}\n\nfunction classList(node) {\n return node.classList || new ClassList(node);\n}\n\nfunction ClassList(node) {\n this._node = node;\n this._names = classArray(node.getAttribute(\"class\") || \"\");\n}\n\nClassList.prototype = {\n add: function(name) {\n var i = this._names.indexOf(name);\n if (i < 0) {\n this._names.push(name);\n this._node.setAttribute(\"class\", this._names.join(\" \"));\n }\n },\n remove: function(name) {\n var i = this._names.indexOf(name);\n if (i >= 0) {\n this._names.splice(i, 1);\n this._node.setAttribute(\"class\", this._names.join(\" \"));\n }\n },\n contains: function(name) {\n return this._names.indexOf(name) >= 0;\n }\n};\n\nfunction classedAdd(node, names) {\n var list = classList(node), i = -1, n = names.length;\n while (++i < n) list.add(names[i]);\n}\n\nfunction classedRemove(node, names) {\n var list = classList(node), i = -1, n = names.length;\n while (++i < n) list.remove(names[i]);\n}\n\nfunction classedTrue(names) {\n return function() {\n classedAdd(this, names);\n };\n}\n\nfunction classedFalse(names) {\n return function() {\n classedRemove(this, names);\n };\n}\n\nfunction classedFunction(names, value) {\n return function() {\n (value.apply(this, arguments) ? classedAdd : classedRemove)(this, names);\n };\n}\n\nexport default function(name, value) {\n var names = classArray(name + \"\");\n\n if (arguments.length < 2) {\n var list = classList(this.node()), i = -1, n = names.length;\n while (++i < n) if (!list.contains(names[i])) return false;\n return true;\n }\n\n return this.each((typeof value === \"function\"\n ? classedFunction : value\n ? classedTrue\n : classedFalse)(names, value));\n}\n", "function textRemove() {\n this.textContent = \"\";\n}\n\nfunction textConstant(value) {\n return function() {\n this.textContent = value;\n };\n}\n\nfunction textFunction(value) {\n return function() {\n var v = value.apply(this, arguments);\n this.textContent = v == null ? \"\" : v;\n };\n}\n\nexport default function(value) {\n return arguments.length\n ? this.each(value == null\n ? textRemove : (typeof value === \"function\"\n ? textFunction\n : textConstant)(value))\n : this.node().textContent;\n}\n", "function htmlRemove() {\n this.innerHTML = \"\";\n}\n\nfunction htmlConstant(value) {\n return function() {\n this.innerHTML = value;\n };\n}\n\nfunction htmlFunction(value) {\n return function() {\n var v = value.apply(this, arguments);\n this.innerHTML = v == null ? \"\" : v;\n };\n}\n\nexport default function(value) {\n return arguments.length\n ? this.each(value == null\n ? htmlRemove : (typeof value === \"function\"\n ? htmlFunction\n : htmlConstant)(value))\n : this.node().innerHTML;\n}\n", "function raise() {\n if (this.nextSibling) this.parentNode.appendChild(this);\n}\n\nexport default function() {\n return this.each(raise);\n}\n", "function lower() {\n if (this.previousSibling) this.parentNode.insertBefore(this, this.parentNode.firstChild);\n}\n\nexport default function() {\n return this.each(lower);\n}\n", "import namespace from \"./namespace.js\";\nimport {xhtml} from \"./namespaces.js\";\n\nfunction creatorInherit(name) {\n return function() {\n var document = this.ownerDocument,\n uri = this.namespaceURI;\n return uri === xhtml && document.documentElement.namespaceURI === xhtml\n ? document.createElement(name)\n : document.createElementNS(uri, name);\n };\n}\n\nfunction creatorFixed(fullname) {\n return function() {\n return this.ownerDocument.createElementNS(fullname.space, fullname.local);\n };\n}\n\nexport default function(name) {\n var fullname = namespace(name);\n return (fullname.local\n ? creatorFixed\n : creatorInherit)(fullname);\n}\n", "import creator from \"../creator.js\";\n\nexport default function(name) {\n var create = typeof name === \"function\" ? name : creator(name);\n return this.select(function() {\n return this.appendChild(create.apply(this, arguments));\n });\n}\n", "import creator from \"../creator.js\";\nimport selector from \"../selector.js\";\n\nfunction constantNull() {\n return null;\n}\n\nexport default function(name, before) {\n var create = typeof name === \"function\" ? name : creator(name),\n select = before == null ? constantNull : typeof before === \"function\" ? before : selector(before);\n return this.select(function() {\n return this.insertBefore(create.apply(this, arguments), select.apply(this, arguments) || null);\n });\n}\n", "function remove() {\n var parent = this.parentNode;\n if (parent) parent.removeChild(this);\n}\n\nexport default function() {\n return this.each(remove);\n}\n", "function selection_cloneShallow() {\n var clone = this.cloneNode(false), parent = this.parentNode;\n return parent ? parent.insertBefore(clone, this.nextSibling) : clone;\n}\n\nfunction selection_cloneDeep() {\n var clone = this.cloneNode(true), parent = this.parentNode;\n return parent ? parent.insertBefore(clone, this.nextSibling) : clone;\n}\n\nexport default function(deep) {\n return this.select(deep ? selection_cloneDeep : selection_cloneShallow);\n}\n", "export default function(value) {\n return arguments.length\n ? this.property(\"__data__\", value)\n : this.node().__data__;\n}\n", "function contextListener(listener) {\n return function(event) {\n listener.call(this, event, this.__data__);\n };\n}\n\nfunction parseTypenames(typenames) {\n return typenames.trim().split(/^|\\s+/).map(function(t) {\n var name = \"\", i = t.indexOf(\".\");\n if (i >= 0) name = t.slice(i + 1), t = t.slice(0, i);\n return {type: t, name: name};\n });\n}\n\nfunction onRemove(typename) {\n return function() {\n var on = this.__on;\n if (!on) return;\n for (var j = 0, i = -1, m = on.length, o; j < m; ++j) {\n if (o = on[j], (!typename.type || o.type === typename.type) && o.name === typename.name) {\n this.removeEventListener(o.type, o.listener, o.options);\n } else {\n on[++i] = o;\n }\n }\n if (++i) on.length = i;\n else delete this.__on;\n };\n}\n\nfunction onAdd(typename, value, options) {\n return function() {\n var on = this.__on, o, listener = contextListener(value);\n if (on) for (var j = 0, m = on.length; j < m; ++j) {\n if ((o = on[j]).type === typename.type && o.name === typename.name) {\n this.removeEventListener(o.type, o.listener, o.options);\n this.addEventListener(o.type, o.listener = listener, o.options = options);\n o.value = value;\n return;\n }\n }\n this.addEventListener(typename.type, listener, options);\n o = {type: typename.type, name: typename.name, value: value, listener: listener, options: options};\n if (!on) this.__on = [o];\n else on.push(o);\n };\n}\n\nexport default function(typename, value, options) {\n var typenames = parseTypenames(typename + \"\"), i, n = typenames.length, t;\n\n if (arguments.length < 2) {\n var on = this.node().__on;\n if (on) for (var j = 0, m = on.length, o; j < m; ++j) {\n for (i = 0, o = on[j]; i < n; ++i) {\n if ((t = typenames[i]).type === o.type && t.name === o.name) {\n return o.value;\n }\n }\n }\n return;\n }\n\n on = value ? onAdd : onRemove;\n for (i = 0; i < n; ++i) this.each(on(typenames[i], value, options));\n return this;\n}\n", "import defaultView from \"../window.js\";\n\nfunction dispatchEvent(node, type, params) {\n var window = defaultView(node),\n event = window.CustomEvent;\n\n if (typeof event === \"function\") {\n event = new event(type, params);\n } else {\n event = window.document.createEvent(\"Event\");\n if (params) event.initEvent(type, params.bubbles, params.cancelable), event.detail = params.detail;\n else event.initEvent(type, false, false);\n }\n\n node.dispatchEvent(event);\n}\n\nfunction dispatchConstant(type, params) {\n return function() {\n return dispatchEvent(this, type, params);\n };\n}\n\nfunction dispatchFunction(type, params) {\n return function() {\n return dispatchEvent(this, type, params.apply(this, arguments));\n };\n}\n\nexport default function(type, params) {\n return this.each((typeof params === \"function\"\n ? dispatchFunction\n : dispatchConstant)(type, params));\n}\n", "export default function*() {\n for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {\n for (var group = groups[j], i = 0, n = group.length, node; i < n; ++i) {\n if (node = group[i]) yield node;\n }\n }\n}\n", "import selection_select from \"./select.js\";\nimport selection_selectAll from \"./selectAll.js\";\nimport selection_selectChild from \"./selectChild.js\";\nimport selection_selectChildren from \"./selectChildren.js\";\nimport selection_filter from \"./filter.js\";\nimport selection_data from \"./data.js\";\nimport selection_enter from \"./enter.js\";\nimport selection_exit from \"./exit.js\";\nimport selection_join from \"./join.js\";\nimport selection_merge from \"./merge.js\";\nimport selection_order from \"./order.js\";\nimport selection_sort from \"./sort.js\";\nimport selection_call from \"./call.js\";\nimport selection_nodes from \"./nodes.js\";\nimport selection_node from \"./node.js\";\nimport selection_size from \"./size.js\";\nimport selection_empty from \"./empty.js\";\nimport selection_each from \"./each.js\";\nimport selection_attr from \"./attr.js\";\nimport selection_style from \"./style.js\";\nimport selection_property from \"./property.js\";\nimport selection_classed from \"./classed.js\";\nimport selection_text from \"./text.js\";\nimport selection_html from \"./html.js\";\nimport selection_raise from \"./raise.js\";\nimport selection_lower from \"./lower.js\";\nimport selection_append from \"./append.js\";\nimport selection_insert from \"./insert.js\";\nimport selection_remove from \"./remove.js\";\nimport selection_clone from \"./clone.js\";\nimport selection_datum from \"./datum.js\";\nimport selection_on from \"./on.js\";\nimport selection_dispatch from \"./dispatch.js\";\nimport selection_iterator from \"./iterator.js\";\n\nexport var root = [null];\n\nexport function Selection(groups, parents) {\n this._groups = groups;\n this._parents = parents;\n}\n\nfunction selection() {\n return new Selection([[document.documentElement]], root);\n}\n\nfunction selection_selection() {\n return this;\n}\n\nSelection.prototype = selection.prototype = {\n constructor: Selection,\n select: selection_select,\n selectAll: selection_selectAll,\n selectChild: selection_selectChild,\n selectChildren: selection_selectChildren,\n filter: selection_filter,\n data: selection_data,\n enter: selection_enter,\n exit: selection_exit,\n join: selection_join,\n merge: selection_merge,\n selection: selection_selection,\n order: selection_order,\n sort: selection_sort,\n call: selection_call,\n nodes: selection_nodes,\n node: selection_node,\n size: selection_size,\n empty: selection_empty,\n each: selection_each,\n attr: selection_attr,\n style: selection_style,\n property: selection_property,\n classed: selection_classed,\n text: selection_text,\n html: selection_html,\n raise: selection_raise,\n lower: selection_lower,\n append: selection_append,\n insert: selection_insert,\n remove: selection_remove,\n clone: selection_clone,\n datum: selection_datum,\n on: selection_on,\n dispatch: selection_dispatch,\n [Symbol.iterator]: selection_iterator\n};\n\nexport default selection;\n", "import {Selection, root} from \"./selection/index.js\";\n\nexport default function(selector) {\n return typeof selector === \"string\"\n ? new Selection([[document.querySelector(selector)]], [document.documentElement])\n : new Selection([[selector]], root);\n}\n", "import array from \"./array.js\";\nimport {Selection, root} from \"./selection/index.js\";\n\nexport default function(selector) {\n return typeof selector === \"string\"\n ? new Selection([document.querySelectorAll(selector)], [document.documentElement])\n : new Selection([array(selector)], root);\n}\n", "export default function(constructor, factory, prototype) {\n constructor.prototype = factory.prototype = prototype;\n prototype.constructor = constructor;\n}\n\nexport function extend(parent, definition) {\n var prototype = Object.create(parent.prototype);\n for (var key in definition) prototype[key] = definition[key];\n return prototype;\n}\n", "import define, {extend} from \"./define.js\";\n\nexport function Color() {}\n\nexport var darker = 0.7;\nexport var brighter = 1 / darker;\n\nvar reI = \"\\\\s*([+-]?\\\\d+)\\\\s*\",\n reN = \"\\\\s*([+-]?(?:\\\\d*\\\\.)?\\\\d+(?:[eE][+-]?\\\\d+)?)\\\\s*\",\n reP = \"\\\\s*([+-]?(?:\\\\d*\\\\.)?\\\\d+(?:[eE][+-]?\\\\d+)?)%\\\\s*\",\n reHex = /^#([0-9a-f]{3,8})$/,\n reRgbInteger = new RegExp(`^rgb\\\\(${reI},${reI},${reI}\\\\)$`),\n reRgbPercent = new RegExp(`^rgb\\\\(${reP},${reP},${reP}\\\\)$`),\n reRgbaInteger = new RegExp(`^rgba\\\\(${reI},${reI},${reI},${reN}\\\\)$`),\n reRgbaPercent = new RegExp(`^rgba\\\\(${reP},${reP},${reP},${reN}\\\\)$`),\n reHslPercent = new RegExp(`^hsl\\\\(${reN},${reP},${reP}\\\\)$`),\n reHslaPercent = new RegExp(`^hsla\\\\(${reN},${reP},${reP},${reN}\\\\)$`);\n\nvar named = {\n aliceblue: 0xf0f8ff,\n antiquewhite: 0xfaebd7,\n aqua: 0x00ffff,\n aquamarine: 0x7fffd4,\n azure: 0xf0ffff,\n beige: 0xf5f5dc,\n bisque: 0xffe4c4,\n black: 0x000000,\n blanchedalmond: 0xffebcd,\n blue: 0x0000ff,\n blueviolet: 0x8a2be2,\n brown: 0xa52a2a,\n burlywood: 0xdeb887,\n cadetblue: 0x5f9ea0,\n chartreuse: 0x7fff00,\n chocolate: 0xd2691e,\n coral: 0xff7f50,\n cornflowerblue: 0x6495ed,\n cornsilk: 0xfff8dc,\n crimson: 0xdc143c,\n cyan: 0x00ffff,\n darkblue: 0x00008b,\n darkcyan: 0x008b8b,\n darkgoldenrod: 0xb8860b,\n darkgray: 0xa9a9a9,\n darkgreen: 0x006400,\n darkgrey: 0xa9a9a9,\n darkkhaki: 0xbdb76b,\n darkmagenta: 0x8b008b,\n darkolivegreen: 0x556b2f,\n darkorange: 0xff8c00,\n darkorchid: 0x9932cc,\n darkred: 0x8b0000,\n darksalmon: 0xe9967a,\n darkseagreen: 0x8fbc8f,\n darkslateblue: 0x483d8b,\n darkslategray: 0x2f4f4f,\n darkslategrey: 0x2f4f4f,\n darkturquoise: 0x00ced1,\n darkviolet: 0x9400d3,\n deeppink: 0xff1493,\n deepskyblue: 0x00bfff,\n dimgray: 0x696969,\n dimgrey: 0x696969,\n dodgerblue: 0x1e90ff,\n firebrick: 0xb22222,\n floralwhite: 0xfffaf0,\n forestgreen: 0x228b22,\n fuchsia: 0xff00ff,\n gainsboro: 0xdcdcdc,\n ghostwhite: 0xf8f8ff,\n gold: 0xffd700,\n goldenrod: 0xdaa520,\n gray: 0x808080,\n green: 0x008000,\n greenyellow: 0xadff2f,\n grey: 0x808080,\n honeydew: 0xf0fff0,\n hotpink: 0xff69b4,\n indianred: 0xcd5c5c,\n indigo: 0x4b0082,\n ivory: 0xfffff0,\n khaki: 0xf0e68c,\n lavender: 0xe6e6fa,\n lavenderblush: 0xfff0f5,\n lawngreen: 0x7cfc00,\n lemonchiffon: 0xfffacd,\n lightblue: 0xadd8e6,\n lightcoral: 0xf08080,\n lightcyan: 0xe0ffff,\n lightgoldenrodyellow: 0xfafad2,\n lightgray: 0xd3d3d3,\n lightgreen: 0x90ee90,\n lightgrey: 0xd3d3d3,\n lightpink: 0xffb6c1,\n lightsalmon: 0xffa07a,\n lightseagreen: 0x20b2aa,\n lightskyblue: 0x87cefa,\n lightslategray: 0x778899,\n lightslategrey: 0x778899,\n lightsteelblue: 0xb0c4de,\n lightyellow: 0xffffe0,\n lime: 0x00ff00,\n limegreen: 0x32cd32,\n linen: 0xfaf0e6,\n magenta: 0xff00ff,\n maroon: 0x800000,\n mediumaquamarine: 0x66cdaa,\n mediumblue: 0x0000cd,\n mediumorchid: 0xba55d3,\n mediumpurple: 0x9370db,\n mediumseagreen: 0x3cb371,\n mediumslateblue: 0x7b68ee,\n mediumspringgreen: 0x00fa9a,\n mediumturquoise: 0x48d1cc,\n mediumvioletred: 0xc71585,\n midnightblue: 0x191970,\n mintcream: 0xf5fffa,\n mistyrose: 0xffe4e1,\n moccasin: 0xffe4b5,\n navajowhite: 0xffdead,\n navy: 0x000080,\n oldlace: 0xfdf5e6,\n olive: 0x808000,\n olivedrab: 0x6b8e23,\n orange: 0xffa500,\n orangered: 0xff4500,\n orchid: 0xda70d6,\n palegoldenrod: 0xeee8aa,\n palegreen: 0x98fb98,\n paleturquoise: 0xafeeee,\n palevioletred: 0xdb7093,\n papayawhip: 0xffefd5,\n peachpuff: 0xffdab9,\n peru: 0xcd853f,\n pink: 0xffc0cb,\n plum: 0xdda0dd,\n powderblue: 0xb0e0e6,\n purple: 0x800080,\n rebeccapurple: 0x663399,\n red: 0xff0000,\n rosybrown: 0xbc8f8f,\n royalblue: 0x4169e1,\n saddlebrown: 0x8b4513,\n salmon: 0xfa8072,\n sandybrown: 0xf4a460,\n seagreen: 0x2e8b57,\n seashell: 0xfff5ee,\n sienna: 0xa0522d,\n silver: 0xc0c0c0,\n skyblue: 0x87ceeb,\n slateblue: 0x6a5acd,\n slategray: 0x708090,\n slategrey: 0x708090,\n snow: 0xfffafa,\n springgreen: 0x00ff7f,\n steelblue: 0x4682b4,\n tan: 0xd2b48c,\n teal: 0x008080,\n thistle: 0xd8bfd8,\n tomato: 0xff6347,\n turquoise: 0x40e0d0,\n violet: 0xee82ee,\n wheat: 0xf5deb3,\n white: 0xffffff,\n whitesmoke: 0xf5f5f5,\n yellow: 0xffff00,\n yellowgreen: 0x9acd32\n};\n\ndefine(Color, color, {\n copy(channels) {\n return Object.assign(new this.constructor, this, channels);\n },\n displayable() {\n return this.rgb().displayable();\n },\n hex: color_formatHex, // Deprecated! Use color.formatHex.\n formatHex: color_formatHex,\n formatHex8: color_formatHex8,\n formatHsl: color_formatHsl,\n formatRgb: color_formatRgb,\n toString: color_formatRgb\n});\n\nfunction color_formatHex() {\n return this.rgb().formatHex();\n}\n\nfunction color_formatHex8() {\n return this.rgb().formatHex8();\n}\n\nfunction color_formatHsl() {\n return hslConvert(this).formatHsl();\n}\n\nfunction color_formatRgb() {\n return this.rgb().formatRgb();\n}\n\nexport default function color(format) {\n var m, l;\n format = (format + \"\").trim().toLowerCase();\n return (m = reHex.exec(format)) ? (l = m[1].length, m = parseInt(m[1], 16), l === 6 ? rgbn(m) // #ff0000\n : l === 3 ? new Rgb((m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), ((m & 0xf) << 4) | (m & 0xf), 1) // #f00\n : l === 8 ? rgba(m >> 24 & 0xff, m >> 16 & 0xff, m >> 8 & 0xff, (m & 0xff) / 0xff) // #ff000000\n : l === 4 ? rgba((m >> 12 & 0xf) | (m >> 8 & 0xf0), (m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), (((m & 0xf) << 4) | (m & 0xf)) / 0xff) // #f000\n : null) // invalid hex\n : (m = reRgbInteger.exec(format)) ? new Rgb(m[1], m[2], m[3], 1) // rgb(255, 0, 0)\n : (m = reRgbPercent.exec(format)) ? new Rgb(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, 1) // rgb(100%, 0%, 0%)\n : (m = reRgbaInteger.exec(format)) ? rgba(m[1], m[2], m[3], m[4]) // rgba(255, 0, 0, 1)\n : (m = reRgbaPercent.exec(format)) ? rgba(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, m[4]) // rgb(100%, 0%, 0%, 1)\n : (m = reHslPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, 1) // hsl(120, 50%, 50%)\n : (m = reHslaPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, m[4]) // hsla(120, 50%, 50%, 1)\n : named.hasOwnProperty(format) ? rgbn(named[format]) // eslint-disable-line no-prototype-builtins\n : format === \"transparent\" ? new Rgb(NaN, NaN, NaN, 0)\n : null;\n}\n\nfunction rgbn(n) {\n return new Rgb(n >> 16 & 0xff, n >> 8 & 0xff, n & 0xff, 1);\n}\n\nfunction rgba(r, g, b, a) {\n if (a <= 0) r = g = b = NaN;\n return new Rgb(r, g, b, a);\n}\n\nexport function rgbConvert(o) {\n if (!(o instanceof Color)) o = color(o);\n if (!o) return new Rgb;\n o = o.rgb();\n return new Rgb(o.r, o.g, o.b, o.opacity);\n}\n\nexport function rgb(r, g, b, opacity) {\n return arguments.length === 1 ? rgbConvert(r) : new Rgb(r, g, b, opacity == null ? 1 : opacity);\n}\n\nexport function Rgb(r, g, b, opacity) {\n this.r = +r;\n this.g = +g;\n this.b = +b;\n this.opacity = +opacity;\n}\n\ndefine(Rgb, rgb, extend(Color, {\n brighter(k) {\n k = k == null ? brighter : Math.pow(brighter, k);\n return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity);\n },\n darker(k) {\n k = k == null ? darker : Math.pow(darker, k);\n return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity);\n },\n rgb() {\n return this;\n },\n clamp() {\n return new Rgb(clampi(this.r), clampi(this.g), clampi(this.b), clampa(this.opacity));\n },\n displayable() {\n return (-0.5 <= this.r && this.r < 255.5)\n && (-0.5 <= this.g && this.g < 255.5)\n && (-0.5 <= this.b && this.b < 255.5)\n && (0 <= this.opacity && this.opacity <= 1);\n },\n hex: rgb_formatHex, // Deprecated! Use color.formatHex.\n formatHex: rgb_formatHex,\n formatHex8: rgb_formatHex8,\n formatRgb: rgb_formatRgb,\n toString: rgb_formatRgb\n}));\n\nfunction rgb_formatHex() {\n return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}`;\n}\n\nfunction rgb_formatHex8() {\n return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}${hex((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`;\n}\n\nfunction rgb_formatRgb() {\n const a = clampa(this.opacity);\n return `${a === 1 ? \"rgb(\" : \"rgba(\"}${clampi(this.r)}, ${clampi(this.g)}, ${clampi(this.b)}${a === 1 ? \")\" : `, ${a})`}`;\n}\n\nfunction clampa(opacity) {\n return isNaN(opacity) ? 1 : Math.max(0, Math.min(1, opacity));\n}\n\nfunction clampi(value) {\n return Math.max(0, Math.min(255, Math.round(value) || 0));\n}\n\nfunction hex(value) {\n value = clampi(value);\n return (value < 16 ? \"0\" : \"\") + value.toString(16);\n}\n\nfunction hsla(h, s, l, a) {\n if (a <= 0) h = s = l = NaN;\n else if (l <= 0 || l >= 1) h = s = NaN;\n else if (s <= 0) h = NaN;\n return new Hsl(h, s, l, a);\n}\n\nexport function hslConvert(o) {\n if (o instanceof Hsl) return new Hsl(o.h, o.s, o.l, o.opacity);\n if (!(o instanceof Color)) o = color(o);\n if (!o) return new Hsl;\n if (o instanceof Hsl) return o;\n o = o.rgb();\n var r = o.r / 255,\n g = o.g / 255,\n b = o.b / 255,\n min = Math.min(r, g, b),\n max = Math.max(r, g, b),\n h = NaN,\n s = max - min,\n l = (max + min) / 2;\n if (s) {\n if (r === max) h = (g - b) / s + (g < b) * 6;\n else if (g === max) h = (b - r) / s + 2;\n else h = (r - g) / s + 4;\n s /= l < 0.5 ? max + min : 2 - max - min;\n h *= 60;\n } else {\n s = l > 0 && l < 1 ? 0 : h;\n }\n return new Hsl(h, s, l, o.opacity);\n}\n\nexport function hsl(h, s, l, opacity) {\n return arguments.length === 1 ? hslConvert(h) : new Hsl(h, s, l, opacity == null ? 1 : opacity);\n}\n\nfunction Hsl(h, s, l, opacity) {\n this.h = +h;\n this.s = +s;\n this.l = +l;\n this.opacity = +opacity;\n}\n\ndefine(Hsl, hsl, extend(Color, {\n brighter(k) {\n k = k == null ? brighter : Math.pow(brighter, k);\n return new Hsl(this.h, this.s, this.l * k, this.opacity);\n },\n darker(k) {\n k = k == null ? darker : Math.pow(darker, k);\n return new Hsl(this.h, this.s, this.l * k, this.opacity);\n },\n rgb() {\n var h = this.h % 360 + (this.h < 0) * 360,\n s = isNaN(h) || isNaN(this.s) ? 0 : this.s,\n l = this.l,\n m2 = l + (l < 0.5 ? l : 1 - l) * s,\n m1 = 2 * l - m2;\n return new Rgb(\n hsl2rgb(h >= 240 ? h - 240 : h + 120, m1, m2),\n hsl2rgb(h, m1, m2),\n hsl2rgb(h < 120 ? h + 240 : h - 120, m1, m2),\n this.opacity\n );\n },\n clamp() {\n return new Hsl(clamph(this.h), clampt(this.s), clampt(this.l), clampa(this.opacity));\n },\n displayable() {\n return (0 <= this.s && this.s <= 1 || isNaN(this.s))\n && (0 <= this.l && this.l <= 1)\n && (0 <= this.opacity && this.opacity <= 1);\n },\n formatHsl() {\n const a = clampa(this.opacity);\n return `${a === 1 ? \"hsl(\" : \"hsla(\"}${clamph(this.h)}, ${clampt(this.s) * 100}%, ${clampt(this.l) * 100}%${a === 1 ? \")\" : `, ${a})`}`;\n }\n}));\n\nfunction clamph(value) {\n value = (value || 0) % 360;\n return value < 0 ? value + 360 : value;\n}\n\nfunction clampt(value) {\n return Math.max(0, Math.min(1, value || 0));\n}\n\n/* From FvD 13.37, CSS Color Module Level 3 */\nfunction hsl2rgb(h, m1, m2) {\n return (h < 60 ? m1 + (m2 - m1) * h / 60\n : h < 180 ? m2\n : h < 240 ? m1 + (m2 - m1) * (240 - h) / 60\n : m1) * 255;\n}\n", "export const radians = Math.PI / 180;\nexport const degrees = 180 / Math.PI;\n", "import define, {extend} from \"./define.js\";\nimport {Color, rgbConvert, Rgb} from \"./color.js\";\nimport {degrees, radians} from \"./math.js\";\n\n// https://observablehq.com/@mbostock/lab-and-rgb\nconst K = 18,\n Xn = 0.96422,\n Yn = 1,\n Zn = 0.82521,\n t0 = 4 / 29,\n t1 = 6 / 29,\n t2 = 3 * t1 * t1,\n t3 = t1 * t1 * t1;\n\nfunction labConvert(o) {\n if (o instanceof Lab) return new Lab(o.l, o.a, o.b, o.opacity);\n if (o instanceof Hcl) return hcl2lab(o);\n if (!(o instanceof Rgb)) o = rgbConvert(o);\n var r = rgb2lrgb(o.r),\n g = rgb2lrgb(o.g),\n b = rgb2lrgb(o.b),\n y = xyz2lab((0.2225045 * r + 0.7168786 * g + 0.0606169 * b) / Yn), x, z;\n if (r === g && g === b) x = z = y; else {\n x = xyz2lab((0.4360747 * r + 0.3850649 * g + 0.1430804 * b) / Xn);\n z = xyz2lab((0.0139322 * r + 0.0971045 * g + 0.7141733 * b) / Zn);\n }\n return new Lab(116 * y - 16, 500 * (x - y), 200 * (y - z), o.opacity);\n}\n\nexport function gray(l, opacity) {\n return new Lab(l, 0, 0, opacity == null ? 1 : opacity);\n}\n\nexport default function lab(l, a, b, opacity) {\n return arguments.length === 1 ? labConvert(l) : new Lab(l, a, b, opacity == null ? 1 : opacity);\n}\n\nexport function Lab(l, a, b, opacity) {\n this.l = +l;\n this.a = +a;\n this.b = +b;\n this.opacity = +opacity;\n}\n\ndefine(Lab, lab, extend(Color, {\n brighter(k) {\n return new Lab(this.l + K * (k == null ? 1 : k), this.a, this.b, this.opacity);\n },\n darker(k) {\n return new Lab(this.l - K * (k == null ? 1 : k), this.a, this.b, this.opacity);\n },\n rgb() {\n var y = (this.l + 16) / 116,\n x = isNaN(this.a) ? y : y + this.a / 500,\n z = isNaN(this.b) ? y : y - this.b / 200;\n x = Xn * lab2xyz(x);\n y = Yn * lab2xyz(y);\n z = Zn * lab2xyz(z);\n return new Rgb(\n lrgb2rgb( 3.1338561 * x - 1.6168667 * y - 0.4906146 * z),\n lrgb2rgb(-0.9787684 * x + 1.9161415 * y + 0.0334540 * z),\n lrgb2rgb( 0.0719453 * x - 0.2289914 * y + 1.4052427 * z),\n this.opacity\n );\n }\n}));\n\nfunction xyz2lab(t) {\n return t > t3 ? Math.pow(t, 1 / 3) : t / t2 + t0;\n}\n\nfunction lab2xyz(t) {\n return t > t1 ? t * t * t : t2 * (t - t0);\n}\n\nfunction lrgb2rgb(x) {\n return 255 * (x <= 0.0031308 ? 12.92 * x : 1.055 * Math.pow(x, 1 / 2.4) - 0.055);\n}\n\nfunction rgb2lrgb(x) {\n return (x /= 255) <= 0.04045 ? x / 12.92 : Math.pow((x + 0.055) / 1.055, 2.4);\n}\n\nfunction hclConvert(o) {\n if (o instanceof Hcl) return new Hcl(o.h, o.c, o.l, o.opacity);\n if (!(o instanceof Lab)) o = labConvert(o);\n if (o.a === 0 && o.b === 0) return new Hcl(NaN, 0 < o.l && o.l < 100 ? 0 : NaN, o.l, o.opacity);\n var h = Math.atan2(o.b, o.a) * degrees;\n return new Hcl(h < 0 ? h + 360 : h, Math.sqrt(o.a * o.a + o.b * o.b), o.l, o.opacity);\n}\n\nexport function lch(l, c, h, opacity) {\n return arguments.length === 1 ? hclConvert(l) : new Hcl(h, c, l, opacity == null ? 1 : opacity);\n}\n\nexport function hcl(h, c, l, opacity) {\n return arguments.length === 1 ? hclConvert(h) : new Hcl(h, c, l, opacity == null ? 1 : opacity);\n}\n\nexport function Hcl(h, c, l, opacity) {\n this.h = +h;\n this.c = +c;\n this.l = +l;\n this.opacity = +opacity;\n}\n\nfunction hcl2lab(o) {\n if (isNaN(o.h)) return new Lab(o.l, 0, 0, o.opacity);\n var h = o.h * radians;\n return new Lab(o.l, Math.cos(h) * o.c, Math.sin(h) * o.c, o.opacity);\n}\n\ndefine(Hcl, hcl, extend(Color, {\n brighter(k) {\n return new Hcl(this.h, this.c, this.l + K * (k == null ? 1 : k), this.opacity);\n },\n darker(k) {\n return new Hcl(this.h, this.c, this.l - K * (k == null ? 1 : k), this.opacity);\n },\n rgb() {\n return hcl2lab(this).rgb();\n }\n}));\n", "export default x => () => x;\n", "import constant from \"./constant.js\";\n\nfunction linear(a, d) {\n return function(t) {\n return a + t * d;\n };\n}\n\nfunction exponential(a, b, y) {\n return a = Math.pow(a, y), b = Math.pow(b, y) - a, y = 1 / y, function(t) {\n return Math.pow(a + t * b, y);\n };\n}\n\nexport function hue(a, b) {\n var d = b - a;\n return d ? linear(a, d > 180 || d < -180 ? d - 360 * Math.round(d / 360) : d) : constant(isNaN(a) ? b : a);\n}\n\nexport function gamma(y) {\n return (y = +y) === 1 ? nogamma : function(a, b) {\n return b - a ? exponential(a, b, y) : constant(isNaN(a) ? b : a);\n };\n}\n\nexport default function nogamma(a, b) {\n var d = b - a;\n return d ? linear(a, d) : constant(isNaN(a) ? b : a);\n}\n", "import {hcl as colorHcl} from \"d3-color\";\nimport color, {hue} from \"./color.js\";\n\nfunction hcl(hue) {\n return function(start, end) {\n var h = hue((start = colorHcl(start)).h, (end = colorHcl(end)).h),\n c = color(start.c, end.c),\n l = color(start.l, end.l),\n opacity = color(start.opacity, end.opacity);\n return function(t) {\n start.h = h(t);\n start.c = c(t);\n start.l = l(t);\n start.opacity = opacity(t);\n return start + \"\";\n };\n }\n}\n\nexport default hcl(hue);\nexport var hclLong = hcl(color);\n", "export function basis(t1, v0, v1, v2, v3) {\n var t2 = t1 * t1, t3 = t2 * t1;\n return ((1 - 3 * t1 + 3 * t2 - t3) * v0\n + (4 - 6 * t2 + 3 * t3) * v1\n + (1 + 3 * t1 + 3 * t2 - 3 * t3) * v2\n + t3 * v3) / 6;\n}\n\nexport default function(values) {\n var n = values.length - 1;\n return function(t) {\n var i = t <= 0 ? (t = 0) : t >= 1 ? (t = 1, n - 1) : Math.floor(t * n),\n v1 = values[i],\n v2 = values[i + 1],\n v0 = i > 0 ? values[i - 1] : 2 * v1 - v2,\n v3 = i < n - 1 ? values[i + 2] : 2 * v2 - v1;\n return basis((t - i / n) * n, v0, v1, v2, v3);\n };\n}\n", "import {basis} from \"./basis.js\";\n\nexport default function(values) {\n var n = values.length;\n return function(t) {\n var i = Math.floor(((t %= 1) < 0 ? ++t : t) * n),\n v0 = values[(i + n - 1) % n],\n v1 = values[i % n],\n v2 = values[(i + 1) % n],\n v3 = values[(i + 2) % n];\n return basis((t - i / n) * n, v0, v1, v2, v3);\n };\n}\n", "import {rgb as colorRgb} from \"d3-color\";\nimport basis from \"./basis.js\";\nimport basisClosed from \"./basisClosed.js\";\nimport nogamma, {gamma} from \"./color.js\";\n\nexport default (function rgbGamma(y) {\n var color = gamma(y);\n\n function rgb(start, end) {\n var r = color((start = colorRgb(start)).r, (end = colorRgb(end)).r),\n g = color(start.g, end.g),\n b = color(start.b, end.b),\n opacity = nogamma(start.opacity, end.opacity);\n return function(t) {\n start.r = r(t);\n start.g = g(t);\n start.b = b(t);\n start.opacity = opacity(t);\n return start + \"\";\n };\n }\n\n rgb.gamma = rgbGamma;\n\n return rgb;\n})(1);\n\nfunction rgbSpline(spline) {\n return function(colors) {\n var n = colors.length,\n r = new Array(n),\n g = new Array(n),\n b = new Array(n),\n i, color;\n for (i = 0; i < n; ++i) {\n color = colorRgb(colors[i]);\n r[i] = color.r || 0;\n g[i] = color.g || 0;\n b[i] = color.b || 0;\n }\n r = spline(r);\n g = spline(g);\n b = spline(b);\n color.opacity = 1;\n return function(t) {\n color.r = r(t);\n color.g = g(t);\n color.b = b(t);\n return color + \"\";\n };\n };\n}\n\nexport var rgbBasis = rgbSpline(basis);\nexport var rgbBasisClosed = rgbSpline(basisClosed);\n", "export default function(a, b) {\n if (!b) b = [];\n var n = a ? Math.min(b.length, a.length) : 0,\n c = b.slice(),\n i;\n return function(t) {\n for (i = 0; i < n; ++i) c[i] = a[i] * (1 - t) + b[i] * t;\n return c;\n };\n}\n\nexport function isNumberArray(x) {\n return ArrayBuffer.isView(x) && !(x instanceof DataView);\n}\n", "import value from \"./value.js\";\nimport numberArray, {isNumberArray} from \"./numberArray.js\";\n\nexport default function(a, b) {\n return (isNumberArray(b) ? numberArray : genericArray)(a, b);\n}\n\nexport function genericArray(a, b) {\n var nb = b ? b.length : 0,\n na = a ? Math.min(nb, a.length) : 0,\n x = new Array(na),\n c = new Array(nb),\n i;\n\n for (i = 0; i < na; ++i) x[i] = value(a[i], b[i]);\n for (; i < nb; ++i) c[i] = b[i];\n\n return function(t) {\n for (i = 0; i < na; ++i) c[i] = x[i](t);\n return c;\n };\n}\n", "export default function(a, b) {\n var d = new Date;\n return a = +a, b = +b, function(t) {\n return d.setTime(a * (1 - t) + b * t), d;\n };\n}\n", "export default function(a, b) {\n return a = +a, b = +b, function(t) {\n return a * (1 - t) + b * t;\n };\n}\n", "import value from \"./value.js\";\n\nexport default function(a, b) {\n var i = {},\n c = {},\n k;\n\n if (a === null || typeof a !== \"object\") a = {};\n if (b === null || typeof b !== \"object\") b = {};\n\n for (k in b) {\n if (k in a) {\n i[k] = value(a[k], b[k]);\n } else {\n c[k] = b[k];\n }\n }\n\n return function(t) {\n for (k in i) c[k] = i[k](t);\n return c;\n };\n}\n", "import number from \"./number.js\";\n\nvar reA = /[-+]?(?:\\d+\\.?\\d*|\\.?\\d+)(?:[eE][-+]?\\d+)?/g,\n reB = new RegExp(reA.source, \"g\");\n\nfunction zero(b) {\n return function() {\n return b;\n };\n}\n\nfunction one(b) {\n return function(t) {\n return b(t) + \"\";\n };\n}\n\nexport default function(a, b) {\n var bi = reA.lastIndex = reB.lastIndex = 0, // scan index for next number in b\n am, // current match in a\n bm, // current match in b\n bs, // string preceding current number in b, if any\n i = -1, // index in s\n s = [], // string constants and placeholders\n q = []; // number interpolators\n\n // Coerce inputs to strings.\n a = a + \"\", b = b + \"\";\n\n // Interpolate pairs of numbers in a & b.\n while ((am = reA.exec(a))\n && (bm = reB.exec(b))) {\n if ((bs = bm.index) > bi) { // a string precedes the next number in b\n bs = b.slice(bi, bs);\n if (s[i]) s[i] += bs; // coalesce with previous string\n else s[++i] = bs;\n }\n if ((am = am[0]) === (bm = bm[0])) { // numbers in a & b match\n if (s[i]) s[i] += bm; // coalesce with previous string\n else s[++i] = bm;\n } else { // interpolate non-matching numbers\n s[++i] = null;\n q.push({i: i, x: number(am, bm)});\n }\n bi = reB.lastIndex;\n }\n\n // Add remains of b.\n if (bi < b.length) {\n bs = b.slice(bi);\n if (s[i]) s[i] += bs; // coalesce with previous string\n else s[++i] = bs;\n }\n\n // Special optimization for only a single match.\n // Otherwise, interpolate each of the numbers and rejoin the string.\n return s.length < 2 ? (q[0]\n ? one(q[0].x)\n : zero(b))\n : (b = q.length, function(t) {\n for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t);\n return s.join(\"\");\n });\n}\n", "import {color} from \"d3-color\";\nimport rgb from \"./rgb.js\";\nimport {genericArray} from \"./array.js\";\nimport date from \"./date.js\";\nimport number from \"./number.js\";\nimport object from \"./object.js\";\nimport string from \"./string.js\";\nimport constant from \"./constant.js\";\nimport numberArray, {isNumberArray} from \"./numberArray.js\";\n\nexport default function(a, b) {\n var t = typeof b, c;\n return b == null || t === \"boolean\" ? constant(b)\n : (t === \"number\" ? number\n : t === \"string\" ? ((c = color(b)) ? (b = c, rgb) : string)\n : b instanceof color ? rgb\n : b instanceof Date ? date\n : isNumberArray(b) ? numberArray\n : Array.isArray(b) ? genericArray\n : typeof b.valueOf !== \"function\" && typeof b.toString !== \"function\" || isNaN(b) ? object\n : number)(a, b);\n}\n", "export default function(a, b) {\n return a = +a, b = +b, function(t) {\n return Math.round(a * (1 - t) + b * t);\n };\n}\n", "var degrees = 180 / Math.PI;\n\nexport var identity = {\n translateX: 0,\n translateY: 0,\n rotate: 0,\n skewX: 0,\n scaleX: 1,\n scaleY: 1\n};\n\nexport default function(a, b, c, d, e, f) {\n var scaleX, scaleY, skewX;\n if (scaleX = Math.sqrt(a * a + b * b)) a /= scaleX, b /= scaleX;\n if (skewX = a * c + b * d) c -= a * skewX, d -= b * skewX;\n if (scaleY = Math.sqrt(c * c + d * d)) c /= scaleY, d /= scaleY, skewX /= scaleY;\n if (a * d < b * c) a = -a, b = -b, skewX = -skewX, scaleX = -scaleX;\n return {\n translateX: e,\n translateY: f,\n rotate: Math.atan2(b, a) * degrees,\n skewX: Math.atan(skewX) * degrees,\n scaleX: scaleX,\n scaleY: scaleY\n };\n}\n", "import decompose, {identity} from \"./decompose.js\";\n\nvar svgNode;\n\n/* eslint-disable no-undef */\nexport function parseCss(value) {\n const m = new (typeof DOMMatrix === \"function\" ? DOMMatrix : WebKitCSSMatrix)(value + \"\");\n return m.isIdentity ? identity : decompose(m.a, m.b, m.c, m.d, m.e, m.f);\n}\n\nexport function parseSvg(value) {\n if (value == null) return identity;\n if (!svgNode) svgNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"g\");\n svgNode.setAttribute(\"transform\", value);\n if (!(value = svgNode.transform.baseVal.consolidate())) return identity;\n value = value.matrix;\n return decompose(value.a, value.b, value.c, value.d, value.e, value.f);\n}\n", "import number from \"../number.js\";\nimport {parseCss, parseSvg} from \"./parse.js\";\n\nfunction interpolateTransform(parse, pxComma, pxParen, degParen) {\n\n function pop(s) {\n return s.length ? s.pop() + \" \" : \"\";\n }\n\n function translate(xa, ya, xb, yb, s, q) {\n if (xa !== xb || ya !== yb) {\n var i = s.push(\"translate(\", null, pxComma, null, pxParen);\n q.push({i: i - 4, x: number(xa, xb)}, {i: i - 2, x: number(ya, yb)});\n } else if (xb || yb) {\n s.push(\"translate(\" + xb + pxComma + yb + pxParen);\n }\n }\n\n function rotate(a, b, s, q) {\n if (a !== b) {\n if (a - b > 180) b += 360; else if (b - a > 180) a += 360; // shortest path\n q.push({i: s.push(pop(s) + \"rotate(\", null, degParen) - 2, x: number(a, b)});\n } else if (b) {\n s.push(pop(s) + \"rotate(\" + b + degParen);\n }\n }\n\n function skewX(a, b, s, q) {\n if (a !== b) {\n q.push({i: s.push(pop(s) + \"skewX(\", null, degParen) - 2, x: number(a, b)});\n } else if (b) {\n s.push(pop(s) + \"skewX(\" + b + degParen);\n }\n }\n\n function scale(xa, ya, xb, yb, s, q) {\n if (xa !== xb || ya !== yb) {\n var i = s.push(pop(s) + \"scale(\", null, \",\", null, \")\");\n q.push({i: i - 4, x: number(xa, xb)}, {i: i - 2, x: number(ya, yb)});\n } else if (xb !== 1 || yb !== 1) {\n s.push(pop(s) + \"scale(\" + xb + \",\" + yb + \")\");\n }\n }\n\n return function(a, b) {\n var s = [], // string constants and placeholders\n q = []; // number interpolators\n a = parse(a), b = parse(b);\n translate(a.translateX, a.translateY, b.translateX, b.translateY, s, q);\n rotate(a.rotate, b.rotate, s, q);\n skewX(a.skewX, b.skewX, s, q);\n scale(a.scaleX, a.scaleY, b.scaleX, b.scaleY, s, q);\n a = b = null; // gc\n return function(t) {\n var i = -1, n = q.length, o;\n while (++i < n) s[(o = q[i]).i] = o.x(t);\n return s.join(\"\");\n };\n };\n}\n\nexport var interpolateTransformCss = interpolateTransform(parseCss, \"px, \", \"px)\", \"deg)\");\nexport var interpolateTransformSvg = interpolateTransform(parseSvg, \", \", \")\", \")\");\n", "export function initRange(domain, range) {\n switch (arguments.length) {\n case 0: break;\n case 1: this.range(domain); break;\n default: this.range(range).domain(domain); break;\n }\n return this;\n}\n\nexport function initInterpolator(domain, interpolator) {\n switch (arguments.length) {\n case 0: break;\n case 1: {\n if (typeof domain === \"function\") this.interpolator(domain);\n else this.range(domain);\n break;\n }\n default: {\n this.domain(domain);\n if (typeof interpolator === \"function\") this.interpolator(interpolator);\n else this.range(interpolator);\n break;\n }\n }\n return this;\n}\n", "import {InternMap} from \"d3-array\";\nimport {initRange} from \"./init.js\";\n\nexport const implicit = Symbol(\"implicit\");\n\nexport default function ordinal() {\n var index = new InternMap(),\n domain = [],\n range = [],\n unknown = implicit;\n\n function scale(d) {\n let i = index.get(d);\n if (i === undefined) {\n if (unknown !== implicit) return unknown;\n index.set(d, i = domain.push(d) - 1);\n }\n return range[i % range.length];\n }\n\n scale.domain = function(_) {\n if (!arguments.length) return domain.slice();\n domain = [], index = new InternMap();\n for (const value of _) {\n if (index.has(value)) continue;\n index.set(value, domain.push(value) - 1);\n }\n return scale;\n };\n\n scale.range = function(_) {\n return arguments.length ? (range = Array.from(_), scale) : range.slice();\n };\n\n scale.unknown = function(_) {\n return arguments.length ? (unknown = _, scale) : unknown;\n };\n\n scale.copy = function() {\n return ordinal(domain, range).unknown(unknown);\n };\n\n initRange.apply(scale, arguments);\n\n return scale;\n}\n", "import {range as sequence} from \"d3-array\";\nimport {initRange} from \"./init.js\";\nimport ordinal from \"./ordinal.js\";\n\nexport default function band() {\n var scale = ordinal().unknown(undefined),\n domain = scale.domain,\n ordinalRange = scale.range,\n r0 = 0,\n r1 = 1,\n step,\n bandwidth,\n round = false,\n paddingInner = 0,\n paddingOuter = 0,\n align = 0.5;\n\n delete scale.unknown;\n\n function rescale() {\n var n = domain().length,\n reverse = r1 < r0,\n start = reverse ? r1 : r0,\n stop = reverse ? r0 : r1;\n step = (stop - start) / Math.max(1, n - paddingInner + paddingOuter * 2);\n if (round) step = Math.floor(step);\n start += (stop - start - step * (n - paddingInner)) * align;\n bandwidth = step * (1 - paddingInner);\n if (round) start = Math.round(start), bandwidth = Math.round(bandwidth);\n var values = sequence(n).map(function(i) { return start + step * i; });\n return ordinalRange(reverse ? values.reverse() : values);\n }\n\n scale.domain = function(_) {\n return arguments.length ? (domain(_), rescale()) : domain();\n };\n\n scale.range = function(_) {\n return arguments.length ? ([r0, r1] = _, r0 = +r0, r1 = +r1, rescale()) : [r0, r1];\n };\n\n scale.rangeRound = function(_) {\n return [r0, r1] = _, r0 = +r0, r1 = +r1, round = true, rescale();\n };\n\n scale.bandwidth = function() {\n return bandwidth;\n };\n\n scale.step = function() {\n return step;\n };\n\n scale.round = function(_) {\n return arguments.length ? (round = !!_, rescale()) : round;\n };\n\n scale.padding = function(_) {\n return arguments.length ? (paddingInner = Math.min(1, paddingOuter = +_), rescale()) : paddingInner;\n };\n\n scale.paddingInner = function(_) {\n return arguments.length ? (paddingInner = Math.min(1, _), rescale()) : paddingInner;\n };\n\n scale.paddingOuter = function(_) {\n return arguments.length ? (paddingOuter = +_, rescale()) : paddingOuter;\n };\n\n scale.align = function(_) {\n return arguments.length ? (align = Math.max(0, Math.min(1, _)), rescale()) : align;\n };\n\n scale.copy = function() {\n return band(domain(), [r0, r1])\n .round(round)\n .paddingInner(paddingInner)\n .paddingOuter(paddingOuter)\n .align(align);\n };\n\n return initRange.apply(rescale(), arguments);\n}\n\nfunction pointish(scale) {\n var copy = scale.copy;\n\n scale.padding = scale.paddingOuter;\n delete scale.paddingInner;\n delete scale.paddingOuter;\n\n scale.copy = function() {\n return pointish(copy());\n };\n\n return scale;\n}\n\nexport function point() {\n return pointish(band.apply(null, arguments).paddingInner(1));\n}\n", "export default function constants(x) {\n return function() {\n return x;\n };\n}\n", "export default function number(x) {\n return +x;\n}\n", "import {bisect} from \"d3-array\";\nimport {interpolate as interpolateValue, interpolateNumber, interpolateRound} from \"d3-interpolate\";\nimport constant from \"./constant.js\";\nimport number from \"./number.js\";\n\nvar unit = [0, 1];\n\nexport function identity(x) {\n return x;\n}\n\nfunction normalize(a, b) {\n return (b -= (a = +a))\n ? function(x) { return (x - a) / b; }\n : constant(isNaN(b) ? NaN : 0.5);\n}\n\nfunction clamper(a, b) {\n var t;\n if (a > b) t = a, a = b, b = t;\n return function(x) { return Math.max(a, Math.min(b, x)); };\n}\n\n// normalize(a, b)(x) takes a domain value x in [a,b] and returns the corresponding parameter t in [0,1].\n// interpolate(a, b)(t) takes a parameter t in [0,1] and returns the corresponding range value x in [a,b].\nfunction bimap(domain, range, interpolate) {\n var d0 = domain[0], d1 = domain[1], r0 = range[0], r1 = range[1];\n if (d1 < d0) d0 = normalize(d1, d0), r0 = interpolate(r1, r0);\n else d0 = normalize(d0, d1), r0 = interpolate(r0, r1);\n return function(x) { return r0(d0(x)); };\n}\n\nfunction polymap(domain, range, interpolate) {\n var j = Math.min(domain.length, range.length) - 1,\n d = new Array(j),\n r = new Array(j),\n i = -1;\n\n // Reverse descending domains.\n if (domain[j] < domain[0]) {\n domain = domain.slice().reverse();\n range = range.slice().reverse();\n }\n\n while (++i < j) {\n d[i] = normalize(domain[i], domain[i + 1]);\n r[i] = interpolate(range[i], range[i + 1]);\n }\n\n return function(x) {\n var i = bisect(domain, x, 1, j) - 1;\n return r[i](d[i](x));\n };\n}\n\nexport function copy(source, target) {\n return target\n .domain(source.domain())\n .range(source.range())\n .interpolate(source.interpolate())\n .clamp(source.clamp())\n .unknown(source.unknown());\n}\n\nexport function transformer() {\n var domain = unit,\n range = unit,\n interpolate = interpolateValue,\n transform,\n untransform,\n unknown,\n clamp = identity,\n piecewise,\n output,\n input;\n\n function rescale() {\n var n = Math.min(domain.length, range.length);\n if (clamp !== identity) clamp = clamper(domain[0], domain[n - 1]);\n piecewise = n > 2 ? polymap : bimap;\n output = input = null;\n return scale;\n }\n\n function scale(x) {\n return x == null || isNaN(x = +x) ? unknown : (output || (output = piecewise(domain.map(transform), range, interpolate)))(transform(clamp(x)));\n }\n\n scale.invert = function(y) {\n return clamp(untransform((input || (input = piecewise(range, domain.map(transform), interpolateNumber)))(y)));\n };\n\n scale.domain = function(_) {\n return arguments.length ? (domain = Array.from(_, number), rescale()) : domain.slice();\n };\n\n scale.range = function(_) {\n return arguments.length ? (range = Array.from(_), rescale()) : range.slice();\n };\n\n scale.rangeRound = function(_) {\n return range = Array.from(_), interpolate = interpolateRound, rescale();\n };\n\n scale.clamp = function(_) {\n return arguments.length ? (clamp = _ ? true : identity, rescale()) : clamp !== identity;\n };\n\n scale.interpolate = function(_) {\n return arguments.length ? (interpolate = _, rescale()) : interpolate;\n };\n\n scale.unknown = function(_) {\n return arguments.length ? (unknown = _, scale) : unknown;\n };\n\n return function(t, u) {\n transform = t, untransform = u;\n return rescale();\n };\n}\n\nexport default function continuous() {\n return transformer()(identity, identity);\n}\n", "export default function(x) {\n return Math.abs(x = Math.round(x)) >= 1e21\n ? x.toLocaleString(\"en\").replace(/,/g, \"\")\n : x.toString(10);\n}\n\n// Computes the decimal coefficient and exponent of the specified number x with\n// significant digits p, where x is positive and p is in [1, 21] or undefined.\n// For example, formatDecimalParts(1.23) returns [\"123\", 0].\nexport function formatDecimalParts(x, p) {\n if ((i = (x = p ? x.toExponential(p - 1) : x.toExponential()).indexOf(\"e\")) < 0) return null; // NaN, \u00B1Infinity\n var i, coefficient = x.slice(0, i);\n\n // The string returned by toExponential either has the form \\d\\.\\d+e[-+]\\d+\n // (e.g., 1.2e+3) or the form \\de[-+]\\d+ (e.g., 1e+3).\n return [\n coefficient.length > 1 ? coefficient[0] + coefficient.slice(2) : coefficient,\n +x.slice(i + 1)\n ];\n}\n", "import {formatDecimalParts} from \"./formatDecimal.js\";\n\nexport default function(x) {\n return x = formatDecimalParts(Math.abs(x)), x ? x[1] : NaN;\n}\n", "export default function(grouping, thousands) {\n return function(value, width) {\n var i = value.length,\n t = [],\n j = 0,\n g = grouping[0],\n length = 0;\n\n while (i > 0 && g > 0) {\n if (length + g + 1 > width) g = Math.max(1, width - length);\n t.push(value.substring(i -= g, i + g));\n if ((length += g + 1) > width) break;\n g = grouping[j = (j + 1) % grouping.length];\n }\n\n return t.reverse().join(thousands);\n };\n}\n", "export default function(numerals) {\n return function(value) {\n return value.replace(/[0-9]/g, function(i) {\n return numerals[+i];\n });\n };\n}\n", "// [[fill]align][sign][symbol][0][width][,][.precision][~][type]\nvar re = /^(?:(.)?([<>=^]))?([+\\-( ])?([$#])?(0)?(\\d+)?(,)?(\\.\\d+)?(~)?([a-z%])?$/i;\n\nexport default function formatSpecifier(specifier) {\n if (!(match = re.exec(specifier))) throw new Error(\"invalid format: \" + specifier);\n var match;\n return new FormatSpecifier({\n fill: match[1],\n align: match[2],\n sign: match[3],\n symbol: match[4],\n zero: match[5],\n width: match[6],\n comma: match[7],\n precision: match[8] && match[8].slice(1),\n trim: match[9],\n type: match[10]\n });\n}\n\nformatSpecifier.prototype = FormatSpecifier.prototype; // instanceof\n\nexport function FormatSpecifier(specifier) {\n this.fill = specifier.fill === undefined ? \" \" : specifier.fill + \"\";\n this.align = specifier.align === undefined ? \">\" : specifier.align + \"\";\n this.sign = specifier.sign === undefined ? \"-\" : specifier.sign + \"\";\n this.symbol = specifier.symbol === undefined ? \"\" : specifier.symbol + \"\";\n this.zero = !!specifier.zero;\n this.width = specifier.width === undefined ? undefined : +specifier.width;\n this.comma = !!specifier.comma;\n this.precision = specifier.precision === undefined ? undefined : +specifier.precision;\n this.trim = !!specifier.trim;\n this.type = specifier.type === undefined ? \"\" : specifier.type + \"\";\n}\n\nFormatSpecifier.prototype.toString = function() {\n return this.fill\n + this.align\n + this.sign\n + this.symbol\n + (this.zero ? \"0\" : \"\")\n + (this.width === undefined ? \"\" : Math.max(1, this.width | 0))\n + (this.comma ? \",\" : \"\")\n + (this.precision === undefined ? \"\" : \".\" + Math.max(0, this.precision | 0))\n + (this.trim ? \"~\" : \"\")\n + this.type;\n};\n", "// Trims insignificant zeros, e.g., replaces 1.2000k with 1.2k.\nexport default function(s) {\n out: for (var n = s.length, i = 1, i0 = -1, i1; i < n; ++i) {\n switch (s[i]) {\n case \".\": i0 = i1 = i; break;\n case \"0\": if (i0 === 0) i0 = i; i1 = i; break;\n default: if (!+s[i]) break out; if (i0 > 0) i0 = 0; break;\n }\n }\n return i0 > 0 ? s.slice(0, i0) + s.slice(i1 + 1) : s;\n}\n", "import {formatDecimalParts} from \"./formatDecimal.js\";\n\nexport var prefixExponent;\n\nexport default function(x, p) {\n var d = formatDecimalParts(x, p);\n if (!d) return x + \"\";\n var coefficient = d[0],\n exponent = d[1],\n i = exponent - (prefixExponent = Math.max(-8, Math.min(8, Math.floor(exponent / 3))) * 3) + 1,\n n = coefficient.length;\n return i === n ? coefficient\n : i > n ? coefficient + new Array(i - n + 1).join(\"0\")\n : i > 0 ? coefficient.slice(0, i) + \".\" + coefficient.slice(i)\n : \"0.\" + new Array(1 - i).join(\"0\") + formatDecimalParts(x, Math.max(0, p + i - 1))[0]; // less than 1y!\n}\n", "import {formatDecimalParts} from \"./formatDecimal.js\";\n\nexport default function(x, p) {\n var d = formatDecimalParts(x, p);\n if (!d) return x + \"\";\n var coefficient = d[0],\n exponent = d[1];\n return exponent < 0 ? \"0.\" + new Array(-exponent).join(\"0\") + coefficient\n : coefficient.length > exponent + 1 ? coefficient.slice(0, exponent + 1) + \".\" + coefficient.slice(exponent + 1)\n : coefficient + new Array(exponent - coefficient.length + 2).join(\"0\");\n}\n", "import formatDecimal from \"./formatDecimal.js\";\nimport formatPrefixAuto from \"./formatPrefixAuto.js\";\nimport formatRounded from \"./formatRounded.js\";\n\nexport default {\n \"%\": (x, p) => (x * 100).toFixed(p),\n \"b\": (x) => Math.round(x).toString(2),\n \"c\": (x) => x + \"\",\n \"d\": formatDecimal,\n \"e\": (x, p) => x.toExponential(p),\n \"f\": (x, p) => x.toFixed(p),\n \"g\": (x, p) => x.toPrecision(p),\n \"o\": (x) => Math.round(x).toString(8),\n \"p\": (x, p) => formatRounded(x * 100, p),\n \"r\": formatRounded,\n \"s\": formatPrefixAuto,\n \"X\": (x) => Math.round(x).toString(16).toUpperCase(),\n \"x\": (x) => Math.round(x).toString(16)\n};\n", "export default function(x) {\n return x;\n}\n", "import exponent from \"./exponent.js\";\nimport formatGroup from \"./formatGroup.js\";\nimport formatNumerals from \"./formatNumerals.js\";\nimport formatSpecifier from \"./formatSpecifier.js\";\nimport formatTrim from \"./formatTrim.js\";\nimport formatTypes from \"./formatTypes.js\";\nimport {prefixExponent} from \"./formatPrefixAuto.js\";\nimport identity from \"./identity.js\";\n\nvar map = Array.prototype.map,\n prefixes = [\"y\",\"z\",\"a\",\"f\",\"p\",\"n\",\"\u00B5\",\"m\",\"\",\"k\",\"M\",\"G\",\"T\",\"P\",\"E\",\"Z\",\"Y\"];\n\nexport default function(locale) {\n var group = locale.grouping === undefined || locale.thousands === undefined ? identity : formatGroup(map.call(locale.grouping, Number), locale.thousands + \"\"),\n currencyPrefix = locale.currency === undefined ? \"\" : locale.currency[0] + \"\",\n currencySuffix = locale.currency === undefined ? \"\" : locale.currency[1] + \"\",\n decimal = locale.decimal === undefined ? \".\" : locale.decimal + \"\",\n numerals = locale.numerals === undefined ? identity : formatNumerals(map.call(locale.numerals, String)),\n percent = locale.percent === undefined ? \"%\" : locale.percent + \"\",\n minus = locale.minus === undefined ? \"\u2212\" : locale.minus + \"\",\n nan = locale.nan === undefined ? \"NaN\" : locale.nan + \"\";\n\n function newFormat(specifier) {\n specifier = formatSpecifier(specifier);\n\n var fill = specifier.fill,\n align = specifier.align,\n sign = specifier.sign,\n symbol = specifier.symbol,\n zero = specifier.zero,\n width = specifier.width,\n comma = specifier.comma,\n precision = specifier.precision,\n trim = specifier.trim,\n type = specifier.type;\n\n // The \"n\" type is an alias for \",g\".\n if (type === \"n\") comma = true, type = \"g\";\n\n // The \"\" type, and any invalid type, is an alias for \".12~g\".\n else if (!formatTypes[type]) precision === undefined && (precision = 12), trim = true, type = \"g\";\n\n // If zero fill is specified, padding goes after sign and before digits.\n if (zero || (fill === \"0\" && align === \"=\")) zero = true, fill = \"0\", align = \"=\";\n\n // Compute the prefix and suffix.\n // For SI-prefix, the suffix is lazily computed.\n var prefix = symbol === \"$\" ? currencyPrefix : symbol === \"#\" && /[boxX]/.test(type) ? \"0\" + type.toLowerCase() : \"\",\n suffix = symbol === \"$\" ? currencySuffix : /[%p]/.test(type) ? percent : \"\";\n\n // What format function should we use?\n // Is this an integer type?\n // Can this type generate exponential notation?\n var formatType = formatTypes[type],\n maybeSuffix = /[defgprs%]/.test(type);\n\n // Set the default precision if not specified,\n // or clamp the specified precision to the supported range.\n // For significant precision, it must be in [1, 21].\n // For fixed precision, it must be in [0, 20].\n precision = precision === undefined ? 6\n : /[gprs]/.test(type) ? Math.max(1, Math.min(21, precision))\n : Math.max(0, Math.min(20, precision));\n\n function format(value) {\n var valuePrefix = prefix,\n valueSuffix = suffix,\n i, n, c;\n\n if (type === \"c\") {\n valueSuffix = formatType(value) + valueSuffix;\n value = \"\";\n } else {\n value = +value;\n\n // Determine the sign. -0 is not less than 0, but 1 / -0 is!\n var valueNegative = value < 0 || 1 / value < 0;\n\n // Perform the initial formatting.\n value = isNaN(value) ? nan : formatType(Math.abs(value), precision);\n\n // Trim insignificant zeros.\n if (trim) value = formatTrim(value);\n\n // If a negative value rounds to zero after formatting, and no explicit positive sign is requested, hide the sign.\n if (valueNegative && +value === 0 && sign !== \"+\") valueNegative = false;\n\n // Compute the prefix and suffix.\n valuePrefix = (valueNegative ? (sign === \"(\" ? sign : minus) : sign === \"-\" || sign === \"(\" ? \"\" : sign) + valuePrefix;\n valueSuffix = (type === \"s\" ? prefixes[8 + prefixExponent / 3] : \"\") + valueSuffix + (valueNegative && sign === \"(\" ? \")\" : \"\");\n\n // Break the formatted value into the integer \u201Cvalue\u201D part that can be\n // grouped, and fractional or exponential \u201Csuffix\u201D part that is not.\n if (maybeSuffix) {\n i = -1, n = value.length;\n while (++i < n) {\n if (c = value.charCodeAt(i), 48 > c || c > 57) {\n valueSuffix = (c === 46 ? decimal + value.slice(i + 1) : value.slice(i)) + valueSuffix;\n value = value.slice(0, i);\n break;\n }\n }\n }\n }\n\n // If the fill character is not \"0\", grouping is applied before padding.\n if (comma && !zero) value = group(value, Infinity);\n\n // Compute the padding.\n var length = valuePrefix.length + value.length + valueSuffix.length,\n padding = length < width ? new Array(width - length + 1).join(fill) : \"\";\n\n // If the fill character is \"0\", grouping is applied after padding.\n if (comma && zero) value = group(padding + value, padding.length ? width - valueSuffix.length : Infinity), padding = \"\";\n\n // Reconstruct the final output based on the desired alignment.\n switch (align) {\n case \"<\": value = valuePrefix + value + valueSuffix + padding; break;\n case \"=\": value = valuePrefix + padding + value + valueSuffix; break;\n case \"^\": value = padding.slice(0, length = padding.length >> 1) + valuePrefix + value + valueSuffix + padding.slice(length); break;\n default: value = padding + valuePrefix + value + valueSuffix; break;\n }\n\n return numerals(value);\n }\n\n format.toString = function() {\n return specifier + \"\";\n };\n\n return format;\n }\n\n function formatPrefix(specifier, value) {\n var f = newFormat((specifier = formatSpecifier(specifier), specifier.type = \"f\", specifier)),\n e = Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3,\n k = Math.pow(10, -e),\n prefix = prefixes[8 + e / 3];\n return function(value) {\n return f(k * value) + prefix;\n };\n }\n\n return {\n format: newFormat,\n formatPrefix: formatPrefix\n };\n}\n", "import formatLocale from \"./locale.js\";\n\nvar locale;\nexport var format;\nexport var formatPrefix;\n\ndefaultLocale({\n thousands: \",\",\n grouping: [3],\n currency: [\"$\", \"\"]\n});\n\nexport default function defaultLocale(definition) {\n locale = formatLocale(definition);\n format = locale.format;\n formatPrefix = locale.formatPrefix;\n return locale;\n}\n", "import exponent from \"./exponent.js\";\n\nexport default function(step) {\n return Math.max(0, -exponent(Math.abs(step)));\n}\n", "import exponent from \"./exponent.js\";\n\nexport default function(step, value) {\n return Math.max(0, Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3 - exponent(Math.abs(step)));\n}\n", "import exponent from \"./exponent.js\";\n\nexport default function(step, max) {\n step = Math.abs(step), max = Math.abs(max) - step;\n return Math.max(0, exponent(max) - exponent(step)) + 1;\n}\n", "import {tickStep} from \"d3-array\";\nimport {format, formatPrefix, formatSpecifier, precisionFixed, precisionPrefix, precisionRound} from \"d3-format\";\n\nexport default function tickFormat(start, stop, count, specifier) {\n var step = tickStep(start, stop, count),\n precision;\n specifier = formatSpecifier(specifier == null ? \",f\" : specifier);\n switch (specifier.type) {\n case \"s\": {\n var value = Math.max(Math.abs(start), Math.abs(stop));\n if (specifier.precision == null && !isNaN(precision = precisionPrefix(step, value))) specifier.precision = precision;\n return formatPrefix(specifier, value);\n }\n case \"\":\n case \"e\":\n case \"g\":\n case \"p\":\n case \"r\": {\n if (specifier.precision == null && !isNaN(precision = precisionRound(step, Math.max(Math.abs(start), Math.abs(stop))))) specifier.precision = precision - (specifier.type === \"e\");\n break;\n }\n case \"f\":\n case \"%\": {\n if (specifier.precision == null && !isNaN(precision = precisionFixed(step))) specifier.precision = precision - (specifier.type === \"%\") * 2;\n break;\n }\n }\n return format(specifier);\n}\n", "import {ticks, tickIncrement} from \"d3-array\";\nimport continuous, {copy} from \"./continuous.js\";\nimport {initRange} from \"./init.js\";\nimport tickFormat from \"./tickFormat.js\";\n\nexport function linearish(scale) {\n var domain = scale.domain;\n\n scale.ticks = function(count) {\n var d = domain();\n return ticks(d[0], d[d.length - 1], count == null ? 10 : count);\n };\n\n scale.tickFormat = function(count, specifier) {\n var d = domain();\n return tickFormat(d[0], d[d.length - 1], count == null ? 10 : count, specifier);\n };\n\n scale.nice = function(count) {\n if (count == null) count = 10;\n\n var d = domain();\n var i0 = 0;\n var i1 = d.length - 1;\n var start = d[i0];\n var stop = d[i1];\n var prestep;\n var step;\n var maxIter = 10;\n\n if (stop < start) {\n step = start, start = stop, stop = step;\n step = i0, i0 = i1, i1 = step;\n }\n \n while (maxIter-- > 0) {\n step = tickIncrement(start, stop, count);\n if (step === prestep) {\n d[i0] = start\n d[i1] = stop\n return domain(d);\n } else if (step > 0) {\n start = Math.floor(start / step) * step;\n stop = Math.ceil(stop / step) * step;\n } else if (step < 0) {\n start = Math.ceil(start * step) / step;\n stop = Math.floor(stop * step) / step;\n } else {\n break;\n }\n prestep = step;\n }\n\n return scale;\n };\n\n return scale;\n}\n\nexport default function linear() {\n var scale = continuous();\n\n scale.copy = function() {\n return copy(scale, linear());\n };\n\n initRange.apply(scale, arguments);\n\n return linearish(scale);\n}\n", "const t0 = new Date, t1 = new Date;\n\nexport function timeInterval(floori, offseti, count, field) {\n\n function interval(date) {\n return floori(date = arguments.length === 0 ? new Date : new Date(+date)), date;\n }\n\n interval.floor = (date) => {\n return floori(date = new Date(+date)), date;\n };\n\n interval.ceil = (date) => {\n return floori(date = new Date(date - 1)), offseti(date, 1), floori(date), date;\n };\n\n interval.round = (date) => {\n const d0 = interval(date), d1 = interval.ceil(date);\n return date - d0 < d1 - date ? d0 : d1;\n };\n\n interval.offset = (date, step) => {\n return offseti(date = new Date(+date), step == null ? 1 : Math.floor(step)), date;\n };\n\n interval.range = (start, stop, step) => {\n const range = [];\n start = interval.ceil(start);\n step = step == null ? 1 : Math.floor(step);\n if (!(start < stop) || !(step > 0)) return range; // also handles Invalid Date\n let previous;\n do range.push(previous = new Date(+start)), offseti(start, step), floori(start);\n while (previous < start && start < stop);\n return range;\n };\n\n interval.filter = (test) => {\n return timeInterval((date) => {\n if (date >= date) while (floori(date), !test(date)) date.setTime(date - 1);\n }, (date, step) => {\n if (date >= date) {\n if (step < 0) while (++step <= 0) {\n while (offseti(date, -1), !test(date)) {} // eslint-disable-line no-empty\n } else while (--step >= 0) {\n while (offseti(date, +1), !test(date)) {} // eslint-disable-line no-empty\n }\n }\n });\n };\n\n if (count) {\n interval.count = (start, end) => {\n t0.setTime(+start), t1.setTime(+end);\n floori(t0), floori(t1);\n return Math.floor(count(t0, t1));\n };\n\n interval.every = (step) => {\n step = Math.floor(step);\n return !isFinite(step) || !(step > 0) ? null\n : !(step > 1) ? interval\n : interval.filter(field\n ? (d) => field(d) % step === 0\n : (d) => interval.count(0, d) % step === 0);\n };\n }\n\n return interval;\n}\n", "import {timeInterval} from \"./interval.js\";\n\nexport const millisecond = timeInterval(() => {\n // noop\n}, (date, step) => {\n date.setTime(+date + step);\n}, (start, end) => {\n return end - start;\n});\n\n// An optimized implementation for this simple case.\nmillisecond.every = (k) => {\n k = Math.floor(k);\n if (!isFinite(k) || !(k > 0)) return null;\n if (!(k > 1)) return millisecond;\n return timeInterval((date) => {\n date.setTime(Math.floor(date / k) * k);\n }, (date, step) => {\n date.setTime(+date + step * k);\n }, (start, end) => {\n return (end - start) / k;\n });\n};\n\nexport const milliseconds = millisecond.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationSecond} from \"./duration.js\";\n\nexport const second = timeInterval((date) => {\n date.setTime(date - date.getMilliseconds());\n}, (date, step) => {\n date.setTime(+date + step * durationSecond);\n}, (start, end) => {\n return (end - start) / durationSecond;\n}, (date) => {\n return date.getUTCSeconds();\n});\n\nexport const seconds = second.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationMinute, durationSecond} from \"./duration.js\";\n\nexport const timeMinute = timeInterval((date) => {\n date.setTime(date - date.getMilliseconds() - date.getSeconds() * durationSecond);\n}, (date, step) => {\n date.setTime(+date + step * durationMinute);\n}, (start, end) => {\n return (end - start) / durationMinute;\n}, (date) => {\n return date.getMinutes();\n});\n\nexport const timeMinutes = timeMinute.range;\n\nexport const utcMinute = timeInterval((date) => {\n date.setUTCSeconds(0, 0);\n}, (date, step) => {\n date.setTime(+date + step * durationMinute);\n}, (start, end) => {\n return (end - start) / durationMinute;\n}, (date) => {\n return date.getUTCMinutes();\n});\n\nexport const utcMinutes = utcMinute.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationHour, durationMinute, durationSecond} from \"./duration.js\";\n\nexport const timeHour = timeInterval((date) => {\n date.setTime(date - date.getMilliseconds() - date.getSeconds() * durationSecond - date.getMinutes() * durationMinute);\n}, (date, step) => {\n date.setTime(+date + step * durationHour);\n}, (start, end) => {\n return (end - start) / durationHour;\n}, (date) => {\n return date.getHours();\n});\n\nexport const timeHours = timeHour.range;\n\nexport const utcHour = timeInterval((date) => {\n date.setUTCMinutes(0, 0, 0);\n}, (date, step) => {\n date.setTime(+date + step * durationHour);\n}, (start, end) => {\n return (end - start) / durationHour;\n}, (date) => {\n return date.getUTCHours();\n});\n\nexport const utcHours = utcHour.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationDay, durationMinute} from \"./duration.js\";\n\nexport const timeDay = timeInterval(\n date => date.setHours(0, 0, 0, 0),\n (date, step) => date.setDate(date.getDate() + step),\n (start, end) => (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * durationMinute) / durationDay,\n date => date.getDate() - 1\n);\n\nexport const timeDays = timeDay.range;\n\nexport const utcDay = timeInterval((date) => {\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCDate(date.getUTCDate() + step);\n}, (start, end) => {\n return (end - start) / durationDay;\n}, (date) => {\n return date.getUTCDate() - 1;\n});\n\nexport const utcDays = utcDay.range;\n\nexport const unixDay = timeInterval((date) => {\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCDate(date.getUTCDate() + step);\n}, (start, end) => {\n return (end - start) / durationDay;\n}, (date) => {\n return Math.floor(date / durationDay);\n});\n\nexport const unixDays = unixDay.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationMinute, durationWeek} from \"./duration.js\";\n\nfunction timeWeekday(i) {\n return timeInterval((date) => {\n date.setDate(date.getDate() - (date.getDay() + 7 - i) % 7);\n date.setHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setDate(date.getDate() + step * 7);\n }, (start, end) => {\n return (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * durationMinute) / durationWeek;\n });\n}\n\nexport const timeSunday = timeWeekday(0);\nexport const timeMonday = timeWeekday(1);\nexport const timeTuesday = timeWeekday(2);\nexport const timeWednesday = timeWeekday(3);\nexport const timeThursday = timeWeekday(4);\nexport const timeFriday = timeWeekday(5);\nexport const timeSaturday = timeWeekday(6);\n\nexport const timeSundays = timeSunday.range;\nexport const timeMondays = timeMonday.range;\nexport const timeTuesdays = timeTuesday.range;\nexport const timeWednesdays = timeWednesday.range;\nexport const timeThursdays = timeThursday.range;\nexport const timeFridays = timeFriday.range;\nexport const timeSaturdays = timeSaturday.range;\n\nfunction utcWeekday(i) {\n return timeInterval((date) => {\n date.setUTCDate(date.getUTCDate() - (date.getUTCDay() + 7 - i) % 7);\n date.setUTCHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setUTCDate(date.getUTCDate() + step * 7);\n }, (start, end) => {\n return (end - start) / durationWeek;\n });\n}\n\nexport const utcSunday = utcWeekday(0);\nexport const utcMonday = utcWeekday(1);\nexport const utcTuesday = utcWeekday(2);\nexport const utcWednesday = utcWeekday(3);\nexport const utcThursday = utcWeekday(4);\nexport const utcFriday = utcWeekday(5);\nexport const utcSaturday = utcWeekday(6);\n\nexport const utcSundays = utcSunday.range;\nexport const utcMondays = utcMonday.range;\nexport const utcTuesdays = utcTuesday.range;\nexport const utcWednesdays = utcWednesday.range;\nexport const utcThursdays = utcThursday.range;\nexport const utcFridays = utcFriday.range;\nexport const utcSaturdays = utcSaturday.range;\n", "import {timeInterval} from \"./interval.js\";\n\nexport const timeMonth = timeInterval((date) => {\n date.setDate(1);\n date.setHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setMonth(date.getMonth() + step);\n}, (start, end) => {\n return end.getMonth() - start.getMonth() + (end.getFullYear() - start.getFullYear()) * 12;\n}, (date) => {\n return date.getMonth();\n});\n\nexport const timeMonths = timeMonth.range;\n\nexport const utcMonth = timeInterval((date) => {\n date.setUTCDate(1);\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCMonth(date.getUTCMonth() + step);\n}, (start, end) => {\n return end.getUTCMonth() - start.getUTCMonth() + (end.getUTCFullYear() - start.getUTCFullYear()) * 12;\n}, (date) => {\n return date.getUTCMonth();\n});\n\nexport const utcMonths = utcMonth.range;\n", "import {timeInterval} from \"./interval.js\";\n\nexport const timeYear = timeInterval((date) => {\n date.setMonth(0, 1);\n date.setHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setFullYear(date.getFullYear() + step);\n}, (start, end) => {\n return end.getFullYear() - start.getFullYear();\n}, (date) => {\n return date.getFullYear();\n});\n\n// An optimized implementation for this simple case.\ntimeYear.every = (k) => {\n return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : timeInterval((date) => {\n date.setFullYear(Math.floor(date.getFullYear() / k) * k);\n date.setMonth(0, 1);\n date.setHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setFullYear(date.getFullYear() + step * k);\n });\n};\n\nexport const timeYears = timeYear.range;\n\nexport const utcYear = timeInterval((date) => {\n date.setUTCMonth(0, 1);\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCFullYear(date.getUTCFullYear() + step);\n}, (start, end) => {\n return end.getUTCFullYear() - start.getUTCFullYear();\n}, (date) => {\n return date.getUTCFullYear();\n});\n\n// An optimized implementation for this simple case.\nutcYear.every = (k) => {\n return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : timeInterval((date) => {\n date.setUTCFullYear(Math.floor(date.getUTCFullYear() / k) * k);\n date.setUTCMonth(0, 1);\n date.setUTCHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setUTCFullYear(date.getUTCFullYear() + step * k);\n });\n};\n\nexport const utcYears = utcYear.range;\n", "import {bisector, tickStep} from \"d3-array\";\nimport {durationDay, durationHour, durationMinute, durationMonth, durationSecond, durationWeek, durationYear} from \"./duration.js\";\nimport {millisecond} from \"./millisecond.js\";\nimport {second} from \"./second.js\";\nimport {timeMinute, utcMinute} from \"./minute.js\";\nimport {timeHour, utcHour} from \"./hour.js\";\nimport {timeDay, unixDay} from \"./day.js\";\nimport {timeSunday, utcSunday} from \"./week.js\";\nimport {timeMonth, utcMonth} from \"./month.js\";\nimport {timeYear, utcYear} from \"./year.js\";\n\nfunction ticker(year, month, week, day, hour, minute) {\n\n const tickIntervals = [\n [second, 1, durationSecond],\n [second, 5, 5 * durationSecond],\n [second, 15, 15 * durationSecond],\n [second, 30, 30 * durationSecond],\n [minute, 1, durationMinute],\n [minute, 5, 5 * durationMinute],\n [minute, 15, 15 * durationMinute],\n [minute, 30, 30 * durationMinute],\n [ hour, 1, durationHour ],\n [ hour, 3, 3 * durationHour ],\n [ hour, 6, 6 * durationHour ],\n [ hour, 12, 12 * durationHour ],\n [ day, 1, durationDay ],\n [ day, 2, 2 * durationDay ],\n [ week, 1, durationWeek ],\n [ month, 1, durationMonth ],\n [ month, 3, 3 * durationMonth ],\n [ year, 1, durationYear ]\n ];\n\n function ticks(start, stop, count) {\n const reverse = stop < start;\n if (reverse) [start, stop] = [stop, start];\n const interval = count && typeof count.range === \"function\" ? count : tickInterval(start, stop, count);\n const ticks = interval ? interval.range(start, +stop + 1) : []; // inclusive stop\n return reverse ? ticks.reverse() : ticks;\n }\n\n function tickInterval(start, stop, count) {\n const target = Math.abs(stop - start) / count;\n const i = bisector(([,, step]) => step).right(tickIntervals, target);\n if (i === tickIntervals.length) return year.every(tickStep(start / durationYear, stop / durationYear, count));\n if (i === 0) return millisecond.every(Math.max(tickStep(start, stop, count), 1));\n const [t, step] = tickIntervals[target / tickIntervals[i - 1][2] < tickIntervals[i][2] / target ? i - 1 : i];\n return t.every(step);\n }\n\n return [ticks, tickInterval];\n}\n\nconst [utcTicks, utcTickInterval] = ticker(utcYear, utcMonth, utcSunday, unixDay, utcHour, utcMinute);\nconst [timeTicks, timeTickInterval] = ticker(timeYear, timeMonth, timeSunday, timeDay, timeHour, timeMinute);\n\nexport {utcTicks, utcTickInterval, timeTicks, timeTickInterval};\n", "import {\n timeDay,\n timeSunday,\n timeMonday,\n timeThursday,\n timeYear,\n utcDay,\n utcSunday,\n utcMonday,\n utcThursday,\n utcYear\n} from \"d3-time\";\n\nfunction localDate(d) {\n if (0 <= d.y && d.y < 100) {\n var date = new Date(-1, d.m, d.d, d.H, d.M, d.S, d.L);\n date.setFullYear(d.y);\n return date;\n }\n return new Date(d.y, d.m, d.d, d.H, d.M, d.S, d.L);\n}\n\nfunction utcDate(d) {\n if (0 <= d.y && d.y < 100) {\n var date = new Date(Date.UTC(-1, d.m, d.d, d.H, d.M, d.S, d.L));\n date.setUTCFullYear(d.y);\n return date;\n }\n return new Date(Date.UTC(d.y, d.m, d.d, d.H, d.M, d.S, d.L));\n}\n\nfunction newDate(y, m, d) {\n return {y: y, m: m, d: d, H: 0, M: 0, S: 0, L: 0};\n}\n\nexport default function formatLocale(locale) {\n var locale_dateTime = locale.dateTime,\n locale_date = locale.date,\n locale_time = locale.time,\n locale_periods = locale.periods,\n locale_weekdays = locale.days,\n locale_shortWeekdays = locale.shortDays,\n locale_months = locale.months,\n locale_shortMonths = locale.shortMonths;\n\n var periodRe = formatRe(locale_periods),\n periodLookup = formatLookup(locale_periods),\n weekdayRe = formatRe(locale_weekdays),\n weekdayLookup = formatLookup(locale_weekdays),\n shortWeekdayRe = formatRe(locale_shortWeekdays),\n shortWeekdayLookup = formatLookup(locale_shortWeekdays),\n monthRe = formatRe(locale_months),\n monthLookup = formatLookup(locale_months),\n shortMonthRe = formatRe(locale_shortMonths),\n shortMonthLookup = formatLookup(locale_shortMonths);\n\n var formats = {\n \"a\": formatShortWeekday,\n \"A\": formatWeekday,\n \"b\": formatShortMonth,\n \"B\": formatMonth,\n \"c\": null,\n \"d\": formatDayOfMonth,\n \"e\": formatDayOfMonth,\n \"f\": formatMicroseconds,\n \"g\": formatYearISO,\n \"G\": formatFullYearISO,\n \"H\": formatHour24,\n \"I\": formatHour12,\n \"j\": formatDayOfYear,\n \"L\": formatMilliseconds,\n \"m\": formatMonthNumber,\n \"M\": formatMinutes,\n \"p\": formatPeriod,\n \"q\": formatQuarter,\n \"Q\": formatUnixTimestamp,\n \"s\": formatUnixTimestampSeconds,\n \"S\": formatSeconds,\n \"u\": formatWeekdayNumberMonday,\n \"U\": formatWeekNumberSunday,\n \"V\": formatWeekNumberISO,\n \"w\": formatWeekdayNumberSunday,\n \"W\": formatWeekNumberMonday,\n \"x\": null,\n \"X\": null,\n \"y\": formatYear,\n \"Y\": formatFullYear,\n \"Z\": formatZone,\n \"%\": formatLiteralPercent\n };\n\n var utcFormats = {\n \"a\": formatUTCShortWeekday,\n \"A\": formatUTCWeekday,\n \"b\": formatUTCShortMonth,\n \"B\": formatUTCMonth,\n \"c\": null,\n \"d\": formatUTCDayOfMonth,\n \"e\": formatUTCDayOfMonth,\n \"f\": formatUTCMicroseconds,\n \"g\": formatUTCYearISO,\n \"G\": formatUTCFullYearISO,\n \"H\": formatUTCHour24,\n \"I\": formatUTCHour12,\n \"j\": formatUTCDayOfYear,\n \"L\": formatUTCMilliseconds,\n \"m\": formatUTCMonthNumber,\n \"M\": formatUTCMinutes,\n \"p\": formatUTCPeriod,\n \"q\": formatUTCQuarter,\n \"Q\": formatUnixTimestamp,\n \"s\": formatUnixTimestampSeconds,\n \"S\": formatUTCSeconds,\n \"u\": formatUTCWeekdayNumberMonday,\n \"U\": formatUTCWeekNumberSunday,\n \"V\": formatUTCWeekNumberISO,\n \"w\": formatUTCWeekdayNumberSunday,\n \"W\": formatUTCWeekNumberMonday,\n \"x\": null,\n \"X\": null,\n \"y\": formatUTCYear,\n \"Y\": formatUTCFullYear,\n \"Z\": formatUTCZone,\n \"%\": formatLiteralPercent\n };\n\n var parses = {\n \"a\": parseShortWeekday,\n \"A\": parseWeekday,\n \"b\": parseShortMonth,\n \"B\": parseMonth,\n \"c\": parseLocaleDateTime,\n \"d\": parseDayOfMonth,\n \"e\": parseDayOfMonth,\n \"f\": parseMicroseconds,\n \"g\": parseYear,\n \"G\": parseFullYear,\n \"H\": parseHour24,\n \"I\": parseHour24,\n \"j\": parseDayOfYear,\n \"L\": parseMilliseconds,\n \"m\": parseMonthNumber,\n \"M\": parseMinutes,\n \"p\": parsePeriod,\n \"q\": parseQuarter,\n \"Q\": parseUnixTimestamp,\n \"s\": parseUnixTimestampSeconds,\n \"S\": parseSeconds,\n \"u\": parseWeekdayNumberMonday,\n \"U\": parseWeekNumberSunday,\n \"V\": parseWeekNumberISO,\n \"w\": parseWeekdayNumberSunday,\n \"W\": parseWeekNumberMonday,\n \"x\": parseLocaleDate,\n \"X\": parseLocaleTime,\n \"y\": parseYear,\n \"Y\": parseFullYear,\n \"Z\": parseZone,\n \"%\": parseLiteralPercent\n };\n\n // These recursive directive definitions must be deferred.\n formats.x = newFormat(locale_date, formats);\n formats.X = newFormat(locale_time, formats);\n formats.c = newFormat(locale_dateTime, formats);\n utcFormats.x = newFormat(locale_date, utcFormats);\n utcFormats.X = newFormat(locale_time, utcFormats);\n utcFormats.c = newFormat(locale_dateTime, utcFormats);\n\n function newFormat(specifier, formats) {\n return function(date) {\n var string = [],\n i = -1,\n j = 0,\n n = specifier.length,\n c,\n pad,\n format;\n\n if (!(date instanceof Date)) date = new Date(+date);\n\n while (++i < n) {\n if (specifier.charCodeAt(i) === 37) {\n string.push(specifier.slice(j, i));\n if ((pad = pads[c = specifier.charAt(++i)]) != null) c = specifier.charAt(++i);\n else pad = c === \"e\" ? \" \" : \"0\";\n if (format = formats[c]) c = format(date, pad);\n string.push(c);\n j = i + 1;\n }\n }\n\n string.push(specifier.slice(j, i));\n return string.join(\"\");\n };\n }\n\n function newParse(specifier, Z) {\n return function(string) {\n var d = newDate(1900, undefined, 1),\n i = parseSpecifier(d, specifier, string += \"\", 0),\n week, day;\n if (i != string.length) return null;\n\n // If a UNIX timestamp is specified, return it.\n if (\"Q\" in d) return new Date(d.Q);\n if (\"s\" in d) return new Date(d.s * 1000 + (\"L\" in d ? d.L : 0));\n\n // If this is utcParse, never use the local timezone.\n if (Z && !(\"Z\" in d)) d.Z = 0;\n\n // The am-pm flag is 0 for AM, and 1 for PM.\n if (\"p\" in d) d.H = d.H % 12 + d.p * 12;\n\n // If the month was not specified, inherit from the quarter.\n if (d.m === undefined) d.m = \"q\" in d ? d.q : 0;\n\n // Convert day-of-week and week-of-year to day-of-year.\n if (\"V\" in d) {\n if (d.V < 1 || d.V > 53) return null;\n if (!(\"w\" in d)) d.w = 1;\n if (\"Z\" in d) {\n week = utcDate(newDate(d.y, 0, 1)), day = week.getUTCDay();\n week = day > 4 || day === 0 ? utcMonday.ceil(week) : utcMonday(week);\n week = utcDay.offset(week, (d.V - 1) * 7);\n d.y = week.getUTCFullYear();\n d.m = week.getUTCMonth();\n d.d = week.getUTCDate() + (d.w + 6) % 7;\n } else {\n week = localDate(newDate(d.y, 0, 1)), day = week.getDay();\n week = day > 4 || day === 0 ? timeMonday.ceil(week) : timeMonday(week);\n week = timeDay.offset(week, (d.V - 1) * 7);\n d.y = week.getFullYear();\n d.m = week.getMonth();\n d.d = week.getDate() + (d.w + 6) % 7;\n }\n } else if (\"W\" in d || \"U\" in d) {\n if (!(\"w\" in d)) d.w = \"u\" in d ? d.u % 7 : \"W\" in d ? 1 : 0;\n day = \"Z\" in d ? utcDate(newDate(d.y, 0, 1)).getUTCDay() : localDate(newDate(d.y, 0, 1)).getDay();\n d.m = 0;\n d.d = \"W\" in d ? (d.w + 6) % 7 + d.W * 7 - (day + 5) % 7 : d.w + d.U * 7 - (day + 6) % 7;\n }\n\n // If a time zone is specified, all fields are interpreted as UTC and then\n // offset according to the specified time zone.\n if (\"Z\" in d) {\n d.H += d.Z / 100 | 0;\n d.M += d.Z % 100;\n return utcDate(d);\n }\n\n // Otherwise, all fields are in local time.\n return localDate(d);\n };\n }\n\n function parseSpecifier(d, specifier, string, j) {\n var i = 0,\n n = specifier.length,\n m = string.length,\n c,\n parse;\n\n while (i < n) {\n if (j >= m) return -1;\n c = specifier.charCodeAt(i++);\n if (c === 37) {\n c = specifier.charAt(i++);\n parse = parses[c in pads ? specifier.charAt(i++) : c];\n if (!parse || ((j = parse(d, string, j)) < 0)) return -1;\n } else if (c != string.charCodeAt(j++)) {\n return -1;\n }\n }\n\n return j;\n }\n\n function parsePeriod(d, string, i) {\n var n = periodRe.exec(string.slice(i));\n return n ? (d.p = periodLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseShortWeekday(d, string, i) {\n var n = shortWeekdayRe.exec(string.slice(i));\n return n ? (d.w = shortWeekdayLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseWeekday(d, string, i) {\n var n = weekdayRe.exec(string.slice(i));\n return n ? (d.w = weekdayLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseShortMonth(d, string, i) {\n var n = shortMonthRe.exec(string.slice(i));\n return n ? (d.m = shortMonthLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseMonth(d, string, i) {\n var n = monthRe.exec(string.slice(i));\n return n ? (d.m = monthLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseLocaleDateTime(d, string, i) {\n return parseSpecifier(d, locale_dateTime, string, i);\n }\n\n function parseLocaleDate(d, string, i) {\n return parseSpecifier(d, locale_date, string, i);\n }\n\n function parseLocaleTime(d, string, i) {\n return parseSpecifier(d, locale_time, string, i);\n }\n\n function formatShortWeekday(d) {\n return locale_shortWeekdays[d.getDay()];\n }\n\n function formatWeekday(d) {\n return locale_weekdays[d.getDay()];\n }\n\n function formatShortMonth(d) {\n return locale_shortMonths[d.getMonth()];\n }\n\n function formatMonth(d) {\n return locale_months[d.getMonth()];\n }\n\n function formatPeriod(d) {\n return locale_periods[+(d.getHours() >= 12)];\n }\n\n function formatQuarter(d) {\n return 1 + ~~(d.getMonth() / 3);\n }\n\n function formatUTCShortWeekday(d) {\n return locale_shortWeekdays[d.getUTCDay()];\n }\n\n function formatUTCWeekday(d) {\n return locale_weekdays[d.getUTCDay()];\n }\n\n function formatUTCShortMonth(d) {\n return locale_shortMonths[d.getUTCMonth()];\n }\n\n function formatUTCMonth(d) {\n return locale_months[d.getUTCMonth()];\n }\n\n function formatUTCPeriod(d) {\n return locale_periods[+(d.getUTCHours() >= 12)];\n }\n\n function formatUTCQuarter(d) {\n return 1 + ~~(d.getUTCMonth() / 3);\n }\n\n return {\n format: function(specifier) {\n var f = newFormat(specifier += \"\", formats);\n f.toString = function() { return specifier; };\n return f;\n },\n parse: function(specifier) {\n var p = newParse(specifier += \"\", false);\n p.toString = function() { return specifier; };\n return p;\n },\n utcFormat: function(specifier) {\n var f = newFormat(specifier += \"\", utcFormats);\n f.toString = function() { return specifier; };\n return f;\n },\n utcParse: function(specifier) {\n var p = newParse(specifier += \"\", true);\n p.toString = function() { return specifier; };\n return p;\n }\n };\n}\n\nvar pads = {\"-\": \"\", \"_\": \" \", \"0\": \"0\"},\n numberRe = /^\\s*\\d+/, // note: ignores next directive\n percentRe = /^%/,\n requoteRe = /[\\\\^$*+?|[\\]().{}]/g;\n\nfunction pad(value, fill, width) {\n var sign = value < 0 ? \"-\" : \"\",\n string = (sign ? -value : value) + \"\",\n length = string.length;\n return sign + (length < width ? new Array(width - length + 1).join(fill) + string : string);\n}\n\nfunction requote(s) {\n return s.replace(requoteRe, \"\\\\$&\");\n}\n\nfunction formatRe(names) {\n return new RegExp(\"^(?:\" + names.map(requote).join(\"|\") + \")\", \"i\");\n}\n\nfunction formatLookup(names) {\n return new Map(names.map((name, i) => [name.toLowerCase(), i]));\n}\n\nfunction parseWeekdayNumberSunday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 1));\n return n ? (d.w = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekdayNumberMonday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 1));\n return n ? (d.u = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekNumberSunday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.U = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekNumberISO(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.V = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekNumberMonday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.W = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseFullYear(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 4));\n return n ? (d.y = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseYear(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.y = +n[0] + (+n[0] > 68 ? 1900 : 2000), i + n[0].length) : -1;\n}\n\nfunction parseZone(d, string, i) {\n var n = /^(Z)|([+-]\\d\\d)(?::?(\\d\\d))?/.exec(string.slice(i, i + 6));\n return n ? (d.Z = n[1] ? 0 : -(n[2] + (n[3] || \"00\")), i + n[0].length) : -1;\n}\n\nfunction parseQuarter(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 1));\n return n ? (d.q = n[0] * 3 - 3, i + n[0].length) : -1;\n}\n\nfunction parseMonthNumber(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.m = n[0] - 1, i + n[0].length) : -1;\n}\n\nfunction parseDayOfMonth(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.d = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseDayOfYear(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 3));\n return n ? (d.m = 0, d.d = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseHour24(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.H = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseMinutes(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.M = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseSeconds(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.S = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseMilliseconds(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 3));\n return n ? (d.L = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseMicroseconds(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 6));\n return n ? (d.L = Math.floor(n[0] / 1000), i + n[0].length) : -1;\n}\n\nfunction parseLiteralPercent(d, string, i) {\n var n = percentRe.exec(string.slice(i, i + 1));\n return n ? i + n[0].length : -1;\n}\n\nfunction parseUnixTimestamp(d, string, i) {\n var n = numberRe.exec(string.slice(i));\n return n ? (d.Q = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseUnixTimestampSeconds(d, string, i) {\n var n = numberRe.exec(string.slice(i));\n return n ? (d.s = +n[0], i + n[0].length) : -1;\n}\n\nfunction formatDayOfMonth(d, p) {\n return pad(d.getDate(), p, 2);\n}\n\nfunction formatHour24(d, p) {\n return pad(d.getHours(), p, 2);\n}\n\nfunction formatHour12(d, p) {\n return pad(d.getHours() % 12 || 12, p, 2);\n}\n\nfunction formatDayOfYear(d, p) {\n return pad(1 + timeDay.count(timeYear(d), d), p, 3);\n}\n\nfunction formatMilliseconds(d, p) {\n return pad(d.getMilliseconds(), p, 3);\n}\n\nfunction formatMicroseconds(d, p) {\n return formatMilliseconds(d, p) + \"000\";\n}\n\nfunction formatMonthNumber(d, p) {\n return pad(d.getMonth() + 1, p, 2);\n}\n\nfunction formatMinutes(d, p) {\n return pad(d.getMinutes(), p, 2);\n}\n\nfunction formatSeconds(d, p) {\n return pad(d.getSeconds(), p, 2);\n}\n\nfunction formatWeekdayNumberMonday(d) {\n var day = d.getDay();\n return day === 0 ? 7 : day;\n}\n\nfunction formatWeekNumberSunday(d, p) {\n return pad(timeSunday.count(timeYear(d) - 1, d), p, 2);\n}\n\nfunction dISO(d) {\n var day = d.getDay();\n return (day >= 4 || day === 0) ? timeThursday(d) : timeThursday.ceil(d);\n}\n\nfunction formatWeekNumberISO(d, p) {\n d = dISO(d);\n return pad(timeThursday.count(timeYear(d), d) + (timeYear(d).getDay() === 4), p, 2);\n}\n\nfunction formatWeekdayNumberSunday(d) {\n return d.getDay();\n}\n\nfunction formatWeekNumberMonday(d, p) {\n return pad(timeMonday.count(timeYear(d) - 1, d), p, 2);\n}\n\nfunction formatYear(d, p) {\n return pad(d.getFullYear() % 100, p, 2);\n}\n\nfunction formatYearISO(d, p) {\n d = dISO(d);\n return pad(d.getFullYear() % 100, p, 2);\n}\n\nfunction formatFullYear(d, p) {\n return pad(d.getFullYear() % 10000, p, 4);\n}\n\nfunction formatFullYearISO(d, p) {\n var day = d.getDay();\n d = (day >= 4 || day === 0) ? timeThursday(d) : timeThursday.ceil(d);\n return pad(d.getFullYear() % 10000, p, 4);\n}\n\nfunction formatZone(d) {\n var z = d.getTimezoneOffset();\n return (z > 0 ? \"-\" : (z *= -1, \"+\"))\n + pad(z / 60 | 0, \"0\", 2)\n + pad(z % 60, \"0\", 2);\n}\n\nfunction formatUTCDayOfMonth(d, p) {\n return pad(d.getUTCDate(), p, 2);\n}\n\nfunction formatUTCHour24(d, p) {\n return pad(d.getUTCHours(), p, 2);\n}\n\nfunction formatUTCHour12(d, p) {\n return pad(d.getUTCHours() % 12 || 12, p, 2);\n}\n\nfunction formatUTCDayOfYear(d, p) {\n return pad(1 + utcDay.count(utcYear(d), d), p, 3);\n}\n\nfunction formatUTCMilliseconds(d, p) {\n return pad(d.getUTCMilliseconds(), p, 3);\n}\n\nfunction formatUTCMicroseconds(d, p) {\n return formatUTCMilliseconds(d, p) + \"000\";\n}\n\nfunction formatUTCMonthNumber(d, p) {\n return pad(d.getUTCMonth() + 1, p, 2);\n}\n\nfunction formatUTCMinutes(d, p) {\n return pad(d.getUTCMinutes(), p, 2);\n}\n\nfunction formatUTCSeconds(d, p) {\n return pad(d.getUTCSeconds(), p, 2);\n}\n\nfunction formatUTCWeekdayNumberMonday(d) {\n var dow = d.getUTCDay();\n return dow === 0 ? 7 : dow;\n}\n\nfunction formatUTCWeekNumberSunday(d, p) {\n return pad(utcSunday.count(utcYear(d) - 1, d), p, 2);\n}\n\nfunction UTCdISO(d) {\n var day = d.getUTCDay();\n return (day >= 4 || day === 0) ? utcThursday(d) : utcThursday.ceil(d);\n}\n\nfunction formatUTCWeekNumberISO(d, p) {\n d = UTCdISO(d);\n return pad(utcThursday.count(utcYear(d), d) + (utcYear(d).getUTCDay() === 4), p, 2);\n}\n\nfunction formatUTCWeekdayNumberSunday(d) {\n return d.getUTCDay();\n}\n\nfunction formatUTCWeekNumberMonday(d, p) {\n return pad(utcMonday.count(utcYear(d) - 1, d), p, 2);\n}\n\nfunction formatUTCYear(d, p) {\n return pad(d.getUTCFullYear() % 100, p, 2);\n}\n\nfunction formatUTCYearISO(d, p) {\n d = UTCdISO(d);\n return pad(d.getUTCFullYear() % 100, p, 2);\n}\n\nfunction formatUTCFullYear(d, p) {\n return pad(d.getUTCFullYear() % 10000, p, 4);\n}\n\nfunction formatUTCFullYearISO(d, p) {\n var day = d.getUTCDay();\n d = (day >= 4 || day === 0) ? utcThursday(d) : utcThursday.ceil(d);\n return pad(d.getUTCFullYear() % 10000, p, 4);\n}\n\nfunction formatUTCZone() {\n return \"+0000\";\n}\n\nfunction formatLiteralPercent() {\n return \"%\";\n}\n\nfunction formatUnixTimestamp(d) {\n return +d;\n}\n\nfunction formatUnixTimestampSeconds(d) {\n return Math.floor(+d / 1000);\n}\n", "import formatLocale from \"./locale.js\";\n\nvar locale;\nexport var timeFormat;\nexport var timeParse;\nexport var utcFormat;\nexport var utcParse;\n\ndefaultLocale({\n dateTime: \"%x, %X\",\n date: \"%-m/%-d/%Y\",\n time: \"%-I:%M:%S %p\",\n periods: [\"AM\", \"PM\"],\n days: [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"],\n shortDays: [\"Sun\", \"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\"],\n months: [\"January\", \"February\", \"March\", \"April\", \"May\", \"June\", \"July\", \"August\", \"September\", \"October\", \"November\", \"December\"],\n shortMonths: [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sep\", \"Oct\", \"Nov\", \"Dec\"]\n});\n\nexport default function defaultLocale(definition) {\n locale = formatLocale(definition);\n timeFormat = locale.format;\n timeParse = locale.parse;\n utcFormat = locale.utcFormat;\n utcParse = locale.utcParse;\n return locale;\n}\n", "export default function nice(domain, interval) {\n domain = domain.slice();\n\n var i0 = 0,\n i1 = domain.length - 1,\n x0 = domain[i0],\n x1 = domain[i1],\n t;\n\n if (x1 < x0) {\n t = i0, i0 = i1, i1 = t;\n t = x0, x0 = x1, x1 = t;\n }\n\n domain[i0] = interval.floor(x0);\n domain[i1] = interval.ceil(x1);\n return domain;\n}\n", "import {timeYear, timeMonth, timeWeek, timeDay, timeHour, timeMinute, timeSecond, timeTicks, timeTickInterval} from \"d3-time\";\nimport {timeFormat} from \"d3-time-format\";\nimport continuous, {copy} from \"./continuous.js\";\nimport {initRange} from \"./init.js\";\nimport nice from \"./nice.js\";\n\nfunction date(t) {\n return new Date(t);\n}\n\nfunction number(t) {\n return t instanceof Date ? +t : +new Date(+t);\n}\n\nexport function calendar(ticks, tickInterval, year, month, week, day, hour, minute, second, format) {\n var scale = continuous(),\n invert = scale.invert,\n domain = scale.domain;\n\n var formatMillisecond = format(\".%L\"),\n formatSecond = format(\":%S\"),\n formatMinute = format(\"%I:%M\"),\n formatHour = format(\"%I %p\"),\n formatDay = format(\"%a %d\"),\n formatWeek = format(\"%b %d\"),\n formatMonth = format(\"%B\"),\n formatYear = format(\"%Y\");\n\n function tickFormat(date) {\n return (second(date) < date ? formatMillisecond\n : minute(date) < date ? formatSecond\n : hour(date) < date ? formatMinute\n : day(date) < date ? formatHour\n : month(date) < date ? (week(date) < date ? formatDay : formatWeek)\n : year(date) < date ? formatMonth\n : formatYear)(date);\n }\n\n scale.invert = function(y) {\n return new Date(invert(y));\n };\n\n scale.domain = function(_) {\n return arguments.length ? domain(Array.from(_, number)) : domain().map(date);\n };\n\n scale.ticks = function(interval) {\n var d = domain();\n return ticks(d[0], d[d.length - 1], interval == null ? 10 : interval);\n };\n\n scale.tickFormat = function(count, specifier) {\n return specifier == null ? tickFormat : format(specifier);\n };\n\n scale.nice = function(interval) {\n var d = domain();\n if (!interval || typeof interval.range !== \"function\") interval = tickInterval(d[0], d[d.length - 1], interval == null ? 10 : interval);\n return interval ? domain(nice(d, interval)) : scale;\n };\n\n scale.copy = function() {\n return copy(scale, calendar(ticks, tickInterval, year, month, week, day, hour, minute, second, format));\n };\n\n return scale;\n}\n\nexport default function time() {\n return initRange.apply(calendar(timeTicks, timeTickInterval, timeYear, timeMonth, timeWeek, timeDay, timeHour, timeMinute, timeSecond, timeFormat).domain([new Date(2000, 0, 1), new Date(2000, 0, 2)]), arguments);\n}\n", "export default function(specifier) {\n var n = specifier.length / 6 | 0, colors = new Array(n), i = 0;\n while (i < n) colors[i] = \"#\" + specifier.slice(i * 6, ++i * 6);\n return colors;\n}\n", "import colors from \"../colors.js\";\n\nexport default colors(\"4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab\");\n", "export default function(x) {\n return function constant() {\n return x;\n };\n}\n", "export const abs = Math.abs;\nexport const atan2 = Math.atan2;\nexport const cos = Math.cos;\nexport const max = Math.max;\nexport const min = Math.min;\nexport const sin = Math.sin;\nexport const sqrt = Math.sqrt;\n\nexport const epsilon = 1e-12;\nexport const pi = Math.PI;\nexport const halfPi = pi / 2;\nexport const tau = 2 * pi;\n\nexport function acos(x) {\n return x > 1 ? 0 : x < -1 ? pi : Math.acos(x);\n}\n\nexport function asin(x) {\n return x >= 1 ? halfPi : x <= -1 ? -halfPi : Math.asin(x);\n}\n", "const pi = Math.PI,\n tau = 2 * pi,\n epsilon = 1e-6,\n tauEpsilon = tau - epsilon;\n\nfunction append(strings) {\n this._ += strings[0];\n for (let i = 1, n = strings.length; i < n; ++i) {\n this._ += arguments[i] + strings[i];\n }\n}\n\nfunction appendRound(digits) {\n let d = Math.floor(digits);\n if (!(d >= 0)) throw new Error(`invalid digits: ${digits}`);\n if (d > 15) return append;\n const k = 10 ** d;\n return function(strings) {\n this._ += strings[0];\n for (let i = 1, n = strings.length; i < n; ++i) {\n this._ += Math.round(arguments[i] * k) / k + strings[i];\n }\n };\n}\n\nexport class Path {\n constructor(digits) {\n this._x0 = this._y0 = // start of current subpath\n this._x1 = this._y1 = null; // end of current subpath\n this._ = \"\";\n this._append = digits == null ? append : appendRound(digits);\n }\n moveTo(x, y) {\n this._append`M${this._x0 = this._x1 = +x},${this._y0 = this._y1 = +y}`;\n }\n closePath() {\n if (this._x1 !== null) {\n this._x1 = this._x0, this._y1 = this._y0;\n this._append`Z`;\n }\n }\n lineTo(x, y) {\n this._append`L${this._x1 = +x},${this._y1 = +y}`;\n }\n quadraticCurveTo(x1, y1, x, y) {\n this._append`Q${+x1},${+y1},${this._x1 = +x},${this._y1 = +y}`;\n }\n bezierCurveTo(x1, y1, x2, y2, x, y) {\n this._append`C${+x1},${+y1},${+x2},${+y2},${this._x1 = +x},${this._y1 = +y}`;\n }\n arcTo(x1, y1, x2, y2, r) {\n x1 = +x1, y1 = +y1, x2 = +x2, y2 = +y2, r = +r;\n\n // Is the radius negative? Error.\n if (r < 0) throw new Error(`negative radius: ${r}`);\n\n let x0 = this._x1,\n y0 = this._y1,\n x21 = x2 - x1,\n y21 = y2 - y1,\n x01 = x0 - x1,\n y01 = y0 - y1,\n l01_2 = x01 * x01 + y01 * y01;\n\n // Is this path empty? Move to (x1,y1).\n if (this._x1 === null) {\n this._append`M${this._x1 = x1},${this._y1 = y1}`;\n }\n\n // Or, is (x1,y1) coincident with (x0,y0)? Do nothing.\n else if (!(l01_2 > epsilon));\n\n // Or, are (x0,y0), (x1,y1) and (x2,y2) collinear?\n // Equivalently, is (x1,y1) coincident with (x2,y2)?\n // Or, is the radius zero? Line to (x1,y1).\n else if (!(Math.abs(y01 * x21 - y21 * x01) > epsilon) || !r) {\n this._append`L${this._x1 = x1},${this._y1 = y1}`;\n }\n\n // Otherwise, draw an arc!\n else {\n let x20 = x2 - x0,\n y20 = y2 - y0,\n l21_2 = x21 * x21 + y21 * y21,\n l20_2 = x20 * x20 + y20 * y20,\n l21 = Math.sqrt(l21_2),\n l01 = Math.sqrt(l01_2),\n l = r * Math.tan((pi - Math.acos((l21_2 + l01_2 - l20_2) / (2 * l21 * l01))) / 2),\n t01 = l / l01,\n t21 = l / l21;\n\n // If the start tangent is not coincident with (x0,y0), line to.\n if (Math.abs(t01 - 1) > epsilon) {\n this._append`L${x1 + t01 * x01},${y1 + t01 * y01}`;\n }\n\n this._append`A${r},${r},0,0,${+(y01 * x20 > x01 * y20)},${this._x1 = x1 + t21 * x21},${this._y1 = y1 + t21 * y21}`;\n }\n }\n arc(x, y, r, a0, a1, ccw) {\n x = +x, y = +y, r = +r, ccw = !!ccw;\n\n // Is the radius negative? Error.\n if (r < 0) throw new Error(`negative radius: ${r}`);\n\n let dx = r * Math.cos(a0),\n dy = r * Math.sin(a0),\n x0 = x + dx,\n y0 = y + dy,\n cw = 1 ^ ccw,\n da = ccw ? a0 - a1 : a1 - a0;\n\n // Is this path empty? Move to (x0,y0).\n if (this._x1 === null) {\n this._append`M${x0},${y0}`;\n }\n\n // Or, is (x0,y0) not coincident with the previous point? Line to (x0,y0).\n else if (Math.abs(this._x1 - x0) > epsilon || Math.abs(this._y1 - y0) > epsilon) {\n this._append`L${x0},${y0}`;\n }\n\n // Is this arc empty? We\u2019re done.\n if (!r) return;\n\n // Does the angle go the wrong way? Flip the direction.\n if (da < 0) da = da % tau + tau;\n\n // Is this a complete circle? Draw two arcs to complete the circle.\n if (da > tauEpsilon) {\n this._append`A${r},${r},0,1,${cw},${x - dx},${y - dy}A${r},${r},0,1,${cw},${this._x1 = x0},${this._y1 = y0}`;\n }\n\n // Is this arc non-empty? Draw an arc!\n else if (da > epsilon) {\n this._append`A${r},${r},0,${+(da >= pi)},${cw},${this._x1 = x + r * Math.cos(a1)},${this._y1 = y + r * Math.sin(a1)}`;\n }\n }\n rect(x, y, w, h) {\n this._append`M${this._x0 = this._x1 = +x},${this._y0 = this._y1 = +y}h${w = +w}v${+h}h${-w}Z`;\n }\n toString() {\n return this._;\n }\n}\n\nexport function path() {\n return new Path;\n}\n\n// Allow instanceof d3.path\npath.prototype = Path.prototype;\n\nexport function pathRound(digits = 3) {\n return new Path(+digits);\n}\n", "import {Path} from \"d3-path\";\n\nexport function withPath(shape) {\n let digits = 3;\n\n shape.digits = function(_) {\n if (!arguments.length) return digits;\n if (_ == null) {\n digits = null;\n } else {\n const d = Math.floor(_);\n if (!(d >= 0)) throw new RangeError(`invalid digits: ${_}`);\n digits = d;\n }\n return shape;\n };\n\n return () => new Path(digits);\n}\n", "import constant from \"./constant.js\";\nimport {abs, acos, asin, atan2, cos, epsilon, halfPi, max, min, pi, sin, sqrt, tau} from \"./math.js\";\nimport {withPath} from \"./path.js\";\n\nfunction arcInnerRadius(d) {\n return d.innerRadius;\n}\n\nfunction arcOuterRadius(d) {\n return d.outerRadius;\n}\n\nfunction arcStartAngle(d) {\n return d.startAngle;\n}\n\nfunction arcEndAngle(d) {\n return d.endAngle;\n}\n\nfunction arcPadAngle(d) {\n return d && d.padAngle; // Note: optional!\n}\n\nfunction intersect(x0, y0, x1, y1, x2, y2, x3, y3) {\n var x10 = x1 - x0, y10 = y1 - y0,\n x32 = x3 - x2, y32 = y3 - y2,\n t = y32 * x10 - x32 * y10;\n if (t * t < epsilon) return;\n t = (x32 * (y0 - y2) - y32 * (x0 - x2)) / t;\n return [x0 + t * x10, y0 + t * y10];\n}\n\n// Compute perpendicular offset line of length rc.\n// http://mathworld.wolfram.com/Circle-LineIntersection.html\nfunction cornerTangents(x0, y0, x1, y1, r1, rc, cw) {\n var x01 = x0 - x1,\n y01 = y0 - y1,\n lo = (cw ? rc : -rc) / sqrt(x01 * x01 + y01 * y01),\n ox = lo * y01,\n oy = -lo * x01,\n x11 = x0 + ox,\n y11 = y0 + oy,\n x10 = x1 + ox,\n y10 = y1 + oy,\n x00 = (x11 + x10) / 2,\n y00 = (y11 + y10) / 2,\n dx = x10 - x11,\n dy = y10 - y11,\n d2 = dx * dx + dy * dy,\n r = r1 - rc,\n D = x11 * y10 - x10 * y11,\n d = (dy < 0 ? -1 : 1) * sqrt(max(0, r * r * d2 - D * D)),\n cx0 = (D * dy - dx * d) / d2,\n cy0 = (-D * dx - dy * d) / d2,\n cx1 = (D * dy + dx * d) / d2,\n cy1 = (-D * dx + dy * d) / d2,\n dx0 = cx0 - x00,\n dy0 = cy0 - y00,\n dx1 = cx1 - x00,\n dy1 = cy1 - y00;\n\n // Pick the closer of the two intersection points.\n // TODO Is there a faster way to determine which intersection to use?\n if (dx0 * dx0 + dy0 * dy0 > dx1 * dx1 + dy1 * dy1) cx0 = cx1, cy0 = cy1;\n\n return {\n cx: cx0,\n cy: cy0,\n x01: -ox,\n y01: -oy,\n x11: cx0 * (r1 / r - 1),\n y11: cy0 * (r1 / r - 1)\n };\n}\n\nexport default function() {\n var innerRadius = arcInnerRadius,\n outerRadius = arcOuterRadius,\n cornerRadius = constant(0),\n padRadius = null,\n startAngle = arcStartAngle,\n endAngle = arcEndAngle,\n padAngle = arcPadAngle,\n context = null,\n path = withPath(arc);\n\n function arc() {\n var buffer,\n r,\n r0 = +innerRadius.apply(this, arguments),\n r1 = +outerRadius.apply(this, arguments),\n a0 = startAngle.apply(this, arguments) - halfPi,\n a1 = endAngle.apply(this, arguments) - halfPi,\n da = abs(a1 - a0),\n cw = a1 > a0;\n\n if (!context) context = buffer = path();\n\n // Ensure that the outer radius is always larger than the inner radius.\n if (r1 < r0) r = r1, r1 = r0, r0 = r;\n\n // Is it a point?\n if (!(r1 > epsilon)) context.moveTo(0, 0);\n\n // Or is it a circle or annulus?\n else if (da > tau - epsilon) {\n context.moveTo(r1 * cos(a0), r1 * sin(a0));\n context.arc(0, 0, r1, a0, a1, !cw);\n if (r0 > epsilon) {\n context.moveTo(r0 * cos(a1), r0 * sin(a1));\n context.arc(0, 0, r0, a1, a0, cw);\n }\n }\n\n // Or is it a circular or annular sector?\n else {\n var a01 = a0,\n a11 = a1,\n a00 = a0,\n a10 = a1,\n da0 = da,\n da1 = da,\n ap = padAngle.apply(this, arguments) / 2,\n rp = (ap > epsilon) && (padRadius ? +padRadius.apply(this, arguments) : sqrt(r0 * r0 + r1 * r1)),\n rc = min(abs(r1 - r0) / 2, +cornerRadius.apply(this, arguments)),\n rc0 = rc,\n rc1 = rc,\n t0,\n t1;\n\n // Apply padding? Note that since r1 \u2265 r0, da1 \u2265 da0.\n if (rp > epsilon) {\n var p0 = asin(rp / r0 * sin(ap)),\n p1 = asin(rp / r1 * sin(ap));\n if ((da0 -= p0 * 2) > epsilon) p0 *= (cw ? 1 : -1), a00 += p0, a10 -= p0;\n else da0 = 0, a00 = a10 = (a0 + a1) / 2;\n if ((da1 -= p1 * 2) > epsilon) p1 *= (cw ? 1 : -1), a01 += p1, a11 -= p1;\n else da1 = 0, a01 = a11 = (a0 + a1) / 2;\n }\n\n var x01 = r1 * cos(a01),\n y01 = r1 * sin(a01),\n x10 = r0 * cos(a10),\n y10 = r0 * sin(a10);\n\n // Apply rounded corners?\n if (rc > epsilon) {\n var x11 = r1 * cos(a11),\n y11 = r1 * sin(a11),\n x00 = r0 * cos(a00),\n y00 = r0 * sin(a00),\n oc;\n\n // Restrict the corner radius according to the sector angle. If this\n // intersection fails, it\u2019s probably because the arc is too small, so\n // disable the corner radius entirely.\n if (da < pi) {\n if (oc = intersect(x01, y01, x00, y00, x11, y11, x10, y10)) {\n var ax = x01 - oc[0],\n ay = y01 - oc[1],\n bx = x11 - oc[0],\n by = y11 - oc[1],\n kc = 1 / sin(acos((ax * bx + ay * by) / (sqrt(ax * ax + ay * ay) * sqrt(bx * bx + by * by))) / 2),\n lc = sqrt(oc[0] * oc[0] + oc[1] * oc[1]);\n rc0 = min(rc, (r0 - lc) / (kc - 1));\n rc1 = min(rc, (r1 - lc) / (kc + 1));\n } else {\n rc0 = rc1 = 0;\n }\n }\n }\n\n // Is the sector collapsed to a line?\n if (!(da1 > epsilon)) context.moveTo(x01, y01);\n\n // Does the sector\u2019s outer ring have rounded corners?\n else if (rc1 > epsilon) {\n t0 = cornerTangents(x00, y00, x01, y01, r1, rc1, cw);\n t1 = cornerTangents(x11, y11, x10, y10, r1, rc1, cw);\n\n context.moveTo(t0.cx + t0.x01, t0.cy + t0.y01);\n\n // Have the corners merged?\n if (rc1 < rc) context.arc(t0.cx, t0.cy, rc1, atan2(t0.y01, t0.x01), atan2(t1.y01, t1.x01), !cw);\n\n // Otherwise, draw the two corners and the ring.\n else {\n context.arc(t0.cx, t0.cy, rc1, atan2(t0.y01, t0.x01), atan2(t0.y11, t0.x11), !cw);\n context.arc(0, 0, r1, atan2(t0.cy + t0.y11, t0.cx + t0.x11), atan2(t1.cy + t1.y11, t1.cx + t1.x11), !cw);\n context.arc(t1.cx, t1.cy, rc1, atan2(t1.y11, t1.x11), atan2(t1.y01, t1.x01), !cw);\n }\n }\n\n // Or is the outer ring just a circular arc?\n else context.moveTo(x01, y01), context.arc(0, 0, r1, a01, a11, !cw);\n\n // Is there no inner ring, and it\u2019s a circular sector?\n // Or perhaps it\u2019s an annular sector collapsed due to padding?\n if (!(r0 > epsilon) || !(da0 > epsilon)) context.lineTo(x10, y10);\n\n // Does the sector\u2019s inner ring (or point) have rounded corners?\n else if (rc0 > epsilon) {\n t0 = cornerTangents(x10, y10, x11, y11, r0, -rc0, cw);\n t1 = cornerTangents(x01, y01, x00, y00, r0, -rc0, cw);\n\n context.lineTo(t0.cx + t0.x01, t0.cy + t0.y01);\n\n // Have the corners merged?\n if (rc0 < rc) context.arc(t0.cx, t0.cy, rc0, atan2(t0.y01, t0.x01), atan2(t1.y01, t1.x01), !cw);\n\n // Otherwise, draw the two corners and the ring.\n else {\n context.arc(t0.cx, t0.cy, rc0, atan2(t0.y01, t0.x01), atan2(t0.y11, t0.x11), !cw);\n context.arc(0, 0, r0, atan2(t0.cy + t0.y11, t0.cx + t0.x11), atan2(t1.cy + t1.y11, t1.cx + t1.x11), cw);\n context.arc(t1.cx, t1.cy, rc0, atan2(t1.y11, t1.x11), atan2(t1.y01, t1.x01), !cw);\n }\n }\n\n // Or is the inner ring just a circular arc?\n else context.arc(0, 0, r0, a10, a00, cw);\n }\n\n context.closePath();\n\n if (buffer) return context = null, buffer + \"\" || null;\n }\n\n arc.centroid = function() {\n var r = (+innerRadius.apply(this, arguments) + +outerRadius.apply(this, arguments)) / 2,\n a = (+startAngle.apply(this, arguments) + +endAngle.apply(this, arguments)) / 2 - pi / 2;\n return [cos(a) * r, sin(a) * r];\n };\n\n arc.innerRadius = function(_) {\n return arguments.length ? (innerRadius = typeof _ === \"function\" ? _ : constant(+_), arc) : innerRadius;\n };\n\n arc.outerRadius = function(_) {\n return arguments.length ? (outerRadius = typeof _ === \"function\" ? _ : constant(+_), arc) : outerRadius;\n };\n\n arc.cornerRadius = function(_) {\n return arguments.length ? (cornerRadius = typeof _ === \"function\" ? _ : constant(+_), arc) : cornerRadius;\n };\n\n arc.padRadius = function(_) {\n return arguments.length ? (padRadius = _ == null ? null : typeof _ === \"function\" ? _ : constant(+_), arc) : padRadius;\n };\n\n arc.startAngle = function(_) {\n return arguments.length ? (startAngle = typeof _ === \"function\" ? _ : constant(+_), arc) : startAngle;\n };\n\n arc.endAngle = function(_) {\n return arguments.length ? (endAngle = typeof _ === \"function\" ? _ : constant(+_), arc) : endAngle;\n };\n\n arc.padAngle = function(_) {\n return arguments.length ? (padAngle = typeof _ === \"function\" ? _ : constant(+_), arc) : padAngle;\n };\n\n arc.context = function(_) {\n return arguments.length ? ((context = _ == null ? null : _), arc) : context;\n };\n\n return arc;\n}\n", "function Linear(context) {\n this._context = context;\n}\n\nLinear.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; // falls through\n default: this._context.lineTo(x, y); break;\n }\n }\n};\n\nexport default function(context) {\n return new Linear(context);\n}\n", "export var slice = Array.prototype.slice;\n\nexport default function(x) {\n return typeof x === \"object\" && \"length\" in x\n ? x // Array, TypedArray, NodeList, array-like\n : Array.from(x); // Map, Set, iterable, string, or anything else\n}\n", "export function x(p) {\n return p[0];\n}\n\nexport function y(p) {\n return p[1];\n}\n", "import array from \"./array.js\";\nimport constant from \"./constant.js\";\nimport curveLinear from \"./curve/linear.js\";\nimport {withPath} from \"./path.js\";\nimport {x as pointX, y as pointY} from \"./point.js\";\n\nexport default function(x, y) {\n var defined = constant(true),\n context = null,\n curve = curveLinear,\n output = null,\n path = withPath(line);\n\n x = typeof x === \"function\" ? x : (x === undefined) ? pointX : constant(x);\n y = typeof y === \"function\" ? y : (y === undefined) ? pointY : constant(y);\n\n function line(data) {\n var i,\n n = (data = array(data)).length,\n d,\n defined0 = false,\n buffer;\n\n if (context == null) output = curve(buffer = path());\n\n for (i = 0; i <= n; ++i) {\n if (!(i < n && defined(d = data[i], i, data)) === defined0) {\n if (defined0 = !defined0) output.lineStart();\n else output.lineEnd();\n }\n if (defined0) output.point(+x(d, i, data), +y(d, i, data));\n }\n\n if (buffer) return output = null, buffer + \"\" || null;\n }\n\n line.x = function(_) {\n return arguments.length ? (x = typeof _ === \"function\" ? _ : constant(+_), line) : x;\n };\n\n line.y = function(_) {\n return arguments.length ? (y = typeof _ === \"function\" ? _ : constant(+_), line) : y;\n };\n\n line.defined = function(_) {\n return arguments.length ? (defined = typeof _ === \"function\" ? _ : constant(!!_), line) : defined;\n };\n\n line.curve = function(_) {\n return arguments.length ? (curve = _, context != null && (output = curve(context)), line) : curve;\n };\n\n line.context = function(_) {\n return arguments.length ? (_ == null ? context = output = null : output = curve(context = _), line) : context;\n };\n\n return line;\n}\n", "export default function(a, b) {\n return b < a ? -1 : b > a ? 1 : b >= a ? 0 : NaN;\n}\n", "export default function(d) {\n return d;\n}\n", "import array from \"./array.js\";\nimport constant from \"./constant.js\";\nimport descending from \"./descending.js\";\nimport identity from \"./identity.js\";\nimport {tau} from \"./math.js\";\n\nexport default function() {\n var value = identity,\n sortValues = descending,\n sort = null,\n startAngle = constant(0),\n endAngle = constant(tau),\n padAngle = constant(0);\n\n function pie(data) {\n var i,\n n = (data = array(data)).length,\n j,\n k,\n sum = 0,\n index = new Array(n),\n arcs = new Array(n),\n a0 = +startAngle.apply(this, arguments),\n da = Math.min(tau, Math.max(-tau, endAngle.apply(this, arguments) - a0)),\n a1,\n p = Math.min(Math.abs(da) / n, padAngle.apply(this, arguments)),\n pa = p * (da < 0 ? -1 : 1),\n v;\n\n for (i = 0; i < n; ++i) {\n if ((v = arcs[index[i] = i] = +value(data[i], i, data)) > 0) {\n sum += v;\n }\n }\n\n // Optionally sort the arcs by previously-computed values or by data.\n if (sortValues != null) index.sort(function(i, j) { return sortValues(arcs[i], arcs[j]); });\n else if (sort != null) index.sort(function(i, j) { return sort(data[i], data[j]); });\n\n // Compute the arcs! They are stored in the original data's order.\n for (i = 0, k = sum ? (da - n * pa) / sum : 0; i < n; ++i, a0 = a1) {\n j = index[i], v = arcs[j], a1 = a0 + (v > 0 ? v * k : 0) + pa, arcs[j] = {\n data: data[j],\n index: i,\n value: v,\n startAngle: a0,\n endAngle: a1,\n padAngle: p\n };\n }\n\n return arcs;\n }\n\n pie.value = function(_) {\n return arguments.length ? (value = typeof _ === \"function\" ? _ : constant(+_), pie) : value;\n };\n\n pie.sortValues = function(_) {\n return arguments.length ? (sortValues = _, sort = null, pie) : sortValues;\n };\n\n pie.sort = function(_) {\n return arguments.length ? (sort = _, sortValues = null, pie) : sort;\n };\n\n pie.startAngle = function(_) {\n return arguments.length ? (startAngle = typeof _ === \"function\" ? _ : constant(+_), pie) : startAngle;\n };\n\n pie.endAngle = function(_) {\n return arguments.length ? (endAngle = typeof _ === \"function\" ? _ : constant(+_), pie) : endAngle;\n };\n\n pie.padAngle = function(_) {\n return arguments.length ? (padAngle = typeof _ === \"function\" ? _ : constant(+_), pie) : padAngle;\n };\n\n return pie;\n}\n", "export function point(that, x, y) {\n that._context.bezierCurveTo(\n (2 * that._x0 + that._x1) / 3,\n (2 * that._y0 + that._y1) / 3,\n (that._x0 + 2 * that._x1) / 3,\n (that._y0 + 2 * that._y1) / 3,\n (that._x0 + 4 * that._x1 + x) / 6,\n (that._y0 + 4 * that._y1 + y) / 6\n );\n}\n\nexport function Basis(context) {\n this._context = context;\n}\n\nBasis.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 =\n this._y0 = this._y1 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 3: point(this, this._x1, this._y1); // falls through\n case 2: this._context.lineTo(this._x1, this._y1); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; this._context.lineTo((5 * this._x0 + this._x1) / 6, (5 * this._y0 + this._y1) / 6); // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n }\n};\n\nexport default function(context) {\n return new Basis(context);\n}\n", "import pointRadial from \"../pointRadial.js\";\n\nclass Bump {\n constructor(context, x) {\n this._context = context;\n this._x = x;\n }\n areaStart() {\n this._line = 0;\n }\n areaEnd() {\n this._line = NaN;\n }\n lineStart() {\n this._point = 0;\n }\n lineEnd() {\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n }\n point(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: {\n this._point = 1;\n if (this._line) this._context.lineTo(x, y);\n else this._context.moveTo(x, y);\n break;\n }\n case 1: this._point = 2; // falls through\n default: {\n if (this._x) this._context.bezierCurveTo(this._x0 = (this._x0 + x) / 2, this._y0, this._x0, y, x, y);\n else this._context.bezierCurveTo(this._x0, this._y0 = (this._y0 + y) / 2, x, this._y0, x, y);\n break;\n }\n }\n this._x0 = x, this._y0 = y;\n }\n}\n\nclass BumpRadial {\n constructor(context) {\n this._context = context;\n }\n lineStart() {\n this._point = 0;\n }\n lineEnd() {}\n point(x, y) {\n x = +x, y = +y;\n if (this._point === 0) {\n this._point = 1;\n } else {\n const p0 = pointRadial(this._x0, this._y0);\n const p1 = pointRadial(this._x0, this._y0 = (this._y0 + y) / 2);\n const p2 = pointRadial(x, this._y0);\n const p3 = pointRadial(x, y);\n this._context.moveTo(...p0);\n this._context.bezierCurveTo(...p1, ...p2, ...p3);\n }\n this._x0 = x, this._y0 = y;\n }\n}\n\nexport function bumpX(context) {\n return new Bump(context, true);\n}\n\nexport function bumpY(context) {\n return new Bump(context, false);\n}\n\nexport function bumpRadial(context) {\n return new BumpRadial(context);\n}\n", "export default function() {}\n", "import noop from \"../noop.js\";\nimport {point} from \"./basis.js\";\n\nfunction BasisClosed(context) {\n this._context = context;\n}\n\nBasisClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._x0 = this._x1 = this._x2 = this._x3 = this._x4 =\n this._y0 = this._y1 = this._y2 = this._y3 = this._y4 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 1: {\n this._context.moveTo(this._x2, this._y2);\n this._context.closePath();\n break;\n }\n case 2: {\n this._context.moveTo((this._x2 + 2 * this._x3) / 3, (this._y2 + 2 * this._y3) / 3);\n this._context.lineTo((this._x3 + 2 * this._x2) / 3, (this._y3 + 2 * this._y2) / 3);\n this._context.closePath();\n break;\n }\n case 3: {\n this.point(this._x2, this._y2);\n this.point(this._x3, this._y3);\n this.point(this._x4, this._y4);\n break;\n }\n }\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._x2 = x, this._y2 = y; break;\n case 1: this._point = 2; this._x3 = x, this._y3 = y; break;\n case 2: this._point = 3; this._x4 = x, this._y4 = y; this._context.moveTo((this._x0 + 4 * this._x1 + x) / 6, (this._y0 + 4 * this._y1 + y) / 6); break;\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n }\n};\n\nexport default function(context) {\n return new BasisClosed(context);\n}\n", "import {point} from \"./basis.js\";\n\nfunction BasisOpen(context) {\n this._context = context;\n}\n\nBasisOpen.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 =\n this._y0 = this._y1 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 3)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; var x0 = (this._x0 + 4 * this._x1 + x) / 6, y0 = (this._y0 + 4 * this._y1 + y) / 6; this._line ? this._context.lineTo(x0, y0) : this._context.moveTo(x0, y0); break;\n case 3: this._point = 4; // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n }\n};\n\nexport default function(context) {\n return new BasisOpen(context);\n}\n", "import {Basis} from \"./basis.js\";\n\nfunction Bundle(context, beta) {\n this._basis = new Basis(context);\n this._beta = beta;\n}\n\nBundle.prototype = {\n lineStart: function() {\n this._x = [];\n this._y = [];\n this._basis.lineStart();\n },\n lineEnd: function() {\n var x = this._x,\n y = this._y,\n j = x.length - 1;\n\n if (j > 0) {\n var x0 = x[0],\n y0 = y[0],\n dx = x[j] - x0,\n dy = y[j] - y0,\n i = -1,\n t;\n\n while (++i <= j) {\n t = i / j;\n this._basis.point(\n this._beta * x[i] + (1 - this._beta) * (x0 + t * dx),\n this._beta * y[i] + (1 - this._beta) * (y0 + t * dy)\n );\n }\n }\n\n this._x = this._y = null;\n this._basis.lineEnd();\n },\n point: function(x, y) {\n this._x.push(+x);\n this._y.push(+y);\n }\n};\n\nexport default (function custom(beta) {\n\n function bundle(context) {\n return beta === 1 ? new Basis(context) : new Bundle(context, beta);\n }\n\n bundle.beta = function(beta) {\n return custom(+beta);\n };\n\n return bundle;\n})(0.85);\n", "export function point(that, x, y) {\n that._context.bezierCurveTo(\n that._x1 + that._k * (that._x2 - that._x0),\n that._y1 + that._k * (that._y2 - that._y0),\n that._x2 + that._k * (that._x1 - x),\n that._y2 + that._k * (that._y1 - y),\n that._x2,\n that._y2\n );\n}\n\nexport function Cardinal(context, tension) {\n this._context = context;\n this._k = (1 - tension) / 6;\n}\n\nCardinal.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 2: this._context.lineTo(this._x2, this._y2); break;\n case 3: point(this, this._x1, this._y1); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; this._x1 = x, this._y1 = y; break;\n case 2: this._point = 3; // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(tension) {\n\n function cardinal(context) {\n return new Cardinal(context, tension);\n }\n\n cardinal.tension = function(tension) {\n return custom(+tension);\n };\n\n return cardinal;\n})(0);\n", "import noop from \"../noop.js\";\nimport {point} from \"./cardinal.js\";\n\nexport function CardinalClosed(context, tension) {\n this._context = context;\n this._k = (1 - tension) / 6;\n}\n\nCardinalClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._x0 = this._x1 = this._x2 = this._x3 = this._x4 = this._x5 =\n this._y0 = this._y1 = this._y2 = this._y3 = this._y4 = this._y5 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 1: {\n this._context.moveTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 2: {\n this._context.lineTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 3: {\n this.point(this._x3, this._y3);\n this.point(this._x4, this._y4);\n this.point(this._x5, this._y5);\n break;\n }\n }\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._x3 = x, this._y3 = y; break;\n case 1: this._point = 2; this._context.moveTo(this._x4 = x, this._y4 = y); break;\n case 2: this._point = 3; this._x5 = x, this._y5 = y; break;\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(tension) {\n\n function cardinal(context) {\n return new CardinalClosed(context, tension);\n }\n\n cardinal.tension = function(tension) {\n return custom(+tension);\n };\n\n return cardinal;\n})(0);\n", "import {point} from \"./cardinal.js\";\n\nexport function CardinalOpen(context, tension) {\n this._context = context;\n this._k = (1 - tension) / 6;\n}\n\nCardinalOpen.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 3)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; this._line ? this._context.lineTo(this._x2, this._y2) : this._context.moveTo(this._x2, this._y2); break;\n case 3: this._point = 4; // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(tension) {\n\n function cardinal(context) {\n return new CardinalOpen(context, tension);\n }\n\n cardinal.tension = function(tension) {\n return custom(+tension);\n };\n\n return cardinal;\n})(0);\n", "import {epsilon} from \"../math.js\";\nimport {Cardinal} from \"./cardinal.js\";\n\nexport function point(that, x, y) {\n var x1 = that._x1,\n y1 = that._y1,\n x2 = that._x2,\n y2 = that._y2;\n\n if (that._l01_a > epsilon) {\n var a = 2 * that._l01_2a + 3 * that._l01_a * that._l12_a + that._l12_2a,\n n = 3 * that._l01_a * (that._l01_a + that._l12_a);\n x1 = (x1 * a - that._x0 * that._l12_2a + that._x2 * that._l01_2a) / n;\n y1 = (y1 * a - that._y0 * that._l12_2a + that._y2 * that._l01_2a) / n;\n }\n\n if (that._l23_a > epsilon) {\n var b = 2 * that._l23_2a + 3 * that._l23_a * that._l12_a + that._l12_2a,\n m = 3 * that._l23_a * (that._l23_a + that._l12_a);\n x2 = (x2 * b + that._x1 * that._l23_2a - x * that._l12_2a) / m;\n y2 = (y2 * b + that._y1 * that._l23_2a - y * that._l12_2a) / m;\n }\n\n that._context.bezierCurveTo(x1, y1, x2, y2, that._x2, that._y2);\n}\n\nfunction CatmullRom(context, alpha) {\n this._context = context;\n this._alpha = alpha;\n}\n\nCatmullRom.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._l01_a = this._l12_a = this._l23_a =\n this._l01_2a = this._l12_2a = this._l23_2a =\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 2: this._context.lineTo(this._x2, this._y2); break;\n case 3: this.point(this._x2, this._y2); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n\n if (this._point) {\n var x23 = this._x2 - x,\n y23 = this._y2 - y;\n this._l23_a = Math.sqrt(this._l23_2a = Math.pow(x23 * x23 + y23 * y23, this._alpha));\n }\n\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; // falls through\n default: point(this, x, y); break;\n }\n\n this._l01_a = this._l12_a, this._l12_a = this._l23_a;\n this._l01_2a = this._l12_2a, this._l12_2a = this._l23_2a;\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(alpha) {\n\n function catmullRom(context) {\n return alpha ? new CatmullRom(context, alpha) : new Cardinal(context, 0);\n }\n\n catmullRom.alpha = function(alpha) {\n return custom(+alpha);\n };\n\n return catmullRom;\n})(0.5);\n", "import {CardinalClosed} from \"./cardinalClosed.js\";\nimport noop from \"../noop.js\";\nimport {point} from \"./catmullRom.js\";\n\nfunction CatmullRomClosed(context, alpha) {\n this._context = context;\n this._alpha = alpha;\n}\n\nCatmullRomClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._x0 = this._x1 = this._x2 = this._x3 = this._x4 = this._x5 =\n this._y0 = this._y1 = this._y2 = this._y3 = this._y4 = this._y5 = NaN;\n this._l01_a = this._l12_a = this._l23_a =\n this._l01_2a = this._l12_2a = this._l23_2a =\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 1: {\n this._context.moveTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 2: {\n this._context.lineTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 3: {\n this.point(this._x3, this._y3);\n this.point(this._x4, this._y4);\n this.point(this._x5, this._y5);\n break;\n }\n }\n },\n point: function(x, y) {\n x = +x, y = +y;\n\n if (this._point) {\n var x23 = this._x2 - x,\n y23 = this._y2 - y;\n this._l23_a = Math.sqrt(this._l23_2a = Math.pow(x23 * x23 + y23 * y23, this._alpha));\n }\n\n switch (this._point) {\n case 0: this._point = 1; this._x3 = x, this._y3 = y; break;\n case 1: this._point = 2; this._context.moveTo(this._x4 = x, this._y4 = y); break;\n case 2: this._point = 3; this._x5 = x, this._y5 = y; break;\n default: point(this, x, y); break;\n }\n\n this._l01_a = this._l12_a, this._l12_a = this._l23_a;\n this._l01_2a = this._l12_2a, this._l12_2a = this._l23_2a;\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(alpha) {\n\n function catmullRom(context) {\n return alpha ? new CatmullRomClosed(context, alpha) : new CardinalClosed(context, 0);\n }\n\n catmullRom.alpha = function(alpha) {\n return custom(+alpha);\n };\n\n return catmullRom;\n})(0.5);\n", "import {CardinalOpen} from \"./cardinalOpen.js\";\nimport {point} from \"./catmullRom.js\";\n\nfunction CatmullRomOpen(context, alpha) {\n this._context = context;\n this._alpha = alpha;\n}\n\nCatmullRomOpen.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._l01_a = this._l12_a = this._l23_a =\n this._l01_2a = this._l12_2a = this._l23_2a =\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 3)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n\n if (this._point) {\n var x23 = this._x2 - x,\n y23 = this._y2 - y;\n this._l23_a = Math.sqrt(this._l23_2a = Math.pow(x23 * x23 + y23 * y23, this._alpha));\n }\n\n switch (this._point) {\n case 0: this._point = 1; break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; this._line ? this._context.lineTo(this._x2, this._y2) : this._context.moveTo(this._x2, this._y2); break;\n case 3: this._point = 4; // falls through\n default: point(this, x, y); break;\n }\n\n this._l01_a = this._l12_a, this._l12_a = this._l23_a;\n this._l01_2a = this._l12_2a, this._l12_2a = this._l23_2a;\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(alpha) {\n\n function catmullRom(context) {\n return alpha ? new CatmullRomOpen(context, alpha) : new CardinalOpen(context, 0);\n }\n\n catmullRom.alpha = function(alpha) {\n return custom(+alpha);\n };\n\n return catmullRom;\n})(0.5);\n", "import noop from \"../noop.js\";\n\nfunction LinearClosed(context) {\n this._context = context;\n}\n\nLinearClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._point = 0;\n },\n lineEnd: function() {\n if (this._point) this._context.closePath();\n },\n point: function(x, y) {\n x = +x, y = +y;\n if (this._point) this._context.lineTo(x, y);\n else this._point = 1, this._context.moveTo(x, y);\n }\n};\n\nexport default function(context) {\n return new LinearClosed(context);\n}\n", "function sign(x) {\n return x < 0 ? -1 : 1;\n}\n\n// Calculate the slopes of the tangents (Hermite-type interpolation) based on\n// the following paper: Steffen, M. 1990. A Simple Method for Monotonic\n// Interpolation in One Dimension. Astronomy and Astrophysics, Vol. 239, NO.\n// NOV(II), P. 443, 1990.\nfunction slope3(that, x2, y2) {\n var h0 = that._x1 - that._x0,\n h1 = x2 - that._x1,\n s0 = (that._y1 - that._y0) / (h0 || h1 < 0 && -0),\n s1 = (y2 - that._y1) / (h1 || h0 < 0 && -0),\n p = (s0 * h1 + s1 * h0) / (h0 + h1);\n return (sign(s0) + sign(s1)) * Math.min(Math.abs(s0), Math.abs(s1), 0.5 * Math.abs(p)) || 0;\n}\n\n// Calculate a one-sided slope.\nfunction slope2(that, t) {\n var h = that._x1 - that._x0;\n return h ? (3 * (that._y1 - that._y0) / h - t) / 2 : t;\n}\n\n// According to https://en.wikipedia.org/wiki/Cubic_Hermite_spline#Representations\n// \"you can express cubic Hermite interpolation in terms of cubic B\u00E9zier curves\n// with respect to the four values p0, p0 + m0 / 3, p1 - m1 / 3, p1\".\nfunction point(that, t0, t1) {\n var x0 = that._x0,\n y0 = that._y0,\n x1 = that._x1,\n y1 = that._y1,\n dx = (x1 - x0) / 3;\n that._context.bezierCurveTo(x0 + dx, y0 + dx * t0, x1 - dx, y1 - dx * t1, x1, y1);\n}\n\nfunction MonotoneX(context) {\n this._context = context;\n}\n\nMonotoneX.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 =\n this._y0 = this._y1 =\n this._t0 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 2: this._context.lineTo(this._x1, this._y1); break;\n case 3: point(this, this._t0, slope2(this, this._t0)); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n var t1 = NaN;\n\n x = +x, y = +y;\n if (x === this._x1 && y === this._y1) return; // Ignore coincident points.\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; point(this, slope2(this, t1 = slope3(this, x, y)), t1); break;\n default: point(this, this._t0, t1 = slope3(this, x, y)); break;\n }\n\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n this._t0 = t1;\n }\n}\n\nfunction MonotoneY(context) {\n this._context = new ReflectContext(context);\n}\n\n(MonotoneY.prototype = Object.create(MonotoneX.prototype)).point = function(x, y) {\n MonotoneX.prototype.point.call(this, y, x);\n};\n\nfunction ReflectContext(context) {\n this._context = context;\n}\n\nReflectContext.prototype = {\n moveTo: function(x, y) { this._context.moveTo(y, x); },\n closePath: function() { this._context.closePath(); },\n lineTo: function(x, y) { this._context.lineTo(y, x); },\n bezierCurveTo: function(x1, y1, x2, y2, x, y) { this._context.bezierCurveTo(y1, x1, y2, x2, y, x); }\n};\n\nexport function monotoneX(context) {\n return new MonotoneX(context);\n}\n\nexport function monotoneY(context) {\n return new MonotoneY(context);\n}\n", "function Natural(context) {\n this._context = context;\n}\n\nNatural.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x = [];\n this._y = [];\n },\n lineEnd: function() {\n var x = this._x,\n y = this._y,\n n = x.length;\n\n if (n) {\n this._line ? this._context.lineTo(x[0], y[0]) : this._context.moveTo(x[0], y[0]);\n if (n === 2) {\n this._context.lineTo(x[1], y[1]);\n } else {\n var px = controlPoints(x),\n py = controlPoints(y);\n for (var i0 = 0, i1 = 1; i1 < n; ++i0, ++i1) {\n this._context.bezierCurveTo(px[0][i0], py[0][i0], px[1][i0], py[1][i0], x[i1], y[i1]);\n }\n }\n }\n\n if (this._line || (this._line !== 0 && n === 1)) this._context.closePath();\n this._line = 1 - this._line;\n this._x = this._y = null;\n },\n point: function(x, y) {\n this._x.push(+x);\n this._y.push(+y);\n }\n};\n\n// See https://www.particleincell.com/2012/bezier-splines/ for derivation.\nfunction controlPoints(x) {\n var i,\n n = x.length - 1,\n m,\n a = new Array(n),\n b = new Array(n),\n r = new Array(n);\n a[0] = 0, b[0] = 2, r[0] = x[0] + 2 * x[1];\n for (i = 1; i < n - 1; ++i) a[i] = 1, b[i] = 4, r[i] = 4 * x[i] + 2 * x[i + 1];\n a[n - 1] = 2, b[n - 1] = 7, r[n - 1] = 8 * x[n - 1] + x[n];\n for (i = 1; i < n; ++i) m = a[i] / b[i - 1], b[i] -= m, r[i] -= m * r[i - 1];\n a[n - 1] = r[n - 1] / b[n - 1];\n for (i = n - 2; i >= 0; --i) a[i] = (r[i] - a[i + 1]) / b[i];\n b[n - 1] = (x[n] + a[n - 1]) / 2;\n for (i = 0; i < n - 1; ++i) b[i] = 2 * x[i + 1] - a[i + 1];\n return [a, b];\n}\n\nexport default function(context) {\n return new Natural(context);\n}\n", "function Step(context, t) {\n this._context = context;\n this._t = t;\n}\n\nStep.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x = this._y = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n if (0 < this._t && this._t < 1 && this._point === 2) this._context.lineTo(this._x, this._y);\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n if (this._line >= 0) this._t = 1 - this._t, this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; // falls through\n default: {\n if (this._t <= 0) {\n this._context.lineTo(this._x, y);\n this._context.lineTo(x, y);\n } else {\n var x1 = this._x * (1 - this._t) + x * this._t;\n this._context.lineTo(x1, this._y);\n this._context.lineTo(x1, y);\n }\n break;\n }\n }\n this._x = x, this._y = y;\n }\n};\n\nexport default function(context) {\n return new Step(context, 0.5);\n}\n\nexport function stepBefore(context) {\n return new Step(context, 0);\n}\n\nexport function stepAfter(context) {\n return new Step(context, 1);\n}\n", "var noop = {value: () => {}};\n\nfunction dispatch() {\n for (var i = 0, n = arguments.length, _ = {}, t; i < n; ++i) {\n if (!(t = arguments[i] + \"\") || (t in _) || /[\\s.]/.test(t)) throw new Error(\"illegal type: \" + t);\n _[t] = [];\n }\n return new Dispatch(_);\n}\n\nfunction Dispatch(_) {\n this._ = _;\n}\n\nfunction parseTypenames(typenames, types) {\n return typenames.trim().split(/^|\\s+/).map(function(t) {\n var name = \"\", i = t.indexOf(\".\");\n if (i >= 0) name = t.slice(i + 1), t = t.slice(0, i);\n if (t && !types.hasOwnProperty(t)) throw new Error(\"unknown type: \" + t);\n return {type: t, name: name};\n });\n}\n\nDispatch.prototype = dispatch.prototype = {\n constructor: Dispatch,\n on: function(typename, callback) {\n var _ = this._,\n T = parseTypenames(typename + \"\", _),\n t,\n i = -1,\n n = T.length;\n\n // If no callback was specified, return the callback of the given type and name.\n if (arguments.length < 2) {\n while (++i < n) if ((t = (typename = T[i]).type) && (t = get(_[t], typename.name))) return t;\n return;\n }\n\n // If a type was specified, set the callback for the given type and name.\n // Otherwise, if a null callback was specified, remove callbacks of the given name.\n if (callback != null && typeof callback !== \"function\") throw new Error(\"invalid callback: \" + callback);\n while (++i < n) {\n if (t = (typename = T[i]).type) _[t] = set(_[t], typename.name, callback);\n else if (callback == null) for (t in _) _[t] = set(_[t], typename.name, null);\n }\n\n return this;\n },\n copy: function() {\n var copy = {}, _ = this._;\n for (var t in _) copy[t] = _[t].slice();\n return new Dispatch(copy);\n },\n call: function(type, that) {\n if ((n = arguments.length - 2) > 0) for (var args = new Array(n), i = 0, n, t; i < n; ++i) args[i] = arguments[i + 2];\n if (!this._.hasOwnProperty(type)) throw new Error(\"unknown type: \" + type);\n for (t = this._[type], i = 0, n = t.length; i < n; ++i) t[i].value.apply(that, args);\n },\n apply: function(type, that, args) {\n if (!this._.hasOwnProperty(type)) throw new Error(\"unknown type: \" + type);\n for (var t = this._[type], i = 0, n = t.length; i < n; ++i) t[i].value.apply(that, args);\n }\n};\n\nfunction get(type, name) {\n for (var i = 0, n = type.length, c; i < n; ++i) {\n if ((c = type[i]).name === name) {\n return c.value;\n }\n }\n}\n\nfunction set(type, name, callback) {\n for (var i = 0, n = type.length; i < n; ++i) {\n if (type[i].name === name) {\n type[i] = noop, type = type.slice(0, i).concat(type.slice(i + 1));\n break;\n }\n }\n if (callback != null) type.push({name: name, value: callback});\n return type;\n}\n\nexport default dispatch;\n", "var frame = 0, // is an animation frame pending?\n timeout = 0, // is a timeout pending?\n interval = 0, // are any timers active?\n pokeDelay = 1000, // how frequently we check for clock skew\n taskHead,\n taskTail,\n clockLast = 0,\n clockNow = 0,\n clockSkew = 0,\n clock = typeof performance === \"object\" && performance.now ? performance : Date,\n setFrame = typeof window === \"object\" && window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) : function(f) { setTimeout(f, 17); };\n\nexport function now() {\n return clockNow || (setFrame(clearNow), clockNow = clock.now() + clockSkew);\n}\n\nfunction clearNow() {\n clockNow = 0;\n}\n\nexport function Timer() {\n this._call =\n this._time =\n this._next = null;\n}\n\nTimer.prototype = timer.prototype = {\n constructor: Timer,\n restart: function(callback, delay, time) {\n if (typeof callback !== \"function\") throw new TypeError(\"callback is not a function\");\n time = (time == null ? now() : +time) + (delay == null ? 0 : +delay);\n if (!this._next && taskTail !== this) {\n if (taskTail) taskTail._next = this;\n else taskHead = this;\n taskTail = this;\n }\n this._call = callback;\n this._time = time;\n sleep();\n },\n stop: function() {\n if (this._call) {\n this._call = null;\n this._time = Infinity;\n sleep();\n }\n }\n};\n\nexport function timer(callback, delay, time) {\n var t = new Timer;\n t.restart(callback, delay, time);\n return t;\n}\n\nexport function timerFlush() {\n now(); // Get the current time, if not already set.\n ++frame; // Pretend we\u2019ve set an alarm, if we haven\u2019t already.\n var t = taskHead, e;\n while (t) {\n if ((e = clockNow - t._time) >= 0) t._call.call(undefined, e);\n t = t._next;\n }\n --frame;\n}\n\nfunction wake() {\n clockNow = (clockLast = clock.now()) + clockSkew;\n frame = timeout = 0;\n try {\n timerFlush();\n } finally {\n frame = 0;\n nap();\n clockNow = 0;\n }\n}\n\nfunction poke() {\n var now = clock.now(), delay = now - clockLast;\n if (delay > pokeDelay) clockSkew -= delay, clockLast = now;\n}\n\nfunction nap() {\n var t0, t1 = taskHead, t2, time = Infinity;\n while (t1) {\n if (t1._call) {\n if (time > t1._time) time = t1._time;\n t0 = t1, t1 = t1._next;\n } else {\n t2 = t1._next, t1._next = null;\n t1 = t0 ? t0._next = t2 : taskHead = t2;\n }\n }\n taskTail = t0;\n sleep(time);\n}\n\nfunction sleep(time) {\n if (frame) return; // Soonest alarm already set, or will be.\n if (timeout) timeout = clearTimeout(timeout);\n var delay = time - clockNow; // Strictly less than if we recomputed clockNow.\n if (delay > 24) {\n if (time < Infinity) timeout = setTimeout(wake, time - clock.now() - clockSkew);\n if (interval) interval = clearInterval(interval);\n } else {\n if (!interval) clockLast = clock.now(), interval = setInterval(poke, pokeDelay);\n frame = 1, setFrame(wake);\n }\n}\n", "import {Timer} from \"./timer.js\";\n\nexport default function(callback, delay, time) {\n var t = new Timer;\n delay = delay == null ? 0 : +delay;\n t.restart(elapsed => {\n t.stop();\n callback(elapsed + delay);\n }, delay, time);\n return t;\n}\n", "import {dispatch} from \"d3-dispatch\";\nimport {timer, timeout} from \"d3-timer\";\n\nvar emptyOn = dispatch(\"start\", \"end\", \"cancel\", \"interrupt\");\nvar emptyTween = [];\n\nexport var CREATED = 0;\nexport var SCHEDULED = 1;\nexport var STARTING = 2;\nexport var STARTED = 3;\nexport var RUNNING = 4;\nexport var ENDING = 5;\nexport var ENDED = 6;\n\nexport default function(node, name, id, index, group, timing) {\n var schedules = node.__transition;\n if (!schedules) node.__transition = {};\n else if (id in schedules) return;\n create(node, id, {\n name: name,\n index: index, // For context during callback.\n group: group, // For context during callback.\n on: emptyOn,\n tween: emptyTween,\n time: timing.time,\n delay: timing.delay,\n duration: timing.duration,\n ease: timing.ease,\n timer: null,\n state: CREATED\n });\n}\n\nexport function init(node, id) {\n var schedule = get(node, id);\n if (schedule.state > CREATED) throw new Error(\"too late; already scheduled\");\n return schedule;\n}\n\nexport function set(node, id) {\n var schedule = get(node, id);\n if (schedule.state > STARTED) throw new Error(\"too late; already running\");\n return schedule;\n}\n\nexport function get(node, id) {\n var schedule = node.__transition;\n if (!schedule || !(schedule = schedule[id])) throw new Error(\"transition not found\");\n return schedule;\n}\n\nfunction create(node, id, self) {\n var schedules = node.__transition,\n tween;\n\n // Initialize the self timer when the transition is created.\n // Note the actual delay is not known until the first callback!\n schedules[id] = self;\n self.timer = timer(schedule, 0, self.time);\n\n function schedule(elapsed) {\n self.state = SCHEDULED;\n self.timer.restart(start, self.delay, self.time);\n\n // If the elapsed delay is less than our first sleep, start immediately.\n if (self.delay <= elapsed) start(elapsed - self.delay);\n }\n\n function start(elapsed) {\n var i, j, n, o;\n\n // If the state is not SCHEDULED, then we previously errored on start.\n if (self.state !== SCHEDULED) return stop();\n\n for (i in schedules) {\n o = schedules[i];\n if (o.name !== self.name) continue;\n\n // While this element already has a starting transition during this frame,\n // defer starting an interrupting transition until that transition has a\n // chance to tick (and possibly end); see d3/d3-transition#54!\n if (o.state === STARTED) return timeout(start);\n\n // Interrupt the active transition, if any.\n if (o.state === RUNNING) {\n o.state = ENDED;\n o.timer.stop();\n o.on.call(\"interrupt\", node, node.__data__, o.index, o.group);\n delete schedules[i];\n }\n\n // Cancel any pre-empted transitions.\n else if (+i < id) {\n o.state = ENDED;\n o.timer.stop();\n o.on.call(\"cancel\", node, node.__data__, o.index, o.group);\n delete schedules[i];\n }\n }\n\n // Defer the first tick to end of the current frame; see d3/d3#1576.\n // Note the transition may be canceled after start and before the first tick!\n // Note this must be scheduled before the start event; see d3/d3-transition#16!\n // Assuming this is successful, subsequent callbacks go straight to tick.\n timeout(function() {\n if (self.state === STARTED) {\n self.state = RUNNING;\n self.timer.restart(tick, self.delay, self.time);\n tick(elapsed);\n }\n });\n\n // Dispatch the start event.\n // Note this must be done before the tween are initialized.\n self.state = STARTING;\n self.on.call(\"start\", node, node.__data__, self.index, self.group);\n if (self.state !== STARTING) return; // interrupted\n self.state = STARTED;\n\n // Initialize the tween, deleting null tween.\n tween = new Array(n = self.tween.length);\n for (i = 0, j = -1; i < n; ++i) {\n if (o = self.tween[i].value.call(node, node.__data__, self.index, self.group)) {\n tween[++j] = o;\n }\n }\n tween.length = j + 1;\n }\n\n function tick(elapsed) {\n var t = elapsed < self.duration ? self.ease.call(null, elapsed / self.duration) : (self.timer.restart(stop), self.state = ENDING, 1),\n i = -1,\n n = tween.length;\n\n while (++i < n) {\n tween[i].call(node, t);\n }\n\n // Dispatch the end event.\n if (self.state === ENDING) {\n self.on.call(\"end\", node, node.__data__, self.index, self.group);\n stop();\n }\n }\n\n function stop() {\n self.state = ENDED;\n self.timer.stop();\n delete schedules[id];\n for (var i in schedules) return; // eslint-disable-line no-unused-vars\n delete node.__transition;\n }\n}\n", "import {STARTING, ENDING, ENDED} from \"./transition/schedule.js\";\n\nexport default function(node, name) {\n var schedules = node.__transition,\n schedule,\n active,\n empty = true,\n i;\n\n if (!schedules) return;\n\n name = name == null ? null : name + \"\";\n\n for (i in schedules) {\n if ((schedule = schedules[i]).name !== name) { empty = false; continue; }\n active = schedule.state > STARTING && schedule.state < ENDING;\n schedule.state = ENDED;\n schedule.timer.stop();\n schedule.on.call(active ? \"interrupt\" : \"cancel\", node, node.__data__, schedule.index, schedule.group);\n delete schedules[i];\n }\n\n if (empty) delete node.__transition;\n}\n", "import interrupt from \"../interrupt.js\";\n\nexport default function(name) {\n return this.each(function() {\n interrupt(this, name);\n });\n}\n", "import {get, set} from \"./schedule.js\";\n\nfunction tweenRemove(id, name) {\n var tween0, tween1;\n return function() {\n var schedule = set(this, id),\n tween = schedule.tween;\n\n // If this node shared tween with the previous node,\n // just assign the updated shared tween and we\u2019re done!\n // Otherwise, copy-on-write.\n if (tween !== tween0) {\n tween1 = tween0 = tween;\n for (var i = 0, n = tween1.length; i < n; ++i) {\n if (tween1[i].name === name) {\n tween1 = tween1.slice();\n tween1.splice(i, 1);\n break;\n }\n }\n }\n\n schedule.tween = tween1;\n };\n}\n\nfunction tweenFunction(id, name, value) {\n var tween0, tween1;\n if (typeof value !== \"function\") throw new Error;\n return function() {\n var schedule = set(this, id),\n tween = schedule.tween;\n\n // If this node shared tween with the previous node,\n // just assign the updated shared tween and we\u2019re done!\n // Otherwise, copy-on-write.\n if (tween !== tween0) {\n tween1 = (tween0 = tween).slice();\n for (var t = {name: name, value: value}, i = 0, n = tween1.length; i < n; ++i) {\n if (tween1[i].name === name) {\n tween1[i] = t;\n break;\n }\n }\n if (i === n) tween1.push(t);\n }\n\n schedule.tween = tween1;\n };\n}\n\nexport default function(name, value) {\n var id = this._id;\n\n name += \"\";\n\n if (arguments.length < 2) {\n var tween = get(this.node(), id).tween;\n for (var i = 0, n = tween.length, t; i < n; ++i) {\n if ((t = tween[i]).name === name) {\n return t.value;\n }\n }\n return null;\n }\n\n return this.each((value == null ? tweenRemove : tweenFunction)(id, name, value));\n}\n\nexport function tweenValue(transition, name, value) {\n var id = transition._id;\n\n transition.each(function() {\n var schedule = set(this, id);\n (schedule.value || (schedule.value = {}))[name] = value.apply(this, arguments);\n });\n\n return function(node) {\n return get(node, id).value[name];\n };\n}\n", "import {color} from \"d3-color\";\nimport {interpolateNumber, interpolateRgb, interpolateString} from \"d3-interpolate\";\n\nexport default function(a, b) {\n var c;\n return (typeof b === \"number\" ? interpolateNumber\n : b instanceof color ? interpolateRgb\n : (c = color(b)) ? (b = c, interpolateRgb)\n : interpolateString)(a, b);\n}\n", "import {interpolateTransformSvg as interpolateTransform} from \"d3-interpolate\";\nimport {namespace} from \"d3-selection\";\nimport {tweenValue} from \"./tween.js\";\nimport interpolate from \"./interpolate.js\";\n\nfunction attrRemove(name) {\n return function() {\n this.removeAttribute(name);\n };\n}\n\nfunction attrRemoveNS(fullname) {\n return function() {\n this.removeAttributeNS(fullname.space, fullname.local);\n };\n}\n\nfunction attrConstant(name, interpolate, value1) {\n var string00,\n string1 = value1 + \"\",\n interpolate0;\n return function() {\n var string0 = this.getAttribute(name);\n return string0 === string1 ? null\n : string0 === string00 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, value1);\n };\n}\n\nfunction attrConstantNS(fullname, interpolate, value1) {\n var string00,\n string1 = value1 + \"\",\n interpolate0;\n return function() {\n var string0 = this.getAttributeNS(fullname.space, fullname.local);\n return string0 === string1 ? null\n : string0 === string00 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, value1);\n };\n}\n\nfunction attrFunction(name, interpolate, value) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0, value1 = value(this), string1;\n if (value1 == null) return void this.removeAttribute(name);\n string0 = this.getAttribute(name);\n string1 = value1 + \"\";\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));\n };\n}\n\nfunction attrFunctionNS(fullname, interpolate, value) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0, value1 = value(this), string1;\n if (value1 == null) return void this.removeAttributeNS(fullname.space, fullname.local);\n string0 = this.getAttributeNS(fullname.space, fullname.local);\n string1 = value1 + \"\";\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));\n };\n}\n\nexport default function(name, value) {\n var fullname = namespace(name), i = fullname === \"transform\" ? interpolateTransform : interpolate;\n return this.attrTween(name, typeof value === \"function\"\n ? (fullname.local ? attrFunctionNS : attrFunction)(fullname, i, tweenValue(this, \"attr.\" + name, value))\n : value == null ? (fullname.local ? attrRemoveNS : attrRemove)(fullname)\n : (fullname.local ? attrConstantNS : attrConstant)(fullname, i, value));\n}\n", "import {namespace} from \"d3-selection\";\n\nfunction attrInterpolate(name, i) {\n return function(t) {\n this.setAttribute(name, i.call(this, t));\n };\n}\n\nfunction attrInterpolateNS(fullname, i) {\n return function(t) {\n this.setAttributeNS(fullname.space, fullname.local, i.call(this, t));\n };\n}\n\nfunction attrTweenNS(fullname, value) {\n var t0, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t0 = (i0 = i) && attrInterpolateNS(fullname, i);\n return t0;\n }\n tween._value = value;\n return tween;\n}\n\nfunction attrTween(name, value) {\n var t0, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t0 = (i0 = i) && attrInterpolate(name, i);\n return t0;\n }\n tween._value = value;\n return tween;\n}\n\nexport default function(name, value) {\n var key = \"attr.\" + name;\n if (arguments.length < 2) return (key = this.tween(key)) && key._value;\n if (value == null) return this.tween(key, null);\n if (typeof value !== \"function\") throw new Error;\n var fullname = namespace(name);\n return this.tween(key, (fullname.local ? attrTweenNS : attrTween)(fullname, value));\n}\n", "import {get, init} from \"./schedule.js\";\n\nfunction delayFunction(id, value) {\n return function() {\n init(this, id).delay = +value.apply(this, arguments);\n };\n}\n\nfunction delayConstant(id, value) {\n return value = +value, function() {\n init(this, id).delay = value;\n };\n}\n\nexport default function(value) {\n var id = this._id;\n\n return arguments.length\n ? this.each((typeof value === \"function\"\n ? delayFunction\n : delayConstant)(id, value))\n : get(this.node(), id).delay;\n}\n", "import {get, set} from \"./schedule.js\";\n\nfunction durationFunction(id, value) {\n return function() {\n set(this, id).duration = +value.apply(this, arguments);\n };\n}\n\nfunction durationConstant(id, value) {\n return value = +value, function() {\n set(this, id).duration = value;\n };\n}\n\nexport default function(value) {\n var id = this._id;\n\n return arguments.length\n ? this.each((typeof value === \"function\"\n ? durationFunction\n : durationConstant)(id, value))\n : get(this.node(), id).duration;\n}\n", "import {get, set} from \"./schedule.js\";\n\nfunction easeConstant(id, value) {\n if (typeof value !== \"function\") throw new Error;\n return function() {\n set(this, id).ease = value;\n };\n}\n\nexport default function(value) {\n var id = this._id;\n\n return arguments.length\n ? this.each(easeConstant(id, value))\n : get(this.node(), id).ease;\n}\n", "import {set} from \"./schedule.js\";\n\nfunction easeVarying(id, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (typeof v !== \"function\") throw new Error;\n set(this, id).ease = v;\n };\n}\n\nexport default function(value) {\n if (typeof value !== \"function\") throw new Error;\n return this.each(easeVarying(this._id, value));\n}\n", "import {matcher} from \"d3-selection\";\nimport {Transition} from \"./index.js\";\n\nexport default function(match) {\n if (typeof match !== \"function\") match = matcher(match);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = [], node, i = 0; i < n; ++i) {\n if ((node = group[i]) && match.call(node, node.__data__, i, group)) {\n subgroup.push(node);\n }\n }\n }\n\n return new Transition(subgroups, this._parents, this._name, this._id);\n}\n", "import {Transition} from \"./index.js\";\n\nexport default function(transition) {\n if (transition._id !== this._id) throw new Error;\n\n for (var groups0 = this._groups, groups1 = transition._groups, m0 = groups0.length, m1 = groups1.length, m = Math.min(m0, m1), merges = new Array(m0), j = 0; j < m; ++j) {\n for (var group0 = groups0[j], group1 = groups1[j], n = group0.length, merge = merges[j] = new Array(n), node, i = 0; i < n; ++i) {\n if (node = group0[i] || group1[i]) {\n merge[i] = node;\n }\n }\n }\n\n for (; j < m0; ++j) {\n merges[j] = groups0[j];\n }\n\n return new Transition(merges, this._parents, this._name, this._id);\n}\n", "import {get, set, init} from \"./schedule.js\";\n\nfunction start(name) {\n return (name + \"\").trim().split(/^|\\s+/).every(function(t) {\n var i = t.indexOf(\".\");\n if (i >= 0) t = t.slice(0, i);\n return !t || t === \"start\";\n });\n}\n\nfunction onFunction(id, name, listener) {\n var on0, on1, sit = start(name) ? init : set;\n return function() {\n var schedule = sit(this, id),\n on = schedule.on;\n\n // If this node shared a dispatch with the previous node,\n // just assign the updated shared dispatch and we\u2019re done!\n // Otherwise, copy-on-write.\n if (on !== on0) (on1 = (on0 = on).copy()).on(name, listener);\n\n schedule.on = on1;\n };\n}\n\nexport default function(name, listener) {\n var id = this._id;\n\n return arguments.length < 2\n ? get(this.node(), id).on.on(name)\n : this.each(onFunction(id, name, listener));\n}\n", "function removeFunction(id) {\n return function() {\n var parent = this.parentNode;\n for (var i in this.__transition) if (+i !== id) return;\n if (parent) parent.removeChild(this);\n };\n}\n\nexport default function() {\n return this.on(\"end.remove\", removeFunction(this._id));\n}\n", "import {selector} from \"d3-selection\";\nimport {Transition} from \"./index.js\";\nimport schedule, {get} from \"./schedule.js\";\n\nexport default function(select) {\n var name = this._name,\n id = this._id;\n\n if (typeof select !== \"function\") select = selector(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = new Array(n), node, subnode, i = 0; i < n; ++i) {\n if ((node = group[i]) && (subnode = select.call(node, node.__data__, i, group))) {\n if (\"__data__\" in node) subnode.__data__ = node.__data__;\n subgroup[i] = subnode;\n schedule(subgroup[i], name, id, i, subgroup, get(node, id));\n }\n }\n }\n\n return new Transition(subgroups, this._parents, name, id);\n}\n", "import {selectorAll} from \"d3-selection\";\nimport {Transition} from \"./index.js\";\nimport schedule, {get} from \"./schedule.js\";\n\nexport default function(select) {\n var name = this._name,\n id = this._id;\n\n if (typeof select !== \"function\") select = selectorAll(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = [], parents = [], j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n for (var children = select.call(node, node.__data__, i, group), child, inherit = get(node, id), k = 0, l = children.length; k < l; ++k) {\n if (child = children[k]) {\n schedule(child, name, id, k, children, inherit);\n }\n }\n subgroups.push(children);\n parents.push(node);\n }\n }\n }\n\n return new Transition(subgroups, parents, name, id);\n}\n", "import {selection} from \"d3-selection\";\n\nvar Selection = selection.prototype.constructor;\n\nexport default function() {\n return new Selection(this._groups, this._parents);\n}\n", "import {interpolateTransformCss as interpolateTransform} from \"d3-interpolate\";\nimport {style} from \"d3-selection\";\nimport {set} from \"./schedule.js\";\nimport {tweenValue} from \"./tween.js\";\nimport interpolate from \"./interpolate.js\";\n\nfunction styleNull(name, interpolate) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0 = style(this, name),\n string1 = (this.style.removeProperty(name), style(this, name));\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, string10 = string1);\n };\n}\n\nfunction styleRemove(name) {\n return function() {\n this.style.removeProperty(name);\n };\n}\n\nfunction styleConstant(name, interpolate, value1) {\n var string00,\n string1 = value1 + \"\",\n interpolate0;\n return function() {\n var string0 = style(this, name);\n return string0 === string1 ? null\n : string0 === string00 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, value1);\n };\n}\n\nfunction styleFunction(name, interpolate, value) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0 = style(this, name),\n value1 = value(this),\n string1 = value1 + \"\";\n if (value1 == null) string1 = value1 = (this.style.removeProperty(name), style(this, name));\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));\n };\n}\n\nfunction styleMaybeRemove(id, name) {\n var on0, on1, listener0, key = \"style.\" + name, event = \"end.\" + key, remove;\n return function() {\n var schedule = set(this, id),\n on = schedule.on,\n listener = schedule.value[key] == null ? remove || (remove = styleRemove(name)) : undefined;\n\n // If this node shared a dispatch with the previous node,\n // just assign the updated shared dispatch and we\u2019re done!\n // Otherwise, copy-on-write.\n if (on !== on0 || listener0 !== listener) (on1 = (on0 = on).copy()).on(event, listener0 = listener);\n\n schedule.on = on1;\n };\n}\n\nexport default function(name, value, priority) {\n var i = (name += \"\") === \"transform\" ? interpolateTransform : interpolate;\n return value == null ? this\n .styleTween(name, styleNull(name, i))\n .on(\"end.style.\" + name, styleRemove(name))\n : typeof value === \"function\" ? this\n .styleTween(name, styleFunction(name, i, tweenValue(this, \"style.\" + name, value)))\n .each(styleMaybeRemove(this._id, name))\n : this\n .styleTween(name, styleConstant(name, i, value), priority)\n .on(\"end.style.\" + name, null);\n}\n", "function styleInterpolate(name, i, priority) {\n return function(t) {\n this.style.setProperty(name, i.call(this, t), priority);\n };\n}\n\nfunction styleTween(name, value, priority) {\n var t, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t = (i0 = i) && styleInterpolate(name, i, priority);\n return t;\n }\n tween._value = value;\n return tween;\n}\n\nexport default function(name, value, priority) {\n var key = \"style.\" + (name += \"\");\n if (arguments.length < 2) return (key = this.tween(key)) && key._value;\n if (value == null) return this.tween(key, null);\n if (typeof value !== \"function\") throw new Error;\n return this.tween(key, styleTween(name, value, priority == null ? \"\" : priority));\n}\n", "import {tweenValue} from \"./tween.js\";\n\nfunction textConstant(value) {\n return function() {\n this.textContent = value;\n };\n}\n\nfunction textFunction(value) {\n return function() {\n var value1 = value(this);\n this.textContent = value1 == null ? \"\" : value1;\n };\n}\n\nexport default function(value) {\n return this.tween(\"text\", typeof value === \"function\"\n ? textFunction(tweenValue(this, \"text\", value))\n : textConstant(value == null ? \"\" : value + \"\"));\n}\n", "function textInterpolate(i) {\n return function(t) {\n this.textContent = i.call(this, t);\n };\n}\n\nfunction textTween(value) {\n var t0, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t0 = (i0 = i) && textInterpolate(i);\n return t0;\n }\n tween._value = value;\n return tween;\n}\n\nexport default function(value) {\n var key = \"text\";\n if (arguments.length < 1) return (key = this.tween(key)) && key._value;\n if (value == null) return this.tween(key, null);\n if (typeof value !== \"function\") throw new Error;\n return this.tween(key, textTween(value));\n}\n", "import {Transition, newId} from \"./index.js\";\nimport schedule, {get} from \"./schedule.js\";\n\nexport default function() {\n var name = this._name,\n id0 = this._id,\n id1 = newId();\n\n for (var groups = this._groups, m = groups.length, j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n var inherit = get(node, id0);\n schedule(node, name, id1, i, group, {\n time: inherit.time + inherit.delay + inherit.duration,\n delay: 0,\n duration: inherit.duration,\n ease: inherit.ease\n });\n }\n }\n }\n\n return new Transition(groups, this._parents, name, id1);\n}\n", "import {set} from \"./schedule.js\";\n\nexport default function() {\n var on0, on1, that = this, id = that._id, size = that.size();\n return new Promise(function(resolve, reject) {\n var cancel = {value: reject},\n end = {value: function() { if (--size === 0) resolve(); }};\n\n that.each(function() {\n var schedule = set(this, id),\n on = schedule.on;\n\n // If this node shared a dispatch with the previous node,\n // just assign the updated shared dispatch and we\u2019re done!\n // Otherwise, copy-on-write.\n if (on !== on0) {\n on1 = (on0 = on).copy();\n on1._.cancel.push(cancel);\n on1._.interrupt.push(cancel);\n on1._.end.push(end);\n }\n\n schedule.on = on1;\n });\n\n // The selection was empty, resolve end immediately\n if (size === 0) resolve();\n });\n}\n", "import {selection} from \"d3-selection\";\nimport transition_attr from \"./attr.js\";\nimport transition_attrTween from \"./attrTween.js\";\nimport transition_delay from \"./delay.js\";\nimport transition_duration from \"./duration.js\";\nimport transition_ease from \"./ease.js\";\nimport transition_easeVarying from \"./easeVarying.js\";\nimport transition_filter from \"./filter.js\";\nimport transition_merge from \"./merge.js\";\nimport transition_on from \"./on.js\";\nimport transition_remove from \"./remove.js\";\nimport transition_select from \"./select.js\";\nimport transition_selectAll from \"./selectAll.js\";\nimport transition_selection from \"./selection.js\";\nimport transition_style from \"./style.js\";\nimport transition_styleTween from \"./styleTween.js\";\nimport transition_text from \"./text.js\";\nimport transition_textTween from \"./textTween.js\";\nimport transition_transition from \"./transition.js\";\nimport transition_tween from \"./tween.js\";\nimport transition_end from \"./end.js\";\n\nvar id = 0;\n\nexport function Transition(groups, parents, name, id) {\n this._groups = groups;\n this._parents = parents;\n this._name = name;\n this._id = id;\n}\n\nexport default function transition(name) {\n return selection().transition(name);\n}\n\nexport function newId() {\n return ++id;\n}\n\nvar selection_prototype = selection.prototype;\n\nTransition.prototype = transition.prototype = {\n constructor: Transition,\n select: transition_select,\n selectAll: transition_selectAll,\n selectChild: selection_prototype.selectChild,\n selectChildren: selection_prototype.selectChildren,\n filter: transition_filter,\n merge: transition_merge,\n selection: transition_selection,\n transition: transition_transition,\n call: selection_prototype.call,\n nodes: selection_prototype.nodes,\n node: selection_prototype.node,\n size: selection_prototype.size,\n empty: selection_prototype.empty,\n each: selection_prototype.each,\n on: transition_on,\n attr: transition_attr,\n attrTween: transition_attrTween,\n style: transition_style,\n styleTween: transition_styleTween,\n text: transition_text,\n textTween: transition_textTween,\n remove: transition_remove,\n tween: transition_tween,\n delay: transition_delay,\n duration: transition_duration,\n ease: transition_ease,\n easeVarying: transition_easeVarying,\n end: transition_end,\n [Symbol.iterator]: selection_prototype[Symbol.iterator]\n};\n", "export function cubicIn(t) {\n return t * t * t;\n}\n\nexport function cubicOut(t) {\n return --t * t * t + 1;\n}\n\nexport function cubicInOut(t) {\n return ((t *= 2) <= 1 ? t * t * t : (t -= 2) * t * t + 2) / 2;\n}\n", "import {Transition, newId} from \"../transition/index.js\";\nimport schedule from \"../transition/schedule.js\";\nimport {easeCubicInOut} from \"d3-ease\";\nimport {now} from \"d3-timer\";\n\nvar defaultTiming = {\n time: null, // Set on use.\n delay: 0,\n duration: 250,\n ease: easeCubicInOut\n};\n\nfunction inherit(node, id) {\n var timing;\n while (!(timing = node.__transition) || !(timing = timing[id])) {\n if (!(node = node.parentNode)) {\n throw new Error(`transition ${id} not found`);\n }\n }\n return timing;\n}\n\nexport default function(name) {\n var id,\n timing;\n\n if (name instanceof Transition) {\n id = name._id, name = name._name;\n } else {\n id = newId(), (timing = defaultTiming).time = now(), name = name == null ? null : name + \"\";\n }\n\n for (var groups = this._groups, m = groups.length, j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n schedule(node, name, id, i, group, timing || inherit(node, id));\n }\n }\n }\n\n return new Transition(groups, this._parents, name, id);\n}\n", "import {selection} from \"d3-selection\";\nimport selection_interrupt from \"./interrupt.js\";\nimport selection_transition from \"./transition.js\";\n\nselection.prototype.interrupt = selection_interrupt;\nselection.prototype.transition = selection_transition;\n", "import {dispatch} from \"d3-dispatch\";\nimport {dragDisable, dragEnable} from \"d3-drag\";\nimport {interpolate} from \"d3-interpolate\";\nimport {pointer, select} from \"d3-selection\";\nimport {interrupt} from \"d3-transition\";\nimport constant from \"./constant.js\";\nimport BrushEvent from \"./event.js\";\nimport noevent, {nopropagation} from \"./noevent.js\";\n\nvar MODE_DRAG = {name: \"drag\"},\n MODE_SPACE = {name: \"space\"},\n MODE_HANDLE = {name: \"handle\"},\n MODE_CENTER = {name: \"center\"};\n\nconst {abs, max, min} = Math;\n\nfunction number1(e) {\n return [+e[0], +e[1]];\n}\n\nfunction number2(e) {\n return [number1(e[0]), number1(e[1])];\n}\n\nvar X = {\n name: \"x\",\n handles: [\"w\", \"e\"].map(type),\n input: function(x, e) { return x == null ? null : [[+x[0], e[0][1]], [+x[1], e[1][1]]]; },\n output: function(xy) { return xy && [xy[0][0], xy[1][0]]; }\n};\n\nvar Y = {\n name: \"y\",\n handles: [\"n\", \"s\"].map(type),\n input: function(y, e) { return y == null ? null : [[e[0][0], +y[0]], [e[1][0], +y[1]]]; },\n output: function(xy) { return xy && [xy[0][1], xy[1][1]]; }\n};\n\nvar XY = {\n name: \"xy\",\n handles: [\"n\", \"w\", \"e\", \"s\", \"nw\", \"ne\", \"sw\", \"se\"].map(type),\n input: function(xy) { return xy == null ? null : number2(xy); },\n output: function(xy) { return xy; }\n};\n\nvar cursors = {\n overlay: \"crosshair\",\n selection: \"move\",\n n: \"ns-resize\",\n e: \"ew-resize\",\n s: \"ns-resize\",\n w: \"ew-resize\",\n nw: \"nwse-resize\",\n ne: \"nesw-resize\",\n se: \"nwse-resize\",\n sw: \"nesw-resize\"\n};\n\nvar flipX = {\n e: \"w\",\n w: \"e\",\n nw: \"ne\",\n ne: \"nw\",\n se: \"sw\",\n sw: \"se\"\n};\n\nvar flipY = {\n n: \"s\",\n s: \"n\",\n nw: \"sw\",\n ne: \"se\",\n se: \"ne\",\n sw: \"nw\"\n};\n\nvar signsX = {\n overlay: +1,\n selection: +1,\n n: null,\n e: +1,\n s: null,\n w: -1,\n nw: -1,\n ne: +1,\n se: +1,\n sw: -1\n};\n\nvar signsY = {\n overlay: +1,\n selection: +1,\n n: -1,\n e: null,\n s: +1,\n w: null,\n nw: -1,\n ne: -1,\n se: +1,\n sw: +1\n};\n\nfunction type(t) {\n return {type: t};\n}\n\n// Ignore right-click, since that should open the context menu.\nfunction defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}\n\nfunction defaultExtent() {\n var svg = this.ownerSVGElement || this;\n if (svg.hasAttribute(\"viewBox\")) {\n svg = svg.viewBox.baseVal;\n return [[svg.x, svg.y], [svg.x + svg.width, svg.y + svg.height]];\n }\n return [[0, 0], [svg.width.baseVal.value, svg.height.baseVal.value]];\n}\n\nfunction defaultTouchable() {\n return navigator.maxTouchPoints || (\"ontouchstart\" in this);\n}\n\n// Like d3.local, but with the name \u201C__brush\u201D rather than auto-generated.\nfunction local(node) {\n while (!node.__brush) if (!(node = node.parentNode)) return;\n return node.__brush;\n}\n\nfunction empty(extent) {\n return extent[0][0] === extent[1][0]\n || extent[0][1] === extent[1][1];\n}\n\nexport function brushSelection(node) {\n var state = node.__brush;\n return state ? state.dim.output(state.selection) : null;\n}\n\nexport function brushX() {\n return brush(X);\n}\n\nexport function brushY() {\n return brush(Y);\n}\n\nexport default function() {\n return brush(XY);\n}\n\nfunction brush(dim) {\n var extent = defaultExtent,\n filter = defaultFilter,\n touchable = defaultTouchable,\n keys = true,\n listeners = dispatch(\"start\", \"brush\", \"end\"),\n handleSize = 6,\n touchending;\n\n function brush(group) {\n var overlay = group\n .property(\"__brush\", initialize)\n .selectAll(\".overlay\")\n .data([type(\"overlay\")]);\n\n overlay.enter().append(\"rect\")\n .attr(\"class\", \"overlay\")\n .attr(\"pointer-events\", \"all\")\n .attr(\"cursor\", cursors.overlay)\n .merge(overlay)\n .each(function() {\n var extent = local(this).extent;\n select(this)\n .attr(\"x\", extent[0][0])\n .attr(\"y\", extent[0][1])\n .attr(\"width\", extent[1][0] - extent[0][0])\n .attr(\"height\", extent[1][1] - extent[0][1]);\n });\n\n group.selectAll(\".selection\")\n .data([type(\"selection\")])\n .enter().append(\"rect\")\n .attr(\"class\", \"selection\")\n .attr(\"cursor\", cursors.selection)\n .attr(\"fill\", \"#777\")\n .attr(\"fill-opacity\", 0.3)\n .attr(\"stroke\", \"#fff\")\n .attr(\"shape-rendering\", \"crispEdges\");\n\n var handle = group.selectAll(\".handle\")\n .data(dim.handles, function(d) { return d.type; });\n\n handle.exit().remove();\n\n handle.enter().append(\"rect\")\n .attr(\"class\", function(d) { return \"handle handle--\" + d.type; })\n .attr(\"cursor\", function(d) { return cursors[d.type]; });\n\n group\n .each(redraw)\n .attr(\"fill\", \"none\")\n .attr(\"pointer-events\", \"all\")\n .on(\"mousedown.brush\", started)\n .filter(touchable)\n .on(\"touchstart.brush\", started)\n .on(\"touchmove.brush\", touchmoved)\n .on(\"touchend.brush touchcancel.brush\", touchended)\n .style(\"touch-action\", \"none\")\n .style(\"-webkit-tap-highlight-color\", \"rgba(0,0,0,0)\");\n }\n\n brush.move = function(group, selection, event) {\n if (group.tween) {\n group\n .on(\"start.brush\", function(event) { emitter(this, arguments).beforestart().start(event); })\n .on(\"interrupt.brush end.brush\", function(event) { emitter(this, arguments).end(event); })\n .tween(\"brush\", function() {\n var that = this,\n state = that.__brush,\n emit = emitter(that, arguments),\n selection0 = state.selection,\n selection1 = dim.input(typeof selection === \"function\" ? selection.apply(this, arguments) : selection, state.extent),\n i = interpolate(selection0, selection1);\n\n function tween(t) {\n state.selection = t === 1 && selection1 === null ? null : i(t);\n redraw.call(that);\n emit.brush();\n }\n\n return selection0 !== null && selection1 !== null ? tween : tween(1);\n });\n } else {\n group\n .each(function() {\n var that = this,\n args = arguments,\n state = that.__brush,\n selection1 = dim.input(typeof selection === \"function\" ? selection.apply(that, args) : selection, state.extent),\n emit = emitter(that, args).beforestart();\n\n interrupt(that);\n state.selection = selection1 === null ? null : selection1;\n redraw.call(that);\n emit.start(event).brush(event).end(event);\n });\n }\n };\n\n brush.clear = function(group, event) {\n brush.move(group, null, event);\n };\n\n function redraw() {\n var group = select(this),\n selection = local(this).selection;\n\n if (selection) {\n group.selectAll(\".selection\")\n .style(\"display\", null)\n .attr(\"x\", selection[0][0])\n .attr(\"y\", selection[0][1])\n .attr(\"width\", selection[1][0] - selection[0][0])\n .attr(\"height\", selection[1][1] - selection[0][1]);\n\n group.selectAll(\".handle\")\n .style(\"display\", null)\n .attr(\"x\", function(d) { return d.type[d.type.length - 1] === \"e\" ? selection[1][0] - handleSize / 2 : selection[0][0] - handleSize / 2; })\n .attr(\"y\", function(d) { return d.type[0] === \"s\" ? selection[1][1] - handleSize / 2 : selection[0][1] - handleSize / 2; })\n .attr(\"width\", function(d) { return d.type === \"n\" || d.type === \"s\" ? selection[1][0] - selection[0][0] + handleSize : handleSize; })\n .attr(\"height\", function(d) { return d.type === \"e\" || d.type === \"w\" ? selection[1][1] - selection[0][1] + handleSize : handleSize; });\n }\n\n else {\n group.selectAll(\".selection,.handle\")\n .style(\"display\", \"none\")\n .attr(\"x\", null)\n .attr(\"y\", null)\n .attr(\"width\", null)\n .attr(\"height\", null);\n }\n }\n\n function emitter(that, args, clean) {\n var emit = that.__brush.emitter;\n return emit && (!clean || !emit.clean) ? emit : new Emitter(that, args, clean);\n }\n\n function Emitter(that, args, clean) {\n this.that = that;\n this.args = args;\n this.state = that.__brush;\n this.active = 0;\n this.clean = clean;\n }\n\n Emitter.prototype = {\n beforestart: function() {\n if (++this.active === 1) this.state.emitter = this, this.starting = true;\n return this;\n },\n start: function(event, mode) {\n if (this.starting) this.starting = false, this.emit(\"start\", event, mode);\n else this.emit(\"brush\", event);\n return this;\n },\n brush: function(event, mode) {\n this.emit(\"brush\", event, mode);\n return this;\n },\n end: function(event, mode) {\n if (--this.active === 0) delete this.state.emitter, this.emit(\"end\", event, mode);\n return this;\n },\n emit: function(type, event, mode) {\n var d = select(this.that).datum();\n listeners.call(\n type,\n this.that,\n new BrushEvent(type, {\n sourceEvent: event,\n target: brush,\n selection: dim.output(this.state.selection),\n mode,\n dispatch: listeners\n }),\n d\n );\n }\n };\n\n function started(event) {\n if (touchending && !event.touches) return;\n if (!filter.apply(this, arguments)) return;\n\n var that = this,\n type = event.target.__data__.type,\n mode = (keys && event.metaKey ? type = \"overlay\" : type) === \"selection\" ? MODE_DRAG : (keys && event.altKey ? MODE_CENTER : MODE_HANDLE),\n signX = dim === Y ? null : signsX[type],\n signY = dim === X ? null : signsY[type],\n state = local(that),\n extent = state.extent,\n selection = state.selection,\n W = extent[0][0], w0, w1,\n N = extent[0][1], n0, n1,\n E = extent[1][0], e0, e1,\n S = extent[1][1], s0, s1,\n dx = 0,\n dy = 0,\n moving,\n shifting = signX && signY && keys && event.shiftKey,\n lockX,\n lockY,\n points = Array.from(event.touches || [event], t => {\n const i = t.identifier;\n t = pointer(t, that);\n t.point0 = t.slice();\n t.identifier = i;\n return t;\n });\n\n interrupt(that);\n var emit = emitter(that, arguments, true).beforestart();\n\n if (type === \"overlay\") {\n if (selection) moving = true;\n const pts = [points[0], points[1] || points[0]];\n state.selection = selection = [[\n w0 = dim === Y ? W : min(pts[0][0], pts[1][0]),\n n0 = dim === X ? N : min(pts[0][1], pts[1][1])\n ], [\n e0 = dim === Y ? E : max(pts[0][0], pts[1][0]),\n s0 = dim === X ? S : max(pts[0][1], pts[1][1])\n ]];\n if (points.length > 1) move(event);\n } else {\n w0 = selection[0][0];\n n0 = selection[0][1];\n e0 = selection[1][0];\n s0 = selection[1][1];\n }\n\n w1 = w0;\n n1 = n0;\n e1 = e0;\n s1 = s0;\n\n var group = select(that)\n .attr(\"pointer-events\", \"none\");\n\n var overlay = group.selectAll(\".overlay\")\n .attr(\"cursor\", cursors[type]);\n\n if (event.touches) {\n emit.moved = moved;\n emit.ended = ended;\n } else {\n var view = select(event.view)\n .on(\"mousemove.brush\", moved, true)\n .on(\"mouseup.brush\", ended, true);\n if (keys) view\n .on(\"keydown.brush\", keydowned, true)\n .on(\"keyup.brush\", keyupped, true)\n\n dragDisable(event.view);\n }\n\n redraw.call(that);\n emit.start(event, mode.name);\n\n function moved(event) {\n for (const p of event.changedTouches || [event]) {\n for (const d of points)\n if (d.identifier === p.identifier) d.cur = pointer(p, that);\n }\n if (shifting && !lockX && !lockY && points.length === 1) {\n const point = points[0];\n if (abs(point.cur[0] - point[0]) > abs(point.cur[1] - point[1]))\n lockY = true;\n else\n lockX = true;\n }\n for (const point of points)\n if (point.cur) point[0] = point.cur[0], point[1] = point.cur[1];\n moving = true;\n noevent(event);\n move(event);\n }\n\n function move(event) {\n const point = points[0], point0 = point.point0;\n var t;\n\n dx = point[0] - point0[0];\n dy = point[1] - point0[1];\n\n switch (mode) {\n case MODE_SPACE:\n case MODE_DRAG: {\n if (signX) dx = max(W - w0, min(E - e0, dx)), w1 = w0 + dx, e1 = e0 + dx;\n if (signY) dy = max(N - n0, min(S - s0, dy)), n1 = n0 + dy, s1 = s0 + dy;\n break;\n }\n case MODE_HANDLE: {\n if (points[1]) {\n if (signX) w1 = max(W, min(E, points[0][0])), e1 = max(W, min(E, points[1][0])), signX = 1;\n if (signY) n1 = max(N, min(S, points[0][1])), s1 = max(N, min(S, points[1][1])), signY = 1;\n } else {\n if (signX < 0) dx = max(W - w0, min(E - w0, dx)), w1 = w0 + dx, e1 = e0;\n else if (signX > 0) dx = max(W - e0, min(E - e0, dx)), w1 = w0, e1 = e0 + dx;\n if (signY < 0) dy = max(N - n0, min(S - n0, dy)), n1 = n0 + dy, s1 = s0;\n else if (signY > 0) dy = max(N - s0, min(S - s0, dy)), n1 = n0, s1 = s0 + dy;\n }\n break;\n }\n case MODE_CENTER: {\n if (signX) w1 = max(W, min(E, w0 - dx * signX)), e1 = max(W, min(E, e0 + dx * signX));\n if (signY) n1 = max(N, min(S, n0 - dy * signY)), s1 = max(N, min(S, s0 + dy * signY));\n break;\n }\n }\n\n if (e1 < w1) {\n signX *= -1;\n t = w0, w0 = e0, e0 = t;\n t = w1, w1 = e1, e1 = t;\n if (type in flipX) overlay.attr(\"cursor\", cursors[type = flipX[type]]);\n }\n\n if (s1 < n1) {\n signY *= -1;\n t = n0, n0 = s0, s0 = t;\n t = n1, n1 = s1, s1 = t;\n if (type in flipY) overlay.attr(\"cursor\", cursors[type = flipY[type]]);\n }\n\n if (state.selection) selection = state.selection; // May be set by brush.move!\n if (lockX) w1 = selection[0][0], e1 = selection[1][0];\n if (lockY) n1 = selection[0][1], s1 = selection[1][1];\n\n if (selection[0][0] !== w1\n || selection[0][1] !== n1\n || selection[1][0] !== e1\n || selection[1][1] !== s1) {\n state.selection = [[w1, n1], [e1, s1]];\n redraw.call(that);\n emit.brush(event, mode.name);\n }\n }\n\n function ended(event) {\n nopropagation(event);\n if (event.touches) {\n if (event.touches.length) return;\n if (touchending) clearTimeout(touchending);\n touchending = setTimeout(function() { touchending = null; }, 500); // Ghost clicks are delayed!\n } else {\n dragEnable(event.view, moving);\n view.on(\"keydown.brush keyup.brush mousemove.brush mouseup.brush\", null);\n }\n group.attr(\"pointer-events\", \"all\");\n overlay.attr(\"cursor\", cursors.overlay);\n if (state.selection) selection = state.selection; // May be set by brush.move (on start)!\n if (empty(selection)) state.selection = null, redraw.call(that);\n emit.end(event, mode.name);\n }\n\n function keydowned(event) {\n switch (event.keyCode) {\n case 16: { // SHIFT\n shifting = signX && signY;\n break;\n }\n case 18: { // ALT\n if (mode === MODE_HANDLE) {\n if (signX) e0 = e1 - dx * signX, w0 = w1 + dx * signX;\n if (signY) s0 = s1 - dy * signY, n0 = n1 + dy * signY;\n mode = MODE_CENTER;\n move(event);\n }\n break;\n }\n case 32: { // SPACE; takes priority over ALT\n if (mode === MODE_HANDLE || mode === MODE_CENTER) {\n if (signX < 0) e0 = e1 - dx; else if (signX > 0) w0 = w1 - dx;\n if (signY < 0) s0 = s1 - dy; else if (signY > 0) n0 = n1 - dy;\n mode = MODE_SPACE;\n overlay.attr(\"cursor\", cursors.selection);\n move(event);\n }\n break;\n }\n default: return;\n }\n noevent(event);\n }\n\n function keyupped(event) {\n switch (event.keyCode) {\n case 16: { // SHIFT\n if (shifting) {\n lockX = lockY = shifting = false;\n move(event);\n }\n break;\n }\n case 18: { // ALT\n if (mode === MODE_CENTER) {\n if (signX < 0) e0 = e1; else if (signX > 0) w0 = w1;\n if (signY < 0) s0 = s1; else if (signY > 0) n0 = n1;\n mode = MODE_HANDLE;\n move(event);\n }\n break;\n }\n case 32: { // SPACE\n if (mode === MODE_SPACE) {\n if (event.altKey) {\n if (signX) e0 = e1 - dx * signX, w0 = w1 + dx * signX;\n if (signY) s0 = s1 - dy * signY, n0 = n1 + dy * signY;\n mode = MODE_CENTER;\n } else {\n if (signX < 0) e0 = e1; else if (signX > 0) w0 = w1;\n if (signY < 0) s0 = s1; else if (signY > 0) n0 = n1;\n mode = MODE_HANDLE;\n }\n overlay.attr(\"cursor\", cursors[type]);\n move(event);\n }\n break;\n }\n default: return;\n }\n noevent(event);\n }\n }\n\n function touchmoved(event) {\n emitter(this, arguments).moved(event);\n }\n\n function touchended(event) {\n emitter(this, arguments).ended(event);\n }\n\n function initialize() {\n var state = this.__brush || {selection: null};\n state.extent = number2(extent.apply(this, arguments));\n state.dim = dim;\n return state;\n }\n\n brush.extent = function(_) {\n return arguments.length ? (extent = typeof _ === \"function\" ? _ : constant(number2(_)), brush) : extent;\n };\n\n brush.filter = function(_) {\n return arguments.length ? (filter = typeof _ === \"function\" ? _ : constant(!!_), brush) : filter;\n };\n\n brush.touchable = function(_) {\n return arguments.length ? (touchable = typeof _ === \"function\" ? _ : constant(!!_), brush) : touchable;\n };\n\n brush.handleSize = function(_) {\n return arguments.length ? (handleSize = +_, brush) : handleSize;\n };\n\n brush.keyModifiers = function(_) {\n return arguments.length ? (keys = !!_, brush) : keys;\n };\n\n brush.on = function() {\n var value = listeners.on.apply(listeners, arguments);\n return value === listeners ? brush : value;\n };\n\n return brush;\n}\n", "function responseText(response) {\n if (!response.ok) throw new Error(response.status + \" \" + response.statusText);\n return response.text();\n}\n\nexport default function(input, init) {\n return fetch(input, init).then(responseText);\n}\n", "import text from \"./text.js\";\n\nfunction parser(type) {\n return (input, init) => text(input, init)\n .then(text => (new DOMParser).parseFromString(text, type));\n}\n\nexport default parser(\"application/xml\");\n\nexport var html = parser(\"text/html\");\n\nexport var svg = parser(\"image/svg+xml\");\n", "export function Transform(k, x, y) {\n this.k = k;\n this.x = x;\n this.y = y;\n}\n\nTransform.prototype = {\n constructor: Transform,\n scale: function(k) {\n return k === 1 ? this : new Transform(this.k * k, this.x, this.y);\n },\n translate: function(x, y) {\n return x === 0 & y === 0 ? this : new Transform(this.k, this.x + this.k * x, this.y + this.k * y);\n },\n apply: function(point) {\n return [point[0] * this.k + this.x, point[1] * this.k + this.y];\n },\n applyX: function(x) {\n return x * this.k + this.x;\n },\n applyY: function(y) {\n return y * this.k + this.y;\n },\n invert: function(location) {\n return [(location[0] - this.x) / this.k, (location[1] - this.y) / this.k];\n },\n invertX: function(x) {\n return (x - this.x) / this.k;\n },\n invertY: function(y) {\n return (y - this.y) / this.k;\n },\n rescaleX: function(x) {\n return x.copy().domain(x.range().map(this.invertX, this).map(x.invert, x));\n },\n rescaleY: function(y) {\n return y.copy().domain(y.range().map(this.invertY, this).map(y.invert, y));\n },\n toString: function() {\n return \"translate(\" + this.x + \",\" + this.y + \") scale(\" + this.k + \")\";\n }\n};\n\nexport var identity = new Transform(1, 0, 0);\n\ntransform.prototype = Transform.prototype;\n\nexport default function transform(node) {\n while (!node.__zoom) if (!(node = node.parentNode)) return identity;\n return node.__zoom;\n}\n", "/* IMPORT */\n/* MAIN */\nconst Channel = {\n /* CLAMP */\n min: {\n r: 0,\n g: 0,\n b: 0,\n s: 0,\n l: 0,\n a: 0\n },\n max: {\n r: 255,\n g: 255,\n b: 255,\n h: 360,\n s: 100,\n l: 100,\n a: 1\n },\n clamp: {\n r: (r) => r >= 255 ? 255 : (r < 0 ? 0 : r),\n g: (g) => g >= 255 ? 255 : (g < 0 ? 0 : g),\n b: (b) => b >= 255 ? 255 : (b < 0 ? 0 : b),\n h: (h) => h % 360,\n s: (s) => s >= 100 ? 100 : (s < 0 ? 0 : s),\n l: (l) => l >= 100 ? 100 : (l < 0 ? 0 : l),\n a: (a) => a >= 1 ? 1 : (a < 0 ? 0 : a)\n },\n /* CONVERSION */\n //SOURCE: https://planetcalc.com/7779\n toLinear: (c) => {\n const n = c / 255;\n return c > .03928 ? Math.pow(((n + .055) / 1.055), 2.4) : n / 12.92;\n },\n //SOURCE: https://gist.github.com/mjackson/5311256\n hue2rgb: (p, q, t) => {\n if (t < 0)\n t += 1;\n if (t > 1)\n t -= 1;\n if (t < 1 / 6)\n return p + (q - p) * 6 * t;\n if (t < 1 / 2)\n return q;\n if (t < 2 / 3)\n return p + (q - p) * (2 / 3 - t) * 6;\n return p;\n },\n hsl2rgb: ({ h, s, l }, channel) => {\n if (!s)\n return l * 2.55; // Achromatic\n h /= 360;\n s /= 100;\n l /= 100;\n const q = (l < .5) ? l * (1 + s) : (l + s) - (l * s);\n const p = 2 * l - q;\n switch (channel) {\n case 'r': return Channel.hue2rgb(p, q, h + 1 / 3) * 255;\n case 'g': return Channel.hue2rgb(p, q, h) * 255;\n case 'b': return Channel.hue2rgb(p, q, h - 1 / 3) * 255;\n }\n },\n rgb2hsl: ({ r, g, b }, channel) => {\n r /= 255;\n g /= 255;\n b /= 255;\n const max = Math.max(r, g, b);\n const min = Math.min(r, g, b);\n const l = (max + min) / 2;\n if (channel === 'l')\n return l * 100;\n if (max === min)\n return 0; // Achromatic\n const d = max - min;\n const s = (l > .5) ? d / (2 - max - min) : d / (max + min);\n if (channel === 's')\n return s * 100;\n switch (max) {\n case r: return ((g - b) / d + (g < b ? 6 : 0)) * 60;\n case g: return ((b - r) / d + 2) * 60;\n case b: return ((r - g) / d + 4) * 60;\n default: return -1; //TSC: TypeScript is stupid and complains if there isn't this useless default statement\n }\n }\n};\n/* EXPORT */\nexport default Channel;\n", "/* MAIN */\nconst Lang = {\n /* API */\n clamp: (number, lower, upper) => {\n if (lower > upper)\n return Math.min(lower, Math.max(upper, number));\n return Math.min(upper, Math.max(lower, number));\n },\n round: (number) => {\n return Math.round(number * 10000000000) / 10000000000;\n }\n};\n/* EXPORT */\nexport default Lang;\n", "/* MAIN */\nconst Unit = {\n /* API */\n dec2hex: (dec) => {\n const hex = Math.round(dec).toString(16);\n return hex.length > 1 ? hex : `0${hex}`;\n }\n};\n/* EXPORT */\nexport default Unit;\n", "/* IMPORT */\nimport channel from './channel.js';\nimport lang from './lang.js';\nimport unit from './unit.js';\n/* MAIN */\nconst Utils = {\n channel,\n lang,\n unit\n};\n/* EXPORT */\nexport default Utils;\n", "/* IMPORT */\nimport _ from './utils/index.js';\n/* MAIN */\nconst DEC2HEX = {};\nfor (let i = 0; i <= 255; i++)\n DEC2HEX[i] = _.unit.dec2hex(i); // Populating dynamically, striking a balance between code size and performance\nconst TYPE = {\n ALL: 0,\n RGB: 1,\n HSL: 2\n};\n/* EXPORT */\nexport { DEC2HEX, TYPE };\n", "/* IMPORT */\nimport { TYPE } from '../constants.js';\n/* MAIN */\nclass Type {\n constructor() {\n /* VARIABLES */\n this.type = TYPE.ALL;\n }\n /* API */\n get() {\n return this.type;\n }\n set(type) {\n if (this.type && this.type !== type)\n throw new Error('Cannot change both RGB and HSL channels at the same time');\n this.type = type;\n }\n reset() {\n this.type = TYPE.ALL;\n }\n is(type) {\n return this.type === type;\n }\n}\n/* EXPORT */\nexport default Type;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Type from './type.js';\nimport { TYPE } from '../constants.js';\n/* MAIN */\nclass Channels {\n /* CONSTRUCTOR */\n constructor(data, color) {\n this.color = color;\n this.changed = false;\n this.data = data; //TSC\n this.type = new Type();\n }\n /* API */\n set(data, color) {\n this.color = color;\n this.changed = false;\n this.data = data; //TSC\n this.type.type = TYPE.ALL;\n return this;\n }\n /* HELPERS */\n _ensureHSL() {\n const data = this.data;\n const { h, s, l } = data;\n if (h === undefined)\n data.h = _.channel.rgb2hsl(data, 'h');\n if (s === undefined)\n data.s = _.channel.rgb2hsl(data, 's');\n if (l === undefined)\n data.l = _.channel.rgb2hsl(data, 'l');\n }\n _ensureRGB() {\n const data = this.data;\n const { r, g, b } = data;\n if (r === undefined)\n data.r = _.channel.hsl2rgb(data, 'r');\n if (g === undefined)\n data.g = _.channel.hsl2rgb(data, 'g');\n if (b === undefined)\n data.b = _.channel.hsl2rgb(data, 'b');\n }\n /* GETTERS */\n get r() {\n const data = this.data;\n const r = data.r;\n if (!this.type.is(TYPE.HSL) && r !== undefined)\n return r;\n this._ensureHSL();\n return _.channel.hsl2rgb(data, 'r');\n }\n get g() {\n const data = this.data;\n const g = data.g;\n if (!this.type.is(TYPE.HSL) && g !== undefined)\n return g;\n this._ensureHSL();\n return _.channel.hsl2rgb(data, 'g');\n }\n get b() {\n const data = this.data;\n const b = data.b;\n if (!this.type.is(TYPE.HSL) && b !== undefined)\n return b;\n this._ensureHSL();\n return _.channel.hsl2rgb(data, 'b');\n }\n get h() {\n const data = this.data;\n const h = data.h;\n if (!this.type.is(TYPE.RGB) && h !== undefined)\n return h;\n this._ensureRGB();\n return _.channel.rgb2hsl(data, 'h');\n }\n get s() {\n const data = this.data;\n const s = data.s;\n if (!this.type.is(TYPE.RGB) && s !== undefined)\n return s;\n this._ensureRGB();\n return _.channel.rgb2hsl(data, 's');\n }\n get l() {\n const data = this.data;\n const l = data.l;\n if (!this.type.is(TYPE.RGB) && l !== undefined)\n return l;\n this._ensureRGB();\n return _.channel.rgb2hsl(data, 'l');\n }\n get a() {\n return this.data.a;\n }\n /* SETTERS */\n set r(r) {\n this.type.set(TYPE.RGB);\n this.changed = true;\n this.data.r = r;\n }\n set g(g) {\n this.type.set(TYPE.RGB);\n this.changed = true;\n this.data.g = g;\n }\n set b(b) {\n this.type.set(TYPE.RGB);\n this.changed = true;\n this.data.b = b;\n }\n set h(h) {\n this.type.set(TYPE.HSL);\n this.changed = true;\n this.data.h = h;\n }\n set s(s) {\n this.type.set(TYPE.HSL);\n this.changed = true;\n this.data.s = s;\n }\n set l(l) {\n this.type.set(TYPE.HSL);\n this.changed = true;\n this.data.l = l;\n }\n set a(a) {\n this.changed = true;\n this.data.a = a;\n }\n}\n/* EXPORT */\nexport default Channels;\n", "/* IMPORT */\nimport Channels from './/index.js';\n/* MAIN */\nconst channels = new Channels({ r: 0, g: 0, b: 0, a: 0 }, 'transparent');\n/* EXPORT */\nexport default channels;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\nimport { DEC2HEX } from '../constants.js';\n/* MAIN */\nconst Hex = {\n /* VARIABLES */\n re: /^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,\n /* API */\n parse: (color) => {\n if (color.charCodeAt(0) !== 35)\n return; // '#'\n const match = color.match(Hex.re);\n if (!match)\n return;\n const hex = match[1];\n const dec = parseInt(hex, 16);\n const length = hex.length;\n const hasAlpha = length % 4 === 0;\n const isFullLength = length > 4;\n const multiplier = isFullLength ? 1 : 17;\n const bits = isFullLength ? 8 : 4;\n const bitsOffset = hasAlpha ? 0 : -1;\n const mask = isFullLength ? 255 : 15;\n return ChannelsReusable.set({\n r: ((dec >> (bits * (bitsOffset + 3))) & mask) * multiplier,\n g: ((dec >> (bits * (bitsOffset + 2))) & mask) * multiplier,\n b: ((dec >> (bits * (bitsOffset + 1))) & mask) * multiplier,\n a: hasAlpha ? (dec & mask) * multiplier / 255 : 1\n }, color);\n },\n stringify: (channels) => {\n const { r, g, b, a } = channels;\n if (a < 1) { // #RRGGBBAA\n return `#${DEC2HEX[Math.round(r)]}${DEC2HEX[Math.round(g)]}${DEC2HEX[Math.round(b)]}${DEC2HEX[Math.round(a * 255)]}`;\n }\n else { // #RRGGBB\n return `#${DEC2HEX[Math.round(r)]}${DEC2HEX[Math.round(g)]}${DEC2HEX[Math.round(b)]}`;\n }\n }\n};\n/* EXPORT */\nexport default Hex;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\n/* MAIN */\nconst HSL = {\n /* VARIABLES */\n re: /^hsla?\\(\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?(?:deg|grad|rad|turn)?)\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?%)\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?%)(?:\\s*?(?:,|\\/)\\s*?\\+?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?(%)?))?\\s*?\\)$/i,\n hueRe: /^(.+?)(deg|grad|rad|turn)$/i,\n /* HELPERS */\n _hue2deg: (hue) => {\n const match = hue.match(HSL.hueRe);\n if (match) {\n const [, number, unit] = match;\n switch (unit) {\n case 'grad': return _.channel.clamp.h(parseFloat(number) * .9);\n case 'rad': return _.channel.clamp.h(parseFloat(number) * 180 / Math.PI);\n case 'turn': return _.channel.clamp.h(parseFloat(number) * 360);\n }\n }\n return _.channel.clamp.h(parseFloat(hue));\n },\n /* API */\n parse: (color) => {\n const charCode = color.charCodeAt(0);\n if (charCode !== 104 && charCode !== 72)\n return; // 'h'/'H'\n const match = color.match(HSL.re);\n if (!match)\n return;\n const [, h, s, l, a, isAlphaPercentage] = match;\n return ChannelsReusable.set({\n h: HSL._hue2deg(h),\n s: _.channel.clamp.s(parseFloat(s)),\n l: _.channel.clamp.l(parseFloat(l)),\n a: a ? _.channel.clamp.a(isAlphaPercentage ? parseFloat(a) / 100 : parseFloat(a)) : 1\n }, color);\n },\n stringify: (channels) => {\n const { h, s, l, a } = channels;\n if (a < 1) { // HSLA\n return `hsla(${_.lang.round(h)}, ${_.lang.round(s)}%, ${_.lang.round(l)}%, ${a})`;\n }\n else { // HSL\n return `hsl(${_.lang.round(h)}, ${_.lang.round(s)}%, ${_.lang.round(l)}%)`;\n }\n }\n};\n/* EXPORT */\nexport default HSL;\n", "/* IMPORT */\nimport Hex from './hex.js';\n/* MAIN */\nconst Keyword = {\n /* VARIABLES */\n colors: {\n aliceblue: '#f0f8ff',\n antiquewhite: '#faebd7',\n aqua: '#00ffff',\n aquamarine: '#7fffd4',\n azure: '#f0ffff',\n beige: '#f5f5dc',\n bisque: '#ffe4c4',\n black: '#000000',\n blanchedalmond: '#ffebcd',\n blue: '#0000ff',\n blueviolet: '#8a2be2',\n brown: '#a52a2a',\n burlywood: '#deb887',\n cadetblue: '#5f9ea0',\n chartreuse: '#7fff00',\n chocolate: '#d2691e',\n coral: '#ff7f50',\n cornflowerblue: '#6495ed',\n cornsilk: '#fff8dc',\n crimson: '#dc143c',\n cyanaqua: '#00ffff',\n darkblue: '#00008b',\n darkcyan: '#008b8b',\n darkgoldenrod: '#b8860b',\n darkgray: '#a9a9a9',\n darkgreen: '#006400',\n darkgrey: '#a9a9a9',\n darkkhaki: '#bdb76b',\n darkmagenta: '#8b008b',\n darkolivegreen: '#556b2f',\n darkorange: '#ff8c00',\n darkorchid: '#9932cc',\n darkred: '#8b0000',\n darksalmon: '#e9967a',\n darkseagreen: '#8fbc8f',\n darkslateblue: '#483d8b',\n darkslategray: '#2f4f4f',\n darkslategrey: '#2f4f4f',\n darkturquoise: '#00ced1',\n darkviolet: '#9400d3',\n deeppink: '#ff1493',\n deepskyblue: '#00bfff',\n dimgray: '#696969',\n dimgrey: '#696969',\n dodgerblue: '#1e90ff',\n firebrick: '#b22222',\n floralwhite: '#fffaf0',\n forestgreen: '#228b22',\n fuchsia: '#ff00ff',\n gainsboro: '#dcdcdc',\n ghostwhite: '#f8f8ff',\n gold: '#ffd700',\n goldenrod: '#daa520',\n gray: '#808080',\n green: '#008000',\n greenyellow: '#adff2f',\n grey: '#808080',\n honeydew: '#f0fff0',\n hotpink: '#ff69b4',\n indianred: '#cd5c5c',\n indigo: '#4b0082',\n ivory: '#fffff0',\n khaki: '#f0e68c',\n lavender: '#e6e6fa',\n lavenderblush: '#fff0f5',\n lawngreen: '#7cfc00',\n lemonchiffon: '#fffacd',\n lightblue: '#add8e6',\n lightcoral: '#f08080',\n lightcyan: '#e0ffff',\n lightgoldenrodyellow: '#fafad2',\n lightgray: '#d3d3d3',\n lightgreen: '#90ee90',\n lightgrey: '#d3d3d3',\n lightpink: '#ffb6c1',\n lightsalmon: '#ffa07a',\n lightseagreen: '#20b2aa',\n lightskyblue: '#87cefa',\n lightslategray: '#778899',\n lightslategrey: '#778899',\n lightsteelblue: '#b0c4de',\n lightyellow: '#ffffe0',\n lime: '#00ff00',\n limegreen: '#32cd32',\n linen: '#faf0e6',\n magenta: '#ff00ff',\n maroon: '#800000',\n mediumaquamarine: '#66cdaa',\n mediumblue: '#0000cd',\n mediumorchid: '#ba55d3',\n mediumpurple: '#9370db',\n mediumseagreen: '#3cb371',\n mediumslateblue: '#7b68ee',\n mediumspringgreen: '#00fa9a',\n mediumturquoise: '#48d1cc',\n mediumvioletred: '#c71585',\n midnightblue: '#191970',\n mintcream: '#f5fffa',\n mistyrose: '#ffe4e1',\n moccasin: '#ffe4b5',\n navajowhite: '#ffdead',\n navy: '#000080',\n oldlace: '#fdf5e6',\n olive: '#808000',\n olivedrab: '#6b8e23',\n orange: '#ffa500',\n orangered: '#ff4500',\n orchid: '#da70d6',\n palegoldenrod: '#eee8aa',\n palegreen: '#98fb98',\n paleturquoise: '#afeeee',\n palevioletred: '#db7093',\n papayawhip: '#ffefd5',\n peachpuff: '#ffdab9',\n peru: '#cd853f',\n pink: '#ffc0cb',\n plum: '#dda0dd',\n powderblue: '#b0e0e6',\n purple: '#800080',\n rebeccapurple: '#663399',\n red: '#ff0000',\n rosybrown: '#bc8f8f',\n royalblue: '#4169e1',\n saddlebrown: '#8b4513',\n salmon: '#fa8072',\n sandybrown: '#f4a460',\n seagreen: '#2e8b57',\n seashell: '#fff5ee',\n sienna: '#a0522d',\n silver: '#c0c0c0',\n skyblue: '#87ceeb',\n slateblue: '#6a5acd',\n slategray: '#708090',\n slategrey: '#708090',\n snow: '#fffafa',\n springgreen: '#00ff7f',\n tan: '#d2b48c',\n teal: '#008080',\n thistle: '#d8bfd8',\n transparent: '#00000000',\n turquoise: '#40e0d0',\n violet: '#ee82ee',\n wheat: '#f5deb3',\n white: '#ffffff',\n whitesmoke: '#f5f5f5',\n yellow: '#ffff00',\n yellowgreen: '#9acd32'\n },\n /* API */\n parse: (color) => {\n color = color.toLowerCase();\n const hex = Keyword.colors[color];\n if (!hex)\n return;\n return Hex.parse(hex);\n },\n stringify: (channels) => {\n const hex = Hex.stringify(channels);\n for (const name in Keyword.colors) {\n if (Keyword.colors[name] === hex)\n return name;\n }\n return;\n }\n};\n/* EXPORT */\nexport default Keyword;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\n/* MAIN */\nconst RGB = {\n /* VARIABLES */\n re: /^rgba?\\(\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?))\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?))\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?))(?:\\s*?(?:,|\\/)\\s*?\\+?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?)))?\\s*?\\)$/i,\n /* API */\n parse: (color) => {\n const charCode = color.charCodeAt(0);\n if (charCode !== 114 && charCode !== 82)\n return; // 'r'/'R'\n const match = color.match(RGB.re);\n if (!match)\n return;\n const [, r, isRedPercentage, g, isGreenPercentage, b, isBluePercentage, a, isAlphaPercentage] = match;\n return ChannelsReusable.set({\n r: _.channel.clamp.r(isRedPercentage ? parseFloat(r) * 2.55 : parseFloat(r)),\n g: _.channel.clamp.g(isGreenPercentage ? parseFloat(g) * 2.55 : parseFloat(g)),\n b: _.channel.clamp.b(isBluePercentage ? parseFloat(b) * 2.55 : parseFloat(b)),\n a: a ? _.channel.clamp.a(isAlphaPercentage ? parseFloat(a) / 100 : parseFloat(a)) : 1\n }, color);\n },\n stringify: (channels) => {\n const { r, g, b, a } = channels;\n if (a < 1) { // RGBA\n return `rgba(${_.lang.round(r)}, ${_.lang.round(g)}, ${_.lang.round(b)}, ${_.lang.round(a)})`;\n }\n else { // RGB\n return `rgb(${_.lang.round(r)}, ${_.lang.round(g)}, ${_.lang.round(b)})`;\n }\n }\n};\n/* EXPORT */\nexport default RGB;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Hex from './hex.js';\nimport HSL from './hsl.js';\nimport Keyword from './keyword.js';\nimport RGB from './rgb.js';\nimport { TYPE } from '../constants.js';\n/* MAIN */\nconst Color = {\n /* VARIABLES */\n format: {\n keyword: Keyword,\n hex: Hex,\n rgb: RGB,\n rgba: RGB,\n hsl: HSL,\n hsla: HSL\n },\n /* API */\n parse: (color) => {\n if (typeof color !== 'string')\n return color;\n const channels = Hex.parse(color) || RGB.parse(color) || HSL.parse(color) || Keyword.parse(color); // Color providers ordered with performance in mind\n if (channels)\n return channels;\n throw new Error(`Unsupported color format: \"${color}\"`);\n },\n stringify: (channels) => {\n // SASS returns a keyword if possible, but we avoid doing that as it's slower and doesn't really add any value\n if (!channels.changed && channels.color)\n return channels.color;\n if (channels.type.is(TYPE.HSL) || channels.data.r === undefined) {\n return HSL.stringify(channels);\n }\n else if (channels.a < 1 || !Number.isInteger(channels.r) || !Number.isInteger(channels.g) || !Number.isInteger(channels.b)) {\n return RGB.stringify(channels);\n }\n else {\n return Hex.stringify(channels);\n }\n }\n};\n/* EXPORT */\nexport default Color;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\n//SOURCE: https://planetcalc.com/7779\nconst luminance = (color) => {\n const { r, g, b } = Color.parse(color);\n const luminance = .2126 * _.channel.toLinear(r) + .7152 * _.channel.toLinear(g) + .0722 * _.channel.toLinear(b);\n return _.lang.round(luminance);\n};\n/* EXPORT */\nexport default luminance;\n", "/* IMPORT */\nimport luminance from './luminance.js';\n/* MAIN */\nconst isLight = (color) => {\n return luminance(color) >= .5;\n};\n/* EXPORT */\nexport default isLight;\n", "/* IMPORT */\nimport isLight from './is_light.js';\n/* MAIN */\nconst isDark = (color) => {\n return !isLight(color);\n};\n/* EXPORT */\nexport default isDark;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\nconst adjustChannel = (color, channel, amount) => {\n const channels = Color.parse(color);\n const amountCurrent = channels[channel];\n const amountNext = _.channel.clamp[channel](amountCurrent + amount);\n if (amountCurrent !== amountNext)\n channels[channel] = amountNext;\n return Color.stringify(channels);\n};\n/* EXPORT */\nexport default adjustChannel;\n", "/* IMPORT */\nimport adjustChannel from './adjust_channel.js';\n/* MAIN */\nconst lighten = (color, amount) => {\n return adjustChannel(color, 'l', amount);\n};\n/* EXPORT */\nexport default lighten;\n", "/* IMPORT */\nimport adjustChannel from './adjust_channel.js';\n/* MAIN */\nconst darken = (color, amount) => {\n return adjustChannel(color, 'l', -amount);\n};\n/* EXPORT */\nexport default darken;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\nconst change = (color, channels) => {\n const ch = Color.parse(color);\n for (const c in channels) {\n ch[c] = _.channel.clamp[c](channels[c]);\n }\n return Color.stringify(ch);\n};\n/* EXPORT */\nexport default change;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\nimport Color from '../color/index.js';\nimport change from './change.js';\n/* MAIN */\nconst rgba = (r, g, b = 0, a = 1) => {\n if (typeof r !== 'number')\n return change(r, { a: g });\n const channels = ChannelsReusable.set({\n r: _.channel.clamp.r(r),\n g: _.channel.clamp.g(g),\n b: _.channel.clamp.b(b),\n a: _.channel.clamp.a(a)\n });\n return Color.stringify(channels);\n};\n/* EXPORT */\nexport default rgba;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\nconst channel = (color, channel) => {\n return _.lang.round(Color.parse(color)[channel]);\n};\n/* EXPORT */\nexport default channel;\n", "/* IMPORT */\nimport Color from '../color/index.js';\nimport change from './change.js';\n/* MAIN */\nconst adjust = (color, channels) => {\n const ch = Color.parse(color);\n const changes = {};\n for (const c in channels) {\n if (!channels[c])\n continue;\n changes[c] = ch[c] + channels[c];\n }\n return change(color, changes);\n};\n/* EXPORT */\nexport default adjust;\n", "/* IMPORT */\nimport Color from '../color/index.js';\nimport rgba from './rgba.js';\n/* MAIN */\n//SOURCE: https://github.com/sass/dart-sass/blob/7457d2e9e7e623d9844ffd037a070cf32d39c348/lib/src/functions/color.dart#L718-L756\nconst mix = (color1, color2, weight = 50) => {\n const { r: r1, g: g1, b: b1, a: a1 } = Color.parse(color1);\n const { r: r2, g: g2, b: b2, a: a2 } = Color.parse(color2);\n const weightScale = weight / 100;\n const weightNormalized = (weightScale * 2) - 1;\n const alphaDelta = a1 - a2;\n const weight1combined = ((weightNormalized * alphaDelta) === -1) ? weightNormalized : (weightNormalized + alphaDelta) / (1 + weightNormalized * alphaDelta);\n const weight1 = (weight1combined + 1) / 2;\n const weight2 = 1 - weight1;\n const r = (r1 * weight1) + (r2 * weight2);\n const g = (g1 * weight1) + (g2 * weight2);\n const b = (b1 * weight1) + (b2 * weight2);\n const a = (a1 * weightScale) + (a2 * (1 - weightScale));\n return rgba(r, g, b, a);\n};\n/* EXPORT */\nexport default mix;\n", "/* IMPORT */\nimport Color from '../color/index.js';\nimport mix from './mix.js';\n/* MAIN */\nconst invert = (color, weight = 100) => {\n const inverse = Color.parse(color);\n inverse.r = 255 - inverse.r;\n inverse.g = 255 - inverse.g;\n inverse.b = 255 - inverse.b;\n return mix(inverse, color, weight);\n};\n/* EXPORT */\nexport default invert;\n", "/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nexport default freeGlobal;\n", "import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nexport default root;\n", "import root from './_root.js';\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nexport default Symbol;\n", "import Symbol from './_Symbol.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nexport default getRawTag;\n", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nexport default objectToString;\n", "import Symbol from './_Symbol.js';\nimport getRawTag from './_getRawTag.js';\nimport objectToString from './_objectToString.js';\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nexport default baseGetTag;\n", "/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nexport default isObject;\n", "import baseGetTag from './_baseGetTag.js';\nimport isObject from './isObject.js';\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nexport default isFunction;\n", "import root from './_root.js';\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nexport default coreJsData;\n", "import coreJsData from './_coreJsData.js';\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nexport default isMasked;\n", "/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nexport default toSource;\n", "import isFunction from './isFunction.js';\nimport isMasked from './_isMasked.js';\nimport isObject from './isObject.js';\nimport toSource from './_toSource.js';\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nexport default baseIsNative;\n", "/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nexport default getValue;\n", "import baseIsNative from './_baseIsNative.js';\nimport getValue from './_getValue.js';\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nexport default getNative;\n", "import getNative from './_getNative.js';\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nexport default nativeCreate;\n", "import nativeCreate from './_nativeCreate.js';\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nexport default hashClear;\n", "/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default hashDelete;\n", "import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nexport default hashGet;\n", "import nativeCreate from './_nativeCreate.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nexport default hashHas;\n", "import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nexport default hashSet;\n", "import hashClear from './_hashClear.js';\nimport hashDelete from './_hashDelete.js';\nimport hashGet from './_hashGet.js';\nimport hashHas from './_hashHas.js';\nimport hashSet from './_hashSet.js';\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nexport default Hash;\n", "/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nexport default listCacheClear;\n", "/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nexport default eq;\n", "import eq from './eq.js';\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nexport default assocIndexOf;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nexport default listCacheDelete;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nexport default listCacheGet;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nexport default listCacheHas;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nexport default listCacheSet;\n", "import listCacheClear from './_listCacheClear.js';\nimport listCacheDelete from './_listCacheDelete.js';\nimport listCacheGet from './_listCacheGet.js';\nimport listCacheHas from './_listCacheHas.js';\nimport listCacheSet from './_listCacheSet.js';\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nexport default ListCache;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nexport default Map;\n", "import Hash from './_Hash.js';\nimport ListCache from './_ListCache.js';\nimport Map from './_Map.js';\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nexport default mapCacheClear;\n", "/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nexport default isKeyable;\n", "import isKeyable from './_isKeyable.js';\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nexport default getMapData;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default mapCacheDelete;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nexport default mapCacheGet;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nexport default mapCacheHas;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nexport default mapCacheSet;\n", "import mapCacheClear from './_mapCacheClear.js';\nimport mapCacheDelete from './_mapCacheDelete.js';\nimport mapCacheGet from './_mapCacheGet.js';\nimport mapCacheHas from './_mapCacheHas.js';\nimport mapCacheSet from './_mapCacheSet.js';\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nexport default MapCache;\n", "import MapCache from './_MapCache.js';\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nexport default memoize;\n", "import ListCache from './_ListCache.js';\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nexport default stackClear;\n", "/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nexport default stackDelete;\n", "/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nexport default stackGet;\n", "/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nexport default stackHas;\n", "import ListCache from './_ListCache.js';\nimport Map from './_Map.js';\nimport MapCache from './_MapCache.js';\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nexport default stackSet;\n", "import ListCache from './_ListCache.js';\nimport stackClear from './_stackClear.js';\nimport stackDelete from './_stackDelete.js';\nimport stackGet from './_stackGet.js';\nimport stackHas from './_stackHas.js';\nimport stackSet from './_stackSet.js';\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nexport default Stack;\n", "import getNative from './_getNative.js';\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nexport default defineProperty;\n", "import defineProperty from './_defineProperty.js';\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nexport default baseAssignValue;\n", "import baseAssignValue from './_baseAssignValue.js';\nimport eq from './eq.js';\n\n/**\n * This function is like `assignValue` except that it doesn't assign\n * `undefined` values.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction assignMergeValue(object, key, value) {\n if ((value !== undefined && !eq(object[key], value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n}\n\nexport default assignMergeValue;\n", "/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nexport default createBaseFor;\n", "import createBaseFor from './_createBaseFor.js';\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nexport default baseFor;\n", "import root from './_root.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined,\n allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined;\n\n/**\n * Creates a clone of `buffer`.\n *\n * @private\n * @param {Buffer} buffer The buffer to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Buffer} Returns the cloned buffer.\n */\nfunction cloneBuffer(buffer, isDeep) {\n if (isDeep) {\n return buffer.slice();\n }\n var length = buffer.length,\n result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);\n\n buffer.copy(result);\n return result;\n}\n\nexport default cloneBuffer;\n", "import root from './_root.js';\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nexport default Uint8Array;\n", "import Uint8Array from './_Uint8Array.js';\n\n/**\n * Creates a clone of `arrayBuffer`.\n *\n * @private\n * @param {ArrayBuffer} arrayBuffer The array buffer to clone.\n * @returns {ArrayBuffer} Returns the cloned array buffer.\n */\nfunction cloneArrayBuffer(arrayBuffer) {\n var result = new arrayBuffer.constructor(arrayBuffer.byteLength);\n new Uint8Array(result).set(new Uint8Array(arrayBuffer));\n return result;\n}\n\nexport default cloneArrayBuffer;\n", "import cloneArrayBuffer from './_cloneArrayBuffer.js';\n\n/**\n * Creates a clone of `typedArray`.\n *\n * @private\n * @param {Object} typedArray The typed array to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the cloned typed array.\n */\nfunction cloneTypedArray(typedArray, isDeep) {\n var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;\n return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);\n}\n\nexport default cloneTypedArray;\n", "/**\n * Copies the values of `source` to `array`.\n *\n * @private\n * @param {Array} source The array to copy values from.\n * @param {Array} [array=[]] The array to copy values to.\n * @returns {Array} Returns `array`.\n */\nfunction copyArray(source, array) {\n var index = -1,\n length = source.length;\n\n array || (array = Array(length));\n while (++index < length) {\n array[index] = source[index];\n }\n return array;\n}\n\nexport default copyArray;\n", "import isObject from './isObject.js';\n\n/** Built-in value references. */\nvar objectCreate = Object.create;\n\n/**\n * The base implementation of `_.create` without support for assigning\n * properties to the created object.\n *\n * @private\n * @param {Object} proto The object to inherit from.\n * @returns {Object} Returns the new object.\n */\nvar baseCreate = (function() {\n function object() {}\n return function(proto) {\n if (!isObject(proto)) {\n return {};\n }\n if (objectCreate) {\n return objectCreate(proto);\n }\n object.prototype = proto;\n var result = new object;\n object.prototype = undefined;\n return result;\n };\n}());\n\nexport default baseCreate;\n", "/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nexport default overArg;\n", "import overArg from './_overArg.js';\n\n/** Built-in value references. */\nvar getPrototype = overArg(Object.getPrototypeOf, Object);\n\nexport default getPrototype;\n", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nexport default isPrototype;\n", "import baseCreate from './_baseCreate.js';\nimport getPrototype from './_getPrototype.js';\nimport isPrototype from './_isPrototype.js';\n\n/**\n * Initializes an object clone.\n *\n * @private\n * @param {Object} object The object to clone.\n * @returns {Object} Returns the initialized clone.\n */\nfunction initCloneObject(object) {\n return (typeof object.constructor == 'function' && !isPrototype(object))\n ? baseCreate(getPrototype(object))\n : {};\n}\n\nexport default initCloneObject;\n", "/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nexport default isObjectLike;\n", "import baseGetTag from './_baseGetTag.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nexport default baseIsArguments;\n", "import baseIsArguments from './_baseIsArguments.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nexport default isArguments;\n", "/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nexport default isArray;\n", "/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nexport default isLength;\n", "import isFunction from './isFunction.js';\nimport isLength from './isLength.js';\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nexport default isArrayLike;\n", "import isArrayLike from './isArrayLike.js';\nimport isObjectLike from './isObjectLike.js';\n\n/**\n * This method is like `_.isArrayLike` except that it also checks if `value`\n * is an object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array-like object,\n * else `false`.\n * @example\n *\n * _.isArrayLikeObject([1, 2, 3]);\n * // => true\n *\n * _.isArrayLikeObject(document.body.children);\n * // => true\n *\n * _.isArrayLikeObject('abc');\n * // => false\n *\n * _.isArrayLikeObject(_.noop);\n * // => false\n */\nfunction isArrayLikeObject(value) {\n return isObjectLike(value) && isArrayLike(value);\n}\n\nexport default isArrayLikeObject;\n", "/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nexport default stubFalse;\n", "import root from './_root.js';\nimport stubFalse from './stubFalse.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nexport default isBuffer;\n", "import baseGetTag from './_baseGetTag.js';\nimport getPrototype from './_getPrototype.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to infer the `Object` constructor. */\nvar objectCtorString = funcToString.call(Object);\n\n/**\n * Checks if `value` is a plain object, that is, an object created by the\n * `Object` constructor or one with a `[[Prototype]]` of `null`.\n *\n * @static\n * @memberOf _\n * @since 0.8.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * _.isPlainObject(new Foo);\n * // => false\n *\n * _.isPlainObject([1, 2, 3]);\n * // => false\n *\n * _.isPlainObject({ 'x': 0, 'y': 0 });\n * // => true\n *\n * _.isPlainObject(Object.create(null));\n * // => true\n */\nfunction isPlainObject(value) {\n if (!isObjectLike(value) || baseGetTag(value) != objectTag) {\n return false;\n }\n var proto = getPrototype(value);\n if (proto === null) {\n return true;\n }\n var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;\n return typeof Ctor == 'function' && Ctor instanceof Ctor &&\n funcToString.call(Ctor) == objectCtorString;\n}\n\nexport default isPlainObject;\n", "import baseGetTag from './_baseGetTag.js';\nimport isLength from './isLength.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nexport default baseIsTypedArray;\n", "/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nexport default baseUnary;\n", "import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nexport default nodeUtil;\n", "import baseIsTypedArray from './_baseIsTypedArray.js';\nimport baseUnary from './_baseUnary.js';\nimport nodeUtil from './_nodeUtil.js';\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nexport default isTypedArray;\n", "/**\n * Gets the value at `key`, unless `key` is \"__proto__\" or \"constructor\".\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction safeGet(object, key) {\n if (key === 'constructor' && typeof object[key] === 'function') {\n return;\n }\n\n if (key == '__proto__') {\n return;\n }\n\n return object[key];\n}\n\nexport default safeGet;\n", "import baseAssignValue from './_baseAssignValue.js';\nimport eq from './eq.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Assigns `value` to `key` of `object` if the existing value is not equivalent\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction assignValue(object, key, value) {\n var objValue = object[key];\n if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n}\n\nexport default assignValue;\n", "import assignValue from './_assignValue.js';\nimport baseAssignValue from './_baseAssignValue.js';\n\n/**\n * Copies properties of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy properties from.\n * @param {Array} props The property identifiers to copy.\n * @param {Object} [object={}] The object to copy properties to.\n * @param {Function} [customizer] The function to customize copied values.\n * @returns {Object} Returns `object`.\n */\nfunction copyObject(source, props, object, customizer) {\n var isNew = !object;\n object || (object = {});\n\n var index = -1,\n length = props.length;\n\n while (++index < length) {\n var key = props[index];\n\n var newValue = customizer\n ? customizer(object[key], source[key], key, object, source)\n : undefined;\n\n if (newValue === undefined) {\n newValue = source[key];\n }\n if (isNew) {\n baseAssignValue(object, key, newValue);\n } else {\n assignValue(object, key, newValue);\n }\n }\n return object;\n}\n\nexport default copyObject;\n", "/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nexport default baseTimes;\n", "/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nexport default isIndex;\n", "import baseTimes from './_baseTimes.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isBuffer from './isBuffer.js';\nimport isIndex from './_isIndex.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default arrayLikeKeys;\n", "/**\n * This function is like\n * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * except that it includes inherited enumerable properties.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction nativeKeysIn(object) {\n var result = [];\n if (object != null) {\n for (var key in Object(object)) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default nativeKeysIn;\n", "import isObject from './isObject.js';\nimport isPrototype from './_isPrototype.js';\nimport nativeKeysIn from './_nativeKeysIn.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeysIn(object) {\n if (!isObject(object)) {\n return nativeKeysIn(object);\n }\n var isProto = isPrototype(object),\n result = [];\n\n for (var key in object) {\n if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default baseKeysIn;\n", "import arrayLikeKeys from './_arrayLikeKeys.js';\nimport baseKeysIn from './_baseKeysIn.js';\nimport isArrayLike from './isArrayLike.js';\n\n/**\n * Creates an array of the own and inherited enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keysIn(new Foo);\n * // => ['a', 'b', 'c'] (iteration order is not guaranteed)\n */\nfunction keysIn(object) {\n return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);\n}\n\nexport default keysIn;\n", "import copyObject from './_copyObject.js';\nimport keysIn from './keysIn.js';\n\n/**\n * Converts `value` to a plain object flattening inherited enumerable string\n * keyed properties of `value` to own properties of the plain object.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {Object} Returns the converted plain object.\n * @example\n *\n * function Foo() {\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.assign({ 'a': 1 }, new Foo);\n * // => { 'a': 1, 'b': 2 }\n *\n * _.assign({ 'a': 1 }, _.toPlainObject(new Foo));\n * // => { 'a': 1, 'b': 2, 'c': 3 }\n */\nfunction toPlainObject(value) {\n return copyObject(value, keysIn(value));\n}\n\nexport default toPlainObject;\n", "import assignMergeValue from './_assignMergeValue.js';\nimport cloneBuffer from './_cloneBuffer.js';\nimport cloneTypedArray from './_cloneTypedArray.js';\nimport copyArray from './_copyArray.js';\nimport initCloneObject from './_initCloneObject.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isArrayLikeObject from './isArrayLikeObject.js';\nimport isBuffer from './isBuffer.js';\nimport isFunction from './isFunction.js';\nimport isObject from './isObject.js';\nimport isPlainObject from './isPlainObject.js';\nimport isTypedArray from './isTypedArray.js';\nimport safeGet from './_safeGet.js';\nimport toPlainObject from './toPlainObject.js';\n\n/**\n * A specialized version of `baseMerge` for arrays and objects which performs\n * deep merges and tracks traversed objects enabling objects with circular\n * references to be merged.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {string} key The key of the value to merge.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} mergeFunc The function to merge values.\n * @param {Function} [customizer] The function to customize assigned values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\nfunction baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {\n var objValue = safeGet(object, key),\n srcValue = safeGet(source, key),\n stacked = stack.get(srcValue);\n\n if (stacked) {\n assignMergeValue(object, key, stacked);\n return;\n }\n var newValue = customizer\n ? customizer(objValue, srcValue, (key + ''), object, source, stack)\n : undefined;\n\n var isCommon = newValue === undefined;\n\n if (isCommon) {\n var isArr = isArray(srcValue),\n isBuff = !isArr && isBuffer(srcValue),\n isTyped = !isArr && !isBuff && isTypedArray(srcValue);\n\n newValue = srcValue;\n if (isArr || isBuff || isTyped) {\n if (isArray(objValue)) {\n newValue = objValue;\n }\n else if (isArrayLikeObject(objValue)) {\n newValue = copyArray(objValue);\n }\n else if (isBuff) {\n isCommon = false;\n newValue = cloneBuffer(srcValue, true);\n }\n else if (isTyped) {\n isCommon = false;\n newValue = cloneTypedArray(srcValue, true);\n }\n else {\n newValue = [];\n }\n }\n else if (isPlainObject(srcValue) || isArguments(srcValue)) {\n newValue = objValue;\n if (isArguments(objValue)) {\n newValue = toPlainObject(objValue);\n }\n else if (!isObject(objValue) || isFunction(objValue)) {\n newValue = initCloneObject(srcValue);\n }\n }\n else {\n isCommon = false;\n }\n }\n if (isCommon) {\n // Recursively merge objects and arrays (susceptible to call stack limits).\n stack.set(srcValue, newValue);\n mergeFunc(newValue, srcValue, srcIndex, customizer, stack);\n stack['delete'](srcValue);\n }\n assignMergeValue(object, key, newValue);\n}\n\nexport default baseMergeDeep;\n", "import Stack from './_Stack.js';\nimport assignMergeValue from './_assignMergeValue.js';\nimport baseFor from './_baseFor.js';\nimport baseMergeDeep from './_baseMergeDeep.js';\nimport isObject from './isObject.js';\nimport keysIn from './keysIn.js';\nimport safeGet from './_safeGet.js';\n\n/**\n * The base implementation of `_.merge` without support for multiple sources.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} [customizer] The function to customize merged values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\nfunction baseMerge(object, source, srcIndex, customizer, stack) {\n if (object === source) {\n return;\n }\n baseFor(source, function(srcValue, key) {\n stack || (stack = new Stack);\n if (isObject(srcValue)) {\n baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);\n }\n else {\n var newValue = customizer\n ? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack)\n : undefined;\n\n if (newValue === undefined) {\n newValue = srcValue;\n }\n assignMergeValue(object, key, newValue);\n }\n }, keysIn);\n}\n\nexport default baseMerge;\n", "/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nexport default identity;\n", "/**\n * A faster alternative to `Function#apply`, this function invokes `func`\n * with the `this` binding of `thisArg` and the arguments of `args`.\n *\n * @private\n * @param {Function} func The function to invoke.\n * @param {*} thisArg The `this` binding of `func`.\n * @param {Array} args The arguments to invoke `func` with.\n * @returns {*} Returns the result of `func`.\n */\nfunction apply(func, thisArg, args) {\n switch (args.length) {\n case 0: return func.call(thisArg);\n case 1: return func.call(thisArg, args[0]);\n case 2: return func.call(thisArg, args[0], args[1]);\n case 3: return func.call(thisArg, args[0], args[1], args[2]);\n }\n return func.apply(thisArg, args);\n}\n\nexport default apply;\n", "import apply from './_apply.js';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max;\n\n/**\n * A specialized version of `baseRest` which transforms the rest array.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @param {Function} transform The rest array transform.\n * @returns {Function} Returns the new function.\n */\nfunction overRest(func, start, transform) {\n start = nativeMax(start === undefined ? (func.length - 1) : start, 0);\n return function() {\n var args = arguments,\n index = -1,\n length = nativeMax(args.length - start, 0),\n array = Array(length);\n\n while (++index < length) {\n array[index] = args[start + index];\n }\n index = -1;\n var otherArgs = Array(start + 1);\n while (++index < start) {\n otherArgs[index] = args[index];\n }\n otherArgs[start] = transform(array);\n return apply(func, this, otherArgs);\n };\n}\n\nexport default overRest;\n", "/**\n * Creates a function that returns `value`.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {*} value The value to return from the new function.\n * @returns {Function} Returns the new constant function.\n * @example\n *\n * var objects = _.times(2, _.constant({ 'a': 1 }));\n *\n * console.log(objects);\n * // => [{ 'a': 1 }, { 'a': 1 }]\n *\n * console.log(objects[0] === objects[1]);\n * // => true\n */\nfunction constant(value) {\n return function() {\n return value;\n };\n}\n\nexport default constant;\n", "import constant from './constant.js';\nimport defineProperty from './_defineProperty.js';\nimport identity from './identity.js';\n\n/**\n * The base implementation of `setToString` without support for hot loop shorting.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar baseSetToString = !defineProperty ? identity : function(func, string) {\n return defineProperty(func, 'toString', {\n 'configurable': true,\n 'enumerable': false,\n 'value': constant(string),\n 'writable': true\n });\n};\n\nexport default baseSetToString;\n", "/** Used to detect hot functions by number of calls within a span of milliseconds. */\nvar HOT_COUNT = 800,\n HOT_SPAN = 16;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeNow = Date.now;\n\n/**\n * Creates a function that'll short out and invoke `identity` instead\n * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN`\n * milliseconds.\n *\n * @private\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new shortable function.\n */\nfunction shortOut(func) {\n var count = 0,\n lastCalled = 0;\n\n return function() {\n var stamp = nativeNow(),\n remaining = HOT_SPAN - (stamp - lastCalled);\n\n lastCalled = stamp;\n if (remaining > 0) {\n if (++count >= HOT_COUNT) {\n return arguments[0];\n }\n } else {\n count = 0;\n }\n return func.apply(undefined, arguments);\n };\n}\n\nexport default shortOut;\n", "import baseSetToString from './_baseSetToString.js';\nimport shortOut from './_shortOut.js';\n\n/**\n * Sets the `toString` method of `func` to return `string`.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar setToString = shortOut(baseSetToString);\n\nexport default setToString;\n", "import identity from './identity.js';\nimport overRest from './_overRest.js';\nimport setToString from './_setToString.js';\n\n/**\n * The base implementation of `_.rest` which doesn't validate or coerce arguments.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @returns {Function} Returns the new function.\n */\nfunction baseRest(func, start) {\n return setToString(overRest(func, start, identity), func + '');\n}\n\nexport default baseRest;\n", "import eq from './eq.js';\nimport isArrayLike from './isArrayLike.js';\nimport isIndex from './_isIndex.js';\nimport isObject from './isObject.js';\n\n/**\n * Checks if the given arguments are from an iteratee call.\n *\n * @private\n * @param {*} value The potential iteratee value argument.\n * @param {*} index The potential iteratee index or key argument.\n * @param {*} object The potential iteratee object argument.\n * @returns {boolean} Returns `true` if the arguments are from an iteratee call,\n * else `false`.\n */\nfunction isIterateeCall(value, index, object) {\n if (!isObject(object)) {\n return false;\n }\n var type = typeof index;\n if (type == 'number'\n ? (isArrayLike(object) && isIndex(index, object.length))\n : (type == 'string' && index in object)\n ) {\n return eq(object[index], value);\n }\n return false;\n}\n\nexport default isIterateeCall;\n", "import baseRest from './_baseRest.js';\nimport isIterateeCall from './_isIterateeCall.js';\n\n/**\n * Creates a function like `_.assign`.\n *\n * @private\n * @param {Function} assigner The function to assign values.\n * @returns {Function} Returns the new assigner function.\n */\nfunction createAssigner(assigner) {\n return baseRest(function(object, sources) {\n var index = -1,\n length = sources.length,\n customizer = length > 1 ? sources[length - 1] : undefined,\n guard = length > 2 ? sources[2] : undefined;\n\n customizer = (assigner.length > 3 && typeof customizer == 'function')\n ? (length--, customizer)\n : undefined;\n\n if (guard && isIterateeCall(sources[0], sources[1], guard)) {\n customizer = length < 3 ? undefined : customizer;\n length = 1;\n }\n object = Object(object);\n while (++index < length) {\n var source = sources[index];\n if (source) {\n assigner(object, source, index, customizer);\n }\n }\n return object;\n });\n}\n\nexport default createAssigner;\n", "import baseMerge from './_baseMerge.js';\nimport createAssigner from './_createAssigner.js';\n\n/**\n * This method is like `_.assign` except that it recursively merges own and\n * inherited enumerable string keyed properties of source objects into the\n * destination object. Source properties that resolve to `undefined` are\n * skipped if a destination value exists. Array and plain object properties\n * are merged recursively. Other objects and value types are overridden by\n * assignment. Source objects are applied from left to right. Subsequent\n * sources overwrite property assignments of previous sources.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 0.5.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = {\n * 'a': [{ 'b': 2 }, { 'd': 4 }]\n * };\n *\n * var other = {\n * 'a': [{ 'c': 3 }, { 'e': 5 }]\n * };\n *\n * _.merge(object, other);\n * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] }\n */\nvar merge = createAssigner(function(object, source, srcIndex) {\n baseMerge(object, source, srcIndex);\n});\n\nexport default merge;\n", "import overArg from './_overArg.js';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nexport default nativeKeys;\n", "import isPrototype from './_isPrototype.js';\nimport nativeKeys from './_nativeKeys.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default baseKeys;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nexport default DataView;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nexport default Promise;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nexport default Set;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nexport default WeakMap;\n", "import DataView from './_DataView.js';\nimport Map from './_Map.js';\nimport Promise from './_Promise.js';\nimport Set from './_Set.js';\nimport WeakMap from './_WeakMap.js';\nimport baseGetTag from './_baseGetTag.js';\nimport toSource from './_toSource.js';\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nexport default getTag;\n", "import baseKeys from './_baseKeys.js';\nimport getTag from './_getTag.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isArrayLike from './isArrayLike.js';\nimport isBuffer from './isBuffer.js';\nimport isPrototype from './_isPrototype.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n setTag = '[object Set]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if `value` is an empty object, collection, map, or set.\n *\n * Objects are considered empty if they have no own enumerable string keyed\n * properties.\n *\n * Array-like values such as `arguments` objects, arrays, buffers, strings, or\n * jQuery-like collections are considered empty if they have a `length` of `0`.\n * Similarly, maps and sets are considered empty if they have a `size` of `0`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is empty, else `false`.\n * @example\n *\n * _.isEmpty(null);\n * // => true\n *\n * _.isEmpty(true);\n * // => true\n *\n * _.isEmpty(1);\n * // => true\n *\n * _.isEmpty([1, 2, 3]);\n * // => false\n *\n * _.isEmpty({ 'a': 1 });\n * // => false\n */\nfunction isEmpty(value) {\n if (value == null) {\n return true;\n }\n if (isArrayLike(value) &&\n (isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||\n isBuffer(value) || isTypedArray(value) || isArguments(value))) {\n return !value.length;\n }\n var tag = getTag(value);\n if (tag == mapTag || tag == setTag) {\n return !value.size;\n }\n if (isPrototype(value)) {\n return !baseKeys(value).length;\n }\n for (var key in value) {\n if (hasOwnProperty.call(value, key)) {\n return false;\n }\n }\n return true;\n}\n\nexport default isEmpty;\n", "import { dedent } from \"ts-dedent\";\nimport dayjs from \"dayjs\";\nimport { sanitizeUrl } from \"@braintree/sanitize-url\";\nimport { select, curveBasis, curveBasisClosed, curveBasisOpen, curveBumpX, curveBumpY, curveBundle, curveCardinalClosed, curveCardinalOpen, curveCardinal, curveCatmullRomClosed, curveCatmullRomOpen, curveCatmullRom, curveLinear, curveLinearClosed, curveMonotoneX, curveMonotoneY, curveNatural, curveStep, curveStepAfter, curveStepBefore } from \"d3\";\nimport DOMPurify from \"dompurify\";\nimport { adjust, invert, darken, lighten, isDark, rgba } from \"khroma\";\nimport memoize from \"lodash-es/memoize.js\";\nimport merge$1 from \"lodash-es/merge.js\";\nimport { serialize, compile, stringify } from \"stylis\";\nimport isEmpty from \"lodash-es/isEmpty.js\";\nconst LEVELS = {\n trace: 0,\n debug: 1,\n info: 2,\n warn: 3,\n error: 4,\n fatal: 5\n};\nconst log$1 = {\n trace: (..._args) => {\n },\n debug: (..._args) => {\n },\n info: (..._args) => {\n },\n warn: (..._args) => {\n },\n error: (..._args) => {\n },\n fatal: (..._args) => {\n }\n};\nconst setLogLevel$1 = function(level = \"fatal\") {\n let numericLevel = LEVELS.fatal;\n if (typeof level === \"string\") {\n level = level.toLowerCase();\n if (level in LEVELS) {\n numericLevel = LEVELS[level];\n }\n } else if (typeof level === \"number\") {\n numericLevel = level;\n }\n log$1.trace = () => {\n };\n log$1.debug = () => {\n };\n log$1.info = () => {\n };\n log$1.warn = () => {\n };\n log$1.error = () => {\n };\n log$1.fatal = () => {\n };\n if (numericLevel <= LEVELS.fatal) {\n log$1.fatal = console.error ? console.error.bind(console, format(\"FATAL\"), \"color: orange\") : console.log.bind(console, \"\\x1B[35m\", format(\"FATAL\"));\n }\n if (numericLevel <= LEVELS.error) {\n log$1.error = console.error ? console.error.bind(console, format(\"ERROR\"), \"color: orange\") : console.log.bind(console, \"\\x1B[31m\", format(\"ERROR\"));\n }\n if (numericLevel <= LEVELS.warn) {\n log$1.warn = console.warn ? console.warn.bind(console, format(\"WARN\"), \"color: orange\") : console.log.bind(console, `\\x1B[33m`, format(\"WARN\"));\n }\n if (numericLevel <= LEVELS.info) {\n log$1.info = console.info ? console.info.bind(console, format(\"INFO\"), \"color: lightblue\") : console.log.bind(console, \"\\x1B[34m\", format(\"INFO\"));\n }\n if (numericLevel <= LEVELS.debug) {\n log$1.debug = console.debug ? console.debug.bind(console, format(\"DEBUG\"), \"color: lightgreen\") : console.log.bind(console, \"\\x1B[32m\", format(\"DEBUG\"));\n }\n if (numericLevel <= LEVELS.trace) {\n log$1.trace = console.debug ? console.debug.bind(console, format(\"TRACE\"), \"color: lightgreen\") : console.log.bind(console, \"\\x1B[32m\", format(\"TRACE\"));\n }\n};\nconst format = (level) => {\n const time = dayjs().format(\"ss.SSS\");\n return `%c${time} : ${level} : `;\n};\nconst lineBreakRegex = //gi;\nconst getRows = (s) => {\n if (!s) {\n return [\"\"];\n }\n const str2 = breakToPlaceholder(s).replace(/\\\\n/g, \"#br#\");\n return str2.split(\"#br#\");\n};\nconst removeScript = (txt) => {\n return DOMPurify.sanitize(txt);\n};\nconst sanitizeMore = (text, config2) => {\n var _a;\n if (((_a = config2.flowchart) == null ? void 0 : _a.htmlLabels) !== false) {\n const level = config2.securityLevel;\n if (level === \"antiscript\" || level === \"strict\") {\n text = removeScript(text);\n } else if (level !== \"loose\") {\n text = breakToPlaceholder(text);\n text = text.replace(//g, \">\");\n text = text.replace(/=/g, \"=\");\n text = placeholderToBreak(text);\n }\n }\n return text;\n};\nconst sanitizeText$2 = (text, config2) => {\n if (!text) {\n return text;\n }\n if (config2.dompurifyConfig) {\n text = DOMPurify.sanitize(sanitizeMore(text, config2), config2.dompurifyConfig).toString();\n } else {\n text = DOMPurify.sanitize(sanitizeMore(text, config2), {\n FORBID_TAGS: [\"style\"]\n }).toString();\n }\n return text;\n};\nconst sanitizeTextOrArray = (a, config2) => {\n if (typeof a === \"string\") {\n return sanitizeText$2(a, config2);\n }\n return a.flat().map((x) => sanitizeText$2(x, config2));\n};\nconst hasBreaks = (text) => {\n return lineBreakRegex.test(text);\n};\nconst splitBreaks = (text) => {\n return text.split(lineBreakRegex);\n};\nconst placeholderToBreak = (s) => {\n return s.replace(/#br#/g, \"
      \");\n};\nconst breakToPlaceholder = (s) => {\n return s.replace(lineBreakRegex, \"#br#\");\n};\nconst getUrl = (useAbsolute) => {\n let url = \"\";\n if (useAbsolute) {\n url = window.location.protocol + \"//\" + window.location.host + window.location.pathname + window.location.search;\n url = url.replaceAll(/\\(/g, \"\\\\(\");\n url = url.replaceAll(/\\)/g, \"\\\\)\");\n }\n return url;\n};\nconst evaluate = (val) => val === false || [\"false\", \"null\", \"0\"].includes(String(val).trim().toLowerCase()) ? false : true;\nconst getMax = function(...values) {\n const newValues = values.filter((value) => {\n return !isNaN(value);\n });\n return Math.max(...newValues);\n};\nconst getMin = function(...values) {\n const newValues = values.filter((value) => {\n return !isNaN(value);\n });\n return Math.min(...newValues);\n};\nconst parseGenericTypes = function(input) {\n const inputSets = input.split(/(,)/);\n const output = [];\n for (let i = 0; i < inputSets.length; i++) {\n let thisSet = inputSets[i];\n if (thisSet === \",\" && i > 0 && i + 1 < inputSets.length) {\n const previousSet = inputSets[i - 1];\n const nextSet = inputSets[i + 1];\n if (shouldCombineSets(previousSet, nextSet)) {\n thisSet = previousSet + \",\" + nextSet;\n i++;\n output.pop();\n }\n }\n output.push(processSet(thisSet));\n }\n return output.join(\"\");\n};\nconst countOccurrence = (string, substring) => {\n return Math.max(0, string.split(substring).length - 1);\n};\nconst shouldCombineSets = (previousSet, nextSet) => {\n const prevCount = countOccurrence(previousSet, \"~\");\n const nextCount = countOccurrence(nextSet, \"~\");\n return prevCount === 1 && nextCount === 1;\n};\nconst processSet = (input) => {\n const tildeCount = countOccurrence(input, \"~\");\n let hasStartingTilde = false;\n if (tildeCount <= 1) {\n return input;\n }\n if (tildeCount % 2 !== 0 && input.startsWith(\"~\")) {\n input = input.substring(1);\n hasStartingTilde = true;\n }\n const chars = [...input];\n let first = chars.indexOf(\"~\");\n let last = chars.lastIndexOf(\"~\");\n while (first !== -1 && last !== -1 && first !== last) {\n chars[first] = \"<\";\n chars[last] = \">\";\n first = chars.indexOf(\"~\");\n last = chars.lastIndexOf(\"~\");\n }\n if (hasStartingTilde) {\n chars.unshift(\"~\");\n }\n return chars.join(\"\");\n};\nconst common$1 = {\n getRows,\n sanitizeText: sanitizeText$2,\n sanitizeTextOrArray,\n hasBreaks,\n splitBreaks,\n lineBreakRegex,\n removeScript,\n getUrl,\n evaluate,\n getMax,\n getMin\n};\nconst mkBorder = (col, darkMode) => darkMode ? adjust(col, { s: -40, l: 10 }) : adjust(col, { s: -40, l: -10 });\nconst oldAttributeBackgroundColorOdd = \"#ffffff\";\nconst oldAttributeBackgroundColorEven = \"#f2f2f2\";\nlet Theme$4 = class Theme {\n constructor() {\n this.background = \"#f4f4f4\";\n this.primaryColor = \"#fff4dd\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"#333\";\n this.THEME_COLOR_LIMIT = 12;\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.primaryTextColor = this.primaryTextColor || (this.darkMode ? \"#eee\" : \"#333\");\n this.secondaryColor = this.secondaryColor || adjust(this.primaryColor, { h: -120 });\n this.tertiaryColor = this.tertiaryColor || adjust(this.primaryColor, { h: 180, l: 5 });\n this.primaryBorderColor = this.primaryBorderColor || mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = this.secondaryBorderColor || mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = this.tertiaryBorderColor || mkBorder(this.tertiaryColor, this.darkMode);\n this.noteBorderColor = this.noteBorderColor || mkBorder(this.noteBkgColor, this.darkMode);\n this.noteBkgColor = this.noteBkgColor || \"#fff5ad\";\n this.noteTextColor = this.noteTextColor || \"#333\";\n this.secondaryTextColor = this.secondaryTextColor || invert(this.secondaryColor);\n this.tertiaryTextColor = this.tertiaryTextColor || invert(this.tertiaryColor);\n this.lineColor = this.lineColor || invert(this.background);\n this.arrowheadColor = this.arrowheadColor || invert(this.background);\n this.textColor = this.textColor || this.primaryTextColor;\n this.border2 = this.border2 || this.tertiaryBorderColor;\n this.nodeBkg = this.nodeBkg || this.primaryColor;\n this.mainBkg = this.mainBkg || this.primaryColor;\n this.nodeBorder = this.nodeBorder || this.primaryBorderColor;\n this.clusterBkg = this.clusterBkg || this.tertiaryColor;\n this.clusterBorder = this.clusterBorder || this.tertiaryBorderColor;\n this.defaultLinkColor = this.defaultLinkColor || this.lineColor;\n this.titleColor = this.titleColor || this.tertiaryTextColor;\n this.edgeLabelBackground = this.edgeLabelBackground || (this.darkMode ? darken(this.secondaryColor, 30) : this.secondaryColor);\n this.nodeTextColor = this.nodeTextColor || this.primaryTextColor;\n this.actorBorder = this.actorBorder || this.primaryBorderColor;\n this.actorBkg = this.actorBkg || this.mainBkg;\n this.actorTextColor = this.actorTextColor || this.primaryTextColor;\n this.actorLineColor = this.actorLineColor || \"grey\";\n this.labelBoxBkgColor = this.labelBoxBkgColor || this.actorBkg;\n this.signalColor = this.signalColor || this.textColor;\n this.signalTextColor = this.signalTextColor || this.textColor;\n this.labelBoxBorderColor = this.labelBoxBorderColor || this.actorBorder;\n this.labelTextColor = this.labelTextColor || this.actorTextColor;\n this.loopTextColor = this.loopTextColor || this.actorTextColor;\n this.activationBorderColor = this.activationBorderColor || darken(this.secondaryColor, 10);\n this.activationBkgColor = this.activationBkgColor || this.secondaryColor;\n this.sequenceNumberColor = this.sequenceNumberColor || invert(this.lineColor);\n this.sectionBkgColor = this.sectionBkgColor || this.tertiaryColor;\n this.altSectionBkgColor = this.altSectionBkgColor || \"white\";\n this.sectionBkgColor = this.sectionBkgColor || this.secondaryColor;\n this.sectionBkgColor2 = this.sectionBkgColor2 || this.primaryColor;\n this.excludeBkgColor = this.excludeBkgColor || \"#eeeeee\";\n this.taskBorderColor = this.taskBorderColor || this.primaryBorderColor;\n this.taskBkgColor = this.taskBkgColor || this.primaryColor;\n this.activeTaskBorderColor = this.activeTaskBorderColor || this.primaryColor;\n this.activeTaskBkgColor = this.activeTaskBkgColor || lighten(this.primaryColor, 23);\n this.gridColor = this.gridColor || \"lightgrey\";\n this.doneTaskBkgColor = this.doneTaskBkgColor || \"lightgrey\";\n this.doneTaskBorderColor = this.doneTaskBorderColor || \"grey\";\n this.critBorderColor = this.critBorderColor || \"#ff8888\";\n this.critBkgColor = this.critBkgColor || \"red\";\n this.todayLineColor = this.todayLineColor || \"red\";\n this.taskTextColor = this.taskTextColor || this.textColor;\n this.taskTextOutsideColor = this.taskTextOutsideColor || this.textColor;\n this.taskTextLightColor = this.taskTextLightColor || this.textColor;\n this.taskTextColor = this.taskTextColor || this.primaryTextColor;\n this.taskTextDarkColor = this.taskTextDarkColor || this.textColor;\n this.taskTextClickableColor = this.taskTextClickableColor || \"#003163\";\n this.personBorder = this.personBorder || this.primaryBorderColor;\n this.personBkg = this.personBkg || this.mainBkg;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || this.tertiaryColor;\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.nodeBorder;\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.specialStateColor = this.lineColor;\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210, l: 150 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n if (this.darkMode) {\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 75);\n }\n } else {\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 25);\n }\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || invert(this[\"cScale\" + i]);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n if (this.darkMode) {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || lighten(this[\"cScale\" + i], 10);\n } else {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 10);\n }\n }\n this.scaleLabelColor = this.scaleLabelColor || this.labelTextColor;\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n const multiplier = this.darkMode ? -4 : -1;\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 180, s: -15, l: multiplier * (5 + i * 3) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 180, s: -15, l: multiplier * (8 + i * 3) });\n }\n this.classText = this.classText || this.textColor;\n this.fillType0 = this.fillType0 || this.primaryColor;\n this.fillType1 = this.fillType1 || this.secondaryColor;\n this.fillType2 = this.fillType2 || adjust(this.primaryColor, { h: 64 });\n this.fillType3 = this.fillType3 || adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = this.fillType4 || adjust(this.primaryColor, { h: -64 });\n this.fillType5 = this.fillType5 || adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = this.fillType6 || adjust(this.primaryColor, { h: 128 });\n this.fillType7 = this.fillType7 || adjust(this.secondaryColor, { h: 128 });\n this.pie1 = this.pie1 || this.primaryColor;\n this.pie2 = this.pie2 || this.secondaryColor;\n this.pie3 = this.pie3 || this.tertiaryColor;\n this.pie4 = this.pie4 || adjust(this.primaryColor, { l: -10 });\n this.pie5 = this.pie5 || adjust(this.secondaryColor, { l: -10 });\n this.pie6 = this.pie6 || adjust(this.tertiaryColor, { l: -10 });\n this.pie7 = this.pie7 || adjust(this.primaryColor, { h: 60, l: -10 });\n this.pie8 = this.pie8 || adjust(this.primaryColor, { h: -60, l: -10 });\n this.pie9 = this.pie9 || adjust(this.primaryColor, { h: 120, l: 0 });\n this.pie10 = this.pie10 || adjust(this.primaryColor, { h: 60, l: -20 });\n this.pie11 = this.pie11 || adjust(this.primaryColor, { h: -60, l: -20 });\n this.pie12 = this.pie12 || adjust(this.primaryColor, { h: 120, l: -10 });\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || (this.darkMode ? darken(this.secondaryColor, 30) : this.secondaryColor);\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = this.git0 || this.primaryColor;\n this.git1 = this.git1 || this.secondaryColor;\n this.git2 = this.git2 || this.tertiaryColor;\n this.git3 = this.git3 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.git4 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.git5 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.git6 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.git7 || adjust(this.primaryColor, { h: 120 });\n if (this.darkMode) {\n this.git0 = lighten(this.git0, 25);\n this.git1 = lighten(this.git1, 25);\n this.git2 = lighten(this.git2, 25);\n this.git3 = lighten(this.git3, 25);\n this.git4 = lighten(this.git4, 25);\n this.git5 = lighten(this.git5, 25);\n this.git6 = lighten(this.git6, 25);\n this.git7 = lighten(this.git7, 25);\n } else {\n this.git0 = darken(this.git0, 25);\n this.git1 = darken(this.git1, 25);\n this.git2 = darken(this.git2, 25);\n this.git3 = darken(this.git3, 25);\n this.git4 = darken(this.git4, 25);\n this.git5 = darken(this.git5, 25);\n this.git6 = darken(this.git6, 25);\n this.git7 = darken(this.git7, 25);\n }\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.branchLabelColor = this.branchLabelColor || (this.darkMode ? \"black\" : this.labelTextColor);\n this.gitBranchLabel0 = this.gitBranchLabel0 || this.branchLabelColor;\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.branchLabelColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.branchLabelColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || this.branchLabelColor;\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.branchLabelColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.branchLabelColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.branchLabelColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.branchLabelColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$4 = (userOverrides) => {\n const theme2 = new Theme$4();\n theme2.calculate(userOverrides);\n return theme2;\n};\nlet Theme$3 = class Theme2 {\n constructor() {\n this.background = \"#333\";\n this.primaryColor = \"#1f2020\";\n this.secondaryColor = lighten(this.primaryColor, 16);\n this.tertiaryColor = adjust(this.primaryColor, { h: -160 });\n this.primaryBorderColor = invert(this.background);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.tertiaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.mainBkg = \"#1f2020\";\n this.secondBkg = \"calculated\";\n this.mainContrastColor = \"lightgrey\";\n this.darkTextColor = lighten(invert(\"#323D47\"), 10);\n this.lineColor = \"calculated\";\n this.border1 = \"#81B1DB\";\n this.border2 = rgba(255, 255, 255, 0.25);\n this.arrowheadColor = \"calculated\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.labelBackground = \"#181818\";\n this.textColor = \"#ccc\";\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"#F9FFFE\";\n this.edgeLabelBackground = \"calculated\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"calculated\";\n this.actorLineColor = \"calculated\";\n this.signalColor = \"calculated\";\n this.signalTextColor = \"calculated\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"calculated\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"calculated\";\n this.activationBkgColor = \"calculated\";\n this.sequenceNumberColor = \"black\";\n this.sectionBkgColor = darken(\"#EAE8D9\", 30);\n this.altSectionBkgColor = \"calculated\";\n this.sectionBkgColor2 = \"#EAE8D9\";\n this.excludeBkgColor = darken(this.sectionBkgColor, 10);\n this.taskBorderColor = rgba(255, 255, 255, 70);\n this.taskBkgColor = \"calculated\";\n this.taskTextColor = \"calculated\";\n this.taskTextLightColor = \"calculated\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = rgba(255, 255, 255, 50);\n this.activeTaskBkgColor = \"#81B1DB\";\n this.gridColor = \"calculated\";\n this.doneTaskBkgColor = \"calculated\";\n this.doneTaskBorderColor = \"grey\";\n this.critBorderColor = \"#E83737\";\n this.critBkgColor = \"#E83737\";\n this.taskTextDarkColor = \"calculated\";\n this.todayLineColor = \"#DB5757\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"calculated\";\n this.errorBkgColor = \"#a44141\";\n this.errorTextColor = \"#ddd\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.secondBkg = lighten(this.mainBkg, 16);\n this.lineColor = this.mainContrastColor;\n this.arrowheadColor = this.mainContrastColor;\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.edgeLabelBackground = lighten(this.labelBackground, 25);\n this.actorBorder = this.border1;\n this.actorBkg = this.mainBkg;\n this.actorTextColor = this.mainContrastColor;\n this.actorLineColor = this.mainContrastColor;\n this.signalColor = this.mainContrastColor;\n this.signalTextColor = this.mainContrastColor;\n this.labelBoxBkgColor = this.actorBkg;\n this.labelBoxBorderColor = this.actorBorder;\n this.labelTextColor = this.mainContrastColor;\n this.loopTextColor = this.mainContrastColor;\n this.noteBorderColor = this.secondaryBorderColor;\n this.noteBkgColor = this.secondBkg;\n this.noteTextColor = this.secondaryTextColor;\n this.activationBorderColor = this.border1;\n this.activationBkgColor = this.secondBkg;\n this.altSectionBkgColor = this.background;\n this.taskBkgColor = lighten(this.mainBkg, 23);\n this.taskTextColor = this.darkTextColor;\n this.taskTextLightColor = this.mainContrastColor;\n this.taskTextOutsideColor = this.taskTextLightColor;\n this.gridColor = this.mainContrastColor;\n this.doneTaskBkgColor = this.mainContrastColor;\n this.taskTextDarkColor = this.darkTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#555\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.primaryBorderColor;\n this.specialStateColor = \"#f4f4f4\";\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n this.cScale1 = this.cScale1 || \"#0b0000\";\n this.cScale2 = this.cScale2 || \"#4d1037\";\n this.cScale3 = this.cScale3 || \"#3f5258\";\n this.cScale4 = this.cScale4 || \"#4f2f1b\";\n this.cScale5 = this.cScale5 || \"#6e0a0a\";\n this.cScale6 = this.cScale6 || \"#3b0048\";\n this.cScale7 = this.cScale7 || \"#995a01\";\n this.cScale8 = this.cScale8 || \"#154706\";\n this.cScale9 = this.cScale9 || \"#161722\";\n this.cScale10 = this.cScale10 || \"#00296f\";\n this.cScale11 = this.cScale11 || \"#01629c\";\n this.cScale12 = this.cScale12 || \"#010029\";\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || invert(this[\"cScale\" + i]);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || lighten(this[\"cScale\" + i], 10);\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(-10 + i * 4) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(-7 + i * 4) });\n }\n this.scaleLabelColor = this.scaleLabelColor || (this.darkMode ? \"black\" : this.labelTextColor);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"pie\" + i] = this[\"cScale\" + i];\n }\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22\"\n };\n this.classText = this.primaryTextColor;\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || (this.darkMode ? darken(this.secondaryColor, 30) : this.secondaryColor);\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = lighten(this.secondaryColor, 20);\n this.git1 = lighten(this.pie2 || this.secondaryColor, 20);\n this.git2 = lighten(this.pie3 || this.tertiaryColor, 20);\n this.git3 = lighten(this.pie4 || adjust(this.primaryColor, { h: -30 }), 20);\n this.git4 = lighten(this.pie5 || adjust(this.primaryColor, { h: -60 }), 20);\n this.git5 = lighten(this.pie6 || adjust(this.primaryColor, { h: -90 }), 10);\n this.git6 = lighten(this.pie7 || adjust(this.primaryColor, { h: 60 }), 10);\n this.git7 = lighten(this.pie8 || adjust(this.primaryColor, { h: 120 }), 20);\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.gitBranchLabel0 = this.gitBranchLabel0 || invert(this.labelTextColor);\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.labelTextColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.labelTextColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || invert(this.labelTextColor);\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.labelTextColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.labelTextColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.labelTextColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.labelTextColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || lighten(this.background, 12);\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || lighten(this.background, 2);\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$3 = (userOverrides) => {\n const theme2 = new Theme$3();\n theme2.calculate(userOverrides);\n return theme2;\n};\nlet Theme$2 = class Theme3 {\n constructor() {\n this.background = \"#f4f4f4\";\n this.primaryColor = \"#ECECFF\";\n this.secondaryColor = adjust(this.primaryColor, { h: 120 });\n this.secondaryColor = \"#ffffde\";\n this.tertiaryColor = adjust(this.primaryColor, { h: -160 });\n this.primaryBorderColor = mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.tertiaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.background = \"white\";\n this.mainBkg = \"#ECECFF\";\n this.secondBkg = \"#ffffde\";\n this.lineColor = \"#333333\";\n this.border1 = \"#9370DB\";\n this.border2 = \"#aaaa33\";\n this.arrowheadColor = \"#333333\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.labelBackground = \"#e8e8e8\";\n this.textColor = \"#333\";\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"calculated\";\n this.edgeLabelBackground = \"calculated\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"black\";\n this.actorLineColor = \"grey\";\n this.signalColor = \"calculated\";\n this.signalTextColor = \"calculated\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"calculated\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"#666\";\n this.activationBkgColor = \"#f4f4f4\";\n this.sequenceNumberColor = \"white\";\n this.sectionBkgColor = \"calculated\";\n this.altSectionBkgColor = \"calculated\";\n this.sectionBkgColor2 = \"calculated\";\n this.excludeBkgColor = \"#eeeeee\";\n this.taskBorderColor = \"calculated\";\n this.taskBkgColor = \"calculated\";\n this.taskTextLightColor = \"calculated\";\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextDarkColor = \"calculated\";\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.taskTextClickableColor = \"calculated\";\n this.activeTaskBorderColor = \"calculated\";\n this.activeTaskBkgColor = \"calculated\";\n this.gridColor = \"calculated\";\n this.doneTaskBkgColor = \"calculated\";\n this.doneTaskBorderColor = \"calculated\";\n this.critBorderColor = \"calculated\";\n this.critBkgColor = \"calculated\";\n this.todayLineColor = \"calculated\";\n this.sectionBkgColor = rgba(102, 102, 255, 0.49);\n this.altSectionBkgColor = \"white\";\n this.sectionBkgColor2 = \"#fff400\";\n this.taskBorderColor = \"#534fbc\";\n this.taskBkgColor = \"#8a90dd\";\n this.taskTextLightColor = \"white\";\n this.taskTextColor = \"calculated\";\n this.taskTextDarkColor = \"black\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = \"#534fbc\";\n this.activeTaskBkgColor = \"#bfc7ff\";\n this.gridColor = \"lightgrey\";\n this.doneTaskBkgColor = \"lightgrey\";\n this.doneTaskBorderColor = \"grey\";\n this.critBorderColor = \"#ff8888\";\n this.critBkgColor = \"red\";\n this.todayLineColor = \"red\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"black\";\n this.errorBkgColor = \"#552222\";\n this.errorTextColor = \"#552222\";\n this.updateColors();\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n this[\"cScalePeer1\"] = this[\"cScalePeer1\"] || darken(this.secondaryColor, 45);\n this[\"cScalePeer2\"] = this[\"cScalePeer2\"] || darken(this.tertiaryColor, 40);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 10);\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 25);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || adjust(this[\"cScale\" + i], { h: 180 });\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 30, l: -(5 + i * 5) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 30, l: -(7 + i * 5) });\n }\n this.scaleLabelColor = this.scaleLabelColor !== \"calculated\" && this.scaleLabelColor ? this.scaleLabelColor : this.labelTextColor;\n if (this.labelTextColor !== \"calculated\") {\n this.cScaleLabel0 = this.cScaleLabel0 || invert(this.labelTextColor);\n this.cScaleLabel3 = this.cScaleLabel3 || invert(this.labelTextColor);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.labelTextColor;\n }\n }\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.titleColor = this.textColor;\n this.edgeLabelBackground = this.labelBackground;\n this.actorBorder = lighten(this.border1, 23);\n this.actorBkg = this.mainBkg;\n this.labelBoxBkgColor = this.actorBkg;\n this.signalColor = this.textColor;\n this.signalTextColor = this.textColor;\n this.labelBoxBorderColor = this.actorBorder;\n this.labelTextColor = this.actorTextColor;\n this.loopTextColor = this.actorTextColor;\n this.noteBorderColor = this.border2;\n this.noteTextColor = this.actorTextColor;\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#f0f0f0\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.nodeBorder;\n this.specialStateColor = this.lineColor;\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.classText = this.primaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n this.pie1 = this.pie1 || this.primaryColor;\n this.pie2 = this.pie2 || this.secondaryColor;\n this.pie3 = this.pie3 || adjust(this.tertiaryColor, { l: -40 });\n this.pie4 = this.pie4 || adjust(this.primaryColor, { l: -10 });\n this.pie5 = this.pie5 || adjust(this.secondaryColor, { l: -30 });\n this.pie6 = this.pie6 || adjust(this.tertiaryColor, { l: -20 });\n this.pie7 = this.pie7 || adjust(this.primaryColor, { h: 60, l: -20 });\n this.pie8 = this.pie8 || adjust(this.primaryColor, { h: -60, l: -40 });\n this.pie9 = this.pie9 || adjust(this.primaryColor, { h: 120, l: -40 });\n this.pie10 = this.pie10 || adjust(this.primaryColor, { h: 60, l: -40 });\n this.pie11 = this.pie11 || adjust(this.primaryColor, { h: -90, l: -40 });\n this.pie12 = this.pie12 || adjust(this.primaryColor, { h: 120, l: -30 });\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || this.labelBackground;\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = this.git0 || this.primaryColor;\n this.git1 = this.git1 || this.secondaryColor;\n this.git2 = this.git2 || this.tertiaryColor;\n this.git3 = this.git3 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.git4 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.git5 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.git6 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.git7 || adjust(this.primaryColor, { h: 120 });\n if (this.darkMode) {\n this.git0 = lighten(this.git0, 25);\n this.git1 = lighten(this.git1, 25);\n this.git2 = lighten(this.git2, 25);\n this.git3 = lighten(this.git3, 25);\n this.git4 = lighten(this.git4, 25);\n this.git5 = lighten(this.git5, 25);\n this.git6 = lighten(this.git6, 25);\n this.git7 = lighten(this.git7, 25);\n } else {\n this.git0 = darken(this.git0, 25);\n this.git1 = darken(this.git1, 25);\n this.git2 = darken(this.git2, 25);\n this.git3 = darken(this.git3, 25);\n this.git4 = darken(this.git4, 25);\n this.git5 = darken(this.git5, 25);\n this.git6 = darken(this.git6, 25);\n this.git7 = darken(this.git7, 25);\n }\n this.gitInv0 = this.gitInv0 || darken(invert(this.git0), 25);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.gitBranchLabel0 = this.gitBranchLabel0 || invert(this.labelTextColor);\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.labelTextColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.labelTextColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || invert(this.labelTextColor);\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.labelTextColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.labelTextColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.labelTextColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.labelTextColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$2 = (userOverrides) => {\n const theme2 = new Theme$2();\n theme2.calculate(userOverrides);\n return theme2;\n};\nlet Theme$1 = class Theme4 {\n constructor() {\n this.background = \"#f4f4f4\";\n this.primaryColor = \"#cde498\";\n this.secondaryColor = \"#cdffb2\";\n this.background = \"white\";\n this.mainBkg = \"#cde498\";\n this.secondBkg = \"#cdffb2\";\n this.lineColor = \"green\";\n this.border1 = \"#13540c\";\n this.border2 = \"#6eaa49\";\n this.arrowheadColor = \"green\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.tertiaryColor = lighten(\"#cde498\", 10);\n this.primaryBorderColor = mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.primaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"#333\";\n this.edgeLabelBackground = \"#e8e8e8\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"black\";\n this.actorLineColor = \"grey\";\n this.signalColor = \"#333\";\n this.signalTextColor = \"#333\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"#326932\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"#666\";\n this.activationBkgColor = \"#f4f4f4\";\n this.sequenceNumberColor = \"white\";\n this.sectionBkgColor = \"#6eaa49\";\n this.altSectionBkgColor = \"white\";\n this.sectionBkgColor2 = \"#6eaa49\";\n this.excludeBkgColor = \"#eeeeee\";\n this.taskBorderColor = \"calculated\";\n this.taskBkgColor = \"#487e3a\";\n this.taskTextLightColor = \"white\";\n this.taskTextColor = \"calculated\";\n this.taskTextDarkColor = \"black\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = \"calculated\";\n this.activeTaskBkgColor = \"calculated\";\n this.gridColor = \"lightgrey\";\n this.doneTaskBkgColor = \"lightgrey\";\n this.doneTaskBorderColor = \"grey\";\n this.critBorderColor = \"#ff8888\";\n this.critBkgColor = \"red\";\n this.todayLineColor = \"red\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"black\";\n this.errorBkgColor = \"#552222\";\n this.errorTextColor = \"#552222\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.actorBorder = darken(this.mainBkg, 20);\n this.actorBkg = this.mainBkg;\n this.labelBoxBkgColor = this.actorBkg;\n this.labelTextColor = this.actorTextColor;\n this.loopTextColor = this.actorTextColor;\n this.noteBorderColor = this.border2;\n this.noteTextColor = this.actorTextColor;\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n this[\"cScalePeer1\"] = this[\"cScalePeer1\"] || darken(this.secondaryColor, 45);\n this[\"cScalePeer2\"] = this[\"cScalePeer2\"] || darken(this.tertiaryColor, 40);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 10);\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 25);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || adjust(this[\"cScale\" + i], { h: 180 });\n }\n this.scaleLabelColor = this.scaleLabelColor !== \"calculated\" && this.scaleLabelColor ? this.scaleLabelColor : this.labelTextColor;\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(5 + i * 5) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(8 + i * 5) });\n }\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.taskBorderColor = this.border1;\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.activeTaskBorderColor = this.taskBorderColor;\n this.activeTaskBkgColor = this.mainBkg;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#f0f0f0\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.primaryBorderColor;\n this.specialStateColor = this.lineColor;\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.classText = this.primaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n this.pie1 = this.pie1 || this.primaryColor;\n this.pie2 = this.pie2 || this.secondaryColor;\n this.pie3 = this.pie3 || this.tertiaryColor;\n this.pie4 = this.pie4 || adjust(this.primaryColor, { l: -30 });\n this.pie5 = this.pie5 || adjust(this.secondaryColor, { l: -30 });\n this.pie6 = this.pie6 || adjust(this.tertiaryColor, { h: 40, l: -40 });\n this.pie7 = this.pie7 || adjust(this.primaryColor, { h: 60, l: -10 });\n this.pie8 = this.pie8 || adjust(this.primaryColor, { h: -60, l: -10 });\n this.pie9 = this.pie9 || adjust(this.primaryColor, { h: 120, l: 0 });\n this.pie10 = this.pie10 || adjust(this.primaryColor, { h: 60, l: -50 });\n this.pie11 = this.pie11 || adjust(this.primaryColor, { h: -60, l: -50 });\n this.pie12 = this.pie12 || adjust(this.primaryColor, { h: 120, l: -50 });\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || this.edgeLabelBackground;\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = this.git0 || this.primaryColor;\n this.git1 = this.git1 || this.secondaryColor;\n this.git2 = this.git2 || this.tertiaryColor;\n this.git3 = this.git3 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.git4 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.git5 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.git6 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.git7 || adjust(this.primaryColor, { h: 120 });\n if (this.darkMode) {\n this.git0 = lighten(this.git0, 25);\n this.git1 = lighten(this.git1, 25);\n this.git2 = lighten(this.git2, 25);\n this.git3 = lighten(this.git3, 25);\n this.git4 = lighten(this.git4, 25);\n this.git5 = lighten(this.git5, 25);\n this.git6 = lighten(this.git6, 25);\n this.git7 = lighten(this.git7, 25);\n } else {\n this.git0 = darken(this.git0, 25);\n this.git1 = darken(this.git1, 25);\n this.git2 = darken(this.git2, 25);\n this.git3 = darken(this.git3, 25);\n this.git4 = darken(this.git4, 25);\n this.git5 = darken(this.git5, 25);\n this.git6 = darken(this.git6, 25);\n this.git7 = darken(this.git7, 25);\n }\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.gitBranchLabel0 = this.gitBranchLabel0 || invert(this.labelTextColor);\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.labelTextColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.labelTextColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || invert(this.labelTextColor);\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.labelTextColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.labelTextColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.labelTextColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.labelTextColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$1 = (userOverrides) => {\n const theme2 = new Theme$1();\n theme2.calculate(userOverrides);\n return theme2;\n};\nclass Theme5 {\n constructor() {\n this.primaryColor = \"#eee\";\n this.contrast = \"#707070\";\n this.secondaryColor = lighten(this.contrast, 55);\n this.background = \"#ffffff\";\n this.tertiaryColor = adjust(this.primaryColor, { h: -160 });\n this.primaryBorderColor = mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.tertiaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.mainBkg = \"#eee\";\n this.secondBkg = \"calculated\";\n this.lineColor = \"#666\";\n this.border1 = \"#999\";\n this.border2 = \"calculated\";\n this.note = \"#ffa\";\n this.text = \"#333\";\n this.critical = \"#d42\";\n this.done = \"#bbb\";\n this.arrowheadColor = \"#333333\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"calculated\";\n this.edgeLabelBackground = \"white\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"calculated\";\n this.actorLineColor = \"calculated\";\n this.signalColor = \"calculated\";\n this.signalTextColor = \"calculated\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"calculated\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"calculated\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"#666\";\n this.activationBkgColor = \"#f4f4f4\";\n this.sequenceNumberColor = \"white\";\n this.sectionBkgColor = \"calculated\";\n this.altSectionBkgColor = \"white\";\n this.sectionBkgColor2 = \"calculated\";\n this.excludeBkgColor = \"#eeeeee\";\n this.taskBorderColor = \"calculated\";\n this.taskBkgColor = \"calculated\";\n this.taskTextLightColor = \"white\";\n this.taskTextColor = \"calculated\";\n this.taskTextDarkColor = \"calculated\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = \"calculated\";\n this.activeTaskBkgColor = \"calculated\";\n this.gridColor = \"calculated\";\n this.doneTaskBkgColor = \"calculated\";\n this.doneTaskBorderColor = \"calculated\";\n this.critBkgColor = \"calculated\";\n this.critBorderColor = \"calculated\";\n this.todayLineColor = \"calculated\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"black\";\n this.errorBkgColor = \"#552222\";\n this.errorTextColor = \"#552222\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.secondBkg = lighten(this.contrast, 55);\n this.border2 = this.contrast;\n this.actorBorder = lighten(this.border1, 23);\n this.actorBkg = this.mainBkg;\n this.actorTextColor = this.text;\n this.actorLineColor = this.lineColor;\n this.signalColor = this.text;\n this.signalTextColor = this.text;\n this.labelBoxBkgColor = this.actorBkg;\n this.labelBoxBorderColor = this.actorBorder;\n this.labelTextColor = this.text;\n this.loopTextColor = this.text;\n this.noteBorderColor = \"#999\";\n this.noteBkgColor = \"#666\";\n this.noteTextColor = \"#fff\";\n this.cScale0 = this.cScale0 || \"#555\";\n this.cScale1 = this.cScale1 || \"#F4F4F4\";\n this.cScale2 = this.cScale2 || \"#555\";\n this.cScale3 = this.cScale3 || \"#BBB\";\n this.cScale4 = this.cScale4 || \"#777\";\n this.cScale5 = this.cScale5 || \"#999\";\n this.cScale6 = this.cScale6 || \"#DDD\";\n this.cScale7 = this.cScale7 || \"#FFF\";\n this.cScale8 = this.cScale8 || \"#DDD\";\n this.cScale9 = this.cScale9 || \"#BBB\";\n this.cScale10 = this.cScale10 || \"#999\";\n this.cScale11 = this.cScale11 || \"#777\";\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || invert(this[\"cScale\" + i]);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n if (this.darkMode) {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || lighten(this[\"cScale\" + i], 10);\n } else {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 10);\n }\n }\n this.scaleLabelColor = this.scaleLabelColor || (this.darkMode ? \"black\" : this.labelTextColor);\n this[\"cScaleLabel0\"] = this[\"cScaleLabel0\"] || this.cScale1;\n this[\"cScaleLabel2\"] = this[\"cScaleLabel2\"] || this.cScale1;\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { l: -(5 + i * 5) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { l: -(8 + i * 5) });\n }\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.titleColor = this.text;\n this.sectionBkgColor = lighten(this.contrast, 30);\n this.sectionBkgColor2 = lighten(this.contrast, 30);\n this.taskBorderColor = darken(this.contrast, 10);\n this.taskBkgColor = this.contrast;\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextDarkColor = this.text;\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.activeTaskBorderColor = this.taskBorderColor;\n this.activeTaskBkgColor = this.mainBkg;\n this.gridColor = lighten(this.border1, 30);\n this.doneTaskBkgColor = this.done;\n this.doneTaskBorderColor = this.lineColor;\n this.critBkgColor = this.critical;\n this.critBorderColor = darken(this.critBkgColor, 10);\n this.todayLineColor = this.critBkgColor;\n this.transitionColor = this.transitionColor || \"#000\";\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#f4f4f4\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.stateBorder = this.stateBorder || \"#000\";\n this.innerEndBackground = this.primaryBorderColor;\n this.specialStateColor = \"#222\";\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.classText = this.primaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"pie\" + i] = this[\"cScale\" + i];\n }\n this.pie12 = this.pie0;\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || this.edgeLabelBackground;\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = darken(this.pie1, 25) || this.primaryColor;\n this.git1 = this.pie2 || this.secondaryColor;\n this.git2 = this.pie3 || this.tertiaryColor;\n this.git3 = this.pie4 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.pie5 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.pie6 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.pie7 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.pie8 || adjust(this.primaryColor, { h: 120 });\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.branchLabelColor = this.branchLabelColor || this.labelTextColor;\n this.gitBranchLabel0 = this.branchLabelColor;\n this.gitBranchLabel1 = \"white\";\n this.gitBranchLabel2 = this.branchLabelColor;\n this.gitBranchLabel3 = \"white\";\n this.gitBranchLabel4 = this.branchLabelColor;\n this.gitBranchLabel5 = this.branchLabelColor;\n this.gitBranchLabel6 = this.branchLabelColor;\n this.gitBranchLabel7 = this.branchLabelColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n}\nconst getThemeVariables = (userOverrides) => {\n const theme2 = new Theme5();\n theme2.calculate(userOverrides);\n return theme2;\n};\nconst theme = {\n base: {\n getThemeVariables: getThemeVariables$4\n },\n dark: {\n getThemeVariables: getThemeVariables$3\n },\n default: {\n getThemeVariables: getThemeVariables$2\n },\n forest: {\n getThemeVariables: getThemeVariables$1\n },\n neutral: {\n getThemeVariables\n }\n};\nconst defaultConfigJson = {\n \"flowchart\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"diagramPadding\": 8,\n \"htmlLabels\": true,\n \"nodeSpacing\": 50,\n \"rankSpacing\": 50,\n \"curve\": \"basis\",\n \"padding\": 15,\n \"defaultRenderer\": \"dagre-wrapper\",\n \"wrappingWidth\": 200\n },\n \"sequence\": {\n \"useMaxWidth\": true,\n \"hideUnusedParticipants\": false,\n \"activationWidth\": 10,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"actorMargin\": 50,\n \"width\": 150,\n \"height\": 65,\n \"boxMargin\": 10,\n \"boxTextMargin\": 5,\n \"noteMargin\": 10,\n \"messageMargin\": 35,\n \"messageAlign\": \"center\",\n \"mirrorActors\": true,\n \"forceMenus\": false,\n \"bottomMarginAdj\": 1,\n \"rightAngles\": false,\n \"showSequenceNumbers\": false,\n \"actorFontSize\": 14,\n \"actorFontFamily\": '\"Open Sans\", sans-serif',\n \"actorFontWeight\": 400,\n \"noteFontSize\": 14,\n \"noteFontFamily\": '\"trebuchet ms\", verdana, arial, sans-serif',\n \"noteFontWeight\": 400,\n \"noteAlign\": \"center\",\n \"messageFontSize\": 16,\n \"messageFontFamily\": '\"trebuchet ms\", verdana, arial, sans-serif',\n \"messageFontWeight\": 400,\n \"wrap\": false,\n \"wrapPadding\": 10,\n \"labelBoxWidth\": 50,\n \"labelBoxHeight\": 20\n },\n \"gantt\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"barHeight\": 20,\n \"barGap\": 4,\n \"topPadding\": 50,\n \"rightPadding\": 75,\n \"leftPadding\": 75,\n \"gridLineStartPadding\": 35,\n \"fontSize\": 11,\n \"sectionFontSize\": 11,\n \"numberSectionStyles\": 4,\n \"axisFormat\": \"%Y-%m-%d\",\n \"topAxis\": false,\n \"displayMode\": \"\",\n \"weekday\": \"sunday\"\n },\n \"journey\": {\n \"useMaxWidth\": true,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"leftMargin\": 150,\n \"width\": 150,\n \"height\": 50,\n \"boxMargin\": 10,\n \"boxTextMargin\": 5,\n \"noteMargin\": 10,\n \"messageMargin\": 35,\n \"messageAlign\": \"center\",\n \"bottomMarginAdj\": 1,\n \"rightAngles\": false,\n \"taskFontSize\": 14,\n \"taskFontFamily\": '\"Open Sans\", sans-serif',\n \"taskMargin\": 50,\n \"activationWidth\": 10,\n \"textPlacement\": \"fo\",\n \"actorColours\": [\n \"#8FBC8F\",\n \"#7CFC00\",\n \"#00FFFF\",\n \"#20B2AA\",\n \"#B0E0E6\",\n \"#FFFFE0\"\n ],\n \"sectionFills\": [\n \"#191970\",\n \"#8B008B\",\n \"#4B0082\",\n \"#2F4F4F\",\n \"#800000\",\n \"#8B4513\",\n \"#00008B\"\n ],\n \"sectionColours\": [\n \"#fff\"\n ]\n },\n \"class\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"arrowMarkerAbsolute\": false,\n \"dividerMargin\": 10,\n \"padding\": 5,\n \"textHeight\": 10,\n \"defaultRenderer\": \"dagre-wrapper\",\n \"htmlLabels\": false\n },\n \"state\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"dividerMargin\": 10,\n \"sizeUnit\": 5,\n \"padding\": 8,\n \"textHeight\": 10,\n \"titleShift\": -15,\n \"noteMargin\": 10,\n \"forkWidth\": 70,\n \"forkHeight\": 7,\n \"miniPadding\": 2,\n \"fontSizeFactor\": 5.02,\n \"fontSize\": 24,\n \"labelHeight\": 16,\n \"edgeLengthFactor\": \"20\",\n \"compositTitleSize\": 35,\n \"radius\": 5,\n \"defaultRenderer\": \"dagre-wrapper\"\n },\n \"er\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"diagramPadding\": 20,\n \"layoutDirection\": \"TB\",\n \"minEntityWidth\": 100,\n \"minEntityHeight\": 75,\n \"entityPadding\": 15,\n \"stroke\": \"gray\",\n \"fill\": \"honeydew\",\n \"fontSize\": 12\n },\n \"pie\": {\n \"useMaxWidth\": true,\n \"textPosition\": 0.75\n },\n \"quadrantChart\": {\n \"useMaxWidth\": true,\n \"chartWidth\": 500,\n \"chartHeight\": 500,\n \"titleFontSize\": 20,\n \"titlePadding\": 10,\n \"quadrantPadding\": 5,\n \"xAxisLabelPadding\": 5,\n \"yAxisLabelPadding\": 5,\n \"xAxisLabelFontSize\": 16,\n \"yAxisLabelFontSize\": 16,\n \"quadrantLabelFontSize\": 16,\n \"quadrantTextTopPadding\": 5,\n \"pointTextPadding\": 5,\n \"pointLabelFontSize\": 12,\n \"pointRadius\": 5,\n \"xAxisPosition\": \"top\",\n \"yAxisPosition\": \"left\",\n \"quadrantInternalBorderStrokeWidth\": 1,\n \"quadrantExternalBorderStrokeWidth\": 2\n },\n \"xyChart\": {\n \"useMaxWidth\": true,\n \"width\": 700,\n \"height\": 500,\n \"titleFontSize\": 20,\n \"titlePadding\": 10,\n \"showTitle\": true,\n \"xAxis\": {\n \"$ref\": \"#/$defs/XYChartAxisConfig\",\n \"showLabel\": true,\n \"labelFontSize\": 14,\n \"labelPadding\": 5,\n \"showTitle\": true,\n \"titleFontSize\": 16,\n \"titlePadding\": 5,\n \"showTick\": true,\n \"tickLength\": 5,\n \"tickWidth\": 2,\n \"showAxisLine\": true,\n \"axisLineWidth\": 2\n },\n \"yAxis\": {\n \"$ref\": \"#/$defs/XYChartAxisConfig\",\n \"showLabel\": true,\n \"labelFontSize\": 14,\n \"labelPadding\": 5,\n \"showTitle\": true,\n \"titleFontSize\": 16,\n \"titlePadding\": 5,\n \"showTick\": true,\n \"tickLength\": 5,\n \"tickWidth\": 2,\n \"showAxisLine\": true,\n \"axisLineWidth\": 2\n },\n \"chartOrientation\": \"vertical\",\n \"plotReservedSpacePercent\": 50\n },\n \"requirement\": {\n \"useMaxWidth\": true,\n \"rect_fill\": \"#f9f9f9\",\n \"text_color\": \"#333\",\n \"rect_border_size\": \"0.5px\",\n \"rect_border_color\": \"#bbb\",\n \"rect_min_width\": 200,\n \"rect_min_height\": 200,\n \"fontSize\": 14,\n \"rect_padding\": 10,\n \"line_height\": 20\n },\n \"mindmap\": {\n \"useMaxWidth\": true,\n \"padding\": 10,\n \"maxNodeWidth\": 200\n },\n \"timeline\": {\n \"useMaxWidth\": true,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"leftMargin\": 150,\n \"width\": 150,\n \"height\": 50,\n \"boxMargin\": 10,\n \"boxTextMargin\": 5,\n \"noteMargin\": 10,\n \"messageMargin\": 35,\n \"messageAlign\": \"center\",\n \"bottomMarginAdj\": 1,\n \"rightAngles\": false,\n \"taskFontSize\": 14,\n \"taskFontFamily\": '\"Open Sans\", sans-serif',\n \"taskMargin\": 50,\n \"activationWidth\": 10,\n \"textPlacement\": \"fo\",\n \"actorColours\": [\n \"#8FBC8F\",\n \"#7CFC00\",\n \"#00FFFF\",\n \"#20B2AA\",\n \"#B0E0E6\",\n \"#FFFFE0\"\n ],\n \"sectionFills\": [\n \"#191970\",\n \"#8B008B\",\n \"#4B0082\",\n \"#2F4F4F\",\n \"#800000\",\n \"#8B4513\",\n \"#00008B\"\n ],\n \"sectionColours\": [\n \"#fff\"\n ],\n \"disableMulticolor\": false\n },\n \"gitGraph\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"diagramPadding\": 8,\n \"nodeLabel\": {\n \"width\": 75,\n \"height\": 100,\n \"x\": -25,\n \"y\": 0\n },\n \"mainBranchName\": \"main\",\n \"mainBranchOrder\": 0,\n \"showCommitLabel\": true,\n \"showBranches\": true,\n \"rotateCommitLabel\": true,\n \"arrowMarkerAbsolute\": false\n },\n \"c4\": {\n \"useMaxWidth\": true,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"c4ShapeMargin\": 50,\n \"c4ShapePadding\": 20,\n \"width\": 216,\n \"height\": 60,\n \"boxMargin\": 10,\n \"c4ShapeInRow\": 4,\n \"nextLinePaddingX\": 0,\n \"c4BoundaryInRow\": 2,\n \"personFontSize\": 14,\n \"personFontFamily\": '\"Open Sans\", sans-serif',\n \"personFontWeight\": \"normal\",\n \"external_personFontSize\": 14,\n \"external_personFontFamily\": '\"Open Sans\", sans-serif',\n \"external_personFontWeight\": \"normal\",\n \"systemFontSize\": 14,\n \"systemFontFamily\": '\"Open Sans\", sans-serif',\n \"systemFontWeight\": \"normal\",\n \"external_systemFontSize\": 14,\n \"external_systemFontFamily\": '\"Open Sans\", sans-serif',\n \"external_systemFontWeight\": \"normal\",\n \"system_dbFontSize\": 14,\n \"system_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"system_dbFontWeight\": \"normal\",\n \"external_system_dbFontSize\": 14,\n \"external_system_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"external_system_dbFontWeight\": \"normal\",\n \"system_queueFontSize\": 14,\n \"system_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"system_queueFontWeight\": \"normal\",\n \"external_system_queueFontSize\": 14,\n \"external_system_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"external_system_queueFontWeight\": \"normal\",\n \"boundaryFontSize\": 14,\n \"boundaryFontFamily\": '\"Open Sans\", sans-serif',\n \"boundaryFontWeight\": \"normal\",\n \"messageFontSize\": 12,\n \"messageFontFamily\": '\"Open Sans\", sans-serif',\n \"messageFontWeight\": \"normal\",\n \"containerFontSize\": 14,\n \"containerFontFamily\": '\"Open Sans\", sans-serif',\n \"containerFontWeight\": \"normal\",\n \"external_containerFontSize\": 14,\n \"external_containerFontFamily\": '\"Open Sans\", sans-serif',\n \"external_containerFontWeight\": \"normal\",\n \"container_dbFontSize\": 14,\n \"container_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"container_dbFontWeight\": \"normal\",\n \"external_container_dbFontSize\": 14,\n \"external_container_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"external_container_dbFontWeight\": \"normal\",\n \"container_queueFontSize\": 14,\n \"container_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"container_queueFontWeight\": \"normal\",\n \"external_container_queueFontSize\": 14,\n \"external_container_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"external_container_queueFontWeight\": \"normal\",\n \"componentFontSize\": 14,\n \"componentFontFamily\": '\"Open Sans\", sans-serif',\n \"componentFontWeight\": \"normal\",\n \"external_componentFontSize\": 14,\n \"external_componentFontFamily\": '\"Open Sans\", sans-serif',\n \"external_componentFontWeight\": \"normal\",\n \"component_dbFontSize\": 14,\n \"component_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"component_dbFontWeight\": \"normal\",\n \"external_component_dbFontSize\": 14,\n \"external_component_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"external_component_dbFontWeight\": \"normal\",\n \"component_queueFontSize\": 14,\n \"component_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"component_queueFontWeight\": \"normal\",\n \"external_component_queueFontSize\": 14,\n \"external_component_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"external_component_queueFontWeight\": \"normal\",\n \"wrap\": true,\n \"wrapPadding\": 10,\n \"person_bg_color\": \"#08427B\",\n \"person_border_color\": \"#073B6F\",\n \"external_person_bg_color\": \"#686868\",\n \"external_person_border_color\": \"#8A8A8A\",\n \"system_bg_color\": \"#1168BD\",\n \"system_border_color\": \"#3C7FC0\",\n \"system_db_bg_color\": \"#1168BD\",\n \"system_db_border_color\": \"#3C7FC0\",\n \"system_queue_bg_color\": \"#1168BD\",\n \"system_queue_border_color\": \"#3C7FC0\",\n \"external_system_bg_color\": \"#999999\",\n \"external_system_border_color\": \"#8A8A8A\",\n \"external_system_db_bg_color\": \"#999999\",\n \"external_system_db_border_color\": \"#8A8A8A\",\n \"external_system_queue_bg_color\": \"#999999\",\n \"external_system_queue_border_color\": \"#8A8A8A\",\n \"container_bg_color\": \"#438DD5\",\n \"container_border_color\": \"#3C7FC0\",\n \"container_db_bg_color\": \"#438DD5\",\n \"container_db_border_color\": \"#3C7FC0\",\n \"container_queue_bg_color\": \"#438DD5\",\n \"container_queue_border_color\": \"#3C7FC0\",\n \"external_container_bg_color\": \"#B3B3B3\",\n \"external_container_border_color\": \"#A6A6A6\",\n \"external_container_db_bg_color\": \"#B3B3B3\",\n \"external_container_db_border_color\": \"#A6A6A6\",\n \"external_container_queue_bg_color\": \"#B3B3B3\",\n \"external_container_queue_border_color\": \"#A6A6A6\",\n \"component_bg_color\": \"#85BBF0\",\n \"component_border_color\": \"#78A8D8\",\n \"component_db_bg_color\": \"#85BBF0\",\n \"component_db_border_color\": \"#78A8D8\",\n \"component_queue_bg_color\": \"#85BBF0\",\n \"component_queue_border_color\": \"#78A8D8\",\n \"external_component_bg_color\": \"#CCCCCC\",\n \"external_component_border_color\": \"#BFBFBF\",\n \"external_component_db_bg_color\": \"#CCCCCC\",\n \"external_component_db_border_color\": \"#BFBFBF\",\n \"external_component_queue_bg_color\": \"#CCCCCC\",\n \"external_component_queue_border_color\": \"#BFBFBF\"\n },\n \"sankey\": {\n \"useMaxWidth\": true,\n \"width\": 600,\n \"height\": 400,\n \"linkColor\": \"gradient\",\n \"nodeAlignment\": \"justify\",\n \"showValues\": true,\n \"prefix\": \"\",\n \"suffix\": \"\"\n },\n \"theme\": \"default\",\n \"maxTextSize\": 5e4,\n \"darkMode\": false,\n \"fontFamily\": '\"trebuchet ms\", verdana, arial, sans-serif;',\n \"logLevel\": 5,\n \"securityLevel\": \"strict\",\n \"startOnLoad\": true,\n \"arrowMarkerAbsolute\": false,\n \"secure\": [\n \"secure\",\n \"securityLevel\",\n \"startOnLoad\",\n \"maxTextSize\"\n ],\n \"deterministicIds\": false,\n \"fontSize\": 16\n};\nconst config = {\n ...defaultConfigJson,\n // Set, even though they're `undefined` so that `configKeys` finds these keys\n // TODO: Should we replace these with `null` so that they can go in the JSON Schema?\n deterministicIDSeed: void 0,\n themeCSS: void 0,\n // add non-JSON default config values\n themeVariables: theme[\"default\"].getThemeVariables(),\n sequence: {\n ...defaultConfigJson.sequence,\n messageFont: function() {\n return {\n fontFamily: this.messageFontFamily,\n fontSize: this.messageFontSize,\n fontWeight: this.messageFontWeight\n };\n },\n noteFont: function() {\n return {\n fontFamily: this.noteFontFamily,\n fontSize: this.noteFontSize,\n fontWeight: this.noteFontWeight\n };\n },\n actorFont: function() {\n return {\n fontFamily: this.actorFontFamily,\n fontSize: this.actorFontSize,\n fontWeight: this.actorFontWeight\n };\n }\n },\n gantt: {\n ...defaultConfigJson.gantt,\n tickInterval: void 0,\n useWidth: void 0\n // can probably be removed since `configKeys` already includes this\n },\n c4: {\n ...defaultConfigJson.c4,\n useWidth: void 0,\n personFont: function() {\n return {\n fontFamily: this.personFontFamily,\n fontSize: this.personFontSize,\n fontWeight: this.personFontWeight\n };\n },\n external_personFont: function() {\n return {\n fontFamily: this.external_personFontFamily,\n fontSize: this.external_personFontSize,\n fontWeight: this.external_personFontWeight\n };\n },\n systemFont: function() {\n return {\n fontFamily: this.systemFontFamily,\n fontSize: this.systemFontSize,\n fontWeight: this.systemFontWeight\n };\n },\n external_systemFont: function() {\n return {\n fontFamily: this.external_systemFontFamily,\n fontSize: this.external_systemFontSize,\n fontWeight: this.external_systemFontWeight\n };\n },\n system_dbFont: function() {\n return {\n fontFamily: this.system_dbFontFamily,\n fontSize: this.system_dbFontSize,\n fontWeight: this.system_dbFontWeight\n };\n },\n external_system_dbFont: function() {\n return {\n fontFamily: this.external_system_dbFontFamily,\n fontSize: this.external_system_dbFontSize,\n fontWeight: this.external_system_dbFontWeight\n };\n },\n system_queueFont: function() {\n return {\n fontFamily: this.system_queueFontFamily,\n fontSize: this.system_queueFontSize,\n fontWeight: this.system_queueFontWeight\n };\n },\n external_system_queueFont: function() {\n return {\n fontFamily: this.external_system_queueFontFamily,\n fontSize: this.external_system_queueFontSize,\n fontWeight: this.external_system_queueFontWeight\n };\n },\n containerFont: function() {\n return {\n fontFamily: this.containerFontFamily,\n fontSize: this.containerFontSize,\n fontWeight: this.containerFontWeight\n };\n },\n external_containerFont: function() {\n return {\n fontFamily: this.external_containerFontFamily,\n fontSize: this.external_containerFontSize,\n fontWeight: this.external_containerFontWeight\n };\n },\n container_dbFont: function() {\n return {\n fontFamily: this.container_dbFontFamily,\n fontSize: this.container_dbFontSize,\n fontWeight: this.container_dbFontWeight\n };\n },\n external_container_dbFont: function() {\n return {\n fontFamily: this.external_container_dbFontFamily,\n fontSize: this.external_container_dbFontSize,\n fontWeight: this.external_container_dbFontWeight\n };\n },\n container_queueFont: function() {\n return {\n fontFamily: this.container_queueFontFamily,\n fontSize: this.container_queueFontSize,\n fontWeight: this.container_queueFontWeight\n };\n },\n external_container_queueFont: function() {\n return {\n fontFamily: this.external_container_queueFontFamily,\n fontSize: this.external_container_queueFontSize,\n fontWeight: this.external_container_queueFontWeight\n };\n },\n componentFont: function() {\n return {\n fontFamily: this.componentFontFamily,\n fontSize: this.componentFontSize,\n fontWeight: this.componentFontWeight\n };\n },\n external_componentFont: function() {\n return {\n fontFamily: this.external_componentFontFamily,\n fontSize: this.external_componentFontSize,\n fontWeight: this.external_componentFontWeight\n };\n },\n component_dbFont: function() {\n return {\n fontFamily: this.component_dbFontFamily,\n fontSize: this.component_dbFontSize,\n fontWeight: this.component_dbFontWeight\n };\n },\n external_component_dbFont: function() {\n return {\n fontFamily: this.external_component_dbFontFamily,\n fontSize: this.external_component_dbFontSize,\n fontWeight: this.external_component_dbFontWeight\n };\n },\n component_queueFont: function() {\n return {\n fontFamily: this.component_queueFontFamily,\n fontSize: this.component_queueFontSize,\n fontWeight: this.component_queueFontWeight\n };\n },\n external_component_queueFont: function() {\n return {\n fontFamily: this.external_component_queueFontFamily,\n fontSize: this.external_component_queueFontSize,\n fontWeight: this.external_component_queueFontWeight\n };\n },\n boundaryFont: function() {\n return {\n fontFamily: this.boundaryFontFamily,\n fontSize: this.boundaryFontSize,\n fontWeight: this.boundaryFontWeight\n };\n },\n messageFont: function() {\n return {\n fontFamily: this.messageFontFamily,\n fontSize: this.messageFontSize,\n fontWeight: this.messageFontWeight\n };\n }\n },\n pie: {\n ...defaultConfigJson.pie,\n useWidth: 984\n },\n xyChart: {\n ...defaultConfigJson.xyChart,\n useWidth: void 0\n },\n requirement: {\n ...defaultConfigJson.requirement,\n useWidth: void 0\n },\n gitGraph: {\n ...defaultConfigJson.gitGraph,\n // TODO: This is a temporary override for `gitGraph`, since every other\n // diagram does have `useMaxWidth`, but instead sets it to `true`.\n // Should we set this to `true` instead?\n useMaxWidth: false\n },\n sankey: {\n ...defaultConfigJson.sankey,\n // this is false, unlike every other diagram (other than gitGraph)\n // TODO: can we make this default to `true` instead?\n useMaxWidth: false\n }\n};\nconst keyify = (obj, prefix = \"\") => Object.keys(obj).reduce((res, el) => {\n if (Array.isArray(obj[el])) {\n return res;\n } else if (typeof obj[el] === \"object\" && obj[el] !== null) {\n return [...res, prefix + el, ...keyify(obj[el], \"\")];\n }\n return [...res, prefix + el];\n}, []);\nconst configKeys = new Set(keyify(config, \"\"));\nconst defaultConfig$2 = config;\nconst sanitizeDirective = (args) => {\n log$1.debug(\"sanitizeDirective called with\", args);\n if (typeof args !== \"object\" || args == null) {\n return;\n }\n if (Array.isArray(args)) {\n args.forEach((arg) => sanitizeDirective(arg));\n return;\n }\n for (const key of Object.keys(args)) {\n log$1.debug(\"Checking key\", key);\n if (key.startsWith(\"__\") || key.includes(\"proto\") || key.includes(\"constr\") || !configKeys.has(key) || args[key] == null) {\n log$1.debug(\"sanitize deleting key: \", key);\n delete args[key];\n continue;\n }\n if (typeof args[key] === \"object\") {\n log$1.debug(\"sanitizing object\", key);\n sanitizeDirective(args[key]);\n continue;\n }\n const cssMatchers = [\"themeCSS\", \"fontFamily\", \"altFontFamily\"];\n for (const cssKey of cssMatchers) {\n if (key.includes(cssKey)) {\n log$1.debug(\"sanitizing css option\", key);\n args[key] = sanitizeCss(args[key]);\n }\n }\n }\n if (args.themeVariables) {\n for (const k of Object.keys(args.themeVariables)) {\n const val = args.themeVariables[k];\n if ((val == null ? void 0 : val.match) && !val.match(/^[\\d \"#%(),.;A-Za-z]+$/)) {\n args.themeVariables[k] = \"\";\n }\n }\n }\n log$1.debug(\"After sanitization\", args);\n};\nconst sanitizeCss = (str2) => {\n let startCnt = 0;\n let endCnt = 0;\n for (const element of str2) {\n if (startCnt < endCnt) {\n return \"{ /* ERROR: Unbalanced CSS */ }\";\n }\n if (element === \"{\") {\n startCnt++;\n } else if (element === \"}\") {\n endCnt++;\n }\n }\n if (startCnt !== endCnt) {\n return \"{ /* ERROR: Unbalanced CSS */ }\";\n }\n return str2;\n};\nconst frontMatterRegex = /^-{3}\\s*[\\n\\r](.*?)[\\n\\r]-{3}\\s*[\\n\\r]+/s;\nconst directiveRegex = /%{2}{\\s*(?:(\\w+)\\s*:|(\\w+))\\s*(?:(\\w+)|((?:(?!}%{2}).|\\r?\\n)*))?\\s*(?:}%{2})?/gi;\nconst anyCommentRegex = /\\s*%%.*\\n/gm;\nclass UnknownDiagramError extends Error {\n constructor(message) {\n super(message);\n this.name = \"UnknownDiagramError\";\n }\n}\nconst detectors = {};\nconst detectType = function(text, config2) {\n text = text.replace(frontMatterRegex, \"\").replace(directiveRegex, \"\").replace(anyCommentRegex, \"\\n\");\n for (const [key, { detector: detector2 }] of Object.entries(detectors)) {\n const diagram2 = detector2(text, config2);\n if (diagram2) {\n return key;\n }\n }\n throw new UnknownDiagramError(\n `No diagram type detected matching given configuration for text: ${text}`\n );\n};\nconst registerLazyLoadedDiagrams = (...diagrams2) => {\n for (const { id: id2, detector: detector2, loader: loader2 } of diagrams2) {\n addDetector(id2, detector2, loader2);\n }\n};\nconst addDetector = (key, detector2, loader2) => {\n if (detectors[key]) {\n log$1.error(`Detector with key ${key} already exists`);\n } else {\n detectors[key] = { detector: detector2, loader: loader2 };\n }\n log$1.debug(`Detector with key ${key} added${loader2 ? \" with loader\" : \"\"}`);\n};\nconst getDiagramLoader = (key) => {\n return detectors[key].loader;\n};\nconst assignWithDepth = (dst, src, { depth = 2, clobber = false } = {}) => {\n const config2 = { depth, clobber };\n if (Array.isArray(src) && !Array.isArray(dst)) {\n src.forEach((s) => assignWithDepth(dst, s, config2));\n return dst;\n } else if (Array.isArray(src) && Array.isArray(dst)) {\n src.forEach((s) => {\n if (!dst.includes(s)) {\n dst.push(s);\n }\n });\n return dst;\n }\n if (dst === void 0 || depth <= 0) {\n if (dst !== void 0 && dst !== null && typeof dst === \"object\" && typeof src === \"object\") {\n return Object.assign(dst, src);\n } else {\n return src;\n }\n }\n if (src !== void 0 && typeof dst === \"object\" && typeof src === \"object\") {\n Object.keys(src).forEach((key) => {\n if (typeof src[key] === \"object\" && (dst[key] === void 0 || typeof dst[key] === \"object\")) {\n if (dst[key] === void 0) {\n dst[key] = Array.isArray(src[key]) ? [] : {};\n }\n dst[key] = assignWithDepth(dst[key], src[key], { depth: depth - 1, clobber });\n } else if (clobber || typeof dst[key] !== \"object\" && typeof src[key] !== \"object\") {\n dst[key] = src[key];\n }\n });\n }\n return dst;\n};\nconst assignWithDepth$1 = assignWithDepth;\nconst ZERO_WIDTH_SPACE = \"\u200B\";\nconst d3CurveTypes = {\n curveBasis,\n curveBasisClosed,\n curveBasisOpen,\n curveBumpX,\n curveBumpY,\n curveBundle,\n curveCardinalClosed,\n curveCardinalOpen,\n curveCardinal,\n curveCatmullRomClosed,\n curveCatmullRomOpen,\n curveCatmullRom,\n curveLinear,\n curveLinearClosed,\n curveMonotoneX,\n curveMonotoneY,\n curveNatural,\n curveStep,\n curveStepAfter,\n curveStepBefore\n};\nconst directiveWithoutOpen = /\\s*(?:(\\w+)(?=:):|(\\w+))\\s*(?:(\\w+)|((?:(?!}%{2}).|\\r?\\n)*))?\\s*(?:}%{2})?/gi;\nconst detectInit = function(text, config2) {\n const inits = detectDirective(text, /(?:init\\b)|(?:initialize\\b)/);\n let results = {};\n if (Array.isArray(inits)) {\n const args = inits.map((init2) => init2.args);\n sanitizeDirective(args);\n results = assignWithDepth$1(results, [...args]);\n } else {\n results = inits.args;\n }\n if (!results) {\n return;\n }\n let type2 = detectType(text, config2);\n const prop = \"config\";\n if (results[prop] !== void 0) {\n if (type2 === \"flowchart-v2\") {\n type2 = \"flowchart\";\n }\n results[type2] = results[prop];\n delete results[prop];\n }\n return results;\n};\nconst detectDirective = function(text, type2 = null) {\n try {\n const commentWithoutDirectives = new RegExp(\n `[%]{2}(?![{]${directiveWithoutOpen.source})(?=[}][%]{2}).*\n`,\n \"ig\"\n );\n text = text.trim().replace(commentWithoutDirectives, \"\").replace(/'/gm, '\"');\n log$1.debug(\n `Detecting diagram directive${type2 !== null ? \" type:\" + type2 : \"\"} based on the text:${text}`\n );\n let match;\n const result = [];\n while ((match = directiveRegex.exec(text)) !== null) {\n if (match.index === directiveRegex.lastIndex) {\n directiveRegex.lastIndex++;\n }\n if (match && !type2 || type2 && match[1] && match[1].match(type2) || type2 && match[2] && match[2].match(type2)) {\n const type22 = match[1] ? match[1] : match[2];\n const args = match[3] ? match[3].trim() : match[4] ? JSON.parse(match[4].trim()) : null;\n result.push({ type: type22, args });\n }\n }\n if (result.length === 0) {\n return { type: text, args: null };\n }\n return result.length === 1 ? result[0] : result;\n } catch (error) {\n log$1.error(\n `ERROR: ${error.message} - Unable to parse directive type: '${type2}' based on the text: '${text}'`\n );\n return { type: void 0, args: null };\n }\n};\nconst removeDirectives = function(text) {\n return text.replace(directiveRegex, \"\");\n};\nconst isSubstringInArray = function(str2, arr) {\n for (const [i, element] of arr.entries()) {\n if (element.match(str2)) {\n return i;\n }\n }\n return -1;\n};\nfunction interpolateToCurve(interpolate, defaultCurve) {\n if (!interpolate) {\n return defaultCurve;\n }\n const curveName = `curve${interpolate.charAt(0).toUpperCase() + interpolate.slice(1)}`;\n return d3CurveTypes[curveName] ?? defaultCurve;\n}\nfunction formatUrl(linkStr, config2) {\n const url = linkStr.trim();\n if (!url) {\n return void 0;\n }\n if (config2.securityLevel !== \"loose\") {\n return sanitizeUrl(url);\n }\n return url;\n}\nconst runFunc = (functionName, ...params) => {\n const arrPaths = functionName.split(\".\");\n const len = arrPaths.length - 1;\n const fnName = arrPaths[len];\n let obj = window;\n for (let i = 0; i < len; i++) {\n obj = obj[arrPaths[i]];\n if (!obj) {\n log$1.error(`Function name: ${functionName} not found in window`);\n return;\n }\n }\n obj[fnName](...params);\n};\nfunction distance(p1, p2) {\n if (!p1 || !p2) {\n return 0;\n }\n return Math.sqrt(Math.pow(p2.x - p1.x, 2) + Math.pow(p2.y - p1.y, 2));\n}\nfunction traverseEdge(points) {\n let prevPoint;\n let totalDistance = 0;\n points.forEach((point) => {\n totalDistance += distance(point, prevPoint);\n prevPoint = point;\n });\n const remainingDistance = totalDistance / 2;\n return calculatePoint(points, remainingDistance);\n}\nfunction calcLabelPosition(points) {\n if (points.length === 1) {\n return points[0];\n }\n return traverseEdge(points);\n}\nconst roundNumber = (num, precision = 2) => {\n const factor = Math.pow(10, precision);\n return Math.round(num * factor) / factor;\n};\nconst calculatePoint = (points, distanceToTraverse) => {\n let prevPoint = void 0;\n let remainingDistance = distanceToTraverse;\n for (const point of points) {\n if (prevPoint) {\n const vectorDistance = distance(point, prevPoint);\n if (vectorDistance < remainingDistance) {\n remainingDistance -= vectorDistance;\n } else {\n const distanceRatio = remainingDistance / vectorDistance;\n if (distanceRatio <= 0) {\n return prevPoint;\n }\n if (distanceRatio >= 1) {\n return { x: point.x, y: point.y };\n }\n if (distanceRatio > 0 && distanceRatio < 1) {\n return {\n x: roundNumber((1 - distanceRatio) * prevPoint.x + distanceRatio * point.x, 5),\n y: roundNumber((1 - distanceRatio) * prevPoint.y + distanceRatio * point.y, 5)\n };\n }\n }\n }\n prevPoint = point;\n }\n throw new Error(\"Could not find a suitable point for the given distance\");\n};\nconst calcCardinalityPosition = (isRelationTypePresent, points, initialPosition) => {\n log$1.info(`our points ${JSON.stringify(points)}`);\n if (points[0] !== initialPosition) {\n points = points.reverse();\n }\n const distanceToCardinalityPoint = 25;\n const center = calculatePoint(points, distanceToCardinalityPoint);\n const d = isRelationTypePresent ? 10 : 5;\n const angle = Math.atan2(points[0].y - center.y, points[0].x - center.x);\n const cardinalityPosition = { x: 0, y: 0 };\n cardinalityPosition.x = Math.sin(angle) * d + (points[0].x + center.x) / 2;\n cardinalityPosition.y = -Math.cos(angle) * d + (points[0].y + center.y) / 2;\n return cardinalityPosition;\n};\nfunction calcTerminalLabelPosition(terminalMarkerSize, position, _points) {\n const points = structuredClone(_points);\n log$1.info(\"our points\", points);\n if (position !== \"start_left\" && position !== \"start_right\") {\n points.reverse();\n }\n const distanceToCardinalityPoint = 25 + terminalMarkerSize;\n const center = calculatePoint(points, distanceToCardinalityPoint);\n const d = 10 + terminalMarkerSize * 0.5;\n const angle = Math.atan2(points[0].y - center.y, points[0].x - center.x);\n const cardinalityPosition = { x: 0, y: 0 };\n if (position === \"start_left\") {\n cardinalityPosition.x = Math.sin(angle + Math.PI) * d + (points[0].x + center.x) / 2;\n cardinalityPosition.y = -Math.cos(angle + Math.PI) * d + (points[0].y + center.y) / 2;\n } else if (position === \"end_right\") {\n cardinalityPosition.x = Math.sin(angle - Math.PI) * d + (points[0].x + center.x) / 2 - 5;\n cardinalityPosition.y = -Math.cos(angle - Math.PI) * d + (points[0].y + center.y) / 2 - 5;\n } else if (position === \"end_left\") {\n cardinalityPosition.x = Math.sin(angle) * d + (points[0].x + center.x) / 2 - 5;\n cardinalityPosition.y = -Math.cos(angle) * d + (points[0].y + center.y) / 2 - 5;\n } else {\n cardinalityPosition.x = Math.sin(angle) * d + (points[0].x + center.x) / 2;\n cardinalityPosition.y = -Math.cos(angle) * d + (points[0].y + center.y) / 2;\n }\n return cardinalityPosition;\n}\nfunction getStylesFromArray(arr) {\n let style = \"\";\n let labelStyle = \"\";\n for (const element of arr) {\n if (element !== void 0) {\n if (element.startsWith(\"color:\") || element.startsWith(\"text-align:\")) {\n labelStyle = labelStyle + element + \";\";\n } else {\n style = style + element + \";\";\n }\n }\n }\n return { style, labelStyle };\n}\nlet cnt = 0;\nconst generateId = () => {\n cnt++;\n return \"id-\" + Math.random().toString(36).substr(2, 12) + \"-\" + cnt;\n};\nfunction makeRandomHex(length) {\n let result = \"\";\n const characters = \"0123456789abcdef\";\n const charactersLength = characters.length;\n for (let i = 0; i < length; i++) {\n result += characters.charAt(Math.floor(Math.random() * charactersLength));\n }\n return result;\n}\nconst random = (options) => {\n return makeRandomHex(options.length);\n};\nconst getTextObj = function() {\n return {\n x: 0,\n y: 0,\n fill: void 0,\n anchor: \"start\",\n style: \"#666\",\n width: 100,\n height: 100,\n textMargin: 0,\n rx: 0,\n ry: 0,\n valign: void 0,\n text: \"\"\n };\n};\nconst drawSimpleText = function(elem, textData) {\n const nText = textData.text.replace(common$1.lineBreakRegex, \" \");\n const [, _fontSizePx] = parseFontSize(textData.fontSize);\n const textElem = elem.append(\"text\");\n textElem.attr(\"x\", textData.x);\n textElem.attr(\"y\", textData.y);\n textElem.style(\"text-anchor\", textData.anchor);\n textElem.style(\"font-family\", textData.fontFamily);\n textElem.style(\"font-size\", _fontSizePx);\n textElem.style(\"font-weight\", textData.fontWeight);\n textElem.attr(\"fill\", textData.fill);\n if (textData.class !== void 0) {\n textElem.attr(\"class\", textData.class);\n }\n const span = textElem.append(\"tspan\");\n span.attr(\"x\", textData.x + textData.textMargin * 2);\n span.attr(\"fill\", textData.fill);\n span.text(nText);\n return textElem;\n};\nconst wrapLabel = memoize(\n (label, maxWidth, config2) => {\n if (!label) {\n return label;\n }\n config2 = Object.assign(\n { fontSize: 12, fontWeight: 400, fontFamily: \"Arial\", joinWith: \"
      \" },\n config2\n );\n if (common$1.lineBreakRegex.test(label)) {\n return label;\n }\n const words = label.split(\" \");\n const completedLines = [];\n let nextLine = \"\";\n words.forEach((word, index) => {\n const wordLength = calculateTextWidth(`${word} `, config2);\n const nextLineLength = calculateTextWidth(nextLine, config2);\n if (wordLength > maxWidth) {\n const { hyphenatedStrings, remainingWord } = breakString(word, maxWidth, \"-\", config2);\n completedLines.push(nextLine, ...hyphenatedStrings);\n nextLine = remainingWord;\n } else if (nextLineLength + wordLength >= maxWidth) {\n completedLines.push(nextLine);\n nextLine = word;\n } else {\n nextLine = [nextLine, word].filter(Boolean).join(\" \");\n }\n const currentWord = index + 1;\n const isLastWord = currentWord === words.length;\n if (isLastWord) {\n completedLines.push(nextLine);\n }\n });\n return completedLines.filter((line) => line !== \"\").join(config2.joinWith);\n },\n (label, maxWidth, config2) => `${label}${maxWidth}${config2.fontSize}${config2.fontWeight}${config2.fontFamily}${config2.joinWith}`\n);\nconst breakString = memoize(\n (word, maxWidth, hyphenCharacter = \"-\", config2) => {\n config2 = Object.assign(\n { fontSize: 12, fontWeight: 400, fontFamily: \"Arial\", margin: 0 },\n config2\n );\n const characters = [...word];\n const lines = [];\n let currentLine = \"\";\n characters.forEach((character, index) => {\n const nextLine = `${currentLine}${character}`;\n const lineWidth = calculateTextWidth(nextLine, config2);\n if (lineWidth >= maxWidth) {\n const currentCharacter = index + 1;\n const isLastLine = characters.length === currentCharacter;\n const hyphenatedNextLine = `${nextLine}${hyphenCharacter}`;\n lines.push(isLastLine ? nextLine : hyphenatedNextLine);\n currentLine = \"\";\n } else {\n currentLine = nextLine;\n }\n });\n return { hyphenatedStrings: lines, remainingWord: currentLine };\n },\n (word, maxWidth, hyphenCharacter = \"-\", config2) => `${word}${maxWidth}${hyphenCharacter}${config2.fontSize}${config2.fontWeight}${config2.fontFamily}`\n);\nfunction calculateTextHeight(text, config2) {\n return calculateTextDimensions(text, config2).height;\n}\nfunction calculateTextWidth(text, config2) {\n return calculateTextDimensions(text, config2).width;\n}\nconst calculateTextDimensions = memoize(\n (text, config2) => {\n const { fontSize = 12, fontFamily = \"Arial\", fontWeight = 400 } = config2;\n if (!text) {\n return { width: 0, height: 0 };\n }\n const [, _fontSizePx] = parseFontSize(fontSize);\n const fontFamilies = [\"sans-serif\", fontFamily];\n const lines = text.split(common$1.lineBreakRegex);\n const dims = [];\n const body = select(\"body\");\n if (!body.remove) {\n return { width: 0, height: 0, lineHeight: 0 };\n }\n const g = body.append(\"svg\");\n for (const fontFamily2 of fontFamilies) {\n let cHeight = 0;\n const dim = { width: 0, height: 0, lineHeight: 0 };\n for (const line of lines) {\n const textObj = getTextObj();\n textObj.text = line || ZERO_WIDTH_SPACE;\n const textElem = drawSimpleText(g, textObj).style(\"font-size\", _fontSizePx).style(\"font-weight\", fontWeight).style(\"font-family\", fontFamily2);\n const bBox = (textElem._groups || textElem)[0][0].getBBox();\n if (bBox.width === 0 && bBox.height === 0) {\n throw new Error(\"svg element not in render tree\");\n }\n dim.width = Math.round(Math.max(dim.width, bBox.width));\n cHeight = Math.round(bBox.height);\n dim.height += cHeight;\n dim.lineHeight = Math.round(Math.max(dim.lineHeight, cHeight));\n }\n dims.push(dim);\n }\n g.remove();\n const index = isNaN(dims[1].height) || isNaN(dims[1].width) || isNaN(dims[1].lineHeight) || dims[0].height > dims[1].height && dims[0].width > dims[1].width && dims[0].lineHeight > dims[1].lineHeight ? 0 : 1;\n return dims[index];\n },\n (text, config2) => `${text}${config2.fontSize}${config2.fontWeight}${config2.fontFamily}`\n);\nclass InitIDGenerator {\n constructor(deterministic = false, seed) {\n this.count = 0;\n this.count = seed ? seed.length : 0;\n this.next = deterministic ? () => this.count++ : () => Date.now();\n }\n}\nlet decoder;\nconst entityDecode = function(html) {\n decoder = decoder || document.createElement(\"div\");\n html = escape(html).replace(/%26/g, \"&\").replace(/%23/g, \"#\").replace(/%3B/g, \";\");\n decoder.innerHTML = html;\n return unescape(decoder.textContent);\n};\nfunction isDetailedError(error) {\n return \"str\" in error;\n}\nconst insertTitle = (parent, cssClass, titleTopMargin, title) => {\n var _a;\n if (!title) {\n return;\n }\n const bounds = (_a = parent.node()) == null ? void 0 : _a.getBBox();\n if (!bounds) {\n return;\n }\n parent.append(\"text\").text(title).attr(\"x\", bounds.x + bounds.width / 2).attr(\"y\", -titleTopMargin).attr(\"class\", cssClass);\n};\nconst parseFontSize = (fontSize) => {\n if (typeof fontSize === \"number\") {\n return [fontSize, fontSize + \"px\"];\n }\n const fontSizeNumber = parseInt(fontSize ?? \"\", 10);\n if (Number.isNaN(fontSizeNumber)) {\n return [void 0, void 0];\n } else if (fontSize === String(fontSizeNumber)) {\n return [fontSizeNumber, fontSize + \"px\"];\n } else {\n return [fontSizeNumber, fontSize];\n }\n};\nfunction cleanAndMerge(defaultData, data) {\n return merge$1({}, defaultData, data);\n}\nconst utils = {\n assignWithDepth: assignWithDepth$1,\n wrapLabel,\n calculateTextHeight,\n calculateTextWidth,\n calculateTextDimensions,\n cleanAndMerge,\n detectInit,\n detectDirective,\n isSubstringInArray,\n interpolateToCurve,\n calcLabelPosition,\n calcCardinalityPosition,\n calcTerminalLabelPosition,\n formatUrl,\n getStylesFromArray,\n generateId,\n random,\n runFunc,\n entityDecode,\n insertTitle,\n parseFontSize,\n InitIDGenerator\n};\nconst version = \"10.6.0\";\nconst defaultConfig$1 = Object.freeze(defaultConfig$2);\nlet siteConfig = assignWithDepth$1({}, defaultConfig$1);\nlet configFromInitialize;\nlet directives = [];\nlet currentConfig = assignWithDepth$1({}, defaultConfig$1);\nconst updateCurrentConfig = (siteCfg, _directives) => {\n let cfg = assignWithDepth$1({}, siteCfg);\n let sumOfDirectives = {};\n for (const d of _directives) {\n sanitize(d);\n sumOfDirectives = assignWithDepth$1(sumOfDirectives, d);\n }\n cfg = assignWithDepth$1(cfg, sumOfDirectives);\n if (sumOfDirectives.theme && sumOfDirectives.theme in theme) {\n const tmpConfigFromInitialize = assignWithDepth$1({}, configFromInitialize);\n const themeVariables = assignWithDepth$1(\n tmpConfigFromInitialize.themeVariables || {},\n sumOfDirectives.themeVariables\n );\n if (cfg.theme && cfg.theme in theme) {\n cfg.themeVariables = theme[cfg.theme].getThemeVariables(themeVariables);\n }\n }\n currentConfig = cfg;\n checkConfig(currentConfig);\n return currentConfig;\n};\nconst setSiteConfig = (conf) => {\n siteConfig = assignWithDepth$1({}, defaultConfig$1);\n siteConfig = assignWithDepth$1(siteConfig, conf);\n if (conf.theme && theme[conf.theme]) {\n siteConfig.themeVariables = theme[conf.theme].getThemeVariables(conf.themeVariables);\n }\n updateCurrentConfig(siteConfig, directives);\n return siteConfig;\n};\nconst saveConfigFromInitialize = (conf) => {\n configFromInitialize = assignWithDepth$1({}, conf);\n};\nconst updateSiteConfig = (conf) => {\n siteConfig = assignWithDepth$1(siteConfig, conf);\n updateCurrentConfig(siteConfig, directives);\n return siteConfig;\n};\nconst getSiteConfig = () => {\n return assignWithDepth$1({}, siteConfig);\n};\nconst setConfig$1 = (conf) => {\n checkConfig(conf);\n assignWithDepth$1(currentConfig, conf);\n return getConfig$1();\n};\nconst getConfig$1 = () => {\n return assignWithDepth$1({}, currentConfig);\n};\nconst sanitize = (options) => {\n if (!options) {\n return;\n }\n [\"secure\", ...siteConfig.secure ?? []].forEach((key) => {\n if (Object.hasOwn(options, key)) {\n log$1.debug(`Denied attempt to modify a secure key ${key}`, options[key]);\n delete options[key];\n }\n });\n Object.keys(options).forEach((key) => {\n if (key.startsWith(\"__\")) {\n delete options[key];\n }\n });\n Object.keys(options).forEach((key) => {\n if (typeof options[key] === \"string\" && (options[key].includes(\"<\") || options[key].includes(\">\") || options[key].includes(\"url(data:\"))) {\n delete options[key];\n }\n if (typeof options[key] === \"object\") {\n sanitize(options[key]);\n }\n });\n};\nconst addDirective = (directive) => {\n sanitizeDirective(directive);\n if (directive.fontFamily && (!directive.themeVariables || !directive.themeVariables.fontFamily)) {\n directive.themeVariables = { fontFamily: directive.fontFamily };\n }\n directives.push(directive);\n updateCurrentConfig(siteConfig, directives);\n};\nconst reset = (config2 = siteConfig) => {\n directives = [];\n updateCurrentConfig(config2, directives);\n};\nconst ConfigWarning = {\n LAZY_LOAD_DEPRECATED: \"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.\"\n};\nconst issuedWarnings = {};\nconst issueWarning = (warning) => {\n if (issuedWarnings[warning]) {\n return;\n }\n log$1.warn(ConfigWarning[warning]);\n issuedWarnings[warning] = true;\n};\nconst checkConfig = (config2) => {\n if (!config2) {\n return;\n }\n if (config2.lazyLoadedDiagrams || config2.loadExternalDiagramsAtStartup) {\n issueWarning(\"LAZY_LOAD_DEPRECATED\");\n }\n};\nconst id$k = \"c4\";\nconst detector$k = (txt) => {\n return /^\\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(txt);\n};\nconst loader$l = async () => {\n const { diagram: diagram2 } = await import(\"./c4Diagram-d0fbc5ce.js\");\n return { id: id$k, diagram: diagram2 };\n};\nconst plugin$i = {\n id: id$k,\n detector: detector$k,\n loader: loader$l\n};\nconst c4 = plugin$i;\nconst id$j = \"flowchart\";\nconst detector$j = (txt, config2) => {\n var _a, _b;\n if (((_a = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\" || ((_b = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _b.defaultRenderer) === \"elk\") {\n return false;\n }\n return /^\\s*graph/.test(txt);\n};\nconst loader$k = async () => {\n const { diagram: diagram2 } = await import(\"./flowDiagram-7ea5b25a.js\");\n return { id: id$j, diagram: diagram2 };\n};\nconst plugin$h = {\n id: id$j,\n detector: detector$j,\n loader: loader$k\n};\nconst flowchart = plugin$h;\nconst id$i = \"flowchart-v2\";\nconst detector$i = (txt, config2) => {\n var _a, _b, _c;\n if (((_a = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _a.defaultRenderer) === \"dagre-d3\" || ((_b = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _b.defaultRenderer) === \"elk\") {\n return false;\n }\n if (/^\\s*graph/.test(txt) && ((_c = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _c.defaultRenderer) === \"dagre-wrapper\") {\n return true;\n }\n return /^\\s*flowchart/.test(txt);\n};\nconst loader$j = async () => {\n const { diagram: diagram2 } = await import(\"./flowDiagram-v2-855bc5b3.js\");\n return { id: id$i, diagram: diagram2 };\n};\nconst plugin$g = {\n id: id$i,\n detector: detector$i,\n loader: loader$j\n};\nconst flowchartV2 = plugin$g;\nconst id$h = \"er\";\nconst detector$h = (txt) => {\n return /^\\s*erDiagram/.test(txt);\n};\nconst loader$i = async () => {\n const { diagram: diagram2 } = await import(\"./erDiagram-9d236eb7.js\");\n return { id: id$h, diagram: diagram2 };\n};\nconst plugin$f = {\n id: id$h,\n detector: detector$h,\n loader: loader$i\n};\nconst er = plugin$f;\nconst id$g = \"gitGraph\";\nconst detector$g = (txt) => {\n return /^\\s*gitGraph/.test(txt);\n};\nconst loader$h = async () => {\n const { diagram: diagram2 } = await import(\"./gitGraphDiagram-99d0ae7c.js\");\n return { id: id$g, diagram: diagram2 };\n};\nconst plugin$e = {\n id: id$g,\n detector: detector$g,\n loader: loader$h\n};\nconst git = plugin$e;\nconst id$f = \"gantt\";\nconst detector$f = (txt) => {\n return /^\\s*gantt/.test(txt);\n};\nconst loader$g = async () => {\n const { diagram: diagram2 } = await import(\"./ganttDiagram-9b5ea136.js\");\n return { id: id$f, diagram: diagram2 };\n};\nconst plugin$d = {\n id: id$f,\n detector: detector$f,\n loader: loader$g\n};\nconst gantt = plugin$d;\nconst id$e = \"info\";\nconst detector$e = (txt) => {\n return /^\\s*info/.test(txt);\n};\nconst loader$f = async () => {\n const { diagram: diagram2 } = await import(\"./infoDiagram-736b4530.js\");\n return { id: id$e, diagram: diagram2 };\n};\nconst info = {\n id: id$e,\n detector: detector$e,\n loader: loader$f\n};\nconst id$d = \"pie\";\nconst detector$d = (txt) => {\n return /^\\s*pie/.test(txt);\n};\nconst loader$e = async () => {\n const { diagram: diagram2 } = await import(\"./pieDiagram-dbbf0591.js\");\n return { id: id$d, diagram: diagram2 };\n};\nconst pie = {\n id: id$d,\n detector: detector$d,\n loader: loader$e\n};\nconst id$c = \"quadrantChart\";\nconst detector$c = (txt) => {\n return /^\\s*quadrantChart/.test(txt);\n};\nconst loader$d = async () => {\n const { diagram: diagram2 } = await import(\"./quadrantDiagram-4d7f4fd6.js\");\n return { id: id$c, diagram: diagram2 };\n};\nconst plugin$c = {\n id: id$c,\n detector: detector$c,\n loader: loader$d\n};\nconst quadrantChart = plugin$c;\nconst id$b = \"xychart\";\nconst detector$b = (txt) => {\n return /^\\s*xychart-beta/.test(txt);\n};\nconst loader$c = async () => {\n const { diagram: diagram2 } = await import(\"./xychartDiagram-2b33534f.js\");\n return { id: id$b, diagram: diagram2 };\n};\nconst plugin$b = {\n id: id$b,\n detector: detector$b,\n loader: loader$c\n};\nconst xychart = plugin$b;\nconst id$a = \"requirement\";\nconst detector$a = (txt) => {\n return /^\\s*requirement(Diagram)?/.test(txt);\n};\nconst loader$b = async () => {\n const { diagram: diagram2 } = await import(\"./requirementDiagram-6fc4c22a.js\");\n return { id: id$a, diagram: diagram2 };\n};\nconst plugin$a = {\n id: id$a,\n detector: detector$a,\n loader: loader$b\n};\nconst requirement = plugin$a;\nconst id$9 = \"sequence\";\nconst detector$9 = (txt) => {\n return /^\\s*sequenceDiagram/.test(txt);\n};\nconst loader$a = async () => {\n const { diagram: diagram2 } = await import(\"./sequenceDiagram-b655622a.js\");\n return { id: id$9, diagram: diagram2 };\n};\nconst plugin$9 = {\n id: id$9,\n detector: detector$9,\n loader: loader$a\n};\nconst sequence = plugin$9;\nconst id$8 = \"class\";\nconst detector$8 = (txt, config2) => {\n var _a;\n if (((_a = config2 == null ? void 0 : config2.class) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return false;\n }\n return /^\\s*classDiagram/.test(txt);\n};\nconst loader$9 = async () => {\n const { diagram: diagram2 } = await import(\"./classDiagram-936ed81e.js\");\n return { id: id$8, diagram: diagram2 };\n};\nconst plugin$8 = {\n id: id$8,\n detector: detector$8,\n loader: loader$9\n};\nconst classDiagram = plugin$8;\nconst id$7 = \"classDiagram\";\nconst detector$7 = (txt, config2) => {\n var _a;\n if (/^\\s*classDiagram/.test(txt) && ((_a = config2 == null ? void 0 : config2.class) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return true;\n }\n return /^\\s*classDiagram-v2/.test(txt);\n};\nconst loader$8 = async () => {\n const { diagram: diagram2 } = await import(\"./classDiagram-v2-c3cb15f1.js\");\n return { id: id$7, diagram: diagram2 };\n};\nconst plugin$7 = {\n id: id$7,\n detector: detector$7,\n loader: loader$8\n};\nconst classDiagramV2 = plugin$7;\nconst id$6 = \"state\";\nconst detector$6 = (txt, config2) => {\n var _a;\n if (((_a = config2 == null ? void 0 : config2.state) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return false;\n }\n return /^\\s*stateDiagram/.test(txt);\n};\nconst loader$7 = async () => {\n const { diagram: diagram2 } = await import(\"./stateDiagram-59f0c015.js\");\n return { id: id$6, diagram: diagram2 };\n};\nconst plugin$6 = {\n id: id$6,\n detector: detector$6,\n loader: loader$7\n};\nconst state = plugin$6;\nconst id$5 = \"stateDiagram\";\nconst detector$5 = (txt, config2) => {\n var _a;\n if (/^\\s*stateDiagram-v2/.test(txt)) {\n return true;\n }\n if (/^\\s*stateDiagram/.test(txt) && ((_a = config2 == null ? void 0 : config2.state) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return true;\n }\n return false;\n};\nconst loader$6 = async () => {\n const { diagram: diagram2 } = await import(\"./stateDiagram-v2-2b26beab.js\");\n return { id: id$5, diagram: diagram2 };\n};\nconst plugin$5 = {\n id: id$5,\n detector: detector$5,\n loader: loader$6\n};\nconst stateV2 = plugin$5;\nconst id$4 = \"journey\";\nconst detector$4 = (txt) => {\n return /^\\s*journey/.test(txt);\n};\nconst loader$5 = async () => {\n const { diagram: diagram2 } = await import(\"./journeyDiagram-df861f2b.js\");\n return { id: id$4, diagram: diagram2 };\n};\nconst plugin$4 = {\n id: id$4,\n detector: detector$4,\n loader: loader$5\n};\nconst journey = plugin$4;\nconst d3Attrs = function(d3Elem, attrs) {\n for (let attr of attrs) {\n d3Elem.attr(attr[0], attr[1]);\n }\n};\nconst calculateSvgSizeAttrs = function(height, width, useMaxWidth) {\n let attrs = /* @__PURE__ */ new Map();\n if (useMaxWidth) {\n attrs.set(\"width\", \"100%\");\n attrs.set(\"style\", `max-width: ${width}px;`);\n } else {\n attrs.set(\"height\", height);\n attrs.set(\"width\", width);\n }\n return attrs;\n};\nconst configureSvgSize = function(svgElem, height, width, useMaxWidth) {\n const attrs = calculateSvgSizeAttrs(height, width, useMaxWidth);\n d3Attrs(svgElem, attrs);\n};\nconst setupGraphViewbox$1 = function(graph, svgElem, padding, useMaxWidth) {\n const svgBounds = svgElem.node().getBBox();\n const sWidth = svgBounds.width;\n const sHeight = svgBounds.height;\n log$1.info(`SVG bounds: ${sWidth}x${sHeight}`, svgBounds);\n let width = 0;\n let height = 0;\n log$1.info(`Graph bounds: ${width}x${height}`, graph);\n width = sWidth + padding * 2;\n height = sHeight + padding * 2;\n log$1.info(`Calculated bounds: ${width}x${height}`);\n configureSvgSize(svgElem, height, width, useMaxWidth);\n const vBox = `${svgBounds.x - padding} ${svgBounds.y - padding} ${svgBounds.width + 2 * padding} ${svgBounds.height + 2 * padding}`;\n svgElem.attr(\"viewBox\", vBox);\n};\nconst themes = {};\nconst getStyles = (type2, userStyles, options) => {\n let diagramStyles = \"\";\n if (type2 in themes && themes[type2]) {\n diagramStyles = themes[type2](options);\n } else {\n log$1.warn(`No theme found for ${type2}`);\n }\n return ` & {\n font-family: ${options.fontFamily};\n font-size: ${options.fontSize};\n fill: ${options.textColor}\n }\n\n /* Classes common for multiple diagrams */\n\n & .error-icon {\n fill: ${options.errorBkgColor};\n }\n & .error-text {\n fill: ${options.errorTextColor};\n stroke: ${options.errorTextColor};\n }\n\n & .edge-thickness-normal {\n stroke-width: 2px;\n }\n & .edge-thickness-thick {\n stroke-width: 3.5px\n }\n & .edge-pattern-solid {\n stroke-dasharray: 0;\n }\n\n & .edge-pattern-dashed{\n stroke-dasharray: 3;\n }\n .edge-pattern-dotted {\n stroke-dasharray: 2;\n }\n\n & .marker {\n fill: ${options.lineColor};\n stroke: ${options.lineColor};\n }\n & .marker.cross {\n stroke: ${options.lineColor};\n }\n\n & svg {\n font-family: ${options.fontFamily};\n font-size: ${options.fontSize};\n }\n\n ${diagramStyles}\n\n ${userStyles}\n`;\n};\nconst addStylesForDiagram = (type2, diagramTheme) => {\n if (diagramTheme !== void 0) {\n themes[type2] = diagramTheme;\n }\n};\nconst getStyles$1 = getStyles;\nlet accTitle = \"\";\nlet diagramTitle = \"\";\nlet accDescription = \"\";\nconst sanitizeText$1 = (txt) => sanitizeText$2(txt, getConfig$1());\nconst clear = () => {\n accTitle = \"\";\n accDescription = \"\";\n diagramTitle = \"\";\n};\nconst setAccTitle = (txt) => {\n accTitle = sanitizeText$1(txt).replace(/^\\s+/g, \"\");\n};\nconst getAccTitle = () => accTitle;\nconst setAccDescription = (txt) => {\n accDescription = sanitizeText$1(txt).replace(/\\n\\s+/g, \"\\n\");\n};\nconst getAccDescription = () => accDescription;\nconst setDiagramTitle = (txt) => {\n diagramTitle = sanitizeText$1(txt);\n};\nconst getDiagramTitle = () => diagramTitle;\nconst commonDb = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({\n __proto__: null,\n clear,\n getAccDescription,\n getAccTitle,\n getDiagramTitle,\n setAccDescription,\n setAccTitle,\n setDiagramTitle\n}, Symbol.toStringTag, { value: \"Module\" }));\nconst log = log$1;\nconst setLogLevel = setLogLevel$1;\nconst getConfig = getConfig$1;\nconst setConfig = setConfig$1;\nconst defaultConfig = defaultConfig$1;\nconst sanitizeText = (text) => sanitizeText$2(text, getConfig());\nconst setupGraphViewbox = setupGraphViewbox$1;\nconst getCommonDb = () => {\n return commonDb;\n};\nconst diagrams = {};\nconst registerDiagram = (id2, diagram2, detector2) => {\n var _a;\n if (diagrams[id2]) {\n throw new Error(`Diagram ${id2} already registered.`);\n }\n diagrams[id2] = diagram2;\n if (detector2) {\n addDetector(id2, detector2);\n }\n addStylesForDiagram(id2, diagram2.styles);\n (_a = diagram2.injectUtils) == null ? void 0 : _a.call(\n diagram2,\n log,\n setLogLevel,\n getConfig,\n sanitizeText,\n setupGraphViewbox,\n getCommonDb(),\n () => {\n }\n );\n};\nconst getDiagram = (name) => {\n if (name in diagrams) {\n return diagrams[name];\n }\n throw new DiagramNotFoundError(name);\n};\nclass DiagramNotFoundError extends Error {\n constructor(name) {\n super(`Diagram ${name} not found.`);\n }\n}\nconst selectSvgElement = (id2) => {\n var _a;\n const { securityLevel } = getConfig();\n let root = select(\"body\");\n if (securityLevel === \"sandbox\") {\n const sandboxElement = select(`#i${id2}`);\n const doc = ((_a = sandboxElement.node()) == null ? void 0 : _a.contentDocument) ?? document;\n root = select(doc.body);\n }\n const svg = root.select(`#${id2}`);\n return svg;\n};\nconst draw = (_text, id2, version2) => {\n log$1.debug(\"renering svg for syntax error\\n\");\n const svg = selectSvgElement(id2);\n svg.attr(\"viewBox\", \"0 0 2412 512\");\n configureSvgSize(svg, 100, 512, true);\n const g = svg.append(\"g\");\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z\"\n );\n g.append(\"text\").attr(\"class\", \"error-text\").attr(\"x\", 1440).attr(\"y\", 250).attr(\"font-size\", \"150px\").style(\"text-anchor\", \"middle\").text(\"Syntax error in text\");\n g.append(\"text\").attr(\"class\", \"error-text\").attr(\"x\", 1250).attr(\"y\", 400).attr(\"font-size\", \"100px\").style(\"text-anchor\", \"middle\").text(`mermaid version ${version2}`);\n};\nconst renderer = { draw };\nconst errorRenderer = renderer;\nconst diagram = {\n db: {},\n renderer,\n parser: {\n parser: { yy: {} },\n parse: () => {\n return;\n }\n }\n};\nconst errorDiagram = diagram;\nconst id$3 = \"flowchart-elk\";\nconst detector$3 = (txt, config2) => {\n var _a;\n if (\n // If diagram explicitly states flowchart-elk\n /^\\s*flowchart-elk/.test(txt) || // If a flowchart/graph diagram has their default renderer set to elk\n /^\\s*flowchart|graph/.test(txt) && ((_a = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _a.defaultRenderer) === \"elk\"\n ) {\n return true;\n }\n return false;\n};\nconst loader$4 = async () => {\n const { diagram: diagram2 } = await import(\"./flowchart-elk-definition-abe16c3d.js\");\n return { id: id$3, diagram: diagram2 };\n};\nconst plugin$3 = {\n id: id$3,\n detector: detector$3,\n loader: loader$4\n};\nconst flowchartElk = plugin$3;\nconst id$2 = \"timeline\";\nconst detector$2 = (txt) => {\n return /^\\s*timeline/.test(txt);\n};\nconst loader$3 = async () => {\n const { diagram: diagram2 } = await import(\"./timeline-definition-5b62e21b.js\");\n return { id: id$2, diagram: diagram2 };\n};\nconst plugin$2 = {\n id: id$2,\n detector: detector$2,\n loader: loader$3\n};\nconst timeline = plugin$2;\nconst id$1 = \"mindmap\";\nconst detector$1 = (txt) => {\n return /^\\s*mindmap/.test(txt);\n};\nconst loader$2 = async () => {\n const { diagram: diagram2 } = await import(\"./mindmap-definition-beec6740.js\");\n return { id: id$1, diagram: diagram2 };\n};\nconst plugin$1 = {\n id: id$1,\n detector: detector$1,\n loader: loader$2\n};\nconst mindmap = plugin$1;\nconst id = \"sankey\";\nconst detector = (txt) => {\n return /^\\s*sankey-beta/.test(txt);\n};\nconst loader$1 = async () => {\n const { diagram: diagram2 } = await import(\"./sankeyDiagram-8f13d901.js\");\n return { id, diagram: diagram2 };\n};\nconst plugin = {\n id,\n detector,\n loader: loader$1\n};\nconst sankey = plugin;\nlet hasLoadedDiagrams = false;\nconst addDiagrams = () => {\n if (hasLoadedDiagrams) {\n return;\n }\n hasLoadedDiagrams = true;\n registerDiagram(\"error\", errorDiagram, (text) => {\n return text.toLowerCase().trim() === \"error\";\n });\n registerDiagram(\n \"---\",\n // --- diagram type may appear if YAML front-matter is not parsed correctly\n {\n db: {\n clear: () => {\n }\n },\n styles: {},\n // should never be used\n renderer: {\n draw: () => {\n }\n },\n parser: {\n parser: { yy: {} },\n parse: () => {\n throw new Error(\n \"Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks\"\n );\n }\n },\n init: () => null\n // no op\n },\n (text) => {\n return text.toLowerCase().trimStart().startsWith(\"---\");\n }\n );\n registerLazyLoadedDiagrams(\n c4,\n classDiagramV2,\n classDiagram,\n er,\n gantt,\n info,\n pie,\n requirement,\n sequence,\n flowchartElk,\n flowchartV2,\n flowchart,\n mindmap,\n timeline,\n git,\n stateV2,\n state,\n journey,\n quadrantChart,\n sankey,\n xychart\n );\n};\nclass Diagram {\n constructor(text, metadata = {}) {\n this.text = text;\n this.metadata = metadata;\n this.type = \"graph\";\n this.text += \"\\n\";\n const cnf = getConfig$1();\n try {\n this.type = detectType(text, cnf);\n } catch (e) {\n this.type = \"error\";\n this.detectError = e;\n }\n const diagram2 = getDiagram(this.type);\n log$1.debug(\"Type \" + this.type);\n this.db = diagram2.db;\n this.renderer = diagram2.renderer;\n this.parser = diagram2.parser;\n this.parser.parser.yy = this.db;\n this.init = diagram2.init;\n this.parse();\n }\n parse() {\n var _a, _b, _c, _d, _e;\n if (this.detectError) {\n throw this.detectError;\n }\n (_b = (_a = this.db).clear) == null ? void 0 : _b.call(_a);\n const config2 = getConfig$1();\n (_c = this.init) == null ? void 0 : _c.call(this, config2);\n if (this.metadata.title) {\n (_e = (_d = this.db).setDiagramTitle) == null ? void 0 : _e.call(_d, this.metadata.title);\n }\n this.parser.parse(this.text);\n }\n async render(id2, version2) {\n await this.renderer.draw(this.text, id2, version2, this);\n }\n getParser() {\n return this.parser;\n }\n getType() {\n return this.type;\n }\n}\nconst getDiagramFromText = async (text, metadata = {}) => {\n const type2 = detectType(text, getConfig$1());\n try {\n getDiagram(type2);\n } catch (error) {\n const loader2 = getDiagramLoader(type2);\n if (!loader2) {\n throw new UnknownDiagramError(`Diagram ${type2} not found.`);\n }\n const { id: id2, diagram: diagram2 } = await loader2();\n registerDiagram(id2, diagram2);\n }\n return new Diagram(text, metadata);\n};\nlet interactionFunctions = [];\nconst addFunction = (func) => {\n interactionFunctions.push(func);\n};\nconst attachFunctions = () => {\n interactionFunctions.forEach((f) => {\n f();\n });\n interactionFunctions = [];\n};\nconst SVG_ROLE = \"graphics-document document\";\nfunction setA11yDiagramInfo(svg, diagramType) {\n svg.attr(\"role\", SVG_ROLE);\n if (diagramType !== \"\") {\n svg.attr(\"aria-roledescription\", diagramType);\n }\n}\nfunction addSVGa11yTitleDescription(svg, a11yTitle, a11yDesc, baseId) {\n if (svg.insert === void 0) {\n return;\n }\n if (a11yDesc) {\n const descId = `chart-desc-${baseId}`;\n svg.attr(\"aria-describedby\", descId);\n svg.insert(\"desc\", \":first-child\").attr(\"id\", descId).text(a11yDesc);\n }\n if (a11yTitle) {\n const titleId = `chart-title-${baseId}`;\n svg.attr(\"aria-labelledby\", titleId);\n svg.insert(\"title\", \":first-child\").attr(\"id\", titleId).text(a11yTitle);\n }\n}\nconst cleanupComments = (text) => {\n return text.replace(/^\\s*%%(?!{)[^\\n]+\\n?/gm, \"\").trimStart();\n};\n/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */\nfunction isNothing(subject) {\n return typeof subject === \"undefined\" || subject === null;\n}\nfunction isObject(subject) {\n return typeof subject === \"object\" && subject !== null;\n}\nfunction toArray(sequence2) {\n if (Array.isArray(sequence2))\n return sequence2;\n else if (isNothing(sequence2))\n return [];\n return [sequence2];\n}\nfunction extend(target, source) {\n var index, length, key, sourceKeys;\n if (source) {\n sourceKeys = Object.keys(source);\n for (index = 0, length = sourceKeys.length; index < length; index += 1) {\n key = sourceKeys[index];\n target[key] = source[key];\n }\n }\n return target;\n}\nfunction repeat(string, count) {\n var result = \"\", cycle;\n for (cycle = 0; cycle < count; cycle += 1) {\n result += string;\n }\n return result;\n}\nfunction isNegativeZero(number) {\n return number === 0 && Number.NEGATIVE_INFINITY === 1 / number;\n}\nvar isNothing_1 = isNothing;\nvar isObject_1 = isObject;\nvar toArray_1 = toArray;\nvar repeat_1 = repeat;\nvar isNegativeZero_1 = isNegativeZero;\nvar extend_1 = extend;\nvar common = {\n isNothing: isNothing_1,\n isObject: isObject_1,\n toArray: toArray_1,\n repeat: repeat_1,\n isNegativeZero: isNegativeZero_1,\n extend: extend_1\n};\nfunction formatError(exception2, compact) {\n var where = \"\", message = exception2.reason || \"(unknown reason)\";\n if (!exception2.mark)\n return message;\n if (exception2.mark.name) {\n where += 'in \"' + exception2.mark.name + '\" ';\n }\n where += \"(\" + (exception2.mark.line + 1) + \":\" + (exception2.mark.column + 1) + \")\";\n if (!compact && exception2.mark.snippet) {\n where += \"\\n\\n\" + exception2.mark.snippet;\n }\n return message + \" \" + where;\n}\nfunction YAMLException$1(reason, mark) {\n Error.call(this);\n this.name = \"YAMLException\";\n this.reason = reason;\n this.mark = mark;\n this.message = formatError(this, false);\n if (Error.captureStackTrace) {\n Error.captureStackTrace(this, this.constructor);\n } else {\n this.stack = new Error().stack || \"\";\n }\n}\nYAMLException$1.prototype = Object.create(Error.prototype);\nYAMLException$1.prototype.constructor = YAMLException$1;\nYAMLException$1.prototype.toString = function toString(compact) {\n return this.name + \": \" + formatError(this, compact);\n};\nvar exception = YAMLException$1;\nfunction getLine(buffer, lineStart, lineEnd, position, maxLineLength) {\n var head = \"\";\n var tail = \"\";\n var maxHalfLength = Math.floor(maxLineLength / 2) - 1;\n if (position - lineStart > maxHalfLength) {\n head = \" ... \";\n lineStart = position - maxHalfLength + head.length;\n }\n if (lineEnd - position > maxHalfLength) {\n tail = \" ...\";\n lineEnd = position + maxHalfLength - tail.length;\n }\n return {\n str: head + buffer.slice(lineStart, lineEnd).replace(/\\t/g, \"\u2192\") + tail,\n pos: position - lineStart + head.length\n // relative position\n };\n}\nfunction padStart(string, max) {\n return common.repeat(\" \", max - string.length) + string;\n}\nfunction makeSnippet(mark, options) {\n options = Object.create(options || null);\n if (!mark.buffer)\n return null;\n if (!options.maxLength)\n options.maxLength = 79;\n if (typeof options.indent !== \"number\")\n options.indent = 1;\n if (typeof options.linesBefore !== \"number\")\n options.linesBefore = 3;\n if (typeof options.linesAfter !== \"number\")\n options.linesAfter = 2;\n var re = /\\r?\\n|\\r|\\0/g;\n var lineStarts = [0];\n var lineEnds = [];\n var match;\n var foundLineNo = -1;\n while (match = re.exec(mark.buffer)) {\n lineEnds.push(match.index);\n lineStarts.push(match.index + match[0].length);\n if (mark.position <= match.index && foundLineNo < 0) {\n foundLineNo = lineStarts.length - 2;\n }\n }\n if (foundLineNo < 0)\n foundLineNo = lineStarts.length - 1;\n var result = \"\", i, line;\n var lineNoLength = Math.min(mark.line + options.linesAfter, lineEnds.length).toString().length;\n var maxLineLength = options.maxLength - (options.indent + lineNoLength + 3);\n for (i = 1; i <= options.linesBefore; i++) {\n if (foundLineNo - i < 0)\n break;\n line = getLine(\n mark.buffer,\n lineStarts[foundLineNo - i],\n lineEnds[foundLineNo - i],\n mark.position - (lineStarts[foundLineNo] - lineStarts[foundLineNo - i]),\n maxLineLength\n );\n result = common.repeat(\" \", options.indent) + padStart((mark.line - i + 1).toString(), lineNoLength) + \" | \" + line.str + \"\\n\" + result;\n }\n line = getLine(mark.buffer, lineStarts[foundLineNo], lineEnds[foundLineNo], mark.position, maxLineLength);\n result += common.repeat(\" \", options.indent) + padStart((mark.line + 1).toString(), lineNoLength) + \" | \" + line.str + \"\\n\";\n result += common.repeat(\"-\", options.indent + lineNoLength + 3 + line.pos) + \"^\\n\";\n for (i = 1; i <= options.linesAfter; i++) {\n if (foundLineNo + i >= lineEnds.length)\n break;\n line = getLine(\n mark.buffer,\n lineStarts[foundLineNo + i],\n lineEnds[foundLineNo + i],\n mark.position - (lineStarts[foundLineNo] - lineStarts[foundLineNo + i]),\n maxLineLength\n );\n result += common.repeat(\" \", options.indent) + padStart((mark.line + i + 1).toString(), lineNoLength) + \" | \" + line.str + \"\\n\";\n }\n return result.replace(/\\n$/, \"\");\n}\nvar snippet = makeSnippet;\nvar TYPE_CONSTRUCTOR_OPTIONS = [\n \"kind\",\n \"multi\",\n \"resolve\",\n \"construct\",\n \"instanceOf\",\n \"predicate\",\n \"represent\",\n \"representName\",\n \"defaultStyle\",\n \"styleAliases\"\n];\nvar YAML_NODE_KINDS = [\n \"scalar\",\n \"sequence\",\n \"mapping\"\n];\nfunction compileStyleAliases(map2) {\n var result = {};\n if (map2 !== null) {\n Object.keys(map2).forEach(function(style) {\n map2[style].forEach(function(alias) {\n result[String(alias)] = style;\n });\n });\n }\n return result;\n}\nfunction Type$1(tag, options) {\n options = options || {};\n Object.keys(options).forEach(function(name) {\n if (TYPE_CONSTRUCTOR_OPTIONS.indexOf(name) === -1) {\n throw new exception('Unknown option \"' + name + '\" is met in definition of \"' + tag + '\" YAML type.');\n }\n });\n this.options = options;\n this.tag = tag;\n this.kind = options[\"kind\"] || null;\n this.resolve = options[\"resolve\"] || function() {\n return true;\n };\n this.construct = options[\"construct\"] || function(data) {\n return data;\n };\n this.instanceOf = options[\"instanceOf\"] || null;\n this.predicate = options[\"predicate\"] || null;\n this.represent = options[\"represent\"] || null;\n this.representName = options[\"representName\"] || null;\n this.defaultStyle = options[\"defaultStyle\"] || null;\n this.multi = options[\"multi\"] || false;\n this.styleAliases = compileStyleAliases(options[\"styleAliases\"] || null);\n if (YAML_NODE_KINDS.indexOf(this.kind) === -1) {\n throw new exception('Unknown kind \"' + this.kind + '\" is specified for \"' + tag + '\" YAML type.');\n }\n}\nvar type = Type$1;\nfunction compileList(schema2, name) {\n var result = [];\n schema2[name].forEach(function(currentType) {\n var newIndex = result.length;\n result.forEach(function(previousType, previousIndex) {\n if (previousType.tag === currentType.tag && previousType.kind === currentType.kind && previousType.multi === currentType.multi) {\n newIndex = previousIndex;\n }\n });\n result[newIndex] = currentType;\n });\n return result;\n}\nfunction compileMap() {\n var result = {\n scalar: {},\n sequence: {},\n mapping: {},\n fallback: {},\n multi: {\n scalar: [],\n sequence: [],\n mapping: [],\n fallback: []\n }\n }, index, length;\n function collectType(type2) {\n if (type2.multi) {\n result.multi[type2.kind].push(type2);\n result.multi[\"fallback\"].push(type2);\n } else {\n result[type2.kind][type2.tag] = result[\"fallback\"][type2.tag] = type2;\n }\n }\n for (index = 0, length = arguments.length; index < length; index += 1) {\n arguments[index].forEach(collectType);\n }\n return result;\n}\nfunction Schema$1(definition) {\n return this.extend(definition);\n}\nSchema$1.prototype.extend = function extend2(definition) {\n var implicit = [];\n var explicit = [];\n if (definition instanceof type) {\n explicit.push(definition);\n } else if (Array.isArray(definition)) {\n explicit = explicit.concat(definition);\n } else if (definition && (Array.isArray(definition.implicit) || Array.isArray(definition.explicit))) {\n if (definition.implicit)\n implicit = implicit.concat(definition.implicit);\n if (definition.explicit)\n explicit = explicit.concat(definition.explicit);\n } else {\n throw new exception(\"Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })\");\n }\n implicit.forEach(function(type$1) {\n if (!(type$1 instanceof type)) {\n throw new exception(\"Specified list of YAML types (or a single Type object) contains a non-Type object.\");\n }\n if (type$1.loadKind && type$1.loadKind !== \"scalar\") {\n throw new exception(\"There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.\");\n }\n if (type$1.multi) {\n throw new exception(\"There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.\");\n }\n });\n explicit.forEach(function(type$1) {\n if (!(type$1 instanceof type)) {\n throw new exception(\"Specified list of YAML types (or a single Type object) contains a non-Type object.\");\n }\n });\n var result = Object.create(Schema$1.prototype);\n result.implicit = (this.implicit || []).concat(implicit);\n result.explicit = (this.explicit || []).concat(explicit);\n result.compiledImplicit = compileList(result, \"implicit\");\n result.compiledExplicit = compileList(result, \"explicit\");\n result.compiledTypeMap = compileMap(result.compiledImplicit, result.compiledExplicit);\n return result;\n};\nvar schema = Schema$1;\nvar str = new type(\"tag:yaml.org,2002:str\", {\n kind: \"scalar\",\n construct: function(data) {\n return data !== null ? data : \"\";\n }\n});\nvar seq = new type(\"tag:yaml.org,2002:seq\", {\n kind: \"sequence\",\n construct: function(data) {\n return data !== null ? data : [];\n }\n});\nvar map = new type(\"tag:yaml.org,2002:map\", {\n kind: \"mapping\",\n construct: function(data) {\n return data !== null ? data : {};\n }\n});\nvar failsafe = new schema({\n explicit: [\n str,\n seq,\n map\n ]\n});\nfunction resolveYamlNull(data) {\n if (data === null)\n return true;\n var max = data.length;\n return max === 1 && data === \"~\" || max === 4 && (data === \"null\" || data === \"Null\" || data === \"NULL\");\n}\nfunction constructYamlNull() {\n return null;\n}\nfunction isNull(object) {\n return object === null;\n}\nvar _null = new type(\"tag:yaml.org,2002:null\", {\n kind: \"scalar\",\n resolve: resolveYamlNull,\n construct: constructYamlNull,\n predicate: isNull,\n represent: {\n canonical: function() {\n return \"~\";\n },\n lowercase: function() {\n return \"null\";\n },\n uppercase: function() {\n return \"NULL\";\n },\n camelcase: function() {\n return \"Null\";\n },\n empty: function() {\n return \"\";\n }\n },\n defaultStyle: \"lowercase\"\n});\nfunction resolveYamlBoolean(data) {\n if (data === null)\n return false;\n var max = data.length;\n return max === 4 && (data === \"true\" || data === \"True\" || data === \"TRUE\") || max === 5 && (data === \"false\" || data === \"False\" || data === \"FALSE\");\n}\nfunction constructYamlBoolean(data) {\n return data === \"true\" || data === \"True\" || data === \"TRUE\";\n}\nfunction isBoolean(object) {\n return Object.prototype.toString.call(object) === \"[object Boolean]\";\n}\nvar bool = new type(\"tag:yaml.org,2002:bool\", {\n kind: \"scalar\",\n resolve: resolveYamlBoolean,\n construct: constructYamlBoolean,\n predicate: isBoolean,\n represent: {\n lowercase: function(object) {\n return object ? \"true\" : \"false\";\n },\n uppercase: function(object) {\n return object ? \"TRUE\" : \"FALSE\";\n },\n camelcase: function(object) {\n return object ? \"True\" : \"False\";\n }\n },\n defaultStyle: \"lowercase\"\n});\nfunction isHexCode(c) {\n return 48 <= c && c <= 57 || 65 <= c && c <= 70 || 97 <= c && c <= 102;\n}\nfunction isOctCode(c) {\n return 48 <= c && c <= 55;\n}\nfunction isDecCode(c) {\n return 48 <= c && c <= 57;\n}\nfunction resolveYamlInteger(data) {\n if (data === null)\n return false;\n var max = data.length, index = 0, hasDigits = false, ch;\n if (!max)\n return false;\n ch = data[index];\n if (ch === \"-\" || ch === \"+\") {\n ch = data[++index];\n }\n if (ch === \"0\") {\n if (index + 1 === max)\n return true;\n ch = data[++index];\n if (ch === \"b\") {\n index++;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (ch !== \"0\" && ch !== \"1\")\n return false;\n hasDigits = true;\n }\n return hasDigits && ch !== \"_\";\n }\n if (ch === \"x\") {\n index++;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (!isHexCode(data.charCodeAt(index)))\n return false;\n hasDigits = true;\n }\n return hasDigits && ch !== \"_\";\n }\n if (ch === \"o\") {\n index++;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (!isOctCode(data.charCodeAt(index)))\n return false;\n hasDigits = true;\n }\n return hasDigits && ch !== \"_\";\n }\n }\n if (ch === \"_\")\n return false;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (!isDecCode(data.charCodeAt(index))) {\n return false;\n }\n hasDigits = true;\n }\n if (!hasDigits || ch === \"_\")\n return false;\n return true;\n}\nfunction constructYamlInteger(data) {\n var value = data, sign = 1, ch;\n if (value.indexOf(\"_\") !== -1) {\n value = value.replace(/_/g, \"\");\n }\n ch = value[0];\n if (ch === \"-\" || ch === \"+\") {\n if (ch === \"-\")\n sign = -1;\n value = value.slice(1);\n ch = value[0];\n }\n if (value === \"0\")\n return 0;\n if (ch === \"0\") {\n if (value[1] === \"b\")\n return sign * parseInt(value.slice(2), 2);\n if (value[1] === \"x\")\n return sign * parseInt(value.slice(2), 16);\n if (value[1] === \"o\")\n return sign * parseInt(value.slice(2), 8);\n }\n return sign * parseInt(value, 10);\n}\nfunction isInteger(object) {\n return Object.prototype.toString.call(object) === \"[object Number]\" && (object % 1 === 0 && !common.isNegativeZero(object));\n}\nvar int = new type(\"tag:yaml.org,2002:int\", {\n kind: \"scalar\",\n resolve: resolveYamlInteger,\n construct: constructYamlInteger,\n predicate: isInteger,\n represent: {\n binary: function(obj) {\n return obj >= 0 ? \"0b\" + obj.toString(2) : \"-0b\" + obj.toString(2).slice(1);\n },\n octal: function(obj) {\n return obj >= 0 ? \"0o\" + obj.toString(8) : \"-0o\" + obj.toString(8).slice(1);\n },\n decimal: function(obj) {\n return obj.toString(10);\n },\n /* eslint-disable max-len */\n hexadecimal: function(obj) {\n return obj >= 0 ? \"0x\" + obj.toString(16).toUpperCase() : \"-0x\" + obj.toString(16).toUpperCase().slice(1);\n }\n },\n defaultStyle: \"decimal\",\n styleAliases: {\n binary: [2, \"bin\"],\n octal: [8, \"oct\"],\n decimal: [10, \"dec\"],\n hexadecimal: [16, \"hex\"]\n }\n});\nvar YAML_FLOAT_PATTERN = new RegExp(\n // 2.5e4, 2.5 and integers\n \"^(?:[-+]?(?:[0-9][0-9_]*)(?:\\\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\\\.(?:inf|Inf|INF)|\\\\.(?:nan|NaN|NAN))$\"\n);\nfunction resolveYamlFloat(data) {\n if (data === null)\n return false;\n if (!YAML_FLOAT_PATTERN.test(data) || // Quick hack to not allow integers end with `_`\n // Probably should update regexp & check speed\n data[data.length - 1] === \"_\") {\n return false;\n }\n return true;\n}\nfunction constructYamlFloat(data) {\n var value, sign;\n value = data.replace(/_/g, \"\").toLowerCase();\n sign = value[0] === \"-\" ? -1 : 1;\n if (\"+-\".indexOf(value[0]) >= 0) {\n value = value.slice(1);\n }\n if (value === \".inf\") {\n return sign === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY;\n } else if (value === \".nan\") {\n return NaN;\n }\n return sign * parseFloat(value, 10);\n}\nvar SCIENTIFIC_WITHOUT_DOT = /^[-+]?[0-9]+e/;\nfunction representYamlFloat(object, style) {\n var res;\n if (isNaN(object)) {\n switch (style) {\n case \"lowercase\":\n return \".nan\";\n case \"uppercase\":\n return \".NAN\";\n case \"camelcase\":\n return \".NaN\";\n }\n } else if (Number.POSITIVE_INFINITY === object) {\n switch (style) {\n case \"lowercase\":\n return \".inf\";\n case \"uppercase\":\n return \".INF\";\n case \"camelcase\":\n return \".Inf\";\n }\n } else if (Number.NEGATIVE_INFINITY === object) {\n switch (style) {\n case \"lowercase\":\n return \"-.inf\";\n case \"uppercase\":\n return \"-.INF\";\n case \"camelcase\":\n return \"-.Inf\";\n }\n } else if (common.isNegativeZero(object)) {\n return \"-0.0\";\n }\n res = object.toString(10);\n return SCIENTIFIC_WITHOUT_DOT.test(res) ? res.replace(\"e\", \".e\") : res;\n}\nfunction isFloat(object) {\n return Object.prototype.toString.call(object) === \"[object Number]\" && (object % 1 !== 0 || common.isNegativeZero(object));\n}\nvar float = new type(\"tag:yaml.org,2002:float\", {\n kind: \"scalar\",\n resolve: resolveYamlFloat,\n construct: constructYamlFloat,\n predicate: isFloat,\n represent: representYamlFloat,\n defaultStyle: \"lowercase\"\n});\nvar json = failsafe.extend({\n implicit: [\n _null,\n bool,\n int,\n float\n ]\n});\nvar core = json;\nvar YAML_DATE_REGEXP = new RegExp(\n \"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$\"\n);\nvar YAML_TIMESTAMP_REGEXP = new RegExp(\n \"^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\\\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\\\.([0-9]*))?(?:[ \\\\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$\"\n);\nfunction resolveYamlTimestamp(data) {\n if (data === null)\n return false;\n if (YAML_DATE_REGEXP.exec(data) !== null)\n return true;\n if (YAML_TIMESTAMP_REGEXP.exec(data) !== null)\n return true;\n return false;\n}\nfunction constructYamlTimestamp(data) {\n var match, year, month, day, hour, minute, second, fraction = 0, delta = null, tz_hour, tz_minute, date;\n match = YAML_DATE_REGEXP.exec(data);\n if (match === null)\n match = YAML_TIMESTAMP_REGEXP.exec(data);\n if (match === null)\n throw new Error(\"Date resolve error\");\n year = +match[1];\n month = +match[2] - 1;\n day = +match[3];\n if (!match[4]) {\n return new Date(Date.UTC(year, month, day));\n }\n hour = +match[4];\n minute = +match[5];\n second = +match[6];\n if (match[7]) {\n fraction = match[7].slice(0, 3);\n while (fraction.length < 3) {\n fraction += \"0\";\n }\n fraction = +fraction;\n }\n if (match[9]) {\n tz_hour = +match[10];\n tz_minute = +(match[11] || 0);\n delta = (tz_hour * 60 + tz_minute) * 6e4;\n if (match[9] === \"-\")\n delta = -delta;\n }\n date = new Date(Date.UTC(year, month, day, hour, minute, second, fraction));\n if (delta)\n date.setTime(date.getTime() - delta);\n return date;\n}\nfunction representYamlTimestamp(object) {\n return object.toISOString();\n}\nvar timestamp = new type(\"tag:yaml.org,2002:timestamp\", {\n kind: \"scalar\",\n resolve: resolveYamlTimestamp,\n construct: constructYamlTimestamp,\n instanceOf: Date,\n represent: representYamlTimestamp\n});\nfunction resolveYamlMerge(data) {\n return data === \"<<\" || data === null;\n}\nvar merge = new type(\"tag:yaml.org,2002:merge\", {\n kind: \"scalar\",\n resolve: resolveYamlMerge\n});\nvar BASE64_MAP = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\\n\\r\";\nfunction resolveYamlBinary(data) {\n if (data === null)\n return false;\n var code, idx, bitlen = 0, max = data.length, map2 = BASE64_MAP;\n for (idx = 0; idx < max; idx++) {\n code = map2.indexOf(data.charAt(idx));\n if (code > 64)\n continue;\n if (code < 0)\n return false;\n bitlen += 6;\n }\n return bitlen % 8 === 0;\n}\nfunction constructYamlBinary(data) {\n var idx, tailbits, input = data.replace(/[\\r\\n=]/g, \"\"), max = input.length, map2 = BASE64_MAP, bits = 0, result = [];\n for (idx = 0; idx < max; idx++) {\n if (idx % 4 === 0 && idx) {\n result.push(bits >> 16 & 255);\n result.push(bits >> 8 & 255);\n result.push(bits & 255);\n }\n bits = bits << 6 | map2.indexOf(input.charAt(idx));\n }\n tailbits = max % 4 * 6;\n if (tailbits === 0) {\n result.push(bits >> 16 & 255);\n result.push(bits >> 8 & 255);\n result.push(bits & 255);\n } else if (tailbits === 18) {\n result.push(bits >> 10 & 255);\n result.push(bits >> 2 & 255);\n } else if (tailbits === 12) {\n result.push(bits >> 4 & 255);\n }\n return new Uint8Array(result);\n}\nfunction representYamlBinary(object) {\n var result = \"\", bits = 0, idx, tail, max = object.length, map2 = BASE64_MAP;\n for (idx = 0; idx < max; idx++) {\n if (idx % 3 === 0 && idx) {\n result += map2[bits >> 18 & 63];\n result += map2[bits >> 12 & 63];\n result += map2[bits >> 6 & 63];\n result += map2[bits & 63];\n }\n bits = (bits << 8) + object[idx];\n }\n tail = max % 3;\n if (tail === 0) {\n result += map2[bits >> 18 & 63];\n result += map2[bits >> 12 & 63];\n result += map2[bits >> 6 & 63];\n result += map2[bits & 63];\n } else if (tail === 2) {\n result += map2[bits >> 10 & 63];\n result += map2[bits >> 4 & 63];\n result += map2[bits << 2 & 63];\n result += map2[64];\n } else if (tail === 1) {\n result += map2[bits >> 2 & 63];\n result += map2[bits << 4 & 63];\n result += map2[64];\n result += map2[64];\n }\n return result;\n}\nfunction isBinary(obj) {\n return Object.prototype.toString.call(obj) === \"[object Uint8Array]\";\n}\nvar binary = new type(\"tag:yaml.org,2002:binary\", {\n kind: \"scalar\",\n resolve: resolveYamlBinary,\n construct: constructYamlBinary,\n predicate: isBinary,\n represent: representYamlBinary\n});\nvar _hasOwnProperty$3 = Object.prototype.hasOwnProperty;\nvar _toString$2 = Object.prototype.toString;\nfunction resolveYamlOmap(data) {\n if (data === null)\n return true;\n var objectKeys = [], index, length, pair, pairKey, pairHasKey, object = data;\n for (index = 0, length = object.length; index < length; index += 1) {\n pair = object[index];\n pairHasKey = false;\n if (_toString$2.call(pair) !== \"[object Object]\")\n return false;\n for (pairKey in pair) {\n if (_hasOwnProperty$3.call(pair, pairKey)) {\n if (!pairHasKey)\n pairHasKey = true;\n else\n return false;\n }\n }\n if (!pairHasKey)\n return false;\n if (objectKeys.indexOf(pairKey) === -1)\n objectKeys.push(pairKey);\n else\n return false;\n }\n return true;\n}\nfunction constructYamlOmap(data) {\n return data !== null ? data : [];\n}\nvar omap = new type(\"tag:yaml.org,2002:omap\", {\n kind: \"sequence\",\n resolve: resolveYamlOmap,\n construct: constructYamlOmap\n});\nvar _toString$1 = Object.prototype.toString;\nfunction resolveYamlPairs(data) {\n if (data === null)\n return true;\n var index, length, pair, keys, result, object = data;\n result = new Array(object.length);\n for (index = 0, length = object.length; index < length; index += 1) {\n pair = object[index];\n if (_toString$1.call(pair) !== \"[object Object]\")\n return false;\n keys = Object.keys(pair);\n if (keys.length !== 1)\n return false;\n result[index] = [keys[0], pair[keys[0]]];\n }\n return true;\n}\nfunction constructYamlPairs(data) {\n if (data === null)\n return [];\n var index, length, pair, keys, result, object = data;\n result = new Array(object.length);\n for (index = 0, length = object.length; index < length; index += 1) {\n pair = object[index];\n keys = Object.keys(pair);\n result[index] = [keys[0], pair[keys[0]]];\n }\n return result;\n}\nvar pairs = new type(\"tag:yaml.org,2002:pairs\", {\n kind: \"sequence\",\n resolve: resolveYamlPairs,\n construct: constructYamlPairs\n});\nvar _hasOwnProperty$2 = Object.prototype.hasOwnProperty;\nfunction resolveYamlSet(data) {\n if (data === null)\n return true;\n var key, object = data;\n for (key in object) {\n if (_hasOwnProperty$2.call(object, key)) {\n if (object[key] !== null)\n return false;\n }\n }\n return true;\n}\nfunction constructYamlSet(data) {\n return data !== null ? data : {};\n}\nvar set = new type(\"tag:yaml.org,2002:set\", {\n kind: \"mapping\",\n resolve: resolveYamlSet,\n construct: constructYamlSet\n});\nvar _default = core.extend({\n implicit: [\n timestamp,\n merge\n ],\n explicit: [\n binary,\n omap,\n pairs,\n set\n ]\n});\nvar _hasOwnProperty$1 = Object.prototype.hasOwnProperty;\nvar CONTEXT_FLOW_IN = 1;\nvar CONTEXT_FLOW_OUT = 2;\nvar CONTEXT_BLOCK_IN = 3;\nvar CONTEXT_BLOCK_OUT = 4;\nvar CHOMPING_CLIP = 1;\nvar CHOMPING_STRIP = 2;\nvar CHOMPING_KEEP = 3;\nvar PATTERN_NON_PRINTABLE = /[\\x00-\\x08\\x0B\\x0C\\x0E-\\x1F\\x7F-\\x84\\x86-\\x9F\\uFFFE\\uFFFF]|[\\uD800-\\uDBFF](?![\\uDC00-\\uDFFF])|(?:[^\\uD800-\\uDBFF]|^)[\\uDC00-\\uDFFF]/;\nvar PATTERN_NON_ASCII_LINE_BREAKS = /[\\x85\\u2028\\u2029]/;\nvar PATTERN_FLOW_INDICATORS = /[,\\[\\]\\{\\}]/;\nvar PATTERN_TAG_HANDLE = /^(?:!|!!|![a-z\\-]+!)$/i;\nvar PATTERN_TAG_URI = /^(?:!|[^,\\[\\]\\{\\}])(?:%[0-9a-f]{2}|[0-9a-z\\-#;\\/\\?:@&=\\+\\$,_\\.!~\\*'\\(\\)\\[\\]])*$/i;\nfunction _class(obj) {\n return Object.prototype.toString.call(obj);\n}\nfunction is_EOL(c) {\n return c === 10 || c === 13;\n}\nfunction is_WHITE_SPACE(c) {\n return c === 9 || c === 32;\n}\nfunction is_WS_OR_EOL(c) {\n return c === 9 || c === 32 || c === 10 || c === 13;\n}\nfunction is_FLOW_INDICATOR(c) {\n return c === 44 || c === 91 || c === 93 || c === 123 || c === 125;\n}\nfunction fromHexCode(c) {\n var lc;\n if (48 <= c && c <= 57) {\n return c - 48;\n }\n lc = c | 32;\n if (97 <= lc && lc <= 102) {\n return lc - 97 + 10;\n }\n return -1;\n}\nfunction escapedHexLen(c) {\n if (c === 120) {\n return 2;\n }\n if (c === 117) {\n return 4;\n }\n if (c === 85) {\n return 8;\n }\n return 0;\n}\nfunction fromDecimalCode(c) {\n if (48 <= c && c <= 57) {\n return c - 48;\n }\n return -1;\n}\nfunction simpleEscapeSequence(c) {\n return c === 48 ? \"\\0\" : c === 97 ? \"\\x07\" : c === 98 ? \"\\b\" : c === 116 ? \"\t\" : c === 9 ? \"\t\" : c === 110 ? \"\\n\" : c === 118 ? \"\\v\" : c === 102 ? \"\\f\" : c === 114 ? \"\\r\" : c === 101 ? \"\\x1B\" : c === 32 ? \" \" : c === 34 ? '\"' : c === 47 ? \"/\" : c === 92 ? \"\\\\\" : c === 78 ? \"\u0085\" : c === 95 ? \"\u00A0\" : c === 76 ? \"\\u2028\" : c === 80 ? \"\\u2029\" : \"\";\n}\nfunction charFromCodepoint(c) {\n if (c <= 65535) {\n return String.fromCharCode(c);\n }\n return String.fromCharCode(\n (c - 65536 >> 10) + 55296,\n (c - 65536 & 1023) + 56320\n );\n}\nvar simpleEscapeCheck = new Array(256);\nvar simpleEscapeMap = new Array(256);\nfor (var i = 0; i < 256; i++) {\n simpleEscapeCheck[i] = simpleEscapeSequence(i) ? 1 : 0;\n simpleEscapeMap[i] = simpleEscapeSequence(i);\n}\nfunction State$1(input, options) {\n this.input = input;\n this.filename = options[\"filename\"] || null;\n this.schema = options[\"schema\"] || _default;\n this.onWarning = options[\"onWarning\"] || null;\n this.legacy = options[\"legacy\"] || false;\n this.json = options[\"json\"] || false;\n this.listener = options[\"listener\"] || null;\n this.implicitTypes = this.schema.compiledImplicit;\n this.typeMap = this.schema.compiledTypeMap;\n this.length = input.length;\n this.position = 0;\n this.line = 0;\n this.lineStart = 0;\n this.lineIndent = 0;\n this.firstTabInLine = -1;\n this.documents = [];\n}\nfunction generateError(state2, message) {\n var mark = {\n name: state2.filename,\n buffer: state2.input.slice(0, -1),\n // omit trailing \\0\n position: state2.position,\n line: state2.line,\n column: state2.position - state2.lineStart\n };\n mark.snippet = snippet(mark);\n return new exception(message, mark);\n}\nfunction throwError(state2, message) {\n throw generateError(state2, message);\n}\nfunction throwWarning(state2, message) {\n if (state2.onWarning) {\n state2.onWarning.call(null, generateError(state2, message));\n }\n}\nvar directiveHandlers = {\n YAML: function handleYamlDirective(state2, name, args) {\n var match, major, minor;\n if (state2.version !== null) {\n throwError(state2, \"duplication of %YAML directive\");\n }\n if (args.length !== 1) {\n throwError(state2, \"YAML directive accepts exactly one argument\");\n }\n match = /^([0-9]+)\\.([0-9]+)$/.exec(args[0]);\n if (match === null) {\n throwError(state2, \"ill-formed argument of the YAML directive\");\n }\n major = parseInt(match[1], 10);\n minor = parseInt(match[2], 10);\n if (major !== 1) {\n throwError(state2, \"unacceptable YAML version of the document\");\n }\n state2.version = args[0];\n state2.checkLineBreaks = minor < 2;\n if (minor !== 1 && minor !== 2) {\n throwWarning(state2, \"unsupported YAML version of the document\");\n }\n },\n TAG: function handleTagDirective(state2, name, args) {\n var handle, prefix;\n if (args.length !== 2) {\n throwError(state2, \"TAG directive accepts exactly two arguments\");\n }\n handle = args[0];\n prefix = args[1];\n if (!PATTERN_TAG_HANDLE.test(handle)) {\n throwError(state2, \"ill-formed tag handle (first argument) of the TAG directive\");\n }\n if (_hasOwnProperty$1.call(state2.tagMap, handle)) {\n throwError(state2, 'there is a previously declared suffix for \"' + handle + '\" tag handle');\n }\n if (!PATTERN_TAG_URI.test(prefix)) {\n throwError(state2, \"ill-formed tag prefix (second argument) of the TAG directive\");\n }\n try {\n prefix = decodeURIComponent(prefix);\n } catch (err) {\n throwError(state2, \"tag prefix is malformed: \" + prefix);\n }\n state2.tagMap[handle] = prefix;\n }\n};\nfunction captureSegment(state2, start, end, checkJson) {\n var _position, _length, _character, _result;\n if (start < end) {\n _result = state2.input.slice(start, end);\n if (checkJson) {\n for (_position = 0, _length = _result.length; _position < _length; _position += 1) {\n _character = _result.charCodeAt(_position);\n if (!(_character === 9 || 32 <= _character && _character <= 1114111)) {\n throwError(state2, \"expected valid JSON character\");\n }\n }\n } else if (PATTERN_NON_PRINTABLE.test(_result)) {\n throwError(state2, \"the stream contains non-printable characters\");\n }\n state2.result += _result;\n }\n}\nfunction mergeMappings(state2, destination, source, overridableKeys) {\n var sourceKeys, key, index, quantity;\n if (!common.isObject(source)) {\n throwError(state2, \"cannot merge mappings; the provided source object is unacceptable\");\n }\n sourceKeys = Object.keys(source);\n for (index = 0, quantity = sourceKeys.length; index < quantity; index += 1) {\n key = sourceKeys[index];\n if (!_hasOwnProperty$1.call(destination, key)) {\n destination[key] = source[key];\n overridableKeys[key] = true;\n }\n }\n}\nfunction storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, valueNode, startLine, startLineStart, startPos) {\n var index, quantity;\n if (Array.isArray(keyNode)) {\n keyNode = Array.prototype.slice.call(keyNode);\n for (index = 0, quantity = keyNode.length; index < quantity; index += 1) {\n if (Array.isArray(keyNode[index])) {\n throwError(state2, \"nested arrays are not supported inside keys\");\n }\n if (typeof keyNode === \"object\" && _class(keyNode[index]) === \"[object Object]\") {\n keyNode[index] = \"[object Object]\";\n }\n }\n }\n if (typeof keyNode === \"object\" && _class(keyNode) === \"[object Object]\") {\n keyNode = \"[object Object]\";\n }\n keyNode = String(keyNode);\n if (_result === null) {\n _result = {};\n }\n if (keyTag === \"tag:yaml.org,2002:merge\") {\n if (Array.isArray(valueNode)) {\n for (index = 0, quantity = valueNode.length; index < quantity; index += 1) {\n mergeMappings(state2, _result, valueNode[index], overridableKeys);\n }\n } else {\n mergeMappings(state2, _result, valueNode, overridableKeys);\n }\n } else {\n if (!state2.json && !_hasOwnProperty$1.call(overridableKeys, keyNode) && _hasOwnProperty$1.call(_result, keyNode)) {\n state2.line = startLine || state2.line;\n state2.lineStart = startLineStart || state2.lineStart;\n state2.position = startPos || state2.position;\n throwError(state2, \"duplicated mapping key\");\n }\n if (keyNode === \"__proto__\") {\n Object.defineProperty(_result, keyNode, {\n configurable: true,\n enumerable: true,\n writable: true,\n value: valueNode\n });\n } else {\n _result[keyNode] = valueNode;\n }\n delete overridableKeys[keyNode];\n }\n return _result;\n}\nfunction readLineBreak(state2) {\n var ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 10) {\n state2.position++;\n } else if (ch === 13) {\n state2.position++;\n if (state2.input.charCodeAt(state2.position) === 10) {\n state2.position++;\n }\n } else {\n throwError(state2, \"a line break is expected\");\n }\n state2.line += 1;\n state2.lineStart = state2.position;\n state2.firstTabInLine = -1;\n}\nfunction skipSeparationSpace(state2, allowComments, checkIndent) {\n var lineBreaks = 0, ch = state2.input.charCodeAt(state2.position);\n while (ch !== 0) {\n while (is_WHITE_SPACE(ch)) {\n if (ch === 9 && state2.firstTabInLine === -1) {\n state2.firstTabInLine = state2.position;\n }\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (allowComments && ch === 35) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (ch !== 10 && ch !== 13 && ch !== 0);\n }\n if (is_EOL(ch)) {\n readLineBreak(state2);\n ch = state2.input.charCodeAt(state2.position);\n lineBreaks++;\n state2.lineIndent = 0;\n while (ch === 32) {\n state2.lineIndent++;\n ch = state2.input.charCodeAt(++state2.position);\n }\n } else {\n break;\n }\n }\n if (checkIndent !== -1 && lineBreaks !== 0 && state2.lineIndent < checkIndent) {\n throwWarning(state2, \"deficient indentation\");\n }\n return lineBreaks;\n}\nfunction testDocumentSeparator(state2) {\n var _position = state2.position, ch;\n ch = state2.input.charCodeAt(_position);\n if ((ch === 45 || ch === 46) && ch === state2.input.charCodeAt(_position + 1) && ch === state2.input.charCodeAt(_position + 2)) {\n _position += 3;\n ch = state2.input.charCodeAt(_position);\n if (ch === 0 || is_WS_OR_EOL(ch)) {\n return true;\n }\n }\n return false;\n}\nfunction writeFoldedLines(state2, count) {\n if (count === 1) {\n state2.result += \" \";\n } else if (count > 1) {\n state2.result += common.repeat(\"\\n\", count - 1);\n }\n}\nfunction readPlainScalar(state2, nodeIndent, withinFlowCollection) {\n var preceding, following, captureStart, captureEnd, hasPendingContent, _line, _lineStart, _lineIndent, _kind = state2.kind, _result = state2.result, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (is_WS_OR_EOL(ch) || is_FLOW_INDICATOR(ch) || ch === 35 || ch === 38 || ch === 42 || ch === 33 || ch === 124 || ch === 62 || ch === 39 || ch === 34 || ch === 37 || ch === 64 || ch === 96) {\n return false;\n }\n if (ch === 63 || ch === 45) {\n following = state2.input.charCodeAt(state2.position + 1);\n if (is_WS_OR_EOL(following) || withinFlowCollection && is_FLOW_INDICATOR(following)) {\n return false;\n }\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n captureStart = captureEnd = state2.position;\n hasPendingContent = false;\n while (ch !== 0) {\n if (ch === 58) {\n following = state2.input.charCodeAt(state2.position + 1);\n if (is_WS_OR_EOL(following) || withinFlowCollection && is_FLOW_INDICATOR(following)) {\n break;\n }\n } else if (ch === 35) {\n preceding = state2.input.charCodeAt(state2.position - 1);\n if (is_WS_OR_EOL(preceding)) {\n break;\n }\n } else if (state2.position === state2.lineStart && testDocumentSeparator(state2) || withinFlowCollection && is_FLOW_INDICATOR(ch)) {\n break;\n } else if (is_EOL(ch)) {\n _line = state2.line;\n _lineStart = state2.lineStart;\n _lineIndent = state2.lineIndent;\n skipSeparationSpace(state2, false, -1);\n if (state2.lineIndent >= nodeIndent) {\n hasPendingContent = true;\n ch = state2.input.charCodeAt(state2.position);\n continue;\n } else {\n state2.position = captureEnd;\n state2.line = _line;\n state2.lineStart = _lineStart;\n state2.lineIndent = _lineIndent;\n break;\n }\n }\n if (hasPendingContent) {\n captureSegment(state2, captureStart, captureEnd, false);\n writeFoldedLines(state2, state2.line - _line);\n captureStart = captureEnd = state2.position;\n hasPendingContent = false;\n }\n if (!is_WHITE_SPACE(ch)) {\n captureEnd = state2.position + 1;\n }\n ch = state2.input.charCodeAt(++state2.position);\n }\n captureSegment(state2, captureStart, captureEnd, false);\n if (state2.result) {\n return true;\n }\n state2.kind = _kind;\n state2.result = _result;\n return false;\n}\nfunction readSingleQuotedScalar(state2, nodeIndent) {\n var ch, captureStart, captureEnd;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 39) {\n return false;\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n state2.position++;\n captureStart = captureEnd = state2.position;\n while ((ch = state2.input.charCodeAt(state2.position)) !== 0) {\n if (ch === 39) {\n captureSegment(state2, captureStart, state2.position, true);\n ch = state2.input.charCodeAt(++state2.position);\n if (ch === 39) {\n captureStart = state2.position;\n state2.position++;\n captureEnd = state2.position;\n } else {\n return true;\n }\n } else if (is_EOL(ch)) {\n captureSegment(state2, captureStart, captureEnd, true);\n writeFoldedLines(state2, skipSeparationSpace(state2, false, nodeIndent));\n captureStart = captureEnd = state2.position;\n } else if (state2.position === state2.lineStart && testDocumentSeparator(state2)) {\n throwError(state2, \"unexpected end of the document within a single quoted scalar\");\n } else {\n state2.position++;\n captureEnd = state2.position;\n }\n }\n throwError(state2, \"unexpected end of the stream within a single quoted scalar\");\n}\nfunction readDoubleQuotedScalar(state2, nodeIndent) {\n var captureStart, captureEnd, hexLength, hexResult, tmp, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 34) {\n return false;\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n state2.position++;\n captureStart = captureEnd = state2.position;\n while ((ch = state2.input.charCodeAt(state2.position)) !== 0) {\n if (ch === 34) {\n captureSegment(state2, captureStart, state2.position, true);\n state2.position++;\n return true;\n } else if (ch === 92) {\n captureSegment(state2, captureStart, state2.position, true);\n ch = state2.input.charCodeAt(++state2.position);\n if (is_EOL(ch)) {\n skipSeparationSpace(state2, false, nodeIndent);\n } else if (ch < 256 && simpleEscapeCheck[ch]) {\n state2.result += simpleEscapeMap[ch];\n state2.position++;\n } else if ((tmp = escapedHexLen(ch)) > 0) {\n hexLength = tmp;\n hexResult = 0;\n for (; hexLength > 0; hexLength--) {\n ch = state2.input.charCodeAt(++state2.position);\n if ((tmp = fromHexCode(ch)) >= 0) {\n hexResult = (hexResult << 4) + tmp;\n } else {\n throwError(state2, \"expected hexadecimal character\");\n }\n }\n state2.result += charFromCodepoint(hexResult);\n state2.position++;\n } else {\n throwError(state2, \"unknown escape sequence\");\n }\n captureStart = captureEnd = state2.position;\n } else if (is_EOL(ch)) {\n captureSegment(state2, captureStart, captureEnd, true);\n writeFoldedLines(state2, skipSeparationSpace(state2, false, nodeIndent));\n captureStart = captureEnd = state2.position;\n } else if (state2.position === state2.lineStart && testDocumentSeparator(state2)) {\n throwError(state2, \"unexpected end of the document within a double quoted scalar\");\n } else {\n state2.position++;\n captureEnd = state2.position;\n }\n }\n throwError(state2, \"unexpected end of the stream within a double quoted scalar\");\n}\nfunction readFlowCollection(state2, nodeIndent) {\n var readNext = true, _line, _lineStart, _pos, _tag = state2.tag, _result, _anchor = state2.anchor, following, terminator, isPair, isExplicitPair, isMapping, overridableKeys = /* @__PURE__ */ Object.create(null), keyNode, keyTag, valueNode, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 91) {\n terminator = 93;\n isMapping = false;\n _result = [];\n } else if (ch === 123) {\n terminator = 125;\n isMapping = true;\n _result = {};\n } else {\n return false;\n }\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = _result;\n }\n ch = state2.input.charCodeAt(++state2.position);\n while (ch !== 0) {\n skipSeparationSpace(state2, true, nodeIndent);\n ch = state2.input.charCodeAt(state2.position);\n if (ch === terminator) {\n state2.position++;\n state2.tag = _tag;\n state2.anchor = _anchor;\n state2.kind = isMapping ? \"mapping\" : \"sequence\";\n state2.result = _result;\n return true;\n } else if (!readNext) {\n throwError(state2, \"missed comma between flow collection entries\");\n } else if (ch === 44) {\n throwError(state2, \"expected the node content, but found ','\");\n }\n keyTag = keyNode = valueNode = null;\n isPair = isExplicitPair = false;\n if (ch === 63) {\n following = state2.input.charCodeAt(state2.position + 1);\n if (is_WS_OR_EOL(following)) {\n isPair = isExplicitPair = true;\n state2.position++;\n skipSeparationSpace(state2, true, nodeIndent);\n }\n }\n _line = state2.line;\n _lineStart = state2.lineStart;\n _pos = state2.position;\n composeNode(state2, nodeIndent, CONTEXT_FLOW_IN, false, true);\n keyTag = state2.tag;\n keyNode = state2.result;\n skipSeparationSpace(state2, true, nodeIndent);\n ch = state2.input.charCodeAt(state2.position);\n if ((isExplicitPair || state2.line === _line) && ch === 58) {\n isPair = true;\n ch = state2.input.charCodeAt(++state2.position);\n skipSeparationSpace(state2, true, nodeIndent);\n composeNode(state2, nodeIndent, CONTEXT_FLOW_IN, false, true);\n valueNode = state2.result;\n }\n if (isMapping) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, valueNode, _line, _lineStart, _pos);\n } else if (isPair) {\n _result.push(storeMappingPair(state2, null, overridableKeys, keyTag, keyNode, valueNode, _line, _lineStart, _pos));\n } else {\n _result.push(keyNode);\n }\n skipSeparationSpace(state2, true, nodeIndent);\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 44) {\n readNext = true;\n ch = state2.input.charCodeAt(++state2.position);\n } else {\n readNext = false;\n }\n }\n throwError(state2, \"unexpected end of the stream within a flow collection\");\n}\nfunction readBlockScalar(state2, nodeIndent) {\n var captureStart, folding, chomping = CHOMPING_CLIP, didReadContent = false, detectedIndent = false, textIndent = nodeIndent, emptyLines = 0, atMoreIndented = false, tmp, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 124) {\n folding = false;\n } else if (ch === 62) {\n folding = true;\n } else {\n return false;\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n while (ch !== 0) {\n ch = state2.input.charCodeAt(++state2.position);\n if (ch === 43 || ch === 45) {\n if (CHOMPING_CLIP === chomping) {\n chomping = ch === 43 ? CHOMPING_KEEP : CHOMPING_STRIP;\n } else {\n throwError(state2, \"repeat of a chomping mode identifier\");\n }\n } else if ((tmp = fromDecimalCode(ch)) >= 0) {\n if (tmp === 0) {\n throwError(state2, \"bad explicit indentation width of a block scalar; it cannot be less than one\");\n } else if (!detectedIndent) {\n textIndent = nodeIndent + tmp - 1;\n detectedIndent = true;\n } else {\n throwError(state2, \"repeat of an indentation width identifier\");\n }\n } else {\n break;\n }\n }\n if (is_WHITE_SPACE(ch)) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (is_WHITE_SPACE(ch));\n if (ch === 35) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (!is_EOL(ch) && ch !== 0);\n }\n }\n while (ch !== 0) {\n readLineBreak(state2);\n state2.lineIndent = 0;\n ch = state2.input.charCodeAt(state2.position);\n while ((!detectedIndent || state2.lineIndent < textIndent) && ch === 32) {\n state2.lineIndent++;\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (!detectedIndent && state2.lineIndent > textIndent) {\n textIndent = state2.lineIndent;\n }\n if (is_EOL(ch)) {\n emptyLines++;\n continue;\n }\n if (state2.lineIndent < textIndent) {\n if (chomping === CHOMPING_KEEP) {\n state2.result += common.repeat(\"\\n\", didReadContent ? 1 + emptyLines : emptyLines);\n } else if (chomping === CHOMPING_CLIP) {\n if (didReadContent) {\n state2.result += \"\\n\";\n }\n }\n break;\n }\n if (folding) {\n if (is_WHITE_SPACE(ch)) {\n atMoreIndented = true;\n state2.result += common.repeat(\"\\n\", didReadContent ? 1 + emptyLines : emptyLines);\n } else if (atMoreIndented) {\n atMoreIndented = false;\n state2.result += common.repeat(\"\\n\", emptyLines + 1);\n } else if (emptyLines === 0) {\n if (didReadContent) {\n state2.result += \" \";\n }\n } else {\n state2.result += common.repeat(\"\\n\", emptyLines);\n }\n } else {\n state2.result += common.repeat(\"\\n\", didReadContent ? 1 + emptyLines : emptyLines);\n }\n didReadContent = true;\n detectedIndent = true;\n emptyLines = 0;\n captureStart = state2.position;\n while (!is_EOL(ch) && ch !== 0) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n captureSegment(state2, captureStart, state2.position, false);\n }\n return true;\n}\nfunction readBlockSequence(state2, nodeIndent) {\n var _line, _tag = state2.tag, _anchor = state2.anchor, _result = [], following, detected = false, ch;\n if (state2.firstTabInLine !== -1)\n return false;\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = _result;\n }\n ch = state2.input.charCodeAt(state2.position);\n while (ch !== 0) {\n if (state2.firstTabInLine !== -1) {\n state2.position = state2.firstTabInLine;\n throwError(state2, \"tab characters must not be used in indentation\");\n }\n if (ch !== 45) {\n break;\n }\n following = state2.input.charCodeAt(state2.position + 1);\n if (!is_WS_OR_EOL(following)) {\n break;\n }\n detected = true;\n state2.position++;\n if (skipSeparationSpace(state2, true, -1)) {\n if (state2.lineIndent <= nodeIndent) {\n _result.push(null);\n ch = state2.input.charCodeAt(state2.position);\n continue;\n }\n }\n _line = state2.line;\n composeNode(state2, nodeIndent, CONTEXT_BLOCK_IN, false, true);\n _result.push(state2.result);\n skipSeparationSpace(state2, true, -1);\n ch = state2.input.charCodeAt(state2.position);\n if ((state2.line === _line || state2.lineIndent > nodeIndent) && ch !== 0) {\n throwError(state2, \"bad indentation of a sequence entry\");\n } else if (state2.lineIndent < nodeIndent) {\n break;\n }\n }\n if (detected) {\n state2.tag = _tag;\n state2.anchor = _anchor;\n state2.kind = \"sequence\";\n state2.result = _result;\n return true;\n }\n return false;\n}\nfunction readBlockMapping(state2, nodeIndent, flowIndent) {\n var following, allowCompact, _line, _keyLine, _keyLineStart, _keyPos, _tag = state2.tag, _anchor = state2.anchor, _result = {}, overridableKeys = /* @__PURE__ */ Object.create(null), keyTag = null, keyNode = null, valueNode = null, atExplicitKey = false, detected = false, ch;\n if (state2.firstTabInLine !== -1)\n return false;\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = _result;\n }\n ch = state2.input.charCodeAt(state2.position);\n while (ch !== 0) {\n if (!atExplicitKey && state2.firstTabInLine !== -1) {\n state2.position = state2.firstTabInLine;\n throwError(state2, \"tab characters must not be used in indentation\");\n }\n following = state2.input.charCodeAt(state2.position + 1);\n _line = state2.line;\n if ((ch === 63 || ch === 58) && is_WS_OR_EOL(following)) {\n if (ch === 63) {\n if (atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);\n keyTag = keyNode = valueNode = null;\n }\n detected = true;\n atExplicitKey = true;\n allowCompact = true;\n } else if (atExplicitKey) {\n atExplicitKey = false;\n allowCompact = true;\n } else {\n throwError(state2, \"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line\");\n }\n state2.position += 1;\n ch = following;\n } else {\n _keyLine = state2.line;\n _keyLineStart = state2.lineStart;\n _keyPos = state2.position;\n if (!composeNode(state2, flowIndent, CONTEXT_FLOW_OUT, false, true)) {\n break;\n }\n if (state2.line === _line) {\n ch = state2.input.charCodeAt(state2.position);\n while (is_WHITE_SPACE(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (ch === 58) {\n ch = state2.input.charCodeAt(++state2.position);\n if (!is_WS_OR_EOL(ch)) {\n throwError(state2, \"a whitespace character is expected after the key-value separator within a block mapping\");\n }\n if (atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);\n keyTag = keyNode = valueNode = null;\n }\n detected = true;\n atExplicitKey = false;\n allowCompact = false;\n keyTag = state2.tag;\n keyNode = state2.result;\n } else if (detected) {\n throwError(state2, \"can not read an implicit mapping pair; a colon is missed\");\n } else {\n state2.tag = _tag;\n state2.anchor = _anchor;\n return true;\n }\n } else if (detected) {\n throwError(state2, \"can not read a block mapping entry; a multiline key may not be an implicit key\");\n } else {\n state2.tag = _tag;\n state2.anchor = _anchor;\n return true;\n }\n }\n if (state2.line === _line || state2.lineIndent > nodeIndent) {\n if (atExplicitKey) {\n _keyLine = state2.line;\n _keyLineStart = state2.lineStart;\n _keyPos = state2.position;\n }\n if (composeNode(state2, nodeIndent, CONTEXT_BLOCK_OUT, true, allowCompact)) {\n if (atExplicitKey) {\n keyNode = state2.result;\n } else {\n valueNode = state2.result;\n }\n }\n if (!atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, valueNode, _keyLine, _keyLineStart, _keyPos);\n keyTag = keyNode = valueNode = null;\n }\n skipSeparationSpace(state2, true, -1);\n ch = state2.input.charCodeAt(state2.position);\n }\n if ((state2.line === _line || state2.lineIndent > nodeIndent) && ch !== 0) {\n throwError(state2, \"bad indentation of a mapping entry\");\n } else if (state2.lineIndent < nodeIndent) {\n break;\n }\n }\n if (atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);\n }\n if (detected) {\n state2.tag = _tag;\n state2.anchor = _anchor;\n state2.kind = \"mapping\";\n state2.result = _result;\n }\n return detected;\n}\nfunction readTagProperty(state2) {\n var _position, isVerbatim = false, isNamed = false, tagHandle, tagName, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 33)\n return false;\n if (state2.tag !== null) {\n throwError(state2, \"duplication of a tag property\");\n }\n ch = state2.input.charCodeAt(++state2.position);\n if (ch === 60) {\n isVerbatim = true;\n ch = state2.input.charCodeAt(++state2.position);\n } else if (ch === 33) {\n isNamed = true;\n tagHandle = \"!!\";\n ch = state2.input.charCodeAt(++state2.position);\n } else {\n tagHandle = \"!\";\n }\n _position = state2.position;\n if (isVerbatim) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (ch !== 0 && ch !== 62);\n if (state2.position < state2.length) {\n tagName = state2.input.slice(_position, state2.position);\n ch = state2.input.charCodeAt(++state2.position);\n } else {\n throwError(state2, \"unexpected end of the stream within a verbatim tag\");\n }\n } else {\n while (ch !== 0 && !is_WS_OR_EOL(ch)) {\n if (ch === 33) {\n if (!isNamed) {\n tagHandle = state2.input.slice(_position - 1, state2.position + 1);\n if (!PATTERN_TAG_HANDLE.test(tagHandle)) {\n throwError(state2, \"named tag handle cannot contain such characters\");\n }\n isNamed = true;\n _position = state2.position + 1;\n } else {\n throwError(state2, \"tag suffix cannot contain exclamation marks\");\n }\n }\n ch = state2.input.charCodeAt(++state2.position);\n }\n tagName = state2.input.slice(_position, state2.position);\n if (PATTERN_FLOW_INDICATORS.test(tagName)) {\n throwError(state2, \"tag suffix cannot contain flow indicator characters\");\n }\n }\n if (tagName && !PATTERN_TAG_URI.test(tagName)) {\n throwError(state2, \"tag name cannot contain such characters: \" + tagName);\n }\n try {\n tagName = decodeURIComponent(tagName);\n } catch (err) {\n throwError(state2, \"tag name is malformed: \" + tagName);\n }\n if (isVerbatim) {\n state2.tag = tagName;\n } else if (_hasOwnProperty$1.call(state2.tagMap, tagHandle)) {\n state2.tag = state2.tagMap[tagHandle] + tagName;\n } else if (tagHandle === \"!\") {\n state2.tag = \"!\" + tagName;\n } else if (tagHandle === \"!!\") {\n state2.tag = \"tag:yaml.org,2002:\" + tagName;\n } else {\n throwError(state2, 'undeclared tag handle \"' + tagHandle + '\"');\n }\n return true;\n}\nfunction readAnchorProperty(state2) {\n var _position, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 38)\n return false;\n if (state2.anchor !== null) {\n throwError(state2, \"duplication of an anchor property\");\n }\n ch = state2.input.charCodeAt(++state2.position);\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch) && !is_FLOW_INDICATOR(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (state2.position === _position) {\n throwError(state2, \"name of an anchor node must contain at least one character\");\n }\n state2.anchor = state2.input.slice(_position, state2.position);\n return true;\n}\nfunction readAlias(state2) {\n var _position, alias, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 42)\n return false;\n ch = state2.input.charCodeAt(++state2.position);\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch) && !is_FLOW_INDICATOR(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (state2.position === _position) {\n throwError(state2, \"name of an alias node must contain at least one character\");\n }\n alias = state2.input.slice(_position, state2.position);\n if (!_hasOwnProperty$1.call(state2.anchorMap, alias)) {\n throwError(state2, 'unidentified alias \"' + alias + '\"');\n }\n state2.result = state2.anchorMap[alias];\n skipSeparationSpace(state2, true, -1);\n return true;\n}\nfunction composeNode(state2, parentIndent, nodeContext, allowToSeek, allowCompact) {\n var allowBlockStyles, allowBlockScalars, allowBlockCollections, indentStatus = 1, atNewLine = false, hasContent = false, typeIndex, typeQuantity, typeList, type2, flowIndent, blockIndent;\n if (state2.listener !== null) {\n state2.listener(\"open\", state2);\n }\n state2.tag = null;\n state2.anchor = null;\n state2.kind = null;\n state2.result = null;\n allowBlockStyles = allowBlockScalars = allowBlockCollections = CONTEXT_BLOCK_OUT === nodeContext || CONTEXT_BLOCK_IN === nodeContext;\n if (allowToSeek) {\n if (skipSeparationSpace(state2, true, -1)) {\n atNewLine = true;\n if (state2.lineIndent > parentIndent) {\n indentStatus = 1;\n } else if (state2.lineIndent === parentIndent) {\n indentStatus = 0;\n } else if (state2.lineIndent < parentIndent) {\n indentStatus = -1;\n }\n }\n }\n if (indentStatus === 1) {\n while (readTagProperty(state2) || readAnchorProperty(state2)) {\n if (skipSeparationSpace(state2, true, -1)) {\n atNewLine = true;\n allowBlockCollections = allowBlockStyles;\n if (state2.lineIndent > parentIndent) {\n indentStatus = 1;\n } else if (state2.lineIndent === parentIndent) {\n indentStatus = 0;\n } else if (state2.lineIndent < parentIndent) {\n indentStatus = -1;\n }\n } else {\n allowBlockCollections = false;\n }\n }\n }\n if (allowBlockCollections) {\n allowBlockCollections = atNewLine || allowCompact;\n }\n if (indentStatus === 1 || CONTEXT_BLOCK_OUT === nodeContext) {\n if (CONTEXT_FLOW_IN === nodeContext || CONTEXT_FLOW_OUT === nodeContext) {\n flowIndent = parentIndent;\n } else {\n flowIndent = parentIndent + 1;\n }\n blockIndent = state2.position - state2.lineStart;\n if (indentStatus === 1) {\n if (allowBlockCollections && (readBlockSequence(state2, blockIndent) || readBlockMapping(state2, blockIndent, flowIndent)) || readFlowCollection(state2, flowIndent)) {\n hasContent = true;\n } else {\n if (allowBlockScalars && readBlockScalar(state2, flowIndent) || readSingleQuotedScalar(state2, flowIndent) || readDoubleQuotedScalar(state2, flowIndent)) {\n hasContent = true;\n } else if (readAlias(state2)) {\n hasContent = true;\n if (state2.tag !== null || state2.anchor !== null) {\n throwError(state2, \"alias node should not have any properties\");\n }\n } else if (readPlainScalar(state2, flowIndent, CONTEXT_FLOW_IN === nodeContext)) {\n hasContent = true;\n if (state2.tag === null) {\n state2.tag = \"?\";\n }\n }\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n }\n } else if (indentStatus === 0) {\n hasContent = allowBlockCollections && readBlockSequence(state2, blockIndent);\n }\n }\n if (state2.tag === null) {\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n } else if (state2.tag === \"?\") {\n if (state2.result !== null && state2.kind !== \"scalar\") {\n throwError(state2, 'unacceptable node kind for ! tag; it should be \"scalar\", not \"' + state2.kind + '\"');\n }\n for (typeIndex = 0, typeQuantity = state2.implicitTypes.length; typeIndex < typeQuantity; typeIndex += 1) {\n type2 = state2.implicitTypes[typeIndex];\n if (type2.resolve(state2.result)) {\n state2.result = type2.construct(state2.result);\n state2.tag = type2.tag;\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n break;\n }\n }\n } else if (state2.tag !== \"!\") {\n if (_hasOwnProperty$1.call(state2.typeMap[state2.kind || \"fallback\"], state2.tag)) {\n type2 = state2.typeMap[state2.kind || \"fallback\"][state2.tag];\n } else {\n type2 = null;\n typeList = state2.typeMap.multi[state2.kind || \"fallback\"];\n for (typeIndex = 0, typeQuantity = typeList.length; typeIndex < typeQuantity; typeIndex += 1) {\n if (state2.tag.slice(0, typeList[typeIndex].tag.length) === typeList[typeIndex].tag) {\n type2 = typeList[typeIndex];\n break;\n }\n }\n }\n if (!type2) {\n throwError(state2, \"unknown tag !<\" + state2.tag + \">\");\n }\n if (state2.result !== null && type2.kind !== state2.kind) {\n throwError(state2, \"unacceptable node kind for !<\" + state2.tag + '> tag; it should be \"' + type2.kind + '\", not \"' + state2.kind + '\"');\n }\n if (!type2.resolve(state2.result, state2.tag)) {\n throwError(state2, \"cannot resolve a node with !<\" + state2.tag + \"> explicit tag\");\n } else {\n state2.result = type2.construct(state2.result, state2.tag);\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n }\n }\n if (state2.listener !== null) {\n state2.listener(\"close\", state2);\n }\n return state2.tag !== null || state2.anchor !== null || hasContent;\n}\nfunction readDocument(state2) {\n var documentStart = state2.position, _position, directiveName, directiveArgs, hasDirectives = false, ch;\n state2.version = null;\n state2.checkLineBreaks = state2.legacy;\n state2.tagMap = /* @__PURE__ */ Object.create(null);\n state2.anchorMap = /* @__PURE__ */ Object.create(null);\n while ((ch = state2.input.charCodeAt(state2.position)) !== 0) {\n skipSeparationSpace(state2, true, -1);\n ch = state2.input.charCodeAt(state2.position);\n if (state2.lineIndent > 0 || ch !== 37) {\n break;\n }\n hasDirectives = true;\n ch = state2.input.charCodeAt(++state2.position);\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n directiveName = state2.input.slice(_position, state2.position);\n directiveArgs = [];\n if (directiveName.length < 1) {\n throwError(state2, \"directive name must not be less than one character in length\");\n }\n while (ch !== 0) {\n while (is_WHITE_SPACE(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (ch === 35) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (ch !== 0 && !is_EOL(ch));\n break;\n }\n if (is_EOL(ch))\n break;\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n directiveArgs.push(state2.input.slice(_position, state2.position));\n }\n if (ch !== 0)\n readLineBreak(state2);\n if (_hasOwnProperty$1.call(directiveHandlers, directiveName)) {\n directiveHandlers[directiveName](state2, directiveName, directiveArgs);\n } else {\n throwWarning(state2, 'unknown document directive \"' + directiveName + '\"');\n }\n }\n skipSeparationSpace(state2, true, -1);\n if (state2.lineIndent === 0 && state2.input.charCodeAt(state2.position) === 45 && state2.input.charCodeAt(state2.position + 1) === 45 && state2.input.charCodeAt(state2.position + 2) === 45) {\n state2.position += 3;\n skipSeparationSpace(state2, true, -1);\n } else if (hasDirectives) {\n throwError(state2, \"directives end mark is expected\");\n }\n composeNode(state2, state2.lineIndent - 1, CONTEXT_BLOCK_OUT, false, true);\n skipSeparationSpace(state2, true, -1);\n if (state2.checkLineBreaks && PATTERN_NON_ASCII_LINE_BREAKS.test(state2.input.slice(documentStart, state2.position))) {\n throwWarning(state2, \"non-ASCII line breaks are interpreted as content\");\n }\n state2.documents.push(state2.result);\n if (state2.position === state2.lineStart && testDocumentSeparator(state2)) {\n if (state2.input.charCodeAt(state2.position) === 46) {\n state2.position += 3;\n skipSeparationSpace(state2, true, -1);\n }\n return;\n }\n if (state2.position < state2.length - 1) {\n throwError(state2, \"end of the stream or a document separator is expected\");\n } else {\n return;\n }\n}\nfunction loadDocuments(input, options) {\n input = String(input);\n options = options || {};\n if (input.length !== 0) {\n if (input.charCodeAt(input.length - 1) !== 10 && input.charCodeAt(input.length - 1) !== 13) {\n input += \"\\n\";\n }\n if (input.charCodeAt(0) === 65279) {\n input = input.slice(1);\n }\n }\n var state2 = new State$1(input, options);\n var nullpos = input.indexOf(\"\\0\");\n if (nullpos !== -1) {\n state2.position = nullpos;\n throwError(state2, \"null byte is not allowed in input\");\n }\n state2.input += \"\\0\";\n while (state2.input.charCodeAt(state2.position) === 32) {\n state2.lineIndent += 1;\n state2.position += 1;\n }\n while (state2.position < state2.length - 1) {\n readDocument(state2);\n }\n return state2.documents;\n}\nfunction loadAll$1(input, iterator, options) {\n if (iterator !== null && typeof iterator === \"object\" && typeof options === \"undefined\") {\n options = iterator;\n iterator = null;\n }\n var documents = loadDocuments(input, options);\n if (typeof iterator !== \"function\") {\n return documents;\n }\n for (var index = 0, length = documents.length; index < length; index += 1) {\n iterator(documents[index]);\n }\n}\nfunction load$1(input, options) {\n var documents = loadDocuments(input, options);\n if (documents.length === 0) {\n return void 0;\n } else if (documents.length === 1) {\n return documents[0];\n }\n throw new exception(\"expected a single document in the stream, but found more\");\n}\nvar loadAll_1 = loadAll$1;\nvar load_1 = load$1;\nvar loader = {\n loadAll: loadAll_1,\n load: load_1\n};\nvar JSON_SCHEMA = json;\nvar load = loader.load;\nfunction extractFrontMatter(text) {\n const matches = text.match(frontMatterRegex);\n if (!matches) {\n return {\n text,\n metadata: {}\n };\n }\n let parsed = load(matches[1], {\n // To support config, we need JSON schema.\n // https://www.yaml.org/spec/1.2/spec.html#id2803231\n schema: JSON_SCHEMA\n }) ?? {};\n parsed = typeof parsed === \"object\" && !Array.isArray(parsed) ? parsed : {};\n const metadata = {};\n if (parsed.displayMode) {\n metadata.displayMode = parsed.displayMode.toString();\n }\n if (parsed.title) {\n metadata.title = parsed.title.toString();\n }\n if (parsed.config) {\n metadata.config = parsed.config;\n }\n return {\n text: text.slice(matches[0].length),\n metadata\n };\n}\nconst cleanupText = (code) => {\n return code.replace(/\\r\\n?/g, \"\\n\").replace(\n /<(\\w+)([^>]*)>/g,\n (match, tag, attributes) => \"<\" + tag + attributes.replace(/=\"([^\"]*)\"/g, \"='$1'\") + \">\"\n );\n};\nconst processFrontmatter = (code) => {\n const { text, metadata } = extractFrontMatter(code);\n const { displayMode, title, config: config2 = {} } = metadata;\n if (displayMode) {\n if (!config2.gantt) {\n config2.gantt = {};\n }\n config2.gantt.displayMode = displayMode;\n }\n return { title, config: config2, text };\n};\nconst processDirectives = (code) => {\n const initDirective = utils.detectInit(code) ?? {};\n const wrapDirectives = utils.detectDirective(code, \"wrap\");\n if (Array.isArray(wrapDirectives)) {\n initDirective.wrap = wrapDirectives.some(({ type: type2 }) => {\n });\n } else if ((wrapDirectives == null ? void 0 : wrapDirectives.type) === \"wrap\") {\n initDirective.wrap = true;\n }\n return {\n text: removeDirectives(code),\n directive: initDirective\n };\n};\nfunction preprocessDiagram(code) {\n const cleanedCode = cleanupText(code);\n const frontMatterResult = processFrontmatter(cleanedCode);\n const directiveResult = processDirectives(frontMatterResult.text);\n const config2 = cleanAndMerge(frontMatterResult.config, directiveResult.directive);\n code = cleanupComments(directiveResult.text);\n return {\n code,\n title: frontMatterResult.title,\n config: config2\n };\n}\nconst MAX_TEXTLENGTH = 5e4;\nconst MAX_TEXTLENGTH_EXCEEDED_MSG = \"graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa\";\nconst SECURITY_LVL_SANDBOX = \"sandbox\";\nconst SECURITY_LVL_LOOSE = \"loose\";\nconst XMLNS_SVG_STD = \"http://www.w3.org/2000/svg\";\nconst XMLNS_XLINK_STD = \"http://www.w3.org/1999/xlink\";\nconst XMLNS_XHTML_STD = \"http://www.w3.org/1999/xhtml\";\nconst IFRAME_WIDTH = \"100%\";\nconst IFRAME_HEIGHT = \"100%\";\nconst IFRAME_STYLES = \"border:0;margin:0;\";\nconst IFRAME_BODY_STYLE = \"margin:0\";\nconst IFRAME_SANDBOX_OPTS = \"allow-top-navigation-by-user-activation allow-popups\";\nconst IFRAME_NOT_SUPPORTED_MSG = 'The \"iframe\" tag is not supported by your browser.';\nconst DOMPURIFY_TAGS = [\"foreignobject\"];\nconst DOMPURIFY_ATTR = [\"dominant-baseline\"];\nfunction processAndSetConfigs(text) {\n const processed = preprocessDiagram(text);\n reset();\n addDirective(processed.config ?? {});\n return processed;\n}\nasync function parse$1(text, parseOptions) {\n addDiagrams();\n text = processAndSetConfigs(text).code;\n try {\n await getDiagramFromText(text);\n } catch (error) {\n if (parseOptions == null ? void 0 : parseOptions.suppressErrors) {\n return false;\n }\n throw error;\n }\n return true;\n}\nconst encodeEntities = function(text) {\n let txt = text;\n txt = txt.replace(/style.*:\\S*#.*;/g, function(s) {\n return s.substring(0, s.length - 1);\n });\n txt = txt.replace(/classDef.*:\\S*#.*;/g, function(s) {\n return s.substring(0, s.length - 1);\n });\n txt = txt.replace(/#\\w+;/g, function(s) {\n const innerTxt = s.substring(1, s.length - 1);\n const isInt = /^\\+?\\d+$/.test(innerTxt);\n if (isInt) {\n return \"\uFB02\u00B0\u00B0\" + innerTxt + \"\u00B6\u00DF\";\n } else {\n return \"\uFB02\u00B0\" + innerTxt + \"\u00B6\u00DF\";\n }\n });\n return txt;\n};\nconst decodeEntities = function(text) {\n return text.replace(/\uFB02\u00B0\u00B0/g, \"&#\").replace(/\uFB02\u00B0/g, \"&\").replace(/\u00B6\u00DF/g, \";\");\n};\nconst cssImportantStyles = (cssClass, element, cssClasses = []) => {\n return `\n.${cssClass} ${element} { ${cssClasses.join(\" !important; \")} !important; }`;\n};\nconst createCssStyles = (config2, classDefs = {}) => {\n var _a;\n let cssStyles = \"\";\n if (config2.themeCSS !== void 0) {\n cssStyles += `\n${config2.themeCSS}`;\n }\n if (config2.fontFamily !== void 0) {\n cssStyles += `\n:root { --mermaid-font-family: ${config2.fontFamily}}`;\n }\n if (config2.altFontFamily !== void 0) {\n cssStyles += `\n:root { --mermaid-alt-font-family: ${config2.altFontFamily}}`;\n }\n if (!isEmpty(classDefs)) {\n const htmlLabels = config2.htmlLabels || ((_a = config2.flowchart) == null ? void 0 : _a.htmlLabels);\n const cssHtmlElements = [\"> *\", \"span\"];\n const cssShapeElements = [\"rect\", \"polygon\", \"ellipse\", \"circle\", \"path\"];\n const cssElements = htmlLabels ? cssHtmlElements : cssShapeElements;\n for (const classId in classDefs) {\n const styleClassDef = classDefs[classId];\n if (!isEmpty(styleClassDef.styles)) {\n cssElements.forEach((cssElement) => {\n cssStyles += cssImportantStyles(styleClassDef.id, cssElement, styleClassDef.styles);\n });\n }\n if (!isEmpty(styleClassDef.textStyles)) {\n cssStyles += cssImportantStyles(styleClassDef.id, \"tspan\", styleClassDef.textStyles);\n }\n }\n }\n return cssStyles;\n};\nconst createUserStyles = (config2, graphType, classDefs, svgId) => {\n const userCSSstyles = createCssStyles(config2, classDefs);\n const allStyles = getStyles$1(graphType, userCSSstyles, config2.themeVariables);\n return serialize(compile(`${svgId}{${allStyles}}`), stringify);\n};\nconst cleanUpSvgCode = (svgCode = \"\", inSandboxMode, useArrowMarkerUrls) => {\n let cleanedUpSvg = svgCode;\n if (!useArrowMarkerUrls && !inSandboxMode) {\n cleanedUpSvg = cleanedUpSvg.replace(\n /marker-end=\"url\\([\\d+./:=?A-Za-z-]*?#/g,\n 'marker-end=\"url(#'\n );\n }\n cleanedUpSvg = decodeEntities(cleanedUpSvg);\n cleanedUpSvg = cleanedUpSvg.replace(/
      /g, \"
      \");\n return cleanedUpSvg;\n};\nconst putIntoIFrame = (svgCode = \"\", svgElement) => {\n var _a, _b;\n const height = ((_b = (_a = svgElement == null ? void 0 : svgElement.viewBox) == null ? void 0 : _a.baseVal) == null ? void 0 : _b.height) ? svgElement.viewBox.baseVal.height + \"px\" : IFRAME_HEIGHT;\n const base64encodedSrc = btoa('' + svgCode + \"\");\n return ``;\n};\nconst appendDivSvgG = (parentRoot, id2, enclosingDivId, divStyle, svgXlink) => {\n const enclosingDiv = parentRoot.append(\"div\");\n enclosingDiv.attr(\"id\", enclosingDivId);\n if (divStyle) {\n enclosingDiv.attr(\"style\", divStyle);\n }\n const svgNode = enclosingDiv.append(\"svg\").attr(\"id\", id2).attr(\"width\", \"100%\").attr(\"xmlns\", XMLNS_SVG_STD);\n if (svgXlink) {\n svgNode.attr(\"xmlns:xlink\", svgXlink);\n }\n svgNode.append(\"g\");\n return parentRoot;\n};\nfunction sandboxedIframe(parentNode, iFrameId) {\n return parentNode.append(\"iframe\").attr(\"id\", iFrameId).attr(\"style\", \"width: 100%; height: 100%;\").attr(\"sandbox\", \"\");\n}\nconst removeExistingElements = (doc, id2, divId, iFrameId) => {\n var _a, _b, _c;\n (_a = doc.getElementById(id2)) == null ? void 0 : _a.remove();\n (_b = doc.getElementById(divId)) == null ? void 0 : _b.remove();\n (_c = doc.getElementById(iFrameId)) == null ? void 0 : _c.remove();\n};\nconst render$1 = async function(id2, text, svgContainingElement) {\n var _a, _b, _c, _d, _e, _f;\n addDiagrams();\n const processed = processAndSetConfigs(text);\n text = processed.code;\n const config2 = getConfig$1();\n log$1.debug(config2);\n if (text.length > ((config2 == null ? void 0 : config2.maxTextSize) ?? MAX_TEXTLENGTH)) {\n text = MAX_TEXTLENGTH_EXCEEDED_MSG;\n }\n const idSelector = \"#\" + id2;\n const iFrameID = \"i\" + id2;\n const iFrameID_selector = \"#\" + iFrameID;\n const enclosingDivID = \"d\" + id2;\n const enclosingDivID_selector = \"#\" + enclosingDivID;\n let root = select(\"body\");\n const isSandboxed = config2.securityLevel === SECURITY_LVL_SANDBOX;\n const isLooseSecurityLevel = config2.securityLevel === SECURITY_LVL_LOOSE;\n const fontFamily = config2.fontFamily;\n if (svgContainingElement !== void 0) {\n if (svgContainingElement) {\n svgContainingElement.innerHTML = \"\";\n }\n if (isSandboxed) {\n const iframe = sandboxedIframe(select(svgContainingElement), iFrameID);\n root = select(iframe.nodes()[0].contentDocument.body);\n root.node().style.margin = 0;\n } else {\n root = select(svgContainingElement);\n }\n appendDivSvgG(root, id2, enclosingDivID, `font-family: ${fontFamily}`, XMLNS_XLINK_STD);\n } else {\n removeExistingElements(document, id2, enclosingDivID, iFrameID);\n if (isSandboxed) {\n const iframe = sandboxedIframe(select(\"body\"), iFrameID);\n root = select(iframe.nodes()[0].contentDocument.body);\n root.node().style.margin = 0;\n } else {\n root = select(\"body\");\n }\n appendDivSvgG(root, id2, enclosingDivID);\n }\n text = encodeEntities(text);\n let diag;\n let parseEncounteredException;\n try {\n diag = await getDiagramFromText(text, { title: processed.title });\n } catch (error) {\n diag = new Diagram(\"error\");\n parseEncounteredException = error;\n }\n const element = root.select(enclosingDivID_selector).node();\n const diagramType = diag.type;\n const svg = element.firstChild;\n const firstChild = svg.firstChild;\n const diagramClassDefs = (_b = (_a = diag.renderer).getClasses) == null ? void 0 : _b.call(_a, text, diag);\n const rules = createUserStyles(config2, diagramType, diagramClassDefs, idSelector);\n const style1 = document.createElement(\"style\");\n style1.innerHTML = rules;\n svg.insertBefore(style1, firstChild);\n try {\n await diag.renderer.draw(text, id2, version, diag);\n } catch (e) {\n errorRenderer.draw(text, id2, version);\n throw e;\n }\n const svgNode = root.select(`${enclosingDivID_selector} svg`);\n const a11yTitle = (_d = (_c = diag.db).getAccTitle) == null ? void 0 : _d.call(_c);\n const a11yDescr = (_f = (_e = diag.db).getAccDescription) == null ? void 0 : _f.call(_e);\n addA11yInfo(diagramType, svgNode, a11yTitle, a11yDescr);\n root.select(`[id=\"${id2}\"]`).selectAll(\"foreignobject > *\").attr(\"xmlns\", XMLNS_XHTML_STD);\n let svgCode = root.select(enclosingDivID_selector).node().innerHTML;\n log$1.debug(\"config.arrowMarkerAbsolute\", config2.arrowMarkerAbsolute);\n svgCode = cleanUpSvgCode(svgCode, isSandboxed, evaluate(config2.arrowMarkerAbsolute));\n if (isSandboxed) {\n const svgEl = root.select(enclosingDivID_selector + \" svg\").node();\n svgCode = putIntoIFrame(svgCode, svgEl);\n } else if (!isLooseSecurityLevel) {\n svgCode = DOMPurify.sanitize(svgCode, {\n ADD_TAGS: DOMPURIFY_TAGS,\n ADD_ATTR: DOMPURIFY_ATTR\n });\n }\n attachFunctions();\n if (parseEncounteredException) {\n throw parseEncounteredException;\n }\n const tmpElementSelector = isSandboxed ? iFrameID_selector : enclosingDivID_selector;\n const node = select(tmpElementSelector).node();\n if (node && \"remove\" in node) {\n node.remove();\n }\n return {\n svg: svgCode,\n bindFunctions: diag.db.bindFunctions\n };\n};\nfunction initialize$1(options = {}) {\n var _a;\n if ((options == null ? void 0 : options.fontFamily) && !((_a = options.themeVariables) == null ? void 0 : _a.fontFamily)) {\n if (!options.themeVariables) {\n options.themeVariables = {};\n }\n options.themeVariables.fontFamily = options.fontFamily;\n }\n saveConfigFromInitialize(options);\n if ((options == null ? void 0 : options.theme) && options.theme in theme) {\n options.themeVariables = theme[options.theme].getThemeVariables(\n options.themeVariables\n );\n } else if (options) {\n options.themeVariables = theme.default.getThemeVariables(options.themeVariables);\n }\n const config2 = typeof options === \"object\" ? setSiteConfig(options) : getSiteConfig();\n setLogLevel$1(config2.logLevel);\n addDiagrams();\n}\nfunction addA11yInfo(diagramType, svgNode, a11yTitle, a11yDescr) {\n setA11yDiagramInfo(svgNode, diagramType);\n addSVGa11yTitleDescription(svgNode, a11yTitle, a11yDescr, svgNode.attr(\"id\"));\n}\nconst mermaidAPI = Object.freeze({\n render: render$1,\n parse: parse$1,\n getDiagramFromText,\n initialize: initialize$1,\n getConfig: getConfig$1,\n setConfig: setConfig$1,\n getSiteConfig,\n updateSiteConfig,\n reset: () => {\n reset();\n },\n globalReset: () => {\n reset(defaultConfig$1);\n },\n defaultConfig: defaultConfig$1\n});\nsetLogLevel$1(getConfig$1().logLevel);\nreset(getConfig$1());\nconst loadRegisteredDiagrams = async () => {\n log$1.debug(`Loading registered diagrams`);\n const results = await Promise.allSettled(\n Object.entries(detectors).map(async ([key, { detector: detector2, loader: loader2 }]) => {\n if (loader2) {\n try {\n getDiagram(key);\n } catch (error) {\n try {\n const { diagram: diagram2, id: id2 } = await loader2();\n registerDiagram(id2, diagram2, detector2);\n } catch (err) {\n log$1.error(`Failed to load external diagram with key ${key}. Removing from detectors.`);\n delete detectors[key];\n throw err;\n }\n }\n }\n })\n );\n const failed = results.filter((result) => result.status === \"rejected\");\n if (failed.length > 0) {\n log$1.error(`Failed to load ${failed.length} external diagrams`);\n for (const res of failed) {\n log$1.error(res);\n }\n throw new Error(`Failed to load ${failed.length} external diagrams`);\n }\n};\nconst handleError = (error, errors, parseError) => {\n log$1.warn(error);\n if (isDetailedError(error)) {\n if (parseError) {\n parseError(error.str, error.hash);\n }\n errors.push({ ...error, message: error.str, error });\n } else {\n if (parseError) {\n parseError(error);\n }\n if (error instanceof Error) {\n errors.push({\n str: error.message,\n message: error.message,\n hash: error.name,\n error\n });\n }\n }\n};\nconst run = async function(options = {\n querySelector: \".mermaid\"\n}) {\n try {\n await runThrowsErrors(options);\n } catch (e) {\n if (isDetailedError(e)) {\n log$1.error(e.str);\n }\n if (mermaid.parseError) {\n mermaid.parseError(e);\n }\n if (!options.suppressErrors) {\n log$1.error(\"Use the suppressErrors option to suppress these errors\");\n throw e;\n }\n }\n};\nconst runThrowsErrors = async function({ postRenderCallback, querySelector, nodes } = {\n querySelector: \".mermaid\"\n}) {\n const conf = mermaidAPI.getConfig();\n log$1.debug(`${!postRenderCallback ? \"No \" : \"\"}Callback function found`);\n let nodesToProcess;\n if (nodes) {\n nodesToProcess = nodes;\n } else if (querySelector) {\n nodesToProcess = document.querySelectorAll(querySelector);\n } else {\n throw new Error(\"Nodes and querySelector are both undefined\");\n }\n log$1.debug(`Found ${nodesToProcess.length} diagrams`);\n if ((conf == null ? void 0 : conf.startOnLoad) !== void 0) {\n log$1.debug(\"Start On Load: \" + (conf == null ? void 0 : conf.startOnLoad));\n mermaidAPI.updateSiteConfig({ startOnLoad: conf == null ? void 0 : conf.startOnLoad });\n }\n const idGenerator = new utils.InitIDGenerator(conf.deterministicIds, conf.deterministicIDSeed);\n let txt;\n const errors = [];\n for (const element of Array.from(nodesToProcess)) {\n log$1.info(\"Rendering diagram: \" + element.id);\n /*! Check if previously processed */\n if (element.getAttribute(\"data-processed\")) {\n continue;\n }\n element.setAttribute(\"data-processed\", \"true\");\n const id2 = `mermaid-${idGenerator.next()}`;\n txt = element.innerHTML;\n txt = dedent(utils.entityDecode(txt)).trim().replace(//gi, \"
      \");\n const init2 = utils.detectInit(txt);\n if (init2) {\n log$1.debug(\"Detected early reinit: \", init2);\n }\n try {\n const { svg, bindFunctions } = await render(id2, txt, element);\n element.innerHTML = svg;\n if (postRenderCallback) {\n await postRenderCallback(id2);\n }\n if (bindFunctions) {\n bindFunctions(element);\n }\n } catch (error) {\n handleError(error, errors, mermaid.parseError);\n }\n }\n if (errors.length > 0) {\n throw errors[0];\n }\n};\nconst initialize = function(config2) {\n mermaidAPI.initialize(config2);\n};\nconst init = async function(config2, nodes, callback) {\n log$1.warn(\"mermaid.init is deprecated. Please use run instead.\");\n if (config2) {\n initialize(config2);\n }\n const runOptions = { postRenderCallback: callback, querySelector: \".mermaid\" };\n if (typeof nodes === \"string\") {\n runOptions.querySelector = nodes;\n } else if (nodes) {\n if (nodes instanceof HTMLElement) {\n runOptions.nodes = [nodes];\n } else {\n runOptions.nodes = nodes;\n }\n }\n await run(runOptions);\n};\nconst registerExternalDiagrams = async (diagrams2, {\n lazyLoad = true\n} = {}) => {\n registerLazyLoadedDiagrams(...diagrams2);\n if (lazyLoad === false) {\n await loadRegisteredDiagrams();\n }\n};\nconst contentLoaded = function() {\n if (mermaid.startOnLoad) {\n const { startOnLoad } = mermaidAPI.getConfig();\n if (startOnLoad) {\n mermaid.run().catch((err) => log$1.error(\"Mermaid failed to initialize\", err));\n }\n }\n};\nif (typeof document !== \"undefined\") {\n /*!\n * Wait for document loaded before starting the execution\n */\n window.addEventListener(\"load\", contentLoaded, false);\n}\nconst setParseErrorHandler = function(parseErrorHandler) {\n mermaid.parseError = parseErrorHandler;\n};\nconst executionQueue = [];\nlet executionQueueRunning = false;\nconst executeQueue = async () => {\n if (executionQueueRunning) {\n return;\n }\n executionQueueRunning = true;\n while (executionQueue.length > 0) {\n const f = executionQueue.shift();\n if (f) {\n try {\n await f();\n } catch (e) {\n log$1.error(\"Error executing queue\", e);\n }\n }\n }\n executionQueueRunning = false;\n};\nconst parse = async (text, parseOptions) => {\n return new Promise((resolve, reject) => {\n const performCall = () => new Promise((res, rej) => {\n mermaidAPI.parse(text, parseOptions).then(\n (r) => {\n res(r);\n resolve(r);\n },\n (e) => {\n var _a;\n log$1.error(\"Error parsing\", e);\n (_a = mermaid.parseError) == null ? void 0 : _a.call(mermaid, e);\n rej(e);\n reject(e);\n }\n );\n });\n executionQueue.push(performCall);\n executeQueue().catch(reject);\n });\n};\nconst render = (id2, text, container) => {\n return new Promise((resolve, reject) => {\n const performCall = () => new Promise((res, rej) => {\n mermaidAPI.render(id2, text, container).then(\n (r) => {\n res(r);\n resolve(r);\n },\n (e) => {\n var _a;\n log$1.error(\"Error parsing\", e);\n (_a = mermaid.parseError) == null ? void 0 : _a.call(mermaid, e);\n rej(e);\n reject(e);\n }\n );\n });\n executionQueue.push(performCall);\n executeQueue().catch(reject);\n });\n};\nconst mermaid = {\n startOnLoad: true,\n mermaidAPI,\n parse,\n render,\n init,\n run,\n registerExternalDiagrams,\n initialize,\n parseError: void 0,\n contentLoaded,\n setParseErrorHandler,\n detectType\n};\nexport {\n defaultConfig$2 as A,\n cleanAndMerge as B,\n parseFontSize as C,\n getThemeVariables$2 as D,\n getConfig$1 as E,\n addFunction as F,\n generateId as G,\n lineBreakRegex as H,\n defaultConfig as I,\n decodeEntities as J,\n commonDb as K,\n mermaid as L,\n ZERO_WIDTH_SPACE as Z,\n getAccDescription as a,\n setAccDescription as b,\n getConfig as c,\n sanitizeText$2 as d,\n common$1 as e,\n assignWithDepth$1 as f,\n getAccTitle as g,\n calculateTextWidth as h,\n configureSvgSize as i,\n calculateTextHeight as j,\n getStylesFromArray as k,\n log$1 as l,\n evaluate as m,\n interpolateToCurve as n,\n setupGraphViewbox$1 as o,\n setConfig as p,\n setDiagramTitle as q,\n getDiagramTitle as r,\n setAccTitle as s,\n clear as t,\n utils as u,\n parseGenericTypes as v,\n wrapLabel as w,\n random as x,\n setupGraphViewbox as y,\n selectSvgElement as z\n};\n", "export var MS = '-ms-'\nexport var MOZ = '-moz-'\nexport var WEBKIT = '-webkit-'\n\nexport var COMMENT = 'comm'\nexport var RULESET = 'rule'\nexport var DECLARATION = 'decl'\n\nexport var PAGE = '@page'\nexport var MEDIA = '@media'\nexport var IMPORT = '@import'\nexport var CHARSET = '@charset'\nexport var VIEWPORT = '@viewport'\nexport var SUPPORTS = '@supports'\nexport var DOCUMENT = '@document'\nexport var NAMESPACE = '@namespace'\nexport var KEYFRAMES = '@keyframes'\nexport var FONT_FACE = '@font-face'\nexport var COUNTER_STYLE = '@counter-style'\nexport var FONT_FEATURE_VALUES = '@font-feature-values'\n", "/**\n * @param {number}\n * @return {number}\n */\nexport var abs = Math.abs\n\n/**\n * @param {number}\n * @return {string}\n */\nexport var from = String.fromCharCode\n\n/**\n * @param {object}\n * @return {object}\n */\nexport var assign = Object.assign\n\n/**\n * @param {string} value\n * @param {number} length\n * @return {number}\n */\nexport function hash (value, length) {\n\treturn charat(value, 0) ^ 45 ? (((((((length << 2) ^ charat(value, 0)) << 2) ^ charat(value, 1)) << 2) ^ charat(value, 2)) << 2) ^ charat(value, 3) : 0\n}\n\n/**\n * @param {string} value\n * @return {string}\n */\nexport function trim (value) {\n\treturn value.trim()\n}\n\n/**\n * @param {string} value\n * @param {RegExp} pattern\n * @return {string?}\n */\nexport function match (value, pattern) {\n\treturn (value = pattern.exec(value)) ? value[0] : value\n}\n\n/**\n * @param {string} value\n * @param {(string|RegExp)} pattern\n * @param {string} replacement\n * @return {string}\n */\nexport function replace (value, pattern, replacement) {\n\treturn value.replace(pattern, replacement)\n}\n\n/**\n * @param {string} value\n * @param {string} search\n * @return {number}\n */\nexport function indexof (value, search) {\n\treturn value.indexOf(search)\n}\n\n/**\n * @param {string} value\n * @param {number} index\n * @return {number}\n */\nexport function charat (value, index) {\n\treturn value.charCodeAt(index) | 0\n}\n\n/**\n * @param {string} value\n * @param {number} begin\n * @param {number} end\n * @return {string}\n */\nexport function substr (value, begin, end) {\n\treturn value.slice(begin, end)\n}\n\n/**\n * @param {string} value\n * @return {number}\n */\nexport function strlen (value) {\n\treturn value.length\n}\n\n/**\n * @param {any[]} value\n * @return {number}\n */\nexport function sizeof (value) {\n\treturn value.length\n}\n\n/**\n * @param {any} value\n * @param {any[]} array\n * @return {any}\n */\nexport function append (value, array) {\n\treturn array.push(value), value\n}\n\n/**\n * @param {string[]} array\n * @param {function} callback\n * @return {string}\n */\nexport function combine (array, callback) {\n\treturn array.map(callback).join('')\n}\n", "import {from, trim, charat, strlen, substr, append, assign} from './Utility.js'\n\nexport var line = 1\nexport var column = 1\nexport var length = 0\nexport var position = 0\nexport var character = 0\nexport var characters = ''\n\n/**\n * @param {string} value\n * @param {object | null} root\n * @param {object | null} parent\n * @param {string} type\n * @param {string[] | string} props\n * @param {object[] | string} children\n * @param {number} length\n */\nexport function node (value, root, parent, type, props, children, length) {\n\treturn {value: value, root: root, parent: parent, type: type, props: props, children: children, line: line, column: column, length: length, return: ''}\n}\n\n/**\n * @param {object} root\n * @param {object} props\n * @return {object}\n */\nexport function copy (root, props) {\n\treturn assign(node('', null, null, '', null, null, 0), root, {length: -root.length}, props)\n}\n\n/**\n * @return {number}\n */\nexport function char () {\n\treturn character\n}\n\n/**\n * @return {number}\n */\nexport function prev () {\n\tcharacter = position > 0 ? charat(characters, --position) : 0\n\n\tif (column--, character === 10)\n\t\tcolumn = 1, line--\n\n\treturn character\n}\n\n/**\n * @return {number}\n */\nexport function next () {\n\tcharacter = position < length ? charat(characters, position++) : 0\n\n\tif (column++, character === 10)\n\t\tcolumn = 1, line++\n\n\treturn character\n}\n\n/**\n * @return {number}\n */\nexport function peek () {\n\treturn charat(characters, position)\n}\n\n/**\n * @return {number}\n */\nexport function caret () {\n\treturn position\n}\n\n/**\n * @param {number} begin\n * @param {number} end\n * @return {string}\n */\nexport function slice (begin, end) {\n\treturn substr(characters, begin, end)\n}\n\n/**\n * @param {number} type\n * @return {number}\n */\nexport function token (type) {\n\tswitch (type) {\n\t\t// \\0 \\t \\n \\r \\s whitespace token\n\t\tcase 0: case 9: case 10: case 13: case 32:\n\t\t\treturn 5\n\t\t// ! + , / > @ ~ isolate token\n\t\tcase 33: case 43: case 44: case 47: case 62: case 64: case 126:\n\t\t// ; { } breakpoint token\n\t\tcase 59: case 123: case 125:\n\t\t\treturn 4\n\t\t// : accompanied token\n\t\tcase 58:\n\t\t\treturn 3\n\t\t// \" ' ( [ opening delimit token\n\t\tcase 34: case 39: case 40: case 91:\n\t\t\treturn 2\n\t\t// ) ] closing delimit token\n\t\tcase 41: case 93:\n\t\t\treturn 1\n\t}\n\n\treturn 0\n}\n\n/**\n * @param {string} value\n * @return {any[]}\n */\nexport function alloc (value) {\n\treturn line = column = 1, length = strlen(characters = value), position = 0, []\n}\n\n/**\n * @param {any} value\n * @return {any}\n */\nexport function dealloc (value) {\n\treturn characters = '', value\n}\n\n/**\n * @param {number} type\n * @return {string}\n */\nexport function delimit (type) {\n\treturn trim(slice(position - 1, delimiter(type === 91 ? type + 2 : type === 40 ? type + 1 : type)))\n}\n\n/**\n * @param {string} value\n * @return {string[]}\n */\nexport function tokenize (value) {\n\treturn dealloc(tokenizer(alloc(value)))\n}\n\n/**\n * @param {number} type\n * @return {string}\n */\nexport function whitespace (type) {\n\twhile (character = peek())\n\t\tif (character < 33)\n\t\t\tnext()\n\t\telse\n\t\t\tbreak\n\n\treturn token(type) > 2 || token(character) > 3 ? '' : ' '\n}\n\n/**\n * @param {string[]} children\n * @return {string[]}\n */\nexport function tokenizer (children) {\n\twhile (next())\n\t\tswitch (token(character)) {\n\t\t\tcase 0: append(identifier(position - 1), children)\n\t\t\t\tbreak\n\t\t\tcase 2: append(delimit(character), children)\n\t\t\t\tbreak\n\t\t\tdefault: append(from(character), children)\n\t\t}\n\n\treturn children\n}\n\n/**\n * @param {number} index\n * @param {number} count\n * @return {string}\n */\nexport function escaping (index, count) {\n\twhile (--count && next())\n\t\t// not 0-9 A-F a-f\n\t\tif (character < 48 || character > 102 || (character > 57 && character < 65) || (character > 70 && character < 97))\n\t\t\tbreak\n\n\treturn slice(index, caret() + (count < 6 && peek() == 32 && next() == 32))\n}\n\n/**\n * @param {number} type\n * @return {number}\n */\nexport function delimiter (type) {\n\twhile (next())\n\t\tswitch (character) {\n\t\t\t// ] ) \" '\n\t\t\tcase type:\n\t\t\t\treturn position\n\t\t\t// \" '\n\t\t\tcase 34: case 39:\n\t\t\t\tif (type !== 34 && type !== 39)\n\t\t\t\t\tdelimiter(character)\n\t\t\t\tbreak\n\t\t\t// (\n\t\t\tcase 40:\n\t\t\t\tif (type === 41)\n\t\t\t\t\tdelimiter(type)\n\t\t\t\tbreak\n\t\t\t// \\\n\t\t\tcase 92:\n\t\t\t\tnext()\n\t\t\t\tbreak\n\t\t}\n\n\treturn position\n}\n\n/**\n * @param {number} type\n * @param {number} index\n * @return {number}\n */\nexport function commenter (type, index) {\n\twhile (next())\n\t\t// //\n\t\tif (type + character === 47 + 10)\n\t\t\tbreak\n\t\t// /*\n\t\telse if (type + character === 42 + 42 && peek() === 47)\n\t\t\tbreak\n\n\treturn '/*' + slice(index, position - 1) + '*' + from(type === 47 ? type : next())\n}\n\n/**\n * @param {number} index\n * @return {string}\n */\nexport function identifier (index) {\n\twhile (!token(peek()))\n\t\tnext()\n\n\treturn slice(index, position)\n}\n", "import {COMMENT, RULESET, DECLARATION} from './Enum.js'\nimport {abs, charat, trim, from, sizeof, strlen, substr, append, replace, indexof} from './Utility.js'\nimport {node, char, prev, next, peek, caret, alloc, dealloc, delimit, whitespace, escaping, identifier, commenter} from './Tokenizer.js'\n\n/**\n * @param {string} value\n * @return {object[]}\n */\nexport function compile (value) {\n\treturn dealloc(parse('', null, null, null, [''], value = alloc(value), 0, [0], value))\n}\n\n/**\n * @param {string} value\n * @param {object} root\n * @param {object?} parent\n * @param {string[]} rule\n * @param {string[]} rules\n * @param {string[]} rulesets\n * @param {number[]} pseudo\n * @param {number[]} points\n * @param {string[]} declarations\n * @return {object}\n */\nexport function parse (value, root, parent, rule, rules, rulesets, pseudo, points, declarations) {\n\tvar index = 0\n\tvar offset = 0\n\tvar length = pseudo\n\tvar atrule = 0\n\tvar property = 0\n\tvar previous = 0\n\tvar variable = 1\n\tvar scanning = 1\n\tvar ampersand = 1\n\tvar character = 0\n\tvar type = ''\n\tvar props = rules\n\tvar children = rulesets\n\tvar reference = rule\n\tvar characters = type\n\n\twhile (scanning)\n\t\tswitch (previous = character, character = next()) {\n\t\t\t// (\n\t\t\tcase 40:\n\t\t\t\tif (previous != 108 && charat(characters, length - 1) == 58) {\n\t\t\t\t\tif (indexof(characters += replace(delimit(character), '&', '&\\f'), '&\\f') != -1)\n\t\t\t\t\t\tampersand = -1\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t// \" ' [\n\t\t\tcase 34: case 39: case 91:\n\t\t\t\tcharacters += delimit(character)\n\t\t\t\tbreak\n\t\t\t// \\t \\n \\r \\s\n\t\t\tcase 9: case 10: case 13: case 32:\n\t\t\t\tcharacters += whitespace(previous)\n\t\t\t\tbreak\n\t\t\t// \\\n\t\t\tcase 92:\n\t\t\t\tcharacters += escaping(caret() - 1, 7)\n\t\t\t\tcontinue\n\t\t\t// /\n\t\t\tcase 47:\n\t\t\t\tswitch (peek()) {\n\t\t\t\t\tcase 42: case 47:\n\t\t\t\t\t\tappend(comment(commenter(next(), caret()), root, parent), declarations)\n\t\t\t\t\t\tbreak\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tcharacters += '/'\n\t\t\t\t}\n\t\t\t\tbreak\n\t\t\t// {\n\t\t\tcase 123 * variable:\n\t\t\t\tpoints[index++] = strlen(characters) * ampersand\n\t\t\t// } ; \\0\n\t\t\tcase 125 * variable: case 59: case 0:\n\t\t\t\tswitch (character) {\n\t\t\t\t\t// \\0 }\n\t\t\t\t\tcase 0: case 125: scanning = 0\n\t\t\t\t\t// ;\n\t\t\t\t\tcase 59 + offset:\n\t\t\t\t\t\tif (property > 0 && (strlen(characters) - length))\n\t\t\t\t\t\t\tappend(property > 32 ? declaration(characters + ';', rule, parent, length - 1) : declaration(replace(characters, ' ', '') + ';', rule, parent, length - 2), declarations)\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// @ ;\n\t\t\t\t\tcase 59: characters += ';'\n\t\t\t\t\t// { rule/at-rule\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tappend(reference = ruleset(characters, root, parent, index, offset, rules, points, type, props = [], children = [], length), rulesets)\n\n\t\t\t\t\t\tif (character === 123)\n\t\t\t\t\t\t\tif (offset === 0)\n\t\t\t\t\t\t\t\tparse(characters, root, reference, reference, props, rulesets, length, points, children)\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\tswitch (atrule === 99 && charat(characters, 3) === 110 ? 100 : atrule) {\n\t\t\t\t\t\t\t\t\t// d m s\n\t\t\t\t\t\t\t\t\tcase 100: case 109: case 115:\n\t\t\t\t\t\t\t\t\t\tparse(value, reference, reference, rule && append(ruleset(value, reference, reference, 0, 0, rules, points, type, rules, props = [], length), children), rules, children, length, points, rule ? props : children)\n\t\t\t\t\t\t\t\t\t\tbreak\n\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\tparse(characters, reference, reference, reference, [''], children, 0, points, children)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tindex = offset = property = 0, variable = ampersand = 1, type = characters = '', length = pseudo\n\t\t\t\tbreak\n\t\t\t// :\n\t\t\tcase 58:\n\t\t\t\tlength = 1 + strlen(characters), property = previous\n\t\t\tdefault:\n\t\t\t\tif (variable < 1)\n\t\t\t\t\tif (character == 123)\n\t\t\t\t\t\t--variable\n\t\t\t\t\telse if (character == 125 && variable++ == 0 && prev() == 125)\n\t\t\t\t\t\tcontinue\n\n\t\t\t\tswitch (characters += from(character), character * variable) {\n\t\t\t\t\t// &\n\t\t\t\t\tcase 38:\n\t\t\t\t\t\tampersand = offset > 0 ? 1 : (characters += '\\f', -1)\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// ,\n\t\t\t\t\tcase 44:\n\t\t\t\t\t\tpoints[index++] = (strlen(characters) - 1) * ampersand, ampersand = 1\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// @\n\t\t\t\t\tcase 64:\n\t\t\t\t\t\t// -\n\t\t\t\t\t\tif (peek() === 45)\n\t\t\t\t\t\t\tcharacters += delimit(next())\n\n\t\t\t\t\t\tatrule = peek(), offset = length = strlen(type = characters += identifier(caret())), character++\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// -\n\t\t\t\t\tcase 45:\n\t\t\t\t\t\tif (previous === 45 && strlen(characters) == 2)\n\t\t\t\t\t\t\tvariable = 0\n\t\t\t\t}\n\t\t}\n\n\treturn rulesets\n}\n\n/**\n * @param {string} value\n * @param {object} root\n * @param {object?} parent\n * @param {number} index\n * @param {number} offset\n * @param {string[]} rules\n * @param {number[]} points\n * @param {string} type\n * @param {string[]} props\n * @param {string[]} children\n * @param {number} length\n * @return {object}\n */\nexport function ruleset (value, root, parent, index, offset, rules, points, type, props, children, length) {\n\tvar post = offset - 1\n\tvar rule = offset === 0 ? rules : ['']\n\tvar size = sizeof(rule)\n\n\tfor (var i = 0, j = 0, k = 0; i < index; ++i)\n\t\tfor (var x = 0, y = substr(value, post + 1, post = abs(j = points[i])), z = value; x < size; ++x)\n\t\t\tif (z = trim(j > 0 ? rule[x] + ' ' + y : replace(y, /&\\f/g, rule[x])))\n\t\t\t\tprops[k++] = z\n\n\treturn node(value, root, parent, offset === 0 ? RULESET : type, props, children, length)\n}\n\n/**\n * @param {number} value\n * @param {object} root\n * @param {object?} parent\n * @return {object}\n */\nexport function comment (value, root, parent) {\n\treturn node(value, root, parent, COMMENT, from(char()), substr(value, 2, -2), 0)\n}\n\n/**\n * @param {string} value\n * @param {object} root\n * @param {object?} parent\n * @param {number} length\n * @return {object}\n */\nexport function declaration (value, root, parent, length) {\n\treturn node(value, root, parent, DECLARATION, substr(value, 0, length), substr(value, length + 1, -1), length)\n}\n", "import {IMPORT, COMMENT, RULESET, DECLARATION, KEYFRAMES} from './Enum.js'\nimport {strlen, sizeof} from './Utility.js'\n\n/**\n * @param {object[]} children\n * @param {function} callback\n * @return {string}\n */\nexport function serialize (children, callback) {\n\tvar output = ''\n\tvar length = sizeof(children)\n\n\tfor (var i = 0; i < length; i++)\n\t\toutput += callback(children[i], i, children, callback) || ''\n\n\treturn output\n}\n\n/**\n * @param {object} element\n * @param {number} index\n * @param {object[]} children\n * @param {function} callback\n * @return {string}\n */\nexport function stringify (element, index, children, callback) {\n\tswitch (element.type) {\n\t\tcase IMPORT: case DECLARATION: return element.return = element.return || element.value\n\t\tcase COMMENT: return ''\n\t\tcase KEYFRAMES: return element.return = element.value + '{' + serialize(element.children, callback) + '}'\n\t\tcase RULESET: element.value = element.props.join(',')\n\t}\n\n\treturn strlen(children = serialize(element.children, callback)) ? element.return = element.value + '{' + children + '}' : ''\n}\n"], + "sources": ["../../node_modules/dayjs/dayjs.min.js", "../../node_modules/@braintree/sanitize-url/dist/index.js", "../../node_modules/dompurify/src/utils.js", "../../node_modules/dompurify/src/tags.js", "../../node_modules/dompurify/src/attrs.js", "../../node_modules/dompurify/src/regexp.js", "../../node_modules/dompurify/src/purify.js", "../../node_modules/ts-dedent/src/index.ts", "../../node_modules/d3-array/src/max.js", "../../node_modules/d3-array/src/min.js", "../../node_modules/d3-array/src/ascending.js", "../../node_modules/d3-array/src/descending.js", "../../node_modules/d3-array/src/bisector.js", "../../node_modules/d3-array/src/number.js", "../../node_modules/d3-array/src/bisect.js", "../../node_modules/internmap/src/index.js", "../../node_modules/d3-array/src/ticks.js", "../../node_modules/d3-array/src/range.js", "../../node_modules/d3-axis/src/identity.js", "../../node_modules/d3-axis/src/axis.js", "../../node_modules/d3-selection/src/selector.js", "../../node_modules/d3-selection/src/selection/select.js", "../../node_modules/d3-selection/src/array.js", "../../node_modules/d3-selection/src/selectorAll.js", "../../node_modules/d3-selection/src/selection/selectAll.js", "../../node_modules/d3-selection/src/matcher.js", "../../node_modules/d3-selection/src/selection/selectChild.js", "../../node_modules/d3-selection/src/selection/selectChildren.js", "../../node_modules/d3-selection/src/selection/filter.js", "../../node_modules/d3-selection/src/selection/sparse.js", "../../node_modules/d3-selection/src/selection/enter.js", "../../node_modules/d3-selection/src/constant.js", "../../node_modules/d3-selection/src/selection/data.js", "../../node_modules/d3-selection/src/selection/exit.js", "../../node_modules/d3-selection/src/selection/join.js", "../../node_modules/d3-selection/src/selection/merge.js", "../../node_modules/d3-selection/src/selection/order.js", "../../node_modules/d3-selection/src/selection/sort.js", "../../node_modules/d3-selection/src/selection/call.js", "../../node_modules/d3-selection/src/selection/nodes.js", "../../node_modules/d3-selection/src/selection/node.js", "../../node_modules/d3-selection/src/selection/size.js", "../../node_modules/d3-selection/src/selection/empty.js", "../../node_modules/d3-selection/src/selection/each.js", "../../node_modules/d3-selection/src/namespaces.js", "../../node_modules/d3-selection/src/namespace.js", "../../node_modules/d3-selection/src/selection/attr.js", "../../node_modules/d3-selection/src/window.js", "../../node_modules/d3-selection/src/selection/style.js", "../../node_modules/d3-selection/src/selection/property.js", "../../node_modules/d3-selection/src/selection/classed.js", "../../node_modules/d3-selection/src/selection/text.js", "../../node_modules/d3-selection/src/selection/html.js", "../../node_modules/d3-selection/src/selection/raise.js", "../../node_modules/d3-selection/src/selection/lower.js", "../../node_modules/d3-selection/src/creator.js", "../../node_modules/d3-selection/src/selection/append.js", "../../node_modules/d3-selection/src/selection/insert.js", "../../node_modules/d3-selection/src/selection/remove.js", "../../node_modules/d3-selection/src/selection/clone.js", "../../node_modules/d3-selection/src/selection/datum.js", "../../node_modules/d3-selection/src/selection/on.js", "../../node_modules/d3-selection/src/selection/dispatch.js", "../../node_modules/d3-selection/src/selection/iterator.js", "../../node_modules/d3-selection/src/selection/index.js", "../../node_modules/d3-selection/src/select.js", "../../node_modules/d3-selection/src/selectAll.js", "../../node_modules/d3-color/src/define.js", "../../node_modules/d3-color/src/color.js", "../../node_modules/d3-color/src/math.js", "../../node_modules/d3-color/src/lab.js", "../../node_modules/d3-interpolate/src/constant.js", "../../node_modules/d3-interpolate/src/color.js", "../../node_modules/d3-interpolate/src/hcl.js", "../../node_modules/d3-interpolate/src/basis.js", "../../node_modules/d3-interpolate/src/basisClosed.js", "../../node_modules/d3-interpolate/src/rgb.js", "../../node_modules/d3-interpolate/src/numberArray.js", "../../node_modules/d3-interpolate/src/array.js", "../../node_modules/d3-interpolate/src/date.js", "../../node_modules/d3-interpolate/src/number.js", "../../node_modules/d3-interpolate/src/object.js", "../../node_modules/d3-interpolate/src/string.js", "../../node_modules/d3-interpolate/src/value.js", "../../node_modules/d3-interpolate/src/round.js", "../../node_modules/d3-interpolate/src/transform/decompose.js", "../../node_modules/d3-interpolate/src/transform/parse.js", "../../node_modules/d3-interpolate/src/transform/index.js", "../../node_modules/d3-scale/src/init.js", "../../node_modules/d3-scale/src/ordinal.js", "../../node_modules/d3-scale/src/band.js", "../../node_modules/d3-scale/src/constant.js", "../../node_modules/d3-scale/src/number.js", "../../node_modules/d3-scale/src/continuous.js", "../../node_modules/d3-format/src/formatDecimal.js", "../../node_modules/d3-format/src/exponent.js", "../../node_modules/d3-format/src/formatGroup.js", "../../node_modules/d3-format/src/formatNumerals.js", "../../node_modules/d3-format/src/formatSpecifier.js", "../../node_modules/d3-format/src/formatTrim.js", "../../node_modules/d3-format/src/formatPrefixAuto.js", "../../node_modules/d3-format/src/formatRounded.js", "../../node_modules/d3-format/src/formatTypes.js", "../../node_modules/d3-format/src/identity.js", "../../node_modules/d3-format/src/locale.js", "../../node_modules/d3-format/src/defaultLocale.js", "../../node_modules/d3-format/src/precisionFixed.js", "../../node_modules/d3-format/src/precisionPrefix.js", "../../node_modules/d3-format/src/precisionRound.js", "../../node_modules/d3-scale/src/tickFormat.js", "../../node_modules/d3-scale/src/linear.js", "../../node_modules/d3-time/src/interval.js", "../../node_modules/d3-time/src/millisecond.js", "../../node_modules/d3-time/src/second.js", "../../node_modules/d3-time/src/minute.js", "../../node_modules/d3-time/src/hour.js", "../../node_modules/d3-time/src/day.js", "../../node_modules/d3-time/src/week.js", "../../node_modules/d3-time/src/month.js", "../../node_modules/d3-time/src/year.js", "../../node_modules/d3-time/src/ticks.js", "../../node_modules/d3-time-format/src/locale.js", "../../node_modules/d3-time-format/src/defaultLocale.js", "../../node_modules/d3-scale/src/nice.js", "../../node_modules/d3-scale/src/time.js", "../../node_modules/d3-scale-chromatic/src/colors.js", "../../node_modules/d3-scale-chromatic/src/categorical/Tableau10.js", "../../node_modules/d3-shape/src/constant.js", "../../node_modules/d3-shape/src/math.js", "../../node_modules/d3-path/src/path.js", "../../node_modules/d3-shape/src/path.js", "../../node_modules/d3-shape/src/arc.js", "../../node_modules/d3-shape/src/curve/linear.js", "../../node_modules/d3-shape/src/array.js", "../../node_modules/d3-shape/src/point.js", "../../node_modules/d3-shape/src/line.js", "../../node_modules/d3-shape/src/descending.js", "../../node_modules/d3-shape/src/identity.js", "../../node_modules/d3-shape/src/pie.js", "../../node_modules/d3-shape/src/curve/basis.js", "../../node_modules/d3-shape/src/curve/bump.js", "../../node_modules/d3-shape/src/noop.js", "../../node_modules/d3-shape/src/curve/basisClosed.js", "../../node_modules/d3-shape/src/curve/basisOpen.js", "../../node_modules/d3-shape/src/curve/bundle.js", "../../node_modules/d3-shape/src/curve/cardinal.js", "../../node_modules/d3-shape/src/curve/cardinalClosed.js", "../../node_modules/d3-shape/src/curve/cardinalOpen.js", "../../node_modules/d3-shape/src/curve/catmullRom.js", "../../node_modules/d3-shape/src/curve/catmullRomClosed.js", "../../node_modules/d3-shape/src/curve/catmullRomOpen.js", "../../node_modules/d3-shape/src/curve/linearClosed.js", "../../node_modules/d3-shape/src/curve/monotone.js", "../../node_modules/d3-shape/src/curve/natural.js", "../../node_modules/d3-shape/src/curve/step.js", "../../node_modules/d3-dispatch/src/dispatch.js", "../../node_modules/d3-timer/src/timer.js", "../../node_modules/d3-timer/src/timeout.js", "../../node_modules/d3-transition/src/transition/schedule.js", "../../node_modules/d3-transition/src/interrupt.js", "../../node_modules/d3-transition/src/selection/interrupt.js", "../../node_modules/d3-transition/src/transition/tween.js", "../../node_modules/d3-transition/src/transition/interpolate.js", "../../node_modules/d3-transition/src/transition/attr.js", "../../node_modules/d3-transition/src/transition/attrTween.js", "../../node_modules/d3-transition/src/transition/delay.js", "../../node_modules/d3-transition/src/transition/duration.js", "../../node_modules/d3-transition/src/transition/ease.js", "../../node_modules/d3-transition/src/transition/easeVarying.js", "../../node_modules/d3-transition/src/transition/filter.js", "../../node_modules/d3-transition/src/transition/merge.js", "../../node_modules/d3-transition/src/transition/on.js", "../../node_modules/d3-transition/src/transition/remove.js", "../../node_modules/d3-transition/src/transition/select.js", "../../node_modules/d3-transition/src/transition/selectAll.js", "../../node_modules/d3-transition/src/transition/selection.js", "../../node_modules/d3-transition/src/transition/style.js", "../../node_modules/d3-transition/src/transition/styleTween.js", "../../node_modules/d3-transition/src/transition/text.js", "../../node_modules/d3-transition/src/transition/textTween.js", "../../node_modules/d3-transition/src/transition/transition.js", "../../node_modules/d3-transition/src/transition/end.js", "../../node_modules/d3-transition/src/transition/index.js", "../../node_modules/d3-ease/src/cubic.js", "../../node_modules/d3-transition/src/selection/transition.js", "../../node_modules/d3-transition/src/selection/index.js", "../../node_modules/d3-brush/src/brush.js", "../../node_modules/d3-fetch/src/text.js", "../../node_modules/d3-fetch/src/xml.js", "../../node_modules/d3-zoom/src/transform.js", "../../node_modules/khroma/dist/utils/channel.js", "../../node_modules/khroma/dist/utils/lang.js", "../../node_modules/khroma/dist/utils/unit.js", "../../node_modules/khroma/dist/utils/index.js", "../../node_modules/khroma/dist/constants.js", "../../node_modules/khroma/dist/channels/type.js", "../../node_modules/khroma/dist/channels/index.js", "../../node_modules/khroma/dist/channels/reusable.js", "../../node_modules/khroma/dist/color/hex.js", "../../node_modules/khroma/dist/color/hsl.js", "../../node_modules/khroma/dist/color/keyword.js", "../../node_modules/khroma/dist/color/rgb.js", "../../node_modules/khroma/dist/color/index.js", "../../node_modules/khroma/dist/methods/luminance.js", "../../node_modules/khroma/dist/methods/is_light.js", "../../node_modules/khroma/dist/methods/is_dark.js", "../../node_modules/khroma/dist/methods/adjust_channel.js", "../../node_modules/khroma/dist/methods/lighten.js", "../../node_modules/khroma/dist/methods/darken.js", "../../node_modules/khroma/dist/methods/change.js", "../../node_modules/khroma/dist/methods/rgba.js", "../../node_modules/khroma/dist/methods/channel.js", "../../node_modules/khroma/dist/methods/adjust.js", "../../node_modules/khroma/dist/methods/mix.js", "../../node_modules/khroma/dist/methods/invert.js", "../../node_modules/lodash-es/_freeGlobal.js", "../../node_modules/lodash-es/_root.js", "../../node_modules/lodash-es/_Symbol.js", "../../node_modules/lodash-es/_getRawTag.js", "../../node_modules/lodash-es/_objectToString.js", "../../node_modules/lodash-es/_baseGetTag.js", "../../node_modules/lodash-es/isObject.js", "../../node_modules/lodash-es/isFunction.js", "../../node_modules/lodash-es/_coreJsData.js", "../../node_modules/lodash-es/_isMasked.js", "../../node_modules/lodash-es/_toSource.js", "../../node_modules/lodash-es/_baseIsNative.js", "../../node_modules/lodash-es/_getValue.js", "../../node_modules/lodash-es/_getNative.js", "../../node_modules/lodash-es/_nativeCreate.js", "../../node_modules/lodash-es/_hashClear.js", "../../node_modules/lodash-es/_hashDelete.js", "../../node_modules/lodash-es/_hashGet.js", "../../node_modules/lodash-es/_hashHas.js", "../../node_modules/lodash-es/_hashSet.js", "../../node_modules/lodash-es/_Hash.js", "../../node_modules/lodash-es/_listCacheClear.js", "../../node_modules/lodash-es/eq.js", "../../node_modules/lodash-es/_assocIndexOf.js", "../../node_modules/lodash-es/_listCacheDelete.js", "../../node_modules/lodash-es/_listCacheGet.js", "../../node_modules/lodash-es/_listCacheHas.js", "../../node_modules/lodash-es/_listCacheSet.js", "../../node_modules/lodash-es/_ListCache.js", "../../node_modules/lodash-es/_Map.js", "../../node_modules/lodash-es/_mapCacheClear.js", "../../node_modules/lodash-es/_isKeyable.js", "../../node_modules/lodash-es/_getMapData.js", "../../node_modules/lodash-es/_mapCacheDelete.js", "../../node_modules/lodash-es/_mapCacheGet.js", "../../node_modules/lodash-es/_mapCacheHas.js", "../../node_modules/lodash-es/_mapCacheSet.js", "../../node_modules/lodash-es/_MapCache.js", "../../node_modules/lodash-es/memoize.js", "../../node_modules/lodash-es/_stackClear.js", "../../node_modules/lodash-es/_stackDelete.js", "../../node_modules/lodash-es/_stackGet.js", "../../node_modules/lodash-es/_stackHas.js", "../../node_modules/lodash-es/_stackSet.js", "../../node_modules/lodash-es/_Stack.js", "../../node_modules/lodash-es/_defineProperty.js", "../../node_modules/lodash-es/_baseAssignValue.js", "../../node_modules/lodash-es/_assignMergeValue.js", "../../node_modules/lodash-es/_createBaseFor.js", "../../node_modules/lodash-es/_baseFor.js", "../../node_modules/lodash-es/_cloneBuffer.js", "../../node_modules/lodash-es/_Uint8Array.js", "../../node_modules/lodash-es/_cloneArrayBuffer.js", "../../node_modules/lodash-es/_cloneTypedArray.js", "../../node_modules/lodash-es/_copyArray.js", "../../node_modules/lodash-es/_baseCreate.js", "../../node_modules/lodash-es/_overArg.js", "../../node_modules/lodash-es/_getPrototype.js", "../../node_modules/lodash-es/_isPrototype.js", "../../node_modules/lodash-es/_initCloneObject.js", "../../node_modules/lodash-es/isObjectLike.js", "../../node_modules/lodash-es/_baseIsArguments.js", "../../node_modules/lodash-es/isArguments.js", "../../node_modules/lodash-es/isArray.js", "../../node_modules/lodash-es/isLength.js", "../../node_modules/lodash-es/isArrayLike.js", "../../node_modules/lodash-es/isArrayLikeObject.js", "../../node_modules/lodash-es/stubFalse.js", "../../node_modules/lodash-es/isBuffer.js", "../../node_modules/lodash-es/isPlainObject.js", "../../node_modules/lodash-es/_baseIsTypedArray.js", "../../node_modules/lodash-es/_baseUnary.js", "../../node_modules/lodash-es/_nodeUtil.js", "../../node_modules/lodash-es/isTypedArray.js", "../../node_modules/lodash-es/_safeGet.js", "../../node_modules/lodash-es/_assignValue.js", "../../node_modules/lodash-es/_copyObject.js", "../../node_modules/lodash-es/_baseTimes.js", "../../node_modules/lodash-es/_isIndex.js", "../../node_modules/lodash-es/_arrayLikeKeys.js", "../../node_modules/lodash-es/_nativeKeysIn.js", "../../node_modules/lodash-es/_baseKeysIn.js", "../../node_modules/lodash-es/keysIn.js", "../../node_modules/lodash-es/toPlainObject.js", "../../node_modules/lodash-es/_baseMergeDeep.js", "../../node_modules/lodash-es/_baseMerge.js", "../../node_modules/lodash-es/identity.js", "../../node_modules/lodash-es/_apply.js", "../../node_modules/lodash-es/_overRest.js", "../../node_modules/lodash-es/constant.js", "../../node_modules/lodash-es/_baseSetToString.js", "../../node_modules/lodash-es/_shortOut.js", "../../node_modules/lodash-es/_setToString.js", "../../node_modules/lodash-es/_baseRest.js", "../../node_modules/lodash-es/_isIterateeCall.js", "../../node_modules/lodash-es/_createAssigner.js", "../../node_modules/lodash-es/merge.js", "../../node_modules/lodash-es/_nativeKeys.js", "../../node_modules/lodash-es/_baseKeys.js", "../../node_modules/lodash-es/_DataView.js", "../../node_modules/lodash-es/_Promise.js", "../../node_modules/lodash-es/_Set.js", "../../node_modules/lodash-es/_WeakMap.js", "../../node_modules/lodash-es/_getTag.js", "../../node_modules/lodash-es/isEmpty.js", "../../node_modules/mermaid/dist/mermaid-934d9bea.js", "../../node_modules/stylis/src/Enum.js", "../../node_modules/stylis/src/Utility.js", "../../node_modules/stylis/src/Tokenizer.js", "../../node_modules/stylis/src/Parser.js", "../../node_modules/stylis/src/Serializer.js"], + "sourcesContent": ["!function(t,e){\"object\"==typeof exports&&\"undefined\"!=typeof module?module.exports=e():\"function\"==typeof define&&define.amd?define(e):(t=\"undefined\"!=typeof globalThis?globalThis:t||self).dayjs=e()}(this,(function(){\"use strict\";var t=1e3,e=6e4,n=36e5,r=\"millisecond\",i=\"second\",s=\"minute\",u=\"hour\",a=\"day\",o=\"week\",f=\"month\",h=\"quarter\",c=\"year\",d=\"date\",l=\"Invalid Date\",$=/^(\\d{4})[-/]?(\\d{1,2})?[-/]?(\\d{0,2})[Tt\\s]*(\\d{1,2})?:?(\\d{1,2})?:?(\\d{1,2})?[.:]?(\\d+)?$/,y=/\\[([^\\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:\"en\",weekdays:\"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday\".split(\"_\"),months:\"January_February_March_April_May_June_July_August_September_October_November_December\".split(\"_\"),ordinal:function(t){var e=[\"th\",\"st\",\"nd\",\"rd\"],n=t%100;return\"[\"+t+(e[(n-20)%10]||e[n]||e[0])+\"]\"}},m=function(t,e,n){var r=String(t);return!r||r.length>=e?t:\"\"+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?\"+\":\"-\")+m(r,2,\"0\")+\":\"+m(i,2,\"0\")},m:function t(e,n){if(e.date()1)return t(u[0])}else{var a=e.name;D[a]=e,i=a}return!r&&i&&(g=i),i||!r&&g},w=function(t,e){if(p(t))return t.clone();var n=\"object\"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},O=v;O.l=S,O.i=p,O.w=function(t,e){return w(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function M(t){this.$L=S(t.locale,null,!0),this.parse(t)}var m=M.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(O.u(e))return new Date;if(e instanceof Date)return new Date(e);if(\"string\"==typeof e&&!/Z$/i.test(e)){var r=e.match($);if(r){var i=r[2]-1||0,s=(r[7]||\"0\").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.$x=t.x||{},this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return O},m.isValid=function(){return!(this.$d.toString()===l)},m.isSame=function(t,e){var n=w(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return w(t) -1;\n}\n// adapted from https://stackoverflow.com/a/29824550/2601552\nfunction decodeHtmlCharacters(str) {\n return str.replace(htmlEntitiesRegex, function (match, dec) {\n return String.fromCharCode(dec);\n });\n}\nfunction sanitizeUrl(url) {\n var sanitizedUrl = decodeHtmlCharacters(url || \"\")\n .replace(htmlCtrlEntityRegex, \"\")\n .replace(ctrlCharactersRegex, \"\")\n .trim();\n if (!sanitizedUrl) {\n return \"about:blank\";\n }\n if (isRelativeUrlWithoutProtocol(sanitizedUrl)) {\n return sanitizedUrl;\n }\n var urlSchemeParseResults = sanitizedUrl.match(urlSchemeRegex);\n if (!urlSchemeParseResults) {\n return sanitizedUrl;\n }\n var urlScheme = urlSchemeParseResults[0];\n if (invalidProtocolRegex.test(urlScheme)) {\n return \"about:blank\";\n }\n return sanitizedUrl;\n}\nexports.sanitizeUrl = sanitizeUrl;\n", "const {\n entries,\n setPrototypeOf,\n isFrozen,\n getPrototypeOf,\n getOwnPropertyDescriptor,\n} = Object;\n\nlet { freeze, seal, create } = Object; // eslint-disable-line import/no-mutable-exports\nlet { apply, construct } = typeof Reflect !== 'undefined' && Reflect;\n\nif (!apply) {\n apply = function (fun, thisValue, args) {\n return fun.apply(thisValue, args);\n };\n}\n\nif (!freeze) {\n freeze = function (x) {\n return x;\n };\n}\n\nif (!seal) {\n seal = function (x) {\n return x;\n };\n}\n\nif (!construct) {\n construct = function (Func, args) {\n return new Func(...args);\n };\n}\n\nconst arrayForEach = unapply(Array.prototype.forEach);\nconst arrayIndexOf = unapply(Array.prototype.indexOf);\nconst arrayPop = unapply(Array.prototype.pop);\nconst arrayPush = unapply(Array.prototype.push);\nconst arraySlice = unapply(Array.prototype.slice);\n\nconst stringToLowerCase = unapply(String.prototype.toLowerCase);\nconst stringToString = unapply(String.prototype.toString);\nconst stringMatch = unapply(String.prototype.match);\nconst stringReplace = unapply(String.prototype.replace);\nconst stringIndexOf = unapply(String.prototype.indexOf);\nconst stringTrim = unapply(String.prototype.trim);\n\nconst regExpTest = unapply(RegExp.prototype.test);\n\nconst typeErrorCreate = unconstruct(TypeError);\n\nexport function unapply(func) {\n return (thisArg, ...args) => apply(func, thisArg, args);\n}\n\nexport function unconstruct(func) {\n return (...args) => construct(func, args);\n}\n\n/* Add properties to a lookup table */\nexport function addToSet(set, array, transformCaseFunc) {\n transformCaseFunc = transformCaseFunc ?? stringToLowerCase;\n if (setPrototypeOf) {\n // Make 'in' and truthy checks like Boolean(set.constructor)\n // independent of any properties defined on Object.prototype.\n // Prevent prototype setters from intercepting set as a this value.\n setPrototypeOf(set, null);\n }\n\n let l = array.length;\n while (l--) {\n let element = array[l];\n if (typeof element === 'string') {\n const lcElement = transformCaseFunc(element);\n if (lcElement !== element) {\n // Config presets (e.g. tags.js, attrs.js) are immutable.\n if (!isFrozen(array)) {\n array[l] = lcElement;\n }\n\n element = lcElement;\n }\n }\n\n set[element] = true;\n }\n\n return set;\n}\n\n/* Shallow clone an object */\nexport function clone(object) {\n const newObject = create(null);\n\n for (const [property, value] of entries(object)) {\n newObject[property] = value;\n }\n\n return newObject;\n}\n\n/* This method automatically checks if the prop is function\n * or getter and behaves accordingly. */\nfunction lookupGetter(object, prop) {\n while (object !== null) {\n const desc = getOwnPropertyDescriptor(object, prop);\n if (desc) {\n if (desc.get) {\n return unapply(desc.get);\n }\n\n if (typeof desc.value === 'function') {\n return unapply(desc.value);\n }\n }\n\n object = getPrototypeOf(object);\n }\n\n function fallbackValue(element) {\n console.warn('fallback value for', element);\n return null;\n }\n\n return fallbackValue;\n}\n\nexport {\n // Array\n arrayForEach,\n arrayIndexOf,\n arrayPop,\n arrayPush,\n arraySlice,\n // Object\n entries,\n freeze,\n getPrototypeOf,\n getOwnPropertyDescriptor,\n isFrozen,\n setPrototypeOf,\n seal,\n // RegExp\n regExpTest,\n // String\n stringIndexOf,\n stringMatch,\n stringReplace,\n stringToLowerCase,\n stringToString,\n stringTrim,\n // Errors\n typeErrorCreate,\n // Other\n lookupGetter,\n};\n", "import { freeze } from './utils.js';\n\nexport const html = freeze([\n 'a',\n 'abbr',\n 'acronym',\n 'address',\n 'area',\n 'article',\n 'aside',\n 'audio',\n 'b',\n 'bdi',\n 'bdo',\n 'big',\n 'blink',\n 'blockquote',\n 'body',\n 'br',\n 'button',\n 'canvas',\n 'caption',\n 'center',\n 'cite',\n 'code',\n 'col',\n 'colgroup',\n 'content',\n 'data',\n 'datalist',\n 'dd',\n 'decorator',\n 'del',\n 'details',\n 'dfn',\n 'dialog',\n 'dir',\n 'div',\n 'dl',\n 'dt',\n 'element',\n 'em',\n 'fieldset',\n 'figcaption',\n 'figure',\n 'font',\n 'footer',\n 'form',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'head',\n 'header',\n 'hgroup',\n 'hr',\n 'html',\n 'i',\n 'img',\n 'input',\n 'ins',\n 'kbd',\n 'label',\n 'legend',\n 'li',\n 'main',\n 'map',\n 'mark',\n 'marquee',\n 'menu',\n 'menuitem',\n 'meter',\n 'nav',\n 'nobr',\n 'ol',\n 'optgroup',\n 'option',\n 'output',\n 'p',\n 'picture',\n 'pre',\n 'progress',\n 'q',\n 'rp',\n 'rt',\n 'ruby',\n 's',\n 'samp',\n 'section',\n 'select',\n 'shadow',\n 'small',\n 'source',\n 'spacer',\n 'span',\n 'strike',\n 'strong',\n 'style',\n 'sub',\n 'summary',\n 'sup',\n 'table',\n 'tbody',\n 'td',\n 'template',\n 'textarea',\n 'tfoot',\n 'th',\n 'thead',\n 'time',\n 'tr',\n 'track',\n 'tt',\n 'u',\n 'ul',\n 'var',\n 'video',\n 'wbr',\n]);\n\n// SVG\nexport const svg = freeze([\n 'svg',\n 'a',\n 'altglyph',\n 'altglyphdef',\n 'altglyphitem',\n 'animatecolor',\n 'animatemotion',\n 'animatetransform',\n 'circle',\n 'clippath',\n 'defs',\n 'desc',\n 'ellipse',\n 'filter',\n 'font',\n 'g',\n 'glyph',\n 'glyphref',\n 'hkern',\n 'image',\n 'line',\n 'lineargradient',\n 'marker',\n 'mask',\n 'metadata',\n 'mpath',\n 'path',\n 'pattern',\n 'polygon',\n 'polyline',\n 'radialgradient',\n 'rect',\n 'stop',\n 'style',\n 'switch',\n 'symbol',\n 'text',\n 'textpath',\n 'title',\n 'tref',\n 'tspan',\n 'view',\n 'vkern',\n]);\n\nexport const svgFilters = freeze([\n 'feBlend',\n 'feColorMatrix',\n 'feComponentTransfer',\n 'feComposite',\n 'feConvolveMatrix',\n 'feDiffuseLighting',\n 'feDisplacementMap',\n 'feDistantLight',\n 'feDropShadow',\n 'feFlood',\n 'feFuncA',\n 'feFuncB',\n 'feFuncG',\n 'feFuncR',\n 'feGaussianBlur',\n 'feImage',\n 'feMerge',\n 'feMergeNode',\n 'feMorphology',\n 'feOffset',\n 'fePointLight',\n 'feSpecularLighting',\n 'feSpotLight',\n 'feTile',\n 'feTurbulence',\n]);\n\n// List of SVG elements that are disallowed by default.\n// We still need to know them so that we can do namespace\n// checks properly in case one wants to add them to\n// allow-list.\nexport const svgDisallowed = freeze([\n 'animate',\n 'color-profile',\n 'cursor',\n 'discard',\n 'font-face',\n 'font-face-format',\n 'font-face-name',\n 'font-face-src',\n 'font-face-uri',\n 'foreignobject',\n 'hatch',\n 'hatchpath',\n 'mesh',\n 'meshgradient',\n 'meshpatch',\n 'meshrow',\n 'missing-glyph',\n 'script',\n 'set',\n 'solidcolor',\n 'unknown',\n 'use',\n]);\n\nexport const mathMl = freeze([\n 'math',\n 'menclose',\n 'merror',\n 'mfenced',\n 'mfrac',\n 'mglyph',\n 'mi',\n 'mlabeledtr',\n 'mmultiscripts',\n 'mn',\n 'mo',\n 'mover',\n 'mpadded',\n 'mphantom',\n 'mroot',\n 'mrow',\n 'ms',\n 'mspace',\n 'msqrt',\n 'mstyle',\n 'msub',\n 'msup',\n 'msubsup',\n 'mtable',\n 'mtd',\n 'mtext',\n 'mtr',\n 'munder',\n 'munderover',\n 'mprescripts',\n]);\n\n// Similarly to SVG, we want to know all MathML elements,\n// even those that we disallow by default.\nexport const mathMlDisallowed = freeze([\n 'maction',\n 'maligngroup',\n 'malignmark',\n 'mlongdiv',\n 'mscarries',\n 'mscarry',\n 'msgroup',\n 'mstack',\n 'msline',\n 'msrow',\n 'semantics',\n 'annotation',\n 'annotation-xml',\n 'mprescripts',\n 'none',\n]);\n\nexport const text = freeze(['#text']);\n", "import { freeze } from './utils.js';\n\nexport const html = freeze([\n 'accept',\n 'action',\n 'align',\n 'alt',\n 'autocapitalize',\n 'autocomplete',\n 'autopictureinpicture',\n 'autoplay',\n 'background',\n 'bgcolor',\n 'border',\n 'capture',\n 'cellpadding',\n 'cellspacing',\n 'checked',\n 'cite',\n 'class',\n 'clear',\n 'color',\n 'cols',\n 'colspan',\n 'controls',\n 'controlslist',\n 'coords',\n 'crossorigin',\n 'datetime',\n 'decoding',\n 'default',\n 'dir',\n 'disabled',\n 'disablepictureinpicture',\n 'disableremoteplayback',\n 'download',\n 'draggable',\n 'enctype',\n 'enterkeyhint',\n 'face',\n 'for',\n 'headers',\n 'height',\n 'hidden',\n 'high',\n 'href',\n 'hreflang',\n 'id',\n 'inputmode',\n 'integrity',\n 'ismap',\n 'kind',\n 'label',\n 'lang',\n 'list',\n 'loading',\n 'loop',\n 'low',\n 'max',\n 'maxlength',\n 'media',\n 'method',\n 'min',\n 'minlength',\n 'multiple',\n 'muted',\n 'name',\n 'nonce',\n 'noshade',\n 'novalidate',\n 'nowrap',\n 'open',\n 'optimum',\n 'pattern',\n 'placeholder',\n 'playsinline',\n 'poster',\n 'preload',\n 'pubdate',\n 'radiogroup',\n 'readonly',\n 'rel',\n 'required',\n 'rev',\n 'reversed',\n 'role',\n 'rows',\n 'rowspan',\n 'spellcheck',\n 'scope',\n 'selected',\n 'shape',\n 'size',\n 'sizes',\n 'span',\n 'srclang',\n 'start',\n 'src',\n 'srcset',\n 'step',\n 'style',\n 'summary',\n 'tabindex',\n 'title',\n 'translate',\n 'type',\n 'usemap',\n 'valign',\n 'value',\n 'width',\n 'xmlns',\n 'slot',\n]);\n\nexport const svg = freeze([\n 'accent-height',\n 'accumulate',\n 'additive',\n 'alignment-baseline',\n 'ascent',\n 'attributename',\n 'attributetype',\n 'azimuth',\n 'basefrequency',\n 'baseline-shift',\n 'begin',\n 'bias',\n 'by',\n 'class',\n 'clip',\n 'clippathunits',\n 'clip-path',\n 'clip-rule',\n 'color',\n 'color-interpolation',\n 'color-interpolation-filters',\n 'color-profile',\n 'color-rendering',\n 'cx',\n 'cy',\n 'd',\n 'dx',\n 'dy',\n 'diffuseconstant',\n 'direction',\n 'display',\n 'divisor',\n 'dur',\n 'edgemode',\n 'elevation',\n 'end',\n 'fill',\n 'fill-opacity',\n 'fill-rule',\n 'filter',\n 'filterunits',\n 'flood-color',\n 'flood-opacity',\n 'font-family',\n 'font-size',\n 'font-size-adjust',\n 'font-stretch',\n 'font-style',\n 'font-variant',\n 'font-weight',\n 'fx',\n 'fy',\n 'g1',\n 'g2',\n 'glyph-name',\n 'glyphref',\n 'gradientunits',\n 'gradienttransform',\n 'height',\n 'href',\n 'id',\n 'image-rendering',\n 'in',\n 'in2',\n 'k',\n 'k1',\n 'k2',\n 'k3',\n 'k4',\n 'kerning',\n 'keypoints',\n 'keysplines',\n 'keytimes',\n 'lang',\n 'lengthadjust',\n 'letter-spacing',\n 'kernelmatrix',\n 'kernelunitlength',\n 'lighting-color',\n 'local',\n 'marker-end',\n 'marker-mid',\n 'marker-start',\n 'markerheight',\n 'markerunits',\n 'markerwidth',\n 'maskcontentunits',\n 'maskunits',\n 'max',\n 'mask',\n 'media',\n 'method',\n 'mode',\n 'min',\n 'name',\n 'numoctaves',\n 'offset',\n 'operator',\n 'opacity',\n 'order',\n 'orient',\n 'orientation',\n 'origin',\n 'overflow',\n 'paint-order',\n 'path',\n 'pathlength',\n 'patterncontentunits',\n 'patterntransform',\n 'patternunits',\n 'points',\n 'preservealpha',\n 'preserveaspectratio',\n 'primitiveunits',\n 'r',\n 'rx',\n 'ry',\n 'radius',\n 'refx',\n 'refy',\n 'repeatcount',\n 'repeatdur',\n 'restart',\n 'result',\n 'rotate',\n 'scale',\n 'seed',\n 'shape-rendering',\n 'specularconstant',\n 'specularexponent',\n 'spreadmethod',\n 'startoffset',\n 'stddeviation',\n 'stitchtiles',\n 'stop-color',\n 'stop-opacity',\n 'stroke-dasharray',\n 'stroke-dashoffset',\n 'stroke-linecap',\n 'stroke-linejoin',\n 'stroke-miterlimit',\n 'stroke-opacity',\n 'stroke',\n 'stroke-width',\n 'style',\n 'surfacescale',\n 'systemlanguage',\n 'tabindex',\n 'targetx',\n 'targety',\n 'transform',\n 'transform-origin',\n 'text-anchor',\n 'text-decoration',\n 'text-rendering',\n 'textlength',\n 'type',\n 'u1',\n 'u2',\n 'unicode',\n 'values',\n 'viewbox',\n 'visibility',\n 'version',\n 'vert-adv-y',\n 'vert-origin-x',\n 'vert-origin-y',\n 'width',\n 'word-spacing',\n 'wrap',\n 'writing-mode',\n 'xchannelselector',\n 'ychannelselector',\n 'x',\n 'x1',\n 'x2',\n 'xmlns',\n 'y',\n 'y1',\n 'y2',\n 'z',\n 'zoomandpan',\n]);\n\nexport const mathMl = freeze([\n 'accent',\n 'accentunder',\n 'align',\n 'bevelled',\n 'close',\n 'columnsalign',\n 'columnlines',\n 'columnspan',\n 'denomalign',\n 'depth',\n 'dir',\n 'display',\n 'displaystyle',\n 'encoding',\n 'fence',\n 'frame',\n 'height',\n 'href',\n 'id',\n 'largeop',\n 'length',\n 'linethickness',\n 'lspace',\n 'lquote',\n 'mathbackground',\n 'mathcolor',\n 'mathsize',\n 'mathvariant',\n 'maxsize',\n 'minsize',\n 'movablelimits',\n 'notation',\n 'numalign',\n 'open',\n 'rowalign',\n 'rowlines',\n 'rowspacing',\n 'rowspan',\n 'rspace',\n 'rquote',\n 'scriptlevel',\n 'scriptminsize',\n 'scriptsizemultiplier',\n 'selection',\n 'separator',\n 'separators',\n 'stretchy',\n 'subscriptshift',\n 'supscriptshift',\n 'symmetric',\n 'voffset',\n 'width',\n 'xmlns',\n]);\n\nexport const xml = freeze([\n 'xlink:href',\n 'xml:id',\n 'xlink:title',\n 'xml:space',\n 'xmlns:xlink',\n]);\n", "import { seal } from './utils.js';\n\n// eslint-disable-next-line unicorn/better-regex\nexport const MUSTACHE_EXPR = seal(/\\{\\{[\\w\\W]*|[\\w\\W]*\\}\\}/gm); // Specify template detection regex for SAFE_FOR_TEMPLATES mode\nexport const ERB_EXPR = seal(/<%[\\w\\W]*|[\\w\\W]*%>/gm);\nexport const TMPLIT_EXPR = seal(/\\${[\\w\\W]*}/gm);\nexport const DATA_ATTR = seal(/^data-[\\-\\w.\\u00B7-\\uFFFF]/); // eslint-disable-line no-useless-escape\nexport const ARIA_ATTR = seal(/^aria-[\\-\\w]+$/); // eslint-disable-line no-useless-escape\nexport const IS_ALLOWED_URI = seal(\n /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\\-]+(?:[^a-z+.\\-:]|$))/i // eslint-disable-line no-useless-escape\n);\nexport const IS_SCRIPT_OR_DATA = seal(/^(?:\\w+script|data):/i);\nexport const ATTR_WHITESPACE = seal(\n /[\\u0000-\\u0020\\u00A0\\u1680\\u180E\\u2000-\\u2029\\u205F\\u3000]/g // eslint-disable-line no-control-regex\n);\nexport const DOCTYPE_NAME = seal(/^html$/i);\n", "import * as TAGS from './tags.js';\nimport * as ATTRS from './attrs.js';\nimport * as EXPRESSIONS from './regexp.js';\nimport {\n addToSet,\n clone,\n entries,\n freeze,\n arrayForEach,\n arrayPop,\n arrayPush,\n stringMatch,\n stringReplace,\n stringToLowerCase,\n stringToString,\n stringIndexOf,\n stringTrim,\n regExpTest,\n typeErrorCreate,\n lookupGetter,\n} from './utils.js';\n\nconst getGlobal = () => (typeof window === 'undefined' ? null : window);\n\n/**\n * Creates a no-op policy for internal use only.\n * Don't export this function outside this module!\n * @param {?TrustedTypePolicyFactory} trustedTypes The policy factory.\n * @param {HTMLScriptElement} purifyHostElement The Script element used to load DOMPurify (to determine policy name suffix).\n * @return {?TrustedTypePolicy} The policy created (or null, if Trusted Types\n * are not supported or creating the policy failed).\n */\nconst _createTrustedTypesPolicy = function (trustedTypes, purifyHostElement) {\n if (\n typeof trustedTypes !== 'object' ||\n typeof trustedTypes.createPolicy !== 'function'\n ) {\n return null;\n }\n\n // Allow the callers to control the unique policy name\n // by adding a data-tt-policy-suffix to the script element with the DOMPurify.\n // Policy creation with duplicate names throws in Trusted Types.\n let suffix = null;\n const ATTR_NAME = 'data-tt-policy-suffix';\n if (purifyHostElement && purifyHostElement.hasAttribute(ATTR_NAME)) {\n suffix = purifyHostElement.getAttribute(ATTR_NAME);\n }\n\n const policyName = 'dompurify' + (suffix ? '#' + suffix : '');\n\n try {\n return trustedTypes.createPolicy(policyName, {\n createHTML(html) {\n return html;\n },\n createScriptURL(scriptUrl) {\n return scriptUrl;\n },\n });\n } catch (_) {\n // Policy creation failed (most likely another DOMPurify script has\n // already run). Skip creating the policy, as this will only cause errors\n // if TT are enforced.\n console.warn(\n 'TrustedTypes policy ' + policyName + ' could not be created.'\n );\n return null;\n }\n};\n\nfunction createDOMPurify(window = getGlobal()) {\n const DOMPurify = (root) => createDOMPurify(root);\n\n /**\n * Version label, exposed for easier checks\n * if DOMPurify is up to date or not\n */\n DOMPurify.version = VERSION;\n\n /**\n * Array of elements that DOMPurify removed during sanitation.\n * Empty if nothing was removed.\n */\n DOMPurify.removed = [];\n\n if (!window || !window.document || window.document.nodeType !== 9) {\n // Not running in a browser, provide a factory function\n // so that you can pass your own Window\n DOMPurify.isSupported = false;\n\n return DOMPurify;\n }\n\n const originalDocument = window.document;\n const currentScript = originalDocument.currentScript;\n\n let { document } = window;\n const {\n DocumentFragment,\n HTMLTemplateElement,\n Node,\n Element,\n NodeFilter,\n NamedNodeMap = window.NamedNodeMap || window.MozNamedAttrMap,\n HTMLFormElement,\n DOMParser,\n trustedTypes,\n } = window;\n\n const ElementPrototype = Element.prototype;\n\n const cloneNode = lookupGetter(ElementPrototype, 'cloneNode');\n const getNextSibling = lookupGetter(ElementPrototype, 'nextSibling');\n const getChildNodes = lookupGetter(ElementPrototype, 'childNodes');\n const getParentNode = lookupGetter(ElementPrototype, 'parentNode');\n\n // As per issue #47, the web-components registry is inherited by a\n // new document created via createHTMLDocument. As per the spec\n // (http://w3c.github.io/webcomponents/spec/custom/#creating-and-passing-registries)\n // a new empty registry is used when creating a template contents owner\n // document, so we use that as our parent document to ensure nothing\n // is inherited.\n if (typeof HTMLTemplateElement === 'function') {\n const template = document.createElement('template');\n if (template.content && template.content.ownerDocument) {\n document = template.content.ownerDocument;\n }\n }\n\n let trustedTypesPolicy;\n let emptyHTML = '';\n\n const {\n implementation,\n createNodeIterator,\n createDocumentFragment,\n getElementsByTagName,\n } = document;\n const { importNode } = originalDocument;\n\n let hooks = {};\n\n /**\n * Expose whether this browser supports running the full DOMPurify.\n */\n DOMPurify.isSupported =\n typeof entries === 'function' &&\n typeof getParentNode === 'function' &&\n implementation &&\n implementation.createHTMLDocument !== undefined;\n\n const {\n MUSTACHE_EXPR,\n ERB_EXPR,\n TMPLIT_EXPR,\n DATA_ATTR,\n ARIA_ATTR,\n IS_SCRIPT_OR_DATA,\n ATTR_WHITESPACE,\n } = EXPRESSIONS;\n\n let { IS_ALLOWED_URI } = EXPRESSIONS;\n\n /**\n * We consider the elements and attributes below to be safe. Ideally\n * don't add any new ones but feel free to remove unwanted ones.\n */\n\n /* allowed element names */\n let ALLOWED_TAGS = null;\n const DEFAULT_ALLOWED_TAGS = addToSet({}, [\n ...TAGS.html,\n ...TAGS.svg,\n ...TAGS.svgFilters,\n ...TAGS.mathMl,\n ...TAGS.text,\n ]);\n\n /* Allowed attribute names */\n let ALLOWED_ATTR = null;\n const DEFAULT_ALLOWED_ATTR = addToSet({}, [\n ...ATTRS.html,\n ...ATTRS.svg,\n ...ATTRS.mathMl,\n ...ATTRS.xml,\n ]);\n\n /*\n * Configure how DOMPUrify should handle custom elements and their attributes as well as customized built-in elements.\n * @property {RegExp|Function|null} tagNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any custom elements)\n * @property {RegExp|Function|null} attributeNameCheck one of [null, regexPattern, predicate]. Default: `null` (disallow any attributes not on the allow list)\n * @property {boolean} allowCustomizedBuiltInElements allow custom elements derived from built-ins if they pass CUSTOM_ELEMENT_HANDLING.tagNameCheck. Default: `false`.\n */\n let CUSTOM_ELEMENT_HANDLING = Object.seal(\n Object.create(null, {\n tagNameCheck: {\n writable: true,\n configurable: false,\n enumerable: true,\n value: null,\n },\n attributeNameCheck: {\n writable: true,\n configurable: false,\n enumerable: true,\n value: null,\n },\n allowCustomizedBuiltInElements: {\n writable: true,\n configurable: false,\n enumerable: true,\n value: false,\n },\n })\n );\n\n /* Explicitly forbidden tags (overrides ALLOWED_TAGS/ADD_TAGS) */\n let FORBID_TAGS = null;\n\n /* Explicitly forbidden attributes (overrides ALLOWED_ATTR/ADD_ATTR) */\n let FORBID_ATTR = null;\n\n /* Decide if ARIA attributes are okay */\n let ALLOW_ARIA_ATTR = true;\n\n /* Decide if custom data attributes are okay */\n let ALLOW_DATA_ATTR = true;\n\n /* Decide if unknown protocols are okay */\n let ALLOW_UNKNOWN_PROTOCOLS = false;\n\n /* Decide if self-closing tags in attributes are allowed.\n * Usually removed due to a mXSS issue in jQuery 3.0 */\n let ALLOW_SELF_CLOSE_IN_ATTR = true;\n\n /* Output should be safe for common template engines.\n * This means, DOMPurify removes data attributes, mustaches and ERB\n */\n let SAFE_FOR_TEMPLATES = false;\n\n /* Decide if document with ... should be returned */\n let WHOLE_DOCUMENT = false;\n\n /* Track whether config is already set on this instance of DOMPurify. */\n let SET_CONFIG = false;\n\n /* Decide if all elements (e.g. style, script) must be children of\n * document.body. By default, browsers might move them to document.head */\n let FORCE_BODY = false;\n\n /* Decide if a DOM `HTMLBodyElement` should be returned, instead of a html\n * string (or a TrustedHTML object if Trusted Types are supported).\n * If `WHOLE_DOCUMENT` is enabled a `HTMLHtmlElement` will be returned instead\n */\n let RETURN_DOM = false;\n\n /* Decide if a DOM `DocumentFragment` should be returned, instead of a html\n * string (or a TrustedHTML object if Trusted Types are supported) */\n let RETURN_DOM_FRAGMENT = false;\n\n /* Try to return a Trusted Type object instead of a string, return a string in\n * case Trusted Types are not supported */\n let RETURN_TRUSTED_TYPE = false;\n\n /* Output should be free from DOM clobbering attacks?\n * This sanitizes markups named with colliding, clobberable built-in DOM APIs.\n */\n let SANITIZE_DOM = true;\n\n /* Achieve full DOM Clobbering protection by isolating the namespace of named\n * properties and JS variables, mitigating attacks that abuse the HTML/DOM spec rules.\n *\n * HTML/DOM spec rules that enable DOM Clobbering:\n * - Named Access on Window (§7.3.3)\n * - DOM Tree Accessors (§3.1.5)\n * - Form Element Parent-Child Relations (§4.10.3)\n * - Iframe srcdoc / Nested WindowProxies (§4.8.5)\n * - HTMLCollection (§4.2.10.2)\n *\n * Namespace isolation is implemented by prefixing `id` and `name` attributes\n * with a constant string, i.e., `user-content-`\n */\n let SANITIZE_NAMED_PROPS = false;\n const SANITIZE_NAMED_PROPS_PREFIX = 'user-content-';\n\n /* Keep element content when removing element? */\n let KEEP_CONTENT = true;\n\n /* If a `Node` is passed to sanitize(), then performs sanitization in-place instead\n * of importing it into a new Document and returning a sanitized copy */\n let IN_PLACE = false;\n\n /* Allow usage of profiles like html, svg and mathMl */\n let USE_PROFILES = {};\n\n /* Tags to ignore content of when KEEP_CONTENT is true */\n let FORBID_CONTENTS = null;\n const DEFAULT_FORBID_CONTENTS = addToSet({}, [\n 'annotation-xml',\n 'audio',\n 'colgroup',\n 'desc',\n 'foreignobject',\n 'head',\n 'iframe',\n 'math',\n 'mi',\n 'mn',\n 'mo',\n 'ms',\n 'mtext',\n 'noembed',\n 'noframes',\n 'noscript',\n 'plaintext',\n 'script',\n 'style',\n 'svg',\n 'template',\n 'thead',\n 'title',\n 'video',\n 'xmp',\n ]);\n\n /* Tags that are safe for data: URIs */\n let DATA_URI_TAGS = null;\n const DEFAULT_DATA_URI_TAGS = addToSet({}, [\n 'audio',\n 'video',\n 'img',\n 'source',\n 'image',\n 'track',\n ]);\n\n /* Attributes safe for values like \"javascript:\" */\n let URI_SAFE_ATTRIBUTES = null;\n const DEFAULT_URI_SAFE_ATTRIBUTES = addToSet({}, [\n 'alt',\n 'class',\n 'for',\n 'id',\n 'label',\n 'name',\n 'pattern',\n 'placeholder',\n 'role',\n 'summary',\n 'title',\n 'value',\n 'style',\n 'xmlns',\n ]);\n\n const MATHML_NAMESPACE = 'http://www.w3.org/1998/Math/MathML';\n const SVG_NAMESPACE = 'http://www.w3.org/2000/svg';\n const HTML_NAMESPACE = 'http://www.w3.org/1999/xhtml';\n /* Document namespace */\n let NAMESPACE = HTML_NAMESPACE;\n let IS_EMPTY_INPUT = false;\n\n /* Allowed XHTML+XML namespaces */\n let ALLOWED_NAMESPACES = null;\n const DEFAULT_ALLOWED_NAMESPACES = addToSet(\n {},\n [MATHML_NAMESPACE, SVG_NAMESPACE, HTML_NAMESPACE],\n stringToString\n );\n\n /* Parsing of strict XHTML documents */\n let PARSER_MEDIA_TYPE;\n const SUPPORTED_PARSER_MEDIA_TYPES = ['application/xhtml+xml', 'text/html'];\n const DEFAULT_PARSER_MEDIA_TYPE = 'text/html';\n let transformCaseFunc;\n\n /* Keep a reference to config to pass to hooks */\n let CONFIG = null;\n\n /* Ideally, do not touch anything below this line */\n /* ______________________________________________ */\n\n const formElement = document.createElement('form');\n\n const isRegexOrFunction = function (testValue) {\n return testValue instanceof RegExp || testValue instanceof Function;\n };\n\n /**\n * _parseConfig\n *\n * @param {Object} cfg optional config literal\n */\n // eslint-disable-next-line complexity\n const _parseConfig = function (cfg) {\n if (CONFIG && CONFIG === cfg) {\n return;\n }\n\n /* Shield configuration object from tampering */\n if (!cfg || typeof cfg !== 'object') {\n cfg = {};\n }\n\n /* Shield configuration object from prototype pollution */\n cfg = clone(cfg);\n\n PARSER_MEDIA_TYPE =\n // eslint-disable-next-line unicorn/prefer-includes\n SUPPORTED_PARSER_MEDIA_TYPES.indexOf(cfg.PARSER_MEDIA_TYPE) === -1\n ? (PARSER_MEDIA_TYPE = DEFAULT_PARSER_MEDIA_TYPE)\n : (PARSER_MEDIA_TYPE = cfg.PARSER_MEDIA_TYPE);\n\n // HTML tags and attributes are not case-sensitive, converting to lowercase. Keeping XHTML as is.\n transformCaseFunc =\n PARSER_MEDIA_TYPE === 'application/xhtml+xml'\n ? stringToString\n : stringToLowerCase;\n\n /* Set configuration parameters */\n ALLOWED_TAGS =\n 'ALLOWED_TAGS' in cfg\n ? addToSet({}, cfg.ALLOWED_TAGS, transformCaseFunc)\n : DEFAULT_ALLOWED_TAGS;\n ALLOWED_ATTR =\n 'ALLOWED_ATTR' in cfg\n ? addToSet({}, cfg.ALLOWED_ATTR, transformCaseFunc)\n : DEFAULT_ALLOWED_ATTR;\n ALLOWED_NAMESPACES =\n 'ALLOWED_NAMESPACES' in cfg\n ? addToSet({}, cfg.ALLOWED_NAMESPACES, stringToString)\n : DEFAULT_ALLOWED_NAMESPACES;\n URI_SAFE_ATTRIBUTES =\n 'ADD_URI_SAFE_ATTR' in cfg\n ? addToSet(\n clone(DEFAULT_URI_SAFE_ATTRIBUTES), // eslint-disable-line indent\n cfg.ADD_URI_SAFE_ATTR, // eslint-disable-line indent\n transformCaseFunc // eslint-disable-line indent\n ) // eslint-disable-line indent\n : DEFAULT_URI_SAFE_ATTRIBUTES;\n DATA_URI_TAGS =\n 'ADD_DATA_URI_TAGS' in cfg\n ? addToSet(\n clone(DEFAULT_DATA_URI_TAGS), // eslint-disable-line indent\n cfg.ADD_DATA_URI_TAGS, // eslint-disable-line indent\n transformCaseFunc // eslint-disable-line indent\n ) // eslint-disable-line indent\n : DEFAULT_DATA_URI_TAGS;\n FORBID_CONTENTS =\n 'FORBID_CONTENTS' in cfg\n ? addToSet({}, cfg.FORBID_CONTENTS, transformCaseFunc)\n : DEFAULT_FORBID_CONTENTS;\n FORBID_TAGS =\n 'FORBID_TAGS' in cfg\n ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc)\n : {};\n FORBID_ATTR =\n 'FORBID_ATTR' in cfg\n ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc)\n : {};\n USE_PROFILES = 'USE_PROFILES' in cfg ? cfg.USE_PROFILES : false;\n ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false; // Default true\n ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false; // Default true\n ALLOW_UNKNOWN_PROTOCOLS = cfg.ALLOW_UNKNOWN_PROTOCOLS || false; // Default false\n ALLOW_SELF_CLOSE_IN_ATTR = cfg.ALLOW_SELF_CLOSE_IN_ATTR !== false; // Default true\n SAFE_FOR_TEMPLATES = cfg.SAFE_FOR_TEMPLATES || false; // Default false\n WHOLE_DOCUMENT = cfg.WHOLE_DOCUMENT || false; // Default false\n RETURN_DOM = cfg.RETURN_DOM || false; // Default false\n RETURN_DOM_FRAGMENT = cfg.RETURN_DOM_FRAGMENT || false; // Default false\n RETURN_TRUSTED_TYPE = cfg.RETURN_TRUSTED_TYPE || false; // Default false\n FORCE_BODY = cfg.FORCE_BODY || false; // Default false\n SANITIZE_DOM = cfg.SANITIZE_DOM !== false; // Default true\n SANITIZE_NAMED_PROPS = cfg.SANITIZE_NAMED_PROPS || false; // Default false\n KEEP_CONTENT = cfg.KEEP_CONTENT !== false; // Default true\n IN_PLACE = cfg.IN_PLACE || false; // Default false\n IS_ALLOWED_URI = cfg.ALLOWED_URI_REGEXP || EXPRESSIONS.IS_ALLOWED_URI;\n NAMESPACE = cfg.NAMESPACE || HTML_NAMESPACE;\n CUSTOM_ELEMENT_HANDLING = cfg.CUSTOM_ELEMENT_HANDLING || {};\n if (\n cfg.CUSTOM_ELEMENT_HANDLING &&\n isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck)\n ) {\n CUSTOM_ELEMENT_HANDLING.tagNameCheck =\n cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck;\n }\n\n if (\n cfg.CUSTOM_ELEMENT_HANDLING &&\n isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)\n ) {\n CUSTOM_ELEMENT_HANDLING.attributeNameCheck =\n cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck;\n }\n\n if (\n cfg.CUSTOM_ELEMENT_HANDLING &&\n typeof cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements ===\n 'boolean'\n ) {\n CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements =\n cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements;\n }\n\n if (SAFE_FOR_TEMPLATES) {\n ALLOW_DATA_ATTR = false;\n }\n\n if (RETURN_DOM_FRAGMENT) {\n RETURN_DOM = true;\n }\n\n /* Parse profile info */\n if (USE_PROFILES) {\n ALLOWED_TAGS = addToSet({}, [...TAGS.text]);\n ALLOWED_ATTR = [];\n if (USE_PROFILES.html === true) {\n addToSet(ALLOWED_TAGS, TAGS.html);\n addToSet(ALLOWED_ATTR, ATTRS.html);\n }\n\n if (USE_PROFILES.svg === true) {\n addToSet(ALLOWED_TAGS, TAGS.svg);\n addToSet(ALLOWED_ATTR, ATTRS.svg);\n addToSet(ALLOWED_ATTR, ATTRS.xml);\n }\n\n if (USE_PROFILES.svgFilters === true) {\n addToSet(ALLOWED_TAGS, TAGS.svgFilters);\n addToSet(ALLOWED_ATTR, ATTRS.svg);\n addToSet(ALLOWED_ATTR, ATTRS.xml);\n }\n\n if (USE_PROFILES.mathMl === true) {\n addToSet(ALLOWED_TAGS, TAGS.mathMl);\n addToSet(ALLOWED_ATTR, ATTRS.mathMl);\n addToSet(ALLOWED_ATTR, ATTRS.xml);\n }\n }\n\n /* Merge configuration parameters */\n if (cfg.ADD_TAGS) {\n if (ALLOWED_TAGS === DEFAULT_ALLOWED_TAGS) {\n ALLOWED_TAGS = clone(ALLOWED_TAGS);\n }\n\n addToSet(ALLOWED_TAGS, cfg.ADD_TAGS, transformCaseFunc);\n }\n\n if (cfg.ADD_ATTR) {\n if (ALLOWED_ATTR === DEFAULT_ALLOWED_ATTR) {\n ALLOWED_ATTR = clone(ALLOWED_ATTR);\n }\n\n addToSet(ALLOWED_ATTR, cfg.ADD_ATTR, transformCaseFunc);\n }\n\n if (cfg.ADD_URI_SAFE_ATTR) {\n addToSet(URI_SAFE_ATTRIBUTES, cfg.ADD_URI_SAFE_ATTR, transformCaseFunc);\n }\n\n if (cfg.FORBID_CONTENTS) {\n if (FORBID_CONTENTS === DEFAULT_FORBID_CONTENTS) {\n FORBID_CONTENTS = clone(FORBID_CONTENTS);\n }\n\n addToSet(FORBID_CONTENTS, cfg.FORBID_CONTENTS, transformCaseFunc);\n }\n\n /* Add #text in case KEEP_CONTENT is set to true */\n if (KEEP_CONTENT) {\n ALLOWED_TAGS['#text'] = true;\n }\n\n /* Add html, head and body to ALLOWED_TAGS in case WHOLE_DOCUMENT is true */\n if (WHOLE_DOCUMENT) {\n addToSet(ALLOWED_TAGS, ['html', 'head', 'body']);\n }\n\n /* Add tbody to ALLOWED_TAGS in case tables are permitted, see #286, #365 */\n if (ALLOWED_TAGS.table) {\n addToSet(ALLOWED_TAGS, ['tbody']);\n delete FORBID_TAGS.tbody;\n }\n\n if (cfg.TRUSTED_TYPES_POLICY) {\n if (typeof cfg.TRUSTED_TYPES_POLICY.createHTML !== 'function') {\n throw typeErrorCreate(\n 'TRUSTED_TYPES_POLICY configuration option must provide a \"createHTML\" hook.'\n );\n }\n\n if (typeof cfg.TRUSTED_TYPES_POLICY.createScriptURL !== 'function') {\n throw typeErrorCreate(\n 'TRUSTED_TYPES_POLICY configuration option must provide a \"createScriptURL\" hook.'\n );\n }\n\n // Overwrite existing TrustedTypes policy.\n trustedTypesPolicy = cfg.TRUSTED_TYPES_POLICY;\n\n // Sign local variables required by `sanitize`.\n emptyHTML = trustedTypesPolicy.createHTML('');\n } else {\n // Uninitialized policy, attempt to initialize the internal dompurify policy.\n if (trustedTypesPolicy === undefined) {\n trustedTypesPolicy = _createTrustedTypesPolicy(\n trustedTypes,\n currentScript\n );\n }\n\n // If creating the internal policy succeeded sign internal variables.\n if (trustedTypesPolicy !== null && typeof emptyHTML === 'string') {\n emptyHTML = trustedTypesPolicy.createHTML('');\n }\n }\n\n // Prevent further manipulation of configuration.\n // Not available in IE8, Safari 5, etc.\n if (freeze) {\n freeze(cfg);\n }\n\n CONFIG = cfg;\n };\n\n const MATHML_TEXT_INTEGRATION_POINTS = addToSet({}, [\n 'mi',\n 'mo',\n 'mn',\n 'ms',\n 'mtext',\n ]);\n\n const HTML_INTEGRATION_POINTS = addToSet({}, [\n 'foreignobject',\n 'desc',\n 'title',\n 'annotation-xml',\n ]);\n\n // Certain elements are allowed in both SVG and HTML\n // namespace. We need to specify them explicitly\n // so that they don't get erroneously deleted from\n // HTML namespace.\n const COMMON_SVG_AND_HTML_ELEMENTS = addToSet({}, [\n 'title',\n 'style',\n 'font',\n 'a',\n 'script',\n ]);\n\n /* Keep track of all possible SVG and MathML tags\n * so that we can perform the namespace checks\n * correctly. */\n const ALL_SVG_TAGS = addToSet({}, TAGS.svg);\n addToSet(ALL_SVG_TAGS, TAGS.svgFilters);\n addToSet(ALL_SVG_TAGS, TAGS.svgDisallowed);\n\n const ALL_MATHML_TAGS = addToSet({}, TAGS.mathMl);\n addToSet(ALL_MATHML_TAGS, TAGS.mathMlDisallowed);\n\n /**\n *\n *\n * @param {Element} element a DOM element whose namespace is being checked\n * @returns {boolean} Return false if the element has a\n * namespace that a spec-compliant parser would never\n * return. Return true otherwise.\n */\n const _checkValidNamespace = function (element) {\n let parent = getParentNode(element);\n\n // In JSDOM, if we're inside shadow DOM, then parentNode\n // can be null. We just simulate parent in this case.\n if (!parent || !parent.tagName) {\n parent = {\n namespaceURI: NAMESPACE,\n tagName: 'template',\n };\n }\n\n const tagName = stringToLowerCase(element.tagName);\n const parentTagName = stringToLowerCase(parent.tagName);\n\n if (!ALLOWED_NAMESPACES[element.namespaceURI]) {\n return false;\n }\n\n if (element.namespaceURI === SVG_NAMESPACE) {\n // The only way to switch from HTML namespace to SVG\n // is via . If it happens via any other tag, then\n // it should be killed.\n if (parent.namespaceURI === HTML_NAMESPACE) {\n return tagName === 'svg';\n }\n\n // The only way to switch from MathML to SVG is via`\n // svg if parent is either or MathML\n // text integration points.\n if (parent.namespaceURI === MATHML_NAMESPACE) {\n return (\n tagName === 'svg' &&\n (parentTagName === 'annotation-xml' ||\n MATHML_TEXT_INTEGRATION_POINTS[parentTagName])\n );\n }\n\n // We only allow elements that are defined in SVG\n // spec. All others are disallowed in SVG namespace.\n return Boolean(ALL_SVG_TAGS[tagName]);\n }\n\n if (element.namespaceURI === MATHML_NAMESPACE) {\n // The only way to switch from HTML namespace to MathML\n // is via . If it happens via any other tag, then\n // it should be killed.\n if (parent.namespaceURI === HTML_NAMESPACE) {\n return tagName === 'math';\n }\n\n // The only way to switch from SVG to MathML is via\n // and HTML integration points\n if (parent.namespaceURI === SVG_NAMESPACE) {\n return tagName === 'math' && HTML_INTEGRATION_POINTS[parentTagName];\n }\n\n // We only allow elements that are defined in MathML\n // spec. All others are disallowed in MathML namespace.\n return Boolean(ALL_MATHML_TAGS[tagName]);\n }\n\n if (element.namespaceURI === HTML_NAMESPACE) {\n // The only way to switch from SVG to HTML is via\n // HTML integration points, and from MathML to HTML\n // is via MathML text integration points\n if (\n parent.namespaceURI === SVG_NAMESPACE &&\n !HTML_INTEGRATION_POINTS[parentTagName]\n ) {\n return false;\n }\n\n if (\n parent.namespaceURI === MATHML_NAMESPACE &&\n !MATHML_TEXT_INTEGRATION_POINTS[parentTagName]\n ) {\n return false;\n }\n\n // We disallow tags that are specific for MathML\n // or SVG and should never appear in HTML namespace\n return (\n !ALL_MATHML_TAGS[tagName] &&\n (COMMON_SVG_AND_HTML_ELEMENTS[tagName] || !ALL_SVG_TAGS[tagName])\n );\n }\n\n // For XHTML and XML documents that support custom namespaces\n if (\n PARSER_MEDIA_TYPE === 'application/xhtml+xml' &&\n ALLOWED_NAMESPACES[element.namespaceURI]\n ) {\n return true;\n }\n\n // The code should never reach this place (this means\n // that the element somehow got namespace that is not\n // HTML, SVG, MathML or allowed via ALLOWED_NAMESPACES).\n // Return false just in case.\n return false;\n };\n\n /**\n * _forceRemove\n *\n * @param {Node} node a DOM node\n */\n const _forceRemove = function (node) {\n arrayPush(DOMPurify.removed, { element: node });\n try {\n // eslint-disable-next-line unicorn/prefer-dom-node-remove\n node.parentNode.removeChild(node);\n } catch (_) {\n node.remove();\n }\n };\n\n /**\n * _removeAttribute\n *\n * @param {String} name an Attribute name\n * @param {Node} node a DOM node\n */\n const _removeAttribute = function (name, node) {\n try {\n arrayPush(DOMPurify.removed, {\n attribute: node.getAttributeNode(name),\n from: node,\n });\n } catch (_) {\n arrayPush(DOMPurify.removed, {\n attribute: null,\n from: node,\n });\n }\n\n node.removeAttribute(name);\n\n // We void attribute values for unremovable \"is\"\" attributes\n if (name === 'is' && !ALLOWED_ATTR[name]) {\n if (RETURN_DOM || RETURN_DOM_FRAGMENT) {\n try {\n _forceRemove(node);\n } catch (_) {}\n } else {\n try {\n node.setAttribute(name, '');\n } catch (_) {}\n }\n }\n };\n\n /**\n * _initDocument\n *\n * @param {String} dirty a string of dirty markup\n * @return {Document} a DOM, filled with the dirty markup\n */\n const _initDocument = function (dirty) {\n /* Create a HTML document */\n let doc;\n let leadingWhitespace;\n\n if (FORCE_BODY) {\n dirty = '' + dirty;\n } else {\n /* If FORCE_BODY isn't used, leading whitespace needs to be preserved manually */\n const matches = stringMatch(dirty, /^[\\r\\n\\t ]+/);\n leadingWhitespace = matches && matches[0];\n }\n\n if (\n PARSER_MEDIA_TYPE === 'application/xhtml+xml' &&\n NAMESPACE === HTML_NAMESPACE\n ) {\n // Root of XHTML doc must contain xmlns declaration (see https://www.w3.org/TR/xhtml1/normative.html#strict)\n dirty =\n '' +\n dirty +\n '';\n }\n\n const dirtyPayload = trustedTypesPolicy\n ? trustedTypesPolicy.createHTML(dirty)\n : dirty;\n /*\n * Use the DOMParser API by default, fallback later if needs be\n * DOMParser not work for svg when has multiple root element.\n */\n if (NAMESPACE === HTML_NAMESPACE) {\n try {\n doc = new DOMParser().parseFromString(dirtyPayload, PARSER_MEDIA_TYPE);\n } catch (_) {}\n }\n\n /* Use createHTMLDocument in case DOMParser is not available */\n if (!doc || !doc.documentElement) {\n doc = implementation.createDocument(NAMESPACE, 'template', null);\n try {\n doc.documentElement.innerHTML = IS_EMPTY_INPUT\n ? emptyHTML\n : dirtyPayload;\n } catch (_) {\n // Syntax error if dirtyPayload is invalid xml\n }\n }\n\n const body = doc.body || doc.documentElement;\n\n if (dirty && leadingWhitespace) {\n body.insertBefore(\n document.createTextNode(leadingWhitespace),\n body.childNodes[0] || null\n );\n }\n\n /* Work on whole document or just its body */\n if (NAMESPACE === HTML_NAMESPACE) {\n return getElementsByTagName.call(\n doc,\n WHOLE_DOCUMENT ? 'html' : 'body'\n )[0];\n }\n\n return WHOLE_DOCUMENT ? doc.documentElement : body;\n };\n\n /**\n * _createIterator\n *\n * @param {Document} root document/fragment to create iterator for\n * @return {Iterator} iterator instance\n */\n const _createIterator = function (root) {\n return createNodeIterator.call(\n root.ownerDocument || root,\n root,\n // eslint-disable-next-line no-bitwise\n NodeFilter.SHOW_ELEMENT | NodeFilter.SHOW_COMMENT | NodeFilter.SHOW_TEXT,\n null,\n false\n );\n };\n\n /**\n * _isClobbered\n *\n * @param {Node} elm element to check for clobbering attacks\n * @return {Boolean} true if clobbered, false if safe\n */\n const _isClobbered = function (elm) {\n return (\n elm instanceof HTMLFormElement &&\n (typeof elm.nodeName !== 'string' ||\n typeof elm.textContent !== 'string' ||\n typeof elm.removeChild !== 'function' ||\n !(elm.attributes instanceof NamedNodeMap) ||\n typeof elm.removeAttribute !== 'function' ||\n typeof elm.setAttribute !== 'function' ||\n typeof elm.namespaceURI !== 'string' ||\n typeof elm.insertBefore !== 'function' ||\n typeof elm.hasChildNodes !== 'function')\n );\n };\n\n /**\n * _isNode\n *\n * @param {Node} obj object to check whether it's a DOM node\n * @return {Boolean} true is object is a DOM node\n */\n const _isNode = function (object) {\n return typeof Node === 'object'\n ? object instanceof Node\n : object &&\n typeof object === 'object' &&\n typeof object.nodeType === 'number' &&\n typeof object.nodeName === 'string';\n };\n\n /**\n * _executeHook\n * Execute user configurable hooks\n *\n * @param {String} entryPoint Name of the hook's entry point\n * @param {Node} currentNode node to work on with the hook\n * @param {Object} data additional hook parameters\n */\n const _executeHook = function (entryPoint, currentNode, data) {\n if (!hooks[entryPoint]) {\n return;\n }\n\n arrayForEach(hooks[entryPoint], (hook) => {\n hook.call(DOMPurify, currentNode, data, CONFIG);\n });\n };\n\n /**\n * _sanitizeElements\n *\n * @protect nodeName\n * @protect textContent\n * @protect removeChild\n *\n * @param {Node} currentNode to check for permission to exist\n * @return {Boolean} true if node was killed, false if left alive\n */\n const _sanitizeElements = function (currentNode) {\n let content;\n\n /* Execute a hook if present */\n _executeHook('beforeSanitizeElements', currentNode, null);\n\n /* Check if element is clobbered or can clobber */\n if (_isClobbered(currentNode)) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Now let's check the element's type and name */\n const tagName = transformCaseFunc(currentNode.nodeName);\n\n /* Execute a hook if present */\n _executeHook('uponSanitizeElement', currentNode, {\n tagName,\n allowedTags: ALLOWED_TAGS,\n });\n\n /* Detect mXSS attempts abusing namespace confusion */\n if (\n currentNode.hasChildNodes() &&\n !_isNode(currentNode.firstElementChild) &&\n (!_isNode(currentNode.content) ||\n !_isNode(currentNode.content.firstElementChild)) &&\n regExpTest(/<[/\\w]/g, currentNode.innerHTML) &&\n regExpTest(/<[/\\w]/g, currentNode.textContent)\n ) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Remove element if anything forbids its presence */\n if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {\n /* Check if we have a custom element to handle */\n if (!FORBID_TAGS[tagName] && _basicCustomElementTest(tagName)) {\n if (\n CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, tagName)\n )\n return false;\n if (\n CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.tagNameCheck(tagName)\n )\n return false;\n }\n\n /* Keep content except for bad-listed elements */\n if (KEEP_CONTENT && !FORBID_CONTENTS[tagName]) {\n const parentNode = getParentNode(currentNode) || currentNode.parentNode;\n const childNodes = getChildNodes(currentNode) || currentNode.childNodes;\n\n if (childNodes && parentNode) {\n const childCount = childNodes.length;\n\n for (let i = childCount - 1; i >= 0; --i) {\n parentNode.insertBefore(\n cloneNode(childNodes[i], true),\n getNextSibling(currentNode)\n );\n }\n }\n }\n\n _forceRemove(currentNode);\n return true;\n }\n\n /* Check whether element has a valid namespace */\n if (currentNode instanceof Element && !_checkValidNamespace(currentNode)) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Make sure that older browsers don't get fallback-tag mXSS */\n if (\n (tagName === 'noscript' ||\n tagName === 'noembed' ||\n tagName === 'noframes') &&\n regExpTest(/<\\/no(script|embed|frames)/i, currentNode.innerHTML)\n ) {\n _forceRemove(currentNode);\n return true;\n }\n\n /* Sanitize element content to be template-safe */\n if (SAFE_FOR_TEMPLATES && currentNode.nodeType === 3) {\n /* Get the element's text content */\n content = currentNode.textContent;\n content = stringReplace(content, MUSTACHE_EXPR, ' ');\n content = stringReplace(content, ERB_EXPR, ' ');\n content = stringReplace(content, TMPLIT_EXPR, ' ');\n if (currentNode.textContent !== content) {\n arrayPush(DOMPurify.removed, { element: currentNode.cloneNode() });\n currentNode.textContent = content;\n }\n }\n\n /* Execute a hook if present */\n _executeHook('afterSanitizeElements', currentNode, null);\n\n return false;\n };\n\n /**\n * _isValidAttribute\n *\n * @param {string} lcTag Lowercase tag name of containing element.\n * @param {string} lcName Lowercase attribute name.\n * @param {string} value Attribute value.\n * @return {Boolean} Returns true if `value` is valid, otherwise false.\n */\n // eslint-disable-next-line complexity\n const _isValidAttribute = function (lcTag, lcName, value) {\n /* Make sure attribute cannot clobber */\n if (\n SANITIZE_DOM &&\n (lcName === 'id' || lcName === 'name') &&\n (value in document || value in formElement)\n ) {\n return false;\n }\n\n /* Allow valid data-* attributes: At least one character after \"-\"\n (https://html.spec.whatwg.org/multipage/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes)\n XML-compatible (https://html.spec.whatwg.org/multipage/infrastructure.html#xml-compatible and http://www.w3.org/TR/xml/#d0e804)\n We don't need to check the value; it's always URI safe. */\n if (\n ALLOW_DATA_ATTR &&\n !FORBID_ATTR[lcName] &&\n regExpTest(DATA_ATTR, lcName)\n ) {\n // This attribute is safe\n } else if (ALLOW_ARIA_ATTR && regExpTest(ARIA_ATTR, lcName)) {\n // This attribute is safe\n /* Otherwise, check the name is permitted */\n } else if (!ALLOWED_ATTR[lcName] || FORBID_ATTR[lcName]) {\n if (\n // First condition does a very basic check if a) it's basically a valid custom element tagname AND\n // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck\n // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck\n (_basicCustomElementTest(lcTag) &&\n ((CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, lcTag)) ||\n (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.tagNameCheck(lcTag))) &&\n ((CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.attributeNameCheck, lcName)) ||\n (CUSTOM_ELEMENT_HANDLING.attributeNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.attributeNameCheck(lcName)))) ||\n // Alternative, second condition checks if it's an `is`-attribute, AND\n // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck\n (lcName === 'is' &&\n CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements &&\n ((CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp &&\n regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, value)) ||\n (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function &&\n CUSTOM_ELEMENT_HANDLING.tagNameCheck(value))))\n ) {\n // If user has supplied a regexp or function in CUSTOM_ELEMENT_HANDLING.tagNameCheck, we need to also allow derived custom elements using the same tagName test.\n // Additionally, we need to allow attributes passing the CUSTOM_ELEMENT_HANDLING.attributeNameCheck user has configured, as custom elements can define these at their own discretion.\n } else {\n return false;\n }\n /* Check value is safe. First, is attr inert? If so, is safe */\n } else if (URI_SAFE_ATTRIBUTES[lcName]) {\n // This attribute is safe\n /* Check no script, data or unknown possibly unsafe URI\n unless we know URI values are safe for that attribute */\n } else if (\n regExpTest(IS_ALLOWED_URI, stringReplace(value, ATTR_WHITESPACE, ''))\n ) {\n // This attribute is safe\n /* Keep image data URIs alive if src/xlink:href is allowed */\n /* Further prevent gadget XSS for dynamically built script tags */\n } else if (\n (lcName === 'src' || lcName === 'xlink:href' || lcName === 'href') &&\n lcTag !== 'script' &&\n stringIndexOf(value, 'data:') === 0 &&\n DATA_URI_TAGS[lcTag]\n ) {\n // This attribute is safe\n /* Allow unknown protocols: This provides support for links that\n are handled by protocol handlers which may be unknown ahead of\n time, e.g. fb:, spotify: */\n } else if (\n ALLOW_UNKNOWN_PROTOCOLS &&\n !regExpTest(IS_SCRIPT_OR_DATA, stringReplace(value, ATTR_WHITESPACE, ''))\n ) {\n // This attribute is safe\n /* Check for binary attributes */\n } else if (value) {\n return false;\n } else {\n // Binary attributes are safe at this point\n /* Anything else, presume unsafe, do not add it back */\n }\n\n return true;\n };\n\n /**\n * _basicCustomElementCheck\n * checks if at least one dash is included in tagName, and it's not the first char\n * for more sophisticated checking see https://github.com/sindresorhus/validate-element-name\n * @param {string} tagName name of the tag of the node to sanitize\n */\n const _basicCustomElementTest = function (tagName) {\n return tagName.indexOf('-') > 0;\n };\n\n /**\n * _sanitizeAttributes\n *\n * @protect attributes\n * @protect nodeName\n * @protect removeAttribute\n * @protect setAttribute\n *\n * @param {Node} currentNode to sanitize\n */\n const _sanitizeAttributes = function (currentNode) {\n let attr;\n let value;\n let lcName;\n let l;\n /* Execute a hook if present */\n _executeHook('beforeSanitizeAttributes', currentNode, null);\n\n const { attributes } = currentNode;\n\n /* Check if we have attributes; if not we might have a text node */\n if (!attributes) {\n return;\n }\n\n const hookEvent = {\n attrName: '',\n attrValue: '',\n keepAttr: true,\n allowedAttributes: ALLOWED_ATTR,\n };\n l = attributes.length;\n\n /* Go backwards over all attributes; safely remove bad ones */\n while (l--) {\n attr = attributes[l];\n const { name, namespaceURI } = attr;\n value = name === 'value' ? attr.value : stringTrim(attr.value);\n lcName = transformCaseFunc(name);\n\n /* Execute a hook if present */\n hookEvent.attrName = lcName;\n hookEvent.attrValue = value;\n hookEvent.keepAttr = true;\n hookEvent.forceKeepAttr = undefined; // Allows developers to see this is a property they can set\n _executeHook('uponSanitizeAttribute', currentNode, hookEvent);\n value = hookEvent.attrValue;\n /* Did the hooks approve of the attribute? */\n if (hookEvent.forceKeepAttr) {\n continue;\n }\n\n /* Remove attribute */\n _removeAttribute(name, currentNode);\n\n /* Did the hooks approve of the attribute? */\n if (!hookEvent.keepAttr) {\n continue;\n }\n\n /* Work around a security issue in jQuery 3.0 */\n if (!ALLOW_SELF_CLOSE_IN_ATTR && regExpTest(/\\/>/i, value)) {\n _removeAttribute(name, currentNode);\n continue;\n }\n\n /* Sanitize attribute content to be template-safe */\n if (SAFE_FOR_TEMPLATES) {\n value = stringReplace(value, MUSTACHE_EXPR, ' ');\n value = stringReplace(value, ERB_EXPR, ' ');\n value = stringReplace(value, TMPLIT_EXPR, ' ');\n }\n\n /* Is `value` valid for this attribute? */\n const lcTag = transformCaseFunc(currentNode.nodeName);\n if (!_isValidAttribute(lcTag, lcName, value)) {\n continue;\n }\n\n /* Full DOM Clobbering protection via namespace isolation,\n * Prefix id and name attributes with `user-content-`\n */\n if (SANITIZE_NAMED_PROPS && (lcName === 'id' || lcName === 'name')) {\n // Remove the attribute with this value\n _removeAttribute(name, currentNode);\n\n // Prefix the value and later re-create the attribute with the sanitized value\n value = SANITIZE_NAMED_PROPS_PREFIX + value;\n }\n\n /* Handle attributes that require Trusted Types */\n if (\n trustedTypesPolicy &&\n typeof trustedTypes === 'object' &&\n typeof trustedTypes.getAttributeType === 'function'\n ) {\n if (namespaceURI) {\n /* Namespaces are not yet supported, see https://bugs.chromium.org/p/chromium/issues/detail?id=1305293 */\n } else {\n switch (trustedTypes.getAttributeType(lcTag, lcName)) {\n case 'TrustedHTML': {\n value = trustedTypesPolicy.createHTML(value);\n break;\n }\n\n case 'TrustedScriptURL': {\n value = trustedTypesPolicy.createScriptURL(value);\n break;\n }\n\n default: {\n break;\n }\n }\n }\n }\n\n /* Handle invalid data-* attribute set by try-catching it */\n try {\n if (namespaceURI) {\n currentNode.setAttributeNS(namespaceURI, name, value);\n } else {\n /* Fallback to setAttribute() for browser-unrecognized namespaces e.g. \"x-schema\". */\n currentNode.setAttribute(name, value);\n }\n\n arrayPop(DOMPurify.removed);\n } catch (_) {}\n }\n\n /* Execute a hook if present */\n _executeHook('afterSanitizeAttributes', currentNode, null);\n };\n\n /**\n * _sanitizeShadowDOM\n *\n * @param {DocumentFragment} fragment to iterate over recursively\n */\n const _sanitizeShadowDOM = function (fragment) {\n let shadowNode;\n const shadowIterator = _createIterator(fragment);\n\n /* Execute a hook if present */\n _executeHook('beforeSanitizeShadowDOM', fragment, null);\n\n while ((shadowNode = shadowIterator.nextNode())) {\n /* Execute a hook if present */\n _executeHook('uponSanitizeShadowNode', shadowNode, null);\n\n /* Sanitize tags and elements */\n if (_sanitizeElements(shadowNode)) {\n continue;\n }\n\n /* Deep shadow DOM detected */\n if (shadowNode.content instanceof DocumentFragment) {\n _sanitizeShadowDOM(shadowNode.content);\n }\n\n /* Check attributes, sanitize if necessary */\n _sanitizeAttributes(shadowNode);\n }\n\n /* Execute a hook if present */\n _executeHook('afterSanitizeShadowDOM', fragment, null);\n };\n\n /**\n * Sanitize\n * Public method providing core sanitation functionality\n *\n * @param {String|Node} dirty string or DOM node\n * @param {Object} configuration object\n */\n // eslint-disable-next-line complexity\n DOMPurify.sanitize = function (dirty, cfg = {}) {\n let body;\n let importedNode;\n let currentNode;\n let returnNode;\n /* Make sure we have a string to sanitize.\n DO NOT return early, as this will return the wrong type if\n the user has requested a DOM object rather than a string */\n IS_EMPTY_INPUT = !dirty;\n if (IS_EMPTY_INPUT) {\n dirty = '';\n }\n\n /* Stringify, in case dirty is an object */\n if (typeof dirty !== 'string' && !_isNode(dirty)) {\n if (typeof dirty.toString === 'function') {\n dirty = dirty.toString();\n if (typeof dirty !== 'string') {\n throw typeErrorCreate('dirty is not a string, aborting');\n }\n } else {\n throw typeErrorCreate('toString is not a function');\n }\n }\n\n /* Return dirty HTML if DOMPurify cannot run */\n if (!DOMPurify.isSupported) {\n return dirty;\n }\n\n /* Assign config vars */\n if (!SET_CONFIG) {\n _parseConfig(cfg);\n }\n\n /* Clean up removed elements */\n DOMPurify.removed = [];\n\n /* Check if dirty is correctly typed for IN_PLACE */\n if (typeof dirty === 'string') {\n IN_PLACE = false;\n }\n\n if (IN_PLACE) {\n /* Do some early pre-sanitization to avoid unsafe root nodes */\n if (dirty.nodeName) {\n const tagName = transformCaseFunc(dirty.nodeName);\n if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {\n throw typeErrorCreate(\n 'root node is forbidden and cannot be sanitized in-place'\n );\n }\n }\n } else if (dirty instanceof Node) {\n /* If dirty is a DOM element, append to an empty document to avoid\n elements being stripped by the parser */\n body = _initDocument('');\n importedNode = body.ownerDocument.importNode(dirty, true);\n if (importedNode.nodeType === 1 && importedNode.nodeName === 'BODY') {\n /* Node is already a body, use as is */\n body = importedNode;\n } else if (importedNode.nodeName === 'HTML') {\n body = importedNode;\n } else {\n // eslint-disable-next-line unicorn/prefer-dom-node-append\n body.appendChild(importedNode);\n }\n } else {\n /* Exit directly if we have nothing to do */\n if (\n !RETURN_DOM &&\n !SAFE_FOR_TEMPLATES &&\n !WHOLE_DOCUMENT &&\n // eslint-disable-next-line unicorn/prefer-includes\n dirty.indexOf('<') === -1\n ) {\n return trustedTypesPolicy && RETURN_TRUSTED_TYPE\n ? trustedTypesPolicy.createHTML(dirty)\n : dirty;\n }\n\n /* Initialize the document to work on */\n body = _initDocument(dirty);\n\n /* Check we have a DOM node from the data */\n if (!body) {\n return RETURN_DOM ? null : RETURN_TRUSTED_TYPE ? emptyHTML : '';\n }\n }\n\n /* Remove first element node (ours) if FORCE_BODY is set */\n if (body && FORCE_BODY) {\n _forceRemove(body.firstChild);\n }\n\n /* Get node iterator */\n const nodeIterator = _createIterator(IN_PLACE ? dirty : body);\n\n /* Now start iterating over the created document */\n while ((currentNode = nodeIterator.nextNode())) {\n /* Sanitize tags and elements */\n if (_sanitizeElements(currentNode)) {\n continue;\n }\n\n /* Shadow DOM detected, sanitize it */\n if (currentNode.content instanceof DocumentFragment) {\n _sanitizeShadowDOM(currentNode.content);\n }\n\n /* Check attributes, sanitize if necessary */\n _sanitizeAttributes(currentNode);\n }\n\n /* If we sanitized `dirty` in-place, return it. */\n if (IN_PLACE) {\n return dirty;\n }\n\n /* Return sanitized string or DOM */\n if (RETURN_DOM) {\n if (RETURN_DOM_FRAGMENT) {\n returnNode = createDocumentFragment.call(body.ownerDocument);\n\n while (body.firstChild) {\n // eslint-disable-next-line unicorn/prefer-dom-node-append\n returnNode.appendChild(body.firstChild);\n }\n } else {\n returnNode = body;\n }\n\n if (ALLOWED_ATTR.shadowroot || ALLOWED_ATTR.shadowrootmode) {\n /*\n AdoptNode() is not used because internal state is not reset\n (e.g. the past names map of a HTMLFormElement), this is safe\n in theory but we would rather not risk another attack vector.\n The state that is cloned by importNode() is explicitly defined\n by the specs.\n */\n returnNode = importNode.call(originalDocument, returnNode, true);\n }\n\n return returnNode;\n }\n\n let serializedHTML = WHOLE_DOCUMENT ? body.outerHTML : body.innerHTML;\n\n /* Serialize doctype if allowed */\n if (\n WHOLE_DOCUMENT &&\n ALLOWED_TAGS['!doctype'] &&\n body.ownerDocument &&\n body.ownerDocument.doctype &&\n body.ownerDocument.doctype.name &&\n regExpTest(EXPRESSIONS.DOCTYPE_NAME, body.ownerDocument.doctype.name)\n ) {\n serializedHTML =\n '\\n' + serializedHTML;\n }\n\n /* Sanitize final string template-safe */\n if (SAFE_FOR_TEMPLATES) {\n serializedHTML = stringReplace(serializedHTML, MUSTACHE_EXPR, ' ');\n serializedHTML = stringReplace(serializedHTML, ERB_EXPR, ' ');\n serializedHTML = stringReplace(serializedHTML, TMPLIT_EXPR, ' ');\n }\n\n return trustedTypesPolicy && RETURN_TRUSTED_TYPE\n ? trustedTypesPolicy.createHTML(serializedHTML)\n : serializedHTML;\n };\n\n /**\n * Public method to set the configuration once\n * setConfig\n *\n * @param {Object} cfg configuration object\n */\n DOMPurify.setConfig = function (cfg) {\n _parseConfig(cfg);\n SET_CONFIG = true;\n };\n\n /**\n * Public method to remove the configuration\n * clearConfig\n *\n */\n DOMPurify.clearConfig = function () {\n CONFIG = null;\n SET_CONFIG = false;\n };\n\n /**\n * Public method to check if an attribute value is valid.\n * Uses last set config, if any. Otherwise, uses config defaults.\n * isValidAttribute\n *\n * @param {string} tag Tag name of containing element.\n * @param {string} attr Attribute name.\n * @param {string} value Attribute value.\n * @return {Boolean} Returns true if `value` is valid. Otherwise, returns false.\n */\n DOMPurify.isValidAttribute = function (tag, attr, value) {\n /* Initialize shared config vars if necessary. */\n if (!CONFIG) {\n _parseConfig({});\n }\n\n const lcTag = transformCaseFunc(tag);\n const lcName = transformCaseFunc(attr);\n return _isValidAttribute(lcTag, lcName, value);\n };\n\n /**\n * AddHook\n * Public method to add DOMPurify hooks\n *\n * @param {String} entryPoint entry point for the hook to add\n * @param {Function} hookFunction function to execute\n */\n DOMPurify.addHook = function (entryPoint, hookFunction) {\n if (typeof hookFunction !== 'function') {\n return;\n }\n\n hooks[entryPoint] = hooks[entryPoint] || [];\n arrayPush(hooks[entryPoint], hookFunction);\n };\n\n /**\n * RemoveHook\n * Public method to remove a DOMPurify hook at a given entryPoint\n * (pops it from the stack of hooks if more are present)\n *\n * @param {String} entryPoint entry point for the hook to remove\n * @return {Function} removed(popped) hook\n */\n DOMPurify.removeHook = function (entryPoint) {\n if (hooks[entryPoint]) {\n return arrayPop(hooks[entryPoint]);\n }\n };\n\n /**\n * RemoveHooks\n * Public method to remove all DOMPurify hooks at a given entryPoint\n *\n * @param {String} entryPoint entry point for the hooks to remove\n */\n DOMPurify.removeHooks = function (entryPoint) {\n if (hooks[entryPoint]) {\n hooks[entryPoint] = [];\n }\n };\n\n /**\n * RemoveAllHooks\n * Public method to remove all DOMPurify hooks\n *\n */\n DOMPurify.removeAllHooks = function () {\n hooks = {};\n };\n\n return DOMPurify;\n}\n\nexport default createDOMPurify();\n", "export function dedent(\n templ: TemplateStringsArray | string,\n ...values: unknown[]\n): string {\n let strings = Array.from(typeof templ === 'string' ? [templ] : templ);\n\n // 1. Remove trailing whitespace.\n strings[strings.length - 1] = strings[strings.length - 1].replace(\n /\\r?\\n([\\t ]*)$/,\n '',\n );\n\n // 2. Find all line breaks to determine the highest common indentation level.\n const indentLengths = strings.reduce((arr, str) => {\n const matches = str.match(/\\n([\\t ]+|(?!\\s).)/g);\n if (matches) {\n return arr.concat(\n matches.map((match) => match.match(/[\\t ]/g)?.length ?? 0),\n );\n }\n return arr;\n }, []);\n\n // 3. Remove the common indentation from all strings.\n if (indentLengths.length) {\n const pattern = new RegExp(`\\n[\\t ]{${Math.min(...indentLengths)}}`, 'g');\n\n strings = strings.map((str) => str.replace(pattern, '\\n'));\n }\n\n // 4. Remove leading whitespace.\n strings[0] = strings[0].replace(/^\\r?\\n/, '');\n\n // 5. Perform interpolation.\n let string = strings[0];\n\n values.forEach((value, i) => {\n // 5.1 Read current indentation level\n const endentations = string.match(/(?:^|\\n)( *)$/)\n const endentation = endentations ? endentations[1] : ''\n let indentedValue = value\n // 5.2 Add indentation to values with multiline strings\n if (typeof value === 'string' && value.includes('\\n')) {\n indentedValue = String(value)\n .split('\\n')\n .map((str, i) => {\n return i === 0 ? str : `${endentation}${str}`\n })\n .join('\\n');\n }\n\n string += indentedValue + strings[i + 1];\n });\n\n return string;\n}\n\nexport default dedent;\n", "export default function max(values, valueof) {\n let max;\n if (valueof === undefined) {\n for (const value of values) {\n if (value != null\n && (max < value || (max === undefined && value >= value))) {\n max = value;\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null\n && (max < value || (max === undefined && value >= value))) {\n max = value;\n }\n }\n }\n return max;\n}\n", "export default function min(values, valueof) {\n let min;\n if (valueof === undefined) {\n for (const value of values) {\n if (value != null\n && (min > value || (min === undefined && value >= value))) {\n min = value;\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null\n && (min > value || (min === undefined && value >= value))) {\n min = value;\n }\n }\n }\n return min;\n}\n", "export default function ascending(a, b) {\n return a == null || b == null ? NaN : a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;\n}\n", "export default function descending(a, b) {\n return a == null || b == null ? NaN\n : b < a ? -1\n : b > a ? 1\n : b >= a ? 0\n : NaN;\n}\n", "import ascending from \"./ascending.js\";\nimport descending from \"./descending.js\";\n\nexport default function bisector(f) {\n let compare1, compare2, delta;\n\n // If an accessor is specified, promote it to a comparator. In this case we\n // can test whether the search value is (self-) comparable. We can\u2019t do this\n // for a comparator (except for specific, known comparators) because we can\u2019t\n // tell if the comparator is symmetric, and an asymmetric comparator can\u2019t be\n // used to test whether a single value is comparable.\n if (f.length !== 2) {\n compare1 = ascending;\n compare2 = (d, x) => ascending(f(d), x);\n delta = (d, x) => f(d) - x;\n } else {\n compare1 = f === ascending || f === descending ? f : zero;\n compare2 = f;\n delta = f;\n }\n\n function left(a, x, lo = 0, hi = a.length) {\n if (lo < hi) {\n if (compare1(x, x) !== 0) return hi;\n do {\n const mid = (lo + hi) >>> 1;\n if (compare2(a[mid], x) < 0) lo = mid + 1;\n else hi = mid;\n } while (lo < hi);\n }\n return lo;\n }\n\n function right(a, x, lo = 0, hi = a.length) {\n if (lo < hi) {\n if (compare1(x, x) !== 0) return hi;\n do {\n const mid = (lo + hi) >>> 1;\n if (compare2(a[mid], x) <= 0) lo = mid + 1;\n else hi = mid;\n } while (lo < hi);\n }\n return lo;\n }\n\n function center(a, x, lo = 0, hi = a.length) {\n const i = left(a, x, lo, hi - 1);\n return i > lo && delta(a[i - 1], x) > -delta(a[i], x) ? i - 1 : i;\n }\n\n return {left, center, right};\n}\n\nfunction zero() {\n return 0;\n}\n", "export default function number(x) {\n return x === null ? NaN : +x;\n}\n\nexport function* numbers(values, valueof) {\n if (valueof === undefined) {\n for (let value of values) {\n if (value != null && (value = +value) >= value) {\n yield value;\n }\n }\n } else {\n let index = -1;\n for (let value of values) {\n if ((value = valueof(value, ++index, values)) != null && (value = +value) >= value) {\n yield value;\n }\n }\n }\n}\n", "import ascending from \"./ascending.js\";\nimport bisector from \"./bisector.js\";\nimport number from \"./number.js\";\n\nconst ascendingBisect = bisector(ascending);\nexport const bisectRight = ascendingBisect.right;\nexport const bisectLeft = ascendingBisect.left;\nexport const bisectCenter = bisector(number).center;\nexport default bisectRight;\n", "export class InternMap extends Map {\n constructor(entries, key = keyof) {\n super();\n Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}});\n if (entries != null) for (const [key, value] of entries) this.set(key, value);\n }\n get(key) {\n return super.get(intern_get(this, key));\n }\n has(key) {\n return super.has(intern_get(this, key));\n }\n set(key, value) {\n return super.set(intern_set(this, key), value);\n }\n delete(key) {\n return super.delete(intern_delete(this, key));\n }\n}\n\nexport class InternSet extends Set {\n constructor(values, key = keyof) {\n super();\n Object.defineProperties(this, {_intern: {value: new Map()}, _key: {value: key}});\n if (values != null) for (const value of values) this.add(value);\n }\n has(value) {\n return super.has(intern_get(this, value));\n }\n add(value) {\n return super.add(intern_set(this, value));\n }\n delete(value) {\n return super.delete(intern_delete(this, value));\n }\n}\n\nfunction intern_get({_intern, _key}, value) {\n const key = _key(value);\n return _intern.has(key) ? _intern.get(key) : value;\n}\n\nfunction intern_set({_intern, _key}, value) {\n const key = _key(value);\n if (_intern.has(key)) return _intern.get(key);\n _intern.set(key, value);\n return value;\n}\n\nfunction intern_delete({_intern, _key}, value) {\n const key = _key(value);\n if (_intern.has(key)) {\n value = _intern.get(key);\n _intern.delete(key);\n }\n return value;\n}\n\nfunction keyof(value) {\n return value !== null && typeof value === \"object\" ? value.valueOf() : value;\n}\n", "const e10 = Math.sqrt(50),\n e5 = Math.sqrt(10),\n e2 = Math.sqrt(2);\n\nfunction tickSpec(start, stop, count) {\n const step = (stop - start) / Math.max(0, count),\n power = Math.floor(Math.log10(step)),\n error = step / Math.pow(10, power),\n factor = error >= e10 ? 10 : error >= e5 ? 5 : error >= e2 ? 2 : 1;\n let i1, i2, inc;\n if (power < 0) {\n inc = Math.pow(10, -power) / factor;\n i1 = Math.round(start * inc);\n i2 = Math.round(stop * inc);\n if (i1 / inc < start) ++i1;\n if (i2 / inc > stop) --i2;\n inc = -inc;\n } else {\n inc = Math.pow(10, power) * factor;\n i1 = Math.round(start / inc);\n i2 = Math.round(stop / inc);\n if (i1 * inc < start) ++i1;\n if (i2 * inc > stop) --i2;\n }\n if (i2 < i1 && 0.5 <= count && count < 2) return tickSpec(start, stop, count * 2);\n return [i1, i2, inc];\n}\n\nexport default function ticks(start, stop, count) {\n stop = +stop, start = +start, count = +count;\n if (!(count > 0)) return [];\n if (start === stop) return [start];\n const reverse = stop < start, [i1, i2, inc] = reverse ? tickSpec(stop, start, count) : tickSpec(start, stop, count);\n if (!(i2 >= i1)) return [];\n const n = i2 - i1 + 1, ticks = new Array(n);\n if (reverse) {\n if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) / -inc;\n else for (let i = 0; i < n; ++i) ticks[i] = (i2 - i) * inc;\n } else {\n if (inc < 0) for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) / -inc;\n else for (let i = 0; i < n; ++i) ticks[i] = (i1 + i) * inc;\n }\n return ticks;\n}\n\nexport function tickIncrement(start, stop, count) {\n stop = +stop, start = +start, count = +count;\n return tickSpec(start, stop, count)[2];\n}\n\nexport function tickStep(start, stop, count) {\n stop = +stop, start = +start, count = +count;\n const reverse = stop < start, inc = reverse ? tickIncrement(stop, start, count) : tickIncrement(start, stop, count);\n return (reverse ? -1 : 1) * (inc < 0 ? 1 / -inc : inc);\n}\n", "export default function range(start, stop, step) {\n start = +start, stop = +stop, step = (n = arguments.length) < 2 ? (stop = start, start = 0, 1) : n < 3 ? 1 : +step;\n\n var i = -1,\n n = Math.max(0, Math.ceil((stop - start) / step)) | 0,\n range = new Array(n);\n\n while (++i < n) {\n range[i] = start + i * step;\n }\n\n return range;\n}\n", "export default function(x) {\n return x;\n}\n", "import identity from \"./identity.js\";\n\nvar top = 1,\n right = 2,\n bottom = 3,\n left = 4,\n epsilon = 1e-6;\n\nfunction translateX(x) {\n return \"translate(\" + x + \",0)\";\n}\n\nfunction translateY(y) {\n return \"translate(0,\" + y + \")\";\n}\n\nfunction number(scale) {\n return d => +scale(d);\n}\n\nfunction center(scale, offset) {\n offset = Math.max(0, scale.bandwidth() - offset * 2) / 2;\n if (scale.round()) offset = Math.round(offset);\n return d => +scale(d) + offset;\n}\n\nfunction entering() {\n return !this.__axis;\n}\n\nfunction axis(orient, scale) {\n var tickArguments = [],\n tickValues = null,\n tickFormat = null,\n tickSizeInner = 6,\n tickSizeOuter = 6,\n tickPadding = 3,\n offset = typeof window !== \"undefined\" && window.devicePixelRatio > 1 ? 0 : 0.5,\n k = orient === top || orient === left ? -1 : 1,\n x = orient === left || orient === right ? \"x\" : \"y\",\n transform = orient === top || orient === bottom ? translateX : translateY;\n\n function axis(context) {\n var values = tickValues == null ? (scale.ticks ? scale.ticks.apply(scale, tickArguments) : scale.domain()) : tickValues,\n format = tickFormat == null ? (scale.tickFormat ? scale.tickFormat.apply(scale, tickArguments) : identity) : tickFormat,\n spacing = Math.max(tickSizeInner, 0) + tickPadding,\n range = scale.range(),\n range0 = +range[0] + offset,\n range1 = +range[range.length - 1] + offset,\n position = (scale.bandwidth ? center : number)(scale.copy(), offset),\n selection = context.selection ? context.selection() : context,\n path = selection.selectAll(\".domain\").data([null]),\n tick = selection.selectAll(\".tick\").data(values, scale).order(),\n tickExit = tick.exit(),\n tickEnter = tick.enter().append(\"g\").attr(\"class\", \"tick\"),\n line = tick.select(\"line\"),\n text = tick.select(\"text\");\n\n path = path.merge(path.enter().insert(\"path\", \".tick\")\n .attr(\"class\", \"domain\")\n .attr(\"stroke\", \"currentColor\"));\n\n tick = tick.merge(tickEnter);\n\n line = line.merge(tickEnter.append(\"line\")\n .attr(\"stroke\", \"currentColor\")\n .attr(x + \"2\", k * tickSizeInner));\n\n text = text.merge(tickEnter.append(\"text\")\n .attr(\"fill\", \"currentColor\")\n .attr(x, k * spacing)\n .attr(\"dy\", orient === top ? \"0em\" : orient === bottom ? \"0.71em\" : \"0.32em\"));\n\n if (context !== selection) {\n path = path.transition(context);\n tick = tick.transition(context);\n line = line.transition(context);\n text = text.transition(context);\n\n tickExit = tickExit.transition(context)\n .attr(\"opacity\", epsilon)\n .attr(\"transform\", function(d) { return isFinite(d = position(d)) ? transform(d + offset) : this.getAttribute(\"transform\"); });\n\n tickEnter\n .attr(\"opacity\", epsilon)\n .attr(\"transform\", function(d) { var p = this.parentNode.__axis; return transform((p && isFinite(p = p(d)) ? p : position(d)) + offset); });\n }\n\n tickExit.remove();\n\n path\n .attr(\"d\", orient === left || orient === right\n ? (tickSizeOuter ? \"M\" + k * tickSizeOuter + \",\" + range0 + \"H\" + offset + \"V\" + range1 + \"H\" + k * tickSizeOuter : \"M\" + offset + \",\" + range0 + \"V\" + range1)\n : (tickSizeOuter ? \"M\" + range0 + \",\" + k * tickSizeOuter + \"V\" + offset + \"H\" + range1 + \"V\" + k * tickSizeOuter : \"M\" + range0 + \",\" + offset + \"H\" + range1));\n\n tick\n .attr(\"opacity\", 1)\n .attr(\"transform\", function(d) { return transform(position(d) + offset); });\n\n line\n .attr(x + \"2\", k * tickSizeInner);\n\n text\n .attr(x, k * spacing)\n .text(format);\n\n selection.filter(entering)\n .attr(\"fill\", \"none\")\n .attr(\"font-size\", 10)\n .attr(\"font-family\", \"sans-serif\")\n .attr(\"text-anchor\", orient === right ? \"start\" : orient === left ? \"end\" : \"middle\");\n\n selection\n .each(function() { this.__axis = position; });\n }\n\n axis.scale = function(_) {\n return arguments.length ? (scale = _, axis) : scale;\n };\n\n axis.ticks = function() {\n return tickArguments = Array.from(arguments), axis;\n };\n\n axis.tickArguments = function(_) {\n return arguments.length ? (tickArguments = _ == null ? [] : Array.from(_), axis) : tickArguments.slice();\n };\n\n axis.tickValues = function(_) {\n return arguments.length ? (tickValues = _ == null ? null : Array.from(_), axis) : tickValues && tickValues.slice();\n };\n\n axis.tickFormat = function(_) {\n return arguments.length ? (tickFormat = _, axis) : tickFormat;\n };\n\n axis.tickSize = function(_) {\n return arguments.length ? (tickSizeInner = tickSizeOuter = +_, axis) : tickSizeInner;\n };\n\n axis.tickSizeInner = function(_) {\n return arguments.length ? (tickSizeInner = +_, axis) : tickSizeInner;\n };\n\n axis.tickSizeOuter = function(_) {\n return arguments.length ? (tickSizeOuter = +_, axis) : tickSizeOuter;\n };\n\n axis.tickPadding = function(_) {\n return arguments.length ? (tickPadding = +_, axis) : tickPadding;\n };\n\n axis.offset = function(_) {\n return arguments.length ? (offset = +_, axis) : offset;\n };\n\n return axis;\n}\n\nexport function axisTop(scale) {\n return axis(top, scale);\n}\n\nexport function axisRight(scale) {\n return axis(right, scale);\n}\n\nexport function axisBottom(scale) {\n return axis(bottom, scale);\n}\n\nexport function axisLeft(scale) {\n return axis(left, scale);\n}\n", "function none() {}\n\nexport default function(selector) {\n return selector == null ? none : function() {\n return this.querySelector(selector);\n };\n}\n", "import {Selection} from \"./index.js\";\nimport selector from \"../selector.js\";\n\nexport default function(select) {\n if (typeof select !== \"function\") select = selector(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = new Array(n), node, subnode, i = 0; i < n; ++i) {\n if ((node = group[i]) && (subnode = select.call(node, node.__data__, i, group))) {\n if (\"__data__\" in node) subnode.__data__ = node.__data__;\n subgroup[i] = subnode;\n }\n }\n }\n\n return new Selection(subgroups, this._parents);\n}\n", "// Given something array like (or null), returns something that is strictly an\n// array. This is used to ensure that array-like objects passed to d3.selectAll\n// or selection.selectAll are converted into proper arrays when creating a\n// selection; we don\u2019t ever want to create a selection backed by a live\n// HTMLCollection or NodeList. However, note that selection.selectAll will use a\n// static NodeList as a group, since it safely derived from querySelectorAll.\nexport default function array(x) {\n return x == null ? [] : Array.isArray(x) ? x : Array.from(x);\n}\n", "function empty() {\n return [];\n}\n\nexport default function(selector) {\n return selector == null ? empty : function() {\n return this.querySelectorAll(selector);\n };\n}\n", "import {Selection} from \"./index.js\";\nimport array from \"../array.js\";\nimport selectorAll from \"../selectorAll.js\";\n\nfunction arrayAll(select) {\n return function() {\n return array(select.apply(this, arguments));\n };\n}\n\nexport default function(select) {\n if (typeof select === \"function\") select = arrayAll(select);\n else select = selectorAll(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = [], parents = [], j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n subgroups.push(select.call(node, node.__data__, i, group));\n parents.push(node);\n }\n }\n }\n\n return new Selection(subgroups, parents);\n}\n", "export default function(selector) {\n return function() {\n return this.matches(selector);\n };\n}\n\nexport function childMatcher(selector) {\n return function(node) {\n return node.matches(selector);\n };\n}\n\n", "import {childMatcher} from \"../matcher.js\";\n\nvar find = Array.prototype.find;\n\nfunction childFind(match) {\n return function() {\n return find.call(this.children, match);\n };\n}\n\nfunction childFirst() {\n return this.firstElementChild;\n}\n\nexport default function(match) {\n return this.select(match == null ? childFirst\n : childFind(typeof match === \"function\" ? match : childMatcher(match)));\n}\n", "import {childMatcher} from \"../matcher.js\";\n\nvar filter = Array.prototype.filter;\n\nfunction children() {\n return Array.from(this.children);\n}\n\nfunction childrenFilter(match) {\n return function() {\n return filter.call(this.children, match);\n };\n}\n\nexport default function(match) {\n return this.selectAll(match == null ? children\n : childrenFilter(typeof match === \"function\" ? match : childMatcher(match)));\n}\n", "import {Selection} from \"./index.js\";\nimport matcher from \"../matcher.js\";\n\nexport default function(match) {\n if (typeof match !== \"function\") match = matcher(match);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = [], node, i = 0; i < n; ++i) {\n if ((node = group[i]) && match.call(node, node.__data__, i, group)) {\n subgroup.push(node);\n }\n }\n }\n\n return new Selection(subgroups, this._parents);\n}\n", "export default function(update) {\n return new Array(update.length);\n}\n", "import sparse from \"./sparse.js\";\nimport {Selection} from \"./index.js\";\n\nexport default function() {\n return new Selection(this._enter || this._groups.map(sparse), this._parents);\n}\n\nexport function EnterNode(parent, datum) {\n this.ownerDocument = parent.ownerDocument;\n this.namespaceURI = parent.namespaceURI;\n this._next = null;\n this._parent = parent;\n this.__data__ = datum;\n}\n\nEnterNode.prototype = {\n constructor: EnterNode,\n appendChild: function(child) { return this._parent.insertBefore(child, this._next); },\n insertBefore: function(child, next) { return this._parent.insertBefore(child, next); },\n querySelector: function(selector) { return this._parent.querySelector(selector); },\n querySelectorAll: function(selector) { return this._parent.querySelectorAll(selector); }\n};\n", "export default function(x) {\n return function() {\n return x;\n };\n}\n", "import {Selection} from \"./index.js\";\nimport {EnterNode} from \"./enter.js\";\nimport constant from \"../constant.js\";\n\nfunction bindIndex(parent, group, enter, update, exit, data) {\n var i = 0,\n node,\n groupLength = group.length,\n dataLength = data.length;\n\n // Put any non-null nodes that fit into update.\n // Put any null nodes into enter.\n // Put any remaining data into enter.\n for (; i < dataLength; ++i) {\n if (node = group[i]) {\n node.__data__ = data[i];\n update[i] = node;\n } else {\n enter[i] = new EnterNode(parent, data[i]);\n }\n }\n\n // Put any non-null nodes that don\u2019t fit into exit.\n for (; i < groupLength; ++i) {\n if (node = group[i]) {\n exit[i] = node;\n }\n }\n}\n\nfunction bindKey(parent, group, enter, update, exit, data, key) {\n var i,\n node,\n nodeByKeyValue = new Map,\n groupLength = group.length,\n dataLength = data.length,\n keyValues = new Array(groupLength),\n keyValue;\n\n // Compute the key for each node.\n // If multiple nodes have the same key, the duplicates are added to exit.\n for (i = 0; i < groupLength; ++i) {\n if (node = group[i]) {\n keyValues[i] = keyValue = key.call(node, node.__data__, i, group) + \"\";\n if (nodeByKeyValue.has(keyValue)) {\n exit[i] = node;\n } else {\n nodeByKeyValue.set(keyValue, node);\n }\n }\n }\n\n // Compute the key for each datum.\n // If there a node associated with this key, join and add it to update.\n // If there is not (or the key is a duplicate), add it to enter.\n for (i = 0; i < dataLength; ++i) {\n keyValue = key.call(parent, data[i], i, data) + \"\";\n if (node = nodeByKeyValue.get(keyValue)) {\n update[i] = node;\n node.__data__ = data[i];\n nodeByKeyValue.delete(keyValue);\n } else {\n enter[i] = new EnterNode(parent, data[i]);\n }\n }\n\n // Add any remaining nodes that were not bound to data to exit.\n for (i = 0; i < groupLength; ++i) {\n if ((node = group[i]) && (nodeByKeyValue.get(keyValues[i]) === node)) {\n exit[i] = node;\n }\n }\n}\n\nfunction datum(node) {\n return node.__data__;\n}\n\nexport default function(value, key) {\n if (!arguments.length) return Array.from(this, datum);\n\n var bind = key ? bindKey : bindIndex,\n parents = this._parents,\n groups = this._groups;\n\n if (typeof value !== \"function\") value = constant(value);\n\n for (var m = groups.length, update = new Array(m), enter = new Array(m), exit = new Array(m), j = 0; j < m; ++j) {\n var parent = parents[j],\n group = groups[j],\n groupLength = group.length,\n data = arraylike(value.call(parent, parent && parent.__data__, j, parents)),\n dataLength = data.length,\n enterGroup = enter[j] = new Array(dataLength),\n updateGroup = update[j] = new Array(dataLength),\n exitGroup = exit[j] = new Array(groupLength);\n\n bind(parent, group, enterGroup, updateGroup, exitGroup, data, key);\n\n // Now connect the enter nodes to their following update node, such that\n // appendChild can insert the materialized enter node before this node,\n // rather than at the end of the parent node.\n for (var i0 = 0, i1 = 0, previous, next; i0 < dataLength; ++i0) {\n if (previous = enterGroup[i0]) {\n if (i0 >= i1) i1 = i0 + 1;\n while (!(next = updateGroup[i1]) && ++i1 < dataLength);\n previous._next = next || null;\n }\n }\n }\n\n update = new Selection(update, parents);\n update._enter = enter;\n update._exit = exit;\n return update;\n}\n\n// Given some data, this returns an array-like view of it: an object that\n// exposes a length property and allows numeric indexing. Note that unlike\n// selectAll, this isn\u2019t worried about \u201Clive\u201D collections because the resulting\n// array will only be used briefly while data is being bound. (It is possible to\n// cause the data to change while iterating by using a key function, but please\n// don\u2019t; we\u2019d rather avoid a gratuitous copy.)\nfunction arraylike(data) {\n return typeof data === \"object\" && \"length\" in data\n ? data // Array, TypedArray, NodeList, array-like\n : Array.from(data); // Map, Set, iterable, string, or anything else\n}\n", "import sparse from \"./sparse.js\";\nimport {Selection} from \"./index.js\";\n\nexport default function() {\n return new Selection(this._exit || this._groups.map(sparse), this._parents);\n}\n", "export default function(onenter, onupdate, onexit) {\n var enter = this.enter(), update = this, exit = this.exit();\n if (typeof onenter === \"function\") {\n enter = onenter(enter);\n if (enter) enter = enter.selection();\n } else {\n enter = enter.append(onenter + \"\");\n }\n if (onupdate != null) {\n update = onupdate(update);\n if (update) update = update.selection();\n }\n if (onexit == null) exit.remove(); else onexit(exit);\n return enter && update ? enter.merge(update).order() : update;\n}\n", "import {Selection} from \"./index.js\";\n\nexport default function(context) {\n var selection = context.selection ? context.selection() : context;\n\n for (var groups0 = this._groups, groups1 = selection._groups, m0 = groups0.length, m1 = groups1.length, m = Math.min(m0, m1), merges = new Array(m0), j = 0; j < m; ++j) {\n for (var group0 = groups0[j], group1 = groups1[j], n = group0.length, merge = merges[j] = new Array(n), node, i = 0; i < n; ++i) {\n if (node = group0[i] || group1[i]) {\n merge[i] = node;\n }\n }\n }\n\n for (; j < m0; ++j) {\n merges[j] = groups0[j];\n }\n\n return new Selection(merges, this._parents);\n}\n", "export default function() {\n\n for (var groups = this._groups, j = -1, m = groups.length; ++j < m;) {\n for (var group = groups[j], i = group.length - 1, next = group[i], node; --i >= 0;) {\n if (node = group[i]) {\n if (next && node.compareDocumentPosition(next) ^ 4) next.parentNode.insertBefore(node, next);\n next = node;\n }\n }\n }\n\n return this;\n}\n", "import {Selection} from \"./index.js\";\n\nexport default function(compare) {\n if (!compare) compare = ascending;\n\n function compareNode(a, b) {\n return a && b ? compare(a.__data__, b.__data__) : !a - !b;\n }\n\n for (var groups = this._groups, m = groups.length, sortgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, sortgroup = sortgroups[j] = new Array(n), node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n sortgroup[i] = node;\n }\n }\n sortgroup.sort(compareNode);\n }\n\n return new Selection(sortgroups, this._parents).order();\n}\n\nfunction ascending(a, b) {\n return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;\n}\n", "export default function() {\n var callback = arguments[0];\n arguments[0] = this;\n callback.apply(null, arguments);\n return this;\n}\n", "export default function() {\n return Array.from(this);\n}\n", "export default function() {\n\n for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {\n for (var group = groups[j], i = 0, n = group.length; i < n; ++i) {\n var node = group[i];\n if (node) return node;\n }\n }\n\n return null;\n}\n", "export default function() {\n let size = 0;\n for (const node of this) ++size; // eslint-disable-line no-unused-vars\n return size;\n}\n", "export default function() {\n return !this.node();\n}\n", "export default function(callback) {\n\n for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {\n for (var group = groups[j], i = 0, n = group.length, node; i < n; ++i) {\n if (node = group[i]) callback.call(node, node.__data__, i, group);\n }\n }\n\n return this;\n}\n", "export var xhtml = \"http://www.w3.org/1999/xhtml\";\n\nexport default {\n svg: \"http://www.w3.org/2000/svg\",\n xhtml: xhtml,\n xlink: \"http://www.w3.org/1999/xlink\",\n xml: \"http://www.w3.org/XML/1998/namespace\",\n xmlns: \"http://www.w3.org/2000/xmlns/\"\n};\n", "import namespaces from \"./namespaces.js\";\n\nexport default function(name) {\n var prefix = name += \"\", i = prefix.indexOf(\":\");\n if (i >= 0 && (prefix = name.slice(0, i)) !== \"xmlns\") name = name.slice(i + 1);\n return namespaces.hasOwnProperty(prefix) ? {space: namespaces[prefix], local: name} : name; // eslint-disable-line no-prototype-builtins\n}\n", "import namespace from \"../namespace.js\";\n\nfunction attrRemove(name) {\n return function() {\n this.removeAttribute(name);\n };\n}\n\nfunction attrRemoveNS(fullname) {\n return function() {\n this.removeAttributeNS(fullname.space, fullname.local);\n };\n}\n\nfunction attrConstant(name, value) {\n return function() {\n this.setAttribute(name, value);\n };\n}\n\nfunction attrConstantNS(fullname, value) {\n return function() {\n this.setAttributeNS(fullname.space, fullname.local, value);\n };\n}\n\nfunction attrFunction(name, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) this.removeAttribute(name);\n else this.setAttribute(name, v);\n };\n}\n\nfunction attrFunctionNS(fullname, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) this.removeAttributeNS(fullname.space, fullname.local);\n else this.setAttributeNS(fullname.space, fullname.local, v);\n };\n}\n\nexport default function(name, value) {\n var fullname = namespace(name);\n\n if (arguments.length < 2) {\n var node = this.node();\n return fullname.local\n ? node.getAttributeNS(fullname.space, fullname.local)\n : node.getAttribute(fullname);\n }\n\n return this.each((value == null\n ? (fullname.local ? attrRemoveNS : attrRemove) : (typeof value === \"function\"\n ? (fullname.local ? attrFunctionNS : attrFunction)\n : (fullname.local ? attrConstantNS : attrConstant)))(fullname, value));\n}\n", "export default function(node) {\n return (node.ownerDocument && node.ownerDocument.defaultView) // node is a Node\n || (node.document && node) // node is a Window\n || node.defaultView; // node is a Document\n}\n", "import defaultView from \"../window.js\";\n\nfunction styleRemove(name) {\n return function() {\n this.style.removeProperty(name);\n };\n}\n\nfunction styleConstant(name, value, priority) {\n return function() {\n this.style.setProperty(name, value, priority);\n };\n}\n\nfunction styleFunction(name, value, priority) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) this.style.removeProperty(name);\n else this.style.setProperty(name, v, priority);\n };\n}\n\nexport default function(name, value, priority) {\n return arguments.length > 1\n ? this.each((value == null\n ? styleRemove : typeof value === \"function\"\n ? styleFunction\n : styleConstant)(name, value, priority == null ? \"\" : priority))\n : styleValue(this.node(), name);\n}\n\nexport function styleValue(node, name) {\n return node.style.getPropertyValue(name)\n || defaultView(node).getComputedStyle(node, null).getPropertyValue(name);\n}\n", "function propertyRemove(name) {\n return function() {\n delete this[name];\n };\n}\n\nfunction propertyConstant(name, value) {\n return function() {\n this[name] = value;\n };\n}\n\nfunction propertyFunction(name, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (v == null) delete this[name];\n else this[name] = v;\n };\n}\n\nexport default function(name, value) {\n return arguments.length > 1\n ? this.each((value == null\n ? propertyRemove : typeof value === \"function\"\n ? propertyFunction\n : propertyConstant)(name, value))\n : this.node()[name];\n}\n", "function classArray(string) {\n return string.trim().split(/^|\\s+/);\n}\n\nfunction classList(node) {\n return node.classList || new ClassList(node);\n}\n\nfunction ClassList(node) {\n this._node = node;\n this._names = classArray(node.getAttribute(\"class\") || \"\");\n}\n\nClassList.prototype = {\n add: function(name) {\n var i = this._names.indexOf(name);\n if (i < 0) {\n this._names.push(name);\n this._node.setAttribute(\"class\", this._names.join(\" \"));\n }\n },\n remove: function(name) {\n var i = this._names.indexOf(name);\n if (i >= 0) {\n this._names.splice(i, 1);\n this._node.setAttribute(\"class\", this._names.join(\" \"));\n }\n },\n contains: function(name) {\n return this._names.indexOf(name) >= 0;\n }\n};\n\nfunction classedAdd(node, names) {\n var list = classList(node), i = -1, n = names.length;\n while (++i < n) list.add(names[i]);\n}\n\nfunction classedRemove(node, names) {\n var list = classList(node), i = -1, n = names.length;\n while (++i < n) list.remove(names[i]);\n}\n\nfunction classedTrue(names) {\n return function() {\n classedAdd(this, names);\n };\n}\n\nfunction classedFalse(names) {\n return function() {\n classedRemove(this, names);\n };\n}\n\nfunction classedFunction(names, value) {\n return function() {\n (value.apply(this, arguments) ? classedAdd : classedRemove)(this, names);\n };\n}\n\nexport default function(name, value) {\n var names = classArray(name + \"\");\n\n if (arguments.length < 2) {\n var list = classList(this.node()), i = -1, n = names.length;\n while (++i < n) if (!list.contains(names[i])) return false;\n return true;\n }\n\n return this.each((typeof value === \"function\"\n ? classedFunction : value\n ? classedTrue\n : classedFalse)(names, value));\n}\n", "function textRemove() {\n this.textContent = \"\";\n}\n\nfunction textConstant(value) {\n return function() {\n this.textContent = value;\n };\n}\n\nfunction textFunction(value) {\n return function() {\n var v = value.apply(this, arguments);\n this.textContent = v == null ? \"\" : v;\n };\n}\n\nexport default function(value) {\n return arguments.length\n ? this.each(value == null\n ? textRemove : (typeof value === \"function\"\n ? textFunction\n : textConstant)(value))\n : this.node().textContent;\n}\n", "function htmlRemove() {\n this.innerHTML = \"\";\n}\n\nfunction htmlConstant(value) {\n return function() {\n this.innerHTML = value;\n };\n}\n\nfunction htmlFunction(value) {\n return function() {\n var v = value.apply(this, arguments);\n this.innerHTML = v == null ? \"\" : v;\n };\n}\n\nexport default function(value) {\n return arguments.length\n ? this.each(value == null\n ? htmlRemove : (typeof value === \"function\"\n ? htmlFunction\n : htmlConstant)(value))\n : this.node().innerHTML;\n}\n", "function raise() {\n if (this.nextSibling) this.parentNode.appendChild(this);\n}\n\nexport default function() {\n return this.each(raise);\n}\n", "function lower() {\n if (this.previousSibling) this.parentNode.insertBefore(this, this.parentNode.firstChild);\n}\n\nexport default function() {\n return this.each(lower);\n}\n", "import namespace from \"./namespace.js\";\nimport {xhtml} from \"./namespaces.js\";\n\nfunction creatorInherit(name) {\n return function() {\n var document = this.ownerDocument,\n uri = this.namespaceURI;\n return uri === xhtml && document.documentElement.namespaceURI === xhtml\n ? document.createElement(name)\n : document.createElementNS(uri, name);\n };\n}\n\nfunction creatorFixed(fullname) {\n return function() {\n return this.ownerDocument.createElementNS(fullname.space, fullname.local);\n };\n}\n\nexport default function(name) {\n var fullname = namespace(name);\n return (fullname.local\n ? creatorFixed\n : creatorInherit)(fullname);\n}\n", "import creator from \"../creator.js\";\n\nexport default function(name) {\n var create = typeof name === \"function\" ? name : creator(name);\n return this.select(function() {\n return this.appendChild(create.apply(this, arguments));\n });\n}\n", "import creator from \"../creator.js\";\nimport selector from \"../selector.js\";\n\nfunction constantNull() {\n return null;\n}\n\nexport default function(name, before) {\n var create = typeof name === \"function\" ? name : creator(name),\n select = before == null ? constantNull : typeof before === \"function\" ? before : selector(before);\n return this.select(function() {\n return this.insertBefore(create.apply(this, arguments), select.apply(this, arguments) || null);\n });\n}\n", "function remove() {\n var parent = this.parentNode;\n if (parent) parent.removeChild(this);\n}\n\nexport default function() {\n return this.each(remove);\n}\n", "function selection_cloneShallow() {\n var clone = this.cloneNode(false), parent = this.parentNode;\n return parent ? parent.insertBefore(clone, this.nextSibling) : clone;\n}\n\nfunction selection_cloneDeep() {\n var clone = this.cloneNode(true), parent = this.parentNode;\n return parent ? parent.insertBefore(clone, this.nextSibling) : clone;\n}\n\nexport default function(deep) {\n return this.select(deep ? selection_cloneDeep : selection_cloneShallow);\n}\n", "export default function(value) {\n return arguments.length\n ? this.property(\"__data__\", value)\n : this.node().__data__;\n}\n", "function contextListener(listener) {\n return function(event) {\n listener.call(this, event, this.__data__);\n };\n}\n\nfunction parseTypenames(typenames) {\n return typenames.trim().split(/^|\\s+/).map(function(t) {\n var name = \"\", i = t.indexOf(\".\");\n if (i >= 0) name = t.slice(i + 1), t = t.slice(0, i);\n return {type: t, name: name};\n });\n}\n\nfunction onRemove(typename) {\n return function() {\n var on = this.__on;\n if (!on) return;\n for (var j = 0, i = -1, m = on.length, o; j < m; ++j) {\n if (o = on[j], (!typename.type || o.type === typename.type) && o.name === typename.name) {\n this.removeEventListener(o.type, o.listener, o.options);\n } else {\n on[++i] = o;\n }\n }\n if (++i) on.length = i;\n else delete this.__on;\n };\n}\n\nfunction onAdd(typename, value, options) {\n return function() {\n var on = this.__on, o, listener = contextListener(value);\n if (on) for (var j = 0, m = on.length; j < m; ++j) {\n if ((o = on[j]).type === typename.type && o.name === typename.name) {\n this.removeEventListener(o.type, o.listener, o.options);\n this.addEventListener(o.type, o.listener = listener, o.options = options);\n o.value = value;\n return;\n }\n }\n this.addEventListener(typename.type, listener, options);\n o = {type: typename.type, name: typename.name, value: value, listener: listener, options: options};\n if (!on) this.__on = [o];\n else on.push(o);\n };\n}\n\nexport default function(typename, value, options) {\n var typenames = parseTypenames(typename + \"\"), i, n = typenames.length, t;\n\n if (arguments.length < 2) {\n var on = this.node().__on;\n if (on) for (var j = 0, m = on.length, o; j < m; ++j) {\n for (i = 0, o = on[j]; i < n; ++i) {\n if ((t = typenames[i]).type === o.type && t.name === o.name) {\n return o.value;\n }\n }\n }\n return;\n }\n\n on = value ? onAdd : onRemove;\n for (i = 0; i < n; ++i) this.each(on(typenames[i], value, options));\n return this;\n}\n", "import defaultView from \"../window.js\";\n\nfunction dispatchEvent(node, type, params) {\n var window = defaultView(node),\n event = window.CustomEvent;\n\n if (typeof event === \"function\") {\n event = new event(type, params);\n } else {\n event = window.document.createEvent(\"Event\");\n if (params) event.initEvent(type, params.bubbles, params.cancelable), event.detail = params.detail;\n else event.initEvent(type, false, false);\n }\n\n node.dispatchEvent(event);\n}\n\nfunction dispatchConstant(type, params) {\n return function() {\n return dispatchEvent(this, type, params);\n };\n}\n\nfunction dispatchFunction(type, params) {\n return function() {\n return dispatchEvent(this, type, params.apply(this, arguments));\n };\n}\n\nexport default function(type, params) {\n return this.each((typeof params === \"function\"\n ? dispatchFunction\n : dispatchConstant)(type, params));\n}\n", "export default function*() {\n for (var groups = this._groups, j = 0, m = groups.length; j < m; ++j) {\n for (var group = groups[j], i = 0, n = group.length, node; i < n; ++i) {\n if (node = group[i]) yield node;\n }\n }\n}\n", "import selection_select from \"./select.js\";\nimport selection_selectAll from \"./selectAll.js\";\nimport selection_selectChild from \"./selectChild.js\";\nimport selection_selectChildren from \"./selectChildren.js\";\nimport selection_filter from \"./filter.js\";\nimport selection_data from \"./data.js\";\nimport selection_enter from \"./enter.js\";\nimport selection_exit from \"./exit.js\";\nimport selection_join from \"./join.js\";\nimport selection_merge from \"./merge.js\";\nimport selection_order from \"./order.js\";\nimport selection_sort from \"./sort.js\";\nimport selection_call from \"./call.js\";\nimport selection_nodes from \"./nodes.js\";\nimport selection_node from \"./node.js\";\nimport selection_size from \"./size.js\";\nimport selection_empty from \"./empty.js\";\nimport selection_each from \"./each.js\";\nimport selection_attr from \"./attr.js\";\nimport selection_style from \"./style.js\";\nimport selection_property from \"./property.js\";\nimport selection_classed from \"./classed.js\";\nimport selection_text from \"./text.js\";\nimport selection_html from \"./html.js\";\nimport selection_raise from \"./raise.js\";\nimport selection_lower from \"./lower.js\";\nimport selection_append from \"./append.js\";\nimport selection_insert from \"./insert.js\";\nimport selection_remove from \"./remove.js\";\nimport selection_clone from \"./clone.js\";\nimport selection_datum from \"./datum.js\";\nimport selection_on from \"./on.js\";\nimport selection_dispatch from \"./dispatch.js\";\nimport selection_iterator from \"./iterator.js\";\n\nexport var root = [null];\n\nexport function Selection(groups, parents) {\n this._groups = groups;\n this._parents = parents;\n}\n\nfunction selection() {\n return new Selection([[document.documentElement]], root);\n}\n\nfunction selection_selection() {\n return this;\n}\n\nSelection.prototype = selection.prototype = {\n constructor: Selection,\n select: selection_select,\n selectAll: selection_selectAll,\n selectChild: selection_selectChild,\n selectChildren: selection_selectChildren,\n filter: selection_filter,\n data: selection_data,\n enter: selection_enter,\n exit: selection_exit,\n join: selection_join,\n merge: selection_merge,\n selection: selection_selection,\n order: selection_order,\n sort: selection_sort,\n call: selection_call,\n nodes: selection_nodes,\n node: selection_node,\n size: selection_size,\n empty: selection_empty,\n each: selection_each,\n attr: selection_attr,\n style: selection_style,\n property: selection_property,\n classed: selection_classed,\n text: selection_text,\n html: selection_html,\n raise: selection_raise,\n lower: selection_lower,\n append: selection_append,\n insert: selection_insert,\n remove: selection_remove,\n clone: selection_clone,\n datum: selection_datum,\n on: selection_on,\n dispatch: selection_dispatch,\n [Symbol.iterator]: selection_iterator\n};\n\nexport default selection;\n", "import {Selection, root} from \"./selection/index.js\";\n\nexport default function(selector) {\n return typeof selector === \"string\"\n ? new Selection([[document.querySelector(selector)]], [document.documentElement])\n : new Selection([[selector]], root);\n}\n", "import array from \"./array.js\";\nimport {Selection, root} from \"./selection/index.js\";\n\nexport default function(selector) {\n return typeof selector === \"string\"\n ? new Selection([document.querySelectorAll(selector)], [document.documentElement])\n : new Selection([array(selector)], root);\n}\n", "export default function(constructor, factory, prototype) {\n constructor.prototype = factory.prototype = prototype;\n prototype.constructor = constructor;\n}\n\nexport function extend(parent, definition) {\n var prototype = Object.create(parent.prototype);\n for (var key in definition) prototype[key] = definition[key];\n return prototype;\n}\n", "import define, {extend} from \"./define.js\";\n\nexport function Color() {}\n\nexport var darker = 0.7;\nexport var brighter = 1 / darker;\n\nvar reI = \"\\\\s*([+-]?\\\\d+)\\\\s*\",\n reN = \"\\\\s*([+-]?(?:\\\\d*\\\\.)?\\\\d+(?:[eE][+-]?\\\\d+)?)\\\\s*\",\n reP = \"\\\\s*([+-]?(?:\\\\d*\\\\.)?\\\\d+(?:[eE][+-]?\\\\d+)?)%\\\\s*\",\n reHex = /^#([0-9a-f]{3,8})$/,\n reRgbInteger = new RegExp(`^rgb\\\\(${reI},${reI},${reI}\\\\)$`),\n reRgbPercent = new RegExp(`^rgb\\\\(${reP},${reP},${reP}\\\\)$`),\n reRgbaInteger = new RegExp(`^rgba\\\\(${reI},${reI},${reI},${reN}\\\\)$`),\n reRgbaPercent = new RegExp(`^rgba\\\\(${reP},${reP},${reP},${reN}\\\\)$`),\n reHslPercent = new RegExp(`^hsl\\\\(${reN},${reP},${reP}\\\\)$`),\n reHslaPercent = new RegExp(`^hsla\\\\(${reN},${reP},${reP},${reN}\\\\)$`);\n\nvar named = {\n aliceblue: 0xf0f8ff,\n antiquewhite: 0xfaebd7,\n aqua: 0x00ffff,\n aquamarine: 0x7fffd4,\n azure: 0xf0ffff,\n beige: 0xf5f5dc,\n bisque: 0xffe4c4,\n black: 0x000000,\n blanchedalmond: 0xffebcd,\n blue: 0x0000ff,\n blueviolet: 0x8a2be2,\n brown: 0xa52a2a,\n burlywood: 0xdeb887,\n cadetblue: 0x5f9ea0,\n chartreuse: 0x7fff00,\n chocolate: 0xd2691e,\n coral: 0xff7f50,\n cornflowerblue: 0x6495ed,\n cornsilk: 0xfff8dc,\n crimson: 0xdc143c,\n cyan: 0x00ffff,\n darkblue: 0x00008b,\n darkcyan: 0x008b8b,\n darkgoldenrod: 0xb8860b,\n darkgray: 0xa9a9a9,\n darkgreen: 0x006400,\n darkgrey: 0xa9a9a9,\n darkkhaki: 0xbdb76b,\n darkmagenta: 0x8b008b,\n darkolivegreen: 0x556b2f,\n darkorange: 0xff8c00,\n darkorchid: 0x9932cc,\n darkred: 0x8b0000,\n darksalmon: 0xe9967a,\n darkseagreen: 0x8fbc8f,\n darkslateblue: 0x483d8b,\n darkslategray: 0x2f4f4f,\n darkslategrey: 0x2f4f4f,\n darkturquoise: 0x00ced1,\n darkviolet: 0x9400d3,\n deeppink: 0xff1493,\n deepskyblue: 0x00bfff,\n dimgray: 0x696969,\n dimgrey: 0x696969,\n dodgerblue: 0x1e90ff,\n firebrick: 0xb22222,\n floralwhite: 0xfffaf0,\n forestgreen: 0x228b22,\n fuchsia: 0xff00ff,\n gainsboro: 0xdcdcdc,\n ghostwhite: 0xf8f8ff,\n gold: 0xffd700,\n goldenrod: 0xdaa520,\n gray: 0x808080,\n green: 0x008000,\n greenyellow: 0xadff2f,\n grey: 0x808080,\n honeydew: 0xf0fff0,\n hotpink: 0xff69b4,\n indianred: 0xcd5c5c,\n indigo: 0x4b0082,\n ivory: 0xfffff0,\n khaki: 0xf0e68c,\n lavender: 0xe6e6fa,\n lavenderblush: 0xfff0f5,\n lawngreen: 0x7cfc00,\n lemonchiffon: 0xfffacd,\n lightblue: 0xadd8e6,\n lightcoral: 0xf08080,\n lightcyan: 0xe0ffff,\n lightgoldenrodyellow: 0xfafad2,\n lightgray: 0xd3d3d3,\n lightgreen: 0x90ee90,\n lightgrey: 0xd3d3d3,\n lightpink: 0xffb6c1,\n lightsalmon: 0xffa07a,\n lightseagreen: 0x20b2aa,\n lightskyblue: 0x87cefa,\n lightslategray: 0x778899,\n lightslategrey: 0x778899,\n lightsteelblue: 0xb0c4de,\n lightyellow: 0xffffe0,\n lime: 0x00ff00,\n limegreen: 0x32cd32,\n linen: 0xfaf0e6,\n magenta: 0xff00ff,\n maroon: 0x800000,\n mediumaquamarine: 0x66cdaa,\n mediumblue: 0x0000cd,\n mediumorchid: 0xba55d3,\n mediumpurple: 0x9370db,\n mediumseagreen: 0x3cb371,\n mediumslateblue: 0x7b68ee,\n mediumspringgreen: 0x00fa9a,\n mediumturquoise: 0x48d1cc,\n mediumvioletred: 0xc71585,\n midnightblue: 0x191970,\n mintcream: 0xf5fffa,\n mistyrose: 0xffe4e1,\n moccasin: 0xffe4b5,\n navajowhite: 0xffdead,\n navy: 0x000080,\n oldlace: 0xfdf5e6,\n olive: 0x808000,\n olivedrab: 0x6b8e23,\n orange: 0xffa500,\n orangered: 0xff4500,\n orchid: 0xda70d6,\n palegoldenrod: 0xeee8aa,\n palegreen: 0x98fb98,\n paleturquoise: 0xafeeee,\n palevioletred: 0xdb7093,\n papayawhip: 0xffefd5,\n peachpuff: 0xffdab9,\n peru: 0xcd853f,\n pink: 0xffc0cb,\n plum: 0xdda0dd,\n powderblue: 0xb0e0e6,\n purple: 0x800080,\n rebeccapurple: 0x663399,\n red: 0xff0000,\n rosybrown: 0xbc8f8f,\n royalblue: 0x4169e1,\n saddlebrown: 0x8b4513,\n salmon: 0xfa8072,\n sandybrown: 0xf4a460,\n seagreen: 0x2e8b57,\n seashell: 0xfff5ee,\n sienna: 0xa0522d,\n silver: 0xc0c0c0,\n skyblue: 0x87ceeb,\n slateblue: 0x6a5acd,\n slategray: 0x708090,\n slategrey: 0x708090,\n snow: 0xfffafa,\n springgreen: 0x00ff7f,\n steelblue: 0x4682b4,\n tan: 0xd2b48c,\n teal: 0x008080,\n thistle: 0xd8bfd8,\n tomato: 0xff6347,\n turquoise: 0x40e0d0,\n violet: 0xee82ee,\n wheat: 0xf5deb3,\n white: 0xffffff,\n whitesmoke: 0xf5f5f5,\n yellow: 0xffff00,\n yellowgreen: 0x9acd32\n};\n\ndefine(Color, color, {\n copy(channels) {\n return Object.assign(new this.constructor, this, channels);\n },\n displayable() {\n return this.rgb().displayable();\n },\n hex: color_formatHex, // Deprecated! Use color.formatHex.\n formatHex: color_formatHex,\n formatHex8: color_formatHex8,\n formatHsl: color_formatHsl,\n formatRgb: color_formatRgb,\n toString: color_formatRgb\n});\n\nfunction color_formatHex() {\n return this.rgb().formatHex();\n}\n\nfunction color_formatHex8() {\n return this.rgb().formatHex8();\n}\n\nfunction color_formatHsl() {\n return hslConvert(this).formatHsl();\n}\n\nfunction color_formatRgb() {\n return this.rgb().formatRgb();\n}\n\nexport default function color(format) {\n var m, l;\n format = (format + \"\").trim().toLowerCase();\n return (m = reHex.exec(format)) ? (l = m[1].length, m = parseInt(m[1], 16), l === 6 ? rgbn(m) // #ff0000\n : l === 3 ? new Rgb((m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), ((m & 0xf) << 4) | (m & 0xf), 1) // #f00\n : l === 8 ? rgba(m >> 24 & 0xff, m >> 16 & 0xff, m >> 8 & 0xff, (m & 0xff) / 0xff) // #ff000000\n : l === 4 ? rgba((m >> 12 & 0xf) | (m >> 8 & 0xf0), (m >> 8 & 0xf) | (m >> 4 & 0xf0), (m >> 4 & 0xf) | (m & 0xf0), (((m & 0xf) << 4) | (m & 0xf)) / 0xff) // #f000\n : null) // invalid hex\n : (m = reRgbInteger.exec(format)) ? new Rgb(m[1], m[2], m[3], 1) // rgb(255, 0, 0)\n : (m = reRgbPercent.exec(format)) ? new Rgb(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, 1) // rgb(100%, 0%, 0%)\n : (m = reRgbaInteger.exec(format)) ? rgba(m[1], m[2], m[3], m[4]) // rgba(255, 0, 0, 1)\n : (m = reRgbaPercent.exec(format)) ? rgba(m[1] * 255 / 100, m[2] * 255 / 100, m[3] * 255 / 100, m[4]) // rgb(100%, 0%, 0%, 1)\n : (m = reHslPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, 1) // hsl(120, 50%, 50%)\n : (m = reHslaPercent.exec(format)) ? hsla(m[1], m[2] / 100, m[3] / 100, m[4]) // hsla(120, 50%, 50%, 1)\n : named.hasOwnProperty(format) ? rgbn(named[format]) // eslint-disable-line no-prototype-builtins\n : format === \"transparent\" ? new Rgb(NaN, NaN, NaN, 0)\n : null;\n}\n\nfunction rgbn(n) {\n return new Rgb(n >> 16 & 0xff, n >> 8 & 0xff, n & 0xff, 1);\n}\n\nfunction rgba(r, g, b, a) {\n if (a <= 0) r = g = b = NaN;\n return new Rgb(r, g, b, a);\n}\n\nexport function rgbConvert(o) {\n if (!(o instanceof Color)) o = color(o);\n if (!o) return new Rgb;\n o = o.rgb();\n return new Rgb(o.r, o.g, o.b, o.opacity);\n}\n\nexport function rgb(r, g, b, opacity) {\n return arguments.length === 1 ? rgbConvert(r) : new Rgb(r, g, b, opacity == null ? 1 : opacity);\n}\n\nexport function Rgb(r, g, b, opacity) {\n this.r = +r;\n this.g = +g;\n this.b = +b;\n this.opacity = +opacity;\n}\n\ndefine(Rgb, rgb, extend(Color, {\n brighter(k) {\n k = k == null ? brighter : Math.pow(brighter, k);\n return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity);\n },\n darker(k) {\n k = k == null ? darker : Math.pow(darker, k);\n return new Rgb(this.r * k, this.g * k, this.b * k, this.opacity);\n },\n rgb() {\n return this;\n },\n clamp() {\n return new Rgb(clampi(this.r), clampi(this.g), clampi(this.b), clampa(this.opacity));\n },\n displayable() {\n return (-0.5 <= this.r && this.r < 255.5)\n && (-0.5 <= this.g && this.g < 255.5)\n && (-0.5 <= this.b && this.b < 255.5)\n && (0 <= this.opacity && this.opacity <= 1);\n },\n hex: rgb_formatHex, // Deprecated! Use color.formatHex.\n formatHex: rgb_formatHex,\n formatHex8: rgb_formatHex8,\n formatRgb: rgb_formatRgb,\n toString: rgb_formatRgb\n}));\n\nfunction rgb_formatHex() {\n return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}`;\n}\n\nfunction rgb_formatHex8() {\n return `#${hex(this.r)}${hex(this.g)}${hex(this.b)}${hex((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`;\n}\n\nfunction rgb_formatRgb() {\n const a = clampa(this.opacity);\n return `${a === 1 ? \"rgb(\" : \"rgba(\"}${clampi(this.r)}, ${clampi(this.g)}, ${clampi(this.b)}${a === 1 ? \")\" : `, ${a})`}`;\n}\n\nfunction clampa(opacity) {\n return isNaN(opacity) ? 1 : Math.max(0, Math.min(1, opacity));\n}\n\nfunction clampi(value) {\n return Math.max(0, Math.min(255, Math.round(value) || 0));\n}\n\nfunction hex(value) {\n value = clampi(value);\n return (value < 16 ? \"0\" : \"\") + value.toString(16);\n}\n\nfunction hsla(h, s, l, a) {\n if (a <= 0) h = s = l = NaN;\n else if (l <= 0 || l >= 1) h = s = NaN;\n else if (s <= 0) h = NaN;\n return new Hsl(h, s, l, a);\n}\n\nexport function hslConvert(o) {\n if (o instanceof Hsl) return new Hsl(o.h, o.s, o.l, o.opacity);\n if (!(o instanceof Color)) o = color(o);\n if (!o) return new Hsl;\n if (o instanceof Hsl) return o;\n o = o.rgb();\n var r = o.r / 255,\n g = o.g / 255,\n b = o.b / 255,\n min = Math.min(r, g, b),\n max = Math.max(r, g, b),\n h = NaN,\n s = max - min,\n l = (max + min) / 2;\n if (s) {\n if (r === max) h = (g - b) / s + (g < b) * 6;\n else if (g === max) h = (b - r) / s + 2;\n else h = (r - g) / s + 4;\n s /= l < 0.5 ? max + min : 2 - max - min;\n h *= 60;\n } else {\n s = l > 0 && l < 1 ? 0 : h;\n }\n return new Hsl(h, s, l, o.opacity);\n}\n\nexport function hsl(h, s, l, opacity) {\n return arguments.length === 1 ? hslConvert(h) : new Hsl(h, s, l, opacity == null ? 1 : opacity);\n}\n\nfunction Hsl(h, s, l, opacity) {\n this.h = +h;\n this.s = +s;\n this.l = +l;\n this.opacity = +opacity;\n}\n\ndefine(Hsl, hsl, extend(Color, {\n brighter(k) {\n k = k == null ? brighter : Math.pow(brighter, k);\n return new Hsl(this.h, this.s, this.l * k, this.opacity);\n },\n darker(k) {\n k = k == null ? darker : Math.pow(darker, k);\n return new Hsl(this.h, this.s, this.l * k, this.opacity);\n },\n rgb() {\n var h = this.h % 360 + (this.h < 0) * 360,\n s = isNaN(h) || isNaN(this.s) ? 0 : this.s,\n l = this.l,\n m2 = l + (l < 0.5 ? l : 1 - l) * s,\n m1 = 2 * l - m2;\n return new Rgb(\n hsl2rgb(h >= 240 ? h - 240 : h + 120, m1, m2),\n hsl2rgb(h, m1, m2),\n hsl2rgb(h < 120 ? h + 240 : h - 120, m1, m2),\n this.opacity\n );\n },\n clamp() {\n return new Hsl(clamph(this.h), clampt(this.s), clampt(this.l), clampa(this.opacity));\n },\n displayable() {\n return (0 <= this.s && this.s <= 1 || isNaN(this.s))\n && (0 <= this.l && this.l <= 1)\n && (0 <= this.opacity && this.opacity <= 1);\n },\n formatHsl() {\n const a = clampa(this.opacity);\n return `${a === 1 ? \"hsl(\" : \"hsla(\"}${clamph(this.h)}, ${clampt(this.s) * 100}%, ${clampt(this.l) * 100}%${a === 1 ? \")\" : `, ${a})`}`;\n }\n}));\n\nfunction clamph(value) {\n value = (value || 0) % 360;\n return value < 0 ? value + 360 : value;\n}\n\nfunction clampt(value) {\n return Math.max(0, Math.min(1, value || 0));\n}\n\n/* From FvD 13.37, CSS Color Module Level 3 */\nfunction hsl2rgb(h, m1, m2) {\n return (h < 60 ? m1 + (m2 - m1) * h / 60\n : h < 180 ? m2\n : h < 240 ? m1 + (m2 - m1) * (240 - h) / 60\n : m1) * 255;\n}\n", "export const radians = Math.PI / 180;\nexport const degrees = 180 / Math.PI;\n", "import define, {extend} from \"./define.js\";\nimport {Color, rgbConvert, Rgb} from \"./color.js\";\nimport {degrees, radians} from \"./math.js\";\n\n// https://observablehq.com/@mbostock/lab-and-rgb\nconst K = 18,\n Xn = 0.96422,\n Yn = 1,\n Zn = 0.82521,\n t0 = 4 / 29,\n t1 = 6 / 29,\n t2 = 3 * t1 * t1,\n t3 = t1 * t1 * t1;\n\nfunction labConvert(o) {\n if (o instanceof Lab) return new Lab(o.l, o.a, o.b, o.opacity);\n if (o instanceof Hcl) return hcl2lab(o);\n if (!(o instanceof Rgb)) o = rgbConvert(o);\n var r = rgb2lrgb(o.r),\n g = rgb2lrgb(o.g),\n b = rgb2lrgb(o.b),\n y = xyz2lab((0.2225045 * r + 0.7168786 * g + 0.0606169 * b) / Yn), x, z;\n if (r === g && g === b) x = z = y; else {\n x = xyz2lab((0.4360747 * r + 0.3850649 * g + 0.1430804 * b) / Xn);\n z = xyz2lab((0.0139322 * r + 0.0971045 * g + 0.7141733 * b) / Zn);\n }\n return new Lab(116 * y - 16, 500 * (x - y), 200 * (y - z), o.opacity);\n}\n\nexport function gray(l, opacity) {\n return new Lab(l, 0, 0, opacity == null ? 1 : opacity);\n}\n\nexport default function lab(l, a, b, opacity) {\n return arguments.length === 1 ? labConvert(l) : new Lab(l, a, b, opacity == null ? 1 : opacity);\n}\n\nexport function Lab(l, a, b, opacity) {\n this.l = +l;\n this.a = +a;\n this.b = +b;\n this.opacity = +opacity;\n}\n\ndefine(Lab, lab, extend(Color, {\n brighter(k) {\n return new Lab(this.l + K * (k == null ? 1 : k), this.a, this.b, this.opacity);\n },\n darker(k) {\n return new Lab(this.l - K * (k == null ? 1 : k), this.a, this.b, this.opacity);\n },\n rgb() {\n var y = (this.l + 16) / 116,\n x = isNaN(this.a) ? y : y + this.a / 500,\n z = isNaN(this.b) ? y : y - this.b / 200;\n x = Xn * lab2xyz(x);\n y = Yn * lab2xyz(y);\n z = Zn * lab2xyz(z);\n return new Rgb(\n lrgb2rgb( 3.1338561 * x - 1.6168667 * y - 0.4906146 * z),\n lrgb2rgb(-0.9787684 * x + 1.9161415 * y + 0.0334540 * z),\n lrgb2rgb( 0.0719453 * x - 0.2289914 * y + 1.4052427 * z),\n this.opacity\n );\n }\n}));\n\nfunction xyz2lab(t) {\n return t > t3 ? Math.pow(t, 1 / 3) : t / t2 + t0;\n}\n\nfunction lab2xyz(t) {\n return t > t1 ? t * t * t : t2 * (t - t0);\n}\n\nfunction lrgb2rgb(x) {\n return 255 * (x <= 0.0031308 ? 12.92 * x : 1.055 * Math.pow(x, 1 / 2.4) - 0.055);\n}\n\nfunction rgb2lrgb(x) {\n return (x /= 255) <= 0.04045 ? x / 12.92 : Math.pow((x + 0.055) / 1.055, 2.4);\n}\n\nfunction hclConvert(o) {\n if (o instanceof Hcl) return new Hcl(o.h, o.c, o.l, o.opacity);\n if (!(o instanceof Lab)) o = labConvert(o);\n if (o.a === 0 && o.b === 0) return new Hcl(NaN, 0 < o.l && o.l < 100 ? 0 : NaN, o.l, o.opacity);\n var h = Math.atan2(o.b, o.a) * degrees;\n return new Hcl(h < 0 ? h + 360 : h, Math.sqrt(o.a * o.a + o.b * o.b), o.l, o.opacity);\n}\n\nexport function lch(l, c, h, opacity) {\n return arguments.length === 1 ? hclConvert(l) : new Hcl(h, c, l, opacity == null ? 1 : opacity);\n}\n\nexport function hcl(h, c, l, opacity) {\n return arguments.length === 1 ? hclConvert(h) : new Hcl(h, c, l, opacity == null ? 1 : opacity);\n}\n\nexport function Hcl(h, c, l, opacity) {\n this.h = +h;\n this.c = +c;\n this.l = +l;\n this.opacity = +opacity;\n}\n\nfunction hcl2lab(o) {\n if (isNaN(o.h)) return new Lab(o.l, 0, 0, o.opacity);\n var h = o.h * radians;\n return new Lab(o.l, Math.cos(h) * o.c, Math.sin(h) * o.c, o.opacity);\n}\n\ndefine(Hcl, hcl, extend(Color, {\n brighter(k) {\n return new Hcl(this.h, this.c, this.l + K * (k == null ? 1 : k), this.opacity);\n },\n darker(k) {\n return new Hcl(this.h, this.c, this.l - K * (k == null ? 1 : k), this.opacity);\n },\n rgb() {\n return hcl2lab(this).rgb();\n }\n}));\n", "export default x => () => x;\n", "import constant from \"./constant.js\";\n\nfunction linear(a, d) {\n return function(t) {\n return a + t * d;\n };\n}\n\nfunction exponential(a, b, y) {\n return a = Math.pow(a, y), b = Math.pow(b, y) - a, y = 1 / y, function(t) {\n return Math.pow(a + t * b, y);\n };\n}\n\nexport function hue(a, b) {\n var d = b - a;\n return d ? linear(a, d > 180 || d < -180 ? d - 360 * Math.round(d / 360) : d) : constant(isNaN(a) ? b : a);\n}\n\nexport function gamma(y) {\n return (y = +y) === 1 ? nogamma : function(a, b) {\n return b - a ? exponential(a, b, y) : constant(isNaN(a) ? b : a);\n };\n}\n\nexport default function nogamma(a, b) {\n var d = b - a;\n return d ? linear(a, d) : constant(isNaN(a) ? b : a);\n}\n", "import {hcl as colorHcl} from \"d3-color\";\nimport color, {hue} from \"./color.js\";\n\nfunction hcl(hue) {\n return function(start, end) {\n var h = hue((start = colorHcl(start)).h, (end = colorHcl(end)).h),\n c = color(start.c, end.c),\n l = color(start.l, end.l),\n opacity = color(start.opacity, end.opacity);\n return function(t) {\n start.h = h(t);\n start.c = c(t);\n start.l = l(t);\n start.opacity = opacity(t);\n return start + \"\";\n };\n }\n}\n\nexport default hcl(hue);\nexport var hclLong = hcl(color);\n", "export function basis(t1, v0, v1, v2, v3) {\n var t2 = t1 * t1, t3 = t2 * t1;\n return ((1 - 3 * t1 + 3 * t2 - t3) * v0\n + (4 - 6 * t2 + 3 * t3) * v1\n + (1 + 3 * t1 + 3 * t2 - 3 * t3) * v2\n + t3 * v3) / 6;\n}\n\nexport default function(values) {\n var n = values.length - 1;\n return function(t) {\n var i = t <= 0 ? (t = 0) : t >= 1 ? (t = 1, n - 1) : Math.floor(t * n),\n v1 = values[i],\n v2 = values[i + 1],\n v0 = i > 0 ? values[i - 1] : 2 * v1 - v2,\n v3 = i < n - 1 ? values[i + 2] : 2 * v2 - v1;\n return basis((t - i / n) * n, v0, v1, v2, v3);\n };\n}\n", "import {basis} from \"./basis.js\";\n\nexport default function(values) {\n var n = values.length;\n return function(t) {\n var i = Math.floor(((t %= 1) < 0 ? ++t : t) * n),\n v0 = values[(i + n - 1) % n],\n v1 = values[i % n],\n v2 = values[(i + 1) % n],\n v3 = values[(i + 2) % n];\n return basis((t - i / n) * n, v0, v1, v2, v3);\n };\n}\n", "import {rgb as colorRgb} from \"d3-color\";\nimport basis from \"./basis.js\";\nimport basisClosed from \"./basisClosed.js\";\nimport nogamma, {gamma} from \"./color.js\";\n\nexport default (function rgbGamma(y) {\n var color = gamma(y);\n\n function rgb(start, end) {\n var r = color((start = colorRgb(start)).r, (end = colorRgb(end)).r),\n g = color(start.g, end.g),\n b = color(start.b, end.b),\n opacity = nogamma(start.opacity, end.opacity);\n return function(t) {\n start.r = r(t);\n start.g = g(t);\n start.b = b(t);\n start.opacity = opacity(t);\n return start + \"\";\n };\n }\n\n rgb.gamma = rgbGamma;\n\n return rgb;\n})(1);\n\nfunction rgbSpline(spline) {\n return function(colors) {\n var n = colors.length,\n r = new Array(n),\n g = new Array(n),\n b = new Array(n),\n i, color;\n for (i = 0; i < n; ++i) {\n color = colorRgb(colors[i]);\n r[i] = color.r || 0;\n g[i] = color.g || 0;\n b[i] = color.b || 0;\n }\n r = spline(r);\n g = spline(g);\n b = spline(b);\n color.opacity = 1;\n return function(t) {\n color.r = r(t);\n color.g = g(t);\n color.b = b(t);\n return color + \"\";\n };\n };\n}\n\nexport var rgbBasis = rgbSpline(basis);\nexport var rgbBasisClosed = rgbSpline(basisClosed);\n", "export default function(a, b) {\n if (!b) b = [];\n var n = a ? Math.min(b.length, a.length) : 0,\n c = b.slice(),\n i;\n return function(t) {\n for (i = 0; i < n; ++i) c[i] = a[i] * (1 - t) + b[i] * t;\n return c;\n };\n}\n\nexport function isNumberArray(x) {\n return ArrayBuffer.isView(x) && !(x instanceof DataView);\n}\n", "import value from \"./value.js\";\nimport numberArray, {isNumberArray} from \"./numberArray.js\";\n\nexport default function(a, b) {\n return (isNumberArray(b) ? numberArray : genericArray)(a, b);\n}\n\nexport function genericArray(a, b) {\n var nb = b ? b.length : 0,\n na = a ? Math.min(nb, a.length) : 0,\n x = new Array(na),\n c = new Array(nb),\n i;\n\n for (i = 0; i < na; ++i) x[i] = value(a[i], b[i]);\n for (; i < nb; ++i) c[i] = b[i];\n\n return function(t) {\n for (i = 0; i < na; ++i) c[i] = x[i](t);\n return c;\n };\n}\n", "export default function(a, b) {\n var d = new Date;\n return a = +a, b = +b, function(t) {\n return d.setTime(a * (1 - t) + b * t), d;\n };\n}\n", "export default function(a, b) {\n return a = +a, b = +b, function(t) {\n return a * (1 - t) + b * t;\n };\n}\n", "import value from \"./value.js\";\n\nexport default function(a, b) {\n var i = {},\n c = {},\n k;\n\n if (a === null || typeof a !== \"object\") a = {};\n if (b === null || typeof b !== \"object\") b = {};\n\n for (k in b) {\n if (k in a) {\n i[k] = value(a[k], b[k]);\n } else {\n c[k] = b[k];\n }\n }\n\n return function(t) {\n for (k in i) c[k] = i[k](t);\n return c;\n };\n}\n", "import number from \"./number.js\";\n\nvar reA = /[-+]?(?:\\d+\\.?\\d*|\\.?\\d+)(?:[eE][-+]?\\d+)?/g,\n reB = new RegExp(reA.source, \"g\");\n\nfunction zero(b) {\n return function() {\n return b;\n };\n}\n\nfunction one(b) {\n return function(t) {\n return b(t) + \"\";\n };\n}\n\nexport default function(a, b) {\n var bi = reA.lastIndex = reB.lastIndex = 0, // scan index for next number in b\n am, // current match in a\n bm, // current match in b\n bs, // string preceding current number in b, if any\n i = -1, // index in s\n s = [], // string constants and placeholders\n q = []; // number interpolators\n\n // Coerce inputs to strings.\n a = a + \"\", b = b + \"\";\n\n // Interpolate pairs of numbers in a & b.\n while ((am = reA.exec(a))\n && (bm = reB.exec(b))) {\n if ((bs = bm.index) > bi) { // a string precedes the next number in b\n bs = b.slice(bi, bs);\n if (s[i]) s[i] += bs; // coalesce with previous string\n else s[++i] = bs;\n }\n if ((am = am[0]) === (bm = bm[0])) { // numbers in a & b match\n if (s[i]) s[i] += bm; // coalesce with previous string\n else s[++i] = bm;\n } else { // interpolate non-matching numbers\n s[++i] = null;\n q.push({i: i, x: number(am, bm)});\n }\n bi = reB.lastIndex;\n }\n\n // Add remains of b.\n if (bi < b.length) {\n bs = b.slice(bi);\n if (s[i]) s[i] += bs; // coalesce with previous string\n else s[++i] = bs;\n }\n\n // Special optimization for only a single match.\n // Otherwise, interpolate each of the numbers and rejoin the string.\n return s.length < 2 ? (q[0]\n ? one(q[0].x)\n : zero(b))\n : (b = q.length, function(t) {\n for (var i = 0, o; i < b; ++i) s[(o = q[i]).i] = o.x(t);\n return s.join(\"\");\n });\n}\n", "import {color} from \"d3-color\";\nimport rgb from \"./rgb.js\";\nimport {genericArray} from \"./array.js\";\nimport date from \"./date.js\";\nimport number from \"./number.js\";\nimport object from \"./object.js\";\nimport string from \"./string.js\";\nimport constant from \"./constant.js\";\nimport numberArray, {isNumberArray} from \"./numberArray.js\";\n\nexport default function(a, b) {\n var t = typeof b, c;\n return b == null || t === \"boolean\" ? constant(b)\n : (t === \"number\" ? number\n : t === \"string\" ? ((c = color(b)) ? (b = c, rgb) : string)\n : b instanceof color ? rgb\n : b instanceof Date ? date\n : isNumberArray(b) ? numberArray\n : Array.isArray(b) ? genericArray\n : typeof b.valueOf !== \"function\" && typeof b.toString !== \"function\" || isNaN(b) ? object\n : number)(a, b);\n}\n", "export default function(a, b) {\n return a = +a, b = +b, function(t) {\n return Math.round(a * (1 - t) + b * t);\n };\n}\n", "var degrees = 180 / Math.PI;\n\nexport var identity = {\n translateX: 0,\n translateY: 0,\n rotate: 0,\n skewX: 0,\n scaleX: 1,\n scaleY: 1\n};\n\nexport default function(a, b, c, d, e, f) {\n var scaleX, scaleY, skewX;\n if (scaleX = Math.sqrt(a * a + b * b)) a /= scaleX, b /= scaleX;\n if (skewX = a * c + b * d) c -= a * skewX, d -= b * skewX;\n if (scaleY = Math.sqrt(c * c + d * d)) c /= scaleY, d /= scaleY, skewX /= scaleY;\n if (a * d < b * c) a = -a, b = -b, skewX = -skewX, scaleX = -scaleX;\n return {\n translateX: e,\n translateY: f,\n rotate: Math.atan2(b, a) * degrees,\n skewX: Math.atan(skewX) * degrees,\n scaleX: scaleX,\n scaleY: scaleY\n };\n}\n", "import decompose, {identity} from \"./decompose.js\";\n\nvar svgNode;\n\n/* eslint-disable no-undef */\nexport function parseCss(value) {\n const m = new (typeof DOMMatrix === \"function\" ? DOMMatrix : WebKitCSSMatrix)(value + \"\");\n return m.isIdentity ? identity : decompose(m.a, m.b, m.c, m.d, m.e, m.f);\n}\n\nexport function parseSvg(value) {\n if (value == null) return identity;\n if (!svgNode) svgNode = document.createElementNS(\"http://www.w3.org/2000/svg\", \"g\");\n svgNode.setAttribute(\"transform\", value);\n if (!(value = svgNode.transform.baseVal.consolidate())) return identity;\n value = value.matrix;\n return decompose(value.a, value.b, value.c, value.d, value.e, value.f);\n}\n", "import number from \"../number.js\";\nimport {parseCss, parseSvg} from \"./parse.js\";\n\nfunction interpolateTransform(parse, pxComma, pxParen, degParen) {\n\n function pop(s) {\n return s.length ? s.pop() + \" \" : \"\";\n }\n\n function translate(xa, ya, xb, yb, s, q) {\n if (xa !== xb || ya !== yb) {\n var i = s.push(\"translate(\", null, pxComma, null, pxParen);\n q.push({i: i - 4, x: number(xa, xb)}, {i: i - 2, x: number(ya, yb)});\n } else if (xb || yb) {\n s.push(\"translate(\" + xb + pxComma + yb + pxParen);\n }\n }\n\n function rotate(a, b, s, q) {\n if (a !== b) {\n if (a - b > 180) b += 360; else if (b - a > 180) a += 360; // shortest path\n q.push({i: s.push(pop(s) + \"rotate(\", null, degParen) - 2, x: number(a, b)});\n } else if (b) {\n s.push(pop(s) + \"rotate(\" + b + degParen);\n }\n }\n\n function skewX(a, b, s, q) {\n if (a !== b) {\n q.push({i: s.push(pop(s) + \"skewX(\", null, degParen) - 2, x: number(a, b)});\n } else if (b) {\n s.push(pop(s) + \"skewX(\" + b + degParen);\n }\n }\n\n function scale(xa, ya, xb, yb, s, q) {\n if (xa !== xb || ya !== yb) {\n var i = s.push(pop(s) + \"scale(\", null, \",\", null, \")\");\n q.push({i: i - 4, x: number(xa, xb)}, {i: i - 2, x: number(ya, yb)});\n } else if (xb !== 1 || yb !== 1) {\n s.push(pop(s) + \"scale(\" + xb + \",\" + yb + \")\");\n }\n }\n\n return function(a, b) {\n var s = [], // string constants and placeholders\n q = []; // number interpolators\n a = parse(a), b = parse(b);\n translate(a.translateX, a.translateY, b.translateX, b.translateY, s, q);\n rotate(a.rotate, b.rotate, s, q);\n skewX(a.skewX, b.skewX, s, q);\n scale(a.scaleX, a.scaleY, b.scaleX, b.scaleY, s, q);\n a = b = null; // gc\n return function(t) {\n var i = -1, n = q.length, o;\n while (++i < n) s[(o = q[i]).i] = o.x(t);\n return s.join(\"\");\n };\n };\n}\n\nexport var interpolateTransformCss = interpolateTransform(parseCss, \"px, \", \"px)\", \"deg)\");\nexport var interpolateTransformSvg = interpolateTransform(parseSvg, \", \", \")\", \")\");\n", "export function initRange(domain, range) {\n switch (arguments.length) {\n case 0: break;\n case 1: this.range(domain); break;\n default: this.range(range).domain(domain); break;\n }\n return this;\n}\n\nexport function initInterpolator(domain, interpolator) {\n switch (arguments.length) {\n case 0: break;\n case 1: {\n if (typeof domain === \"function\") this.interpolator(domain);\n else this.range(domain);\n break;\n }\n default: {\n this.domain(domain);\n if (typeof interpolator === \"function\") this.interpolator(interpolator);\n else this.range(interpolator);\n break;\n }\n }\n return this;\n}\n", "import {InternMap} from \"d3-array\";\nimport {initRange} from \"./init.js\";\n\nexport const implicit = Symbol(\"implicit\");\n\nexport default function ordinal() {\n var index = new InternMap(),\n domain = [],\n range = [],\n unknown = implicit;\n\n function scale(d) {\n let i = index.get(d);\n if (i === undefined) {\n if (unknown !== implicit) return unknown;\n index.set(d, i = domain.push(d) - 1);\n }\n return range[i % range.length];\n }\n\n scale.domain = function(_) {\n if (!arguments.length) return domain.slice();\n domain = [], index = new InternMap();\n for (const value of _) {\n if (index.has(value)) continue;\n index.set(value, domain.push(value) - 1);\n }\n return scale;\n };\n\n scale.range = function(_) {\n return arguments.length ? (range = Array.from(_), scale) : range.slice();\n };\n\n scale.unknown = function(_) {\n return arguments.length ? (unknown = _, scale) : unknown;\n };\n\n scale.copy = function() {\n return ordinal(domain, range).unknown(unknown);\n };\n\n initRange.apply(scale, arguments);\n\n return scale;\n}\n", "import {range as sequence} from \"d3-array\";\nimport {initRange} from \"./init.js\";\nimport ordinal from \"./ordinal.js\";\n\nexport default function band() {\n var scale = ordinal().unknown(undefined),\n domain = scale.domain,\n ordinalRange = scale.range,\n r0 = 0,\n r1 = 1,\n step,\n bandwidth,\n round = false,\n paddingInner = 0,\n paddingOuter = 0,\n align = 0.5;\n\n delete scale.unknown;\n\n function rescale() {\n var n = domain().length,\n reverse = r1 < r0,\n start = reverse ? r1 : r0,\n stop = reverse ? r0 : r1;\n step = (stop - start) / Math.max(1, n - paddingInner + paddingOuter * 2);\n if (round) step = Math.floor(step);\n start += (stop - start - step * (n - paddingInner)) * align;\n bandwidth = step * (1 - paddingInner);\n if (round) start = Math.round(start), bandwidth = Math.round(bandwidth);\n var values = sequence(n).map(function(i) { return start + step * i; });\n return ordinalRange(reverse ? values.reverse() : values);\n }\n\n scale.domain = function(_) {\n return arguments.length ? (domain(_), rescale()) : domain();\n };\n\n scale.range = function(_) {\n return arguments.length ? ([r0, r1] = _, r0 = +r0, r1 = +r1, rescale()) : [r0, r1];\n };\n\n scale.rangeRound = function(_) {\n return [r0, r1] = _, r0 = +r0, r1 = +r1, round = true, rescale();\n };\n\n scale.bandwidth = function() {\n return bandwidth;\n };\n\n scale.step = function() {\n return step;\n };\n\n scale.round = function(_) {\n return arguments.length ? (round = !!_, rescale()) : round;\n };\n\n scale.padding = function(_) {\n return arguments.length ? (paddingInner = Math.min(1, paddingOuter = +_), rescale()) : paddingInner;\n };\n\n scale.paddingInner = function(_) {\n return arguments.length ? (paddingInner = Math.min(1, _), rescale()) : paddingInner;\n };\n\n scale.paddingOuter = function(_) {\n return arguments.length ? (paddingOuter = +_, rescale()) : paddingOuter;\n };\n\n scale.align = function(_) {\n return arguments.length ? (align = Math.max(0, Math.min(1, _)), rescale()) : align;\n };\n\n scale.copy = function() {\n return band(domain(), [r0, r1])\n .round(round)\n .paddingInner(paddingInner)\n .paddingOuter(paddingOuter)\n .align(align);\n };\n\n return initRange.apply(rescale(), arguments);\n}\n\nfunction pointish(scale) {\n var copy = scale.copy;\n\n scale.padding = scale.paddingOuter;\n delete scale.paddingInner;\n delete scale.paddingOuter;\n\n scale.copy = function() {\n return pointish(copy());\n };\n\n return scale;\n}\n\nexport function point() {\n return pointish(band.apply(null, arguments).paddingInner(1));\n}\n", "export default function constants(x) {\n return function() {\n return x;\n };\n}\n", "export default function number(x) {\n return +x;\n}\n", "import {bisect} from \"d3-array\";\nimport {interpolate as interpolateValue, interpolateNumber, interpolateRound} from \"d3-interpolate\";\nimport constant from \"./constant.js\";\nimport number from \"./number.js\";\n\nvar unit = [0, 1];\n\nexport function identity(x) {\n return x;\n}\n\nfunction normalize(a, b) {\n return (b -= (a = +a))\n ? function(x) { return (x - a) / b; }\n : constant(isNaN(b) ? NaN : 0.5);\n}\n\nfunction clamper(a, b) {\n var t;\n if (a > b) t = a, a = b, b = t;\n return function(x) { return Math.max(a, Math.min(b, x)); };\n}\n\n// normalize(a, b)(x) takes a domain value x in [a,b] and returns the corresponding parameter t in [0,1].\n// interpolate(a, b)(t) takes a parameter t in [0,1] and returns the corresponding range value x in [a,b].\nfunction bimap(domain, range, interpolate) {\n var d0 = domain[0], d1 = domain[1], r0 = range[0], r1 = range[1];\n if (d1 < d0) d0 = normalize(d1, d0), r0 = interpolate(r1, r0);\n else d0 = normalize(d0, d1), r0 = interpolate(r0, r1);\n return function(x) { return r0(d0(x)); };\n}\n\nfunction polymap(domain, range, interpolate) {\n var j = Math.min(domain.length, range.length) - 1,\n d = new Array(j),\n r = new Array(j),\n i = -1;\n\n // Reverse descending domains.\n if (domain[j] < domain[0]) {\n domain = domain.slice().reverse();\n range = range.slice().reverse();\n }\n\n while (++i < j) {\n d[i] = normalize(domain[i], domain[i + 1]);\n r[i] = interpolate(range[i], range[i + 1]);\n }\n\n return function(x) {\n var i = bisect(domain, x, 1, j) - 1;\n return r[i](d[i](x));\n };\n}\n\nexport function copy(source, target) {\n return target\n .domain(source.domain())\n .range(source.range())\n .interpolate(source.interpolate())\n .clamp(source.clamp())\n .unknown(source.unknown());\n}\n\nexport function transformer() {\n var domain = unit,\n range = unit,\n interpolate = interpolateValue,\n transform,\n untransform,\n unknown,\n clamp = identity,\n piecewise,\n output,\n input;\n\n function rescale() {\n var n = Math.min(domain.length, range.length);\n if (clamp !== identity) clamp = clamper(domain[0], domain[n - 1]);\n piecewise = n > 2 ? polymap : bimap;\n output = input = null;\n return scale;\n }\n\n function scale(x) {\n return x == null || isNaN(x = +x) ? unknown : (output || (output = piecewise(domain.map(transform), range, interpolate)))(transform(clamp(x)));\n }\n\n scale.invert = function(y) {\n return clamp(untransform((input || (input = piecewise(range, domain.map(transform), interpolateNumber)))(y)));\n };\n\n scale.domain = function(_) {\n return arguments.length ? (domain = Array.from(_, number), rescale()) : domain.slice();\n };\n\n scale.range = function(_) {\n return arguments.length ? (range = Array.from(_), rescale()) : range.slice();\n };\n\n scale.rangeRound = function(_) {\n return range = Array.from(_), interpolate = interpolateRound, rescale();\n };\n\n scale.clamp = function(_) {\n return arguments.length ? (clamp = _ ? true : identity, rescale()) : clamp !== identity;\n };\n\n scale.interpolate = function(_) {\n return arguments.length ? (interpolate = _, rescale()) : interpolate;\n };\n\n scale.unknown = function(_) {\n return arguments.length ? (unknown = _, scale) : unknown;\n };\n\n return function(t, u) {\n transform = t, untransform = u;\n return rescale();\n };\n}\n\nexport default function continuous() {\n return transformer()(identity, identity);\n}\n", "export default function(x) {\n return Math.abs(x = Math.round(x)) >= 1e21\n ? x.toLocaleString(\"en\").replace(/,/g, \"\")\n : x.toString(10);\n}\n\n// Computes the decimal coefficient and exponent of the specified number x with\n// significant digits p, where x is positive and p is in [1, 21] or undefined.\n// For example, formatDecimalParts(1.23) returns [\"123\", 0].\nexport function formatDecimalParts(x, p) {\n if ((i = (x = p ? x.toExponential(p - 1) : x.toExponential()).indexOf(\"e\")) < 0) return null; // NaN, \u00B1Infinity\n var i, coefficient = x.slice(0, i);\n\n // The string returned by toExponential either has the form \\d\\.\\d+e[-+]\\d+\n // (e.g., 1.2e+3) or the form \\de[-+]\\d+ (e.g., 1e+3).\n return [\n coefficient.length > 1 ? coefficient[0] + coefficient.slice(2) : coefficient,\n +x.slice(i + 1)\n ];\n}\n", "import {formatDecimalParts} from \"./formatDecimal.js\";\n\nexport default function(x) {\n return x = formatDecimalParts(Math.abs(x)), x ? x[1] : NaN;\n}\n", "export default function(grouping, thousands) {\n return function(value, width) {\n var i = value.length,\n t = [],\n j = 0,\n g = grouping[0],\n length = 0;\n\n while (i > 0 && g > 0) {\n if (length + g + 1 > width) g = Math.max(1, width - length);\n t.push(value.substring(i -= g, i + g));\n if ((length += g + 1) > width) break;\n g = grouping[j = (j + 1) % grouping.length];\n }\n\n return t.reverse().join(thousands);\n };\n}\n", "export default function(numerals) {\n return function(value) {\n return value.replace(/[0-9]/g, function(i) {\n return numerals[+i];\n });\n };\n}\n", "// [[fill]align][sign][symbol][0][width][,][.precision][~][type]\nvar re = /^(?:(.)?([<>=^]))?([+\\-( ])?([$#])?(0)?(\\d+)?(,)?(\\.\\d+)?(~)?([a-z%])?$/i;\n\nexport default function formatSpecifier(specifier) {\n if (!(match = re.exec(specifier))) throw new Error(\"invalid format: \" + specifier);\n var match;\n return new FormatSpecifier({\n fill: match[1],\n align: match[2],\n sign: match[3],\n symbol: match[4],\n zero: match[5],\n width: match[6],\n comma: match[7],\n precision: match[8] && match[8].slice(1),\n trim: match[9],\n type: match[10]\n });\n}\n\nformatSpecifier.prototype = FormatSpecifier.prototype; // instanceof\n\nexport function FormatSpecifier(specifier) {\n this.fill = specifier.fill === undefined ? \" \" : specifier.fill + \"\";\n this.align = specifier.align === undefined ? \">\" : specifier.align + \"\";\n this.sign = specifier.sign === undefined ? \"-\" : specifier.sign + \"\";\n this.symbol = specifier.symbol === undefined ? \"\" : specifier.symbol + \"\";\n this.zero = !!specifier.zero;\n this.width = specifier.width === undefined ? undefined : +specifier.width;\n this.comma = !!specifier.comma;\n this.precision = specifier.precision === undefined ? undefined : +specifier.precision;\n this.trim = !!specifier.trim;\n this.type = specifier.type === undefined ? \"\" : specifier.type + \"\";\n}\n\nFormatSpecifier.prototype.toString = function() {\n return this.fill\n + this.align\n + this.sign\n + this.symbol\n + (this.zero ? \"0\" : \"\")\n + (this.width === undefined ? \"\" : Math.max(1, this.width | 0))\n + (this.comma ? \",\" : \"\")\n + (this.precision === undefined ? \"\" : \".\" + Math.max(0, this.precision | 0))\n + (this.trim ? \"~\" : \"\")\n + this.type;\n};\n", "// Trims insignificant zeros, e.g., replaces 1.2000k with 1.2k.\nexport default function(s) {\n out: for (var n = s.length, i = 1, i0 = -1, i1; i < n; ++i) {\n switch (s[i]) {\n case \".\": i0 = i1 = i; break;\n case \"0\": if (i0 === 0) i0 = i; i1 = i; break;\n default: if (!+s[i]) break out; if (i0 > 0) i0 = 0; break;\n }\n }\n return i0 > 0 ? s.slice(0, i0) + s.slice(i1 + 1) : s;\n}\n", "import {formatDecimalParts} from \"./formatDecimal.js\";\n\nexport var prefixExponent;\n\nexport default function(x, p) {\n var d = formatDecimalParts(x, p);\n if (!d) return x + \"\";\n var coefficient = d[0],\n exponent = d[1],\n i = exponent - (prefixExponent = Math.max(-8, Math.min(8, Math.floor(exponent / 3))) * 3) + 1,\n n = coefficient.length;\n return i === n ? coefficient\n : i > n ? coefficient + new Array(i - n + 1).join(\"0\")\n : i > 0 ? coefficient.slice(0, i) + \".\" + coefficient.slice(i)\n : \"0.\" + new Array(1 - i).join(\"0\") + formatDecimalParts(x, Math.max(0, p + i - 1))[0]; // less than 1y!\n}\n", "import {formatDecimalParts} from \"./formatDecimal.js\";\n\nexport default function(x, p) {\n var d = formatDecimalParts(x, p);\n if (!d) return x + \"\";\n var coefficient = d[0],\n exponent = d[1];\n return exponent < 0 ? \"0.\" + new Array(-exponent).join(\"0\") + coefficient\n : coefficient.length > exponent + 1 ? coefficient.slice(0, exponent + 1) + \".\" + coefficient.slice(exponent + 1)\n : coefficient + new Array(exponent - coefficient.length + 2).join(\"0\");\n}\n", "import formatDecimal from \"./formatDecimal.js\";\nimport formatPrefixAuto from \"./formatPrefixAuto.js\";\nimport formatRounded from \"./formatRounded.js\";\n\nexport default {\n \"%\": (x, p) => (x * 100).toFixed(p),\n \"b\": (x) => Math.round(x).toString(2),\n \"c\": (x) => x + \"\",\n \"d\": formatDecimal,\n \"e\": (x, p) => x.toExponential(p),\n \"f\": (x, p) => x.toFixed(p),\n \"g\": (x, p) => x.toPrecision(p),\n \"o\": (x) => Math.round(x).toString(8),\n \"p\": (x, p) => formatRounded(x * 100, p),\n \"r\": formatRounded,\n \"s\": formatPrefixAuto,\n \"X\": (x) => Math.round(x).toString(16).toUpperCase(),\n \"x\": (x) => Math.round(x).toString(16)\n};\n", "export default function(x) {\n return x;\n}\n", "import exponent from \"./exponent.js\";\nimport formatGroup from \"./formatGroup.js\";\nimport formatNumerals from \"./formatNumerals.js\";\nimport formatSpecifier from \"./formatSpecifier.js\";\nimport formatTrim from \"./formatTrim.js\";\nimport formatTypes from \"./formatTypes.js\";\nimport {prefixExponent} from \"./formatPrefixAuto.js\";\nimport identity from \"./identity.js\";\n\nvar map = Array.prototype.map,\n prefixes = [\"y\",\"z\",\"a\",\"f\",\"p\",\"n\",\"\u00B5\",\"m\",\"\",\"k\",\"M\",\"G\",\"T\",\"P\",\"E\",\"Z\",\"Y\"];\n\nexport default function(locale) {\n var group = locale.grouping === undefined || locale.thousands === undefined ? identity : formatGroup(map.call(locale.grouping, Number), locale.thousands + \"\"),\n currencyPrefix = locale.currency === undefined ? \"\" : locale.currency[0] + \"\",\n currencySuffix = locale.currency === undefined ? \"\" : locale.currency[1] + \"\",\n decimal = locale.decimal === undefined ? \".\" : locale.decimal + \"\",\n numerals = locale.numerals === undefined ? identity : formatNumerals(map.call(locale.numerals, String)),\n percent = locale.percent === undefined ? \"%\" : locale.percent + \"\",\n minus = locale.minus === undefined ? \"\u2212\" : locale.minus + \"\",\n nan = locale.nan === undefined ? \"NaN\" : locale.nan + \"\";\n\n function newFormat(specifier) {\n specifier = formatSpecifier(specifier);\n\n var fill = specifier.fill,\n align = specifier.align,\n sign = specifier.sign,\n symbol = specifier.symbol,\n zero = specifier.zero,\n width = specifier.width,\n comma = specifier.comma,\n precision = specifier.precision,\n trim = specifier.trim,\n type = specifier.type;\n\n // The \"n\" type is an alias for \",g\".\n if (type === \"n\") comma = true, type = \"g\";\n\n // The \"\" type, and any invalid type, is an alias for \".12~g\".\n else if (!formatTypes[type]) precision === undefined && (precision = 12), trim = true, type = \"g\";\n\n // If zero fill is specified, padding goes after sign and before digits.\n if (zero || (fill === \"0\" && align === \"=\")) zero = true, fill = \"0\", align = \"=\";\n\n // Compute the prefix and suffix.\n // For SI-prefix, the suffix is lazily computed.\n var prefix = symbol === \"$\" ? currencyPrefix : symbol === \"#\" && /[boxX]/.test(type) ? \"0\" + type.toLowerCase() : \"\",\n suffix = symbol === \"$\" ? currencySuffix : /[%p]/.test(type) ? percent : \"\";\n\n // What format function should we use?\n // Is this an integer type?\n // Can this type generate exponential notation?\n var formatType = formatTypes[type],\n maybeSuffix = /[defgprs%]/.test(type);\n\n // Set the default precision if not specified,\n // or clamp the specified precision to the supported range.\n // For significant precision, it must be in [1, 21].\n // For fixed precision, it must be in [0, 20].\n precision = precision === undefined ? 6\n : /[gprs]/.test(type) ? Math.max(1, Math.min(21, precision))\n : Math.max(0, Math.min(20, precision));\n\n function format(value) {\n var valuePrefix = prefix,\n valueSuffix = suffix,\n i, n, c;\n\n if (type === \"c\") {\n valueSuffix = formatType(value) + valueSuffix;\n value = \"\";\n } else {\n value = +value;\n\n // Determine the sign. -0 is not less than 0, but 1 / -0 is!\n var valueNegative = value < 0 || 1 / value < 0;\n\n // Perform the initial formatting.\n value = isNaN(value) ? nan : formatType(Math.abs(value), precision);\n\n // Trim insignificant zeros.\n if (trim) value = formatTrim(value);\n\n // If a negative value rounds to zero after formatting, and no explicit positive sign is requested, hide the sign.\n if (valueNegative && +value === 0 && sign !== \"+\") valueNegative = false;\n\n // Compute the prefix and suffix.\n valuePrefix = (valueNegative ? (sign === \"(\" ? sign : minus) : sign === \"-\" || sign === \"(\" ? \"\" : sign) + valuePrefix;\n valueSuffix = (type === \"s\" ? prefixes[8 + prefixExponent / 3] : \"\") + valueSuffix + (valueNegative && sign === \"(\" ? \")\" : \"\");\n\n // Break the formatted value into the integer \u201Cvalue\u201D part that can be\n // grouped, and fractional or exponential \u201Csuffix\u201D part that is not.\n if (maybeSuffix) {\n i = -1, n = value.length;\n while (++i < n) {\n if (c = value.charCodeAt(i), 48 > c || c > 57) {\n valueSuffix = (c === 46 ? decimal + value.slice(i + 1) : value.slice(i)) + valueSuffix;\n value = value.slice(0, i);\n break;\n }\n }\n }\n }\n\n // If the fill character is not \"0\", grouping is applied before padding.\n if (comma && !zero) value = group(value, Infinity);\n\n // Compute the padding.\n var length = valuePrefix.length + value.length + valueSuffix.length,\n padding = length < width ? new Array(width - length + 1).join(fill) : \"\";\n\n // If the fill character is \"0\", grouping is applied after padding.\n if (comma && zero) value = group(padding + value, padding.length ? width - valueSuffix.length : Infinity), padding = \"\";\n\n // Reconstruct the final output based on the desired alignment.\n switch (align) {\n case \"<\": value = valuePrefix + value + valueSuffix + padding; break;\n case \"=\": value = valuePrefix + padding + value + valueSuffix; break;\n case \"^\": value = padding.slice(0, length = padding.length >> 1) + valuePrefix + value + valueSuffix + padding.slice(length); break;\n default: value = padding + valuePrefix + value + valueSuffix; break;\n }\n\n return numerals(value);\n }\n\n format.toString = function() {\n return specifier + \"\";\n };\n\n return format;\n }\n\n function formatPrefix(specifier, value) {\n var f = newFormat((specifier = formatSpecifier(specifier), specifier.type = \"f\", specifier)),\n e = Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3,\n k = Math.pow(10, -e),\n prefix = prefixes[8 + e / 3];\n return function(value) {\n return f(k * value) + prefix;\n };\n }\n\n return {\n format: newFormat,\n formatPrefix: formatPrefix\n };\n}\n", "import formatLocale from \"./locale.js\";\n\nvar locale;\nexport var format;\nexport var formatPrefix;\n\ndefaultLocale({\n thousands: \",\",\n grouping: [3],\n currency: [\"$\", \"\"]\n});\n\nexport default function defaultLocale(definition) {\n locale = formatLocale(definition);\n format = locale.format;\n formatPrefix = locale.formatPrefix;\n return locale;\n}\n", "import exponent from \"./exponent.js\";\n\nexport default function(step) {\n return Math.max(0, -exponent(Math.abs(step)));\n}\n", "import exponent from \"./exponent.js\";\n\nexport default function(step, value) {\n return Math.max(0, Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3 - exponent(Math.abs(step)));\n}\n", "import exponent from \"./exponent.js\";\n\nexport default function(step, max) {\n step = Math.abs(step), max = Math.abs(max) - step;\n return Math.max(0, exponent(max) - exponent(step)) + 1;\n}\n", "import {tickStep} from \"d3-array\";\nimport {format, formatPrefix, formatSpecifier, precisionFixed, precisionPrefix, precisionRound} from \"d3-format\";\n\nexport default function tickFormat(start, stop, count, specifier) {\n var step = tickStep(start, stop, count),\n precision;\n specifier = formatSpecifier(specifier == null ? \",f\" : specifier);\n switch (specifier.type) {\n case \"s\": {\n var value = Math.max(Math.abs(start), Math.abs(stop));\n if (specifier.precision == null && !isNaN(precision = precisionPrefix(step, value))) specifier.precision = precision;\n return formatPrefix(specifier, value);\n }\n case \"\":\n case \"e\":\n case \"g\":\n case \"p\":\n case \"r\": {\n if (specifier.precision == null && !isNaN(precision = precisionRound(step, Math.max(Math.abs(start), Math.abs(stop))))) specifier.precision = precision - (specifier.type === \"e\");\n break;\n }\n case \"f\":\n case \"%\": {\n if (specifier.precision == null && !isNaN(precision = precisionFixed(step))) specifier.precision = precision - (specifier.type === \"%\") * 2;\n break;\n }\n }\n return format(specifier);\n}\n", "import {ticks, tickIncrement} from \"d3-array\";\nimport continuous, {copy} from \"./continuous.js\";\nimport {initRange} from \"./init.js\";\nimport tickFormat from \"./tickFormat.js\";\n\nexport function linearish(scale) {\n var domain = scale.domain;\n\n scale.ticks = function(count) {\n var d = domain();\n return ticks(d[0], d[d.length - 1], count == null ? 10 : count);\n };\n\n scale.tickFormat = function(count, specifier) {\n var d = domain();\n return tickFormat(d[0], d[d.length - 1], count == null ? 10 : count, specifier);\n };\n\n scale.nice = function(count) {\n if (count == null) count = 10;\n\n var d = domain();\n var i0 = 0;\n var i1 = d.length - 1;\n var start = d[i0];\n var stop = d[i1];\n var prestep;\n var step;\n var maxIter = 10;\n\n if (stop < start) {\n step = start, start = stop, stop = step;\n step = i0, i0 = i1, i1 = step;\n }\n \n while (maxIter-- > 0) {\n step = tickIncrement(start, stop, count);\n if (step === prestep) {\n d[i0] = start\n d[i1] = stop\n return domain(d);\n } else if (step > 0) {\n start = Math.floor(start / step) * step;\n stop = Math.ceil(stop / step) * step;\n } else if (step < 0) {\n start = Math.ceil(start * step) / step;\n stop = Math.floor(stop * step) / step;\n } else {\n break;\n }\n prestep = step;\n }\n\n return scale;\n };\n\n return scale;\n}\n\nexport default function linear() {\n var scale = continuous();\n\n scale.copy = function() {\n return copy(scale, linear());\n };\n\n initRange.apply(scale, arguments);\n\n return linearish(scale);\n}\n", "const t0 = new Date, t1 = new Date;\n\nexport function timeInterval(floori, offseti, count, field) {\n\n function interval(date) {\n return floori(date = arguments.length === 0 ? new Date : new Date(+date)), date;\n }\n\n interval.floor = (date) => {\n return floori(date = new Date(+date)), date;\n };\n\n interval.ceil = (date) => {\n return floori(date = new Date(date - 1)), offseti(date, 1), floori(date), date;\n };\n\n interval.round = (date) => {\n const d0 = interval(date), d1 = interval.ceil(date);\n return date - d0 < d1 - date ? d0 : d1;\n };\n\n interval.offset = (date, step) => {\n return offseti(date = new Date(+date), step == null ? 1 : Math.floor(step)), date;\n };\n\n interval.range = (start, stop, step) => {\n const range = [];\n start = interval.ceil(start);\n step = step == null ? 1 : Math.floor(step);\n if (!(start < stop) || !(step > 0)) return range; // also handles Invalid Date\n let previous;\n do range.push(previous = new Date(+start)), offseti(start, step), floori(start);\n while (previous < start && start < stop);\n return range;\n };\n\n interval.filter = (test) => {\n return timeInterval((date) => {\n if (date >= date) while (floori(date), !test(date)) date.setTime(date - 1);\n }, (date, step) => {\n if (date >= date) {\n if (step < 0) while (++step <= 0) {\n while (offseti(date, -1), !test(date)) {} // eslint-disable-line no-empty\n } else while (--step >= 0) {\n while (offseti(date, +1), !test(date)) {} // eslint-disable-line no-empty\n }\n }\n });\n };\n\n if (count) {\n interval.count = (start, end) => {\n t0.setTime(+start), t1.setTime(+end);\n floori(t0), floori(t1);\n return Math.floor(count(t0, t1));\n };\n\n interval.every = (step) => {\n step = Math.floor(step);\n return !isFinite(step) || !(step > 0) ? null\n : !(step > 1) ? interval\n : interval.filter(field\n ? (d) => field(d) % step === 0\n : (d) => interval.count(0, d) % step === 0);\n };\n }\n\n return interval;\n}\n", "import {timeInterval} from \"./interval.js\";\n\nexport const millisecond = timeInterval(() => {\n // noop\n}, (date, step) => {\n date.setTime(+date + step);\n}, (start, end) => {\n return end - start;\n});\n\n// An optimized implementation for this simple case.\nmillisecond.every = (k) => {\n k = Math.floor(k);\n if (!isFinite(k) || !(k > 0)) return null;\n if (!(k > 1)) return millisecond;\n return timeInterval((date) => {\n date.setTime(Math.floor(date / k) * k);\n }, (date, step) => {\n date.setTime(+date + step * k);\n }, (start, end) => {\n return (end - start) / k;\n });\n};\n\nexport const milliseconds = millisecond.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationSecond} from \"./duration.js\";\n\nexport const second = timeInterval((date) => {\n date.setTime(date - date.getMilliseconds());\n}, (date, step) => {\n date.setTime(+date + step * durationSecond);\n}, (start, end) => {\n return (end - start) / durationSecond;\n}, (date) => {\n return date.getUTCSeconds();\n});\n\nexport const seconds = second.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationMinute, durationSecond} from \"./duration.js\";\n\nexport const timeMinute = timeInterval((date) => {\n date.setTime(date - date.getMilliseconds() - date.getSeconds() * durationSecond);\n}, (date, step) => {\n date.setTime(+date + step * durationMinute);\n}, (start, end) => {\n return (end - start) / durationMinute;\n}, (date) => {\n return date.getMinutes();\n});\n\nexport const timeMinutes = timeMinute.range;\n\nexport const utcMinute = timeInterval((date) => {\n date.setUTCSeconds(0, 0);\n}, (date, step) => {\n date.setTime(+date + step * durationMinute);\n}, (start, end) => {\n return (end - start) / durationMinute;\n}, (date) => {\n return date.getUTCMinutes();\n});\n\nexport const utcMinutes = utcMinute.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationHour, durationMinute, durationSecond} from \"./duration.js\";\n\nexport const timeHour = timeInterval((date) => {\n date.setTime(date - date.getMilliseconds() - date.getSeconds() * durationSecond - date.getMinutes() * durationMinute);\n}, (date, step) => {\n date.setTime(+date + step * durationHour);\n}, (start, end) => {\n return (end - start) / durationHour;\n}, (date) => {\n return date.getHours();\n});\n\nexport const timeHours = timeHour.range;\n\nexport const utcHour = timeInterval((date) => {\n date.setUTCMinutes(0, 0, 0);\n}, (date, step) => {\n date.setTime(+date + step * durationHour);\n}, (start, end) => {\n return (end - start) / durationHour;\n}, (date) => {\n return date.getUTCHours();\n});\n\nexport const utcHours = utcHour.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationDay, durationMinute} from \"./duration.js\";\n\nexport const timeDay = timeInterval(\n date => date.setHours(0, 0, 0, 0),\n (date, step) => date.setDate(date.getDate() + step),\n (start, end) => (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * durationMinute) / durationDay,\n date => date.getDate() - 1\n);\n\nexport const timeDays = timeDay.range;\n\nexport const utcDay = timeInterval((date) => {\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCDate(date.getUTCDate() + step);\n}, (start, end) => {\n return (end - start) / durationDay;\n}, (date) => {\n return date.getUTCDate() - 1;\n});\n\nexport const utcDays = utcDay.range;\n\nexport const unixDay = timeInterval((date) => {\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCDate(date.getUTCDate() + step);\n}, (start, end) => {\n return (end - start) / durationDay;\n}, (date) => {\n return Math.floor(date / durationDay);\n});\n\nexport const unixDays = unixDay.range;\n", "import {timeInterval} from \"./interval.js\";\nimport {durationMinute, durationWeek} from \"./duration.js\";\n\nfunction timeWeekday(i) {\n return timeInterval((date) => {\n date.setDate(date.getDate() - (date.getDay() + 7 - i) % 7);\n date.setHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setDate(date.getDate() + step * 7);\n }, (start, end) => {\n return (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * durationMinute) / durationWeek;\n });\n}\n\nexport const timeSunday = timeWeekday(0);\nexport const timeMonday = timeWeekday(1);\nexport const timeTuesday = timeWeekday(2);\nexport const timeWednesday = timeWeekday(3);\nexport const timeThursday = timeWeekday(4);\nexport const timeFriday = timeWeekday(5);\nexport const timeSaturday = timeWeekday(6);\n\nexport const timeSundays = timeSunday.range;\nexport const timeMondays = timeMonday.range;\nexport const timeTuesdays = timeTuesday.range;\nexport const timeWednesdays = timeWednesday.range;\nexport const timeThursdays = timeThursday.range;\nexport const timeFridays = timeFriday.range;\nexport const timeSaturdays = timeSaturday.range;\n\nfunction utcWeekday(i) {\n return timeInterval((date) => {\n date.setUTCDate(date.getUTCDate() - (date.getUTCDay() + 7 - i) % 7);\n date.setUTCHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setUTCDate(date.getUTCDate() + step * 7);\n }, (start, end) => {\n return (end - start) / durationWeek;\n });\n}\n\nexport const utcSunday = utcWeekday(0);\nexport const utcMonday = utcWeekday(1);\nexport const utcTuesday = utcWeekday(2);\nexport const utcWednesday = utcWeekday(3);\nexport const utcThursday = utcWeekday(4);\nexport const utcFriday = utcWeekday(5);\nexport const utcSaturday = utcWeekday(6);\n\nexport const utcSundays = utcSunday.range;\nexport const utcMondays = utcMonday.range;\nexport const utcTuesdays = utcTuesday.range;\nexport const utcWednesdays = utcWednesday.range;\nexport const utcThursdays = utcThursday.range;\nexport const utcFridays = utcFriday.range;\nexport const utcSaturdays = utcSaturday.range;\n", "import {timeInterval} from \"./interval.js\";\n\nexport const timeMonth = timeInterval((date) => {\n date.setDate(1);\n date.setHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setMonth(date.getMonth() + step);\n}, (start, end) => {\n return end.getMonth() - start.getMonth() + (end.getFullYear() - start.getFullYear()) * 12;\n}, (date) => {\n return date.getMonth();\n});\n\nexport const timeMonths = timeMonth.range;\n\nexport const utcMonth = timeInterval((date) => {\n date.setUTCDate(1);\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCMonth(date.getUTCMonth() + step);\n}, (start, end) => {\n return end.getUTCMonth() - start.getUTCMonth() + (end.getUTCFullYear() - start.getUTCFullYear()) * 12;\n}, (date) => {\n return date.getUTCMonth();\n});\n\nexport const utcMonths = utcMonth.range;\n", "import {timeInterval} from \"./interval.js\";\n\nexport const timeYear = timeInterval((date) => {\n date.setMonth(0, 1);\n date.setHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setFullYear(date.getFullYear() + step);\n}, (start, end) => {\n return end.getFullYear() - start.getFullYear();\n}, (date) => {\n return date.getFullYear();\n});\n\n// An optimized implementation for this simple case.\ntimeYear.every = (k) => {\n return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : timeInterval((date) => {\n date.setFullYear(Math.floor(date.getFullYear() / k) * k);\n date.setMonth(0, 1);\n date.setHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setFullYear(date.getFullYear() + step * k);\n });\n};\n\nexport const timeYears = timeYear.range;\n\nexport const utcYear = timeInterval((date) => {\n date.setUTCMonth(0, 1);\n date.setUTCHours(0, 0, 0, 0);\n}, (date, step) => {\n date.setUTCFullYear(date.getUTCFullYear() + step);\n}, (start, end) => {\n return end.getUTCFullYear() - start.getUTCFullYear();\n}, (date) => {\n return date.getUTCFullYear();\n});\n\n// An optimized implementation for this simple case.\nutcYear.every = (k) => {\n return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : timeInterval((date) => {\n date.setUTCFullYear(Math.floor(date.getUTCFullYear() / k) * k);\n date.setUTCMonth(0, 1);\n date.setUTCHours(0, 0, 0, 0);\n }, (date, step) => {\n date.setUTCFullYear(date.getUTCFullYear() + step * k);\n });\n};\n\nexport const utcYears = utcYear.range;\n", "import {bisector, tickStep} from \"d3-array\";\nimport {durationDay, durationHour, durationMinute, durationMonth, durationSecond, durationWeek, durationYear} from \"./duration.js\";\nimport {millisecond} from \"./millisecond.js\";\nimport {second} from \"./second.js\";\nimport {timeMinute, utcMinute} from \"./minute.js\";\nimport {timeHour, utcHour} from \"./hour.js\";\nimport {timeDay, unixDay} from \"./day.js\";\nimport {timeSunday, utcSunday} from \"./week.js\";\nimport {timeMonth, utcMonth} from \"./month.js\";\nimport {timeYear, utcYear} from \"./year.js\";\n\nfunction ticker(year, month, week, day, hour, minute) {\n\n const tickIntervals = [\n [second, 1, durationSecond],\n [second, 5, 5 * durationSecond],\n [second, 15, 15 * durationSecond],\n [second, 30, 30 * durationSecond],\n [minute, 1, durationMinute],\n [minute, 5, 5 * durationMinute],\n [minute, 15, 15 * durationMinute],\n [minute, 30, 30 * durationMinute],\n [ hour, 1, durationHour ],\n [ hour, 3, 3 * durationHour ],\n [ hour, 6, 6 * durationHour ],\n [ hour, 12, 12 * durationHour ],\n [ day, 1, durationDay ],\n [ day, 2, 2 * durationDay ],\n [ week, 1, durationWeek ],\n [ month, 1, durationMonth ],\n [ month, 3, 3 * durationMonth ],\n [ year, 1, durationYear ]\n ];\n\n function ticks(start, stop, count) {\n const reverse = stop < start;\n if (reverse) [start, stop] = [stop, start];\n const interval = count && typeof count.range === \"function\" ? count : tickInterval(start, stop, count);\n const ticks = interval ? interval.range(start, +stop + 1) : []; // inclusive stop\n return reverse ? ticks.reverse() : ticks;\n }\n\n function tickInterval(start, stop, count) {\n const target = Math.abs(stop - start) / count;\n const i = bisector(([,, step]) => step).right(tickIntervals, target);\n if (i === tickIntervals.length) return year.every(tickStep(start / durationYear, stop / durationYear, count));\n if (i === 0) return millisecond.every(Math.max(tickStep(start, stop, count), 1));\n const [t, step] = tickIntervals[target / tickIntervals[i - 1][2] < tickIntervals[i][2] / target ? i - 1 : i];\n return t.every(step);\n }\n\n return [ticks, tickInterval];\n}\n\nconst [utcTicks, utcTickInterval] = ticker(utcYear, utcMonth, utcSunday, unixDay, utcHour, utcMinute);\nconst [timeTicks, timeTickInterval] = ticker(timeYear, timeMonth, timeSunday, timeDay, timeHour, timeMinute);\n\nexport {utcTicks, utcTickInterval, timeTicks, timeTickInterval};\n", "import {\n timeDay,\n timeSunday,\n timeMonday,\n timeThursday,\n timeYear,\n utcDay,\n utcSunday,\n utcMonday,\n utcThursday,\n utcYear\n} from \"d3-time\";\n\nfunction localDate(d) {\n if (0 <= d.y && d.y < 100) {\n var date = new Date(-1, d.m, d.d, d.H, d.M, d.S, d.L);\n date.setFullYear(d.y);\n return date;\n }\n return new Date(d.y, d.m, d.d, d.H, d.M, d.S, d.L);\n}\n\nfunction utcDate(d) {\n if (0 <= d.y && d.y < 100) {\n var date = new Date(Date.UTC(-1, d.m, d.d, d.H, d.M, d.S, d.L));\n date.setUTCFullYear(d.y);\n return date;\n }\n return new Date(Date.UTC(d.y, d.m, d.d, d.H, d.M, d.S, d.L));\n}\n\nfunction newDate(y, m, d) {\n return {y: y, m: m, d: d, H: 0, M: 0, S: 0, L: 0};\n}\n\nexport default function formatLocale(locale) {\n var locale_dateTime = locale.dateTime,\n locale_date = locale.date,\n locale_time = locale.time,\n locale_periods = locale.periods,\n locale_weekdays = locale.days,\n locale_shortWeekdays = locale.shortDays,\n locale_months = locale.months,\n locale_shortMonths = locale.shortMonths;\n\n var periodRe = formatRe(locale_periods),\n periodLookup = formatLookup(locale_periods),\n weekdayRe = formatRe(locale_weekdays),\n weekdayLookup = formatLookup(locale_weekdays),\n shortWeekdayRe = formatRe(locale_shortWeekdays),\n shortWeekdayLookup = formatLookup(locale_shortWeekdays),\n monthRe = formatRe(locale_months),\n monthLookup = formatLookup(locale_months),\n shortMonthRe = formatRe(locale_shortMonths),\n shortMonthLookup = formatLookup(locale_shortMonths);\n\n var formats = {\n \"a\": formatShortWeekday,\n \"A\": formatWeekday,\n \"b\": formatShortMonth,\n \"B\": formatMonth,\n \"c\": null,\n \"d\": formatDayOfMonth,\n \"e\": formatDayOfMonth,\n \"f\": formatMicroseconds,\n \"g\": formatYearISO,\n \"G\": formatFullYearISO,\n \"H\": formatHour24,\n \"I\": formatHour12,\n \"j\": formatDayOfYear,\n \"L\": formatMilliseconds,\n \"m\": formatMonthNumber,\n \"M\": formatMinutes,\n \"p\": formatPeriod,\n \"q\": formatQuarter,\n \"Q\": formatUnixTimestamp,\n \"s\": formatUnixTimestampSeconds,\n \"S\": formatSeconds,\n \"u\": formatWeekdayNumberMonday,\n \"U\": formatWeekNumberSunday,\n \"V\": formatWeekNumberISO,\n \"w\": formatWeekdayNumberSunday,\n \"W\": formatWeekNumberMonday,\n \"x\": null,\n \"X\": null,\n \"y\": formatYear,\n \"Y\": formatFullYear,\n \"Z\": formatZone,\n \"%\": formatLiteralPercent\n };\n\n var utcFormats = {\n \"a\": formatUTCShortWeekday,\n \"A\": formatUTCWeekday,\n \"b\": formatUTCShortMonth,\n \"B\": formatUTCMonth,\n \"c\": null,\n \"d\": formatUTCDayOfMonth,\n \"e\": formatUTCDayOfMonth,\n \"f\": formatUTCMicroseconds,\n \"g\": formatUTCYearISO,\n \"G\": formatUTCFullYearISO,\n \"H\": formatUTCHour24,\n \"I\": formatUTCHour12,\n \"j\": formatUTCDayOfYear,\n \"L\": formatUTCMilliseconds,\n \"m\": formatUTCMonthNumber,\n \"M\": formatUTCMinutes,\n \"p\": formatUTCPeriod,\n \"q\": formatUTCQuarter,\n \"Q\": formatUnixTimestamp,\n \"s\": formatUnixTimestampSeconds,\n \"S\": formatUTCSeconds,\n \"u\": formatUTCWeekdayNumberMonday,\n \"U\": formatUTCWeekNumberSunday,\n \"V\": formatUTCWeekNumberISO,\n \"w\": formatUTCWeekdayNumberSunday,\n \"W\": formatUTCWeekNumberMonday,\n \"x\": null,\n \"X\": null,\n \"y\": formatUTCYear,\n \"Y\": formatUTCFullYear,\n \"Z\": formatUTCZone,\n \"%\": formatLiteralPercent\n };\n\n var parses = {\n \"a\": parseShortWeekday,\n \"A\": parseWeekday,\n \"b\": parseShortMonth,\n \"B\": parseMonth,\n \"c\": parseLocaleDateTime,\n \"d\": parseDayOfMonth,\n \"e\": parseDayOfMonth,\n \"f\": parseMicroseconds,\n \"g\": parseYear,\n \"G\": parseFullYear,\n \"H\": parseHour24,\n \"I\": parseHour24,\n \"j\": parseDayOfYear,\n \"L\": parseMilliseconds,\n \"m\": parseMonthNumber,\n \"M\": parseMinutes,\n \"p\": parsePeriod,\n \"q\": parseQuarter,\n \"Q\": parseUnixTimestamp,\n \"s\": parseUnixTimestampSeconds,\n \"S\": parseSeconds,\n \"u\": parseWeekdayNumberMonday,\n \"U\": parseWeekNumberSunday,\n \"V\": parseWeekNumberISO,\n \"w\": parseWeekdayNumberSunday,\n \"W\": parseWeekNumberMonday,\n \"x\": parseLocaleDate,\n \"X\": parseLocaleTime,\n \"y\": parseYear,\n \"Y\": parseFullYear,\n \"Z\": parseZone,\n \"%\": parseLiteralPercent\n };\n\n // These recursive directive definitions must be deferred.\n formats.x = newFormat(locale_date, formats);\n formats.X = newFormat(locale_time, formats);\n formats.c = newFormat(locale_dateTime, formats);\n utcFormats.x = newFormat(locale_date, utcFormats);\n utcFormats.X = newFormat(locale_time, utcFormats);\n utcFormats.c = newFormat(locale_dateTime, utcFormats);\n\n function newFormat(specifier, formats) {\n return function(date) {\n var string = [],\n i = -1,\n j = 0,\n n = specifier.length,\n c,\n pad,\n format;\n\n if (!(date instanceof Date)) date = new Date(+date);\n\n while (++i < n) {\n if (specifier.charCodeAt(i) === 37) {\n string.push(specifier.slice(j, i));\n if ((pad = pads[c = specifier.charAt(++i)]) != null) c = specifier.charAt(++i);\n else pad = c === \"e\" ? \" \" : \"0\";\n if (format = formats[c]) c = format(date, pad);\n string.push(c);\n j = i + 1;\n }\n }\n\n string.push(specifier.slice(j, i));\n return string.join(\"\");\n };\n }\n\n function newParse(specifier, Z) {\n return function(string) {\n var d = newDate(1900, undefined, 1),\n i = parseSpecifier(d, specifier, string += \"\", 0),\n week, day;\n if (i != string.length) return null;\n\n // If a UNIX timestamp is specified, return it.\n if (\"Q\" in d) return new Date(d.Q);\n if (\"s\" in d) return new Date(d.s * 1000 + (\"L\" in d ? d.L : 0));\n\n // If this is utcParse, never use the local timezone.\n if (Z && !(\"Z\" in d)) d.Z = 0;\n\n // The am-pm flag is 0 for AM, and 1 for PM.\n if (\"p\" in d) d.H = d.H % 12 + d.p * 12;\n\n // If the month was not specified, inherit from the quarter.\n if (d.m === undefined) d.m = \"q\" in d ? d.q : 0;\n\n // Convert day-of-week and week-of-year to day-of-year.\n if (\"V\" in d) {\n if (d.V < 1 || d.V > 53) return null;\n if (!(\"w\" in d)) d.w = 1;\n if (\"Z\" in d) {\n week = utcDate(newDate(d.y, 0, 1)), day = week.getUTCDay();\n week = day > 4 || day === 0 ? utcMonday.ceil(week) : utcMonday(week);\n week = utcDay.offset(week, (d.V - 1) * 7);\n d.y = week.getUTCFullYear();\n d.m = week.getUTCMonth();\n d.d = week.getUTCDate() + (d.w + 6) % 7;\n } else {\n week = localDate(newDate(d.y, 0, 1)), day = week.getDay();\n week = day > 4 || day === 0 ? timeMonday.ceil(week) : timeMonday(week);\n week = timeDay.offset(week, (d.V - 1) * 7);\n d.y = week.getFullYear();\n d.m = week.getMonth();\n d.d = week.getDate() + (d.w + 6) % 7;\n }\n } else if (\"W\" in d || \"U\" in d) {\n if (!(\"w\" in d)) d.w = \"u\" in d ? d.u % 7 : \"W\" in d ? 1 : 0;\n day = \"Z\" in d ? utcDate(newDate(d.y, 0, 1)).getUTCDay() : localDate(newDate(d.y, 0, 1)).getDay();\n d.m = 0;\n d.d = \"W\" in d ? (d.w + 6) % 7 + d.W * 7 - (day + 5) % 7 : d.w + d.U * 7 - (day + 6) % 7;\n }\n\n // If a time zone is specified, all fields are interpreted as UTC and then\n // offset according to the specified time zone.\n if (\"Z\" in d) {\n d.H += d.Z / 100 | 0;\n d.M += d.Z % 100;\n return utcDate(d);\n }\n\n // Otherwise, all fields are in local time.\n return localDate(d);\n };\n }\n\n function parseSpecifier(d, specifier, string, j) {\n var i = 0,\n n = specifier.length,\n m = string.length,\n c,\n parse;\n\n while (i < n) {\n if (j >= m) return -1;\n c = specifier.charCodeAt(i++);\n if (c === 37) {\n c = specifier.charAt(i++);\n parse = parses[c in pads ? specifier.charAt(i++) : c];\n if (!parse || ((j = parse(d, string, j)) < 0)) return -1;\n } else if (c != string.charCodeAt(j++)) {\n return -1;\n }\n }\n\n return j;\n }\n\n function parsePeriod(d, string, i) {\n var n = periodRe.exec(string.slice(i));\n return n ? (d.p = periodLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseShortWeekday(d, string, i) {\n var n = shortWeekdayRe.exec(string.slice(i));\n return n ? (d.w = shortWeekdayLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseWeekday(d, string, i) {\n var n = weekdayRe.exec(string.slice(i));\n return n ? (d.w = weekdayLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseShortMonth(d, string, i) {\n var n = shortMonthRe.exec(string.slice(i));\n return n ? (d.m = shortMonthLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseMonth(d, string, i) {\n var n = monthRe.exec(string.slice(i));\n return n ? (d.m = monthLookup.get(n[0].toLowerCase()), i + n[0].length) : -1;\n }\n\n function parseLocaleDateTime(d, string, i) {\n return parseSpecifier(d, locale_dateTime, string, i);\n }\n\n function parseLocaleDate(d, string, i) {\n return parseSpecifier(d, locale_date, string, i);\n }\n\n function parseLocaleTime(d, string, i) {\n return parseSpecifier(d, locale_time, string, i);\n }\n\n function formatShortWeekday(d) {\n return locale_shortWeekdays[d.getDay()];\n }\n\n function formatWeekday(d) {\n return locale_weekdays[d.getDay()];\n }\n\n function formatShortMonth(d) {\n return locale_shortMonths[d.getMonth()];\n }\n\n function formatMonth(d) {\n return locale_months[d.getMonth()];\n }\n\n function formatPeriod(d) {\n return locale_periods[+(d.getHours() >= 12)];\n }\n\n function formatQuarter(d) {\n return 1 + ~~(d.getMonth() / 3);\n }\n\n function formatUTCShortWeekday(d) {\n return locale_shortWeekdays[d.getUTCDay()];\n }\n\n function formatUTCWeekday(d) {\n return locale_weekdays[d.getUTCDay()];\n }\n\n function formatUTCShortMonth(d) {\n return locale_shortMonths[d.getUTCMonth()];\n }\n\n function formatUTCMonth(d) {\n return locale_months[d.getUTCMonth()];\n }\n\n function formatUTCPeriod(d) {\n return locale_periods[+(d.getUTCHours() >= 12)];\n }\n\n function formatUTCQuarter(d) {\n return 1 + ~~(d.getUTCMonth() / 3);\n }\n\n return {\n format: function(specifier) {\n var f = newFormat(specifier += \"\", formats);\n f.toString = function() { return specifier; };\n return f;\n },\n parse: function(specifier) {\n var p = newParse(specifier += \"\", false);\n p.toString = function() { return specifier; };\n return p;\n },\n utcFormat: function(specifier) {\n var f = newFormat(specifier += \"\", utcFormats);\n f.toString = function() { return specifier; };\n return f;\n },\n utcParse: function(specifier) {\n var p = newParse(specifier += \"\", true);\n p.toString = function() { return specifier; };\n return p;\n }\n };\n}\n\nvar pads = {\"-\": \"\", \"_\": \" \", \"0\": \"0\"},\n numberRe = /^\\s*\\d+/, // note: ignores next directive\n percentRe = /^%/,\n requoteRe = /[\\\\^$*+?|[\\]().{}]/g;\n\nfunction pad(value, fill, width) {\n var sign = value < 0 ? \"-\" : \"\",\n string = (sign ? -value : value) + \"\",\n length = string.length;\n return sign + (length < width ? new Array(width - length + 1).join(fill) + string : string);\n}\n\nfunction requote(s) {\n return s.replace(requoteRe, \"\\\\$&\");\n}\n\nfunction formatRe(names) {\n return new RegExp(\"^(?:\" + names.map(requote).join(\"|\") + \")\", \"i\");\n}\n\nfunction formatLookup(names) {\n return new Map(names.map((name, i) => [name.toLowerCase(), i]));\n}\n\nfunction parseWeekdayNumberSunday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 1));\n return n ? (d.w = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekdayNumberMonday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 1));\n return n ? (d.u = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekNumberSunday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.U = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekNumberISO(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.V = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseWeekNumberMonday(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.W = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseFullYear(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 4));\n return n ? (d.y = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseYear(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.y = +n[0] + (+n[0] > 68 ? 1900 : 2000), i + n[0].length) : -1;\n}\n\nfunction parseZone(d, string, i) {\n var n = /^(Z)|([+-]\\d\\d)(?::?(\\d\\d))?/.exec(string.slice(i, i + 6));\n return n ? (d.Z = n[1] ? 0 : -(n[2] + (n[3] || \"00\")), i + n[0].length) : -1;\n}\n\nfunction parseQuarter(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 1));\n return n ? (d.q = n[0] * 3 - 3, i + n[0].length) : -1;\n}\n\nfunction parseMonthNumber(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.m = n[0] - 1, i + n[0].length) : -1;\n}\n\nfunction parseDayOfMonth(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.d = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseDayOfYear(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 3));\n return n ? (d.m = 0, d.d = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseHour24(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.H = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseMinutes(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.M = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseSeconds(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 2));\n return n ? (d.S = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseMilliseconds(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 3));\n return n ? (d.L = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseMicroseconds(d, string, i) {\n var n = numberRe.exec(string.slice(i, i + 6));\n return n ? (d.L = Math.floor(n[0] / 1000), i + n[0].length) : -1;\n}\n\nfunction parseLiteralPercent(d, string, i) {\n var n = percentRe.exec(string.slice(i, i + 1));\n return n ? i + n[0].length : -1;\n}\n\nfunction parseUnixTimestamp(d, string, i) {\n var n = numberRe.exec(string.slice(i));\n return n ? (d.Q = +n[0], i + n[0].length) : -1;\n}\n\nfunction parseUnixTimestampSeconds(d, string, i) {\n var n = numberRe.exec(string.slice(i));\n return n ? (d.s = +n[0], i + n[0].length) : -1;\n}\n\nfunction formatDayOfMonth(d, p) {\n return pad(d.getDate(), p, 2);\n}\n\nfunction formatHour24(d, p) {\n return pad(d.getHours(), p, 2);\n}\n\nfunction formatHour12(d, p) {\n return pad(d.getHours() % 12 || 12, p, 2);\n}\n\nfunction formatDayOfYear(d, p) {\n return pad(1 + timeDay.count(timeYear(d), d), p, 3);\n}\n\nfunction formatMilliseconds(d, p) {\n return pad(d.getMilliseconds(), p, 3);\n}\n\nfunction formatMicroseconds(d, p) {\n return formatMilliseconds(d, p) + \"000\";\n}\n\nfunction formatMonthNumber(d, p) {\n return pad(d.getMonth() + 1, p, 2);\n}\n\nfunction formatMinutes(d, p) {\n return pad(d.getMinutes(), p, 2);\n}\n\nfunction formatSeconds(d, p) {\n return pad(d.getSeconds(), p, 2);\n}\n\nfunction formatWeekdayNumberMonday(d) {\n var day = d.getDay();\n return day === 0 ? 7 : day;\n}\n\nfunction formatWeekNumberSunday(d, p) {\n return pad(timeSunday.count(timeYear(d) - 1, d), p, 2);\n}\n\nfunction dISO(d) {\n var day = d.getDay();\n return (day >= 4 || day === 0) ? timeThursday(d) : timeThursday.ceil(d);\n}\n\nfunction formatWeekNumberISO(d, p) {\n d = dISO(d);\n return pad(timeThursday.count(timeYear(d), d) + (timeYear(d).getDay() === 4), p, 2);\n}\n\nfunction formatWeekdayNumberSunday(d) {\n return d.getDay();\n}\n\nfunction formatWeekNumberMonday(d, p) {\n return pad(timeMonday.count(timeYear(d) - 1, d), p, 2);\n}\n\nfunction formatYear(d, p) {\n return pad(d.getFullYear() % 100, p, 2);\n}\n\nfunction formatYearISO(d, p) {\n d = dISO(d);\n return pad(d.getFullYear() % 100, p, 2);\n}\n\nfunction formatFullYear(d, p) {\n return pad(d.getFullYear() % 10000, p, 4);\n}\n\nfunction formatFullYearISO(d, p) {\n var day = d.getDay();\n d = (day >= 4 || day === 0) ? timeThursday(d) : timeThursday.ceil(d);\n return pad(d.getFullYear() % 10000, p, 4);\n}\n\nfunction formatZone(d) {\n var z = d.getTimezoneOffset();\n return (z > 0 ? \"-\" : (z *= -1, \"+\"))\n + pad(z / 60 | 0, \"0\", 2)\n + pad(z % 60, \"0\", 2);\n}\n\nfunction formatUTCDayOfMonth(d, p) {\n return pad(d.getUTCDate(), p, 2);\n}\n\nfunction formatUTCHour24(d, p) {\n return pad(d.getUTCHours(), p, 2);\n}\n\nfunction formatUTCHour12(d, p) {\n return pad(d.getUTCHours() % 12 || 12, p, 2);\n}\n\nfunction formatUTCDayOfYear(d, p) {\n return pad(1 + utcDay.count(utcYear(d), d), p, 3);\n}\n\nfunction formatUTCMilliseconds(d, p) {\n return pad(d.getUTCMilliseconds(), p, 3);\n}\n\nfunction formatUTCMicroseconds(d, p) {\n return formatUTCMilliseconds(d, p) + \"000\";\n}\n\nfunction formatUTCMonthNumber(d, p) {\n return pad(d.getUTCMonth() + 1, p, 2);\n}\n\nfunction formatUTCMinutes(d, p) {\n return pad(d.getUTCMinutes(), p, 2);\n}\n\nfunction formatUTCSeconds(d, p) {\n return pad(d.getUTCSeconds(), p, 2);\n}\n\nfunction formatUTCWeekdayNumberMonday(d) {\n var dow = d.getUTCDay();\n return dow === 0 ? 7 : dow;\n}\n\nfunction formatUTCWeekNumberSunday(d, p) {\n return pad(utcSunday.count(utcYear(d) - 1, d), p, 2);\n}\n\nfunction UTCdISO(d) {\n var day = d.getUTCDay();\n return (day >= 4 || day === 0) ? utcThursday(d) : utcThursday.ceil(d);\n}\n\nfunction formatUTCWeekNumberISO(d, p) {\n d = UTCdISO(d);\n return pad(utcThursday.count(utcYear(d), d) + (utcYear(d).getUTCDay() === 4), p, 2);\n}\n\nfunction formatUTCWeekdayNumberSunday(d) {\n return d.getUTCDay();\n}\n\nfunction formatUTCWeekNumberMonday(d, p) {\n return pad(utcMonday.count(utcYear(d) - 1, d), p, 2);\n}\n\nfunction formatUTCYear(d, p) {\n return pad(d.getUTCFullYear() % 100, p, 2);\n}\n\nfunction formatUTCYearISO(d, p) {\n d = UTCdISO(d);\n return pad(d.getUTCFullYear() % 100, p, 2);\n}\n\nfunction formatUTCFullYear(d, p) {\n return pad(d.getUTCFullYear() % 10000, p, 4);\n}\n\nfunction formatUTCFullYearISO(d, p) {\n var day = d.getUTCDay();\n d = (day >= 4 || day === 0) ? utcThursday(d) : utcThursday.ceil(d);\n return pad(d.getUTCFullYear() % 10000, p, 4);\n}\n\nfunction formatUTCZone() {\n return \"+0000\";\n}\n\nfunction formatLiteralPercent() {\n return \"%\";\n}\n\nfunction formatUnixTimestamp(d) {\n return +d;\n}\n\nfunction formatUnixTimestampSeconds(d) {\n return Math.floor(+d / 1000);\n}\n", "import formatLocale from \"./locale.js\";\n\nvar locale;\nexport var timeFormat;\nexport var timeParse;\nexport var utcFormat;\nexport var utcParse;\n\ndefaultLocale({\n dateTime: \"%x, %X\",\n date: \"%-m/%-d/%Y\",\n time: \"%-I:%M:%S %p\",\n periods: [\"AM\", \"PM\"],\n days: [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"],\n shortDays: [\"Sun\", \"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\"],\n months: [\"January\", \"February\", \"March\", \"April\", \"May\", \"June\", \"July\", \"August\", \"September\", \"October\", \"November\", \"December\"],\n shortMonths: [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sep\", \"Oct\", \"Nov\", \"Dec\"]\n});\n\nexport default function defaultLocale(definition) {\n locale = formatLocale(definition);\n timeFormat = locale.format;\n timeParse = locale.parse;\n utcFormat = locale.utcFormat;\n utcParse = locale.utcParse;\n return locale;\n}\n", "export default function nice(domain, interval) {\n domain = domain.slice();\n\n var i0 = 0,\n i1 = domain.length - 1,\n x0 = domain[i0],\n x1 = domain[i1],\n t;\n\n if (x1 < x0) {\n t = i0, i0 = i1, i1 = t;\n t = x0, x0 = x1, x1 = t;\n }\n\n domain[i0] = interval.floor(x0);\n domain[i1] = interval.ceil(x1);\n return domain;\n}\n", "import {timeYear, timeMonth, timeWeek, timeDay, timeHour, timeMinute, timeSecond, timeTicks, timeTickInterval} from \"d3-time\";\nimport {timeFormat} from \"d3-time-format\";\nimport continuous, {copy} from \"./continuous.js\";\nimport {initRange} from \"./init.js\";\nimport nice from \"./nice.js\";\n\nfunction date(t) {\n return new Date(t);\n}\n\nfunction number(t) {\n return t instanceof Date ? +t : +new Date(+t);\n}\n\nexport function calendar(ticks, tickInterval, year, month, week, day, hour, minute, second, format) {\n var scale = continuous(),\n invert = scale.invert,\n domain = scale.domain;\n\n var formatMillisecond = format(\".%L\"),\n formatSecond = format(\":%S\"),\n formatMinute = format(\"%I:%M\"),\n formatHour = format(\"%I %p\"),\n formatDay = format(\"%a %d\"),\n formatWeek = format(\"%b %d\"),\n formatMonth = format(\"%B\"),\n formatYear = format(\"%Y\");\n\n function tickFormat(date) {\n return (second(date) < date ? formatMillisecond\n : minute(date) < date ? formatSecond\n : hour(date) < date ? formatMinute\n : day(date) < date ? formatHour\n : month(date) < date ? (week(date) < date ? formatDay : formatWeek)\n : year(date) < date ? formatMonth\n : formatYear)(date);\n }\n\n scale.invert = function(y) {\n return new Date(invert(y));\n };\n\n scale.domain = function(_) {\n return arguments.length ? domain(Array.from(_, number)) : domain().map(date);\n };\n\n scale.ticks = function(interval) {\n var d = domain();\n return ticks(d[0], d[d.length - 1], interval == null ? 10 : interval);\n };\n\n scale.tickFormat = function(count, specifier) {\n return specifier == null ? tickFormat : format(specifier);\n };\n\n scale.nice = function(interval) {\n var d = domain();\n if (!interval || typeof interval.range !== \"function\") interval = tickInterval(d[0], d[d.length - 1], interval == null ? 10 : interval);\n return interval ? domain(nice(d, interval)) : scale;\n };\n\n scale.copy = function() {\n return copy(scale, calendar(ticks, tickInterval, year, month, week, day, hour, minute, second, format));\n };\n\n return scale;\n}\n\nexport default function time() {\n return initRange.apply(calendar(timeTicks, timeTickInterval, timeYear, timeMonth, timeWeek, timeDay, timeHour, timeMinute, timeSecond, timeFormat).domain([new Date(2000, 0, 1), new Date(2000, 0, 2)]), arguments);\n}\n", "export default function(specifier) {\n var n = specifier.length / 6 | 0, colors = new Array(n), i = 0;\n while (i < n) colors[i] = \"#\" + specifier.slice(i * 6, ++i * 6);\n return colors;\n}\n", "import colors from \"../colors.js\";\n\nexport default colors(\"4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab\");\n", "export default function(x) {\n return function constant() {\n return x;\n };\n}\n", "export const abs = Math.abs;\nexport const atan2 = Math.atan2;\nexport const cos = Math.cos;\nexport const max = Math.max;\nexport const min = Math.min;\nexport const sin = Math.sin;\nexport const sqrt = Math.sqrt;\n\nexport const epsilon = 1e-12;\nexport const pi = Math.PI;\nexport const halfPi = pi / 2;\nexport const tau = 2 * pi;\n\nexport function acos(x) {\n return x > 1 ? 0 : x < -1 ? pi : Math.acos(x);\n}\n\nexport function asin(x) {\n return x >= 1 ? halfPi : x <= -1 ? -halfPi : Math.asin(x);\n}\n", "const pi = Math.PI,\n tau = 2 * pi,\n epsilon = 1e-6,\n tauEpsilon = tau - epsilon;\n\nfunction append(strings) {\n this._ += strings[0];\n for (let i = 1, n = strings.length; i < n; ++i) {\n this._ += arguments[i] + strings[i];\n }\n}\n\nfunction appendRound(digits) {\n let d = Math.floor(digits);\n if (!(d >= 0)) throw new Error(`invalid digits: ${digits}`);\n if (d > 15) return append;\n const k = 10 ** d;\n return function(strings) {\n this._ += strings[0];\n for (let i = 1, n = strings.length; i < n; ++i) {\n this._ += Math.round(arguments[i] * k) / k + strings[i];\n }\n };\n}\n\nexport class Path {\n constructor(digits) {\n this._x0 = this._y0 = // start of current subpath\n this._x1 = this._y1 = null; // end of current subpath\n this._ = \"\";\n this._append = digits == null ? append : appendRound(digits);\n }\n moveTo(x, y) {\n this._append`M${this._x0 = this._x1 = +x},${this._y0 = this._y1 = +y}`;\n }\n closePath() {\n if (this._x1 !== null) {\n this._x1 = this._x0, this._y1 = this._y0;\n this._append`Z`;\n }\n }\n lineTo(x, y) {\n this._append`L${this._x1 = +x},${this._y1 = +y}`;\n }\n quadraticCurveTo(x1, y1, x, y) {\n this._append`Q${+x1},${+y1},${this._x1 = +x},${this._y1 = +y}`;\n }\n bezierCurveTo(x1, y1, x2, y2, x, y) {\n this._append`C${+x1},${+y1},${+x2},${+y2},${this._x1 = +x},${this._y1 = +y}`;\n }\n arcTo(x1, y1, x2, y2, r) {\n x1 = +x1, y1 = +y1, x2 = +x2, y2 = +y2, r = +r;\n\n // Is the radius negative? Error.\n if (r < 0) throw new Error(`negative radius: ${r}`);\n\n let x0 = this._x1,\n y0 = this._y1,\n x21 = x2 - x1,\n y21 = y2 - y1,\n x01 = x0 - x1,\n y01 = y0 - y1,\n l01_2 = x01 * x01 + y01 * y01;\n\n // Is this path empty? Move to (x1,y1).\n if (this._x1 === null) {\n this._append`M${this._x1 = x1},${this._y1 = y1}`;\n }\n\n // Or, is (x1,y1) coincident with (x0,y0)? Do nothing.\n else if (!(l01_2 > epsilon));\n\n // Or, are (x0,y0), (x1,y1) and (x2,y2) collinear?\n // Equivalently, is (x1,y1) coincident with (x2,y2)?\n // Or, is the radius zero? Line to (x1,y1).\n else if (!(Math.abs(y01 * x21 - y21 * x01) > epsilon) || !r) {\n this._append`L${this._x1 = x1},${this._y1 = y1}`;\n }\n\n // Otherwise, draw an arc!\n else {\n let x20 = x2 - x0,\n y20 = y2 - y0,\n l21_2 = x21 * x21 + y21 * y21,\n l20_2 = x20 * x20 + y20 * y20,\n l21 = Math.sqrt(l21_2),\n l01 = Math.sqrt(l01_2),\n l = r * Math.tan((pi - Math.acos((l21_2 + l01_2 - l20_2) / (2 * l21 * l01))) / 2),\n t01 = l / l01,\n t21 = l / l21;\n\n // If the start tangent is not coincident with (x0,y0), line to.\n if (Math.abs(t01 - 1) > epsilon) {\n this._append`L${x1 + t01 * x01},${y1 + t01 * y01}`;\n }\n\n this._append`A${r},${r},0,0,${+(y01 * x20 > x01 * y20)},${this._x1 = x1 + t21 * x21},${this._y1 = y1 + t21 * y21}`;\n }\n }\n arc(x, y, r, a0, a1, ccw) {\n x = +x, y = +y, r = +r, ccw = !!ccw;\n\n // Is the radius negative? Error.\n if (r < 0) throw new Error(`negative radius: ${r}`);\n\n let dx = r * Math.cos(a0),\n dy = r * Math.sin(a0),\n x0 = x + dx,\n y0 = y + dy,\n cw = 1 ^ ccw,\n da = ccw ? a0 - a1 : a1 - a0;\n\n // Is this path empty? Move to (x0,y0).\n if (this._x1 === null) {\n this._append`M${x0},${y0}`;\n }\n\n // Or, is (x0,y0) not coincident with the previous point? Line to (x0,y0).\n else if (Math.abs(this._x1 - x0) > epsilon || Math.abs(this._y1 - y0) > epsilon) {\n this._append`L${x0},${y0}`;\n }\n\n // Is this arc empty? We\u2019re done.\n if (!r) return;\n\n // Does the angle go the wrong way? Flip the direction.\n if (da < 0) da = da % tau + tau;\n\n // Is this a complete circle? Draw two arcs to complete the circle.\n if (da > tauEpsilon) {\n this._append`A${r},${r},0,1,${cw},${x - dx},${y - dy}A${r},${r},0,1,${cw},${this._x1 = x0},${this._y1 = y0}`;\n }\n\n // Is this arc non-empty? Draw an arc!\n else if (da > epsilon) {\n this._append`A${r},${r},0,${+(da >= pi)},${cw},${this._x1 = x + r * Math.cos(a1)},${this._y1 = y + r * Math.sin(a1)}`;\n }\n }\n rect(x, y, w, h) {\n this._append`M${this._x0 = this._x1 = +x},${this._y0 = this._y1 = +y}h${w = +w}v${+h}h${-w}Z`;\n }\n toString() {\n return this._;\n }\n}\n\nexport function path() {\n return new Path;\n}\n\n// Allow instanceof d3.path\npath.prototype = Path.prototype;\n\nexport function pathRound(digits = 3) {\n return new Path(+digits);\n}\n", "import {Path} from \"d3-path\";\n\nexport function withPath(shape) {\n let digits = 3;\n\n shape.digits = function(_) {\n if (!arguments.length) return digits;\n if (_ == null) {\n digits = null;\n } else {\n const d = Math.floor(_);\n if (!(d >= 0)) throw new RangeError(`invalid digits: ${_}`);\n digits = d;\n }\n return shape;\n };\n\n return () => new Path(digits);\n}\n", "import constant from \"./constant.js\";\nimport {abs, acos, asin, atan2, cos, epsilon, halfPi, max, min, pi, sin, sqrt, tau} from \"./math.js\";\nimport {withPath} from \"./path.js\";\n\nfunction arcInnerRadius(d) {\n return d.innerRadius;\n}\n\nfunction arcOuterRadius(d) {\n return d.outerRadius;\n}\n\nfunction arcStartAngle(d) {\n return d.startAngle;\n}\n\nfunction arcEndAngle(d) {\n return d.endAngle;\n}\n\nfunction arcPadAngle(d) {\n return d && d.padAngle; // Note: optional!\n}\n\nfunction intersect(x0, y0, x1, y1, x2, y2, x3, y3) {\n var x10 = x1 - x0, y10 = y1 - y0,\n x32 = x3 - x2, y32 = y3 - y2,\n t = y32 * x10 - x32 * y10;\n if (t * t < epsilon) return;\n t = (x32 * (y0 - y2) - y32 * (x0 - x2)) / t;\n return [x0 + t * x10, y0 + t * y10];\n}\n\n// Compute perpendicular offset line of length rc.\n// http://mathworld.wolfram.com/Circle-LineIntersection.html\nfunction cornerTangents(x0, y0, x1, y1, r1, rc, cw) {\n var x01 = x0 - x1,\n y01 = y0 - y1,\n lo = (cw ? rc : -rc) / sqrt(x01 * x01 + y01 * y01),\n ox = lo * y01,\n oy = -lo * x01,\n x11 = x0 + ox,\n y11 = y0 + oy,\n x10 = x1 + ox,\n y10 = y1 + oy,\n x00 = (x11 + x10) / 2,\n y00 = (y11 + y10) / 2,\n dx = x10 - x11,\n dy = y10 - y11,\n d2 = dx * dx + dy * dy,\n r = r1 - rc,\n D = x11 * y10 - x10 * y11,\n d = (dy < 0 ? -1 : 1) * sqrt(max(0, r * r * d2 - D * D)),\n cx0 = (D * dy - dx * d) / d2,\n cy0 = (-D * dx - dy * d) / d2,\n cx1 = (D * dy + dx * d) / d2,\n cy1 = (-D * dx + dy * d) / d2,\n dx0 = cx0 - x00,\n dy0 = cy0 - y00,\n dx1 = cx1 - x00,\n dy1 = cy1 - y00;\n\n // Pick the closer of the two intersection points.\n // TODO Is there a faster way to determine which intersection to use?\n if (dx0 * dx0 + dy0 * dy0 > dx1 * dx1 + dy1 * dy1) cx0 = cx1, cy0 = cy1;\n\n return {\n cx: cx0,\n cy: cy0,\n x01: -ox,\n y01: -oy,\n x11: cx0 * (r1 / r - 1),\n y11: cy0 * (r1 / r - 1)\n };\n}\n\nexport default function() {\n var innerRadius = arcInnerRadius,\n outerRadius = arcOuterRadius,\n cornerRadius = constant(0),\n padRadius = null,\n startAngle = arcStartAngle,\n endAngle = arcEndAngle,\n padAngle = arcPadAngle,\n context = null,\n path = withPath(arc);\n\n function arc() {\n var buffer,\n r,\n r0 = +innerRadius.apply(this, arguments),\n r1 = +outerRadius.apply(this, arguments),\n a0 = startAngle.apply(this, arguments) - halfPi,\n a1 = endAngle.apply(this, arguments) - halfPi,\n da = abs(a1 - a0),\n cw = a1 > a0;\n\n if (!context) context = buffer = path();\n\n // Ensure that the outer radius is always larger than the inner radius.\n if (r1 < r0) r = r1, r1 = r0, r0 = r;\n\n // Is it a point?\n if (!(r1 > epsilon)) context.moveTo(0, 0);\n\n // Or is it a circle or annulus?\n else if (da > tau - epsilon) {\n context.moveTo(r1 * cos(a0), r1 * sin(a0));\n context.arc(0, 0, r1, a0, a1, !cw);\n if (r0 > epsilon) {\n context.moveTo(r0 * cos(a1), r0 * sin(a1));\n context.arc(0, 0, r0, a1, a0, cw);\n }\n }\n\n // Or is it a circular or annular sector?\n else {\n var a01 = a0,\n a11 = a1,\n a00 = a0,\n a10 = a1,\n da0 = da,\n da1 = da,\n ap = padAngle.apply(this, arguments) / 2,\n rp = (ap > epsilon) && (padRadius ? +padRadius.apply(this, arguments) : sqrt(r0 * r0 + r1 * r1)),\n rc = min(abs(r1 - r0) / 2, +cornerRadius.apply(this, arguments)),\n rc0 = rc,\n rc1 = rc,\n t0,\n t1;\n\n // Apply padding? Note that since r1 \u2265 r0, da1 \u2265 da0.\n if (rp > epsilon) {\n var p0 = asin(rp / r0 * sin(ap)),\n p1 = asin(rp / r1 * sin(ap));\n if ((da0 -= p0 * 2) > epsilon) p0 *= (cw ? 1 : -1), a00 += p0, a10 -= p0;\n else da0 = 0, a00 = a10 = (a0 + a1) / 2;\n if ((da1 -= p1 * 2) > epsilon) p1 *= (cw ? 1 : -1), a01 += p1, a11 -= p1;\n else da1 = 0, a01 = a11 = (a0 + a1) / 2;\n }\n\n var x01 = r1 * cos(a01),\n y01 = r1 * sin(a01),\n x10 = r0 * cos(a10),\n y10 = r0 * sin(a10);\n\n // Apply rounded corners?\n if (rc > epsilon) {\n var x11 = r1 * cos(a11),\n y11 = r1 * sin(a11),\n x00 = r0 * cos(a00),\n y00 = r0 * sin(a00),\n oc;\n\n // Restrict the corner radius according to the sector angle. If this\n // intersection fails, it\u2019s probably because the arc is too small, so\n // disable the corner radius entirely.\n if (da < pi) {\n if (oc = intersect(x01, y01, x00, y00, x11, y11, x10, y10)) {\n var ax = x01 - oc[0],\n ay = y01 - oc[1],\n bx = x11 - oc[0],\n by = y11 - oc[1],\n kc = 1 / sin(acos((ax * bx + ay * by) / (sqrt(ax * ax + ay * ay) * sqrt(bx * bx + by * by))) / 2),\n lc = sqrt(oc[0] * oc[0] + oc[1] * oc[1]);\n rc0 = min(rc, (r0 - lc) / (kc - 1));\n rc1 = min(rc, (r1 - lc) / (kc + 1));\n } else {\n rc0 = rc1 = 0;\n }\n }\n }\n\n // Is the sector collapsed to a line?\n if (!(da1 > epsilon)) context.moveTo(x01, y01);\n\n // Does the sector\u2019s outer ring have rounded corners?\n else if (rc1 > epsilon) {\n t0 = cornerTangents(x00, y00, x01, y01, r1, rc1, cw);\n t1 = cornerTangents(x11, y11, x10, y10, r1, rc1, cw);\n\n context.moveTo(t0.cx + t0.x01, t0.cy + t0.y01);\n\n // Have the corners merged?\n if (rc1 < rc) context.arc(t0.cx, t0.cy, rc1, atan2(t0.y01, t0.x01), atan2(t1.y01, t1.x01), !cw);\n\n // Otherwise, draw the two corners and the ring.\n else {\n context.arc(t0.cx, t0.cy, rc1, atan2(t0.y01, t0.x01), atan2(t0.y11, t0.x11), !cw);\n context.arc(0, 0, r1, atan2(t0.cy + t0.y11, t0.cx + t0.x11), atan2(t1.cy + t1.y11, t1.cx + t1.x11), !cw);\n context.arc(t1.cx, t1.cy, rc1, atan2(t1.y11, t1.x11), atan2(t1.y01, t1.x01), !cw);\n }\n }\n\n // Or is the outer ring just a circular arc?\n else context.moveTo(x01, y01), context.arc(0, 0, r1, a01, a11, !cw);\n\n // Is there no inner ring, and it\u2019s a circular sector?\n // Or perhaps it\u2019s an annular sector collapsed due to padding?\n if (!(r0 > epsilon) || !(da0 > epsilon)) context.lineTo(x10, y10);\n\n // Does the sector\u2019s inner ring (or point) have rounded corners?\n else if (rc0 > epsilon) {\n t0 = cornerTangents(x10, y10, x11, y11, r0, -rc0, cw);\n t1 = cornerTangents(x01, y01, x00, y00, r0, -rc0, cw);\n\n context.lineTo(t0.cx + t0.x01, t0.cy + t0.y01);\n\n // Have the corners merged?\n if (rc0 < rc) context.arc(t0.cx, t0.cy, rc0, atan2(t0.y01, t0.x01), atan2(t1.y01, t1.x01), !cw);\n\n // Otherwise, draw the two corners and the ring.\n else {\n context.arc(t0.cx, t0.cy, rc0, atan2(t0.y01, t0.x01), atan2(t0.y11, t0.x11), !cw);\n context.arc(0, 0, r0, atan2(t0.cy + t0.y11, t0.cx + t0.x11), atan2(t1.cy + t1.y11, t1.cx + t1.x11), cw);\n context.arc(t1.cx, t1.cy, rc0, atan2(t1.y11, t1.x11), atan2(t1.y01, t1.x01), !cw);\n }\n }\n\n // Or is the inner ring just a circular arc?\n else context.arc(0, 0, r0, a10, a00, cw);\n }\n\n context.closePath();\n\n if (buffer) return context = null, buffer + \"\" || null;\n }\n\n arc.centroid = function() {\n var r = (+innerRadius.apply(this, arguments) + +outerRadius.apply(this, arguments)) / 2,\n a = (+startAngle.apply(this, arguments) + +endAngle.apply(this, arguments)) / 2 - pi / 2;\n return [cos(a) * r, sin(a) * r];\n };\n\n arc.innerRadius = function(_) {\n return arguments.length ? (innerRadius = typeof _ === \"function\" ? _ : constant(+_), arc) : innerRadius;\n };\n\n arc.outerRadius = function(_) {\n return arguments.length ? (outerRadius = typeof _ === \"function\" ? _ : constant(+_), arc) : outerRadius;\n };\n\n arc.cornerRadius = function(_) {\n return arguments.length ? (cornerRadius = typeof _ === \"function\" ? _ : constant(+_), arc) : cornerRadius;\n };\n\n arc.padRadius = function(_) {\n return arguments.length ? (padRadius = _ == null ? null : typeof _ === \"function\" ? _ : constant(+_), arc) : padRadius;\n };\n\n arc.startAngle = function(_) {\n return arguments.length ? (startAngle = typeof _ === \"function\" ? _ : constant(+_), arc) : startAngle;\n };\n\n arc.endAngle = function(_) {\n return arguments.length ? (endAngle = typeof _ === \"function\" ? _ : constant(+_), arc) : endAngle;\n };\n\n arc.padAngle = function(_) {\n return arguments.length ? (padAngle = typeof _ === \"function\" ? _ : constant(+_), arc) : padAngle;\n };\n\n arc.context = function(_) {\n return arguments.length ? ((context = _ == null ? null : _), arc) : context;\n };\n\n return arc;\n}\n", "function Linear(context) {\n this._context = context;\n}\n\nLinear.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; // falls through\n default: this._context.lineTo(x, y); break;\n }\n }\n};\n\nexport default function(context) {\n return new Linear(context);\n}\n", "export var slice = Array.prototype.slice;\n\nexport default function(x) {\n return typeof x === \"object\" && \"length\" in x\n ? x // Array, TypedArray, NodeList, array-like\n : Array.from(x); // Map, Set, iterable, string, or anything else\n}\n", "export function x(p) {\n return p[0];\n}\n\nexport function y(p) {\n return p[1];\n}\n", "import array from \"./array.js\";\nimport constant from \"./constant.js\";\nimport curveLinear from \"./curve/linear.js\";\nimport {withPath} from \"./path.js\";\nimport {x as pointX, y as pointY} from \"./point.js\";\n\nexport default function(x, y) {\n var defined = constant(true),\n context = null,\n curve = curveLinear,\n output = null,\n path = withPath(line);\n\n x = typeof x === \"function\" ? x : (x === undefined) ? pointX : constant(x);\n y = typeof y === \"function\" ? y : (y === undefined) ? pointY : constant(y);\n\n function line(data) {\n var i,\n n = (data = array(data)).length,\n d,\n defined0 = false,\n buffer;\n\n if (context == null) output = curve(buffer = path());\n\n for (i = 0; i <= n; ++i) {\n if (!(i < n && defined(d = data[i], i, data)) === defined0) {\n if (defined0 = !defined0) output.lineStart();\n else output.lineEnd();\n }\n if (defined0) output.point(+x(d, i, data), +y(d, i, data));\n }\n\n if (buffer) return output = null, buffer + \"\" || null;\n }\n\n line.x = function(_) {\n return arguments.length ? (x = typeof _ === \"function\" ? _ : constant(+_), line) : x;\n };\n\n line.y = function(_) {\n return arguments.length ? (y = typeof _ === \"function\" ? _ : constant(+_), line) : y;\n };\n\n line.defined = function(_) {\n return arguments.length ? (defined = typeof _ === \"function\" ? _ : constant(!!_), line) : defined;\n };\n\n line.curve = function(_) {\n return arguments.length ? (curve = _, context != null && (output = curve(context)), line) : curve;\n };\n\n line.context = function(_) {\n return arguments.length ? (_ == null ? context = output = null : output = curve(context = _), line) : context;\n };\n\n return line;\n}\n", "export default function(a, b) {\n return b < a ? -1 : b > a ? 1 : b >= a ? 0 : NaN;\n}\n", "export default function(d) {\n return d;\n}\n", "import array from \"./array.js\";\nimport constant from \"./constant.js\";\nimport descending from \"./descending.js\";\nimport identity from \"./identity.js\";\nimport {tau} from \"./math.js\";\n\nexport default function() {\n var value = identity,\n sortValues = descending,\n sort = null,\n startAngle = constant(0),\n endAngle = constant(tau),\n padAngle = constant(0);\n\n function pie(data) {\n var i,\n n = (data = array(data)).length,\n j,\n k,\n sum = 0,\n index = new Array(n),\n arcs = new Array(n),\n a0 = +startAngle.apply(this, arguments),\n da = Math.min(tau, Math.max(-tau, endAngle.apply(this, arguments) - a0)),\n a1,\n p = Math.min(Math.abs(da) / n, padAngle.apply(this, arguments)),\n pa = p * (da < 0 ? -1 : 1),\n v;\n\n for (i = 0; i < n; ++i) {\n if ((v = arcs[index[i] = i] = +value(data[i], i, data)) > 0) {\n sum += v;\n }\n }\n\n // Optionally sort the arcs by previously-computed values or by data.\n if (sortValues != null) index.sort(function(i, j) { return sortValues(arcs[i], arcs[j]); });\n else if (sort != null) index.sort(function(i, j) { return sort(data[i], data[j]); });\n\n // Compute the arcs! They are stored in the original data's order.\n for (i = 0, k = sum ? (da - n * pa) / sum : 0; i < n; ++i, a0 = a1) {\n j = index[i], v = arcs[j], a1 = a0 + (v > 0 ? v * k : 0) + pa, arcs[j] = {\n data: data[j],\n index: i,\n value: v,\n startAngle: a0,\n endAngle: a1,\n padAngle: p\n };\n }\n\n return arcs;\n }\n\n pie.value = function(_) {\n return arguments.length ? (value = typeof _ === \"function\" ? _ : constant(+_), pie) : value;\n };\n\n pie.sortValues = function(_) {\n return arguments.length ? (sortValues = _, sort = null, pie) : sortValues;\n };\n\n pie.sort = function(_) {\n return arguments.length ? (sort = _, sortValues = null, pie) : sort;\n };\n\n pie.startAngle = function(_) {\n return arguments.length ? (startAngle = typeof _ === \"function\" ? _ : constant(+_), pie) : startAngle;\n };\n\n pie.endAngle = function(_) {\n return arguments.length ? (endAngle = typeof _ === \"function\" ? _ : constant(+_), pie) : endAngle;\n };\n\n pie.padAngle = function(_) {\n return arguments.length ? (padAngle = typeof _ === \"function\" ? _ : constant(+_), pie) : padAngle;\n };\n\n return pie;\n}\n", "export function point(that, x, y) {\n that._context.bezierCurveTo(\n (2 * that._x0 + that._x1) / 3,\n (2 * that._y0 + that._y1) / 3,\n (that._x0 + 2 * that._x1) / 3,\n (that._y0 + 2 * that._y1) / 3,\n (that._x0 + 4 * that._x1 + x) / 6,\n (that._y0 + 4 * that._y1 + y) / 6\n );\n}\n\nexport function Basis(context) {\n this._context = context;\n}\n\nBasis.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 =\n this._y0 = this._y1 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 3: point(this, this._x1, this._y1); // falls through\n case 2: this._context.lineTo(this._x1, this._y1); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; this._context.lineTo((5 * this._x0 + this._x1) / 6, (5 * this._y0 + this._y1) / 6); // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n }\n};\n\nexport default function(context) {\n return new Basis(context);\n}\n", "import pointRadial from \"../pointRadial.js\";\n\nclass Bump {\n constructor(context, x) {\n this._context = context;\n this._x = x;\n }\n areaStart() {\n this._line = 0;\n }\n areaEnd() {\n this._line = NaN;\n }\n lineStart() {\n this._point = 0;\n }\n lineEnd() {\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n }\n point(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: {\n this._point = 1;\n if (this._line) this._context.lineTo(x, y);\n else this._context.moveTo(x, y);\n break;\n }\n case 1: this._point = 2; // falls through\n default: {\n if (this._x) this._context.bezierCurveTo(this._x0 = (this._x0 + x) / 2, this._y0, this._x0, y, x, y);\n else this._context.bezierCurveTo(this._x0, this._y0 = (this._y0 + y) / 2, x, this._y0, x, y);\n break;\n }\n }\n this._x0 = x, this._y0 = y;\n }\n}\n\nclass BumpRadial {\n constructor(context) {\n this._context = context;\n }\n lineStart() {\n this._point = 0;\n }\n lineEnd() {}\n point(x, y) {\n x = +x, y = +y;\n if (this._point === 0) {\n this._point = 1;\n } else {\n const p0 = pointRadial(this._x0, this._y0);\n const p1 = pointRadial(this._x0, this._y0 = (this._y0 + y) / 2);\n const p2 = pointRadial(x, this._y0);\n const p3 = pointRadial(x, y);\n this._context.moveTo(...p0);\n this._context.bezierCurveTo(...p1, ...p2, ...p3);\n }\n this._x0 = x, this._y0 = y;\n }\n}\n\nexport function bumpX(context) {\n return new Bump(context, true);\n}\n\nexport function bumpY(context) {\n return new Bump(context, false);\n}\n\nexport function bumpRadial(context) {\n return new BumpRadial(context);\n}\n", "export default function() {}\n", "import noop from \"../noop.js\";\nimport {point} from \"./basis.js\";\n\nfunction BasisClosed(context) {\n this._context = context;\n}\n\nBasisClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._x0 = this._x1 = this._x2 = this._x3 = this._x4 =\n this._y0 = this._y1 = this._y2 = this._y3 = this._y4 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 1: {\n this._context.moveTo(this._x2, this._y2);\n this._context.closePath();\n break;\n }\n case 2: {\n this._context.moveTo((this._x2 + 2 * this._x3) / 3, (this._y2 + 2 * this._y3) / 3);\n this._context.lineTo((this._x3 + 2 * this._x2) / 3, (this._y3 + 2 * this._y2) / 3);\n this._context.closePath();\n break;\n }\n case 3: {\n this.point(this._x2, this._y2);\n this.point(this._x3, this._y3);\n this.point(this._x4, this._y4);\n break;\n }\n }\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._x2 = x, this._y2 = y; break;\n case 1: this._point = 2; this._x3 = x, this._y3 = y; break;\n case 2: this._point = 3; this._x4 = x, this._y4 = y; this._context.moveTo((this._x0 + 4 * this._x1 + x) / 6, (this._y0 + 4 * this._y1 + y) / 6); break;\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n }\n};\n\nexport default function(context) {\n return new BasisClosed(context);\n}\n", "import {point} from \"./basis.js\";\n\nfunction BasisOpen(context) {\n this._context = context;\n}\n\nBasisOpen.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 =\n this._y0 = this._y1 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 3)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; var x0 = (this._x0 + 4 * this._x1 + x) / 6, y0 = (this._y0 + 4 * this._y1 + y) / 6; this._line ? this._context.lineTo(x0, y0) : this._context.moveTo(x0, y0); break;\n case 3: this._point = 4; // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n }\n};\n\nexport default function(context) {\n return new BasisOpen(context);\n}\n", "import {Basis} from \"./basis.js\";\n\nfunction Bundle(context, beta) {\n this._basis = new Basis(context);\n this._beta = beta;\n}\n\nBundle.prototype = {\n lineStart: function() {\n this._x = [];\n this._y = [];\n this._basis.lineStart();\n },\n lineEnd: function() {\n var x = this._x,\n y = this._y,\n j = x.length - 1;\n\n if (j > 0) {\n var x0 = x[0],\n y0 = y[0],\n dx = x[j] - x0,\n dy = y[j] - y0,\n i = -1,\n t;\n\n while (++i <= j) {\n t = i / j;\n this._basis.point(\n this._beta * x[i] + (1 - this._beta) * (x0 + t * dx),\n this._beta * y[i] + (1 - this._beta) * (y0 + t * dy)\n );\n }\n }\n\n this._x = this._y = null;\n this._basis.lineEnd();\n },\n point: function(x, y) {\n this._x.push(+x);\n this._y.push(+y);\n }\n};\n\nexport default (function custom(beta) {\n\n function bundle(context) {\n return beta === 1 ? new Basis(context) : new Bundle(context, beta);\n }\n\n bundle.beta = function(beta) {\n return custom(+beta);\n };\n\n return bundle;\n})(0.85);\n", "export function point(that, x, y) {\n that._context.bezierCurveTo(\n that._x1 + that._k * (that._x2 - that._x0),\n that._y1 + that._k * (that._y2 - that._y0),\n that._x2 + that._k * (that._x1 - x),\n that._y2 + that._k * (that._y1 - y),\n that._x2,\n that._y2\n );\n}\n\nexport function Cardinal(context, tension) {\n this._context = context;\n this._k = (1 - tension) / 6;\n}\n\nCardinal.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 2: this._context.lineTo(this._x2, this._y2); break;\n case 3: point(this, this._x1, this._y1); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; this._x1 = x, this._y1 = y; break;\n case 2: this._point = 3; // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(tension) {\n\n function cardinal(context) {\n return new Cardinal(context, tension);\n }\n\n cardinal.tension = function(tension) {\n return custom(+tension);\n };\n\n return cardinal;\n})(0);\n", "import noop from \"../noop.js\";\nimport {point} from \"./cardinal.js\";\n\nexport function CardinalClosed(context, tension) {\n this._context = context;\n this._k = (1 - tension) / 6;\n}\n\nCardinalClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._x0 = this._x1 = this._x2 = this._x3 = this._x4 = this._x5 =\n this._y0 = this._y1 = this._y2 = this._y3 = this._y4 = this._y5 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 1: {\n this._context.moveTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 2: {\n this._context.lineTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 3: {\n this.point(this._x3, this._y3);\n this.point(this._x4, this._y4);\n this.point(this._x5, this._y5);\n break;\n }\n }\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._x3 = x, this._y3 = y; break;\n case 1: this._point = 2; this._context.moveTo(this._x4 = x, this._y4 = y); break;\n case 2: this._point = 3; this._x5 = x, this._y5 = y; break;\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(tension) {\n\n function cardinal(context) {\n return new CardinalClosed(context, tension);\n }\n\n cardinal.tension = function(tension) {\n return custom(+tension);\n };\n\n return cardinal;\n})(0);\n", "import {point} from \"./cardinal.js\";\n\nexport function CardinalOpen(context, tension) {\n this._context = context;\n this._k = (1 - tension) / 6;\n}\n\nCardinalOpen.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 3)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; this._line ? this._context.lineTo(this._x2, this._y2) : this._context.moveTo(this._x2, this._y2); break;\n case 3: this._point = 4; // falls through\n default: point(this, x, y); break;\n }\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(tension) {\n\n function cardinal(context) {\n return new CardinalOpen(context, tension);\n }\n\n cardinal.tension = function(tension) {\n return custom(+tension);\n };\n\n return cardinal;\n})(0);\n", "import {epsilon} from \"../math.js\";\nimport {Cardinal} from \"./cardinal.js\";\n\nexport function point(that, x, y) {\n var x1 = that._x1,\n y1 = that._y1,\n x2 = that._x2,\n y2 = that._y2;\n\n if (that._l01_a > epsilon) {\n var a = 2 * that._l01_2a + 3 * that._l01_a * that._l12_a + that._l12_2a,\n n = 3 * that._l01_a * (that._l01_a + that._l12_a);\n x1 = (x1 * a - that._x0 * that._l12_2a + that._x2 * that._l01_2a) / n;\n y1 = (y1 * a - that._y0 * that._l12_2a + that._y2 * that._l01_2a) / n;\n }\n\n if (that._l23_a > epsilon) {\n var b = 2 * that._l23_2a + 3 * that._l23_a * that._l12_a + that._l12_2a,\n m = 3 * that._l23_a * (that._l23_a + that._l12_a);\n x2 = (x2 * b + that._x1 * that._l23_2a - x * that._l12_2a) / m;\n y2 = (y2 * b + that._y1 * that._l23_2a - y * that._l12_2a) / m;\n }\n\n that._context.bezierCurveTo(x1, y1, x2, y2, that._x2, that._y2);\n}\n\nfunction CatmullRom(context, alpha) {\n this._context = context;\n this._alpha = alpha;\n}\n\nCatmullRom.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._l01_a = this._l12_a = this._l23_a =\n this._l01_2a = this._l12_2a = this._l23_2a =\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 2: this._context.lineTo(this._x2, this._y2); break;\n case 3: this.point(this._x2, this._y2); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n\n if (this._point) {\n var x23 = this._x2 - x,\n y23 = this._y2 - y;\n this._l23_a = Math.sqrt(this._l23_2a = Math.pow(x23 * x23 + y23 * y23, this._alpha));\n }\n\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; // falls through\n default: point(this, x, y); break;\n }\n\n this._l01_a = this._l12_a, this._l12_a = this._l23_a;\n this._l01_2a = this._l12_2a, this._l12_2a = this._l23_2a;\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(alpha) {\n\n function catmullRom(context) {\n return alpha ? new CatmullRom(context, alpha) : new Cardinal(context, 0);\n }\n\n catmullRom.alpha = function(alpha) {\n return custom(+alpha);\n };\n\n return catmullRom;\n})(0.5);\n", "import {CardinalClosed} from \"./cardinalClosed.js\";\nimport noop from \"../noop.js\";\nimport {point} from \"./catmullRom.js\";\n\nfunction CatmullRomClosed(context, alpha) {\n this._context = context;\n this._alpha = alpha;\n}\n\nCatmullRomClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._x0 = this._x1 = this._x2 = this._x3 = this._x4 = this._x5 =\n this._y0 = this._y1 = this._y2 = this._y3 = this._y4 = this._y5 = NaN;\n this._l01_a = this._l12_a = this._l23_a =\n this._l01_2a = this._l12_2a = this._l23_2a =\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 1: {\n this._context.moveTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 2: {\n this._context.lineTo(this._x3, this._y3);\n this._context.closePath();\n break;\n }\n case 3: {\n this.point(this._x3, this._y3);\n this.point(this._x4, this._y4);\n this.point(this._x5, this._y5);\n break;\n }\n }\n },\n point: function(x, y) {\n x = +x, y = +y;\n\n if (this._point) {\n var x23 = this._x2 - x,\n y23 = this._y2 - y;\n this._l23_a = Math.sqrt(this._l23_2a = Math.pow(x23 * x23 + y23 * y23, this._alpha));\n }\n\n switch (this._point) {\n case 0: this._point = 1; this._x3 = x, this._y3 = y; break;\n case 1: this._point = 2; this._context.moveTo(this._x4 = x, this._y4 = y); break;\n case 2: this._point = 3; this._x5 = x, this._y5 = y; break;\n default: point(this, x, y); break;\n }\n\n this._l01_a = this._l12_a, this._l12_a = this._l23_a;\n this._l01_2a = this._l12_2a, this._l12_2a = this._l23_2a;\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(alpha) {\n\n function catmullRom(context) {\n return alpha ? new CatmullRomClosed(context, alpha) : new CardinalClosed(context, 0);\n }\n\n catmullRom.alpha = function(alpha) {\n return custom(+alpha);\n };\n\n return catmullRom;\n})(0.5);\n", "import {CardinalOpen} from \"./cardinalOpen.js\";\nimport {point} from \"./catmullRom.js\";\n\nfunction CatmullRomOpen(context, alpha) {\n this._context = context;\n this._alpha = alpha;\n}\n\nCatmullRomOpen.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 = this._x2 =\n this._y0 = this._y1 = this._y2 = NaN;\n this._l01_a = this._l12_a = this._l23_a =\n this._l01_2a = this._l12_2a = this._l23_2a =\n this._point = 0;\n },\n lineEnd: function() {\n if (this._line || (this._line !== 0 && this._point === 3)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n\n if (this._point) {\n var x23 = this._x2 - x,\n y23 = this._y2 - y;\n this._l23_a = Math.sqrt(this._l23_2a = Math.pow(x23 * x23 + y23 * y23, this._alpha));\n }\n\n switch (this._point) {\n case 0: this._point = 1; break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; this._line ? this._context.lineTo(this._x2, this._y2) : this._context.moveTo(this._x2, this._y2); break;\n case 3: this._point = 4; // falls through\n default: point(this, x, y); break;\n }\n\n this._l01_a = this._l12_a, this._l12_a = this._l23_a;\n this._l01_2a = this._l12_2a, this._l12_2a = this._l23_2a;\n this._x0 = this._x1, this._x1 = this._x2, this._x2 = x;\n this._y0 = this._y1, this._y1 = this._y2, this._y2 = y;\n }\n};\n\nexport default (function custom(alpha) {\n\n function catmullRom(context) {\n return alpha ? new CatmullRomOpen(context, alpha) : new CardinalOpen(context, 0);\n }\n\n catmullRom.alpha = function(alpha) {\n return custom(+alpha);\n };\n\n return catmullRom;\n})(0.5);\n", "import noop from \"../noop.js\";\n\nfunction LinearClosed(context) {\n this._context = context;\n}\n\nLinearClosed.prototype = {\n areaStart: noop,\n areaEnd: noop,\n lineStart: function() {\n this._point = 0;\n },\n lineEnd: function() {\n if (this._point) this._context.closePath();\n },\n point: function(x, y) {\n x = +x, y = +y;\n if (this._point) this._context.lineTo(x, y);\n else this._point = 1, this._context.moveTo(x, y);\n }\n};\n\nexport default function(context) {\n return new LinearClosed(context);\n}\n", "function sign(x) {\n return x < 0 ? -1 : 1;\n}\n\n// Calculate the slopes of the tangents (Hermite-type interpolation) based on\n// the following paper: Steffen, M. 1990. A Simple Method for Monotonic\n// Interpolation in One Dimension. Astronomy and Astrophysics, Vol. 239, NO.\n// NOV(II), P. 443, 1990.\nfunction slope3(that, x2, y2) {\n var h0 = that._x1 - that._x0,\n h1 = x2 - that._x1,\n s0 = (that._y1 - that._y0) / (h0 || h1 < 0 && -0),\n s1 = (y2 - that._y1) / (h1 || h0 < 0 && -0),\n p = (s0 * h1 + s1 * h0) / (h0 + h1);\n return (sign(s0) + sign(s1)) * Math.min(Math.abs(s0), Math.abs(s1), 0.5 * Math.abs(p)) || 0;\n}\n\n// Calculate a one-sided slope.\nfunction slope2(that, t) {\n var h = that._x1 - that._x0;\n return h ? (3 * (that._y1 - that._y0) / h - t) / 2 : t;\n}\n\n// According to https://en.wikipedia.org/wiki/Cubic_Hermite_spline#Representations\n// \"you can express cubic Hermite interpolation in terms of cubic B\u00E9zier curves\n// with respect to the four values p0, p0 + m0 / 3, p1 - m1 / 3, p1\".\nfunction point(that, t0, t1) {\n var x0 = that._x0,\n y0 = that._y0,\n x1 = that._x1,\n y1 = that._y1,\n dx = (x1 - x0) / 3;\n that._context.bezierCurveTo(x0 + dx, y0 + dx * t0, x1 - dx, y1 - dx * t1, x1, y1);\n}\n\nfunction MonotoneX(context) {\n this._context = context;\n}\n\nMonotoneX.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x0 = this._x1 =\n this._y0 = this._y1 =\n this._t0 = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n switch (this._point) {\n case 2: this._context.lineTo(this._x1, this._y1); break;\n case 3: point(this, this._t0, slope2(this, this._t0)); break;\n }\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n this._line = 1 - this._line;\n },\n point: function(x, y) {\n var t1 = NaN;\n\n x = +x, y = +y;\n if (x === this._x1 && y === this._y1) return; // Ignore coincident points.\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; break;\n case 2: this._point = 3; point(this, slope2(this, t1 = slope3(this, x, y)), t1); break;\n default: point(this, this._t0, t1 = slope3(this, x, y)); break;\n }\n\n this._x0 = this._x1, this._x1 = x;\n this._y0 = this._y1, this._y1 = y;\n this._t0 = t1;\n }\n}\n\nfunction MonotoneY(context) {\n this._context = new ReflectContext(context);\n}\n\n(MonotoneY.prototype = Object.create(MonotoneX.prototype)).point = function(x, y) {\n MonotoneX.prototype.point.call(this, y, x);\n};\n\nfunction ReflectContext(context) {\n this._context = context;\n}\n\nReflectContext.prototype = {\n moveTo: function(x, y) { this._context.moveTo(y, x); },\n closePath: function() { this._context.closePath(); },\n lineTo: function(x, y) { this._context.lineTo(y, x); },\n bezierCurveTo: function(x1, y1, x2, y2, x, y) { this._context.bezierCurveTo(y1, x1, y2, x2, y, x); }\n};\n\nexport function monotoneX(context) {\n return new MonotoneX(context);\n}\n\nexport function monotoneY(context) {\n return new MonotoneY(context);\n}\n", "function Natural(context) {\n this._context = context;\n}\n\nNatural.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x = [];\n this._y = [];\n },\n lineEnd: function() {\n var x = this._x,\n y = this._y,\n n = x.length;\n\n if (n) {\n this._line ? this._context.lineTo(x[0], y[0]) : this._context.moveTo(x[0], y[0]);\n if (n === 2) {\n this._context.lineTo(x[1], y[1]);\n } else {\n var px = controlPoints(x),\n py = controlPoints(y);\n for (var i0 = 0, i1 = 1; i1 < n; ++i0, ++i1) {\n this._context.bezierCurveTo(px[0][i0], py[0][i0], px[1][i0], py[1][i0], x[i1], y[i1]);\n }\n }\n }\n\n if (this._line || (this._line !== 0 && n === 1)) this._context.closePath();\n this._line = 1 - this._line;\n this._x = this._y = null;\n },\n point: function(x, y) {\n this._x.push(+x);\n this._y.push(+y);\n }\n};\n\n// See https://www.particleincell.com/2012/bezier-splines/ for derivation.\nfunction controlPoints(x) {\n var i,\n n = x.length - 1,\n m,\n a = new Array(n),\n b = new Array(n),\n r = new Array(n);\n a[0] = 0, b[0] = 2, r[0] = x[0] + 2 * x[1];\n for (i = 1; i < n - 1; ++i) a[i] = 1, b[i] = 4, r[i] = 4 * x[i] + 2 * x[i + 1];\n a[n - 1] = 2, b[n - 1] = 7, r[n - 1] = 8 * x[n - 1] + x[n];\n for (i = 1; i < n; ++i) m = a[i] / b[i - 1], b[i] -= m, r[i] -= m * r[i - 1];\n a[n - 1] = r[n - 1] / b[n - 1];\n for (i = n - 2; i >= 0; --i) a[i] = (r[i] - a[i + 1]) / b[i];\n b[n - 1] = (x[n] + a[n - 1]) / 2;\n for (i = 0; i < n - 1; ++i) b[i] = 2 * x[i + 1] - a[i + 1];\n return [a, b];\n}\n\nexport default function(context) {\n return new Natural(context);\n}\n", "function Step(context, t) {\n this._context = context;\n this._t = t;\n}\n\nStep.prototype = {\n areaStart: function() {\n this._line = 0;\n },\n areaEnd: function() {\n this._line = NaN;\n },\n lineStart: function() {\n this._x = this._y = NaN;\n this._point = 0;\n },\n lineEnd: function() {\n if (0 < this._t && this._t < 1 && this._point === 2) this._context.lineTo(this._x, this._y);\n if (this._line || (this._line !== 0 && this._point === 1)) this._context.closePath();\n if (this._line >= 0) this._t = 1 - this._t, this._line = 1 - this._line;\n },\n point: function(x, y) {\n x = +x, y = +y;\n switch (this._point) {\n case 0: this._point = 1; this._line ? this._context.lineTo(x, y) : this._context.moveTo(x, y); break;\n case 1: this._point = 2; // falls through\n default: {\n if (this._t <= 0) {\n this._context.lineTo(this._x, y);\n this._context.lineTo(x, y);\n } else {\n var x1 = this._x * (1 - this._t) + x * this._t;\n this._context.lineTo(x1, this._y);\n this._context.lineTo(x1, y);\n }\n break;\n }\n }\n this._x = x, this._y = y;\n }\n};\n\nexport default function(context) {\n return new Step(context, 0.5);\n}\n\nexport function stepBefore(context) {\n return new Step(context, 0);\n}\n\nexport function stepAfter(context) {\n return new Step(context, 1);\n}\n", "var noop = {value: () => {}};\n\nfunction dispatch() {\n for (var i = 0, n = arguments.length, _ = {}, t; i < n; ++i) {\n if (!(t = arguments[i] + \"\") || (t in _) || /[\\s.]/.test(t)) throw new Error(\"illegal type: \" + t);\n _[t] = [];\n }\n return new Dispatch(_);\n}\n\nfunction Dispatch(_) {\n this._ = _;\n}\n\nfunction parseTypenames(typenames, types) {\n return typenames.trim().split(/^|\\s+/).map(function(t) {\n var name = \"\", i = t.indexOf(\".\");\n if (i >= 0) name = t.slice(i + 1), t = t.slice(0, i);\n if (t && !types.hasOwnProperty(t)) throw new Error(\"unknown type: \" + t);\n return {type: t, name: name};\n });\n}\n\nDispatch.prototype = dispatch.prototype = {\n constructor: Dispatch,\n on: function(typename, callback) {\n var _ = this._,\n T = parseTypenames(typename + \"\", _),\n t,\n i = -1,\n n = T.length;\n\n // If no callback was specified, return the callback of the given type and name.\n if (arguments.length < 2) {\n while (++i < n) if ((t = (typename = T[i]).type) && (t = get(_[t], typename.name))) return t;\n return;\n }\n\n // If a type was specified, set the callback for the given type and name.\n // Otherwise, if a null callback was specified, remove callbacks of the given name.\n if (callback != null && typeof callback !== \"function\") throw new Error(\"invalid callback: \" + callback);\n while (++i < n) {\n if (t = (typename = T[i]).type) _[t] = set(_[t], typename.name, callback);\n else if (callback == null) for (t in _) _[t] = set(_[t], typename.name, null);\n }\n\n return this;\n },\n copy: function() {\n var copy = {}, _ = this._;\n for (var t in _) copy[t] = _[t].slice();\n return new Dispatch(copy);\n },\n call: function(type, that) {\n if ((n = arguments.length - 2) > 0) for (var args = new Array(n), i = 0, n, t; i < n; ++i) args[i] = arguments[i + 2];\n if (!this._.hasOwnProperty(type)) throw new Error(\"unknown type: \" + type);\n for (t = this._[type], i = 0, n = t.length; i < n; ++i) t[i].value.apply(that, args);\n },\n apply: function(type, that, args) {\n if (!this._.hasOwnProperty(type)) throw new Error(\"unknown type: \" + type);\n for (var t = this._[type], i = 0, n = t.length; i < n; ++i) t[i].value.apply(that, args);\n }\n};\n\nfunction get(type, name) {\n for (var i = 0, n = type.length, c; i < n; ++i) {\n if ((c = type[i]).name === name) {\n return c.value;\n }\n }\n}\n\nfunction set(type, name, callback) {\n for (var i = 0, n = type.length; i < n; ++i) {\n if (type[i].name === name) {\n type[i] = noop, type = type.slice(0, i).concat(type.slice(i + 1));\n break;\n }\n }\n if (callback != null) type.push({name: name, value: callback});\n return type;\n}\n\nexport default dispatch;\n", "var frame = 0, // is an animation frame pending?\n timeout = 0, // is a timeout pending?\n interval = 0, // are any timers active?\n pokeDelay = 1000, // how frequently we check for clock skew\n taskHead,\n taskTail,\n clockLast = 0,\n clockNow = 0,\n clockSkew = 0,\n clock = typeof performance === \"object\" && performance.now ? performance : Date,\n setFrame = typeof window === \"object\" && window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) : function(f) { setTimeout(f, 17); };\n\nexport function now() {\n return clockNow || (setFrame(clearNow), clockNow = clock.now() + clockSkew);\n}\n\nfunction clearNow() {\n clockNow = 0;\n}\n\nexport function Timer() {\n this._call =\n this._time =\n this._next = null;\n}\n\nTimer.prototype = timer.prototype = {\n constructor: Timer,\n restart: function(callback, delay, time) {\n if (typeof callback !== \"function\") throw new TypeError(\"callback is not a function\");\n time = (time == null ? now() : +time) + (delay == null ? 0 : +delay);\n if (!this._next && taskTail !== this) {\n if (taskTail) taskTail._next = this;\n else taskHead = this;\n taskTail = this;\n }\n this._call = callback;\n this._time = time;\n sleep();\n },\n stop: function() {\n if (this._call) {\n this._call = null;\n this._time = Infinity;\n sleep();\n }\n }\n};\n\nexport function timer(callback, delay, time) {\n var t = new Timer;\n t.restart(callback, delay, time);\n return t;\n}\n\nexport function timerFlush() {\n now(); // Get the current time, if not already set.\n ++frame; // Pretend we\u2019ve set an alarm, if we haven\u2019t already.\n var t = taskHead, e;\n while (t) {\n if ((e = clockNow - t._time) >= 0) t._call.call(undefined, e);\n t = t._next;\n }\n --frame;\n}\n\nfunction wake() {\n clockNow = (clockLast = clock.now()) + clockSkew;\n frame = timeout = 0;\n try {\n timerFlush();\n } finally {\n frame = 0;\n nap();\n clockNow = 0;\n }\n}\n\nfunction poke() {\n var now = clock.now(), delay = now - clockLast;\n if (delay > pokeDelay) clockSkew -= delay, clockLast = now;\n}\n\nfunction nap() {\n var t0, t1 = taskHead, t2, time = Infinity;\n while (t1) {\n if (t1._call) {\n if (time > t1._time) time = t1._time;\n t0 = t1, t1 = t1._next;\n } else {\n t2 = t1._next, t1._next = null;\n t1 = t0 ? t0._next = t2 : taskHead = t2;\n }\n }\n taskTail = t0;\n sleep(time);\n}\n\nfunction sleep(time) {\n if (frame) return; // Soonest alarm already set, or will be.\n if (timeout) timeout = clearTimeout(timeout);\n var delay = time - clockNow; // Strictly less than if we recomputed clockNow.\n if (delay > 24) {\n if (time < Infinity) timeout = setTimeout(wake, time - clock.now() - clockSkew);\n if (interval) interval = clearInterval(interval);\n } else {\n if (!interval) clockLast = clock.now(), interval = setInterval(poke, pokeDelay);\n frame = 1, setFrame(wake);\n }\n}\n", "import {Timer} from \"./timer.js\";\n\nexport default function(callback, delay, time) {\n var t = new Timer;\n delay = delay == null ? 0 : +delay;\n t.restart(elapsed => {\n t.stop();\n callback(elapsed + delay);\n }, delay, time);\n return t;\n}\n", "import {dispatch} from \"d3-dispatch\";\nimport {timer, timeout} from \"d3-timer\";\n\nvar emptyOn = dispatch(\"start\", \"end\", \"cancel\", \"interrupt\");\nvar emptyTween = [];\n\nexport var CREATED = 0;\nexport var SCHEDULED = 1;\nexport var STARTING = 2;\nexport var STARTED = 3;\nexport var RUNNING = 4;\nexport var ENDING = 5;\nexport var ENDED = 6;\n\nexport default function(node, name, id, index, group, timing) {\n var schedules = node.__transition;\n if (!schedules) node.__transition = {};\n else if (id in schedules) return;\n create(node, id, {\n name: name,\n index: index, // For context during callback.\n group: group, // For context during callback.\n on: emptyOn,\n tween: emptyTween,\n time: timing.time,\n delay: timing.delay,\n duration: timing.duration,\n ease: timing.ease,\n timer: null,\n state: CREATED\n });\n}\n\nexport function init(node, id) {\n var schedule = get(node, id);\n if (schedule.state > CREATED) throw new Error(\"too late; already scheduled\");\n return schedule;\n}\n\nexport function set(node, id) {\n var schedule = get(node, id);\n if (schedule.state > STARTED) throw new Error(\"too late; already running\");\n return schedule;\n}\n\nexport function get(node, id) {\n var schedule = node.__transition;\n if (!schedule || !(schedule = schedule[id])) throw new Error(\"transition not found\");\n return schedule;\n}\n\nfunction create(node, id, self) {\n var schedules = node.__transition,\n tween;\n\n // Initialize the self timer when the transition is created.\n // Note the actual delay is not known until the first callback!\n schedules[id] = self;\n self.timer = timer(schedule, 0, self.time);\n\n function schedule(elapsed) {\n self.state = SCHEDULED;\n self.timer.restart(start, self.delay, self.time);\n\n // If the elapsed delay is less than our first sleep, start immediately.\n if (self.delay <= elapsed) start(elapsed - self.delay);\n }\n\n function start(elapsed) {\n var i, j, n, o;\n\n // If the state is not SCHEDULED, then we previously errored on start.\n if (self.state !== SCHEDULED) return stop();\n\n for (i in schedules) {\n o = schedules[i];\n if (o.name !== self.name) continue;\n\n // While this element already has a starting transition during this frame,\n // defer starting an interrupting transition until that transition has a\n // chance to tick (and possibly end); see d3/d3-transition#54!\n if (o.state === STARTED) return timeout(start);\n\n // Interrupt the active transition, if any.\n if (o.state === RUNNING) {\n o.state = ENDED;\n o.timer.stop();\n o.on.call(\"interrupt\", node, node.__data__, o.index, o.group);\n delete schedules[i];\n }\n\n // Cancel any pre-empted transitions.\n else if (+i < id) {\n o.state = ENDED;\n o.timer.stop();\n o.on.call(\"cancel\", node, node.__data__, o.index, o.group);\n delete schedules[i];\n }\n }\n\n // Defer the first tick to end of the current frame; see d3/d3#1576.\n // Note the transition may be canceled after start and before the first tick!\n // Note this must be scheduled before the start event; see d3/d3-transition#16!\n // Assuming this is successful, subsequent callbacks go straight to tick.\n timeout(function() {\n if (self.state === STARTED) {\n self.state = RUNNING;\n self.timer.restart(tick, self.delay, self.time);\n tick(elapsed);\n }\n });\n\n // Dispatch the start event.\n // Note this must be done before the tween are initialized.\n self.state = STARTING;\n self.on.call(\"start\", node, node.__data__, self.index, self.group);\n if (self.state !== STARTING) return; // interrupted\n self.state = STARTED;\n\n // Initialize the tween, deleting null tween.\n tween = new Array(n = self.tween.length);\n for (i = 0, j = -1; i < n; ++i) {\n if (o = self.tween[i].value.call(node, node.__data__, self.index, self.group)) {\n tween[++j] = o;\n }\n }\n tween.length = j + 1;\n }\n\n function tick(elapsed) {\n var t = elapsed < self.duration ? self.ease.call(null, elapsed / self.duration) : (self.timer.restart(stop), self.state = ENDING, 1),\n i = -1,\n n = tween.length;\n\n while (++i < n) {\n tween[i].call(node, t);\n }\n\n // Dispatch the end event.\n if (self.state === ENDING) {\n self.on.call(\"end\", node, node.__data__, self.index, self.group);\n stop();\n }\n }\n\n function stop() {\n self.state = ENDED;\n self.timer.stop();\n delete schedules[id];\n for (var i in schedules) return; // eslint-disable-line no-unused-vars\n delete node.__transition;\n }\n}\n", "import {STARTING, ENDING, ENDED} from \"./transition/schedule.js\";\n\nexport default function(node, name) {\n var schedules = node.__transition,\n schedule,\n active,\n empty = true,\n i;\n\n if (!schedules) return;\n\n name = name == null ? null : name + \"\";\n\n for (i in schedules) {\n if ((schedule = schedules[i]).name !== name) { empty = false; continue; }\n active = schedule.state > STARTING && schedule.state < ENDING;\n schedule.state = ENDED;\n schedule.timer.stop();\n schedule.on.call(active ? \"interrupt\" : \"cancel\", node, node.__data__, schedule.index, schedule.group);\n delete schedules[i];\n }\n\n if (empty) delete node.__transition;\n}\n", "import interrupt from \"../interrupt.js\";\n\nexport default function(name) {\n return this.each(function() {\n interrupt(this, name);\n });\n}\n", "import {get, set} from \"./schedule.js\";\n\nfunction tweenRemove(id, name) {\n var tween0, tween1;\n return function() {\n var schedule = set(this, id),\n tween = schedule.tween;\n\n // If this node shared tween with the previous node,\n // just assign the updated shared tween and we\u2019re done!\n // Otherwise, copy-on-write.\n if (tween !== tween0) {\n tween1 = tween0 = tween;\n for (var i = 0, n = tween1.length; i < n; ++i) {\n if (tween1[i].name === name) {\n tween1 = tween1.slice();\n tween1.splice(i, 1);\n break;\n }\n }\n }\n\n schedule.tween = tween1;\n };\n}\n\nfunction tweenFunction(id, name, value) {\n var tween0, tween1;\n if (typeof value !== \"function\") throw new Error;\n return function() {\n var schedule = set(this, id),\n tween = schedule.tween;\n\n // If this node shared tween with the previous node,\n // just assign the updated shared tween and we\u2019re done!\n // Otherwise, copy-on-write.\n if (tween !== tween0) {\n tween1 = (tween0 = tween).slice();\n for (var t = {name: name, value: value}, i = 0, n = tween1.length; i < n; ++i) {\n if (tween1[i].name === name) {\n tween1[i] = t;\n break;\n }\n }\n if (i === n) tween1.push(t);\n }\n\n schedule.tween = tween1;\n };\n}\n\nexport default function(name, value) {\n var id = this._id;\n\n name += \"\";\n\n if (arguments.length < 2) {\n var tween = get(this.node(), id).tween;\n for (var i = 0, n = tween.length, t; i < n; ++i) {\n if ((t = tween[i]).name === name) {\n return t.value;\n }\n }\n return null;\n }\n\n return this.each((value == null ? tweenRemove : tweenFunction)(id, name, value));\n}\n\nexport function tweenValue(transition, name, value) {\n var id = transition._id;\n\n transition.each(function() {\n var schedule = set(this, id);\n (schedule.value || (schedule.value = {}))[name] = value.apply(this, arguments);\n });\n\n return function(node) {\n return get(node, id).value[name];\n };\n}\n", "import {color} from \"d3-color\";\nimport {interpolateNumber, interpolateRgb, interpolateString} from \"d3-interpolate\";\n\nexport default function(a, b) {\n var c;\n return (typeof b === \"number\" ? interpolateNumber\n : b instanceof color ? interpolateRgb\n : (c = color(b)) ? (b = c, interpolateRgb)\n : interpolateString)(a, b);\n}\n", "import {interpolateTransformSvg as interpolateTransform} from \"d3-interpolate\";\nimport {namespace} from \"d3-selection\";\nimport {tweenValue} from \"./tween.js\";\nimport interpolate from \"./interpolate.js\";\n\nfunction attrRemove(name) {\n return function() {\n this.removeAttribute(name);\n };\n}\n\nfunction attrRemoveNS(fullname) {\n return function() {\n this.removeAttributeNS(fullname.space, fullname.local);\n };\n}\n\nfunction attrConstant(name, interpolate, value1) {\n var string00,\n string1 = value1 + \"\",\n interpolate0;\n return function() {\n var string0 = this.getAttribute(name);\n return string0 === string1 ? null\n : string0 === string00 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, value1);\n };\n}\n\nfunction attrConstantNS(fullname, interpolate, value1) {\n var string00,\n string1 = value1 + \"\",\n interpolate0;\n return function() {\n var string0 = this.getAttributeNS(fullname.space, fullname.local);\n return string0 === string1 ? null\n : string0 === string00 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, value1);\n };\n}\n\nfunction attrFunction(name, interpolate, value) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0, value1 = value(this), string1;\n if (value1 == null) return void this.removeAttribute(name);\n string0 = this.getAttribute(name);\n string1 = value1 + \"\";\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));\n };\n}\n\nfunction attrFunctionNS(fullname, interpolate, value) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0, value1 = value(this), string1;\n if (value1 == null) return void this.removeAttributeNS(fullname.space, fullname.local);\n string0 = this.getAttributeNS(fullname.space, fullname.local);\n string1 = value1 + \"\";\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));\n };\n}\n\nexport default function(name, value) {\n var fullname = namespace(name), i = fullname === \"transform\" ? interpolateTransform : interpolate;\n return this.attrTween(name, typeof value === \"function\"\n ? (fullname.local ? attrFunctionNS : attrFunction)(fullname, i, tweenValue(this, \"attr.\" + name, value))\n : value == null ? (fullname.local ? attrRemoveNS : attrRemove)(fullname)\n : (fullname.local ? attrConstantNS : attrConstant)(fullname, i, value));\n}\n", "import {namespace} from \"d3-selection\";\n\nfunction attrInterpolate(name, i) {\n return function(t) {\n this.setAttribute(name, i.call(this, t));\n };\n}\n\nfunction attrInterpolateNS(fullname, i) {\n return function(t) {\n this.setAttributeNS(fullname.space, fullname.local, i.call(this, t));\n };\n}\n\nfunction attrTweenNS(fullname, value) {\n var t0, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t0 = (i0 = i) && attrInterpolateNS(fullname, i);\n return t0;\n }\n tween._value = value;\n return tween;\n}\n\nfunction attrTween(name, value) {\n var t0, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t0 = (i0 = i) && attrInterpolate(name, i);\n return t0;\n }\n tween._value = value;\n return tween;\n}\n\nexport default function(name, value) {\n var key = \"attr.\" + name;\n if (arguments.length < 2) return (key = this.tween(key)) && key._value;\n if (value == null) return this.tween(key, null);\n if (typeof value !== \"function\") throw new Error;\n var fullname = namespace(name);\n return this.tween(key, (fullname.local ? attrTweenNS : attrTween)(fullname, value));\n}\n", "import {get, init} from \"./schedule.js\";\n\nfunction delayFunction(id, value) {\n return function() {\n init(this, id).delay = +value.apply(this, arguments);\n };\n}\n\nfunction delayConstant(id, value) {\n return value = +value, function() {\n init(this, id).delay = value;\n };\n}\n\nexport default function(value) {\n var id = this._id;\n\n return arguments.length\n ? this.each((typeof value === \"function\"\n ? delayFunction\n : delayConstant)(id, value))\n : get(this.node(), id).delay;\n}\n", "import {get, set} from \"./schedule.js\";\n\nfunction durationFunction(id, value) {\n return function() {\n set(this, id).duration = +value.apply(this, arguments);\n };\n}\n\nfunction durationConstant(id, value) {\n return value = +value, function() {\n set(this, id).duration = value;\n };\n}\n\nexport default function(value) {\n var id = this._id;\n\n return arguments.length\n ? this.each((typeof value === \"function\"\n ? durationFunction\n : durationConstant)(id, value))\n : get(this.node(), id).duration;\n}\n", "import {get, set} from \"./schedule.js\";\n\nfunction easeConstant(id, value) {\n if (typeof value !== \"function\") throw new Error;\n return function() {\n set(this, id).ease = value;\n };\n}\n\nexport default function(value) {\n var id = this._id;\n\n return arguments.length\n ? this.each(easeConstant(id, value))\n : get(this.node(), id).ease;\n}\n", "import {set} from \"./schedule.js\";\n\nfunction easeVarying(id, value) {\n return function() {\n var v = value.apply(this, arguments);\n if (typeof v !== \"function\") throw new Error;\n set(this, id).ease = v;\n };\n}\n\nexport default function(value) {\n if (typeof value !== \"function\") throw new Error;\n return this.each(easeVarying(this._id, value));\n}\n", "import {matcher} from \"d3-selection\";\nimport {Transition} from \"./index.js\";\n\nexport default function(match) {\n if (typeof match !== \"function\") match = matcher(match);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = [], node, i = 0; i < n; ++i) {\n if ((node = group[i]) && match.call(node, node.__data__, i, group)) {\n subgroup.push(node);\n }\n }\n }\n\n return new Transition(subgroups, this._parents, this._name, this._id);\n}\n", "import {Transition} from \"./index.js\";\n\nexport default function(transition) {\n if (transition._id !== this._id) throw new Error;\n\n for (var groups0 = this._groups, groups1 = transition._groups, m0 = groups0.length, m1 = groups1.length, m = Math.min(m0, m1), merges = new Array(m0), j = 0; j < m; ++j) {\n for (var group0 = groups0[j], group1 = groups1[j], n = group0.length, merge = merges[j] = new Array(n), node, i = 0; i < n; ++i) {\n if (node = group0[i] || group1[i]) {\n merge[i] = node;\n }\n }\n }\n\n for (; j < m0; ++j) {\n merges[j] = groups0[j];\n }\n\n return new Transition(merges, this._parents, this._name, this._id);\n}\n", "import {get, set, init} from \"./schedule.js\";\n\nfunction start(name) {\n return (name + \"\").trim().split(/^|\\s+/).every(function(t) {\n var i = t.indexOf(\".\");\n if (i >= 0) t = t.slice(0, i);\n return !t || t === \"start\";\n });\n}\n\nfunction onFunction(id, name, listener) {\n var on0, on1, sit = start(name) ? init : set;\n return function() {\n var schedule = sit(this, id),\n on = schedule.on;\n\n // If this node shared a dispatch with the previous node,\n // just assign the updated shared dispatch and we\u2019re done!\n // Otherwise, copy-on-write.\n if (on !== on0) (on1 = (on0 = on).copy()).on(name, listener);\n\n schedule.on = on1;\n };\n}\n\nexport default function(name, listener) {\n var id = this._id;\n\n return arguments.length < 2\n ? get(this.node(), id).on.on(name)\n : this.each(onFunction(id, name, listener));\n}\n", "function removeFunction(id) {\n return function() {\n var parent = this.parentNode;\n for (var i in this.__transition) if (+i !== id) return;\n if (parent) parent.removeChild(this);\n };\n}\n\nexport default function() {\n return this.on(\"end.remove\", removeFunction(this._id));\n}\n", "import {selector} from \"d3-selection\";\nimport {Transition} from \"./index.js\";\nimport schedule, {get} from \"./schedule.js\";\n\nexport default function(select) {\n var name = this._name,\n id = this._id;\n\n if (typeof select !== \"function\") select = selector(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = new Array(m), j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, subgroup = subgroups[j] = new Array(n), node, subnode, i = 0; i < n; ++i) {\n if ((node = group[i]) && (subnode = select.call(node, node.__data__, i, group))) {\n if (\"__data__\" in node) subnode.__data__ = node.__data__;\n subgroup[i] = subnode;\n schedule(subgroup[i], name, id, i, subgroup, get(node, id));\n }\n }\n }\n\n return new Transition(subgroups, this._parents, name, id);\n}\n", "import {selectorAll} from \"d3-selection\";\nimport {Transition} from \"./index.js\";\nimport schedule, {get} from \"./schedule.js\";\n\nexport default function(select) {\n var name = this._name,\n id = this._id;\n\n if (typeof select !== \"function\") select = selectorAll(select);\n\n for (var groups = this._groups, m = groups.length, subgroups = [], parents = [], j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n for (var children = select.call(node, node.__data__, i, group), child, inherit = get(node, id), k = 0, l = children.length; k < l; ++k) {\n if (child = children[k]) {\n schedule(child, name, id, k, children, inherit);\n }\n }\n subgroups.push(children);\n parents.push(node);\n }\n }\n }\n\n return new Transition(subgroups, parents, name, id);\n}\n", "import {selection} from \"d3-selection\";\n\nvar Selection = selection.prototype.constructor;\n\nexport default function() {\n return new Selection(this._groups, this._parents);\n}\n", "import {interpolateTransformCss as interpolateTransform} from \"d3-interpolate\";\nimport {style} from \"d3-selection\";\nimport {set} from \"./schedule.js\";\nimport {tweenValue} from \"./tween.js\";\nimport interpolate from \"./interpolate.js\";\n\nfunction styleNull(name, interpolate) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0 = style(this, name),\n string1 = (this.style.removeProperty(name), style(this, name));\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, string10 = string1);\n };\n}\n\nfunction styleRemove(name) {\n return function() {\n this.style.removeProperty(name);\n };\n}\n\nfunction styleConstant(name, interpolate, value1) {\n var string00,\n string1 = value1 + \"\",\n interpolate0;\n return function() {\n var string0 = style(this, name);\n return string0 === string1 ? null\n : string0 === string00 ? interpolate0\n : interpolate0 = interpolate(string00 = string0, value1);\n };\n}\n\nfunction styleFunction(name, interpolate, value) {\n var string00,\n string10,\n interpolate0;\n return function() {\n var string0 = style(this, name),\n value1 = value(this),\n string1 = value1 + \"\";\n if (value1 == null) string1 = value1 = (this.style.removeProperty(name), style(this, name));\n return string0 === string1 ? null\n : string0 === string00 && string1 === string10 ? interpolate0\n : (string10 = string1, interpolate0 = interpolate(string00 = string0, value1));\n };\n}\n\nfunction styleMaybeRemove(id, name) {\n var on0, on1, listener0, key = \"style.\" + name, event = \"end.\" + key, remove;\n return function() {\n var schedule = set(this, id),\n on = schedule.on,\n listener = schedule.value[key] == null ? remove || (remove = styleRemove(name)) : undefined;\n\n // If this node shared a dispatch with the previous node,\n // just assign the updated shared dispatch and we\u2019re done!\n // Otherwise, copy-on-write.\n if (on !== on0 || listener0 !== listener) (on1 = (on0 = on).copy()).on(event, listener0 = listener);\n\n schedule.on = on1;\n };\n}\n\nexport default function(name, value, priority) {\n var i = (name += \"\") === \"transform\" ? interpolateTransform : interpolate;\n return value == null ? this\n .styleTween(name, styleNull(name, i))\n .on(\"end.style.\" + name, styleRemove(name))\n : typeof value === \"function\" ? this\n .styleTween(name, styleFunction(name, i, tweenValue(this, \"style.\" + name, value)))\n .each(styleMaybeRemove(this._id, name))\n : this\n .styleTween(name, styleConstant(name, i, value), priority)\n .on(\"end.style.\" + name, null);\n}\n", "function styleInterpolate(name, i, priority) {\n return function(t) {\n this.style.setProperty(name, i.call(this, t), priority);\n };\n}\n\nfunction styleTween(name, value, priority) {\n var t, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t = (i0 = i) && styleInterpolate(name, i, priority);\n return t;\n }\n tween._value = value;\n return tween;\n}\n\nexport default function(name, value, priority) {\n var key = \"style.\" + (name += \"\");\n if (arguments.length < 2) return (key = this.tween(key)) && key._value;\n if (value == null) return this.tween(key, null);\n if (typeof value !== \"function\") throw new Error;\n return this.tween(key, styleTween(name, value, priority == null ? \"\" : priority));\n}\n", "import {tweenValue} from \"./tween.js\";\n\nfunction textConstant(value) {\n return function() {\n this.textContent = value;\n };\n}\n\nfunction textFunction(value) {\n return function() {\n var value1 = value(this);\n this.textContent = value1 == null ? \"\" : value1;\n };\n}\n\nexport default function(value) {\n return this.tween(\"text\", typeof value === \"function\"\n ? textFunction(tweenValue(this, \"text\", value))\n : textConstant(value == null ? \"\" : value + \"\"));\n}\n", "function textInterpolate(i) {\n return function(t) {\n this.textContent = i.call(this, t);\n };\n}\n\nfunction textTween(value) {\n var t0, i0;\n function tween() {\n var i = value.apply(this, arguments);\n if (i !== i0) t0 = (i0 = i) && textInterpolate(i);\n return t0;\n }\n tween._value = value;\n return tween;\n}\n\nexport default function(value) {\n var key = \"text\";\n if (arguments.length < 1) return (key = this.tween(key)) && key._value;\n if (value == null) return this.tween(key, null);\n if (typeof value !== \"function\") throw new Error;\n return this.tween(key, textTween(value));\n}\n", "import {Transition, newId} from \"./index.js\";\nimport schedule, {get} from \"./schedule.js\";\n\nexport default function() {\n var name = this._name,\n id0 = this._id,\n id1 = newId();\n\n for (var groups = this._groups, m = groups.length, j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n var inherit = get(node, id0);\n schedule(node, name, id1, i, group, {\n time: inherit.time + inherit.delay + inherit.duration,\n delay: 0,\n duration: inherit.duration,\n ease: inherit.ease\n });\n }\n }\n }\n\n return new Transition(groups, this._parents, name, id1);\n}\n", "import {set} from \"./schedule.js\";\n\nexport default function() {\n var on0, on1, that = this, id = that._id, size = that.size();\n return new Promise(function(resolve, reject) {\n var cancel = {value: reject},\n end = {value: function() { if (--size === 0) resolve(); }};\n\n that.each(function() {\n var schedule = set(this, id),\n on = schedule.on;\n\n // If this node shared a dispatch with the previous node,\n // just assign the updated shared dispatch and we\u2019re done!\n // Otherwise, copy-on-write.\n if (on !== on0) {\n on1 = (on0 = on).copy();\n on1._.cancel.push(cancel);\n on1._.interrupt.push(cancel);\n on1._.end.push(end);\n }\n\n schedule.on = on1;\n });\n\n // The selection was empty, resolve end immediately\n if (size === 0) resolve();\n });\n}\n", "import {selection} from \"d3-selection\";\nimport transition_attr from \"./attr.js\";\nimport transition_attrTween from \"./attrTween.js\";\nimport transition_delay from \"./delay.js\";\nimport transition_duration from \"./duration.js\";\nimport transition_ease from \"./ease.js\";\nimport transition_easeVarying from \"./easeVarying.js\";\nimport transition_filter from \"./filter.js\";\nimport transition_merge from \"./merge.js\";\nimport transition_on from \"./on.js\";\nimport transition_remove from \"./remove.js\";\nimport transition_select from \"./select.js\";\nimport transition_selectAll from \"./selectAll.js\";\nimport transition_selection from \"./selection.js\";\nimport transition_style from \"./style.js\";\nimport transition_styleTween from \"./styleTween.js\";\nimport transition_text from \"./text.js\";\nimport transition_textTween from \"./textTween.js\";\nimport transition_transition from \"./transition.js\";\nimport transition_tween from \"./tween.js\";\nimport transition_end from \"./end.js\";\n\nvar id = 0;\n\nexport function Transition(groups, parents, name, id) {\n this._groups = groups;\n this._parents = parents;\n this._name = name;\n this._id = id;\n}\n\nexport default function transition(name) {\n return selection().transition(name);\n}\n\nexport function newId() {\n return ++id;\n}\n\nvar selection_prototype = selection.prototype;\n\nTransition.prototype = transition.prototype = {\n constructor: Transition,\n select: transition_select,\n selectAll: transition_selectAll,\n selectChild: selection_prototype.selectChild,\n selectChildren: selection_prototype.selectChildren,\n filter: transition_filter,\n merge: transition_merge,\n selection: transition_selection,\n transition: transition_transition,\n call: selection_prototype.call,\n nodes: selection_prototype.nodes,\n node: selection_prototype.node,\n size: selection_prototype.size,\n empty: selection_prototype.empty,\n each: selection_prototype.each,\n on: transition_on,\n attr: transition_attr,\n attrTween: transition_attrTween,\n style: transition_style,\n styleTween: transition_styleTween,\n text: transition_text,\n textTween: transition_textTween,\n remove: transition_remove,\n tween: transition_tween,\n delay: transition_delay,\n duration: transition_duration,\n ease: transition_ease,\n easeVarying: transition_easeVarying,\n end: transition_end,\n [Symbol.iterator]: selection_prototype[Symbol.iterator]\n};\n", "export function cubicIn(t) {\n return t * t * t;\n}\n\nexport function cubicOut(t) {\n return --t * t * t + 1;\n}\n\nexport function cubicInOut(t) {\n return ((t *= 2) <= 1 ? t * t * t : (t -= 2) * t * t + 2) / 2;\n}\n", "import {Transition, newId} from \"../transition/index.js\";\nimport schedule from \"../transition/schedule.js\";\nimport {easeCubicInOut} from \"d3-ease\";\nimport {now} from \"d3-timer\";\n\nvar defaultTiming = {\n time: null, // Set on use.\n delay: 0,\n duration: 250,\n ease: easeCubicInOut\n};\n\nfunction inherit(node, id) {\n var timing;\n while (!(timing = node.__transition) || !(timing = timing[id])) {\n if (!(node = node.parentNode)) {\n throw new Error(`transition ${id} not found`);\n }\n }\n return timing;\n}\n\nexport default function(name) {\n var id,\n timing;\n\n if (name instanceof Transition) {\n id = name._id, name = name._name;\n } else {\n id = newId(), (timing = defaultTiming).time = now(), name = name == null ? null : name + \"\";\n }\n\n for (var groups = this._groups, m = groups.length, j = 0; j < m; ++j) {\n for (var group = groups[j], n = group.length, node, i = 0; i < n; ++i) {\n if (node = group[i]) {\n schedule(node, name, id, i, group, timing || inherit(node, id));\n }\n }\n }\n\n return new Transition(groups, this._parents, name, id);\n}\n", "import {selection} from \"d3-selection\";\nimport selection_interrupt from \"./interrupt.js\";\nimport selection_transition from \"./transition.js\";\n\nselection.prototype.interrupt = selection_interrupt;\nselection.prototype.transition = selection_transition;\n", "import {dispatch} from \"d3-dispatch\";\nimport {dragDisable, dragEnable} from \"d3-drag\";\nimport {interpolate} from \"d3-interpolate\";\nimport {pointer, select} from \"d3-selection\";\nimport {interrupt} from \"d3-transition\";\nimport constant from \"./constant.js\";\nimport BrushEvent from \"./event.js\";\nimport noevent, {nopropagation} from \"./noevent.js\";\n\nvar MODE_DRAG = {name: \"drag\"},\n MODE_SPACE = {name: \"space\"},\n MODE_HANDLE = {name: \"handle\"},\n MODE_CENTER = {name: \"center\"};\n\nconst {abs, max, min} = Math;\n\nfunction number1(e) {\n return [+e[0], +e[1]];\n}\n\nfunction number2(e) {\n return [number1(e[0]), number1(e[1])];\n}\n\nvar X = {\n name: \"x\",\n handles: [\"w\", \"e\"].map(type),\n input: function(x, e) { return x == null ? null : [[+x[0], e[0][1]], [+x[1], e[1][1]]]; },\n output: function(xy) { return xy && [xy[0][0], xy[1][0]]; }\n};\n\nvar Y = {\n name: \"y\",\n handles: [\"n\", \"s\"].map(type),\n input: function(y, e) { return y == null ? null : [[e[0][0], +y[0]], [e[1][0], +y[1]]]; },\n output: function(xy) { return xy && [xy[0][1], xy[1][1]]; }\n};\n\nvar XY = {\n name: \"xy\",\n handles: [\"n\", \"w\", \"e\", \"s\", \"nw\", \"ne\", \"sw\", \"se\"].map(type),\n input: function(xy) { return xy == null ? null : number2(xy); },\n output: function(xy) { return xy; }\n};\n\nvar cursors = {\n overlay: \"crosshair\",\n selection: \"move\",\n n: \"ns-resize\",\n e: \"ew-resize\",\n s: \"ns-resize\",\n w: \"ew-resize\",\n nw: \"nwse-resize\",\n ne: \"nesw-resize\",\n se: \"nwse-resize\",\n sw: \"nesw-resize\"\n};\n\nvar flipX = {\n e: \"w\",\n w: \"e\",\n nw: \"ne\",\n ne: \"nw\",\n se: \"sw\",\n sw: \"se\"\n};\n\nvar flipY = {\n n: \"s\",\n s: \"n\",\n nw: \"sw\",\n ne: \"se\",\n se: \"ne\",\n sw: \"nw\"\n};\n\nvar signsX = {\n overlay: +1,\n selection: +1,\n n: null,\n e: +1,\n s: null,\n w: -1,\n nw: -1,\n ne: +1,\n se: +1,\n sw: -1\n};\n\nvar signsY = {\n overlay: +1,\n selection: +1,\n n: -1,\n e: null,\n s: +1,\n w: null,\n nw: -1,\n ne: -1,\n se: +1,\n sw: +1\n};\n\nfunction type(t) {\n return {type: t};\n}\n\n// Ignore right-click, since that should open the context menu.\nfunction defaultFilter(event) {\n return !event.ctrlKey && !event.button;\n}\n\nfunction defaultExtent() {\n var svg = this.ownerSVGElement || this;\n if (svg.hasAttribute(\"viewBox\")) {\n svg = svg.viewBox.baseVal;\n return [[svg.x, svg.y], [svg.x + svg.width, svg.y + svg.height]];\n }\n return [[0, 0], [svg.width.baseVal.value, svg.height.baseVal.value]];\n}\n\nfunction defaultTouchable() {\n return navigator.maxTouchPoints || (\"ontouchstart\" in this);\n}\n\n// Like d3.local, but with the name \u201C__brush\u201D rather than auto-generated.\nfunction local(node) {\n while (!node.__brush) if (!(node = node.parentNode)) return;\n return node.__brush;\n}\n\nfunction empty(extent) {\n return extent[0][0] === extent[1][0]\n || extent[0][1] === extent[1][1];\n}\n\nexport function brushSelection(node) {\n var state = node.__brush;\n return state ? state.dim.output(state.selection) : null;\n}\n\nexport function brushX() {\n return brush(X);\n}\n\nexport function brushY() {\n return brush(Y);\n}\n\nexport default function() {\n return brush(XY);\n}\n\nfunction brush(dim) {\n var extent = defaultExtent,\n filter = defaultFilter,\n touchable = defaultTouchable,\n keys = true,\n listeners = dispatch(\"start\", \"brush\", \"end\"),\n handleSize = 6,\n touchending;\n\n function brush(group) {\n var overlay = group\n .property(\"__brush\", initialize)\n .selectAll(\".overlay\")\n .data([type(\"overlay\")]);\n\n overlay.enter().append(\"rect\")\n .attr(\"class\", \"overlay\")\n .attr(\"pointer-events\", \"all\")\n .attr(\"cursor\", cursors.overlay)\n .merge(overlay)\n .each(function() {\n var extent = local(this).extent;\n select(this)\n .attr(\"x\", extent[0][0])\n .attr(\"y\", extent[0][1])\n .attr(\"width\", extent[1][0] - extent[0][0])\n .attr(\"height\", extent[1][1] - extent[0][1]);\n });\n\n group.selectAll(\".selection\")\n .data([type(\"selection\")])\n .enter().append(\"rect\")\n .attr(\"class\", \"selection\")\n .attr(\"cursor\", cursors.selection)\n .attr(\"fill\", \"#777\")\n .attr(\"fill-opacity\", 0.3)\n .attr(\"stroke\", \"#fff\")\n .attr(\"shape-rendering\", \"crispEdges\");\n\n var handle = group.selectAll(\".handle\")\n .data(dim.handles, function(d) { return d.type; });\n\n handle.exit().remove();\n\n handle.enter().append(\"rect\")\n .attr(\"class\", function(d) { return \"handle handle--\" + d.type; })\n .attr(\"cursor\", function(d) { return cursors[d.type]; });\n\n group\n .each(redraw)\n .attr(\"fill\", \"none\")\n .attr(\"pointer-events\", \"all\")\n .on(\"mousedown.brush\", started)\n .filter(touchable)\n .on(\"touchstart.brush\", started)\n .on(\"touchmove.brush\", touchmoved)\n .on(\"touchend.brush touchcancel.brush\", touchended)\n .style(\"touch-action\", \"none\")\n .style(\"-webkit-tap-highlight-color\", \"rgba(0,0,0,0)\");\n }\n\n brush.move = function(group, selection, event) {\n if (group.tween) {\n group\n .on(\"start.brush\", function(event) { emitter(this, arguments).beforestart().start(event); })\n .on(\"interrupt.brush end.brush\", function(event) { emitter(this, arguments).end(event); })\n .tween(\"brush\", function() {\n var that = this,\n state = that.__brush,\n emit = emitter(that, arguments),\n selection0 = state.selection,\n selection1 = dim.input(typeof selection === \"function\" ? selection.apply(this, arguments) : selection, state.extent),\n i = interpolate(selection0, selection1);\n\n function tween(t) {\n state.selection = t === 1 && selection1 === null ? null : i(t);\n redraw.call(that);\n emit.brush();\n }\n\n return selection0 !== null && selection1 !== null ? tween : tween(1);\n });\n } else {\n group\n .each(function() {\n var that = this,\n args = arguments,\n state = that.__brush,\n selection1 = dim.input(typeof selection === \"function\" ? selection.apply(that, args) : selection, state.extent),\n emit = emitter(that, args).beforestart();\n\n interrupt(that);\n state.selection = selection1 === null ? null : selection1;\n redraw.call(that);\n emit.start(event).brush(event).end(event);\n });\n }\n };\n\n brush.clear = function(group, event) {\n brush.move(group, null, event);\n };\n\n function redraw() {\n var group = select(this),\n selection = local(this).selection;\n\n if (selection) {\n group.selectAll(\".selection\")\n .style(\"display\", null)\n .attr(\"x\", selection[0][0])\n .attr(\"y\", selection[0][1])\n .attr(\"width\", selection[1][0] - selection[0][0])\n .attr(\"height\", selection[1][1] - selection[0][1]);\n\n group.selectAll(\".handle\")\n .style(\"display\", null)\n .attr(\"x\", function(d) { return d.type[d.type.length - 1] === \"e\" ? selection[1][0] - handleSize / 2 : selection[0][0] - handleSize / 2; })\n .attr(\"y\", function(d) { return d.type[0] === \"s\" ? selection[1][1] - handleSize / 2 : selection[0][1] - handleSize / 2; })\n .attr(\"width\", function(d) { return d.type === \"n\" || d.type === \"s\" ? selection[1][0] - selection[0][0] + handleSize : handleSize; })\n .attr(\"height\", function(d) { return d.type === \"e\" || d.type === \"w\" ? selection[1][1] - selection[0][1] + handleSize : handleSize; });\n }\n\n else {\n group.selectAll(\".selection,.handle\")\n .style(\"display\", \"none\")\n .attr(\"x\", null)\n .attr(\"y\", null)\n .attr(\"width\", null)\n .attr(\"height\", null);\n }\n }\n\n function emitter(that, args, clean) {\n var emit = that.__brush.emitter;\n return emit && (!clean || !emit.clean) ? emit : new Emitter(that, args, clean);\n }\n\n function Emitter(that, args, clean) {\n this.that = that;\n this.args = args;\n this.state = that.__brush;\n this.active = 0;\n this.clean = clean;\n }\n\n Emitter.prototype = {\n beforestart: function() {\n if (++this.active === 1) this.state.emitter = this, this.starting = true;\n return this;\n },\n start: function(event, mode) {\n if (this.starting) this.starting = false, this.emit(\"start\", event, mode);\n else this.emit(\"brush\", event);\n return this;\n },\n brush: function(event, mode) {\n this.emit(\"brush\", event, mode);\n return this;\n },\n end: function(event, mode) {\n if (--this.active === 0) delete this.state.emitter, this.emit(\"end\", event, mode);\n return this;\n },\n emit: function(type, event, mode) {\n var d = select(this.that).datum();\n listeners.call(\n type,\n this.that,\n new BrushEvent(type, {\n sourceEvent: event,\n target: brush,\n selection: dim.output(this.state.selection),\n mode,\n dispatch: listeners\n }),\n d\n );\n }\n };\n\n function started(event) {\n if (touchending && !event.touches) return;\n if (!filter.apply(this, arguments)) return;\n\n var that = this,\n type = event.target.__data__.type,\n mode = (keys && event.metaKey ? type = \"overlay\" : type) === \"selection\" ? MODE_DRAG : (keys && event.altKey ? MODE_CENTER : MODE_HANDLE),\n signX = dim === Y ? null : signsX[type],\n signY = dim === X ? null : signsY[type],\n state = local(that),\n extent = state.extent,\n selection = state.selection,\n W = extent[0][0], w0, w1,\n N = extent[0][1], n0, n1,\n E = extent[1][0], e0, e1,\n S = extent[1][1], s0, s1,\n dx = 0,\n dy = 0,\n moving,\n shifting = signX && signY && keys && event.shiftKey,\n lockX,\n lockY,\n points = Array.from(event.touches || [event], t => {\n const i = t.identifier;\n t = pointer(t, that);\n t.point0 = t.slice();\n t.identifier = i;\n return t;\n });\n\n interrupt(that);\n var emit = emitter(that, arguments, true).beforestart();\n\n if (type === \"overlay\") {\n if (selection) moving = true;\n const pts = [points[0], points[1] || points[0]];\n state.selection = selection = [[\n w0 = dim === Y ? W : min(pts[0][0], pts[1][0]),\n n0 = dim === X ? N : min(pts[0][1], pts[1][1])\n ], [\n e0 = dim === Y ? E : max(pts[0][0], pts[1][0]),\n s0 = dim === X ? S : max(pts[0][1], pts[1][1])\n ]];\n if (points.length > 1) move(event);\n } else {\n w0 = selection[0][0];\n n0 = selection[0][1];\n e0 = selection[1][0];\n s0 = selection[1][1];\n }\n\n w1 = w0;\n n1 = n0;\n e1 = e0;\n s1 = s0;\n\n var group = select(that)\n .attr(\"pointer-events\", \"none\");\n\n var overlay = group.selectAll(\".overlay\")\n .attr(\"cursor\", cursors[type]);\n\n if (event.touches) {\n emit.moved = moved;\n emit.ended = ended;\n } else {\n var view = select(event.view)\n .on(\"mousemove.brush\", moved, true)\n .on(\"mouseup.brush\", ended, true);\n if (keys) view\n .on(\"keydown.brush\", keydowned, true)\n .on(\"keyup.brush\", keyupped, true)\n\n dragDisable(event.view);\n }\n\n redraw.call(that);\n emit.start(event, mode.name);\n\n function moved(event) {\n for (const p of event.changedTouches || [event]) {\n for (const d of points)\n if (d.identifier === p.identifier) d.cur = pointer(p, that);\n }\n if (shifting && !lockX && !lockY && points.length === 1) {\n const point = points[0];\n if (abs(point.cur[0] - point[0]) > abs(point.cur[1] - point[1]))\n lockY = true;\n else\n lockX = true;\n }\n for (const point of points)\n if (point.cur) point[0] = point.cur[0], point[1] = point.cur[1];\n moving = true;\n noevent(event);\n move(event);\n }\n\n function move(event) {\n const point = points[0], point0 = point.point0;\n var t;\n\n dx = point[0] - point0[0];\n dy = point[1] - point0[1];\n\n switch (mode) {\n case MODE_SPACE:\n case MODE_DRAG: {\n if (signX) dx = max(W - w0, min(E - e0, dx)), w1 = w0 + dx, e1 = e0 + dx;\n if (signY) dy = max(N - n0, min(S - s0, dy)), n1 = n0 + dy, s1 = s0 + dy;\n break;\n }\n case MODE_HANDLE: {\n if (points[1]) {\n if (signX) w1 = max(W, min(E, points[0][0])), e1 = max(W, min(E, points[1][0])), signX = 1;\n if (signY) n1 = max(N, min(S, points[0][1])), s1 = max(N, min(S, points[1][1])), signY = 1;\n } else {\n if (signX < 0) dx = max(W - w0, min(E - w0, dx)), w1 = w0 + dx, e1 = e0;\n else if (signX > 0) dx = max(W - e0, min(E - e0, dx)), w1 = w0, e1 = e0 + dx;\n if (signY < 0) dy = max(N - n0, min(S - n0, dy)), n1 = n0 + dy, s1 = s0;\n else if (signY > 0) dy = max(N - s0, min(S - s0, dy)), n1 = n0, s1 = s0 + dy;\n }\n break;\n }\n case MODE_CENTER: {\n if (signX) w1 = max(W, min(E, w0 - dx * signX)), e1 = max(W, min(E, e0 + dx * signX));\n if (signY) n1 = max(N, min(S, n0 - dy * signY)), s1 = max(N, min(S, s0 + dy * signY));\n break;\n }\n }\n\n if (e1 < w1) {\n signX *= -1;\n t = w0, w0 = e0, e0 = t;\n t = w1, w1 = e1, e1 = t;\n if (type in flipX) overlay.attr(\"cursor\", cursors[type = flipX[type]]);\n }\n\n if (s1 < n1) {\n signY *= -1;\n t = n0, n0 = s0, s0 = t;\n t = n1, n1 = s1, s1 = t;\n if (type in flipY) overlay.attr(\"cursor\", cursors[type = flipY[type]]);\n }\n\n if (state.selection) selection = state.selection; // May be set by brush.move!\n if (lockX) w1 = selection[0][0], e1 = selection[1][0];\n if (lockY) n1 = selection[0][1], s1 = selection[1][1];\n\n if (selection[0][0] !== w1\n || selection[0][1] !== n1\n || selection[1][0] !== e1\n || selection[1][1] !== s1) {\n state.selection = [[w1, n1], [e1, s1]];\n redraw.call(that);\n emit.brush(event, mode.name);\n }\n }\n\n function ended(event) {\n nopropagation(event);\n if (event.touches) {\n if (event.touches.length) return;\n if (touchending) clearTimeout(touchending);\n touchending = setTimeout(function() { touchending = null; }, 500); // Ghost clicks are delayed!\n } else {\n dragEnable(event.view, moving);\n view.on(\"keydown.brush keyup.brush mousemove.brush mouseup.brush\", null);\n }\n group.attr(\"pointer-events\", \"all\");\n overlay.attr(\"cursor\", cursors.overlay);\n if (state.selection) selection = state.selection; // May be set by brush.move (on start)!\n if (empty(selection)) state.selection = null, redraw.call(that);\n emit.end(event, mode.name);\n }\n\n function keydowned(event) {\n switch (event.keyCode) {\n case 16: { // SHIFT\n shifting = signX && signY;\n break;\n }\n case 18: { // ALT\n if (mode === MODE_HANDLE) {\n if (signX) e0 = e1 - dx * signX, w0 = w1 + dx * signX;\n if (signY) s0 = s1 - dy * signY, n0 = n1 + dy * signY;\n mode = MODE_CENTER;\n move(event);\n }\n break;\n }\n case 32: { // SPACE; takes priority over ALT\n if (mode === MODE_HANDLE || mode === MODE_CENTER) {\n if (signX < 0) e0 = e1 - dx; else if (signX > 0) w0 = w1 - dx;\n if (signY < 0) s0 = s1 - dy; else if (signY > 0) n0 = n1 - dy;\n mode = MODE_SPACE;\n overlay.attr(\"cursor\", cursors.selection);\n move(event);\n }\n break;\n }\n default: return;\n }\n noevent(event);\n }\n\n function keyupped(event) {\n switch (event.keyCode) {\n case 16: { // SHIFT\n if (shifting) {\n lockX = lockY = shifting = false;\n move(event);\n }\n break;\n }\n case 18: { // ALT\n if (mode === MODE_CENTER) {\n if (signX < 0) e0 = e1; else if (signX > 0) w0 = w1;\n if (signY < 0) s0 = s1; else if (signY > 0) n0 = n1;\n mode = MODE_HANDLE;\n move(event);\n }\n break;\n }\n case 32: { // SPACE\n if (mode === MODE_SPACE) {\n if (event.altKey) {\n if (signX) e0 = e1 - dx * signX, w0 = w1 + dx * signX;\n if (signY) s0 = s1 - dy * signY, n0 = n1 + dy * signY;\n mode = MODE_CENTER;\n } else {\n if (signX < 0) e0 = e1; else if (signX > 0) w0 = w1;\n if (signY < 0) s0 = s1; else if (signY > 0) n0 = n1;\n mode = MODE_HANDLE;\n }\n overlay.attr(\"cursor\", cursors[type]);\n move(event);\n }\n break;\n }\n default: return;\n }\n noevent(event);\n }\n }\n\n function touchmoved(event) {\n emitter(this, arguments).moved(event);\n }\n\n function touchended(event) {\n emitter(this, arguments).ended(event);\n }\n\n function initialize() {\n var state = this.__brush || {selection: null};\n state.extent = number2(extent.apply(this, arguments));\n state.dim = dim;\n return state;\n }\n\n brush.extent = function(_) {\n return arguments.length ? (extent = typeof _ === \"function\" ? _ : constant(number2(_)), brush) : extent;\n };\n\n brush.filter = function(_) {\n return arguments.length ? (filter = typeof _ === \"function\" ? _ : constant(!!_), brush) : filter;\n };\n\n brush.touchable = function(_) {\n return arguments.length ? (touchable = typeof _ === \"function\" ? _ : constant(!!_), brush) : touchable;\n };\n\n brush.handleSize = function(_) {\n return arguments.length ? (handleSize = +_, brush) : handleSize;\n };\n\n brush.keyModifiers = function(_) {\n return arguments.length ? (keys = !!_, brush) : keys;\n };\n\n brush.on = function() {\n var value = listeners.on.apply(listeners, arguments);\n return value === listeners ? brush : value;\n };\n\n return brush;\n}\n", "function responseText(response) {\n if (!response.ok) throw new Error(response.status + \" \" + response.statusText);\n return response.text();\n}\n\nexport default function(input, init) {\n return fetch(input, init).then(responseText);\n}\n", "import text from \"./text.js\";\n\nfunction parser(type) {\n return (input, init) => text(input, init)\n .then(text => (new DOMParser).parseFromString(text, type));\n}\n\nexport default parser(\"application/xml\");\n\nexport var html = parser(\"text/html\");\n\nexport var svg = parser(\"image/svg+xml\");\n", "export function Transform(k, x, y) {\n this.k = k;\n this.x = x;\n this.y = y;\n}\n\nTransform.prototype = {\n constructor: Transform,\n scale: function(k) {\n return k === 1 ? this : new Transform(this.k * k, this.x, this.y);\n },\n translate: function(x, y) {\n return x === 0 & y === 0 ? this : new Transform(this.k, this.x + this.k * x, this.y + this.k * y);\n },\n apply: function(point) {\n return [point[0] * this.k + this.x, point[1] * this.k + this.y];\n },\n applyX: function(x) {\n return x * this.k + this.x;\n },\n applyY: function(y) {\n return y * this.k + this.y;\n },\n invert: function(location) {\n return [(location[0] - this.x) / this.k, (location[1] - this.y) / this.k];\n },\n invertX: function(x) {\n return (x - this.x) / this.k;\n },\n invertY: function(y) {\n return (y - this.y) / this.k;\n },\n rescaleX: function(x) {\n return x.copy().domain(x.range().map(this.invertX, this).map(x.invert, x));\n },\n rescaleY: function(y) {\n return y.copy().domain(y.range().map(this.invertY, this).map(y.invert, y));\n },\n toString: function() {\n return \"translate(\" + this.x + \",\" + this.y + \") scale(\" + this.k + \")\";\n }\n};\n\nexport var identity = new Transform(1, 0, 0);\n\ntransform.prototype = Transform.prototype;\n\nexport default function transform(node) {\n while (!node.__zoom) if (!(node = node.parentNode)) return identity;\n return node.__zoom;\n}\n", "/* IMPORT */\n/* MAIN */\nconst Channel = {\n /* CLAMP */\n min: {\n r: 0,\n g: 0,\n b: 0,\n s: 0,\n l: 0,\n a: 0\n },\n max: {\n r: 255,\n g: 255,\n b: 255,\n h: 360,\n s: 100,\n l: 100,\n a: 1\n },\n clamp: {\n r: (r) => r >= 255 ? 255 : (r < 0 ? 0 : r),\n g: (g) => g >= 255 ? 255 : (g < 0 ? 0 : g),\n b: (b) => b >= 255 ? 255 : (b < 0 ? 0 : b),\n h: (h) => h % 360,\n s: (s) => s >= 100 ? 100 : (s < 0 ? 0 : s),\n l: (l) => l >= 100 ? 100 : (l < 0 ? 0 : l),\n a: (a) => a >= 1 ? 1 : (a < 0 ? 0 : a)\n },\n /* CONVERSION */\n //SOURCE: https://planetcalc.com/7779\n toLinear: (c) => {\n const n = c / 255;\n return c > .03928 ? Math.pow(((n + .055) / 1.055), 2.4) : n / 12.92;\n },\n //SOURCE: https://gist.github.com/mjackson/5311256\n hue2rgb: (p, q, t) => {\n if (t < 0)\n t += 1;\n if (t > 1)\n t -= 1;\n if (t < 1 / 6)\n return p + (q - p) * 6 * t;\n if (t < 1 / 2)\n return q;\n if (t < 2 / 3)\n return p + (q - p) * (2 / 3 - t) * 6;\n return p;\n },\n hsl2rgb: ({ h, s, l }, channel) => {\n if (!s)\n return l * 2.55; // Achromatic\n h /= 360;\n s /= 100;\n l /= 100;\n const q = (l < .5) ? l * (1 + s) : (l + s) - (l * s);\n const p = 2 * l - q;\n switch (channel) {\n case 'r': return Channel.hue2rgb(p, q, h + 1 / 3) * 255;\n case 'g': return Channel.hue2rgb(p, q, h) * 255;\n case 'b': return Channel.hue2rgb(p, q, h - 1 / 3) * 255;\n }\n },\n rgb2hsl: ({ r, g, b }, channel) => {\n r /= 255;\n g /= 255;\n b /= 255;\n const max = Math.max(r, g, b);\n const min = Math.min(r, g, b);\n const l = (max + min) / 2;\n if (channel === 'l')\n return l * 100;\n if (max === min)\n return 0; // Achromatic\n const d = max - min;\n const s = (l > .5) ? d / (2 - max - min) : d / (max + min);\n if (channel === 's')\n return s * 100;\n switch (max) {\n case r: return ((g - b) / d + (g < b ? 6 : 0)) * 60;\n case g: return ((b - r) / d + 2) * 60;\n case b: return ((r - g) / d + 4) * 60;\n default: return -1; //TSC: TypeScript is stupid and complains if there isn't this useless default statement\n }\n }\n};\n/* EXPORT */\nexport default Channel;\n", "/* MAIN */\nconst Lang = {\n /* API */\n clamp: (number, lower, upper) => {\n if (lower > upper)\n return Math.min(lower, Math.max(upper, number));\n return Math.min(upper, Math.max(lower, number));\n },\n round: (number) => {\n return Math.round(number * 10000000000) / 10000000000;\n }\n};\n/* EXPORT */\nexport default Lang;\n", "/* MAIN */\nconst Unit = {\n /* API */\n dec2hex: (dec) => {\n const hex = Math.round(dec).toString(16);\n return hex.length > 1 ? hex : `0${hex}`;\n }\n};\n/* EXPORT */\nexport default Unit;\n", "/* IMPORT */\nimport channel from './channel.js';\nimport lang from './lang.js';\nimport unit from './unit.js';\n/* MAIN */\nconst Utils = {\n channel,\n lang,\n unit\n};\n/* EXPORT */\nexport default Utils;\n", "/* IMPORT */\nimport _ from './utils/index.js';\n/* MAIN */\nconst DEC2HEX = {};\nfor (let i = 0; i <= 255; i++)\n DEC2HEX[i] = _.unit.dec2hex(i); // Populating dynamically, striking a balance between code size and performance\nconst TYPE = {\n ALL: 0,\n RGB: 1,\n HSL: 2\n};\n/* EXPORT */\nexport { DEC2HEX, TYPE };\n", "/* IMPORT */\nimport { TYPE } from '../constants.js';\n/* MAIN */\nclass Type {\n constructor() {\n /* VARIABLES */\n this.type = TYPE.ALL;\n }\n /* API */\n get() {\n return this.type;\n }\n set(type) {\n if (this.type && this.type !== type)\n throw new Error('Cannot change both RGB and HSL channels at the same time');\n this.type = type;\n }\n reset() {\n this.type = TYPE.ALL;\n }\n is(type) {\n return this.type === type;\n }\n}\n/* EXPORT */\nexport default Type;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Type from './type.js';\nimport { TYPE } from '../constants.js';\n/* MAIN */\nclass Channels {\n /* CONSTRUCTOR */\n constructor(data, color) {\n this.color = color;\n this.changed = false;\n this.data = data; //TSC\n this.type = new Type();\n }\n /* API */\n set(data, color) {\n this.color = color;\n this.changed = false;\n this.data = data; //TSC\n this.type.type = TYPE.ALL;\n return this;\n }\n /* HELPERS */\n _ensureHSL() {\n const data = this.data;\n const { h, s, l } = data;\n if (h === undefined)\n data.h = _.channel.rgb2hsl(data, 'h');\n if (s === undefined)\n data.s = _.channel.rgb2hsl(data, 's');\n if (l === undefined)\n data.l = _.channel.rgb2hsl(data, 'l');\n }\n _ensureRGB() {\n const data = this.data;\n const { r, g, b } = data;\n if (r === undefined)\n data.r = _.channel.hsl2rgb(data, 'r');\n if (g === undefined)\n data.g = _.channel.hsl2rgb(data, 'g');\n if (b === undefined)\n data.b = _.channel.hsl2rgb(data, 'b');\n }\n /* GETTERS */\n get r() {\n const data = this.data;\n const r = data.r;\n if (!this.type.is(TYPE.HSL) && r !== undefined)\n return r;\n this._ensureHSL();\n return _.channel.hsl2rgb(data, 'r');\n }\n get g() {\n const data = this.data;\n const g = data.g;\n if (!this.type.is(TYPE.HSL) && g !== undefined)\n return g;\n this._ensureHSL();\n return _.channel.hsl2rgb(data, 'g');\n }\n get b() {\n const data = this.data;\n const b = data.b;\n if (!this.type.is(TYPE.HSL) && b !== undefined)\n return b;\n this._ensureHSL();\n return _.channel.hsl2rgb(data, 'b');\n }\n get h() {\n const data = this.data;\n const h = data.h;\n if (!this.type.is(TYPE.RGB) && h !== undefined)\n return h;\n this._ensureRGB();\n return _.channel.rgb2hsl(data, 'h');\n }\n get s() {\n const data = this.data;\n const s = data.s;\n if (!this.type.is(TYPE.RGB) && s !== undefined)\n return s;\n this._ensureRGB();\n return _.channel.rgb2hsl(data, 's');\n }\n get l() {\n const data = this.data;\n const l = data.l;\n if (!this.type.is(TYPE.RGB) && l !== undefined)\n return l;\n this._ensureRGB();\n return _.channel.rgb2hsl(data, 'l');\n }\n get a() {\n return this.data.a;\n }\n /* SETTERS */\n set r(r) {\n this.type.set(TYPE.RGB);\n this.changed = true;\n this.data.r = r;\n }\n set g(g) {\n this.type.set(TYPE.RGB);\n this.changed = true;\n this.data.g = g;\n }\n set b(b) {\n this.type.set(TYPE.RGB);\n this.changed = true;\n this.data.b = b;\n }\n set h(h) {\n this.type.set(TYPE.HSL);\n this.changed = true;\n this.data.h = h;\n }\n set s(s) {\n this.type.set(TYPE.HSL);\n this.changed = true;\n this.data.s = s;\n }\n set l(l) {\n this.type.set(TYPE.HSL);\n this.changed = true;\n this.data.l = l;\n }\n set a(a) {\n this.changed = true;\n this.data.a = a;\n }\n}\n/* EXPORT */\nexport default Channels;\n", "/* IMPORT */\nimport Channels from './/index.js';\n/* MAIN */\nconst channels = new Channels({ r: 0, g: 0, b: 0, a: 0 }, 'transparent');\n/* EXPORT */\nexport default channels;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\nimport { DEC2HEX } from '../constants.js';\n/* MAIN */\nconst Hex = {\n /* VARIABLES */\n re: /^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,\n /* API */\n parse: (color) => {\n if (color.charCodeAt(0) !== 35)\n return; // '#'\n const match = color.match(Hex.re);\n if (!match)\n return;\n const hex = match[1];\n const dec = parseInt(hex, 16);\n const length = hex.length;\n const hasAlpha = length % 4 === 0;\n const isFullLength = length > 4;\n const multiplier = isFullLength ? 1 : 17;\n const bits = isFullLength ? 8 : 4;\n const bitsOffset = hasAlpha ? 0 : -1;\n const mask = isFullLength ? 255 : 15;\n return ChannelsReusable.set({\n r: ((dec >> (bits * (bitsOffset + 3))) & mask) * multiplier,\n g: ((dec >> (bits * (bitsOffset + 2))) & mask) * multiplier,\n b: ((dec >> (bits * (bitsOffset + 1))) & mask) * multiplier,\n a: hasAlpha ? (dec & mask) * multiplier / 255 : 1\n }, color);\n },\n stringify: (channels) => {\n const { r, g, b, a } = channels;\n if (a < 1) { // #RRGGBBAA\n return `#${DEC2HEX[Math.round(r)]}${DEC2HEX[Math.round(g)]}${DEC2HEX[Math.round(b)]}${DEC2HEX[Math.round(a * 255)]}`;\n }\n else { // #RRGGBB\n return `#${DEC2HEX[Math.round(r)]}${DEC2HEX[Math.round(g)]}${DEC2HEX[Math.round(b)]}`;\n }\n }\n};\n/* EXPORT */\nexport default Hex;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\n/* MAIN */\nconst HSL = {\n /* VARIABLES */\n re: /^hsla?\\(\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?(?:deg|grad|rad|turn)?)\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?%)\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?%)(?:\\s*?(?:,|\\/)\\s*?\\+?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e-?\\d+)?(%)?))?\\s*?\\)$/i,\n hueRe: /^(.+?)(deg|grad|rad|turn)$/i,\n /* HELPERS */\n _hue2deg: (hue) => {\n const match = hue.match(HSL.hueRe);\n if (match) {\n const [, number, unit] = match;\n switch (unit) {\n case 'grad': return _.channel.clamp.h(parseFloat(number) * .9);\n case 'rad': return _.channel.clamp.h(parseFloat(number) * 180 / Math.PI);\n case 'turn': return _.channel.clamp.h(parseFloat(number) * 360);\n }\n }\n return _.channel.clamp.h(parseFloat(hue));\n },\n /* API */\n parse: (color) => {\n const charCode = color.charCodeAt(0);\n if (charCode !== 104 && charCode !== 72)\n return; // 'h'/'H'\n const match = color.match(HSL.re);\n if (!match)\n return;\n const [, h, s, l, a, isAlphaPercentage] = match;\n return ChannelsReusable.set({\n h: HSL._hue2deg(h),\n s: _.channel.clamp.s(parseFloat(s)),\n l: _.channel.clamp.l(parseFloat(l)),\n a: a ? _.channel.clamp.a(isAlphaPercentage ? parseFloat(a) / 100 : parseFloat(a)) : 1\n }, color);\n },\n stringify: (channels) => {\n const { h, s, l, a } = channels;\n if (a < 1) { // HSLA\n return `hsla(${_.lang.round(h)}, ${_.lang.round(s)}%, ${_.lang.round(l)}%, ${a})`;\n }\n else { // HSL\n return `hsl(${_.lang.round(h)}, ${_.lang.round(s)}%, ${_.lang.round(l)}%)`;\n }\n }\n};\n/* EXPORT */\nexport default HSL;\n", "/* IMPORT */\nimport Hex from './hex.js';\n/* MAIN */\nconst Keyword = {\n /* VARIABLES */\n colors: {\n aliceblue: '#f0f8ff',\n antiquewhite: '#faebd7',\n aqua: '#00ffff',\n aquamarine: '#7fffd4',\n azure: '#f0ffff',\n beige: '#f5f5dc',\n bisque: '#ffe4c4',\n black: '#000000',\n blanchedalmond: '#ffebcd',\n blue: '#0000ff',\n blueviolet: '#8a2be2',\n brown: '#a52a2a',\n burlywood: '#deb887',\n cadetblue: '#5f9ea0',\n chartreuse: '#7fff00',\n chocolate: '#d2691e',\n coral: '#ff7f50',\n cornflowerblue: '#6495ed',\n cornsilk: '#fff8dc',\n crimson: '#dc143c',\n cyanaqua: '#00ffff',\n darkblue: '#00008b',\n darkcyan: '#008b8b',\n darkgoldenrod: '#b8860b',\n darkgray: '#a9a9a9',\n darkgreen: '#006400',\n darkgrey: '#a9a9a9',\n darkkhaki: '#bdb76b',\n darkmagenta: '#8b008b',\n darkolivegreen: '#556b2f',\n darkorange: '#ff8c00',\n darkorchid: '#9932cc',\n darkred: '#8b0000',\n darksalmon: '#e9967a',\n darkseagreen: '#8fbc8f',\n darkslateblue: '#483d8b',\n darkslategray: '#2f4f4f',\n darkslategrey: '#2f4f4f',\n darkturquoise: '#00ced1',\n darkviolet: '#9400d3',\n deeppink: '#ff1493',\n deepskyblue: '#00bfff',\n dimgray: '#696969',\n dimgrey: '#696969',\n dodgerblue: '#1e90ff',\n firebrick: '#b22222',\n floralwhite: '#fffaf0',\n forestgreen: '#228b22',\n fuchsia: '#ff00ff',\n gainsboro: '#dcdcdc',\n ghostwhite: '#f8f8ff',\n gold: '#ffd700',\n goldenrod: '#daa520',\n gray: '#808080',\n green: '#008000',\n greenyellow: '#adff2f',\n grey: '#808080',\n honeydew: '#f0fff0',\n hotpink: '#ff69b4',\n indianred: '#cd5c5c',\n indigo: '#4b0082',\n ivory: '#fffff0',\n khaki: '#f0e68c',\n lavender: '#e6e6fa',\n lavenderblush: '#fff0f5',\n lawngreen: '#7cfc00',\n lemonchiffon: '#fffacd',\n lightblue: '#add8e6',\n lightcoral: '#f08080',\n lightcyan: '#e0ffff',\n lightgoldenrodyellow: '#fafad2',\n lightgray: '#d3d3d3',\n lightgreen: '#90ee90',\n lightgrey: '#d3d3d3',\n lightpink: '#ffb6c1',\n lightsalmon: '#ffa07a',\n lightseagreen: '#20b2aa',\n lightskyblue: '#87cefa',\n lightslategray: '#778899',\n lightslategrey: '#778899',\n lightsteelblue: '#b0c4de',\n lightyellow: '#ffffe0',\n lime: '#00ff00',\n limegreen: '#32cd32',\n linen: '#faf0e6',\n magenta: '#ff00ff',\n maroon: '#800000',\n mediumaquamarine: '#66cdaa',\n mediumblue: '#0000cd',\n mediumorchid: '#ba55d3',\n mediumpurple: '#9370db',\n mediumseagreen: '#3cb371',\n mediumslateblue: '#7b68ee',\n mediumspringgreen: '#00fa9a',\n mediumturquoise: '#48d1cc',\n mediumvioletred: '#c71585',\n midnightblue: '#191970',\n mintcream: '#f5fffa',\n mistyrose: '#ffe4e1',\n moccasin: '#ffe4b5',\n navajowhite: '#ffdead',\n navy: '#000080',\n oldlace: '#fdf5e6',\n olive: '#808000',\n olivedrab: '#6b8e23',\n orange: '#ffa500',\n orangered: '#ff4500',\n orchid: '#da70d6',\n palegoldenrod: '#eee8aa',\n palegreen: '#98fb98',\n paleturquoise: '#afeeee',\n palevioletred: '#db7093',\n papayawhip: '#ffefd5',\n peachpuff: '#ffdab9',\n peru: '#cd853f',\n pink: '#ffc0cb',\n plum: '#dda0dd',\n powderblue: '#b0e0e6',\n purple: '#800080',\n rebeccapurple: '#663399',\n red: '#ff0000',\n rosybrown: '#bc8f8f',\n royalblue: '#4169e1',\n saddlebrown: '#8b4513',\n salmon: '#fa8072',\n sandybrown: '#f4a460',\n seagreen: '#2e8b57',\n seashell: '#fff5ee',\n sienna: '#a0522d',\n silver: '#c0c0c0',\n skyblue: '#87ceeb',\n slateblue: '#6a5acd',\n slategray: '#708090',\n slategrey: '#708090',\n snow: '#fffafa',\n springgreen: '#00ff7f',\n tan: '#d2b48c',\n teal: '#008080',\n thistle: '#d8bfd8',\n transparent: '#00000000',\n turquoise: '#40e0d0',\n violet: '#ee82ee',\n wheat: '#f5deb3',\n white: '#ffffff',\n whitesmoke: '#f5f5f5',\n yellow: '#ffff00',\n yellowgreen: '#9acd32'\n },\n /* API */\n parse: (color) => {\n color = color.toLowerCase();\n const hex = Keyword.colors[color];\n if (!hex)\n return;\n return Hex.parse(hex);\n },\n stringify: (channels) => {\n const hex = Hex.stringify(channels);\n for (const name in Keyword.colors) {\n if (Keyword.colors[name] === hex)\n return name;\n }\n return;\n }\n};\n/* EXPORT */\nexport default Keyword;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\n/* MAIN */\nconst RGB = {\n /* VARIABLES */\n re: /^rgba?\\(\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?))\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?))\\s*?(?:,|\\s)\\s*?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?))(?:\\s*?(?:,|\\/)\\s*?\\+?(-?(?:\\d+(?:\\.\\d+)?|(?:\\.\\d+))(?:e\\d+)?(%?)))?\\s*?\\)$/i,\n /* API */\n parse: (color) => {\n const charCode = color.charCodeAt(0);\n if (charCode !== 114 && charCode !== 82)\n return; // 'r'/'R'\n const match = color.match(RGB.re);\n if (!match)\n return;\n const [, r, isRedPercentage, g, isGreenPercentage, b, isBluePercentage, a, isAlphaPercentage] = match;\n return ChannelsReusable.set({\n r: _.channel.clamp.r(isRedPercentage ? parseFloat(r) * 2.55 : parseFloat(r)),\n g: _.channel.clamp.g(isGreenPercentage ? parseFloat(g) * 2.55 : parseFloat(g)),\n b: _.channel.clamp.b(isBluePercentage ? parseFloat(b) * 2.55 : parseFloat(b)),\n a: a ? _.channel.clamp.a(isAlphaPercentage ? parseFloat(a) / 100 : parseFloat(a)) : 1\n }, color);\n },\n stringify: (channels) => {\n const { r, g, b, a } = channels;\n if (a < 1) { // RGBA\n return `rgba(${_.lang.round(r)}, ${_.lang.round(g)}, ${_.lang.round(b)}, ${_.lang.round(a)})`;\n }\n else { // RGB\n return `rgb(${_.lang.round(r)}, ${_.lang.round(g)}, ${_.lang.round(b)})`;\n }\n }\n};\n/* EXPORT */\nexport default RGB;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Hex from './hex.js';\nimport HSL from './hsl.js';\nimport Keyword from './keyword.js';\nimport RGB from './rgb.js';\nimport { TYPE } from '../constants.js';\n/* MAIN */\nconst Color = {\n /* VARIABLES */\n format: {\n keyword: Keyword,\n hex: Hex,\n rgb: RGB,\n rgba: RGB,\n hsl: HSL,\n hsla: HSL\n },\n /* API */\n parse: (color) => {\n if (typeof color !== 'string')\n return color;\n const channels = Hex.parse(color) || RGB.parse(color) || HSL.parse(color) || Keyword.parse(color); // Color providers ordered with performance in mind\n if (channels)\n return channels;\n throw new Error(`Unsupported color format: \"${color}\"`);\n },\n stringify: (channels) => {\n // SASS returns a keyword if possible, but we avoid doing that as it's slower and doesn't really add any value\n if (!channels.changed && channels.color)\n return channels.color;\n if (channels.type.is(TYPE.HSL) || channels.data.r === undefined) {\n return HSL.stringify(channels);\n }\n else if (channels.a < 1 || !Number.isInteger(channels.r) || !Number.isInteger(channels.g) || !Number.isInteger(channels.b)) {\n return RGB.stringify(channels);\n }\n else {\n return Hex.stringify(channels);\n }\n }\n};\n/* EXPORT */\nexport default Color;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\n//SOURCE: https://planetcalc.com/7779\nconst luminance = (color) => {\n const { r, g, b } = Color.parse(color);\n const luminance = .2126 * _.channel.toLinear(r) + .7152 * _.channel.toLinear(g) + .0722 * _.channel.toLinear(b);\n return _.lang.round(luminance);\n};\n/* EXPORT */\nexport default luminance;\n", "/* IMPORT */\nimport luminance from './luminance.js';\n/* MAIN */\nconst isLight = (color) => {\n return luminance(color) >= .5;\n};\n/* EXPORT */\nexport default isLight;\n", "/* IMPORT */\nimport isLight from './is_light.js';\n/* MAIN */\nconst isDark = (color) => {\n return !isLight(color);\n};\n/* EXPORT */\nexport default isDark;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\nconst adjustChannel = (color, channel, amount) => {\n const channels = Color.parse(color);\n const amountCurrent = channels[channel];\n const amountNext = _.channel.clamp[channel](amountCurrent + amount);\n if (amountCurrent !== amountNext)\n channels[channel] = amountNext;\n return Color.stringify(channels);\n};\n/* EXPORT */\nexport default adjustChannel;\n", "/* IMPORT */\nimport adjustChannel from './adjust_channel.js';\n/* MAIN */\nconst lighten = (color, amount) => {\n return adjustChannel(color, 'l', amount);\n};\n/* EXPORT */\nexport default lighten;\n", "/* IMPORT */\nimport adjustChannel from './adjust_channel.js';\n/* MAIN */\nconst darken = (color, amount) => {\n return adjustChannel(color, 'l', -amount);\n};\n/* EXPORT */\nexport default darken;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\nconst change = (color, channels) => {\n const ch = Color.parse(color);\n for (const c in channels) {\n ch[c] = _.channel.clamp[c](channels[c]);\n }\n return Color.stringify(ch);\n};\n/* EXPORT */\nexport default change;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport ChannelsReusable from '../channels/reusable.js';\nimport Color from '../color/index.js';\nimport change from './change.js';\n/* MAIN */\nconst rgba = (r, g, b = 0, a = 1) => {\n if (typeof r !== 'number')\n return change(r, { a: g });\n const channels = ChannelsReusable.set({\n r: _.channel.clamp.r(r),\n g: _.channel.clamp.g(g),\n b: _.channel.clamp.b(b),\n a: _.channel.clamp.a(a)\n });\n return Color.stringify(channels);\n};\n/* EXPORT */\nexport default rgba;\n", "/* IMPORT */\nimport _ from '../utils/index.js';\nimport Color from '../color/index.js';\n/* MAIN */\nconst channel = (color, channel) => {\n return _.lang.round(Color.parse(color)[channel]);\n};\n/* EXPORT */\nexport default channel;\n", "/* IMPORT */\nimport Color from '../color/index.js';\nimport change from './change.js';\n/* MAIN */\nconst adjust = (color, channels) => {\n const ch = Color.parse(color);\n const changes = {};\n for (const c in channels) {\n if (!channels[c])\n continue;\n changes[c] = ch[c] + channels[c];\n }\n return change(color, changes);\n};\n/* EXPORT */\nexport default adjust;\n", "/* IMPORT */\nimport Color from '../color/index.js';\nimport rgba from './rgba.js';\n/* MAIN */\n//SOURCE: https://github.com/sass/dart-sass/blob/7457d2e9e7e623d9844ffd037a070cf32d39c348/lib/src/functions/color.dart#L718-L756\nconst mix = (color1, color2, weight = 50) => {\n const { r: r1, g: g1, b: b1, a: a1 } = Color.parse(color1);\n const { r: r2, g: g2, b: b2, a: a2 } = Color.parse(color2);\n const weightScale = weight / 100;\n const weightNormalized = (weightScale * 2) - 1;\n const alphaDelta = a1 - a2;\n const weight1combined = ((weightNormalized * alphaDelta) === -1) ? weightNormalized : (weightNormalized + alphaDelta) / (1 + weightNormalized * alphaDelta);\n const weight1 = (weight1combined + 1) / 2;\n const weight2 = 1 - weight1;\n const r = (r1 * weight1) + (r2 * weight2);\n const g = (g1 * weight1) + (g2 * weight2);\n const b = (b1 * weight1) + (b2 * weight2);\n const a = (a1 * weightScale) + (a2 * (1 - weightScale));\n return rgba(r, g, b, a);\n};\n/* EXPORT */\nexport default mix;\n", "/* IMPORT */\nimport Color from '../color/index.js';\nimport mix from './mix.js';\n/* MAIN */\nconst invert = (color, weight = 100) => {\n const inverse = Color.parse(color);\n inverse.r = 255 - inverse.r;\n inverse.g = 255 - inverse.g;\n inverse.b = 255 - inverse.b;\n return mix(inverse, color, weight);\n};\n/* EXPORT */\nexport default invert;\n", "/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nexport default freeGlobal;\n", "import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nexport default root;\n", "import root from './_root.js';\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nexport default Symbol;\n", "import Symbol from './_Symbol.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nexport default getRawTag;\n", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nexport default objectToString;\n", "import Symbol from './_Symbol.js';\nimport getRawTag from './_getRawTag.js';\nimport objectToString from './_objectToString.js';\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nexport default baseGetTag;\n", "/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nexport default isObject;\n", "import baseGetTag from './_baseGetTag.js';\nimport isObject from './isObject.js';\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nexport default isFunction;\n", "import root from './_root.js';\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nexport default coreJsData;\n", "import coreJsData from './_coreJsData.js';\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nexport default isMasked;\n", "/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nexport default toSource;\n", "import isFunction from './isFunction.js';\nimport isMasked from './_isMasked.js';\nimport isObject from './isObject.js';\nimport toSource from './_toSource.js';\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nexport default baseIsNative;\n", "/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nexport default getValue;\n", "import baseIsNative from './_baseIsNative.js';\nimport getValue from './_getValue.js';\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nexport default getNative;\n", "import getNative from './_getNative.js';\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nexport default nativeCreate;\n", "import nativeCreate from './_nativeCreate.js';\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nexport default hashClear;\n", "/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default hashDelete;\n", "import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nexport default hashGet;\n", "import nativeCreate from './_nativeCreate.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nexport default hashHas;\n", "import nativeCreate from './_nativeCreate.js';\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nexport default hashSet;\n", "import hashClear from './_hashClear.js';\nimport hashDelete from './_hashDelete.js';\nimport hashGet from './_hashGet.js';\nimport hashHas from './_hashHas.js';\nimport hashSet from './_hashSet.js';\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nexport default Hash;\n", "/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nexport default listCacheClear;\n", "/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nexport default eq;\n", "import eq from './eq.js';\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nexport default assocIndexOf;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nexport default listCacheDelete;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nexport default listCacheGet;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nexport default listCacheHas;\n", "import assocIndexOf from './_assocIndexOf.js';\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nexport default listCacheSet;\n", "import listCacheClear from './_listCacheClear.js';\nimport listCacheDelete from './_listCacheDelete.js';\nimport listCacheGet from './_listCacheGet.js';\nimport listCacheHas from './_listCacheHas.js';\nimport listCacheSet from './_listCacheSet.js';\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nexport default ListCache;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nexport default Map;\n", "import Hash from './_Hash.js';\nimport ListCache from './_ListCache.js';\nimport Map from './_Map.js';\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nexport default mapCacheClear;\n", "/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nexport default isKeyable;\n", "import isKeyable from './_isKeyable.js';\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nexport default getMapData;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nexport default mapCacheDelete;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nexport default mapCacheGet;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nexport default mapCacheHas;\n", "import getMapData from './_getMapData.js';\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nexport default mapCacheSet;\n", "import mapCacheClear from './_mapCacheClear.js';\nimport mapCacheDelete from './_mapCacheDelete.js';\nimport mapCacheGet from './_mapCacheGet.js';\nimport mapCacheHas from './_mapCacheHas.js';\nimport mapCacheSet from './_mapCacheSet.js';\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nexport default MapCache;\n", "import MapCache from './_MapCache.js';\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nexport default memoize;\n", "import ListCache from './_ListCache.js';\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nexport default stackClear;\n", "/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nexport default stackDelete;\n", "/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nexport default stackGet;\n", "/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nexport default stackHas;\n", "import ListCache from './_ListCache.js';\nimport Map from './_Map.js';\nimport MapCache from './_MapCache.js';\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nexport default stackSet;\n", "import ListCache from './_ListCache.js';\nimport stackClear from './_stackClear.js';\nimport stackDelete from './_stackDelete.js';\nimport stackGet from './_stackGet.js';\nimport stackHas from './_stackHas.js';\nimport stackSet from './_stackSet.js';\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nexport default Stack;\n", "import getNative from './_getNative.js';\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nexport default defineProperty;\n", "import defineProperty from './_defineProperty.js';\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nexport default baseAssignValue;\n", "import baseAssignValue from './_baseAssignValue.js';\nimport eq from './eq.js';\n\n/**\n * This function is like `assignValue` except that it doesn't assign\n * `undefined` values.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction assignMergeValue(object, key, value) {\n if ((value !== undefined && !eq(object[key], value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n}\n\nexport default assignMergeValue;\n", "/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nexport default createBaseFor;\n", "import createBaseFor from './_createBaseFor.js';\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nexport default baseFor;\n", "import root from './_root.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined,\n allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined;\n\n/**\n * Creates a clone of `buffer`.\n *\n * @private\n * @param {Buffer} buffer The buffer to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Buffer} Returns the cloned buffer.\n */\nfunction cloneBuffer(buffer, isDeep) {\n if (isDeep) {\n return buffer.slice();\n }\n var length = buffer.length,\n result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);\n\n buffer.copy(result);\n return result;\n}\n\nexport default cloneBuffer;\n", "import root from './_root.js';\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nexport default Uint8Array;\n", "import Uint8Array from './_Uint8Array.js';\n\n/**\n * Creates a clone of `arrayBuffer`.\n *\n * @private\n * @param {ArrayBuffer} arrayBuffer The array buffer to clone.\n * @returns {ArrayBuffer} Returns the cloned array buffer.\n */\nfunction cloneArrayBuffer(arrayBuffer) {\n var result = new arrayBuffer.constructor(arrayBuffer.byteLength);\n new Uint8Array(result).set(new Uint8Array(arrayBuffer));\n return result;\n}\n\nexport default cloneArrayBuffer;\n", "import cloneArrayBuffer from './_cloneArrayBuffer.js';\n\n/**\n * Creates a clone of `typedArray`.\n *\n * @private\n * @param {Object} typedArray The typed array to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the cloned typed array.\n */\nfunction cloneTypedArray(typedArray, isDeep) {\n var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;\n return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);\n}\n\nexport default cloneTypedArray;\n", "/**\n * Copies the values of `source` to `array`.\n *\n * @private\n * @param {Array} source The array to copy values from.\n * @param {Array} [array=[]] The array to copy values to.\n * @returns {Array} Returns `array`.\n */\nfunction copyArray(source, array) {\n var index = -1,\n length = source.length;\n\n array || (array = Array(length));\n while (++index < length) {\n array[index] = source[index];\n }\n return array;\n}\n\nexport default copyArray;\n", "import isObject from './isObject.js';\n\n/** Built-in value references. */\nvar objectCreate = Object.create;\n\n/**\n * The base implementation of `_.create` without support for assigning\n * properties to the created object.\n *\n * @private\n * @param {Object} proto The object to inherit from.\n * @returns {Object} Returns the new object.\n */\nvar baseCreate = (function() {\n function object() {}\n return function(proto) {\n if (!isObject(proto)) {\n return {};\n }\n if (objectCreate) {\n return objectCreate(proto);\n }\n object.prototype = proto;\n var result = new object;\n object.prototype = undefined;\n return result;\n };\n}());\n\nexport default baseCreate;\n", "/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nexport default overArg;\n", "import overArg from './_overArg.js';\n\n/** Built-in value references. */\nvar getPrototype = overArg(Object.getPrototypeOf, Object);\n\nexport default getPrototype;\n", "/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nexport default isPrototype;\n", "import baseCreate from './_baseCreate.js';\nimport getPrototype from './_getPrototype.js';\nimport isPrototype from './_isPrototype.js';\n\n/**\n * Initializes an object clone.\n *\n * @private\n * @param {Object} object The object to clone.\n * @returns {Object} Returns the initialized clone.\n */\nfunction initCloneObject(object) {\n return (typeof object.constructor == 'function' && !isPrototype(object))\n ? baseCreate(getPrototype(object))\n : {};\n}\n\nexport default initCloneObject;\n", "/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nexport default isObjectLike;\n", "import baseGetTag from './_baseGetTag.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nexport default baseIsArguments;\n", "import baseIsArguments from './_baseIsArguments.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nexport default isArguments;\n", "/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nexport default isArray;\n", "/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nexport default isLength;\n", "import isFunction from './isFunction.js';\nimport isLength from './isLength.js';\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nexport default isArrayLike;\n", "import isArrayLike from './isArrayLike.js';\nimport isObjectLike from './isObjectLike.js';\n\n/**\n * This method is like `_.isArrayLike` except that it also checks if `value`\n * is an object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array-like object,\n * else `false`.\n * @example\n *\n * _.isArrayLikeObject([1, 2, 3]);\n * // => true\n *\n * _.isArrayLikeObject(document.body.children);\n * // => true\n *\n * _.isArrayLikeObject('abc');\n * // => false\n *\n * _.isArrayLikeObject(_.noop);\n * // => false\n */\nfunction isArrayLikeObject(value) {\n return isObjectLike(value) && isArrayLike(value);\n}\n\nexport default isArrayLikeObject;\n", "/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nexport default stubFalse;\n", "import root from './_root.js';\nimport stubFalse from './stubFalse.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nexport default isBuffer;\n", "import baseGetTag from './_baseGetTag.js';\nimport getPrototype from './_getPrototype.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to infer the `Object` constructor. */\nvar objectCtorString = funcToString.call(Object);\n\n/**\n * Checks if `value` is a plain object, that is, an object created by the\n * `Object` constructor or one with a `[[Prototype]]` of `null`.\n *\n * @static\n * @memberOf _\n * @since 0.8.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * _.isPlainObject(new Foo);\n * // => false\n *\n * _.isPlainObject([1, 2, 3]);\n * // => false\n *\n * _.isPlainObject({ 'x': 0, 'y': 0 });\n * // => true\n *\n * _.isPlainObject(Object.create(null));\n * // => true\n */\nfunction isPlainObject(value) {\n if (!isObjectLike(value) || baseGetTag(value) != objectTag) {\n return false;\n }\n var proto = getPrototype(value);\n if (proto === null) {\n return true;\n }\n var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;\n return typeof Ctor == 'function' && Ctor instanceof Ctor &&\n funcToString.call(Ctor) == objectCtorString;\n}\n\nexport default isPlainObject;\n", "import baseGetTag from './_baseGetTag.js';\nimport isLength from './isLength.js';\nimport isObjectLike from './isObjectLike.js';\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nexport default baseIsTypedArray;\n", "/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nexport default baseUnary;\n", "import freeGlobal from './_freeGlobal.js';\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nexport default nodeUtil;\n", "import baseIsTypedArray from './_baseIsTypedArray.js';\nimport baseUnary from './_baseUnary.js';\nimport nodeUtil from './_nodeUtil.js';\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nexport default isTypedArray;\n", "/**\n * Gets the value at `key`, unless `key` is \"__proto__\" or \"constructor\".\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction safeGet(object, key) {\n if (key === 'constructor' && typeof object[key] === 'function') {\n return;\n }\n\n if (key == '__proto__') {\n return;\n }\n\n return object[key];\n}\n\nexport default safeGet;\n", "import baseAssignValue from './_baseAssignValue.js';\nimport eq from './eq.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Assigns `value` to `key` of `object` if the existing value is not equivalent\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction assignValue(object, key, value) {\n var objValue = object[key];\n if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n}\n\nexport default assignValue;\n", "import assignValue from './_assignValue.js';\nimport baseAssignValue from './_baseAssignValue.js';\n\n/**\n * Copies properties of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy properties from.\n * @param {Array} props The property identifiers to copy.\n * @param {Object} [object={}] The object to copy properties to.\n * @param {Function} [customizer] The function to customize copied values.\n * @returns {Object} Returns `object`.\n */\nfunction copyObject(source, props, object, customizer) {\n var isNew = !object;\n object || (object = {});\n\n var index = -1,\n length = props.length;\n\n while (++index < length) {\n var key = props[index];\n\n var newValue = customizer\n ? customizer(object[key], source[key], key, object, source)\n : undefined;\n\n if (newValue === undefined) {\n newValue = source[key];\n }\n if (isNew) {\n baseAssignValue(object, key, newValue);\n } else {\n assignValue(object, key, newValue);\n }\n }\n return object;\n}\n\nexport default copyObject;\n", "/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nexport default baseTimes;\n", "/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nexport default isIndex;\n", "import baseTimes from './_baseTimes.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isBuffer from './isBuffer.js';\nimport isIndex from './_isIndex.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default arrayLikeKeys;\n", "/**\n * This function is like\n * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * except that it includes inherited enumerable properties.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction nativeKeysIn(object) {\n var result = [];\n if (object != null) {\n for (var key in Object(object)) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default nativeKeysIn;\n", "import isObject from './isObject.js';\nimport isPrototype from './_isPrototype.js';\nimport nativeKeysIn from './_nativeKeysIn.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeysIn(object) {\n if (!isObject(object)) {\n return nativeKeysIn(object);\n }\n var isProto = isPrototype(object),\n result = [];\n\n for (var key in object) {\n if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default baseKeysIn;\n", "import arrayLikeKeys from './_arrayLikeKeys.js';\nimport baseKeysIn from './_baseKeysIn.js';\nimport isArrayLike from './isArrayLike.js';\n\n/**\n * Creates an array of the own and inherited enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keysIn(new Foo);\n * // => ['a', 'b', 'c'] (iteration order is not guaranteed)\n */\nfunction keysIn(object) {\n return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);\n}\n\nexport default keysIn;\n", "import copyObject from './_copyObject.js';\nimport keysIn from './keysIn.js';\n\n/**\n * Converts `value` to a plain object flattening inherited enumerable string\n * keyed properties of `value` to own properties of the plain object.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {Object} Returns the converted plain object.\n * @example\n *\n * function Foo() {\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.assign({ 'a': 1 }, new Foo);\n * // => { 'a': 1, 'b': 2 }\n *\n * _.assign({ 'a': 1 }, _.toPlainObject(new Foo));\n * // => { 'a': 1, 'b': 2, 'c': 3 }\n */\nfunction toPlainObject(value) {\n return copyObject(value, keysIn(value));\n}\n\nexport default toPlainObject;\n", "import assignMergeValue from './_assignMergeValue.js';\nimport cloneBuffer from './_cloneBuffer.js';\nimport cloneTypedArray from './_cloneTypedArray.js';\nimport copyArray from './_copyArray.js';\nimport initCloneObject from './_initCloneObject.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isArrayLikeObject from './isArrayLikeObject.js';\nimport isBuffer from './isBuffer.js';\nimport isFunction from './isFunction.js';\nimport isObject from './isObject.js';\nimport isPlainObject from './isPlainObject.js';\nimport isTypedArray from './isTypedArray.js';\nimport safeGet from './_safeGet.js';\nimport toPlainObject from './toPlainObject.js';\n\n/**\n * A specialized version of `baseMerge` for arrays and objects which performs\n * deep merges and tracks traversed objects enabling objects with circular\n * references to be merged.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {string} key The key of the value to merge.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} mergeFunc The function to merge values.\n * @param {Function} [customizer] The function to customize assigned values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\nfunction baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {\n var objValue = safeGet(object, key),\n srcValue = safeGet(source, key),\n stacked = stack.get(srcValue);\n\n if (stacked) {\n assignMergeValue(object, key, stacked);\n return;\n }\n var newValue = customizer\n ? customizer(objValue, srcValue, (key + ''), object, source, stack)\n : undefined;\n\n var isCommon = newValue === undefined;\n\n if (isCommon) {\n var isArr = isArray(srcValue),\n isBuff = !isArr && isBuffer(srcValue),\n isTyped = !isArr && !isBuff && isTypedArray(srcValue);\n\n newValue = srcValue;\n if (isArr || isBuff || isTyped) {\n if (isArray(objValue)) {\n newValue = objValue;\n }\n else if (isArrayLikeObject(objValue)) {\n newValue = copyArray(objValue);\n }\n else if (isBuff) {\n isCommon = false;\n newValue = cloneBuffer(srcValue, true);\n }\n else if (isTyped) {\n isCommon = false;\n newValue = cloneTypedArray(srcValue, true);\n }\n else {\n newValue = [];\n }\n }\n else if (isPlainObject(srcValue) || isArguments(srcValue)) {\n newValue = objValue;\n if (isArguments(objValue)) {\n newValue = toPlainObject(objValue);\n }\n else if (!isObject(objValue) || isFunction(objValue)) {\n newValue = initCloneObject(srcValue);\n }\n }\n else {\n isCommon = false;\n }\n }\n if (isCommon) {\n // Recursively merge objects and arrays (susceptible to call stack limits).\n stack.set(srcValue, newValue);\n mergeFunc(newValue, srcValue, srcIndex, customizer, stack);\n stack['delete'](srcValue);\n }\n assignMergeValue(object, key, newValue);\n}\n\nexport default baseMergeDeep;\n", "import Stack from './_Stack.js';\nimport assignMergeValue from './_assignMergeValue.js';\nimport baseFor from './_baseFor.js';\nimport baseMergeDeep from './_baseMergeDeep.js';\nimport isObject from './isObject.js';\nimport keysIn from './keysIn.js';\nimport safeGet from './_safeGet.js';\n\n/**\n * The base implementation of `_.merge` without support for multiple sources.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} [customizer] The function to customize merged values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\nfunction baseMerge(object, source, srcIndex, customizer, stack) {\n if (object === source) {\n return;\n }\n baseFor(source, function(srcValue, key) {\n stack || (stack = new Stack);\n if (isObject(srcValue)) {\n baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);\n }\n else {\n var newValue = customizer\n ? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack)\n : undefined;\n\n if (newValue === undefined) {\n newValue = srcValue;\n }\n assignMergeValue(object, key, newValue);\n }\n }, keysIn);\n}\n\nexport default baseMerge;\n", "/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nexport default identity;\n", "/**\n * A faster alternative to `Function#apply`, this function invokes `func`\n * with the `this` binding of `thisArg` and the arguments of `args`.\n *\n * @private\n * @param {Function} func The function to invoke.\n * @param {*} thisArg The `this` binding of `func`.\n * @param {Array} args The arguments to invoke `func` with.\n * @returns {*} Returns the result of `func`.\n */\nfunction apply(func, thisArg, args) {\n switch (args.length) {\n case 0: return func.call(thisArg);\n case 1: return func.call(thisArg, args[0]);\n case 2: return func.call(thisArg, args[0], args[1]);\n case 3: return func.call(thisArg, args[0], args[1], args[2]);\n }\n return func.apply(thisArg, args);\n}\n\nexport default apply;\n", "import apply from './_apply.js';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max;\n\n/**\n * A specialized version of `baseRest` which transforms the rest array.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @param {Function} transform The rest array transform.\n * @returns {Function} Returns the new function.\n */\nfunction overRest(func, start, transform) {\n start = nativeMax(start === undefined ? (func.length - 1) : start, 0);\n return function() {\n var args = arguments,\n index = -1,\n length = nativeMax(args.length - start, 0),\n array = Array(length);\n\n while (++index < length) {\n array[index] = args[start + index];\n }\n index = -1;\n var otherArgs = Array(start + 1);\n while (++index < start) {\n otherArgs[index] = args[index];\n }\n otherArgs[start] = transform(array);\n return apply(func, this, otherArgs);\n };\n}\n\nexport default overRest;\n", "/**\n * Creates a function that returns `value`.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {*} value The value to return from the new function.\n * @returns {Function} Returns the new constant function.\n * @example\n *\n * var objects = _.times(2, _.constant({ 'a': 1 }));\n *\n * console.log(objects);\n * // => [{ 'a': 1 }, { 'a': 1 }]\n *\n * console.log(objects[0] === objects[1]);\n * // => true\n */\nfunction constant(value) {\n return function() {\n return value;\n };\n}\n\nexport default constant;\n", "import constant from './constant.js';\nimport defineProperty from './_defineProperty.js';\nimport identity from './identity.js';\n\n/**\n * The base implementation of `setToString` without support for hot loop shorting.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar baseSetToString = !defineProperty ? identity : function(func, string) {\n return defineProperty(func, 'toString', {\n 'configurable': true,\n 'enumerable': false,\n 'value': constant(string),\n 'writable': true\n });\n};\n\nexport default baseSetToString;\n", "/** Used to detect hot functions by number of calls within a span of milliseconds. */\nvar HOT_COUNT = 800,\n HOT_SPAN = 16;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeNow = Date.now;\n\n/**\n * Creates a function that'll short out and invoke `identity` instead\n * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN`\n * milliseconds.\n *\n * @private\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new shortable function.\n */\nfunction shortOut(func) {\n var count = 0,\n lastCalled = 0;\n\n return function() {\n var stamp = nativeNow(),\n remaining = HOT_SPAN - (stamp - lastCalled);\n\n lastCalled = stamp;\n if (remaining > 0) {\n if (++count >= HOT_COUNT) {\n return arguments[0];\n }\n } else {\n count = 0;\n }\n return func.apply(undefined, arguments);\n };\n}\n\nexport default shortOut;\n", "import baseSetToString from './_baseSetToString.js';\nimport shortOut from './_shortOut.js';\n\n/**\n * Sets the `toString` method of `func` to return `string`.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\nvar setToString = shortOut(baseSetToString);\n\nexport default setToString;\n", "import identity from './identity.js';\nimport overRest from './_overRest.js';\nimport setToString from './_setToString.js';\n\n/**\n * The base implementation of `_.rest` which doesn't validate or coerce arguments.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @returns {Function} Returns the new function.\n */\nfunction baseRest(func, start) {\n return setToString(overRest(func, start, identity), func + '');\n}\n\nexport default baseRest;\n", "import eq from './eq.js';\nimport isArrayLike from './isArrayLike.js';\nimport isIndex from './_isIndex.js';\nimport isObject from './isObject.js';\n\n/**\n * Checks if the given arguments are from an iteratee call.\n *\n * @private\n * @param {*} value The potential iteratee value argument.\n * @param {*} index The potential iteratee index or key argument.\n * @param {*} object The potential iteratee object argument.\n * @returns {boolean} Returns `true` if the arguments are from an iteratee call,\n * else `false`.\n */\nfunction isIterateeCall(value, index, object) {\n if (!isObject(object)) {\n return false;\n }\n var type = typeof index;\n if (type == 'number'\n ? (isArrayLike(object) && isIndex(index, object.length))\n : (type == 'string' && index in object)\n ) {\n return eq(object[index], value);\n }\n return false;\n}\n\nexport default isIterateeCall;\n", "import baseRest from './_baseRest.js';\nimport isIterateeCall from './_isIterateeCall.js';\n\n/**\n * Creates a function like `_.assign`.\n *\n * @private\n * @param {Function} assigner The function to assign values.\n * @returns {Function} Returns the new assigner function.\n */\nfunction createAssigner(assigner) {\n return baseRest(function(object, sources) {\n var index = -1,\n length = sources.length,\n customizer = length > 1 ? sources[length - 1] : undefined,\n guard = length > 2 ? sources[2] : undefined;\n\n customizer = (assigner.length > 3 && typeof customizer == 'function')\n ? (length--, customizer)\n : undefined;\n\n if (guard && isIterateeCall(sources[0], sources[1], guard)) {\n customizer = length < 3 ? undefined : customizer;\n length = 1;\n }\n object = Object(object);\n while (++index < length) {\n var source = sources[index];\n if (source) {\n assigner(object, source, index, customizer);\n }\n }\n return object;\n });\n}\n\nexport default createAssigner;\n", "import baseMerge from './_baseMerge.js';\nimport createAssigner from './_createAssigner.js';\n\n/**\n * This method is like `_.assign` except that it recursively merges own and\n * inherited enumerable string keyed properties of source objects into the\n * destination object. Source properties that resolve to `undefined` are\n * skipped if a destination value exists. Array and plain object properties\n * are merged recursively. Other objects and value types are overridden by\n * assignment. Source objects are applied from left to right. Subsequent\n * sources overwrite property assignments of previous sources.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 0.5.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = {\n * 'a': [{ 'b': 2 }, { 'd': 4 }]\n * };\n *\n * var other = {\n * 'a': [{ 'c': 3 }, { 'e': 5 }]\n * };\n *\n * _.merge(object, other);\n * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] }\n */\nvar merge = createAssigner(function(object, source, srcIndex) {\n baseMerge(object, source, srcIndex);\n});\n\nexport default merge;\n", "import overArg from './_overArg.js';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nexport default nativeKeys;\n", "import isPrototype from './_isPrototype.js';\nimport nativeKeys from './_nativeKeys.js';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nexport default baseKeys;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nexport default DataView;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nexport default Promise;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nexport default Set;\n", "import getNative from './_getNative.js';\nimport root from './_root.js';\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nexport default WeakMap;\n", "import DataView from './_DataView.js';\nimport Map from './_Map.js';\nimport Promise from './_Promise.js';\nimport Set from './_Set.js';\nimport WeakMap from './_WeakMap.js';\nimport baseGetTag from './_baseGetTag.js';\nimport toSource from './_toSource.js';\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nexport default getTag;\n", "import baseKeys from './_baseKeys.js';\nimport getTag from './_getTag.js';\nimport isArguments from './isArguments.js';\nimport isArray from './isArray.js';\nimport isArrayLike from './isArrayLike.js';\nimport isBuffer from './isBuffer.js';\nimport isPrototype from './_isPrototype.js';\nimport isTypedArray from './isTypedArray.js';\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n setTag = '[object Set]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if `value` is an empty object, collection, map, or set.\n *\n * Objects are considered empty if they have no own enumerable string keyed\n * properties.\n *\n * Array-like values such as `arguments` objects, arrays, buffers, strings, or\n * jQuery-like collections are considered empty if they have a `length` of `0`.\n * Similarly, maps and sets are considered empty if they have a `size` of `0`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is empty, else `false`.\n * @example\n *\n * _.isEmpty(null);\n * // => true\n *\n * _.isEmpty(true);\n * // => true\n *\n * _.isEmpty(1);\n * // => true\n *\n * _.isEmpty([1, 2, 3]);\n * // => false\n *\n * _.isEmpty({ 'a': 1 });\n * // => false\n */\nfunction isEmpty(value) {\n if (value == null) {\n return true;\n }\n if (isArrayLike(value) &&\n (isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||\n isBuffer(value) || isTypedArray(value) || isArguments(value))) {\n return !value.length;\n }\n var tag = getTag(value);\n if (tag == mapTag || tag == setTag) {\n return !value.size;\n }\n if (isPrototype(value)) {\n return !baseKeys(value).length;\n }\n for (var key in value) {\n if (hasOwnProperty.call(value, key)) {\n return false;\n }\n }\n return true;\n}\n\nexport default isEmpty;\n", "import { dedent } from \"ts-dedent\";\nimport dayjs from \"dayjs\";\nimport { sanitizeUrl } from \"@braintree/sanitize-url\";\nimport { select, curveBasis, curveBasisClosed, curveBasisOpen, curveBumpX, curveBumpY, curveBundle, curveCardinalClosed, curveCardinalOpen, curveCardinal, curveCatmullRomClosed, curveCatmullRomOpen, curveCatmullRom, curveLinear, curveLinearClosed, curveMonotoneX, curveMonotoneY, curveNatural, curveStep, curveStepAfter, curveStepBefore } from \"d3\";\nimport DOMPurify from \"dompurify\";\nimport { adjust, invert, darken, lighten, isDark, rgba } from \"khroma\";\nimport memoize from \"lodash-es/memoize.js\";\nimport merge$1 from \"lodash-es/merge.js\";\nimport { serialize, compile, stringify } from \"stylis\";\nimport isEmpty from \"lodash-es/isEmpty.js\";\nconst LEVELS = {\n trace: 0,\n debug: 1,\n info: 2,\n warn: 3,\n error: 4,\n fatal: 5\n};\nconst log$1 = {\n trace: (..._args) => {\n },\n debug: (..._args) => {\n },\n info: (..._args) => {\n },\n warn: (..._args) => {\n },\n error: (..._args) => {\n },\n fatal: (..._args) => {\n }\n};\nconst setLogLevel$1 = function(level = \"fatal\") {\n let numericLevel = LEVELS.fatal;\n if (typeof level === \"string\") {\n level = level.toLowerCase();\n if (level in LEVELS) {\n numericLevel = LEVELS[level];\n }\n } else if (typeof level === \"number\") {\n numericLevel = level;\n }\n log$1.trace = () => {\n };\n log$1.debug = () => {\n };\n log$1.info = () => {\n };\n log$1.warn = () => {\n };\n log$1.error = () => {\n };\n log$1.fatal = () => {\n };\n if (numericLevel <= LEVELS.fatal) {\n log$1.fatal = console.error ? console.error.bind(console, format(\"FATAL\"), \"color: orange\") : console.log.bind(console, \"\\x1B[35m\", format(\"FATAL\"));\n }\n if (numericLevel <= LEVELS.error) {\n log$1.error = console.error ? console.error.bind(console, format(\"ERROR\"), \"color: orange\") : console.log.bind(console, \"\\x1B[31m\", format(\"ERROR\"));\n }\n if (numericLevel <= LEVELS.warn) {\n log$1.warn = console.warn ? console.warn.bind(console, format(\"WARN\"), \"color: orange\") : console.log.bind(console, `\\x1B[33m`, format(\"WARN\"));\n }\n if (numericLevel <= LEVELS.info) {\n log$1.info = console.info ? console.info.bind(console, format(\"INFO\"), \"color: lightblue\") : console.log.bind(console, \"\\x1B[34m\", format(\"INFO\"));\n }\n if (numericLevel <= LEVELS.debug) {\n log$1.debug = console.debug ? console.debug.bind(console, format(\"DEBUG\"), \"color: lightgreen\") : console.log.bind(console, \"\\x1B[32m\", format(\"DEBUG\"));\n }\n if (numericLevel <= LEVELS.trace) {\n log$1.trace = console.debug ? console.debug.bind(console, format(\"TRACE\"), \"color: lightgreen\") : console.log.bind(console, \"\\x1B[32m\", format(\"TRACE\"));\n }\n};\nconst format = (level) => {\n const time = dayjs().format(\"ss.SSS\");\n return `%c${time} : ${level} : `;\n};\nconst lineBreakRegex = //gi;\nconst getRows = (s) => {\n if (!s) {\n return [\"\"];\n }\n const str2 = breakToPlaceholder(s).replace(/\\\\n/g, \"#br#\");\n return str2.split(\"#br#\");\n};\nconst removeScript = (txt) => {\n return DOMPurify.sanitize(txt);\n};\nconst sanitizeMore = (text, config2) => {\n var _a;\n if (((_a = config2.flowchart) == null ? void 0 : _a.htmlLabels) !== false) {\n const level = config2.securityLevel;\n if (level === \"antiscript\" || level === \"strict\") {\n text = removeScript(text);\n } else if (level !== \"loose\") {\n text = breakToPlaceholder(text);\n text = text.replace(//g, \">\");\n text = text.replace(/=/g, \"=\");\n text = placeholderToBreak(text);\n }\n }\n return text;\n};\nconst sanitizeText$2 = (text, config2) => {\n if (!text) {\n return text;\n }\n if (config2.dompurifyConfig) {\n text = DOMPurify.sanitize(sanitizeMore(text, config2), config2.dompurifyConfig).toString();\n } else {\n text = DOMPurify.sanitize(sanitizeMore(text, config2), {\n FORBID_TAGS: [\"style\"]\n }).toString();\n }\n return text;\n};\nconst sanitizeTextOrArray = (a, config2) => {\n if (typeof a === \"string\") {\n return sanitizeText$2(a, config2);\n }\n return a.flat().map((x) => sanitizeText$2(x, config2));\n};\nconst hasBreaks = (text) => {\n return lineBreakRegex.test(text);\n};\nconst splitBreaks = (text) => {\n return text.split(lineBreakRegex);\n};\nconst placeholderToBreak = (s) => {\n return s.replace(/#br#/g, \"
      \");\n};\nconst breakToPlaceholder = (s) => {\n return s.replace(lineBreakRegex, \"#br#\");\n};\nconst getUrl = (useAbsolute) => {\n let url = \"\";\n if (useAbsolute) {\n url = window.location.protocol + \"//\" + window.location.host + window.location.pathname + window.location.search;\n url = url.replaceAll(/\\(/g, \"\\\\(\");\n url = url.replaceAll(/\\)/g, \"\\\\)\");\n }\n return url;\n};\nconst evaluate = (val) => val === false || [\"false\", \"null\", \"0\"].includes(String(val).trim().toLowerCase()) ? false : true;\nconst getMax = function(...values) {\n const newValues = values.filter((value) => {\n return !isNaN(value);\n });\n return Math.max(...newValues);\n};\nconst getMin = function(...values) {\n const newValues = values.filter((value) => {\n return !isNaN(value);\n });\n return Math.min(...newValues);\n};\nconst parseGenericTypes = function(input) {\n const inputSets = input.split(/(,)/);\n const output = [];\n for (let i = 0; i < inputSets.length; i++) {\n let thisSet = inputSets[i];\n if (thisSet === \",\" && i > 0 && i + 1 < inputSets.length) {\n const previousSet = inputSets[i - 1];\n const nextSet = inputSets[i + 1];\n if (shouldCombineSets(previousSet, nextSet)) {\n thisSet = previousSet + \",\" + nextSet;\n i++;\n output.pop();\n }\n }\n output.push(processSet(thisSet));\n }\n return output.join(\"\");\n};\nconst countOccurrence = (string, substring) => {\n return Math.max(0, string.split(substring).length - 1);\n};\nconst shouldCombineSets = (previousSet, nextSet) => {\n const prevCount = countOccurrence(previousSet, \"~\");\n const nextCount = countOccurrence(nextSet, \"~\");\n return prevCount === 1 && nextCount === 1;\n};\nconst processSet = (input) => {\n const tildeCount = countOccurrence(input, \"~\");\n let hasStartingTilde = false;\n if (tildeCount <= 1) {\n return input;\n }\n if (tildeCount % 2 !== 0 && input.startsWith(\"~\")) {\n input = input.substring(1);\n hasStartingTilde = true;\n }\n const chars = [...input];\n let first = chars.indexOf(\"~\");\n let last = chars.lastIndexOf(\"~\");\n while (first !== -1 && last !== -1 && first !== last) {\n chars[first] = \"<\";\n chars[last] = \">\";\n first = chars.indexOf(\"~\");\n last = chars.lastIndexOf(\"~\");\n }\n if (hasStartingTilde) {\n chars.unshift(\"~\");\n }\n return chars.join(\"\");\n};\nconst common$1 = {\n getRows,\n sanitizeText: sanitizeText$2,\n sanitizeTextOrArray,\n hasBreaks,\n splitBreaks,\n lineBreakRegex,\n removeScript,\n getUrl,\n evaluate,\n getMax,\n getMin\n};\nconst mkBorder = (col, darkMode) => darkMode ? adjust(col, { s: -40, l: 10 }) : adjust(col, { s: -40, l: -10 });\nconst oldAttributeBackgroundColorOdd = \"#ffffff\";\nconst oldAttributeBackgroundColorEven = \"#f2f2f2\";\nlet Theme$4 = class Theme {\n constructor() {\n this.background = \"#f4f4f4\";\n this.primaryColor = \"#fff4dd\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"#333\";\n this.THEME_COLOR_LIMIT = 12;\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.primaryTextColor = this.primaryTextColor || (this.darkMode ? \"#eee\" : \"#333\");\n this.secondaryColor = this.secondaryColor || adjust(this.primaryColor, { h: -120 });\n this.tertiaryColor = this.tertiaryColor || adjust(this.primaryColor, { h: 180, l: 5 });\n this.primaryBorderColor = this.primaryBorderColor || mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = this.secondaryBorderColor || mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = this.tertiaryBorderColor || mkBorder(this.tertiaryColor, this.darkMode);\n this.noteBorderColor = this.noteBorderColor || mkBorder(this.noteBkgColor, this.darkMode);\n this.noteBkgColor = this.noteBkgColor || \"#fff5ad\";\n this.noteTextColor = this.noteTextColor || \"#333\";\n this.secondaryTextColor = this.secondaryTextColor || invert(this.secondaryColor);\n this.tertiaryTextColor = this.tertiaryTextColor || invert(this.tertiaryColor);\n this.lineColor = this.lineColor || invert(this.background);\n this.arrowheadColor = this.arrowheadColor || invert(this.background);\n this.textColor = this.textColor || this.primaryTextColor;\n this.border2 = this.border2 || this.tertiaryBorderColor;\n this.nodeBkg = this.nodeBkg || this.primaryColor;\n this.mainBkg = this.mainBkg || this.primaryColor;\n this.nodeBorder = this.nodeBorder || this.primaryBorderColor;\n this.clusterBkg = this.clusterBkg || this.tertiaryColor;\n this.clusterBorder = this.clusterBorder || this.tertiaryBorderColor;\n this.defaultLinkColor = this.defaultLinkColor || this.lineColor;\n this.titleColor = this.titleColor || this.tertiaryTextColor;\n this.edgeLabelBackground = this.edgeLabelBackground || (this.darkMode ? darken(this.secondaryColor, 30) : this.secondaryColor);\n this.nodeTextColor = this.nodeTextColor || this.primaryTextColor;\n this.actorBorder = this.actorBorder || this.primaryBorderColor;\n this.actorBkg = this.actorBkg || this.mainBkg;\n this.actorTextColor = this.actorTextColor || this.primaryTextColor;\n this.actorLineColor = this.actorLineColor || \"grey\";\n this.labelBoxBkgColor = this.labelBoxBkgColor || this.actorBkg;\n this.signalColor = this.signalColor || this.textColor;\n this.signalTextColor = this.signalTextColor || this.textColor;\n this.labelBoxBorderColor = this.labelBoxBorderColor || this.actorBorder;\n this.labelTextColor = this.labelTextColor || this.actorTextColor;\n this.loopTextColor = this.loopTextColor || this.actorTextColor;\n this.activationBorderColor = this.activationBorderColor || darken(this.secondaryColor, 10);\n this.activationBkgColor = this.activationBkgColor || this.secondaryColor;\n this.sequenceNumberColor = this.sequenceNumberColor || invert(this.lineColor);\n this.sectionBkgColor = this.sectionBkgColor || this.tertiaryColor;\n this.altSectionBkgColor = this.altSectionBkgColor || \"white\";\n this.sectionBkgColor = this.sectionBkgColor || this.secondaryColor;\n this.sectionBkgColor2 = this.sectionBkgColor2 || this.primaryColor;\n this.excludeBkgColor = this.excludeBkgColor || \"#eeeeee\";\n this.taskBorderColor = this.taskBorderColor || this.primaryBorderColor;\n this.taskBkgColor = this.taskBkgColor || this.primaryColor;\n this.activeTaskBorderColor = this.activeTaskBorderColor || this.primaryColor;\n this.activeTaskBkgColor = this.activeTaskBkgColor || lighten(this.primaryColor, 23);\n this.gridColor = this.gridColor || \"lightgrey\";\n this.doneTaskBkgColor = this.doneTaskBkgColor || \"lightgrey\";\n this.doneTaskBorderColor = this.doneTaskBorderColor || \"grey\";\n this.critBorderColor = this.critBorderColor || \"#ff8888\";\n this.critBkgColor = this.critBkgColor || \"red\";\n this.todayLineColor = this.todayLineColor || \"red\";\n this.taskTextColor = this.taskTextColor || this.textColor;\n this.taskTextOutsideColor = this.taskTextOutsideColor || this.textColor;\n this.taskTextLightColor = this.taskTextLightColor || this.textColor;\n this.taskTextColor = this.taskTextColor || this.primaryTextColor;\n this.taskTextDarkColor = this.taskTextDarkColor || this.textColor;\n this.taskTextClickableColor = this.taskTextClickableColor || \"#003163\";\n this.personBorder = this.personBorder || this.primaryBorderColor;\n this.personBkg = this.personBkg || this.mainBkg;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || this.tertiaryColor;\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.nodeBorder;\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.specialStateColor = this.lineColor;\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210, l: 150 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n if (this.darkMode) {\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 75);\n }\n } else {\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 25);\n }\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || invert(this[\"cScale\" + i]);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n if (this.darkMode) {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || lighten(this[\"cScale\" + i], 10);\n } else {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 10);\n }\n }\n this.scaleLabelColor = this.scaleLabelColor || this.labelTextColor;\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n const multiplier = this.darkMode ? -4 : -1;\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 180, s: -15, l: multiplier * (5 + i * 3) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 180, s: -15, l: multiplier * (8 + i * 3) });\n }\n this.classText = this.classText || this.textColor;\n this.fillType0 = this.fillType0 || this.primaryColor;\n this.fillType1 = this.fillType1 || this.secondaryColor;\n this.fillType2 = this.fillType2 || adjust(this.primaryColor, { h: 64 });\n this.fillType3 = this.fillType3 || adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = this.fillType4 || adjust(this.primaryColor, { h: -64 });\n this.fillType5 = this.fillType5 || adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = this.fillType6 || adjust(this.primaryColor, { h: 128 });\n this.fillType7 = this.fillType7 || adjust(this.secondaryColor, { h: 128 });\n this.pie1 = this.pie1 || this.primaryColor;\n this.pie2 = this.pie2 || this.secondaryColor;\n this.pie3 = this.pie3 || this.tertiaryColor;\n this.pie4 = this.pie4 || adjust(this.primaryColor, { l: -10 });\n this.pie5 = this.pie5 || adjust(this.secondaryColor, { l: -10 });\n this.pie6 = this.pie6 || adjust(this.tertiaryColor, { l: -10 });\n this.pie7 = this.pie7 || adjust(this.primaryColor, { h: 60, l: -10 });\n this.pie8 = this.pie8 || adjust(this.primaryColor, { h: -60, l: -10 });\n this.pie9 = this.pie9 || adjust(this.primaryColor, { h: 120, l: 0 });\n this.pie10 = this.pie10 || adjust(this.primaryColor, { h: 60, l: -20 });\n this.pie11 = this.pie11 || adjust(this.primaryColor, { h: -60, l: -20 });\n this.pie12 = this.pie12 || adjust(this.primaryColor, { h: 120, l: -10 });\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || (this.darkMode ? darken(this.secondaryColor, 30) : this.secondaryColor);\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = this.git0 || this.primaryColor;\n this.git1 = this.git1 || this.secondaryColor;\n this.git2 = this.git2 || this.tertiaryColor;\n this.git3 = this.git3 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.git4 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.git5 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.git6 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.git7 || adjust(this.primaryColor, { h: 120 });\n if (this.darkMode) {\n this.git0 = lighten(this.git0, 25);\n this.git1 = lighten(this.git1, 25);\n this.git2 = lighten(this.git2, 25);\n this.git3 = lighten(this.git3, 25);\n this.git4 = lighten(this.git4, 25);\n this.git5 = lighten(this.git5, 25);\n this.git6 = lighten(this.git6, 25);\n this.git7 = lighten(this.git7, 25);\n } else {\n this.git0 = darken(this.git0, 25);\n this.git1 = darken(this.git1, 25);\n this.git2 = darken(this.git2, 25);\n this.git3 = darken(this.git3, 25);\n this.git4 = darken(this.git4, 25);\n this.git5 = darken(this.git5, 25);\n this.git6 = darken(this.git6, 25);\n this.git7 = darken(this.git7, 25);\n }\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.branchLabelColor = this.branchLabelColor || (this.darkMode ? \"black\" : this.labelTextColor);\n this.gitBranchLabel0 = this.gitBranchLabel0 || this.branchLabelColor;\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.branchLabelColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.branchLabelColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || this.branchLabelColor;\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.branchLabelColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.branchLabelColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.branchLabelColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.branchLabelColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$4 = (userOverrides) => {\n const theme2 = new Theme$4();\n theme2.calculate(userOverrides);\n return theme2;\n};\nlet Theme$3 = class Theme2 {\n constructor() {\n this.background = \"#333\";\n this.primaryColor = \"#1f2020\";\n this.secondaryColor = lighten(this.primaryColor, 16);\n this.tertiaryColor = adjust(this.primaryColor, { h: -160 });\n this.primaryBorderColor = invert(this.background);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.tertiaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.mainBkg = \"#1f2020\";\n this.secondBkg = \"calculated\";\n this.mainContrastColor = \"lightgrey\";\n this.darkTextColor = lighten(invert(\"#323D47\"), 10);\n this.lineColor = \"calculated\";\n this.border1 = \"#81B1DB\";\n this.border2 = rgba(255, 255, 255, 0.25);\n this.arrowheadColor = \"calculated\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.labelBackground = \"#181818\";\n this.textColor = \"#ccc\";\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"#F9FFFE\";\n this.edgeLabelBackground = \"calculated\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"calculated\";\n this.actorLineColor = \"calculated\";\n this.signalColor = \"calculated\";\n this.signalTextColor = \"calculated\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"calculated\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"calculated\";\n this.activationBkgColor = \"calculated\";\n this.sequenceNumberColor = \"black\";\n this.sectionBkgColor = darken(\"#EAE8D9\", 30);\n this.altSectionBkgColor = \"calculated\";\n this.sectionBkgColor2 = \"#EAE8D9\";\n this.excludeBkgColor = darken(this.sectionBkgColor, 10);\n this.taskBorderColor = rgba(255, 255, 255, 70);\n this.taskBkgColor = \"calculated\";\n this.taskTextColor = \"calculated\";\n this.taskTextLightColor = \"calculated\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = rgba(255, 255, 255, 50);\n this.activeTaskBkgColor = \"#81B1DB\";\n this.gridColor = \"calculated\";\n this.doneTaskBkgColor = \"calculated\";\n this.doneTaskBorderColor = \"grey\";\n this.critBorderColor = \"#E83737\";\n this.critBkgColor = \"#E83737\";\n this.taskTextDarkColor = \"calculated\";\n this.todayLineColor = \"#DB5757\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"calculated\";\n this.errorBkgColor = \"#a44141\";\n this.errorTextColor = \"#ddd\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.secondBkg = lighten(this.mainBkg, 16);\n this.lineColor = this.mainContrastColor;\n this.arrowheadColor = this.mainContrastColor;\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.edgeLabelBackground = lighten(this.labelBackground, 25);\n this.actorBorder = this.border1;\n this.actorBkg = this.mainBkg;\n this.actorTextColor = this.mainContrastColor;\n this.actorLineColor = this.mainContrastColor;\n this.signalColor = this.mainContrastColor;\n this.signalTextColor = this.mainContrastColor;\n this.labelBoxBkgColor = this.actorBkg;\n this.labelBoxBorderColor = this.actorBorder;\n this.labelTextColor = this.mainContrastColor;\n this.loopTextColor = this.mainContrastColor;\n this.noteBorderColor = this.secondaryBorderColor;\n this.noteBkgColor = this.secondBkg;\n this.noteTextColor = this.secondaryTextColor;\n this.activationBorderColor = this.border1;\n this.activationBkgColor = this.secondBkg;\n this.altSectionBkgColor = this.background;\n this.taskBkgColor = lighten(this.mainBkg, 23);\n this.taskTextColor = this.darkTextColor;\n this.taskTextLightColor = this.mainContrastColor;\n this.taskTextOutsideColor = this.taskTextLightColor;\n this.gridColor = this.mainContrastColor;\n this.doneTaskBkgColor = this.mainContrastColor;\n this.taskTextDarkColor = this.darkTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#555\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.primaryBorderColor;\n this.specialStateColor = \"#f4f4f4\";\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n this.cScale1 = this.cScale1 || \"#0b0000\";\n this.cScale2 = this.cScale2 || \"#4d1037\";\n this.cScale3 = this.cScale3 || \"#3f5258\";\n this.cScale4 = this.cScale4 || \"#4f2f1b\";\n this.cScale5 = this.cScale5 || \"#6e0a0a\";\n this.cScale6 = this.cScale6 || \"#3b0048\";\n this.cScale7 = this.cScale7 || \"#995a01\";\n this.cScale8 = this.cScale8 || \"#154706\";\n this.cScale9 = this.cScale9 || \"#161722\";\n this.cScale10 = this.cScale10 || \"#00296f\";\n this.cScale11 = this.cScale11 || \"#01629c\";\n this.cScale12 = this.cScale12 || \"#010029\";\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || invert(this[\"cScale\" + i]);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || lighten(this[\"cScale\" + i], 10);\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(-10 + i * 4) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(-7 + i * 4) });\n }\n this.scaleLabelColor = this.scaleLabelColor || (this.darkMode ? \"black\" : this.labelTextColor);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"pie\" + i] = this[\"cScale\" + i];\n }\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22\"\n };\n this.classText = this.primaryTextColor;\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || (this.darkMode ? darken(this.secondaryColor, 30) : this.secondaryColor);\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = lighten(this.secondaryColor, 20);\n this.git1 = lighten(this.pie2 || this.secondaryColor, 20);\n this.git2 = lighten(this.pie3 || this.tertiaryColor, 20);\n this.git3 = lighten(this.pie4 || adjust(this.primaryColor, { h: -30 }), 20);\n this.git4 = lighten(this.pie5 || adjust(this.primaryColor, { h: -60 }), 20);\n this.git5 = lighten(this.pie6 || adjust(this.primaryColor, { h: -90 }), 10);\n this.git6 = lighten(this.pie7 || adjust(this.primaryColor, { h: 60 }), 10);\n this.git7 = lighten(this.pie8 || adjust(this.primaryColor, { h: 120 }), 20);\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.gitBranchLabel0 = this.gitBranchLabel0 || invert(this.labelTextColor);\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.labelTextColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.labelTextColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || invert(this.labelTextColor);\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.labelTextColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.labelTextColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.labelTextColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.labelTextColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || lighten(this.background, 12);\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || lighten(this.background, 2);\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$3 = (userOverrides) => {\n const theme2 = new Theme$3();\n theme2.calculate(userOverrides);\n return theme2;\n};\nlet Theme$2 = class Theme3 {\n constructor() {\n this.background = \"#f4f4f4\";\n this.primaryColor = \"#ECECFF\";\n this.secondaryColor = adjust(this.primaryColor, { h: 120 });\n this.secondaryColor = \"#ffffde\";\n this.tertiaryColor = adjust(this.primaryColor, { h: -160 });\n this.primaryBorderColor = mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.tertiaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.background = \"white\";\n this.mainBkg = \"#ECECFF\";\n this.secondBkg = \"#ffffde\";\n this.lineColor = \"#333333\";\n this.border1 = \"#9370DB\";\n this.border2 = \"#aaaa33\";\n this.arrowheadColor = \"#333333\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.labelBackground = \"#e8e8e8\";\n this.textColor = \"#333\";\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"calculated\";\n this.edgeLabelBackground = \"calculated\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"black\";\n this.actorLineColor = \"grey\";\n this.signalColor = \"calculated\";\n this.signalTextColor = \"calculated\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"calculated\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"#666\";\n this.activationBkgColor = \"#f4f4f4\";\n this.sequenceNumberColor = \"white\";\n this.sectionBkgColor = \"calculated\";\n this.altSectionBkgColor = \"calculated\";\n this.sectionBkgColor2 = \"calculated\";\n this.excludeBkgColor = \"#eeeeee\";\n this.taskBorderColor = \"calculated\";\n this.taskBkgColor = \"calculated\";\n this.taskTextLightColor = \"calculated\";\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextDarkColor = \"calculated\";\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.taskTextClickableColor = \"calculated\";\n this.activeTaskBorderColor = \"calculated\";\n this.activeTaskBkgColor = \"calculated\";\n this.gridColor = \"calculated\";\n this.doneTaskBkgColor = \"calculated\";\n this.doneTaskBorderColor = \"calculated\";\n this.critBorderColor = \"calculated\";\n this.critBkgColor = \"calculated\";\n this.todayLineColor = \"calculated\";\n this.sectionBkgColor = rgba(102, 102, 255, 0.49);\n this.altSectionBkgColor = \"white\";\n this.sectionBkgColor2 = \"#fff400\";\n this.taskBorderColor = \"#534fbc\";\n this.taskBkgColor = \"#8a90dd\";\n this.taskTextLightColor = \"white\";\n this.taskTextColor = \"calculated\";\n this.taskTextDarkColor = \"black\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = \"#534fbc\";\n this.activeTaskBkgColor = \"#bfc7ff\";\n this.gridColor = \"lightgrey\";\n this.doneTaskBkgColor = \"lightgrey\";\n this.doneTaskBorderColor = \"grey\";\n this.critBorderColor = \"#ff8888\";\n this.critBkgColor = \"red\";\n this.todayLineColor = \"red\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"black\";\n this.errorBkgColor = \"#552222\";\n this.errorTextColor = \"#552222\";\n this.updateColors();\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n this[\"cScalePeer1\"] = this[\"cScalePeer1\"] || darken(this.secondaryColor, 45);\n this[\"cScalePeer2\"] = this[\"cScalePeer2\"] || darken(this.tertiaryColor, 40);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 10);\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 25);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || adjust(this[\"cScale\" + i], { h: 180 });\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 30, l: -(5 + i * 5) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 30, l: -(7 + i * 5) });\n }\n this.scaleLabelColor = this.scaleLabelColor !== \"calculated\" && this.scaleLabelColor ? this.scaleLabelColor : this.labelTextColor;\n if (this.labelTextColor !== \"calculated\") {\n this.cScaleLabel0 = this.cScaleLabel0 || invert(this.labelTextColor);\n this.cScaleLabel3 = this.cScaleLabel3 || invert(this.labelTextColor);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.labelTextColor;\n }\n }\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.titleColor = this.textColor;\n this.edgeLabelBackground = this.labelBackground;\n this.actorBorder = lighten(this.border1, 23);\n this.actorBkg = this.mainBkg;\n this.labelBoxBkgColor = this.actorBkg;\n this.signalColor = this.textColor;\n this.signalTextColor = this.textColor;\n this.labelBoxBorderColor = this.actorBorder;\n this.labelTextColor = this.actorTextColor;\n this.loopTextColor = this.actorTextColor;\n this.noteBorderColor = this.border2;\n this.noteTextColor = this.actorTextColor;\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#f0f0f0\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.nodeBorder;\n this.specialStateColor = this.lineColor;\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.classText = this.primaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n this.pie1 = this.pie1 || this.primaryColor;\n this.pie2 = this.pie2 || this.secondaryColor;\n this.pie3 = this.pie3 || adjust(this.tertiaryColor, { l: -40 });\n this.pie4 = this.pie4 || adjust(this.primaryColor, { l: -10 });\n this.pie5 = this.pie5 || adjust(this.secondaryColor, { l: -30 });\n this.pie6 = this.pie6 || adjust(this.tertiaryColor, { l: -20 });\n this.pie7 = this.pie7 || adjust(this.primaryColor, { h: 60, l: -20 });\n this.pie8 = this.pie8 || adjust(this.primaryColor, { h: -60, l: -40 });\n this.pie9 = this.pie9 || adjust(this.primaryColor, { h: 120, l: -40 });\n this.pie10 = this.pie10 || adjust(this.primaryColor, { h: 60, l: -40 });\n this.pie11 = this.pie11 || adjust(this.primaryColor, { h: -90, l: -40 });\n this.pie12 = this.pie12 || adjust(this.primaryColor, { h: 120, l: -30 });\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || this.labelBackground;\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = this.git0 || this.primaryColor;\n this.git1 = this.git1 || this.secondaryColor;\n this.git2 = this.git2 || this.tertiaryColor;\n this.git3 = this.git3 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.git4 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.git5 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.git6 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.git7 || adjust(this.primaryColor, { h: 120 });\n if (this.darkMode) {\n this.git0 = lighten(this.git0, 25);\n this.git1 = lighten(this.git1, 25);\n this.git2 = lighten(this.git2, 25);\n this.git3 = lighten(this.git3, 25);\n this.git4 = lighten(this.git4, 25);\n this.git5 = lighten(this.git5, 25);\n this.git6 = lighten(this.git6, 25);\n this.git7 = lighten(this.git7, 25);\n } else {\n this.git0 = darken(this.git0, 25);\n this.git1 = darken(this.git1, 25);\n this.git2 = darken(this.git2, 25);\n this.git3 = darken(this.git3, 25);\n this.git4 = darken(this.git4, 25);\n this.git5 = darken(this.git5, 25);\n this.git6 = darken(this.git6, 25);\n this.git7 = darken(this.git7, 25);\n }\n this.gitInv0 = this.gitInv0 || darken(invert(this.git0), 25);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.gitBranchLabel0 = this.gitBranchLabel0 || invert(this.labelTextColor);\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.labelTextColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.labelTextColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || invert(this.labelTextColor);\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.labelTextColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.labelTextColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.labelTextColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.labelTextColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$2 = (userOverrides) => {\n const theme2 = new Theme$2();\n theme2.calculate(userOverrides);\n return theme2;\n};\nlet Theme$1 = class Theme4 {\n constructor() {\n this.background = \"#f4f4f4\";\n this.primaryColor = \"#cde498\";\n this.secondaryColor = \"#cdffb2\";\n this.background = \"white\";\n this.mainBkg = \"#cde498\";\n this.secondBkg = \"#cdffb2\";\n this.lineColor = \"green\";\n this.border1 = \"#13540c\";\n this.border2 = \"#6eaa49\";\n this.arrowheadColor = \"green\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.tertiaryColor = lighten(\"#cde498\", 10);\n this.primaryBorderColor = mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.primaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"#333\";\n this.edgeLabelBackground = \"#e8e8e8\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"black\";\n this.actorLineColor = \"grey\";\n this.signalColor = \"#333\";\n this.signalTextColor = \"#333\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"#326932\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"#fff5ad\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"#666\";\n this.activationBkgColor = \"#f4f4f4\";\n this.sequenceNumberColor = \"white\";\n this.sectionBkgColor = \"#6eaa49\";\n this.altSectionBkgColor = \"white\";\n this.sectionBkgColor2 = \"#6eaa49\";\n this.excludeBkgColor = \"#eeeeee\";\n this.taskBorderColor = \"calculated\";\n this.taskBkgColor = \"#487e3a\";\n this.taskTextLightColor = \"white\";\n this.taskTextColor = \"calculated\";\n this.taskTextDarkColor = \"black\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = \"calculated\";\n this.activeTaskBkgColor = \"calculated\";\n this.gridColor = \"lightgrey\";\n this.doneTaskBkgColor = \"lightgrey\";\n this.doneTaskBorderColor = \"grey\";\n this.critBorderColor = \"#ff8888\";\n this.critBkgColor = \"red\";\n this.todayLineColor = \"red\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"black\";\n this.errorBkgColor = \"#552222\";\n this.errorTextColor = \"#552222\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.actorBorder = darken(this.mainBkg, 20);\n this.actorBkg = this.mainBkg;\n this.labelBoxBkgColor = this.actorBkg;\n this.labelTextColor = this.actorTextColor;\n this.loopTextColor = this.actorTextColor;\n this.noteBorderColor = this.border2;\n this.noteTextColor = this.actorTextColor;\n this.cScale0 = this.cScale0 || this.primaryColor;\n this.cScale1 = this.cScale1 || this.secondaryColor;\n this.cScale2 = this.cScale2 || this.tertiaryColor;\n this.cScale3 = this.cScale3 || adjust(this.primaryColor, { h: 30 });\n this.cScale4 = this.cScale4 || adjust(this.primaryColor, { h: 60 });\n this.cScale5 = this.cScale5 || adjust(this.primaryColor, { h: 90 });\n this.cScale6 = this.cScale6 || adjust(this.primaryColor, { h: 120 });\n this.cScale7 = this.cScale7 || adjust(this.primaryColor, { h: 150 });\n this.cScale8 = this.cScale8 || adjust(this.primaryColor, { h: 210 });\n this.cScale9 = this.cScale9 || adjust(this.primaryColor, { h: 270 });\n this.cScale10 = this.cScale10 || adjust(this.primaryColor, { h: 300 });\n this.cScale11 = this.cScale11 || adjust(this.primaryColor, { h: 330 });\n this[\"cScalePeer1\"] = this[\"cScalePeer1\"] || darken(this.secondaryColor, 45);\n this[\"cScalePeer2\"] = this[\"cScalePeer2\"] || darken(this.tertiaryColor, 40);\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScale\" + i] = darken(this[\"cScale\" + i], 10);\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 25);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || adjust(this[\"cScale\" + i], { h: 180 });\n }\n this.scaleLabelColor = this.scaleLabelColor !== \"calculated\" && this.scaleLabelColor ? this.scaleLabelColor : this.labelTextColor;\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(5 + i * 5) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { h: 30, s: -30, l: -(8 + i * 5) });\n }\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.taskBorderColor = this.border1;\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.activeTaskBorderColor = this.taskBorderColor;\n this.activeTaskBkgColor = this.mainBkg;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#f0f0f0\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.compositeBorder = this.compositeBorder || this.nodeBorder;\n this.innerEndBackground = this.primaryBorderColor;\n this.specialStateColor = this.lineColor;\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.transitionColor = this.transitionColor || this.lineColor;\n this.classText = this.primaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n this.pie1 = this.pie1 || this.primaryColor;\n this.pie2 = this.pie2 || this.secondaryColor;\n this.pie3 = this.pie3 || this.tertiaryColor;\n this.pie4 = this.pie4 || adjust(this.primaryColor, { l: -30 });\n this.pie5 = this.pie5 || adjust(this.secondaryColor, { l: -30 });\n this.pie6 = this.pie6 || adjust(this.tertiaryColor, { h: 40, l: -40 });\n this.pie7 = this.pie7 || adjust(this.primaryColor, { h: 60, l: -10 });\n this.pie8 = this.pie8 || adjust(this.primaryColor, { h: -60, l: -10 });\n this.pie9 = this.pie9 || adjust(this.primaryColor, { h: 120, l: 0 });\n this.pie10 = this.pie10 || adjust(this.primaryColor, { h: 60, l: -50 });\n this.pie11 = this.pie11 || adjust(this.primaryColor, { h: -60, l: -50 });\n this.pie12 = this.pie12 || adjust(this.primaryColor, { h: 120, l: -50 });\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || this.edgeLabelBackground;\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = this.git0 || this.primaryColor;\n this.git1 = this.git1 || this.secondaryColor;\n this.git2 = this.git2 || this.tertiaryColor;\n this.git3 = this.git3 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.git4 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.git5 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.git6 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.git7 || adjust(this.primaryColor, { h: 120 });\n if (this.darkMode) {\n this.git0 = lighten(this.git0, 25);\n this.git1 = lighten(this.git1, 25);\n this.git2 = lighten(this.git2, 25);\n this.git3 = lighten(this.git3, 25);\n this.git4 = lighten(this.git4, 25);\n this.git5 = lighten(this.git5, 25);\n this.git6 = lighten(this.git6, 25);\n this.git7 = lighten(this.git7, 25);\n } else {\n this.git0 = darken(this.git0, 25);\n this.git1 = darken(this.git1, 25);\n this.git2 = darken(this.git2, 25);\n this.git3 = darken(this.git3, 25);\n this.git4 = darken(this.git4, 25);\n this.git5 = darken(this.git5, 25);\n this.git6 = darken(this.git6, 25);\n this.git7 = darken(this.git7, 25);\n }\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.gitBranchLabel0 = this.gitBranchLabel0 || invert(this.labelTextColor);\n this.gitBranchLabel1 = this.gitBranchLabel1 || this.labelTextColor;\n this.gitBranchLabel2 = this.gitBranchLabel2 || this.labelTextColor;\n this.gitBranchLabel3 = this.gitBranchLabel3 || invert(this.labelTextColor);\n this.gitBranchLabel4 = this.gitBranchLabel4 || this.labelTextColor;\n this.gitBranchLabel5 = this.gitBranchLabel5 || this.labelTextColor;\n this.gitBranchLabel6 = this.gitBranchLabel6 || this.labelTextColor;\n this.gitBranchLabel7 = this.gitBranchLabel7 || this.labelTextColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n};\nconst getThemeVariables$1 = (userOverrides) => {\n const theme2 = new Theme$1();\n theme2.calculate(userOverrides);\n return theme2;\n};\nclass Theme5 {\n constructor() {\n this.primaryColor = \"#eee\";\n this.contrast = \"#707070\";\n this.secondaryColor = lighten(this.contrast, 55);\n this.background = \"#ffffff\";\n this.tertiaryColor = adjust(this.primaryColor, { h: -160 });\n this.primaryBorderColor = mkBorder(this.primaryColor, this.darkMode);\n this.secondaryBorderColor = mkBorder(this.secondaryColor, this.darkMode);\n this.tertiaryBorderColor = mkBorder(this.tertiaryColor, this.darkMode);\n this.primaryTextColor = invert(this.primaryColor);\n this.secondaryTextColor = invert(this.secondaryColor);\n this.tertiaryTextColor = invert(this.tertiaryColor);\n this.lineColor = invert(this.background);\n this.textColor = invert(this.background);\n this.mainBkg = \"#eee\";\n this.secondBkg = \"calculated\";\n this.lineColor = \"#666\";\n this.border1 = \"#999\";\n this.border2 = \"calculated\";\n this.note = \"#ffa\";\n this.text = \"#333\";\n this.critical = \"#d42\";\n this.done = \"#bbb\";\n this.arrowheadColor = \"#333333\";\n this.fontFamily = '\"trebuchet ms\", verdana, arial, sans-serif';\n this.fontSize = \"16px\";\n this.THEME_COLOR_LIMIT = 12;\n this.nodeBkg = \"calculated\";\n this.nodeBorder = \"calculated\";\n this.clusterBkg = \"calculated\";\n this.clusterBorder = \"calculated\";\n this.defaultLinkColor = \"calculated\";\n this.titleColor = \"calculated\";\n this.edgeLabelBackground = \"white\";\n this.actorBorder = \"calculated\";\n this.actorBkg = \"calculated\";\n this.actorTextColor = \"calculated\";\n this.actorLineColor = \"calculated\";\n this.signalColor = \"calculated\";\n this.signalTextColor = \"calculated\";\n this.labelBoxBkgColor = \"calculated\";\n this.labelBoxBorderColor = \"calculated\";\n this.labelTextColor = \"calculated\";\n this.loopTextColor = \"calculated\";\n this.noteBorderColor = \"calculated\";\n this.noteBkgColor = \"calculated\";\n this.noteTextColor = \"calculated\";\n this.activationBorderColor = \"#666\";\n this.activationBkgColor = \"#f4f4f4\";\n this.sequenceNumberColor = \"white\";\n this.sectionBkgColor = \"calculated\";\n this.altSectionBkgColor = \"white\";\n this.sectionBkgColor2 = \"calculated\";\n this.excludeBkgColor = \"#eeeeee\";\n this.taskBorderColor = \"calculated\";\n this.taskBkgColor = \"calculated\";\n this.taskTextLightColor = \"white\";\n this.taskTextColor = \"calculated\";\n this.taskTextDarkColor = \"calculated\";\n this.taskTextOutsideColor = \"calculated\";\n this.taskTextClickableColor = \"#003163\";\n this.activeTaskBorderColor = \"calculated\";\n this.activeTaskBkgColor = \"calculated\";\n this.gridColor = \"calculated\";\n this.doneTaskBkgColor = \"calculated\";\n this.doneTaskBorderColor = \"calculated\";\n this.critBkgColor = \"calculated\";\n this.critBorderColor = \"calculated\";\n this.todayLineColor = \"calculated\";\n this.personBorder = this.primaryBorderColor;\n this.personBkg = this.mainBkg;\n this.labelColor = \"black\";\n this.errorBkgColor = \"#552222\";\n this.errorTextColor = \"#552222\";\n }\n updateColors() {\n var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;\n this.secondBkg = lighten(this.contrast, 55);\n this.border2 = this.contrast;\n this.actorBorder = lighten(this.border1, 23);\n this.actorBkg = this.mainBkg;\n this.actorTextColor = this.text;\n this.actorLineColor = this.lineColor;\n this.signalColor = this.text;\n this.signalTextColor = this.text;\n this.labelBoxBkgColor = this.actorBkg;\n this.labelBoxBorderColor = this.actorBorder;\n this.labelTextColor = this.text;\n this.loopTextColor = this.text;\n this.noteBorderColor = \"#999\";\n this.noteBkgColor = \"#666\";\n this.noteTextColor = \"#fff\";\n this.cScale0 = this.cScale0 || \"#555\";\n this.cScale1 = this.cScale1 || \"#F4F4F4\";\n this.cScale2 = this.cScale2 || \"#555\";\n this.cScale3 = this.cScale3 || \"#BBB\";\n this.cScale4 = this.cScale4 || \"#777\";\n this.cScale5 = this.cScale5 || \"#999\";\n this.cScale6 = this.cScale6 || \"#DDD\";\n this.cScale7 = this.cScale7 || \"#FFF\";\n this.cScale8 = this.cScale8 || \"#DDD\";\n this.cScale9 = this.cScale9 || \"#BBB\";\n this.cScale10 = this.cScale10 || \"#999\";\n this.cScale11 = this.cScale11 || \"#777\";\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleInv\" + i] = this[\"cScaleInv\" + i] || invert(this[\"cScale\" + i]);\n }\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n if (this.darkMode) {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || lighten(this[\"cScale\" + i], 10);\n } else {\n this[\"cScalePeer\" + i] = this[\"cScalePeer\" + i] || darken(this[\"cScale\" + i], 10);\n }\n }\n this.scaleLabelColor = this.scaleLabelColor || (this.darkMode ? \"black\" : this.labelTextColor);\n this[\"cScaleLabel0\"] = this[\"cScaleLabel0\"] || this.cScale1;\n this[\"cScaleLabel2\"] = this[\"cScaleLabel2\"] || this.cScale1;\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"cScaleLabel\" + i] = this[\"cScaleLabel\" + i] || this.scaleLabelColor;\n }\n for (let i = 0; i < 5; i++) {\n this[\"surface\" + i] = this[\"surface\" + i] || adjust(this.mainBkg, { l: -(5 + i * 5) });\n this[\"surfacePeer\" + i] = this[\"surfacePeer\" + i] || adjust(this.mainBkg, { l: -(8 + i * 5) });\n }\n this.nodeBkg = this.mainBkg;\n this.nodeBorder = this.border1;\n this.clusterBkg = this.secondBkg;\n this.clusterBorder = this.border2;\n this.defaultLinkColor = this.lineColor;\n this.titleColor = this.text;\n this.sectionBkgColor = lighten(this.contrast, 30);\n this.sectionBkgColor2 = lighten(this.contrast, 30);\n this.taskBorderColor = darken(this.contrast, 10);\n this.taskBkgColor = this.contrast;\n this.taskTextColor = this.taskTextLightColor;\n this.taskTextDarkColor = this.text;\n this.taskTextOutsideColor = this.taskTextDarkColor;\n this.activeTaskBorderColor = this.taskBorderColor;\n this.activeTaskBkgColor = this.mainBkg;\n this.gridColor = lighten(this.border1, 30);\n this.doneTaskBkgColor = this.done;\n this.doneTaskBorderColor = this.lineColor;\n this.critBkgColor = this.critical;\n this.critBorderColor = darken(this.critBkgColor, 10);\n this.todayLineColor = this.critBkgColor;\n this.transitionColor = this.transitionColor || \"#000\";\n this.transitionLabelColor = this.transitionLabelColor || this.textColor;\n this.stateLabelColor = this.stateLabelColor || this.stateBkg || this.primaryTextColor;\n this.stateBkg = this.stateBkg || this.mainBkg;\n this.labelBackgroundColor = this.labelBackgroundColor || this.stateBkg;\n this.compositeBackground = this.compositeBackground || this.background || this.tertiaryColor;\n this.altBackground = this.altBackground || \"#f4f4f4\";\n this.compositeTitleBackground = this.compositeTitleBackground || this.mainBkg;\n this.stateBorder = this.stateBorder || \"#000\";\n this.innerEndBackground = this.primaryBorderColor;\n this.specialStateColor = \"#222\";\n this.errorBkgColor = this.errorBkgColor || this.tertiaryColor;\n this.errorTextColor = this.errorTextColor || this.tertiaryTextColor;\n this.classText = this.primaryTextColor;\n this.fillType0 = this.primaryColor;\n this.fillType1 = this.secondaryColor;\n this.fillType2 = adjust(this.primaryColor, { h: 64 });\n this.fillType3 = adjust(this.secondaryColor, { h: 64 });\n this.fillType4 = adjust(this.primaryColor, { h: -64 });\n this.fillType5 = adjust(this.secondaryColor, { h: -64 });\n this.fillType6 = adjust(this.primaryColor, { h: 128 });\n this.fillType7 = adjust(this.secondaryColor, { h: 128 });\n for (let i = 0; i < this.THEME_COLOR_LIMIT; i++) {\n this[\"pie\" + i] = this[\"cScale\" + i];\n }\n this.pie12 = this.pie0;\n this.pieTitleTextSize = this.pieTitleTextSize || \"25px\";\n this.pieTitleTextColor = this.pieTitleTextColor || this.taskTextDarkColor;\n this.pieSectionTextSize = this.pieSectionTextSize || \"17px\";\n this.pieSectionTextColor = this.pieSectionTextColor || this.textColor;\n this.pieLegendTextSize = this.pieLegendTextSize || \"17px\";\n this.pieLegendTextColor = this.pieLegendTextColor || this.taskTextDarkColor;\n this.pieStrokeColor = this.pieStrokeColor || \"black\";\n this.pieStrokeWidth = this.pieStrokeWidth || \"2px\";\n this.pieOuterStrokeWidth = this.pieOuterStrokeWidth || \"2px\";\n this.pieOuterStrokeColor = this.pieOuterStrokeColor || \"black\";\n this.pieOpacity = this.pieOpacity || \"0.7\";\n this.quadrant1Fill = this.quadrant1Fill || this.primaryColor;\n this.quadrant2Fill = this.quadrant2Fill || adjust(this.primaryColor, { r: 5, g: 5, b: 5 });\n this.quadrant3Fill = this.quadrant3Fill || adjust(this.primaryColor, { r: 10, g: 10, b: 10 });\n this.quadrant4Fill = this.quadrant4Fill || adjust(this.primaryColor, { r: 15, g: 15, b: 15 });\n this.quadrant1TextFill = this.quadrant1TextFill || this.primaryTextColor;\n this.quadrant2TextFill = this.quadrant2TextFill || adjust(this.primaryTextColor, { r: -5, g: -5, b: -5 });\n this.quadrant3TextFill = this.quadrant3TextFill || adjust(this.primaryTextColor, { r: -10, g: -10, b: -10 });\n this.quadrant4TextFill = this.quadrant4TextFill || adjust(this.primaryTextColor, { r: -15, g: -15, b: -15 });\n this.quadrantPointFill = this.quadrantPointFill || isDark(this.quadrant1Fill) ? lighten(this.quadrant1Fill) : darken(this.quadrant1Fill);\n this.quadrantPointTextFill = this.quadrantPointTextFill || this.primaryTextColor;\n this.quadrantXAxisTextFill = this.quadrantXAxisTextFill || this.primaryTextColor;\n this.quadrantYAxisTextFill = this.quadrantYAxisTextFill || this.primaryTextColor;\n this.quadrantInternalBorderStrokeFill = this.quadrantInternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantExternalBorderStrokeFill = this.quadrantExternalBorderStrokeFill || this.primaryBorderColor;\n this.quadrantTitleFill = this.quadrantTitleFill || this.primaryTextColor;\n this.xyChart = {\n backgroundColor: ((_a = this.xyChart) == null ? void 0 : _a.backgroundColor) || this.background,\n titleColor: ((_b = this.xyChart) == null ? void 0 : _b.titleColor) || this.primaryTextColor,\n xAxisTitleColor: ((_c = this.xyChart) == null ? void 0 : _c.xAxisTitleColor) || this.primaryTextColor,\n xAxisLabelColor: ((_d = this.xyChart) == null ? void 0 : _d.xAxisLabelColor) || this.primaryTextColor,\n xAxisTickColor: ((_e = this.xyChart) == null ? void 0 : _e.xAxisTickColor) || this.primaryTextColor,\n xAxisLineColor: ((_f = this.xyChart) == null ? void 0 : _f.xAxisLineColor) || this.primaryTextColor,\n yAxisTitleColor: ((_g = this.xyChart) == null ? void 0 : _g.yAxisTitleColor) || this.primaryTextColor,\n yAxisLabelColor: ((_h = this.xyChart) == null ? void 0 : _h.yAxisLabelColor) || this.primaryTextColor,\n yAxisTickColor: ((_i = this.xyChart) == null ? void 0 : _i.yAxisTickColor) || this.primaryTextColor,\n yAxisLineColor: ((_j = this.xyChart) == null ? void 0 : _j.yAxisLineColor) || this.primaryTextColor,\n plotColorPalette: ((_k = this.xyChart) == null ? void 0 : _k.plotColorPalette) || \"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0\"\n };\n this.requirementBackground = this.requirementBackground || this.primaryColor;\n this.requirementBorderColor = this.requirementBorderColor || this.primaryBorderColor;\n this.requirementBorderSize = this.requirementBorderSize || \"1\";\n this.requirementTextColor = this.requirementTextColor || this.primaryTextColor;\n this.relationColor = this.relationColor || this.lineColor;\n this.relationLabelBackground = this.relationLabelBackground || this.edgeLabelBackground;\n this.relationLabelColor = this.relationLabelColor || this.actorTextColor;\n this.git0 = darken(this.pie1, 25) || this.primaryColor;\n this.git1 = this.pie2 || this.secondaryColor;\n this.git2 = this.pie3 || this.tertiaryColor;\n this.git3 = this.pie4 || adjust(this.primaryColor, { h: -30 });\n this.git4 = this.pie5 || adjust(this.primaryColor, { h: -60 });\n this.git5 = this.pie6 || adjust(this.primaryColor, { h: -90 });\n this.git6 = this.pie7 || adjust(this.primaryColor, { h: 60 });\n this.git7 = this.pie8 || adjust(this.primaryColor, { h: 120 });\n this.gitInv0 = this.gitInv0 || invert(this.git0);\n this.gitInv1 = this.gitInv1 || invert(this.git1);\n this.gitInv2 = this.gitInv2 || invert(this.git2);\n this.gitInv3 = this.gitInv3 || invert(this.git3);\n this.gitInv4 = this.gitInv4 || invert(this.git4);\n this.gitInv5 = this.gitInv5 || invert(this.git5);\n this.gitInv6 = this.gitInv6 || invert(this.git6);\n this.gitInv7 = this.gitInv7 || invert(this.git7);\n this.branchLabelColor = this.branchLabelColor || this.labelTextColor;\n this.gitBranchLabel0 = this.branchLabelColor;\n this.gitBranchLabel1 = \"white\";\n this.gitBranchLabel2 = this.branchLabelColor;\n this.gitBranchLabel3 = \"white\";\n this.gitBranchLabel4 = this.branchLabelColor;\n this.gitBranchLabel5 = this.branchLabelColor;\n this.gitBranchLabel6 = this.branchLabelColor;\n this.gitBranchLabel7 = this.branchLabelColor;\n this.tagLabelColor = this.tagLabelColor || this.primaryTextColor;\n this.tagLabelBackground = this.tagLabelBackground || this.primaryColor;\n this.tagLabelBorder = this.tagBorder || this.primaryBorderColor;\n this.tagLabelFontSize = this.tagLabelFontSize || \"10px\";\n this.commitLabelColor = this.commitLabelColor || this.secondaryTextColor;\n this.commitLabelBackground = this.commitLabelBackground || this.secondaryColor;\n this.commitLabelFontSize = this.commitLabelFontSize || \"10px\";\n this.attributeBackgroundColorOdd = this.attributeBackgroundColorOdd || oldAttributeBackgroundColorOdd;\n this.attributeBackgroundColorEven = this.attributeBackgroundColorEven || oldAttributeBackgroundColorEven;\n }\n calculate(overrides) {\n if (typeof overrides !== \"object\") {\n this.updateColors();\n return;\n }\n const keys = Object.keys(overrides);\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n this.updateColors();\n keys.forEach((k) => {\n this[k] = overrides[k];\n });\n }\n}\nconst getThemeVariables = (userOverrides) => {\n const theme2 = new Theme5();\n theme2.calculate(userOverrides);\n return theme2;\n};\nconst theme = {\n base: {\n getThemeVariables: getThemeVariables$4\n },\n dark: {\n getThemeVariables: getThemeVariables$3\n },\n default: {\n getThemeVariables: getThemeVariables$2\n },\n forest: {\n getThemeVariables: getThemeVariables$1\n },\n neutral: {\n getThemeVariables\n }\n};\nconst defaultConfigJson = {\n \"flowchart\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"diagramPadding\": 8,\n \"htmlLabels\": true,\n \"nodeSpacing\": 50,\n \"rankSpacing\": 50,\n \"curve\": \"basis\",\n \"padding\": 15,\n \"defaultRenderer\": \"dagre-wrapper\",\n \"wrappingWidth\": 200\n },\n \"sequence\": {\n \"useMaxWidth\": true,\n \"hideUnusedParticipants\": false,\n \"activationWidth\": 10,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"actorMargin\": 50,\n \"width\": 150,\n \"height\": 65,\n \"boxMargin\": 10,\n \"boxTextMargin\": 5,\n \"noteMargin\": 10,\n \"messageMargin\": 35,\n \"messageAlign\": \"center\",\n \"mirrorActors\": true,\n \"forceMenus\": false,\n \"bottomMarginAdj\": 1,\n \"rightAngles\": false,\n \"showSequenceNumbers\": false,\n \"actorFontSize\": 14,\n \"actorFontFamily\": '\"Open Sans\", sans-serif',\n \"actorFontWeight\": 400,\n \"noteFontSize\": 14,\n \"noteFontFamily\": '\"trebuchet ms\", verdana, arial, sans-serif',\n \"noteFontWeight\": 400,\n \"noteAlign\": \"center\",\n \"messageFontSize\": 16,\n \"messageFontFamily\": '\"trebuchet ms\", verdana, arial, sans-serif',\n \"messageFontWeight\": 400,\n \"wrap\": false,\n \"wrapPadding\": 10,\n \"labelBoxWidth\": 50,\n \"labelBoxHeight\": 20\n },\n \"gantt\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"barHeight\": 20,\n \"barGap\": 4,\n \"topPadding\": 50,\n \"rightPadding\": 75,\n \"leftPadding\": 75,\n \"gridLineStartPadding\": 35,\n \"fontSize\": 11,\n \"sectionFontSize\": 11,\n \"numberSectionStyles\": 4,\n \"axisFormat\": \"%Y-%m-%d\",\n \"topAxis\": false,\n \"displayMode\": \"\",\n \"weekday\": \"sunday\"\n },\n \"journey\": {\n \"useMaxWidth\": true,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"leftMargin\": 150,\n \"width\": 150,\n \"height\": 50,\n \"boxMargin\": 10,\n \"boxTextMargin\": 5,\n \"noteMargin\": 10,\n \"messageMargin\": 35,\n \"messageAlign\": \"center\",\n \"bottomMarginAdj\": 1,\n \"rightAngles\": false,\n \"taskFontSize\": 14,\n \"taskFontFamily\": '\"Open Sans\", sans-serif',\n \"taskMargin\": 50,\n \"activationWidth\": 10,\n \"textPlacement\": \"fo\",\n \"actorColours\": [\n \"#8FBC8F\",\n \"#7CFC00\",\n \"#00FFFF\",\n \"#20B2AA\",\n \"#B0E0E6\",\n \"#FFFFE0\"\n ],\n \"sectionFills\": [\n \"#191970\",\n \"#8B008B\",\n \"#4B0082\",\n \"#2F4F4F\",\n \"#800000\",\n \"#8B4513\",\n \"#00008B\"\n ],\n \"sectionColours\": [\n \"#fff\"\n ]\n },\n \"class\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"arrowMarkerAbsolute\": false,\n \"dividerMargin\": 10,\n \"padding\": 5,\n \"textHeight\": 10,\n \"defaultRenderer\": \"dagre-wrapper\",\n \"htmlLabels\": false\n },\n \"state\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"dividerMargin\": 10,\n \"sizeUnit\": 5,\n \"padding\": 8,\n \"textHeight\": 10,\n \"titleShift\": -15,\n \"noteMargin\": 10,\n \"forkWidth\": 70,\n \"forkHeight\": 7,\n \"miniPadding\": 2,\n \"fontSizeFactor\": 5.02,\n \"fontSize\": 24,\n \"labelHeight\": 16,\n \"edgeLengthFactor\": \"20\",\n \"compositTitleSize\": 35,\n \"radius\": 5,\n \"defaultRenderer\": \"dagre-wrapper\"\n },\n \"er\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"diagramPadding\": 20,\n \"layoutDirection\": \"TB\",\n \"minEntityWidth\": 100,\n \"minEntityHeight\": 75,\n \"entityPadding\": 15,\n \"stroke\": \"gray\",\n \"fill\": \"honeydew\",\n \"fontSize\": 12\n },\n \"pie\": {\n \"useMaxWidth\": true,\n \"textPosition\": 0.75\n },\n \"quadrantChart\": {\n \"useMaxWidth\": true,\n \"chartWidth\": 500,\n \"chartHeight\": 500,\n \"titleFontSize\": 20,\n \"titlePadding\": 10,\n \"quadrantPadding\": 5,\n \"xAxisLabelPadding\": 5,\n \"yAxisLabelPadding\": 5,\n \"xAxisLabelFontSize\": 16,\n \"yAxisLabelFontSize\": 16,\n \"quadrantLabelFontSize\": 16,\n \"quadrantTextTopPadding\": 5,\n \"pointTextPadding\": 5,\n \"pointLabelFontSize\": 12,\n \"pointRadius\": 5,\n \"xAxisPosition\": \"top\",\n \"yAxisPosition\": \"left\",\n \"quadrantInternalBorderStrokeWidth\": 1,\n \"quadrantExternalBorderStrokeWidth\": 2\n },\n \"xyChart\": {\n \"useMaxWidth\": true,\n \"width\": 700,\n \"height\": 500,\n \"titleFontSize\": 20,\n \"titlePadding\": 10,\n \"showTitle\": true,\n \"xAxis\": {\n \"$ref\": \"#/$defs/XYChartAxisConfig\",\n \"showLabel\": true,\n \"labelFontSize\": 14,\n \"labelPadding\": 5,\n \"showTitle\": true,\n \"titleFontSize\": 16,\n \"titlePadding\": 5,\n \"showTick\": true,\n \"tickLength\": 5,\n \"tickWidth\": 2,\n \"showAxisLine\": true,\n \"axisLineWidth\": 2\n },\n \"yAxis\": {\n \"$ref\": \"#/$defs/XYChartAxisConfig\",\n \"showLabel\": true,\n \"labelFontSize\": 14,\n \"labelPadding\": 5,\n \"showTitle\": true,\n \"titleFontSize\": 16,\n \"titlePadding\": 5,\n \"showTick\": true,\n \"tickLength\": 5,\n \"tickWidth\": 2,\n \"showAxisLine\": true,\n \"axisLineWidth\": 2\n },\n \"chartOrientation\": \"vertical\",\n \"plotReservedSpacePercent\": 50\n },\n \"requirement\": {\n \"useMaxWidth\": true,\n \"rect_fill\": \"#f9f9f9\",\n \"text_color\": \"#333\",\n \"rect_border_size\": \"0.5px\",\n \"rect_border_color\": \"#bbb\",\n \"rect_min_width\": 200,\n \"rect_min_height\": 200,\n \"fontSize\": 14,\n \"rect_padding\": 10,\n \"line_height\": 20\n },\n \"mindmap\": {\n \"useMaxWidth\": true,\n \"padding\": 10,\n \"maxNodeWidth\": 200\n },\n \"timeline\": {\n \"useMaxWidth\": true,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"leftMargin\": 150,\n \"width\": 150,\n \"height\": 50,\n \"boxMargin\": 10,\n \"boxTextMargin\": 5,\n \"noteMargin\": 10,\n \"messageMargin\": 35,\n \"messageAlign\": \"center\",\n \"bottomMarginAdj\": 1,\n \"rightAngles\": false,\n \"taskFontSize\": 14,\n \"taskFontFamily\": '\"Open Sans\", sans-serif',\n \"taskMargin\": 50,\n \"activationWidth\": 10,\n \"textPlacement\": \"fo\",\n \"actorColours\": [\n \"#8FBC8F\",\n \"#7CFC00\",\n \"#00FFFF\",\n \"#20B2AA\",\n \"#B0E0E6\",\n \"#FFFFE0\"\n ],\n \"sectionFills\": [\n \"#191970\",\n \"#8B008B\",\n \"#4B0082\",\n \"#2F4F4F\",\n \"#800000\",\n \"#8B4513\",\n \"#00008B\"\n ],\n \"sectionColours\": [\n \"#fff\"\n ],\n \"disableMulticolor\": false\n },\n \"gitGraph\": {\n \"useMaxWidth\": true,\n \"titleTopMargin\": 25,\n \"diagramPadding\": 8,\n \"nodeLabel\": {\n \"width\": 75,\n \"height\": 100,\n \"x\": -25,\n \"y\": 0\n },\n \"mainBranchName\": \"main\",\n \"mainBranchOrder\": 0,\n \"showCommitLabel\": true,\n \"showBranches\": true,\n \"rotateCommitLabel\": true,\n \"arrowMarkerAbsolute\": false\n },\n \"c4\": {\n \"useMaxWidth\": true,\n \"diagramMarginX\": 50,\n \"diagramMarginY\": 10,\n \"c4ShapeMargin\": 50,\n \"c4ShapePadding\": 20,\n \"width\": 216,\n \"height\": 60,\n \"boxMargin\": 10,\n \"c4ShapeInRow\": 4,\n \"nextLinePaddingX\": 0,\n \"c4BoundaryInRow\": 2,\n \"personFontSize\": 14,\n \"personFontFamily\": '\"Open Sans\", sans-serif',\n \"personFontWeight\": \"normal\",\n \"external_personFontSize\": 14,\n \"external_personFontFamily\": '\"Open Sans\", sans-serif',\n \"external_personFontWeight\": \"normal\",\n \"systemFontSize\": 14,\n \"systemFontFamily\": '\"Open Sans\", sans-serif',\n \"systemFontWeight\": \"normal\",\n \"external_systemFontSize\": 14,\n \"external_systemFontFamily\": '\"Open Sans\", sans-serif',\n \"external_systemFontWeight\": \"normal\",\n \"system_dbFontSize\": 14,\n \"system_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"system_dbFontWeight\": \"normal\",\n \"external_system_dbFontSize\": 14,\n \"external_system_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"external_system_dbFontWeight\": \"normal\",\n \"system_queueFontSize\": 14,\n \"system_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"system_queueFontWeight\": \"normal\",\n \"external_system_queueFontSize\": 14,\n \"external_system_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"external_system_queueFontWeight\": \"normal\",\n \"boundaryFontSize\": 14,\n \"boundaryFontFamily\": '\"Open Sans\", sans-serif',\n \"boundaryFontWeight\": \"normal\",\n \"messageFontSize\": 12,\n \"messageFontFamily\": '\"Open Sans\", sans-serif',\n \"messageFontWeight\": \"normal\",\n \"containerFontSize\": 14,\n \"containerFontFamily\": '\"Open Sans\", sans-serif',\n \"containerFontWeight\": \"normal\",\n \"external_containerFontSize\": 14,\n \"external_containerFontFamily\": '\"Open Sans\", sans-serif',\n \"external_containerFontWeight\": \"normal\",\n \"container_dbFontSize\": 14,\n \"container_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"container_dbFontWeight\": \"normal\",\n \"external_container_dbFontSize\": 14,\n \"external_container_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"external_container_dbFontWeight\": \"normal\",\n \"container_queueFontSize\": 14,\n \"container_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"container_queueFontWeight\": \"normal\",\n \"external_container_queueFontSize\": 14,\n \"external_container_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"external_container_queueFontWeight\": \"normal\",\n \"componentFontSize\": 14,\n \"componentFontFamily\": '\"Open Sans\", sans-serif',\n \"componentFontWeight\": \"normal\",\n \"external_componentFontSize\": 14,\n \"external_componentFontFamily\": '\"Open Sans\", sans-serif',\n \"external_componentFontWeight\": \"normal\",\n \"component_dbFontSize\": 14,\n \"component_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"component_dbFontWeight\": \"normal\",\n \"external_component_dbFontSize\": 14,\n \"external_component_dbFontFamily\": '\"Open Sans\", sans-serif',\n \"external_component_dbFontWeight\": \"normal\",\n \"component_queueFontSize\": 14,\n \"component_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"component_queueFontWeight\": \"normal\",\n \"external_component_queueFontSize\": 14,\n \"external_component_queueFontFamily\": '\"Open Sans\", sans-serif',\n \"external_component_queueFontWeight\": \"normal\",\n \"wrap\": true,\n \"wrapPadding\": 10,\n \"person_bg_color\": \"#08427B\",\n \"person_border_color\": \"#073B6F\",\n \"external_person_bg_color\": \"#686868\",\n \"external_person_border_color\": \"#8A8A8A\",\n \"system_bg_color\": \"#1168BD\",\n \"system_border_color\": \"#3C7FC0\",\n \"system_db_bg_color\": \"#1168BD\",\n \"system_db_border_color\": \"#3C7FC0\",\n \"system_queue_bg_color\": \"#1168BD\",\n \"system_queue_border_color\": \"#3C7FC0\",\n \"external_system_bg_color\": \"#999999\",\n \"external_system_border_color\": \"#8A8A8A\",\n \"external_system_db_bg_color\": \"#999999\",\n \"external_system_db_border_color\": \"#8A8A8A\",\n \"external_system_queue_bg_color\": \"#999999\",\n \"external_system_queue_border_color\": \"#8A8A8A\",\n \"container_bg_color\": \"#438DD5\",\n \"container_border_color\": \"#3C7FC0\",\n \"container_db_bg_color\": \"#438DD5\",\n \"container_db_border_color\": \"#3C7FC0\",\n \"container_queue_bg_color\": \"#438DD5\",\n \"container_queue_border_color\": \"#3C7FC0\",\n \"external_container_bg_color\": \"#B3B3B3\",\n \"external_container_border_color\": \"#A6A6A6\",\n \"external_container_db_bg_color\": \"#B3B3B3\",\n \"external_container_db_border_color\": \"#A6A6A6\",\n \"external_container_queue_bg_color\": \"#B3B3B3\",\n \"external_container_queue_border_color\": \"#A6A6A6\",\n \"component_bg_color\": \"#85BBF0\",\n \"component_border_color\": \"#78A8D8\",\n \"component_db_bg_color\": \"#85BBF0\",\n \"component_db_border_color\": \"#78A8D8\",\n \"component_queue_bg_color\": \"#85BBF0\",\n \"component_queue_border_color\": \"#78A8D8\",\n \"external_component_bg_color\": \"#CCCCCC\",\n \"external_component_border_color\": \"#BFBFBF\",\n \"external_component_db_bg_color\": \"#CCCCCC\",\n \"external_component_db_border_color\": \"#BFBFBF\",\n \"external_component_queue_bg_color\": \"#CCCCCC\",\n \"external_component_queue_border_color\": \"#BFBFBF\"\n },\n \"sankey\": {\n \"useMaxWidth\": true,\n \"width\": 600,\n \"height\": 400,\n \"linkColor\": \"gradient\",\n \"nodeAlignment\": \"justify\",\n \"showValues\": true,\n \"prefix\": \"\",\n \"suffix\": \"\"\n },\n \"theme\": \"default\",\n \"maxTextSize\": 5e4,\n \"darkMode\": false,\n \"fontFamily\": '\"trebuchet ms\", verdana, arial, sans-serif;',\n \"logLevel\": 5,\n \"securityLevel\": \"strict\",\n \"startOnLoad\": true,\n \"arrowMarkerAbsolute\": false,\n \"secure\": [\n \"secure\",\n \"securityLevel\",\n \"startOnLoad\",\n \"maxTextSize\"\n ],\n \"deterministicIds\": false,\n \"fontSize\": 16\n};\nconst config = {\n ...defaultConfigJson,\n // Set, even though they're `undefined` so that `configKeys` finds these keys\n // TODO: Should we replace these with `null` so that they can go in the JSON Schema?\n deterministicIDSeed: void 0,\n themeCSS: void 0,\n // add non-JSON default config values\n themeVariables: theme[\"default\"].getThemeVariables(),\n sequence: {\n ...defaultConfigJson.sequence,\n messageFont: function() {\n return {\n fontFamily: this.messageFontFamily,\n fontSize: this.messageFontSize,\n fontWeight: this.messageFontWeight\n };\n },\n noteFont: function() {\n return {\n fontFamily: this.noteFontFamily,\n fontSize: this.noteFontSize,\n fontWeight: this.noteFontWeight\n };\n },\n actorFont: function() {\n return {\n fontFamily: this.actorFontFamily,\n fontSize: this.actorFontSize,\n fontWeight: this.actorFontWeight\n };\n }\n },\n gantt: {\n ...defaultConfigJson.gantt,\n tickInterval: void 0,\n useWidth: void 0\n // can probably be removed since `configKeys` already includes this\n },\n c4: {\n ...defaultConfigJson.c4,\n useWidth: void 0,\n personFont: function() {\n return {\n fontFamily: this.personFontFamily,\n fontSize: this.personFontSize,\n fontWeight: this.personFontWeight\n };\n },\n external_personFont: function() {\n return {\n fontFamily: this.external_personFontFamily,\n fontSize: this.external_personFontSize,\n fontWeight: this.external_personFontWeight\n };\n },\n systemFont: function() {\n return {\n fontFamily: this.systemFontFamily,\n fontSize: this.systemFontSize,\n fontWeight: this.systemFontWeight\n };\n },\n external_systemFont: function() {\n return {\n fontFamily: this.external_systemFontFamily,\n fontSize: this.external_systemFontSize,\n fontWeight: this.external_systemFontWeight\n };\n },\n system_dbFont: function() {\n return {\n fontFamily: this.system_dbFontFamily,\n fontSize: this.system_dbFontSize,\n fontWeight: this.system_dbFontWeight\n };\n },\n external_system_dbFont: function() {\n return {\n fontFamily: this.external_system_dbFontFamily,\n fontSize: this.external_system_dbFontSize,\n fontWeight: this.external_system_dbFontWeight\n };\n },\n system_queueFont: function() {\n return {\n fontFamily: this.system_queueFontFamily,\n fontSize: this.system_queueFontSize,\n fontWeight: this.system_queueFontWeight\n };\n },\n external_system_queueFont: function() {\n return {\n fontFamily: this.external_system_queueFontFamily,\n fontSize: this.external_system_queueFontSize,\n fontWeight: this.external_system_queueFontWeight\n };\n },\n containerFont: function() {\n return {\n fontFamily: this.containerFontFamily,\n fontSize: this.containerFontSize,\n fontWeight: this.containerFontWeight\n };\n },\n external_containerFont: function() {\n return {\n fontFamily: this.external_containerFontFamily,\n fontSize: this.external_containerFontSize,\n fontWeight: this.external_containerFontWeight\n };\n },\n container_dbFont: function() {\n return {\n fontFamily: this.container_dbFontFamily,\n fontSize: this.container_dbFontSize,\n fontWeight: this.container_dbFontWeight\n };\n },\n external_container_dbFont: function() {\n return {\n fontFamily: this.external_container_dbFontFamily,\n fontSize: this.external_container_dbFontSize,\n fontWeight: this.external_container_dbFontWeight\n };\n },\n container_queueFont: function() {\n return {\n fontFamily: this.container_queueFontFamily,\n fontSize: this.container_queueFontSize,\n fontWeight: this.container_queueFontWeight\n };\n },\n external_container_queueFont: function() {\n return {\n fontFamily: this.external_container_queueFontFamily,\n fontSize: this.external_container_queueFontSize,\n fontWeight: this.external_container_queueFontWeight\n };\n },\n componentFont: function() {\n return {\n fontFamily: this.componentFontFamily,\n fontSize: this.componentFontSize,\n fontWeight: this.componentFontWeight\n };\n },\n external_componentFont: function() {\n return {\n fontFamily: this.external_componentFontFamily,\n fontSize: this.external_componentFontSize,\n fontWeight: this.external_componentFontWeight\n };\n },\n component_dbFont: function() {\n return {\n fontFamily: this.component_dbFontFamily,\n fontSize: this.component_dbFontSize,\n fontWeight: this.component_dbFontWeight\n };\n },\n external_component_dbFont: function() {\n return {\n fontFamily: this.external_component_dbFontFamily,\n fontSize: this.external_component_dbFontSize,\n fontWeight: this.external_component_dbFontWeight\n };\n },\n component_queueFont: function() {\n return {\n fontFamily: this.component_queueFontFamily,\n fontSize: this.component_queueFontSize,\n fontWeight: this.component_queueFontWeight\n };\n },\n external_component_queueFont: function() {\n return {\n fontFamily: this.external_component_queueFontFamily,\n fontSize: this.external_component_queueFontSize,\n fontWeight: this.external_component_queueFontWeight\n };\n },\n boundaryFont: function() {\n return {\n fontFamily: this.boundaryFontFamily,\n fontSize: this.boundaryFontSize,\n fontWeight: this.boundaryFontWeight\n };\n },\n messageFont: function() {\n return {\n fontFamily: this.messageFontFamily,\n fontSize: this.messageFontSize,\n fontWeight: this.messageFontWeight\n };\n }\n },\n pie: {\n ...defaultConfigJson.pie,\n useWidth: 984\n },\n xyChart: {\n ...defaultConfigJson.xyChart,\n useWidth: void 0\n },\n requirement: {\n ...defaultConfigJson.requirement,\n useWidth: void 0\n },\n gitGraph: {\n ...defaultConfigJson.gitGraph,\n // TODO: This is a temporary override for `gitGraph`, since every other\n // diagram does have `useMaxWidth`, but instead sets it to `true`.\n // Should we set this to `true` instead?\n useMaxWidth: false\n },\n sankey: {\n ...defaultConfigJson.sankey,\n // this is false, unlike every other diagram (other than gitGraph)\n // TODO: can we make this default to `true` instead?\n useMaxWidth: false\n }\n};\nconst keyify = (obj, prefix = \"\") => Object.keys(obj).reduce((res, el) => {\n if (Array.isArray(obj[el])) {\n return res;\n } else if (typeof obj[el] === \"object\" && obj[el] !== null) {\n return [...res, prefix + el, ...keyify(obj[el], \"\")];\n }\n return [...res, prefix + el];\n}, []);\nconst configKeys = new Set(keyify(config, \"\"));\nconst defaultConfig$2 = config;\nconst sanitizeDirective = (args) => {\n log$1.debug(\"sanitizeDirective called with\", args);\n if (typeof args !== \"object\" || args == null) {\n return;\n }\n if (Array.isArray(args)) {\n args.forEach((arg) => sanitizeDirective(arg));\n return;\n }\n for (const key of Object.keys(args)) {\n log$1.debug(\"Checking key\", key);\n if (key.startsWith(\"__\") || key.includes(\"proto\") || key.includes(\"constr\") || !configKeys.has(key) || args[key] == null) {\n log$1.debug(\"sanitize deleting key: \", key);\n delete args[key];\n continue;\n }\n if (typeof args[key] === \"object\") {\n log$1.debug(\"sanitizing object\", key);\n sanitizeDirective(args[key]);\n continue;\n }\n const cssMatchers = [\"themeCSS\", \"fontFamily\", \"altFontFamily\"];\n for (const cssKey of cssMatchers) {\n if (key.includes(cssKey)) {\n log$1.debug(\"sanitizing css option\", key);\n args[key] = sanitizeCss(args[key]);\n }\n }\n }\n if (args.themeVariables) {\n for (const k of Object.keys(args.themeVariables)) {\n const val = args.themeVariables[k];\n if ((val == null ? void 0 : val.match) && !val.match(/^[\\d \"#%(),.;A-Za-z]+$/)) {\n args.themeVariables[k] = \"\";\n }\n }\n }\n log$1.debug(\"After sanitization\", args);\n};\nconst sanitizeCss = (str2) => {\n let startCnt = 0;\n let endCnt = 0;\n for (const element of str2) {\n if (startCnt < endCnt) {\n return \"{ /* ERROR: Unbalanced CSS */ }\";\n }\n if (element === \"{\") {\n startCnt++;\n } else if (element === \"}\") {\n endCnt++;\n }\n }\n if (startCnt !== endCnt) {\n return \"{ /* ERROR: Unbalanced CSS */ }\";\n }\n return str2;\n};\nconst frontMatterRegex = /^-{3}\\s*[\\n\\r](.*?)[\\n\\r]-{3}\\s*[\\n\\r]+/s;\nconst directiveRegex = /%{2}{\\s*(?:(\\w+)\\s*:|(\\w+))\\s*(?:(\\w+)|((?:(?!}%{2}).|\\r?\\n)*))?\\s*(?:}%{2})?/gi;\nconst anyCommentRegex = /\\s*%%.*\\n/gm;\nclass UnknownDiagramError extends Error {\n constructor(message) {\n super(message);\n this.name = \"UnknownDiagramError\";\n }\n}\nconst detectors = {};\nconst detectType = function(text, config2) {\n text = text.replace(frontMatterRegex, \"\").replace(directiveRegex, \"\").replace(anyCommentRegex, \"\\n\");\n for (const [key, { detector: detector2 }] of Object.entries(detectors)) {\n const diagram2 = detector2(text, config2);\n if (diagram2) {\n return key;\n }\n }\n throw new UnknownDiagramError(\n `No diagram type detected matching given configuration for text: ${text}`\n );\n};\nconst registerLazyLoadedDiagrams = (...diagrams2) => {\n for (const { id: id2, detector: detector2, loader: loader2 } of diagrams2) {\n addDetector(id2, detector2, loader2);\n }\n};\nconst addDetector = (key, detector2, loader2) => {\n if (detectors[key]) {\n log$1.error(`Detector with key ${key} already exists`);\n } else {\n detectors[key] = { detector: detector2, loader: loader2 };\n }\n log$1.debug(`Detector with key ${key} added${loader2 ? \" with loader\" : \"\"}`);\n};\nconst getDiagramLoader = (key) => {\n return detectors[key].loader;\n};\nconst assignWithDepth = (dst, src, { depth = 2, clobber = false } = {}) => {\n const config2 = { depth, clobber };\n if (Array.isArray(src) && !Array.isArray(dst)) {\n src.forEach((s) => assignWithDepth(dst, s, config2));\n return dst;\n } else if (Array.isArray(src) && Array.isArray(dst)) {\n src.forEach((s) => {\n if (!dst.includes(s)) {\n dst.push(s);\n }\n });\n return dst;\n }\n if (dst === void 0 || depth <= 0) {\n if (dst !== void 0 && dst !== null && typeof dst === \"object\" && typeof src === \"object\") {\n return Object.assign(dst, src);\n } else {\n return src;\n }\n }\n if (src !== void 0 && typeof dst === \"object\" && typeof src === \"object\") {\n Object.keys(src).forEach((key) => {\n if (typeof src[key] === \"object\" && (dst[key] === void 0 || typeof dst[key] === \"object\")) {\n if (dst[key] === void 0) {\n dst[key] = Array.isArray(src[key]) ? [] : {};\n }\n dst[key] = assignWithDepth(dst[key], src[key], { depth: depth - 1, clobber });\n } else if (clobber || typeof dst[key] !== \"object\" && typeof src[key] !== \"object\") {\n dst[key] = src[key];\n }\n });\n }\n return dst;\n};\nconst assignWithDepth$1 = assignWithDepth;\nconst ZERO_WIDTH_SPACE = \"\u200B\";\nconst d3CurveTypes = {\n curveBasis,\n curveBasisClosed,\n curveBasisOpen,\n curveBumpX,\n curveBumpY,\n curveBundle,\n curveCardinalClosed,\n curveCardinalOpen,\n curveCardinal,\n curveCatmullRomClosed,\n curveCatmullRomOpen,\n curveCatmullRom,\n curveLinear,\n curveLinearClosed,\n curveMonotoneX,\n curveMonotoneY,\n curveNatural,\n curveStep,\n curveStepAfter,\n curveStepBefore\n};\nconst directiveWithoutOpen = /\\s*(?:(\\w+)(?=:):|(\\w+))\\s*(?:(\\w+)|((?:(?!}%{2}).|\\r?\\n)*))?\\s*(?:}%{2})?/gi;\nconst detectInit = function(text, config2) {\n const inits = detectDirective(text, /(?:init\\b)|(?:initialize\\b)/);\n let results = {};\n if (Array.isArray(inits)) {\n const args = inits.map((init2) => init2.args);\n sanitizeDirective(args);\n results = assignWithDepth$1(results, [...args]);\n } else {\n results = inits.args;\n }\n if (!results) {\n return;\n }\n let type2 = detectType(text, config2);\n const prop = \"config\";\n if (results[prop] !== void 0) {\n if (type2 === \"flowchart-v2\") {\n type2 = \"flowchart\";\n }\n results[type2] = results[prop];\n delete results[prop];\n }\n return results;\n};\nconst detectDirective = function(text, type2 = null) {\n try {\n const commentWithoutDirectives = new RegExp(\n `[%]{2}(?![{]${directiveWithoutOpen.source})(?=[}][%]{2}).*\n`,\n \"ig\"\n );\n text = text.trim().replace(commentWithoutDirectives, \"\").replace(/'/gm, '\"');\n log$1.debug(\n `Detecting diagram directive${type2 !== null ? \" type:\" + type2 : \"\"} based on the text:${text}`\n );\n let match;\n const result = [];\n while ((match = directiveRegex.exec(text)) !== null) {\n if (match.index === directiveRegex.lastIndex) {\n directiveRegex.lastIndex++;\n }\n if (match && !type2 || type2 && match[1] && match[1].match(type2) || type2 && match[2] && match[2].match(type2)) {\n const type22 = match[1] ? match[1] : match[2];\n const args = match[3] ? match[3].trim() : match[4] ? JSON.parse(match[4].trim()) : null;\n result.push({ type: type22, args });\n }\n }\n if (result.length === 0) {\n return { type: text, args: null };\n }\n return result.length === 1 ? result[0] : result;\n } catch (error) {\n log$1.error(\n `ERROR: ${error.message} - Unable to parse directive type: '${type2}' based on the text: '${text}'`\n );\n return { type: void 0, args: null };\n }\n};\nconst removeDirectives = function(text) {\n return text.replace(directiveRegex, \"\");\n};\nconst isSubstringInArray = function(str2, arr) {\n for (const [i, element] of arr.entries()) {\n if (element.match(str2)) {\n return i;\n }\n }\n return -1;\n};\nfunction interpolateToCurve(interpolate, defaultCurve) {\n if (!interpolate) {\n return defaultCurve;\n }\n const curveName = `curve${interpolate.charAt(0).toUpperCase() + interpolate.slice(1)}`;\n return d3CurveTypes[curveName] ?? defaultCurve;\n}\nfunction formatUrl(linkStr, config2) {\n const url = linkStr.trim();\n if (!url) {\n return void 0;\n }\n if (config2.securityLevel !== \"loose\") {\n return sanitizeUrl(url);\n }\n return url;\n}\nconst runFunc = (functionName, ...params) => {\n const arrPaths = functionName.split(\".\");\n const len = arrPaths.length - 1;\n const fnName = arrPaths[len];\n let obj = window;\n for (let i = 0; i < len; i++) {\n obj = obj[arrPaths[i]];\n if (!obj) {\n log$1.error(`Function name: ${functionName} not found in window`);\n return;\n }\n }\n obj[fnName](...params);\n};\nfunction distance(p1, p2) {\n if (!p1 || !p2) {\n return 0;\n }\n return Math.sqrt(Math.pow(p2.x - p1.x, 2) + Math.pow(p2.y - p1.y, 2));\n}\nfunction traverseEdge(points) {\n let prevPoint;\n let totalDistance = 0;\n points.forEach((point) => {\n totalDistance += distance(point, prevPoint);\n prevPoint = point;\n });\n const remainingDistance = totalDistance / 2;\n return calculatePoint(points, remainingDistance);\n}\nfunction calcLabelPosition(points) {\n if (points.length === 1) {\n return points[0];\n }\n return traverseEdge(points);\n}\nconst roundNumber = (num, precision = 2) => {\n const factor = Math.pow(10, precision);\n return Math.round(num * factor) / factor;\n};\nconst calculatePoint = (points, distanceToTraverse) => {\n let prevPoint = void 0;\n let remainingDistance = distanceToTraverse;\n for (const point of points) {\n if (prevPoint) {\n const vectorDistance = distance(point, prevPoint);\n if (vectorDistance < remainingDistance) {\n remainingDistance -= vectorDistance;\n } else {\n const distanceRatio = remainingDistance / vectorDistance;\n if (distanceRatio <= 0) {\n return prevPoint;\n }\n if (distanceRatio >= 1) {\n return { x: point.x, y: point.y };\n }\n if (distanceRatio > 0 && distanceRatio < 1) {\n return {\n x: roundNumber((1 - distanceRatio) * prevPoint.x + distanceRatio * point.x, 5),\n y: roundNumber((1 - distanceRatio) * prevPoint.y + distanceRatio * point.y, 5)\n };\n }\n }\n }\n prevPoint = point;\n }\n throw new Error(\"Could not find a suitable point for the given distance\");\n};\nconst calcCardinalityPosition = (isRelationTypePresent, points, initialPosition) => {\n log$1.info(`our points ${JSON.stringify(points)}`);\n if (points[0] !== initialPosition) {\n points = points.reverse();\n }\n const distanceToCardinalityPoint = 25;\n const center = calculatePoint(points, distanceToCardinalityPoint);\n const d = isRelationTypePresent ? 10 : 5;\n const angle = Math.atan2(points[0].y - center.y, points[0].x - center.x);\n const cardinalityPosition = { x: 0, y: 0 };\n cardinalityPosition.x = Math.sin(angle) * d + (points[0].x + center.x) / 2;\n cardinalityPosition.y = -Math.cos(angle) * d + (points[0].y + center.y) / 2;\n return cardinalityPosition;\n};\nfunction calcTerminalLabelPosition(terminalMarkerSize, position, _points) {\n const points = structuredClone(_points);\n log$1.info(\"our points\", points);\n if (position !== \"start_left\" && position !== \"start_right\") {\n points.reverse();\n }\n const distanceToCardinalityPoint = 25 + terminalMarkerSize;\n const center = calculatePoint(points, distanceToCardinalityPoint);\n const d = 10 + terminalMarkerSize * 0.5;\n const angle = Math.atan2(points[0].y - center.y, points[0].x - center.x);\n const cardinalityPosition = { x: 0, y: 0 };\n if (position === \"start_left\") {\n cardinalityPosition.x = Math.sin(angle + Math.PI) * d + (points[0].x + center.x) / 2;\n cardinalityPosition.y = -Math.cos(angle + Math.PI) * d + (points[0].y + center.y) / 2;\n } else if (position === \"end_right\") {\n cardinalityPosition.x = Math.sin(angle - Math.PI) * d + (points[0].x + center.x) / 2 - 5;\n cardinalityPosition.y = -Math.cos(angle - Math.PI) * d + (points[0].y + center.y) / 2 - 5;\n } else if (position === \"end_left\") {\n cardinalityPosition.x = Math.sin(angle) * d + (points[0].x + center.x) / 2 - 5;\n cardinalityPosition.y = -Math.cos(angle) * d + (points[0].y + center.y) / 2 - 5;\n } else {\n cardinalityPosition.x = Math.sin(angle) * d + (points[0].x + center.x) / 2;\n cardinalityPosition.y = -Math.cos(angle) * d + (points[0].y + center.y) / 2;\n }\n return cardinalityPosition;\n}\nfunction getStylesFromArray(arr) {\n let style = \"\";\n let labelStyle = \"\";\n for (const element of arr) {\n if (element !== void 0) {\n if (element.startsWith(\"color:\") || element.startsWith(\"text-align:\")) {\n labelStyle = labelStyle + element + \";\";\n } else {\n style = style + element + \";\";\n }\n }\n }\n return { style, labelStyle };\n}\nlet cnt = 0;\nconst generateId = () => {\n cnt++;\n return \"id-\" + Math.random().toString(36).substr(2, 12) + \"-\" + cnt;\n};\nfunction makeRandomHex(length) {\n let result = \"\";\n const characters = \"0123456789abcdef\";\n const charactersLength = characters.length;\n for (let i = 0; i < length; i++) {\n result += characters.charAt(Math.floor(Math.random() * charactersLength));\n }\n return result;\n}\nconst random = (options) => {\n return makeRandomHex(options.length);\n};\nconst getTextObj = function() {\n return {\n x: 0,\n y: 0,\n fill: void 0,\n anchor: \"start\",\n style: \"#666\",\n width: 100,\n height: 100,\n textMargin: 0,\n rx: 0,\n ry: 0,\n valign: void 0,\n text: \"\"\n };\n};\nconst drawSimpleText = function(elem, textData) {\n const nText = textData.text.replace(common$1.lineBreakRegex, \" \");\n const [, _fontSizePx] = parseFontSize(textData.fontSize);\n const textElem = elem.append(\"text\");\n textElem.attr(\"x\", textData.x);\n textElem.attr(\"y\", textData.y);\n textElem.style(\"text-anchor\", textData.anchor);\n textElem.style(\"font-family\", textData.fontFamily);\n textElem.style(\"font-size\", _fontSizePx);\n textElem.style(\"font-weight\", textData.fontWeight);\n textElem.attr(\"fill\", textData.fill);\n if (textData.class !== void 0) {\n textElem.attr(\"class\", textData.class);\n }\n const span = textElem.append(\"tspan\");\n span.attr(\"x\", textData.x + textData.textMargin * 2);\n span.attr(\"fill\", textData.fill);\n span.text(nText);\n return textElem;\n};\nconst wrapLabel = memoize(\n (label, maxWidth, config2) => {\n if (!label) {\n return label;\n }\n config2 = Object.assign(\n { fontSize: 12, fontWeight: 400, fontFamily: \"Arial\", joinWith: \"
      \" },\n config2\n );\n if (common$1.lineBreakRegex.test(label)) {\n return label;\n }\n const words = label.split(\" \");\n const completedLines = [];\n let nextLine = \"\";\n words.forEach((word, index) => {\n const wordLength = calculateTextWidth(`${word} `, config2);\n const nextLineLength = calculateTextWidth(nextLine, config2);\n if (wordLength > maxWidth) {\n const { hyphenatedStrings, remainingWord } = breakString(word, maxWidth, \"-\", config2);\n completedLines.push(nextLine, ...hyphenatedStrings);\n nextLine = remainingWord;\n } else if (nextLineLength + wordLength >= maxWidth) {\n completedLines.push(nextLine);\n nextLine = word;\n } else {\n nextLine = [nextLine, word].filter(Boolean).join(\" \");\n }\n const currentWord = index + 1;\n const isLastWord = currentWord === words.length;\n if (isLastWord) {\n completedLines.push(nextLine);\n }\n });\n return completedLines.filter((line) => line !== \"\").join(config2.joinWith);\n },\n (label, maxWidth, config2) => `${label}${maxWidth}${config2.fontSize}${config2.fontWeight}${config2.fontFamily}${config2.joinWith}`\n);\nconst breakString = memoize(\n (word, maxWidth, hyphenCharacter = \"-\", config2) => {\n config2 = Object.assign(\n { fontSize: 12, fontWeight: 400, fontFamily: \"Arial\", margin: 0 },\n config2\n );\n const characters = [...word];\n const lines = [];\n let currentLine = \"\";\n characters.forEach((character, index) => {\n const nextLine = `${currentLine}${character}`;\n const lineWidth = calculateTextWidth(nextLine, config2);\n if (lineWidth >= maxWidth) {\n const currentCharacter = index + 1;\n const isLastLine = characters.length === currentCharacter;\n const hyphenatedNextLine = `${nextLine}${hyphenCharacter}`;\n lines.push(isLastLine ? nextLine : hyphenatedNextLine);\n currentLine = \"\";\n } else {\n currentLine = nextLine;\n }\n });\n return { hyphenatedStrings: lines, remainingWord: currentLine };\n },\n (word, maxWidth, hyphenCharacter = \"-\", config2) => `${word}${maxWidth}${hyphenCharacter}${config2.fontSize}${config2.fontWeight}${config2.fontFamily}`\n);\nfunction calculateTextHeight(text, config2) {\n return calculateTextDimensions(text, config2).height;\n}\nfunction calculateTextWidth(text, config2) {\n return calculateTextDimensions(text, config2).width;\n}\nconst calculateTextDimensions = memoize(\n (text, config2) => {\n const { fontSize = 12, fontFamily = \"Arial\", fontWeight = 400 } = config2;\n if (!text) {\n return { width: 0, height: 0 };\n }\n const [, _fontSizePx] = parseFontSize(fontSize);\n const fontFamilies = [\"sans-serif\", fontFamily];\n const lines = text.split(common$1.lineBreakRegex);\n const dims = [];\n const body = select(\"body\");\n if (!body.remove) {\n return { width: 0, height: 0, lineHeight: 0 };\n }\n const g = body.append(\"svg\");\n for (const fontFamily2 of fontFamilies) {\n let cHeight = 0;\n const dim = { width: 0, height: 0, lineHeight: 0 };\n for (const line of lines) {\n const textObj = getTextObj();\n textObj.text = line || ZERO_WIDTH_SPACE;\n const textElem = drawSimpleText(g, textObj).style(\"font-size\", _fontSizePx).style(\"font-weight\", fontWeight).style(\"font-family\", fontFamily2);\n const bBox = (textElem._groups || textElem)[0][0].getBBox();\n if (bBox.width === 0 && bBox.height === 0) {\n throw new Error(\"svg element not in render tree\");\n }\n dim.width = Math.round(Math.max(dim.width, bBox.width));\n cHeight = Math.round(bBox.height);\n dim.height += cHeight;\n dim.lineHeight = Math.round(Math.max(dim.lineHeight, cHeight));\n }\n dims.push(dim);\n }\n g.remove();\n const index = isNaN(dims[1].height) || isNaN(dims[1].width) || isNaN(dims[1].lineHeight) || dims[0].height > dims[1].height && dims[0].width > dims[1].width && dims[0].lineHeight > dims[1].lineHeight ? 0 : 1;\n return dims[index];\n },\n (text, config2) => `${text}${config2.fontSize}${config2.fontWeight}${config2.fontFamily}`\n);\nclass InitIDGenerator {\n constructor(deterministic = false, seed) {\n this.count = 0;\n this.count = seed ? seed.length : 0;\n this.next = deterministic ? () => this.count++ : () => Date.now();\n }\n}\nlet decoder;\nconst entityDecode = function(html) {\n decoder = decoder || document.createElement(\"div\");\n html = escape(html).replace(/%26/g, \"&\").replace(/%23/g, \"#\").replace(/%3B/g, \";\");\n decoder.innerHTML = html;\n return unescape(decoder.textContent);\n};\nfunction isDetailedError(error) {\n return \"str\" in error;\n}\nconst insertTitle = (parent, cssClass, titleTopMargin, title) => {\n var _a;\n if (!title) {\n return;\n }\n const bounds = (_a = parent.node()) == null ? void 0 : _a.getBBox();\n if (!bounds) {\n return;\n }\n parent.append(\"text\").text(title).attr(\"x\", bounds.x + bounds.width / 2).attr(\"y\", -titleTopMargin).attr(\"class\", cssClass);\n};\nconst parseFontSize = (fontSize) => {\n if (typeof fontSize === \"number\") {\n return [fontSize, fontSize + \"px\"];\n }\n const fontSizeNumber = parseInt(fontSize ?? \"\", 10);\n if (Number.isNaN(fontSizeNumber)) {\n return [void 0, void 0];\n } else if (fontSize === String(fontSizeNumber)) {\n return [fontSizeNumber, fontSize + \"px\"];\n } else {\n return [fontSizeNumber, fontSize];\n }\n};\nfunction cleanAndMerge(defaultData, data) {\n return merge$1({}, defaultData, data);\n}\nconst utils = {\n assignWithDepth: assignWithDepth$1,\n wrapLabel,\n calculateTextHeight,\n calculateTextWidth,\n calculateTextDimensions,\n cleanAndMerge,\n detectInit,\n detectDirective,\n isSubstringInArray,\n interpolateToCurve,\n calcLabelPosition,\n calcCardinalityPosition,\n calcTerminalLabelPosition,\n formatUrl,\n getStylesFromArray,\n generateId,\n random,\n runFunc,\n entityDecode,\n insertTitle,\n parseFontSize,\n InitIDGenerator\n};\nconst version = \"10.6.1\";\nconst defaultConfig$1 = Object.freeze(defaultConfig$2);\nlet siteConfig = assignWithDepth$1({}, defaultConfig$1);\nlet configFromInitialize;\nlet directives = [];\nlet currentConfig = assignWithDepth$1({}, defaultConfig$1);\nconst updateCurrentConfig = (siteCfg, _directives) => {\n let cfg = assignWithDepth$1({}, siteCfg);\n let sumOfDirectives = {};\n for (const d of _directives) {\n sanitize(d);\n sumOfDirectives = assignWithDepth$1(sumOfDirectives, d);\n }\n cfg = assignWithDepth$1(cfg, sumOfDirectives);\n if (sumOfDirectives.theme && sumOfDirectives.theme in theme) {\n const tmpConfigFromInitialize = assignWithDepth$1({}, configFromInitialize);\n const themeVariables = assignWithDepth$1(\n tmpConfigFromInitialize.themeVariables || {},\n sumOfDirectives.themeVariables\n );\n if (cfg.theme && cfg.theme in theme) {\n cfg.themeVariables = theme[cfg.theme].getThemeVariables(themeVariables);\n }\n }\n currentConfig = cfg;\n checkConfig(currentConfig);\n return currentConfig;\n};\nconst setSiteConfig = (conf) => {\n siteConfig = assignWithDepth$1({}, defaultConfig$1);\n siteConfig = assignWithDepth$1(siteConfig, conf);\n if (conf.theme && theme[conf.theme]) {\n siteConfig.themeVariables = theme[conf.theme].getThemeVariables(conf.themeVariables);\n }\n updateCurrentConfig(siteConfig, directives);\n return siteConfig;\n};\nconst saveConfigFromInitialize = (conf) => {\n configFromInitialize = assignWithDepth$1({}, conf);\n};\nconst updateSiteConfig = (conf) => {\n siteConfig = assignWithDepth$1(siteConfig, conf);\n updateCurrentConfig(siteConfig, directives);\n return siteConfig;\n};\nconst getSiteConfig = () => {\n return assignWithDepth$1({}, siteConfig);\n};\nconst setConfig$1 = (conf) => {\n checkConfig(conf);\n assignWithDepth$1(currentConfig, conf);\n return getConfig$1();\n};\nconst getConfig$1 = () => {\n return assignWithDepth$1({}, currentConfig);\n};\nconst sanitize = (options) => {\n if (!options) {\n return;\n }\n [\"secure\", ...siteConfig.secure ?? []].forEach((key) => {\n if (Object.hasOwn(options, key)) {\n log$1.debug(`Denied attempt to modify a secure key ${key}`, options[key]);\n delete options[key];\n }\n });\n Object.keys(options).forEach((key) => {\n if (key.startsWith(\"__\")) {\n delete options[key];\n }\n });\n Object.keys(options).forEach((key) => {\n if (typeof options[key] === \"string\" && (options[key].includes(\"<\") || options[key].includes(\">\") || options[key].includes(\"url(data:\"))) {\n delete options[key];\n }\n if (typeof options[key] === \"object\") {\n sanitize(options[key]);\n }\n });\n};\nconst addDirective = (directive) => {\n sanitizeDirective(directive);\n if (directive.fontFamily && (!directive.themeVariables || !directive.themeVariables.fontFamily)) {\n directive.themeVariables = { fontFamily: directive.fontFamily };\n }\n directives.push(directive);\n updateCurrentConfig(siteConfig, directives);\n};\nconst reset = (config2 = siteConfig) => {\n directives = [];\n updateCurrentConfig(config2, directives);\n};\nconst ConfigWarning = {\n LAZY_LOAD_DEPRECATED: \"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.\"\n};\nconst issuedWarnings = {};\nconst issueWarning = (warning) => {\n if (issuedWarnings[warning]) {\n return;\n }\n log$1.warn(ConfigWarning[warning]);\n issuedWarnings[warning] = true;\n};\nconst checkConfig = (config2) => {\n if (!config2) {\n return;\n }\n if (config2.lazyLoadedDiagrams || config2.loadExternalDiagramsAtStartup) {\n issueWarning(\"LAZY_LOAD_DEPRECATED\");\n }\n};\nconst id$k = \"c4\";\nconst detector$k = (txt) => {\n return /^\\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(txt);\n};\nconst loader$l = async () => {\n const { diagram: diagram2 } = await import(\"./c4Diagram-817c8e44.js\");\n return { id: id$k, diagram: diagram2 };\n};\nconst plugin$i = {\n id: id$k,\n detector: detector$k,\n loader: loader$l\n};\nconst c4 = plugin$i;\nconst id$j = \"flowchart\";\nconst detector$j = (txt, config2) => {\n var _a, _b;\n if (((_a = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\" || ((_b = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _b.defaultRenderer) === \"elk\") {\n return false;\n }\n return /^\\s*graph/.test(txt);\n};\nconst loader$k = async () => {\n const { diagram: diagram2 } = await import(\"./flowDiagram-61eb444c.js\");\n return { id: id$j, diagram: diagram2 };\n};\nconst plugin$h = {\n id: id$j,\n detector: detector$j,\n loader: loader$k\n};\nconst flowchart = plugin$h;\nconst id$i = \"flowchart-v2\";\nconst detector$i = (txt, config2) => {\n var _a, _b, _c;\n if (((_a = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _a.defaultRenderer) === \"dagre-d3\" || ((_b = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _b.defaultRenderer) === \"elk\") {\n return false;\n }\n if (/^\\s*graph/.test(txt) && ((_c = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _c.defaultRenderer) === \"dagre-wrapper\") {\n return true;\n }\n return /^\\s*flowchart/.test(txt);\n};\nconst loader$j = async () => {\n const { diagram: diagram2 } = await import(\"./flowDiagram-v2-2f8f667a.js\");\n return { id: id$i, diagram: diagram2 };\n};\nconst plugin$g = {\n id: id$i,\n detector: detector$i,\n loader: loader$j\n};\nconst flowchartV2 = plugin$g;\nconst id$h = \"er\";\nconst detector$h = (txt) => {\n return /^\\s*erDiagram/.test(txt);\n};\nconst loader$i = async () => {\n const { diagram: diagram2 } = await import(\"./erDiagram-9cfc3649.js\");\n return { id: id$h, diagram: diagram2 };\n};\nconst plugin$f = {\n id: id$h,\n detector: detector$h,\n loader: loader$i\n};\nconst er = plugin$f;\nconst id$g = \"gitGraph\";\nconst detector$g = (txt) => {\n return /^\\s*gitGraph/.test(txt);\n};\nconst loader$h = async () => {\n const { diagram: diagram2 } = await import(\"./gitGraphDiagram-6b463803.js\");\n return { id: id$g, diagram: diagram2 };\n};\nconst plugin$e = {\n id: id$g,\n detector: detector$g,\n loader: loader$h\n};\nconst git = plugin$e;\nconst id$f = \"gantt\";\nconst detector$f = (txt) => {\n return /^\\s*gantt/.test(txt);\n};\nconst loader$g = async () => {\n const { diagram: diagram2 } = await import(\"./ganttDiagram-db6931fb.js\");\n return { id: id$f, diagram: diagram2 };\n};\nconst plugin$d = {\n id: id$f,\n detector: detector$f,\n loader: loader$g\n};\nconst gantt = plugin$d;\nconst id$e = \"info\";\nconst detector$e = (txt) => {\n return /^\\s*info/.test(txt);\n};\nconst loader$f = async () => {\n const { diagram: diagram2 } = await import(\"./infoDiagram-a336098b.js\");\n return { id: id$e, diagram: diagram2 };\n};\nconst info = {\n id: id$e,\n detector: detector$e,\n loader: loader$f\n};\nconst id$d = \"pie\";\nconst detector$d = (txt) => {\n return /^\\s*pie/.test(txt);\n};\nconst loader$e = async () => {\n const { diagram: diagram2 } = await import(\"./pieDiagram-a5166659.js\");\n return { id: id$d, diagram: diagram2 };\n};\nconst pie = {\n id: id$d,\n detector: detector$d,\n loader: loader$e\n};\nconst id$c = \"quadrantChart\";\nconst detector$c = (txt) => {\n return /^\\s*quadrantChart/.test(txt);\n};\nconst loader$d = async () => {\n const { diagram: diagram2 } = await import(\"./quadrantDiagram-6c355bbc.js\");\n return { id: id$c, diagram: diagram2 };\n};\nconst plugin$c = {\n id: id$c,\n detector: detector$c,\n loader: loader$d\n};\nconst quadrantChart = plugin$c;\nconst id$b = \"xychart\";\nconst detector$b = (txt) => {\n return /^\\s*xychart-beta/.test(txt);\n};\nconst loader$c = async () => {\n const { diagram: diagram2 } = await import(\"./xychartDiagram-f746c04c.js\");\n return { id: id$b, diagram: diagram2 };\n};\nconst plugin$b = {\n id: id$b,\n detector: detector$b,\n loader: loader$c\n};\nconst xychart = plugin$b;\nconst id$a = \"requirement\";\nconst detector$a = (txt) => {\n return /^\\s*requirement(Diagram)?/.test(txt);\n};\nconst loader$b = async () => {\n const { diagram: diagram2 } = await import(\"./requirementDiagram-4038b16c.js\");\n return { id: id$a, diagram: diagram2 };\n};\nconst plugin$a = {\n id: id$a,\n detector: detector$a,\n loader: loader$b\n};\nconst requirement = plugin$a;\nconst id$9 = \"sequence\";\nconst detector$9 = (txt) => {\n return /^\\s*sequenceDiagram/.test(txt);\n};\nconst loader$a = async () => {\n const { diagram: diagram2 } = await import(\"./sequenceDiagram-465a088a.js\");\n return { id: id$9, diagram: diagram2 };\n};\nconst plugin$9 = {\n id: id$9,\n detector: detector$9,\n loader: loader$a\n};\nconst sequence = plugin$9;\nconst id$8 = \"class\";\nconst detector$8 = (txt, config2) => {\n var _a;\n if (((_a = config2 == null ? void 0 : config2.class) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return false;\n }\n return /^\\s*classDiagram/.test(txt);\n};\nconst loader$9 = async () => {\n const { diagram: diagram2 } = await import(\"./classDiagram-48ab76fb.js\");\n return { id: id$8, diagram: diagram2 };\n};\nconst plugin$8 = {\n id: id$8,\n detector: detector$8,\n loader: loader$9\n};\nconst classDiagram = plugin$8;\nconst id$7 = \"classDiagram\";\nconst detector$7 = (txt, config2) => {\n var _a;\n if (/^\\s*classDiagram/.test(txt) && ((_a = config2 == null ? void 0 : config2.class) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return true;\n }\n return /^\\s*classDiagram-v2/.test(txt);\n};\nconst loader$8 = async () => {\n const { diagram: diagram2 } = await import(\"./classDiagram-v2-8ecb0bfc.js\");\n return { id: id$7, diagram: diagram2 };\n};\nconst plugin$7 = {\n id: id$7,\n detector: detector$7,\n loader: loader$8\n};\nconst classDiagramV2 = plugin$7;\nconst id$6 = \"state\";\nconst detector$6 = (txt, config2) => {\n var _a;\n if (((_a = config2 == null ? void 0 : config2.state) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return false;\n }\n return /^\\s*stateDiagram/.test(txt);\n};\nconst loader$7 = async () => {\n const { diagram: diagram2 } = await import(\"./stateDiagram-b620d43f.js\");\n return { id: id$6, diagram: diagram2 };\n};\nconst plugin$6 = {\n id: id$6,\n detector: detector$6,\n loader: loader$7\n};\nconst state = plugin$6;\nconst id$5 = \"stateDiagram\";\nconst detector$5 = (txt, config2) => {\n var _a;\n if (/^\\s*stateDiagram-v2/.test(txt)) {\n return true;\n }\n if (/^\\s*stateDiagram/.test(txt) && ((_a = config2 == null ? void 0 : config2.state) == null ? void 0 : _a.defaultRenderer) === \"dagre-wrapper\") {\n return true;\n }\n return false;\n};\nconst loader$6 = async () => {\n const { diagram: diagram2 } = await import(\"./stateDiagram-v2-2671c3d1.js\");\n return { id: id$5, diagram: diagram2 };\n};\nconst plugin$5 = {\n id: id$5,\n detector: detector$5,\n loader: loader$6\n};\nconst stateV2 = plugin$5;\nconst id$4 = \"journey\";\nconst detector$4 = (txt) => {\n return /^\\s*journey/.test(txt);\n};\nconst loader$5 = async () => {\n const { diagram: diagram2 } = await import(\"./journeyDiagram-deae3313.js\");\n return { id: id$4, diagram: diagram2 };\n};\nconst plugin$4 = {\n id: id$4,\n detector: detector$4,\n loader: loader$5\n};\nconst journey = plugin$4;\nconst d3Attrs = function(d3Elem, attrs) {\n for (let attr of attrs) {\n d3Elem.attr(attr[0], attr[1]);\n }\n};\nconst calculateSvgSizeAttrs = function(height, width, useMaxWidth) {\n let attrs = /* @__PURE__ */ new Map();\n if (useMaxWidth) {\n attrs.set(\"width\", \"100%\");\n attrs.set(\"style\", `max-width: ${width}px;`);\n } else {\n attrs.set(\"height\", height);\n attrs.set(\"width\", width);\n }\n return attrs;\n};\nconst configureSvgSize = function(svgElem, height, width, useMaxWidth) {\n const attrs = calculateSvgSizeAttrs(height, width, useMaxWidth);\n d3Attrs(svgElem, attrs);\n};\nconst setupGraphViewbox$1 = function(graph, svgElem, padding, useMaxWidth) {\n const svgBounds = svgElem.node().getBBox();\n const sWidth = svgBounds.width;\n const sHeight = svgBounds.height;\n log$1.info(`SVG bounds: ${sWidth}x${sHeight}`, svgBounds);\n let width = 0;\n let height = 0;\n log$1.info(`Graph bounds: ${width}x${height}`, graph);\n width = sWidth + padding * 2;\n height = sHeight + padding * 2;\n log$1.info(`Calculated bounds: ${width}x${height}`);\n configureSvgSize(svgElem, height, width, useMaxWidth);\n const vBox = `${svgBounds.x - padding} ${svgBounds.y - padding} ${svgBounds.width + 2 * padding} ${svgBounds.height + 2 * padding}`;\n svgElem.attr(\"viewBox\", vBox);\n};\nconst themes = {};\nconst getStyles = (type2, userStyles, options) => {\n let diagramStyles = \"\";\n if (type2 in themes && themes[type2]) {\n diagramStyles = themes[type2](options);\n } else {\n log$1.warn(`No theme found for ${type2}`);\n }\n return ` & {\n font-family: ${options.fontFamily};\n font-size: ${options.fontSize};\n fill: ${options.textColor}\n }\n\n /* Classes common for multiple diagrams */\n\n & .error-icon {\n fill: ${options.errorBkgColor};\n }\n & .error-text {\n fill: ${options.errorTextColor};\n stroke: ${options.errorTextColor};\n }\n\n & .edge-thickness-normal {\n stroke-width: 2px;\n }\n & .edge-thickness-thick {\n stroke-width: 3.5px\n }\n & .edge-pattern-solid {\n stroke-dasharray: 0;\n }\n\n & .edge-pattern-dashed{\n stroke-dasharray: 3;\n }\n .edge-pattern-dotted {\n stroke-dasharray: 2;\n }\n\n & .marker {\n fill: ${options.lineColor};\n stroke: ${options.lineColor};\n }\n & .marker.cross {\n stroke: ${options.lineColor};\n }\n\n & svg {\n font-family: ${options.fontFamily};\n font-size: ${options.fontSize};\n }\n\n ${diagramStyles}\n\n ${userStyles}\n`;\n};\nconst addStylesForDiagram = (type2, diagramTheme) => {\n if (diagramTheme !== void 0) {\n themes[type2] = diagramTheme;\n }\n};\nconst getStyles$1 = getStyles;\nlet accTitle = \"\";\nlet diagramTitle = \"\";\nlet accDescription = \"\";\nconst sanitizeText$1 = (txt) => sanitizeText$2(txt, getConfig$1());\nconst clear = () => {\n accTitle = \"\";\n accDescription = \"\";\n diagramTitle = \"\";\n};\nconst setAccTitle = (txt) => {\n accTitle = sanitizeText$1(txt).replace(/^\\s+/g, \"\");\n};\nconst getAccTitle = () => accTitle;\nconst setAccDescription = (txt) => {\n accDescription = sanitizeText$1(txt).replace(/\\n\\s+/g, \"\\n\");\n};\nconst getAccDescription = () => accDescription;\nconst setDiagramTitle = (txt) => {\n diagramTitle = sanitizeText$1(txt);\n};\nconst getDiagramTitle = () => diagramTitle;\nconst commonDb = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({\n __proto__: null,\n clear,\n getAccDescription,\n getAccTitle,\n getDiagramTitle,\n setAccDescription,\n setAccTitle,\n setDiagramTitle\n}, Symbol.toStringTag, { value: \"Module\" }));\nconst log = log$1;\nconst setLogLevel = setLogLevel$1;\nconst getConfig = getConfig$1;\nconst setConfig = setConfig$1;\nconst defaultConfig = defaultConfig$1;\nconst sanitizeText = (text) => sanitizeText$2(text, getConfig());\nconst setupGraphViewbox = setupGraphViewbox$1;\nconst getCommonDb = () => {\n return commonDb;\n};\nconst diagrams = {};\nconst registerDiagram = (id2, diagram2, detector2) => {\n var _a;\n if (diagrams[id2]) {\n throw new Error(`Diagram ${id2} already registered.`);\n }\n diagrams[id2] = diagram2;\n if (detector2) {\n addDetector(id2, detector2);\n }\n addStylesForDiagram(id2, diagram2.styles);\n (_a = diagram2.injectUtils) == null ? void 0 : _a.call(\n diagram2,\n log,\n setLogLevel,\n getConfig,\n sanitizeText,\n setupGraphViewbox,\n getCommonDb(),\n () => {\n }\n );\n};\nconst getDiagram = (name) => {\n if (name in diagrams) {\n return diagrams[name];\n }\n throw new DiagramNotFoundError(name);\n};\nclass DiagramNotFoundError extends Error {\n constructor(name) {\n super(`Diagram ${name} not found.`);\n }\n}\nconst selectSvgElement = (id2) => {\n var _a;\n const { securityLevel } = getConfig();\n let root = select(\"body\");\n if (securityLevel === \"sandbox\") {\n const sandboxElement = select(`#i${id2}`);\n const doc = ((_a = sandboxElement.node()) == null ? void 0 : _a.contentDocument) ?? document;\n root = select(doc.body);\n }\n const svg = root.select(`#${id2}`);\n return svg;\n};\nconst draw = (_text, id2, version2) => {\n log$1.debug(\"renering svg for syntax error\\n\");\n const svg = selectSvgElement(id2);\n svg.attr(\"viewBox\", \"0 0 2412 512\");\n configureSvgSize(svg, 100, 512, true);\n const g = svg.append(\"g\");\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z\"\n );\n g.append(\"path\").attr(\"class\", \"error-icon\").attr(\n \"d\",\n \"m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z\"\n );\n g.append(\"text\").attr(\"class\", \"error-text\").attr(\"x\", 1440).attr(\"y\", 250).attr(\"font-size\", \"150px\").style(\"text-anchor\", \"middle\").text(\"Syntax error in text\");\n g.append(\"text\").attr(\"class\", \"error-text\").attr(\"x\", 1250).attr(\"y\", 400).attr(\"font-size\", \"100px\").style(\"text-anchor\", \"middle\").text(`mermaid version ${version2}`);\n};\nconst renderer = { draw };\nconst errorRenderer = renderer;\nconst diagram = {\n db: {},\n renderer,\n parser: {\n parser: { yy: {} },\n parse: () => {\n return;\n }\n }\n};\nconst errorDiagram = diagram;\nconst id$3 = \"flowchart-elk\";\nconst detector$3 = (txt, config2) => {\n var _a;\n if (\n // If diagram explicitly states flowchart-elk\n /^\\s*flowchart-elk/.test(txt) || // If a flowchart/graph diagram has their default renderer set to elk\n /^\\s*flowchart|graph/.test(txt) && ((_a = config2 == null ? void 0 : config2.flowchart) == null ? void 0 : _a.defaultRenderer) === \"elk\"\n ) {\n return true;\n }\n return false;\n};\nconst loader$4 = async () => {\n const { diagram: diagram2 } = await import(\"./flowchart-elk-definition-e097735e.js\");\n return { id: id$3, diagram: diagram2 };\n};\nconst plugin$3 = {\n id: id$3,\n detector: detector$3,\n loader: loader$4\n};\nconst flowchartElk = plugin$3;\nconst id$2 = \"timeline\";\nconst detector$2 = (txt) => {\n return /^\\s*timeline/.test(txt);\n};\nconst loader$3 = async () => {\n const { diagram: diagram2 } = await import(\"./timeline-definition-732a2638.js\");\n return { id: id$2, diagram: diagram2 };\n};\nconst plugin$2 = {\n id: id$2,\n detector: detector$2,\n loader: loader$3\n};\nconst timeline = plugin$2;\nconst id$1 = \"mindmap\";\nconst detector$1 = (txt) => {\n return /^\\s*mindmap/.test(txt);\n};\nconst loader$2 = async () => {\n const { diagram: diagram2 } = await import(\"./mindmap-definition-617cf8dd.js\");\n return { id: id$1, diagram: diagram2 };\n};\nconst plugin$1 = {\n id: id$1,\n detector: detector$1,\n loader: loader$2\n};\nconst mindmap = plugin$1;\nconst id = \"sankey\";\nconst detector = (txt) => {\n return /^\\s*sankey-beta/.test(txt);\n};\nconst loader$1 = async () => {\n const { diagram: diagram2 } = await import(\"./sankeyDiagram-6db3d513.js\");\n return { id, diagram: diagram2 };\n};\nconst plugin = {\n id,\n detector,\n loader: loader$1\n};\nconst sankey = plugin;\nlet hasLoadedDiagrams = false;\nconst addDiagrams = () => {\n if (hasLoadedDiagrams) {\n return;\n }\n hasLoadedDiagrams = true;\n registerDiagram(\"error\", errorDiagram, (text) => {\n return text.toLowerCase().trim() === \"error\";\n });\n registerDiagram(\n \"---\",\n // --- diagram type may appear if YAML front-matter is not parsed correctly\n {\n db: {\n clear: () => {\n }\n },\n styles: {},\n // should never be used\n renderer: {\n draw: () => {\n }\n },\n parser: {\n parser: { yy: {} },\n parse: () => {\n throw new Error(\n \"Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks\"\n );\n }\n },\n init: () => null\n // no op\n },\n (text) => {\n return text.toLowerCase().trimStart().startsWith(\"---\");\n }\n );\n registerLazyLoadedDiagrams(\n c4,\n classDiagramV2,\n classDiagram,\n er,\n gantt,\n info,\n pie,\n requirement,\n sequence,\n flowchartElk,\n flowchartV2,\n flowchart,\n mindmap,\n timeline,\n git,\n stateV2,\n state,\n journey,\n quadrantChart,\n sankey,\n xychart\n );\n};\nclass Diagram {\n constructor(text, metadata = {}) {\n this.text = text;\n this.metadata = metadata;\n this.type = \"graph\";\n this.text += \"\\n\";\n const cnf = getConfig$1();\n try {\n this.type = detectType(text, cnf);\n } catch (e) {\n this.type = \"error\";\n this.detectError = e;\n }\n const diagram2 = getDiagram(this.type);\n log$1.debug(\"Type \" + this.type);\n this.db = diagram2.db;\n this.renderer = diagram2.renderer;\n this.parser = diagram2.parser;\n this.parser.parser.yy = this.db;\n this.init = diagram2.init;\n this.parse();\n }\n parse() {\n var _a, _b, _c, _d, _e;\n if (this.detectError) {\n throw this.detectError;\n }\n (_b = (_a = this.db).clear) == null ? void 0 : _b.call(_a);\n const config2 = getConfig$1();\n (_c = this.init) == null ? void 0 : _c.call(this, config2);\n if (this.metadata.title) {\n (_e = (_d = this.db).setDiagramTitle) == null ? void 0 : _e.call(_d, this.metadata.title);\n }\n this.parser.parse(this.text);\n }\n async render(id2, version2) {\n await this.renderer.draw(this.text, id2, version2, this);\n }\n getParser() {\n return this.parser;\n }\n getType() {\n return this.type;\n }\n}\nconst getDiagramFromText = async (text, metadata = {}) => {\n const type2 = detectType(text, getConfig$1());\n try {\n getDiagram(type2);\n } catch (error) {\n const loader2 = getDiagramLoader(type2);\n if (!loader2) {\n throw new UnknownDiagramError(`Diagram ${type2} not found.`);\n }\n const { id: id2, diagram: diagram2 } = await loader2();\n registerDiagram(id2, diagram2);\n }\n return new Diagram(text, metadata);\n};\nlet interactionFunctions = [];\nconst addFunction = (func) => {\n interactionFunctions.push(func);\n};\nconst attachFunctions = () => {\n interactionFunctions.forEach((f) => {\n f();\n });\n interactionFunctions = [];\n};\nconst SVG_ROLE = \"graphics-document document\";\nfunction setA11yDiagramInfo(svg, diagramType) {\n svg.attr(\"role\", SVG_ROLE);\n if (diagramType !== \"\") {\n svg.attr(\"aria-roledescription\", diagramType);\n }\n}\nfunction addSVGa11yTitleDescription(svg, a11yTitle, a11yDesc, baseId) {\n if (svg.insert === void 0) {\n return;\n }\n if (a11yDesc) {\n const descId = `chart-desc-${baseId}`;\n svg.attr(\"aria-describedby\", descId);\n svg.insert(\"desc\", \":first-child\").attr(\"id\", descId).text(a11yDesc);\n }\n if (a11yTitle) {\n const titleId = `chart-title-${baseId}`;\n svg.attr(\"aria-labelledby\", titleId);\n svg.insert(\"title\", \":first-child\").attr(\"id\", titleId).text(a11yTitle);\n }\n}\nconst cleanupComments = (text) => {\n return text.replace(/^\\s*%%(?!{)[^\\n]+\\n?/gm, \"\").trimStart();\n};\n/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */\nfunction isNothing(subject) {\n return typeof subject === \"undefined\" || subject === null;\n}\nfunction isObject(subject) {\n return typeof subject === \"object\" && subject !== null;\n}\nfunction toArray(sequence2) {\n if (Array.isArray(sequence2))\n return sequence2;\n else if (isNothing(sequence2))\n return [];\n return [sequence2];\n}\nfunction extend(target, source) {\n var index, length, key, sourceKeys;\n if (source) {\n sourceKeys = Object.keys(source);\n for (index = 0, length = sourceKeys.length; index < length; index += 1) {\n key = sourceKeys[index];\n target[key] = source[key];\n }\n }\n return target;\n}\nfunction repeat(string, count) {\n var result = \"\", cycle;\n for (cycle = 0; cycle < count; cycle += 1) {\n result += string;\n }\n return result;\n}\nfunction isNegativeZero(number) {\n return number === 0 && Number.NEGATIVE_INFINITY === 1 / number;\n}\nvar isNothing_1 = isNothing;\nvar isObject_1 = isObject;\nvar toArray_1 = toArray;\nvar repeat_1 = repeat;\nvar isNegativeZero_1 = isNegativeZero;\nvar extend_1 = extend;\nvar common = {\n isNothing: isNothing_1,\n isObject: isObject_1,\n toArray: toArray_1,\n repeat: repeat_1,\n isNegativeZero: isNegativeZero_1,\n extend: extend_1\n};\nfunction formatError(exception2, compact) {\n var where = \"\", message = exception2.reason || \"(unknown reason)\";\n if (!exception2.mark)\n return message;\n if (exception2.mark.name) {\n where += 'in \"' + exception2.mark.name + '\" ';\n }\n where += \"(\" + (exception2.mark.line + 1) + \":\" + (exception2.mark.column + 1) + \")\";\n if (!compact && exception2.mark.snippet) {\n where += \"\\n\\n\" + exception2.mark.snippet;\n }\n return message + \" \" + where;\n}\nfunction YAMLException$1(reason, mark) {\n Error.call(this);\n this.name = \"YAMLException\";\n this.reason = reason;\n this.mark = mark;\n this.message = formatError(this, false);\n if (Error.captureStackTrace) {\n Error.captureStackTrace(this, this.constructor);\n } else {\n this.stack = new Error().stack || \"\";\n }\n}\nYAMLException$1.prototype = Object.create(Error.prototype);\nYAMLException$1.prototype.constructor = YAMLException$1;\nYAMLException$1.prototype.toString = function toString(compact) {\n return this.name + \": \" + formatError(this, compact);\n};\nvar exception = YAMLException$1;\nfunction getLine(buffer, lineStart, lineEnd, position, maxLineLength) {\n var head = \"\";\n var tail = \"\";\n var maxHalfLength = Math.floor(maxLineLength / 2) - 1;\n if (position - lineStart > maxHalfLength) {\n head = \" ... \";\n lineStart = position - maxHalfLength + head.length;\n }\n if (lineEnd - position > maxHalfLength) {\n tail = \" ...\";\n lineEnd = position + maxHalfLength - tail.length;\n }\n return {\n str: head + buffer.slice(lineStart, lineEnd).replace(/\\t/g, \"\u2192\") + tail,\n pos: position - lineStart + head.length\n // relative position\n };\n}\nfunction padStart(string, max) {\n return common.repeat(\" \", max - string.length) + string;\n}\nfunction makeSnippet(mark, options) {\n options = Object.create(options || null);\n if (!mark.buffer)\n return null;\n if (!options.maxLength)\n options.maxLength = 79;\n if (typeof options.indent !== \"number\")\n options.indent = 1;\n if (typeof options.linesBefore !== \"number\")\n options.linesBefore = 3;\n if (typeof options.linesAfter !== \"number\")\n options.linesAfter = 2;\n var re = /\\r?\\n|\\r|\\0/g;\n var lineStarts = [0];\n var lineEnds = [];\n var match;\n var foundLineNo = -1;\n while (match = re.exec(mark.buffer)) {\n lineEnds.push(match.index);\n lineStarts.push(match.index + match[0].length);\n if (mark.position <= match.index && foundLineNo < 0) {\n foundLineNo = lineStarts.length - 2;\n }\n }\n if (foundLineNo < 0)\n foundLineNo = lineStarts.length - 1;\n var result = \"\", i, line;\n var lineNoLength = Math.min(mark.line + options.linesAfter, lineEnds.length).toString().length;\n var maxLineLength = options.maxLength - (options.indent + lineNoLength + 3);\n for (i = 1; i <= options.linesBefore; i++) {\n if (foundLineNo - i < 0)\n break;\n line = getLine(\n mark.buffer,\n lineStarts[foundLineNo - i],\n lineEnds[foundLineNo - i],\n mark.position - (lineStarts[foundLineNo] - lineStarts[foundLineNo - i]),\n maxLineLength\n );\n result = common.repeat(\" \", options.indent) + padStart((mark.line - i + 1).toString(), lineNoLength) + \" | \" + line.str + \"\\n\" + result;\n }\n line = getLine(mark.buffer, lineStarts[foundLineNo], lineEnds[foundLineNo], mark.position, maxLineLength);\n result += common.repeat(\" \", options.indent) + padStart((mark.line + 1).toString(), lineNoLength) + \" | \" + line.str + \"\\n\";\n result += common.repeat(\"-\", options.indent + lineNoLength + 3 + line.pos) + \"^\\n\";\n for (i = 1; i <= options.linesAfter; i++) {\n if (foundLineNo + i >= lineEnds.length)\n break;\n line = getLine(\n mark.buffer,\n lineStarts[foundLineNo + i],\n lineEnds[foundLineNo + i],\n mark.position - (lineStarts[foundLineNo] - lineStarts[foundLineNo + i]),\n maxLineLength\n );\n result += common.repeat(\" \", options.indent) + padStart((mark.line + i + 1).toString(), lineNoLength) + \" | \" + line.str + \"\\n\";\n }\n return result.replace(/\\n$/, \"\");\n}\nvar snippet = makeSnippet;\nvar TYPE_CONSTRUCTOR_OPTIONS = [\n \"kind\",\n \"multi\",\n \"resolve\",\n \"construct\",\n \"instanceOf\",\n \"predicate\",\n \"represent\",\n \"representName\",\n \"defaultStyle\",\n \"styleAliases\"\n];\nvar YAML_NODE_KINDS = [\n \"scalar\",\n \"sequence\",\n \"mapping\"\n];\nfunction compileStyleAliases(map2) {\n var result = {};\n if (map2 !== null) {\n Object.keys(map2).forEach(function(style) {\n map2[style].forEach(function(alias) {\n result[String(alias)] = style;\n });\n });\n }\n return result;\n}\nfunction Type$1(tag, options) {\n options = options || {};\n Object.keys(options).forEach(function(name) {\n if (TYPE_CONSTRUCTOR_OPTIONS.indexOf(name) === -1) {\n throw new exception('Unknown option \"' + name + '\" is met in definition of \"' + tag + '\" YAML type.');\n }\n });\n this.options = options;\n this.tag = tag;\n this.kind = options[\"kind\"] || null;\n this.resolve = options[\"resolve\"] || function() {\n return true;\n };\n this.construct = options[\"construct\"] || function(data) {\n return data;\n };\n this.instanceOf = options[\"instanceOf\"] || null;\n this.predicate = options[\"predicate\"] || null;\n this.represent = options[\"represent\"] || null;\n this.representName = options[\"representName\"] || null;\n this.defaultStyle = options[\"defaultStyle\"] || null;\n this.multi = options[\"multi\"] || false;\n this.styleAliases = compileStyleAliases(options[\"styleAliases\"] || null);\n if (YAML_NODE_KINDS.indexOf(this.kind) === -1) {\n throw new exception('Unknown kind \"' + this.kind + '\" is specified for \"' + tag + '\" YAML type.');\n }\n}\nvar type = Type$1;\nfunction compileList(schema2, name) {\n var result = [];\n schema2[name].forEach(function(currentType) {\n var newIndex = result.length;\n result.forEach(function(previousType, previousIndex) {\n if (previousType.tag === currentType.tag && previousType.kind === currentType.kind && previousType.multi === currentType.multi) {\n newIndex = previousIndex;\n }\n });\n result[newIndex] = currentType;\n });\n return result;\n}\nfunction compileMap() {\n var result = {\n scalar: {},\n sequence: {},\n mapping: {},\n fallback: {},\n multi: {\n scalar: [],\n sequence: [],\n mapping: [],\n fallback: []\n }\n }, index, length;\n function collectType(type2) {\n if (type2.multi) {\n result.multi[type2.kind].push(type2);\n result.multi[\"fallback\"].push(type2);\n } else {\n result[type2.kind][type2.tag] = result[\"fallback\"][type2.tag] = type2;\n }\n }\n for (index = 0, length = arguments.length; index < length; index += 1) {\n arguments[index].forEach(collectType);\n }\n return result;\n}\nfunction Schema$1(definition) {\n return this.extend(definition);\n}\nSchema$1.prototype.extend = function extend2(definition) {\n var implicit = [];\n var explicit = [];\n if (definition instanceof type) {\n explicit.push(definition);\n } else if (Array.isArray(definition)) {\n explicit = explicit.concat(definition);\n } else if (definition && (Array.isArray(definition.implicit) || Array.isArray(definition.explicit))) {\n if (definition.implicit)\n implicit = implicit.concat(definition.implicit);\n if (definition.explicit)\n explicit = explicit.concat(definition.explicit);\n } else {\n throw new exception(\"Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })\");\n }\n implicit.forEach(function(type$1) {\n if (!(type$1 instanceof type)) {\n throw new exception(\"Specified list of YAML types (or a single Type object) contains a non-Type object.\");\n }\n if (type$1.loadKind && type$1.loadKind !== \"scalar\") {\n throw new exception(\"There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.\");\n }\n if (type$1.multi) {\n throw new exception(\"There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.\");\n }\n });\n explicit.forEach(function(type$1) {\n if (!(type$1 instanceof type)) {\n throw new exception(\"Specified list of YAML types (or a single Type object) contains a non-Type object.\");\n }\n });\n var result = Object.create(Schema$1.prototype);\n result.implicit = (this.implicit || []).concat(implicit);\n result.explicit = (this.explicit || []).concat(explicit);\n result.compiledImplicit = compileList(result, \"implicit\");\n result.compiledExplicit = compileList(result, \"explicit\");\n result.compiledTypeMap = compileMap(result.compiledImplicit, result.compiledExplicit);\n return result;\n};\nvar schema = Schema$1;\nvar str = new type(\"tag:yaml.org,2002:str\", {\n kind: \"scalar\",\n construct: function(data) {\n return data !== null ? data : \"\";\n }\n});\nvar seq = new type(\"tag:yaml.org,2002:seq\", {\n kind: \"sequence\",\n construct: function(data) {\n return data !== null ? data : [];\n }\n});\nvar map = new type(\"tag:yaml.org,2002:map\", {\n kind: \"mapping\",\n construct: function(data) {\n return data !== null ? data : {};\n }\n});\nvar failsafe = new schema({\n explicit: [\n str,\n seq,\n map\n ]\n});\nfunction resolveYamlNull(data) {\n if (data === null)\n return true;\n var max = data.length;\n return max === 1 && data === \"~\" || max === 4 && (data === \"null\" || data === \"Null\" || data === \"NULL\");\n}\nfunction constructYamlNull() {\n return null;\n}\nfunction isNull(object) {\n return object === null;\n}\nvar _null = new type(\"tag:yaml.org,2002:null\", {\n kind: \"scalar\",\n resolve: resolveYamlNull,\n construct: constructYamlNull,\n predicate: isNull,\n represent: {\n canonical: function() {\n return \"~\";\n },\n lowercase: function() {\n return \"null\";\n },\n uppercase: function() {\n return \"NULL\";\n },\n camelcase: function() {\n return \"Null\";\n },\n empty: function() {\n return \"\";\n }\n },\n defaultStyle: \"lowercase\"\n});\nfunction resolveYamlBoolean(data) {\n if (data === null)\n return false;\n var max = data.length;\n return max === 4 && (data === \"true\" || data === \"True\" || data === \"TRUE\") || max === 5 && (data === \"false\" || data === \"False\" || data === \"FALSE\");\n}\nfunction constructYamlBoolean(data) {\n return data === \"true\" || data === \"True\" || data === \"TRUE\";\n}\nfunction isBoolean(object) {\n return Object.prototype.toString.call(object) === \"[object Boolean]\";\n}\nvar bool = new type(\"tag:yaml.org,2002:bool\", {\n kind: \"scalar\",\n resolve: resolveYamlBoolean,\n construct: constructYamlBoolean,\n predicate: isBoolean,\n represent: {\n lowercase: function(object) {\n return object ? \"true\" : \"false\";\n },\n uppercase: function(object) {\n return object ? \"TRUE\" : \"FALSE\";\n },\n camelcase: function(object) {\n return object ? \"True\" : \"False\";\n }\n },\n defaultStyle: \"lowercase\"\n});\nfunction isHexCode(c) {\n return 48 <= c && c <= 57 || 65 <= c && c <= 70 || 97 <= c && c <= 102;\n}\nfunction isOctCode(c) {\n return 48 <= c && c <= 55;\n}\nfunction isDecCode(c) {\n return 48 <= c && c <= 57;\n}\nfunction resolveYamlInteger(data) {\n if (data === null)\n return false;\n var max = data.length, index = 0, hasDigits = false, ch;\n if (!max)\n return false;\n ch = data[index];\n if (ch === \"-\" || ch === \"+\") {\n ch = data[++index];\n }\n if (ch === \"0\") {\n if (index + 1 === max)\n return true;\n ch = data[++index];\n if (ch === \"b\") {\n index++;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (ch !== \"0\" && ch !== \"1\")\n return false;\n hasDigits = true;\n }\n return hasDigits && ch !== \"_\";\n }\n if (ch === \"x\") {\n index++;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (!isHexCode(data.charCodeAt(index)))\n return false;\n hasDigits = true;\n }\n return hasDigits && ch !== \"_\";\n }\n if (ch === \"o\") {\n index++;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (!isOctCode(data.charCodeAt(index)))\n return false;\n hasDigits = true;\n }\n return hasDigits && ch !== \"_\";\n }\n }\n if (ch === \"_\")\n return false;\n for (; index < max; index++) {\n ch = data[index];\n if (ch === \"_\")\n continue;\n if (!isDecCode(data.charCodeAt(index))) {\n return false;\n }\n hasDigits = true;\n }\n if (!hasDigits || ch === \"_\")\n return false;\n return true;\n}\nfunction constructYamlInteger(data) {\n var value = data, sign = 1, ch;\n if (value.indexOf(\"_\") !== -1) {\n value = value.replace(/_/g, \"\");\n }\n ch = value[0];\n if (ch === \"-\" || ch === \"+\") {\n if (ch === \"-\")\n sign = -1;\n value = value.slice(1);\n ch = value[0];\n }\n if (value === \"0\")\n return 0;\n if (ch === \"0\") {\n if (value[1] === \"b\")\n return sign * parseInt(value.slice(2), 2);\n if (value[1] === \"x\")\n return sign * parseInt(value.slice(2), 16);\n if (value[1] === \"o\")\n return sign * parseInt(value.slice(2), 8);\n }\n return sign * parseInt(value, 10);\n}\nfunction isInteger(object) {\n return Object.prototype.toString.call(object) === \"[object Number]\" && (object % 1 === 0 && !common.isNegativeZero(object));\n}\nvar int = new type(\"tag:yaml.org,2002:int\", {\n kind: \"scalar\",\n resolve: resolveYamlInteger,\n construct: constructYamlInteger,\n predicate: isInteger,\n represent: {\n binary: function(obj) {\n return obj >= 0 ? \"0b\" + obj.toString(2) : \"-0b\" + obj.toString(2).slice(1);\n },\n octal: function(obj) {\n return obj >= 0 ? \"0o\" + obj.toString(8) : \"-0o\" + obj.toString(8).slice(1);\n },\n decimal: function(obj) {\n return obj.toString(10);\n },\n /* eslint-disable max-len */\n hexadecimal: function(obj) {\n return obj >= 0 ? \"0x\" + obj.toString(16).toUpperCase() : \"-0x\" + obj.toString(16).toUpperCase().slice(1);\n }\n },\n defaultStyle: \"decimal\",\n styleAliases: {\n binary: [2, \"bin\"],\n octal: [8, \"oct\"],\n decimal: [10, \"dec\"],\n hexadecimal: [16, \"hex\"]\n }\n});\nvar YAML_FLOAT_PATTERN = new RegExp(\n // 2.5e4, 2.5 and integers\n \"^(?:[-+]?(?:[0-9][0-9_]*)(?:\\\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\\\.(?:inf|Inf|INF)|\\\\.(?:nan|NaN|NAN))$\"\n);\nfunction resolveYamlFloat(data) {\n if (data === null)\n return false;\n if (!YAML_FLOAT_PATTERN.test(data) || // Quick hack to not allow integers end with `_`\n // Probably should update regexp & check speed\n data[data.length - 1] === \"_\") {\n return false;\n }\n return true;\n}\nfunction constructYamlFloat(data) {\n var value, sign;\n value = data.replace(/_/g, \"\").toLowerCase();\n sign = value[0] === \"-\" ? -1 : 1;\n if (\"+-\".indexOf(value[0]) >= 0) {\n value = value.slice(1);\n }\n if (value === \".inf\") {\n return sign === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY;\n } else if (value === \".nan\") {\n return NaN;\n }\n return sign * parseFloat(value, 10);\n}\nvar SCIENTIFIC_WITHOUT_DOT = /^[-+]?[0-9]+e/;\nfunction representYamlFloat(object, style) {\n var res;\n if (isNaN(object)) {\n switch (style) {\n case \"lowercase\":\n return \".nan\";\n case \"uppercase\":\n return \".NAN\";\n case \"camelcase\":\n return \".NaN\";\n }\n } else if (Number.POSITIVE_INFINITY === object) {\n switch (style) {\n case \"lowercase\":\n return \".inf\";\n case \"uppercase\":\n return \".INF\";\n case \"camelcase\":\n return \".Inf\";\n }\n } else if (Number.NEGATIVE_INFINITY === object) {\n switch (style) {\n case \"lowercase\":\n return \"-.inf\";\n case \"uppercase\":\n return \"-.INF\";\n case \"camelcase\":\n return \"-.Inf\";\n }\n } else if (common.isNegativeZero(object)) {\n return \"-0.0\";\n }\n res = object.toString(10);\n return SCIENTIFIC_WITHOUT_DOT.test(res) ? res.replace(\"e\", \".e\") : res;\n}\nfunction isFloat(object) {\n return Object.prototype.toString.call(object) === \"[object Number]\" && (object % 1 !== 0 || common.isNegativeZero(object));\n}\nvar float = new type(\"tag:yaml.org,2002:float\", {\n kind: \"scalar\",\n resolve: resolveYamlFloat,\n construct: constructYamlFloat,\n predicate: isFloat,\n represent: representYamlFloat,\n defaultStyle: \"lowercase\"\n});\nvar json = failsafe.extend({\n implicit: [\n _null,\n bool,\n int,\n float\n ]\n});\nvar core = json;\nvar YAML_DATE_REGEXP = new RegExp(\n \"^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$\"\n);\nvar YAML_TIMESTAMP_REGEXP = new RegExp(\n \"^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\\\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\\\.([0-9]*))?(?:[ \\\\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$\"\n);\nfunction resolveYamlTimestamp(data) {\n if (data === null)\n return false;\n if (YAML_DATE_REGEXP.exec(data) !== null)\n return true;\n if (YAML_TIMESTAMP_REGEXP.exec(data) !== null)\n return true;\n return false;\n}\nfunction constructYamlTimestamp(data) {\n var match, year, month, day, hour, minute, second, fraction = 0, delta = null, tz_hour, tz_minute, date;\n match = YAML_DATE_REGEXP.exec(data);\n if (match === null)\n match = YAML_TIMESTAMP_REGEXP.exec(data);\n if (match === null)\n throw new Error(\"Date resolve error\");\n year = +match[1];\n month = +match[2] - 1;\n day = +match[3];\n if (!match[4]) {\n return new Date(Date.UTC(year, month, day));\n }\n hour = +match[4];\n minute = +match[5];\n second = +match[6];\n if (match[7]) {\n fraction = match[7].slice(0, 3);\n while (fraction.length < 3) {\n fraction += \"0\";\n }\n fraction = +fraction;\n }\n if (match[9]) {\n tz_hour = +match[10];\n tz_minute = +(match[11] || 0);\n delta = (tz_hour * 60 + tz_minute) * 6e4;\n if (match[9] === \"-\")\n delta = -delta;\n }\n date = new Date(Date.UTC(year, month, day, hour, minute, second, fraction));\n if (delta)\n date.setTime(date.getTime() - delta);\n return date;\n}\nfunction representYamlTimestamp(object) {\n return object.toISOString();\n}\nvar timestamp = new type(\"tag:yaml.org,2002:timestamp\", {\n kind: \"scalar\",\n resolve: resolveYamlTimestamp,\n construct: constructYamlTimestamp,\n instanceOf: Date,\n represent: representYamlTimestamp\n});\nfunction resolveYamlMerge(data) {\n return data === \"<<\" || data === null;\n}\nvar merge = new type(\"tag:yaml.org,2002:merge\", {\n kind: \"scalar\",\n resolve: resolveYamlMerge\n});\nvar BASE64_MAP = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\\n\\r\";\nfunction resolveYamlBinary(data) {\n if (data === null)\n return false;\n var code, idx, bitlen = 0, max = data.length, map2 = BASE64_MAP;\n for (idx = 0; idx < max; idx++) {\n code = map2.indexOf(data.charAt(idx));\n if (code > 64)\n continue;\n if (code < 0)\n return false;\n bitlen += 6;\n }\n return bitlen % 8 === 0;\n}\nfunction constructYamlBinary(data) {\n var idx, tailbits, input = data.replace(/[\\r\\n=]/g, \"\"), max = input.length, map2 = BASE64_MAP, bits = 0, result = [];\n for (idx = 0; idx < max; idx++) {\n if (idx % 4 === 0 && idx) {\n result.push(bits >> 16 & 255);\n result.push(bits >> 8 & 255);\n result.push(bits & 255);\n }\n bits = bits << 6 | map2.indexOf(input.charAt(idx));\n }\n tailbits = max % 4 * 6;\n if (tailbits === 0) {\n result.push(bits >> 16 & 255);\n result.push(bits >> 8 & 255);\n result.push(bits & 255);\n } else if (tailbits === 18) {\n result.push(bits >> 10 & 255);\n result.push(bits >> 2 & 255);\n } else if (tailbits === 12) {\n result.push(bits >> 4 & 255);\n }\n return new Uint8Array(result);\n}\nfunction representYamlBinary(object) {\n var result = \"\", bits = 0, idx, tail, max = object.length, map2 = BASE64_MAP;\n for (idx = 0; idx < max; idx++) {\n if (idx % 3 === 0 && idx) {\n result += map2[bits >> 18 & 63];\n result += map2[bits >> 12 & 63];\n result += map2[bits >> 6 & 63];\n result += map2[bits & 63];\n }\n bits = (bits << 8) + object[idx];\n }\n tail = max % 3;\n if (tail === 0) {\n result += map2[bits >> 18 & 63];\n result += map2[bits >> 12 & 63];\n result += map2[bits >> 6 & 63];\n result += map2[bits & 63];\n } else if (tail === 2) {\n result += map2[bits >> 10 & 63];\n result += map2[bits >> 4 & 63];\n result += map2[bits << 2 & 63];\n result += map2[64];\n } else if (tail === 1) {\n result += map2[bits >> 2 & 63];\n result += map2[bits << 4 & 63];\n result += map2[64];\n result += map2[64];\n }\n return result;\n}\nfunction isBinary(obj) {\n return Object.prototype.toString.call(obj) === \"[object Uint8Array]\";\n}\nvar binary = new type(\"tag:yaml.org,2002:binary\", {\n kind: \"scalar\",\n resolve: resolveYamlBinary,\n construct: constructYamlBinary,\n predicate: isBinary,\n represent: representYamlBinary\n});\nvar _hasOwnProperty$3 = Object.prototype.hasOwnProperty;\nvar _toString$2 = Object.prototype.toString;\nfunction resolveYamlOmap(data) {\n if (data === null)\n return true;\n var objectKeys = [], index, length, pair, pairKey, pairHasKey, object = data;\n for (index = 0, length = object.length; index < length; index += 1) {\n pair = object[index];\n pairHasKey = false;\n if (_toString$2.call(pair) !== \"[object Object]\")\n return false;\n for (pairKey in pair) {\n if (_hasOwnProperty$3.call(pair, pairKey)) {\n if (!pairHasKey)\n pairHasKey = true;\n else\n return false;\n }\n }\n if (!pairHasKey)\n return false;\n if (objectKeys.indexOf(pairKey) === -1)\n objectKeys.push(pairKey);\n else\n return false;\n }\n return true;\n}\nfunction constructYamlOmap(data) {\n return data !== null ? data : [];\n}\nvar omap = new type(\"tag:yaml.org,2002:omap\", {\n kind: \"sequence\",\n resolve: resolveYamlOmap,\n construct: constructYamlOmap\n});\nvar _toString$1 = Object.prototype.toString;\nfunction resolveYamlPairs(data) {\n if (data === null)\n return true;\n var index, length, pair, keys, result, object = data;\n result = new Array(object.length);\n for (index = 0, length = object.length; index < length; index += 1) {\n pair = object[index];\n if (_toString$1.call(pair) !== \"[object Object]\")\n return false;\n keys = Object.keys(pair);\n if (keys.length !== 1)\n return false;\n result[index] = [keys[0], pair[keys[0]]];\n }\n return true;\n}\nfunction constructYamlPairs(data) {\n if (data === null)\n return [];\n var index, length, pair, keys, result, object = data;\n result = new Array(object.length);\n for (index = 0, length = object.length; index < length; index += 1) {\n pair = object[index];\n keys = Object.keys(pair);\n result[index] = [keys[0], pair[keys[0]]];\n }\n return result;\n}\nvar pairs = new type(\"tag:yaml.org,2002:pairs\", {\n kind: \"sequence\",\n resolve: resolveYamlPairs,\n construct: constructYamlPairs\n});\nvar _hasOwnProperty$2 = Object.prototype.hasOwnProperty;\nfunction resolveYamlSet(data) {\n if (data === null)\n return true;\n var key, object = data;\n for (key in object) {\n if (_hasOwnProperty$2.call(object, key)) {\n if (object[key] !== null)\n return false;\n }\n }\n return true;\n}\nfunction constructYamlSet(data) {\n return data !== null ? data : {};\n}\nvar set = new type(\"tag:yaml.org,2002:set\", {\n kind: \"mapping\",\n resolve: resolveYamlSet,\n construct: constructYamlSet\n});\nvar _default = core.extend({\n implicit: [\n timestamp,\n merge\n ],\n explicit: [\n binary,\n omap,\n pairs,\n set\n ]\n});\nvar _hasOwnProperty$1 = Object.prototype.hasOwnProperty;\nvar CONTEXT_FLOW_IN = 1;\nvar CONTEXT_FLOW_OUT = 2;\nvar CONTEXT_BLOCK_IN = 3;\nvar CONTEXT_BLOCK_OUT = 4;\nvar CHOMPING_CLIP = 1;\nvar CHOMPING_STRIP = 2;\nvar CHOMPING_KEEP = 3;\nvar PATTERN_NON_PRINTABLE = /[\\x00-\\x08\\x0B\\x0C\\x0E-\\x1F\\x7F-\\x84\\x86-\\x9F\\uFFFE\\uFFFF]|[\\uD800-\\uDBFF](?![\\uDC00-\\uDFFF])|(?:[^\\uD800-\\uDBFF]|^)[\\uDC00-\\uDFFF]/;\nvar PATTERN_NON_ASCII_LINE_BREAKS = /[\\x85\\u2028\\u2029]/;\nvar PATTERN_FLOW_INDICATORS = /[,\\[\\]\\{\\}]/;\nvar PATTERN_TAG_HANDLE = /^(?:!|!!|![a-z\\-]+!)$/i;\nvar PATTERN_TAG_URI = /^(?:!|[^,\\[\\]\\{\\}])(?:%[0-9a-f]{2}|[0-9a-z\\-#;\\/\\?:@&=\\+\\$,_\\.!~\\*'\\(\\)\\[\\]])*$/i;\nfunction _class(obj) {\n return Object.prototype.toString.call(obj);\n}\nfunction is_EOL(c) {\n return c === 10 || c === 13;\n}\nfunction is_WHITE_SPACE(c) {\n return c === 9 || c === 32;\n}\nfunction is_WS_OR_EOL(c) {\n return c === 9 || c === 32 || c === 10 || c === 13;\n}\nfunction is_FLOW_INDICATOR(c) {\n return c === 44 || c === 91 || c === 93 || c === 123 || c === 125;\n}\nfunction fromHexCode(c) {\n var lc;\n if (48 <= c && c <= 57) {\n return c - 48;\n }\n lc = c | 32;\n if (97 <= lc && lc <= 102) {\n return lc - 97 + 10;\n }\n return -1;\n}\nfunction escapedHexLen(c) {\n if (c === 120) {\n return 2;\n }\n if (c === 117) {\n return 4;\n }\n if (c === 85) {\n return 8;\n }\n return 0;\n}\nfunction fromDecimalCode(c) {\n if (48 <= c && c <= 57) {\n return c - 48;\n }\n return -1;\n}\nfunction simpleEscapeSequence(c) {\n return c === 48 ? \"\\0\" : c === 97 ? \"\\x07\" : c === 98 ? \"\\b\" : c === 116 ? \"\t\" : c === 9 ? \"\t\" : c === 110 ? \"\\n\" : c === 118 ? \"\\v\" : c === 102 ? \"\\f\" : c === 114 ? \"\\r\" : c === 101 ? \"\\x1B\" : c === 32 ? \" \" : c === 34 ? '\"' : c === 47 ? \"/\" : c === 92 ? \"\\\\\" : c === 78 ? \"\u0085\" : c === 95 ? \"\u00A0\" : c === 76 ? \"\\u2028\" : c === 80 ? \"\\u2029\" : \"\";\n}\nfunction charFromCodepoint(c) {\n if (c <= 65535) {\n return String.fromCharCode(c);\n }\n return String.fromCharCode(\n (c - 65536 >> 10) + 55296,\n (c - 65536 & 1023) + 56320\n );\n}\nvar simpleEscapeCheck = new Array(256);\nvar simpleEscapeMap = new Array(256);\nfor (var i = 0; i < 256; i++) {\n simpleEscapeCheck[i] = simpleEscapeSequence(i) ? 1 : 0;\n simpleEscapeMap[i] = simpleEscapeSequence(i);\n}\nfunction State$1(input, options) {\n this.input = input;\n this.filename = options[\"filename\"] || null;\n this.schema = options[\"schema\"] || _default;\n this.onWarning = options[\"onWarning\"] || null;\n this.legacy = options[\"legacy\"] || false;\n this.json = options[\"json\"] || false;\n this.listener = options[\"listener\"] || null;\n this.implicitTypes = this.schema.compiledImplicit;\n this.typeMap = this.schema.compiledTypeMap;\n this.length = input.length;\n this.position = 0;\n this.line = 0;\n this.lineStart = 0;\n this.lineIndent = 0;\n this.firstTabInLine = -1;\n this.documents = [];\n}\nfunction generateError(state2, message) {\n var mark = {\n name: state2.filename,\n buffer: state2.input.slice(0, -1),\n // omit trailing \\0\n position: state2.position,\n line: state2.line,\n column: state2.position - state2.lineStart\n };\n mark.snippet = snippet(mark);\n return new exception(message, mark);\n}\nfunction throwError(state2, message) {\n throw generateError(state2, message);\n}\nfunction throwWarning(state2, message) {\n if (state2.onWarning) {\n state2.onWarning.call(null, generateError(state2, message));\n }\n}\nvar directiveHandlers = {\n YAML: function handleYamlDirective(state2, name, args) {\n var match, major, minor;\n if (state2.version !== null) {\n throwError(state2, \"duplication of %YAML directive\");\n }\n if (args.length !== 1) {\n throwError(state2, \"YAML directive accepts exactly one argument\");\n }\n match = /^([0-9]+)\\.([0-9]+)$/.exec(args[0]);\n if (match === null) {\n throwError(state2, \"ill-formed argument of the YAML directive\");\n }\n major = parseInt(match[1], 10);\n minor = parseInt(match[2], 10);\n if (major !== 1) {\n throwError(state2, \"unacceptable YAML version of the document\");\n }\n state2.version = args[0];\n state2.checkLineBreaks = minor < 2;\n if (minor !== 1 && minor !== 2) {\n throwWarning(state2, \"unsupported YAML version of the document\");\n }\n },\n TAG: function handleTagDirective(state2, name, args) {\n var handle, prefix;\n if (args.length !== 2) {\n throwError(state2, \"TAG directive accepts exactly two arguments\");\n }\n handle = args[0];\n prefix = args[1];\n if (!PATTERN_TAG_HANDLE.test(handle)) {\n throwError(state2, \"ill-formed tag handle (first argument) of the TAG directive\");\n }\n if (_hasOwnProperty$1.call(state2.tagMap, handle)) {\n throwError(state2, 'there is a previously declared suffix for \"' + handle + '\" tag handle');\n }\n if (!PATTERN_TAG_URI.test(prefix)) {\n throwError(state2, \"ill-formed tag prefix (second argument) of the TAG directive\");\n }\n try {\n prefix = decodeURIComponent(prefix);\n } catch (err) {\n throwError(state2, \"tag prefix is malformed: \" + prefix);\n }\n state2.tagMap[handle] = prefix;\n }\n};\nfunction captureSegment(state2, start, end, checkJson) {\n var _position, _length, _character, _result;\n if (start < end) {\n _result = state2.input.slice(start, end);\n if (checkJson) {\n for (_position = 0, _length = _result.length; _position < _length; _position += 1) {\n _character = _result.charCodeAt(_position);\n if (!(_character === 9 || 32 <= _character && _character <= 1114111)) {\n throwError(state2, \"expected valid JSON character\");\n }\n }\n } else if (PATTERN_NON_PRINTABLE.test(_result)) {\n throwError(state2, \"the stream contains non-printable characters\");\n }\n state2.result += _result;\n }\n}\nfunction mergeMappings(state2, destination, source, overridableKeys) {\n var sourceKeys, key, index, quantity;\n if (!common.isObject(source)) {\n throwError(state2, \"cannot merge mappings; the provided source object is unacceptable\");\n }\n sourceKeys = Object.keys(source);\n for (index = 0, quantity = sourceKeys.length; index < quantity; index += 1) {\n key = sourceKeys[index];\n if (!_hasOwnProperty$1.call(destination, key)) {\n destination[key] = source[key];\n overridableKeys[key] = true;\n }\n }\n}\nfunction storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, valueNode, startLine, startLineStart, startPos) {\n var index, quantity;\n if (Array.isArray(keyNode)) {\n keyNode = Array.prototype.slice.call(keyNode);\n for (index = 0, quantity = keyNode.length; index < quantity; index += 1) {\n if (Array.isArray(keyNode[index])) {\n throwError(state2, \"nested arrays are not supported inside keys\");\n }\n if (typeof keyNode === \"object\" && _class(keyNode[index]) === \"[object Object]\") {\n keyNode[index] = \"[object Object]\";\n }\n }\n }\n if (typeof keyNode === \"object\" && _class(keyNode) === \"[object Object]\") {\n keyNode = \"[object Object]\";\n }\n keyNode = String(keyNode);\n if (_result === null) {\n _result = {};\n }\n if (keyTag === \"tag:yaml.org,2002:merge\") {\n if (Array.isArray(valueNode)) {\n for (index = 0, quantity = valueNode.length; index < quantity; index += 1) {\n mergeMappings(state2, _result, valueNode[index], overridableKeys);\n }\n } else {\n mergeMappings(state2, _result, valueNode, overridableKeys);\n }\n } else {\n if (!state2.json && !_hasOwnProperty$1.call(overridableKeys, keyNode) && _hasOwnProperty$1.call(_result, keyNode)) {\n state2.line = startLine || state2.line;\n state2.lineStart = startLineStart || state2.lineStart;\n state2.position = startPos || state2.position;\n throwError(state2, \"duplicated mapping key\");\n }\n if (keyNode === \"__proto__\") {\n Object.defineProperty(_result, keyNode, {\n configurable: true,\n enumerable: true,\n writable: true,\n value: valueNode\n });\n } else {\n _result[keyNode] = valueNode;\n }\n delete overridableKeys[keyNode];\n }\n return _result;\n}\nfunction readLineBreak(state2) {\n var ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 10) {\n state2.position++;\n } else if (ch === 13) {\n state2.position++;\n if (state2.input.charCodeAt(state2.position) === 10) {\n state2.position++;\n }\n } else {\n throwError(state2, \"a line break is expected\");\n }\n state2.line += 1;\n state2.lineStart = state2.position;\n state2.firstTabInLine = -1;\n}\nfunction skipSeparationSpace(state2, allowComments, checkIndent) {\n var lineBreaks = 0, ch = state2.input.charCodeAt(state2.position);\n while (ch !== 0) {\n while (is_WHITE_SPACE(ch)) {\n if (ch === 9 && state2.firstTabInLine === -1) {\n state2.firstTabInLine = state2.position;\n }\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (allowComments && ch === 35) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (ch !== 10 && ch !== 13 && ch !== 0);\n }\n if (is_EOL(ch)) {\n readLineBreak(state2);\n ch = state2.input.charCodeAt(state2.position);\n lineBreaks++;\n state2.lineIndent = 0;\n while (ch === 32) {\n state2.lineIndent++;\n ch = state2.input.charCodeAt(++state2.position);\n }\n } else {\n break;\n }\n }\n if (checkIndent !== -1 && lineBreaks !== 0 && state2.lineIndent < checkIndent) {\n throwWarning(state2, \"deficient indentation\");\n }\n return lineBreaks;\n}\nfunction testDocumentSeparator(state2) {\n var _position = state2.position, ch;\n ch = state2.input.charCodeAt(_position);\n if ((ch === 45 || ch === 46) && ch === state2.input.charCodeAt(_position + 1) && ch === state2.input.charCodeAt(_position + 2)) {\n _position += 3;\n ch = state2.input.charCodeAt(_position);\n if (ch === 0 || is_WS_OR_EOL(ch)) {\n return true;\n }\n }\n return false;\n}\nfunction writeFoldedLines(state2, count) {\n if (count === 1) {\n state2.result += \" \";\n } else if (count > 1) {\n state2.result += common.repeat(\"\\n\", count - 1);\n }\n}\nfunction readPlainScalar(state2, nodeIndent, withinFlowCollection) {\n var preceding, following, captureStart, captureEnd, hasPendingContent, _line, _lineStart, _lineIndent, _kind = state2.kind, _result = state2.result, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (is_WS_OR_EOL(ch) || is_FLOW_INDICATOR(ch) || ch === 35 || ch === 38 || ch === 42 || ch === 33 || ch === 124 || ch === 62 || ch === 39 || ch === 34 || ch === 37 || ch === 64 || ch === 96) {\n return false;\n }\n if (ch === 63 || ch === 45) {\n following = state2.input.charCodeAt(state2.position + 1);\n if (is_WS_OR_EOL(following) || withinFlowCollection && is_FLOW_INDICATOR(following)) {\n return false;\n }\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n captureStart = captureEnd = state2.position;\n hasPendingContent = false;\n while (ch !== 0) {\n if (ch === 58) {\n following = state2.input.charCodeAt(state2.position + 1);\n if (is_WS_OR_EOL(following) || withinFlowCollection && is_FLOW_INDICATOR(following)) {\n break;\n }\n } else if (ch === 35) {\n preceding = state2.input.charCodeAt(state2.position - 1);\n if (is_WS_OR_EOL(preceding)) {\n break;\n }\n } else if (state2.position === state2.lineStart && testDocumentSeparator(state2) || withinFlowCollection && is_FLOW_INDICATOR(ch)) {\n break;\n } else if (is_EOL(ch)) {\n _line = state2.line;\n _lineStart = state2.lineStart;\n _lineIndent = state2.lineIndent;\n skipSeparationSpace(state2, false, -1);\n if (state2.lineIndent >= nodeIndent) {\n hasPendingContent = true;\n ch = state2.input.charCodeAt(state2.position);\n continue;\n } else {\n state2.position = captureEnd;\n state2.line = _line;\n state2.lineStart = _lineStart;\n state2.lineIndent = _lineIndent;\n break;\n }\n }\n if (hasPendingContent) {\n captureSegment(state2, captureStart, captureEnd, false);\n writeFoldedLines(state2, state2.line - _line);\n captureStart = captureEnd = state2.position;\n hasPendingContent = false;\n }\n if (!is_WHITE_SPACE(ch)) {\n captureEnd = state2.position + 1;\n }\n ch = state2.input.charCodeAt(++state2.position);\n }\n captureSegment(state2, captureStart, captureEnd, false);\n if (state2.result) {\n return true;\n }\n state2.kind = _kind;\n state2.result = _result;\n return false;\n}\nfunction readSingleQuotedScalar(state2, nodeIndent) {\n var ch, captureStart, captureEnd;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 39) {\n return false;\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n state2.position++;\n captureStart = captureEnd = state2.position;\n while ((ch = state2.input.charCodeAt(state2.position)) !== 0) {\n if (ch === 39) {\n captureSegment(state2, captureStart, state2.position, true);\n ch = state2.input.charCodeAt(++state2.position);\n if (ch === 39) {\n captureStart = state2.position;\n state2.position++;\n captureEnd = state2.position;\n } else {\n return true;\n }\n } else if (is_EOL(ch)) {\n captureSegment(state2, captureStart, captureEnd, true);\n writeFoldedLines(state2, skipSeparationSpace(state2, false, nodeIndent));\n captureStart = captureEnd = state2.position;\n } else if (state2.position === state2.lineStart && testDocumentSeparator(state2)) {\n throwError(state2, \"unexpected end of the document within a single quoted scalar\");\n } else {\n state2.position++;\n captureEnd = state2.position;\n }\n }\n throwError(state2, \"unexpected end of the stream within a single quoted scalar\");\n}\nfunction readDoubleQuotedScalar(state2, nodeIndent) {\n var captureStart, captureEnd, hexLength, hexResult, tmp, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 34) {\n return false;\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n state2.position++;\n captureStart = captureEnd = state2.position;\n while ((ch = state2.input.charCodeAt(state2.position)) !== 0) {\n if (ch === 34) {\n captureSegment(state2, captureStart, state2.position, true);\n state2.position++;\n return true;\n } else if (ch === 92) {\n captureSegment(state2, captureStart, state2.position, true);\n ch = state2.input.charCodeAt(++state2.position);\n if (is_EOL(ch)) {\n skipSeparationSpace(state2, false, nodeIndent);\n } else if (ch < 256 && simpleEscapeCheck[ch]) {\n state2.result += simpleEscapeMap[ch];\n state2.position++;\n } else if ((tmp = escapedHexLen(ch)) > 0) {\n hexLength = tmp;\n hexResult = 0;\n for (; hexLength > 0; hexLength--) {\n ch = state2.input.charCodeAt(++state2.position);\n if ((tmp = fromHexCode(ch)) >= 0) {\n hexResult = (hexResult << 4) + tmp;\n } else {\n throwError(state2, \"expected hexadecimal character\");\n }\n }\n state2.result += charFromCodepoint(hexResult);\n state2.position++;\n } else {\n throwError(state2, \"unknown escape sequence\");\n }\n captureStart = captureEnd = state2.position;\n } else if (is_EOL(ch)) {\n captureSegment(state2, captureStart, captureEnd, true);\n writeFoldedLines(state2, skipSeparationSpace(state2, false, nodeIndent));\n captureStart = captureEnd = state2.position;\n } else if (state2.position === state2.lineStart && testDocumentSeparator(state2)) {\n throwError(state2, \"unexpected end of the document within a double quoted scalar\");\n } else {\n state2.position++;\n captureEnd = state2.position;\n }\n }\n throwError(state2, \"unexpected end of the stream within a double quoted scalar\");\n}\nfunction readFlowCollection(state2, nodeIndent) {\n var readNext = true, _line, _lineStart, _pos, _tag = state2.tag, _result, _anchor = state2.anchor, following, terminator, isPair, isExplicitPair, isMapping, overridableKeys = /* @__PURE__ */ Object.create(null), keyNode, keyTag, valueNode, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 91) {\n terminator = 93;\n isMapping = false;\n _result = [];\n } else if (ch === 123) {\n terminator = 125;\n isMapping = true;\n _result = {};\n } else {\n return false;\n }\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = _result;\n }\n ch = state2.input.charCodeAt(++state2.position);\n while (ch !== 0) {\n skipSeparationSpace(state2, true, nodeIndent);\n ch = state2.input.charCodeAt(state2.position);\n if (ch === terminator) {\n state2.position++;\n state2.tag = _tag;\n state2.anchor = _anchor;\n state2.kind = isMapping ? \"mapping\" : \"sequence\";\n state2.result = _result;\n return true;\n } else if (!readNext) {\n throwError(state2, \"missed comma between flow collection entries\");\n } else if (ch === 44) {\n throwError(state2, \"expected the node content, but found ','\");\n }\n keyTag = keyNode = valueNode = null;\n isPair = isExplicitPair = false;\n if (ch === 63) {\n following = state2.input.charCodeAt(state2.position + 1);\n if (is_WS_OR_EOL(following)) {\n isPair = isExplicitPair = true;\n state2.position++;\n skipSeparationSpace(state2, true, nodeIndent);\n }\n }\n _line = state2.line;\n _lineStart = state2.lineStart;\n _pos = state2.position;\n composeNode(state2, nodeIndent, CONTEXT_FLOW_IN, false, true);\n keyTag = state2.tag;\n keyNode = state2.result;\n skipSeparationSpace(state2, true, nodeIndent);\n ch = state2.input.charCodeAt(state2.position);\n if ((isExplicitPair || state2.line === _line) && ch === 58) {\n isPair = true;\n ch = state2.input.charCodeAt(++state2.position);\n skipSeparationSpace(state2, true, nodeIndent);\n composeNode(state2, nodeIndent, CONTEXT_FLOW_IN, false, true);\n valueNode = state2.result;\n }\n if (isMapping) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, valueNode, _line, _lineStart, _pos);\n } else if (isPair) {\n _result.push(storeMappingPair(state2, null, overridableKeys, keyTag, keyNode, valueNode, _line, _lineStart, _pos));\n } else {\n _result.push(keyNode);\n }\n skipSeparationSpace(state2, true, nodeIndent);\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 44) {\n readNext = true;\n ch = state2.input.charCodeAt(++state2.position);\n } else {\n readNext = false;\n }\n }\n throwError(state2, \"unexpected end of the stream within a flow collection\");\n}\nfunction readBlockScalar(state2, nodeIndent) {\n var captureStart, folding, chomping = CHOMPING_CLIP, didReadContent = false, detectedIndent = false, textIndent = nodeIndent, emptyLines = 0, atMoreIndented = false, tmp, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch === 124) {\n folding = false;\n } else if (ch === 62) {\n folding = true;\n } else {\n return false;\n }\n state2.kind = \"scalar\";\n state2.result = \"\";\n while (ch !== 0) {\n ch = state2.input.charCodeAt(++state2.position);\n if (ch === 43 || ch === 45) {\n if (CHOMPING_CLIP === chomping) {\n chomping = ch === 43 ? CHOMPING_KEEP : CHOMPING_STRIP;\n } else {\n throwError(state2, \"repeat of a chomping mode identifier\");\n }\n } else if ((tmp = fromDecimalCode(ch)) >= 0) {\n if (tmp === 0) {\n throwError(state2, \"bad explicit indentation width of a block scalar; it cannot be less than one\");\n } else if (!detectedIndent) {\n textIndent = nodeIndent + tmp - 1;\n detectedIndent = true;\n } else {\n throwError(state2, \"repeat of an indentation width identifier\");\n }\n } else {\n break;\n }\n }\n if (is_WHITE_SPACE(ch)) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (is_WHITE_SPACE(ch));\n if (ch === 35) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (!is_EOL(ch) && ch !== 0);\n }\n }\n while (ch !== 0) {\n readLineBreak(state2);\n state2.lineIndent = 0;\n ch = state2.input.charCodeAt(state2.position);\n while ((!detectedIndent || state2.lineIndent < textIndent) && ch === 32) {\n state2.lineIndent++;\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (!detectedIndent && state2.lineIndent > textIndent) {\n textIndent = state2.lineIndent;\n }\n if (is_EOL(ch)) {\n emptyLines++;\n continue;\n }\n if (state2.lineIndent < textIndent) {\n if (chomping === CHOMPING_KEEP) {\n state2.result += common.repeat(\"\\n\", didReadContent ? 1 + emptyLines : emptyLines);\n } else if (chomping === CHOMPING_CLIP) {\n if (didReadContent) {\n state2.result += \"\\n\";\n }\n }\n break;\n }\n if (folding) {\n if (is_WHITE_SPACE(ch)) {\n atMoreIndented = true;\n state2.result += common.repeat(\"\\n\", didReadContent ? 1 + emptyLines : emptyLines);\n } else if (atMoreIndented) {\n atMoreIndented = false;\n state2.result += common.repeat(\"\\n\", emptyLines + 1);\n } else if (emptyLines === 0) {\n if (didReadContent) {\n state2.result += \" \";\n }\n } else {\n state2.result += common.repeat(\"\\n\", emptyLines);\n }\n } else {\n state2.result += common.repeat(\"\\n\", didReadContent ? 1 + emptyLines : emptyLines);\n }\n didReadContent = true;\n detectedIndent = true;\n emptyLines = 0;\n captureStart = state2.position;\n while (!is_EOL(ch) && ch !== 0) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n captureSegment(state2, captureStart, state2.position, false);\n }\n return true;\n}\nfunction readBlockSequence(state2, nodeIndent) {\n var _line, _tag = state2.tag, _anchor = state2.anchor, _result = [], following, detected = false, ch;\n if (state2.firstTabInLine !== -1)\n return false;\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = _result;\n }\n ch = state2.input.charCodeAt(state2.position);\n while (ch !== 0) {\n if (state2.firstTabInLine !== -1) {\n state2.position = state2.firstTabInLine;\n throwError(state2, \"tab characters must not be used in indentation\");\n }\n if (ch !== 45) {\n break;\n }\n following = state2.input.charCodeAt(state2.position + 1);\n if (!is_WS_OR_EOL(following)) {\n break;\n }\n detected = true;\n state2.position++;\n if (skipSeparationSpace(state2, true, -1)) {\n if (state2.lineIndent <= nodeIndent) {\n _result.push(null);\n ch = state2.input.charCodeAt(state2.position);\n continue;\n }\n }\n _line = state2.line;\n composeNode(state2, nodeIndent, CONTEXT_BLOCK_IN, false, true);\n _result.push(state2.result);\n skipSeparationSpace(state2, true, -1);\n ch = state2.input.charCodeAt(state2.position);\n if ((state2.line === _line || state2.lineIndent > nodeIndent) && ch !== 0) {\n throwError(state2, \"bad indentation of a sequence entry\");\n } else if (state2.lineIndent < nodeIndent) {\n break;\n }\n }\n if (detected) {\n state2.tag = _tag;\n state2.anchor = _anchor;\n state2.kind = \"sequence\";\n state2.result = _result;\n return true;\n }\n return false;\n}\nfunction readBlockMapping(state2, nodeIndent, flowIndent) {\n var following, allowCompact, _line, _keyLine, _keyLineStart, _keyPos, _tag = state2.tag, _anchor = state2.anchor, _result = {}, overridableKeys = /* @__PURE__ */ Object.create(null), keyTag = null, keyNode = null, valueNode = null, atExplicitKey = false, detected = false, ch;\n if (state2.firstTabInLine !== -1)\n return false;\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = _result;\n }\n ch = state2.input.charCodeAt(state2.position);\n while (ch !== 0) {\n if (!atExplicitKey && state2.firstTabInLine !== -1) {\n state2.position = state2.firstTabInLine;\n throwError(state2, \"tab characters must not be used in indentation\");\n }\n following = state2.input.charCodeAt(state2.position + 1);\n _line = state2.line;\n if ((ch === 63 || ch === 58) && is_WS_OR_EOL(following)) {\n if (ch === 63) {\n if (atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);\n keyTag = keyNode = valueNode = null;\n }\n detected = true;\n atExplicitKey = true;\n allowCompact = true;\n } else if (atExplicitKey) {\n atExplicitKey = false;\n allowCompact = true;\n } else {\n throwError(state2, \"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line\");\n }\n state2.position += 1;\n ch = following;\n } else {\n _keyLine = state2.line;\n _keyLineStart = state2.lineStart;\n _keyPos = state2.position;\n if (!composeNode(state2, flowIndent, CONTEXT_FLOW_OUT, false, true)) {\n break;\n }\n if (state2.line === _line) {\n ch = state2.input.charCodeAt(state2.position);\n while (is_WHITE_SPACE(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (ch === 58) {\n ch = state2.input.charCodeAt(++state2.position);\n if (!is_WS_OR_EOL(ch)) {\n throwError(state2, \"a whitespace character is expected after the key-value separator within a block mapping\");\n }\n if (atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);\n keyTag = keyNode = valueNode = null;\n }\n detected = true;\n atExplicitKey = false;\n allowCompact = false;\n keyTag = state2.tag;\n keyNode = state2.result;\n } else if (detected) {\n throwError(state2, \"can not read an implicit mapping pair; a colon is missed\");\n } else {\n state2.tag = _tag;\n state2.anchor = _anchor;\n return true;\n }\n } else if (detected) {\n throwError(state2, \"can not read a block mapping entry; a multiline key may not be an implicit key\");\n } else {\n state2.tag = _tag;\n state2.anchor = _anchor;\n return true;\n }\n }\n if (state2.line === _line || state2.lineIndent > nodeIndent) {\n if (atExplicitKey) {\n _keyLine = state2.line;\n _keyLineStart = state2.lineStart;\n _keyPos = state2.position;\n }\n if (composeNode(state2, nodeIndent, CONTEXT_BLOCK_OUT, true, allowCompact)) {\n if (atExplicitKey) {\n keyNode = state2.result;\n } else {\n valueNode = state2.result;\n }\n }\n if (!atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, valueNode, _keyLine, _keyLineStart, _keyPos);\n keyTag = keyNode = valueNode = null;\n }\n skipSeparationSpace(state2, true, -1);\n ch = state2.input.charCodeAt(state2.position);\n }\n if ((state2.line === _line || state2.lineIndent > nodeIndent) && ch !== 0) {\n throwError(state2, \"bad indentation of a mapping entry\");\n } else if (state2.lineIndent < nodeIndent) {\n break;\n }\n }\n if (atExplicitKey) {\n storeMappingPair(state2, _result, overridableKeys, keyTag, keyNode, null, _keyLine, _keyLineStart, _keyPos);\n }\n if (detected) {\n state2.tag = _tag;\n state2.anchor = _anchor;\n state2.kind = \"mapping\";\n state2.result = _result;\n }\n return detected;\n}\nfunction readTagProperty(state2) {\n var _position, isVerbatim = false, isNamed = false, tagHandle, tagName, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 33)\n return false;\n if (state2.tag !== null) {\n throwError(state2, \"duplication of a tag property\");\n }\n ch = state2.input.charCodeAt(++state2.position);\n if (ch === 60) {\n isVerbatim = true;\n ch = state2.input.charCodeAt(++state2.position);\n } else if (ch === 33) {\n isNamed = true;\n tagHandle = \"!!\";\n ch = state2.input.charCodeAt(++state2.position);\n } else {\n tagHandle = \"!\";\n }\n _position = state2.position;\n if (isVerbatim) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (ch !== 0 && ch !== 62);\n if (state2.position < state2.length) {\n tagName = state2.input.slice(_position, state2.position);\n ch = state2.input.charCodeAt(++state2.position);\n } else {\n throwError(state2, \"unexpected end of the stream within a verbatim tag\");\n }\n } else {\n while (ch !== 0 && !is_WS_OR_EOL(ch)) {\n if (ch === 33) {\n if (!isNamed) {\n tagHandle = state2.input.slice(_position - 1, state2.position + 1);\n if (!PATTERN_TAG_HANDLE.test(tagHandle)) {\n throwError(state2, \"named tag handle cannot contain such characters\");\n }\n isNamed = true;\n _position = state2.position + 1;\n } else {\n throwError(state2, \"tag suffix cannot contain exclamation marks\");\n }\n }\n ch = state2.input.charCodeAt(++state2.position);\n }\n tagName = state2.input.slice(_position, state2.position);\n if (PATTERN_FLOW_INDICATORS.test(tagName)) {\n throwError(state2, \"tag suffix cannot contain flow indicator characters\");\n }\n }\n if (tagName && !PATTERN_TAG_URI.test(tagName)) {\n throwError(state2, \"tag name cannot contain such characters: \" + tagName);\n }\n try {\n tagName = decodeURIComponent(tagName);\n } catch (err) {\n throwError(state2, \"tag name is malformed: \" + tagName);\n }\n if (isVerbatim) {\n state2.tag = tagName;\n } else if (_hasOwnProperty$1.call(state2.tagMap, tagHandle)) {\n state2.tag = state2.tagMap[tagHandle] + tagName;\n } else if (tagHandle === \"!\") {\n state2.tag = \"!\" + tagName;\n } else if (tagHandle === \"!!\") {\n state2.tag = \"tag:yaml.org,2002:\" + tagName;\n } else {\n throwError(state2, 'undeclared tag handle \"' + tagHandle + '\"');\n }\n return true;\n}\nfunction readAnchorProperty(state2) {\n var _position, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 38)\n return false;\n if (state2.anchor !== null) {\n throwError(state2, \"duplication of an anchor property\");\n }\n ch = state2.input.charCodeAt(++state2.position);\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch) && !is_FLOW_INDICATOR(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (state2.position === _position) {\n throwError(state2, \"name of an anchor node must contain at least one character\");\n }\n state2.anchor = state2.input.slice(_position, state2.position);\n return true;\n}\nfunction readAlias(state2) {\n var _position, alias, ch;\n ch = state2.input.charCodeAt(state2.position);\n if (ch !== 42)\n return false;\n ch = state2.input.charCodeAt(++state2.position);\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch) && !is_FLOW_INDICATOR(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (state2.position === _position) {\n throwError(state2, \"name of an alias node must contain at least one character\");\n }\n alias = state2.input.slice(_position, state2.position);\n if (!_hasOwnProperty$1.call(state2.anchorMap, alias)) {\n throwError(state2, 'unidentified alias \"' + alias + '\"');\n }\n state2.result = state2.anchorMap[alias];\n skipSeparationSpace(state2, true, -1);\n return true;\n}\nfunction composeNode(state2, parentIndent, nodeContext, allowToSeek, allowCompact) {\n var allowBlockStyles, allowBlockScalars, allowBlockCollections, indentStatus = 1, atNewLine = false, hasContent = false, typeIndex, typeQuantity, typeList, type2, flowIndent, blockIndent;\n if (state2.listener !== null) {\n state2.listener(\"open\", state2);\n }\n state2.tag = null;\n state2.anchor = null;\n state2.kind = null;\n state2.result = null;\n allowBlockStyles = allowBlockScalars = allowBlockCollections = CONTEXT_BLOCK_OUT === nodeContext || CONTEXT_BLOCK_IN === nodeContext;\n if (allowToSeek) {\n if (skipSeparationSpace(state2, true, -1)) {\n atNewLine = true;\n if (state2.lineIndent > parentIndent) {\n indentStatus = 1;\n } else if (state2.lineIndent === parentIndent) {\n indentStatus = 0;\n } else if (state2.lineIndent < parentIndent) {\n indentStatus = -1;\n }\n }\n }\n if (indentStatus === 1) {\n while (readTagProperty(state2) || readAnchorProperty(state2)) {\n if (skipSeparationSpace(state2, true, -1)) {\n atNewLine = true;\n allowBlockCollections = allowBlockStyles;\n if (state2.lineIndent > parentIndent) {\n indentStatus = 1;\n } else if (state2.lineIndent === parentIndent) {\n indentStatus = 0;\n } else if (state2.lineIndent < parentIndent) {\n indentStatus = -1;\n }\n } else {\n allowBlockCollections = false;\n }\n }\n }\n if (allowBlockCollections) {\n allowBlockCollections = atNewLine || allowCompact;\n }\n if (indentStatus === 1 || CONTEXT_BLOCK_OUT === nodeContext) {\n if (CONTEXT_FLOW_IN === nodeContext || CONTEXT_FLOW_OUT === nodeContext) {\n flowIndent = parentIndent;\n } else {\n flowIndent = parentIndent + 1;\n }\n blockIndent = state2.position - state2.lineStart;\n if (indentStatus === 1) {\n if (allowBlockCollections && (readBlockSequence(state2, blockIndent) || readBlockMapping(state2, blockIndent, flowIndent)) || readFlowCollection(state2, flowIndent)) {\n hasContent = true;\n } else {\n if (allowBlockScalars && readBlockScalar(state2, flowIndent) || readSingleQuotedScalar(state2, flowIndent) || readDoubleQuotedScalar(state2, flowIndent)) {\n hasContent = true;\n } else if (readAlias(state2)) {\n hasContent = true;\n if (state2.tag !== null || state2.anchor !== null) {\n throwError(state2, \"alias node should not have any properties\");\n }\n } else if (readPlainScalar(state2, flowIndent, CONTEXT_FLOW_IN === nodeContext)) {\n hasContent = true;\n if (state2.tag === null) {\n state2.tag = \"?\";\n }\n }\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n }\n } else if (indentStatus === 0) {\n hasContent = allowBlockCollections && readBlockSequence(state2, blockIndent);\n }\n }\n if (state2.tag === null) {\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n } else if (state2.tag === \"?\") {\n if (state2.result !== null && state2.kind !== \"scalar\") {\n throwError(state2, 'unacceptable node kind for ! tag; it should be \"scalar\", not \"' + state2.kind + '\"');\n }\n for (typeIndex = 0, typeQuantity = state2.implicitTypes.length; typeIndex < typeQuantity; typeIndex += 1) {\n type2 = state2.implicitTypes[typeIndex];\n if (type2.resolve(state2.result)) {\n state2.result = type2.construct(state2.result);\n state2.tag = type2.tag;\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n break;\n }\n }\n } else if (state2.tag !== \"!\") {\n if (_hasOwnProperty$1.call(state2.typeMap[state2.kind || \"fallback\"], state2.tag)) {\n type2 = state2.typeMap[state2.kind || \"fallback\"][state2.tag];\n } else {\n type2 = null;\n typeList = state2.typeMap.multi[state2.kind || \"fallback\"];\n for (typeIndex = 0, typeQuantity = typeList.length; typeIndex < typeQuantity; typeIndex += 1) {\n if (state2.tag.slice(0, typeList[typeIndex].tag.length) === typeList[typeIndex].tag) {\n type2 = typeList[typeIndex];\n break;\n }\n }\n }\n if (!type2) {\n throwError(state2, \"unknown tag !<\" + state2.tag + \">\");\n }\n if (state2.result !== null && type2.kind !== state2.kind) {\n throwError(state2, \"unacceptable node kind for !<\" + state2.tag + '> tag; it should be \"' + type2.kind + '\", not \"' + state2.kind + '\"');\n }\n if (!type2.resolve(state2.result, state2.tag)) {\n throwError(state2, \"cannot resolve a node with !<\" + state2.tag + \"> explicit tag\");\n } else {\n state2.result = type2.construct(state2.result, state2.tag);\n if (state2.anchor !== null) {\n state2.anchorMap[state2.anchor] = state2.result;\n }\n }\n }\n if (state2.listener !== null) {\n state2.listener(\"close\", state2);\n }\n return state2.tag !== null || state2.anchor !== null || hasContent;\n}\nfunction readDocument(state2) {\n var documentStart = state2.position, _position, directiveName, directiveArgs, hasDirectives = false, ch;\n state2.version = null;\n state2.checkLineBreaks = state2.legacy;\n state2.tagMap = /* @__PURE__ */ Object.create(null);\n state2.anchorMap = /* @__PURE__ */ Object.create(null);\n while ((ch = state2.input.charCodeAt(state2.position)) !== 0) {\n skipSeparationSpace(state2, true, -1);\n ch = state2.input.charCodeAt(state2.position);\n if (state2.lineIndent > 0 || ch !== 37) {\n break;\n }\n hasDirectives = true;\n ch = state2.input.charCodeAt(++state2.position);\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n directiveName = state2.input.slice(_position, state2.position);\n directiveArgs = [];\n if (directiveName.length < 1) {\n throwError(state2, \"directive name must not be less than one character in length\");\n }\n while (ch !== 0) {\n while (is_WHITE_SPACE(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n if (ch === 35) {\n do {\n ch = state2.input.charCodeAt(++state2.position);\n } while (ch !== 0 && !is_EOL(ch));\n break;\n }\n if (is_EOL(ch))\n break;\n _position = state2.position;\n while (ch !== 0 && !is_WS_OR_EOL(ch)) {\n ch = state2.input.charCodeAt(++state2.position);\n }\n directiveArgs.push(state2.input.slice(_position, state2.position));\n }\n if (ch !== 0)\n readLineBreak(state2);\n if (_hasOwnProperty$1.call(directiveHandlers, directiveName)) {\n directiveHandlers[directiveName](state2, directiveName, directiveArgs);\n } else {\n throwWarning(state2, 'unknown document directive \"' + directiveName + '\"');\n }\n }\n skipSeparationSpace(state2, true, -1);\n if (state2.lineIndent === 0 && state2.input.charCodeAt(state2.position) === 45 && state2.input.charCodeAt(state2.position + 1) === 45 && state2.input.charCodeAt(state2.position + 2) === 45) {\n state2.position += 3;\n skipSeparationSpace(state2, true, -1);\n } else if (hasDirectives) {\n throwError(state2, \"directives end mark is expected\");\n }\n composeNode(state2, state2.lineIndent - 1, CONTEXT_BLOCK_OUT, false, true);\n skipSeparationSpace(state2, true, -1);\n if (state2.checkLineBreaks && PATTERN_NON_ASCII_LINE_BREAKS.test(state2.input.slice(documentStart, state2.position))) {\n throwWarning(state2, \"non-ASCII line breaks are interpreted as content\");\n }\n state2.documents.push(state2.result);\n if (state2.position === state2.lineStart && testDocumentSeparator(state2)) {\n if (state2.input.charCodeAt(state2.position) === 46) {\n state2.position += 3;\n skipSeparationSpace(state2, true, -1);\n }\n return;\n }\n if (state2.position < state2.length - 1) {\n throwError(state2, \"end of the stream or a document separator is expected\");\n } else {\n return;\n }\n}\nfunction loadDocuments(input, options) {\n input = String(input);\n options = options || {};\n if (input.length !== 0) {\n if (input.charCodeAt(input.length - 1) !== 10 && input.charCodeAt(input.length - 1) !== 13) {\n input += \"\\n\";\n }\n if (input.charCodeAt(0) === 65279) {\n input = input.slice(1);\n }\n }\n var state2 = new State$1(input, options);\n var nullpos = input.indexOf(\"\\0\");\n if (nullpos !== -1) {\n state2.position = nullpos;\n throwError(state2, \"null byte is not allowed in input\");\n }\n state2.input += \"\\0\";\n while (state2.input.charCodeAt(state2.position) === 32) {\n state2.lineIndent += 1;\n state2.position += 1;\n }\n while (state2.position < state2.length - 1) {\n readDocument(state2);\n }\n return state2.documents;\n}\nfunction loadAll$1(input, iterator, options) {\n if (iterator !== null && typeof iterator === \"object\" && typeof options === \"undefined\") {\n options = iterator;\n iterator = null;\n }\n var documents = loadDocuments(input, options);\n if (typeof iterator !== \"function\") {\n return documents;\n }\n for (var index = 0, length = documents.length; index < length; index += 1) {\n iterator(documents[index]);\n }\n}\nfunction load$1(input, options) {\n var documents = loadDocuments(input, options);\n if (documents.length === 0) {\n return void 0;\n } else if (documents.length === 1) {\n return documents[0];\n }\n throw new exception(\"expected a single document in the stream, but found more\");\n}\nvar loadAll_1 = loadAll$1;\nvar load_1 = load$1;\nvar loader = {\n loadAll: loadAll_1,\n load: load_1\n};\nvar JSON_SCHEMA = json;\nvar load = loader.load;\nfunction extractFrontMatter(text) {\n const matches = text.match(frontMatterRegex);\n if (!matches) {\n return {\n text,\n metadata: {}\n };\n }\n let parsed = load(matches[1], {\n // To support config, we need JSON schema.\n // https://www.yaml.org/spec/1.2/spec.html#id2803231\n schema: JSON_SCHEMA\n }) ?? {};\n parsed = typeof parsed === \"object\" && !Array.isArray(parsed) ? parsed : {};\n const metadata = {};\n if (parsed.displayMode) {\n metadata.displayMode = parsed.displayMode.toString();\n }\n if (parsed.title) {\n metadata.title = parsed.title.toString();\n }\n if (parsed.config) {\n metadata.config = parsed.config;\n }\n return {\n text: text.slice(matches[0].length),\n metadata\n };\n}\nconst cleanupText = (code) => {\n return code.replace(/\\r\\n?/g, \"\\n\").replace(\n /<(\\w+)([^>]*)>/g,\n (match, tag, attributes) => \"<\" + tag + attributes.replace(/=\"([^\"]*)\"/g, \"='$1'\") + \">\"\n );\n};\nconst processFrontmatter = (code) => {\n const { text, metadata } = extractFrontMatter(code);\n const { displayMode, title, config: config2 = {} } = metadata;\n if (displayMode) {\n if (!config2.gantt) {\n config2.gantt = {};\n }\n config2.gantt.displayMode = displayMode;\n }\n return { title, config: config2, text };\n};\nconst processDirectives = (code) => {\n const initDirective = utils.detectInit(code) ?? {};\n const wrapDirectives = utils.detectDirective(code, \"wrap\");\n if (Array.isArray(wrapDirectives)) {\n initDirective.wrap = wrapDirectives.some(({ type: type2 }) => {\n });\n } else if ((wrapDirectives == null ? void 0 : wrapDirectives.type) === \"wrap\") {\n initDirective.wrap = true;\n }\n return {\n text: removeDirectives(code),\n directive: initDirective\n };\n};\nfunction preprocessDiagram(code) {\n const cleanedCode = cleanupText(code);\n const frontMatterResult = processFrontmatter(cleanedCode);\n const directiveResult = processDirectives(frontMatterResult.text);\n const config2 = cleanAndMerge(frontMatterResult.config, directiveResult.directive);\n code = cleanupComments(directiveResult.text);\n return {\n code,\n title: frontMatterResult.title,\n config: config2\n };\n}\nconst MAX_TEXTLENGTH = 5e4;\nconst MAX_TEXTLENGTH_EXCEEDED_MSG = \"graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa\";\nconst SECURITY_LVL_SANDBOX = \"sandbox\";\nconst SECURITY_LVL_LOOSE = \"loose\";\nconst XMLNS_SVG_STD = \"http://www.w3.org/2000/svg\";\nconst XMLNS_XLINK_STD = \"http://www.w3.org/1999/xlink\";\nconst XMLNS_XHTML_STD = \"http://www.w3.org/1999/xhtml\";\nconst IFRAME_WIDTH = \"100%\";\nconst IFRAME_HEIGHT = \"100%\";\nconst IFRAME_STYLES = \"border:0;margin:0;\";\nconst IFRAME_BODY_STYLE = \"margin:0\";\nconst IFRAME_SANDBOX_OPTS = \"allow-top-navigation-by-user-activation allow-popups\";\nconst IFRAME_NOT_SUPPORTED_MSG = 'The \"iframe\" tag is not supported by your browser.';\nconst DOMPURIFY_TAGS = [\"foreignobject\"];\nconst DOMPURIFY_ATTR = [\"dominant-baseline\"];\nfunction processAndSetConfigs(text) {\n const processed = preprocessDiagram(text);\n reset();\n addDirective(processed.config ?? {});\n return processed;\n}\nasync function parse$1(text, parseOptions) {\n addDiagrams();\n text = processAndSetConfigs(text).code;\n try {\n await getDiagramFromText(text);\n } catch (error) {\n if (parseOptions == null ? void 0 : parseOptions.suppressErrors) {\n return false;\n }\n throw error;\n }\n return true;\n}\nconst encodeEntities = function(text) {\n let txt = text;\n txt = txt.replace(/style.*:\\S*#.*;/g, function(s) {\n return s.substring(0, s.length - 1);\n });\n txt = txt.replace(/classDef.*:\\S*#.*;/g, function(s) {\n return s.substring(0, s.length - 1);\n });\n txt = txt.replace(/#\\w+;/g, function(s) {\n const innerTxt = s.substring(1, s.length - 1);\n const isInt = /^\\+?\\d+$/.test(innerTxt);\n if (isInt) {\n return \"\uFB02\u00B0\u00B0\" + innerTxt + \"\u00B6\u00DF\";\n } else {\n return \"\uFB02\u00B0\" + innerTxt + \"\u00B6\u00DF\";\n }\n });\n return txt;\n};\nconst decodeEntities = function(text) {\n return text.replace(/\uFB02\u00B0\u00B0/g, \"&#\").replace(/\uFB02\u00B0/g, \"&\").replace(/\u00B6\u00DF/g, \";\");\n};\nconst cssImportantStyles = (cssClass, element, cssClasses = []) => {\n return `\n.${cssClass} ${element} { ${cssClasses.join(\" !important; \")} !important; }`;\n};\nconst createCssStyles = (config2, classDefs = {}) => {\n var _a;\n let cssStyles = \"\";\n if (config2.themeCSS !== void 0) {\n cssStyles += `\n${config2.themeCSS}`;\n }\n if (config2.fontFamily !== void 0) {\n cssStyles += `\n:root { --mermaid-font-family: ${config2.fontFamily}}`;\n }\n if (config2.altFontFamily !== void 0) {\n cssStyles += `\n:root { --mermaid-alt-font-family: ${config2.altFontFamily}}`;\n }\n if (!isEmpty(classDefs)) {\n const htmlLabels = config2.htmlLabels || ((_a = config2.flowchart) == null ? void 0 : _a.htmlLabels);\n const cssHtmlElements = [\"> *\", \"span\"];\n const cssShapeElements = [\"rect\", \"polygon\", \"ellipse\", \"circle\", \"path\"];\n const cssElements = htmlLabels ? cssHtmlElements : cssShapeElements;\n for (const classId in classDefs) {\n const styleClassDef = classDefs[classId];\n if (!isEmpty(styleClassDef.styles)) {\n cssElements.forEach((cssElement) => {\n cssStyles += cssImportantStyles(styleClassDef.id, cssElement, styleClassDef.styles);\n });\n }\n if (!isEmpty(styleClassDef.textStyles)) {\n cssStyles += cssImportantStyles(styleClassDef.id, \"tspan\", styleClassDef.textStyles);\n }\n }\n }\n return cssStyles;\n};\nconst createUserStyles = (config2, graphType, classDefs, svgId) => {\n const userCSSstyles = createCssStyles(config2, classDefs);\n const allStyles = getStyles$1(graphType, userCSSstyles, config2.themeVariables);\n return serialize(compile(`${svgId}{${allStyles}}`), stringify);\n};\nconst cleanUpSvgCode = (svgCode = \"\", inSandboxMode, useArrowMarkerUrls) => {\n let cleanedUpSvg = svgCode;\n if (!useArrowMarkerUrls && !inSandboxMode) {\n cleanedUpSvg = cleanedUpSvg.replace(\n /marker-end=\"url\\([\\d+./:=?A-Za-z-]*?#/g,\n 'marker-end=\"url(#'\n );\n }\n cleanedUpSvg = decodeEntities(cleanedUpSvg);\n cleanedUpSvg = cleanedUpSvg.replace(/
      /g, \"
      \");\n return cleanedUpSvg;\n};\nconst putIntoIFrame = (svgCode = \"\", svgElement) => {\n var _a, _b;\n const height = ((_b = (_a = svgElement == null ? void 0 : svgElement.viewBox) == null ? void 0 : _a.baseVal) == null ? void 0 : _b.height) ? svgElement.viewBox.baseVal.height + \"px\" : IFRAME_HEIGHT;\n const base64encodedSrc = btoa('' + svgCode + \"\");\n return ``;\n};\nconst appendDivSvgG = (parentRoot, id2, enclosingDivId, divStyle, svgXlink) => {\n const enclosingDiv = parentRoot.append(\"div\");\n enclosingDiv.attr(\"id\", enclosingDivId);\n if (divStyle) {\n enclosingDiv.attr(\"style\", divStyle);\n }\n const svgNode = enclosingDiv.append(\"svg\").attr(\"id\", id2).attr(\"width\", \"100%\").attr(\"xmlns\", XMLNS_SVG_STD);\n if (svgXlink) {\n svgNode.attr(\"xmlns:xlink\", svgXlink);\n }\n svgNode.append(\"g\");\n return parentRoot;\n};\nfunction sandboxedIframe(parentNode, iFrameId) {\n return parentNode.append(\"iframe\").attr(\"id\", iFrameId).attr(\"style\", \"width: 100%; height: 100%;\").attr(\"sandbox\", \"\");\n}\nconst removeExistingElements = (doc, id2, divId, iFrameId) => {\n var _a, _b, _c;\n (_a = doc.getElementById(id2)) == null ? void 0 : _a.remove();\n (_b = doc.getElementById(divId)) == null ? void 0 : _b.remove();\n (_c = doc.getElementById(iFrameId)) == null ? void 0 : _c.remove();\n};\nconst render$1 = async function(id2, text, svgContainingElement) {\n var _a, _b, _c, _d, _e, _f;\n addDiagrams();\n const processed = processAndSetConfigs(text);\n text = processed.code;\n const config2 = getConfig$1();\n log$1.debug(config2);\n if (text.length > ((config2 == null ? void 0 : config2.maxTextSize) ?? MAX_TEXTLENGTH)) {\n text = MAX_TEXTLENGTH_EXCEEDED_MSG;\n }\n const idSelector = \"#\" + id2;\n const iFrameID = \"i\" + id2;\n const iFrameID_selector = \"#\" + iFrameID;\n const enclosingDivID = \"d\" + id2;\n const enclosingDivID_selector = \"#\" + enclosingDivID;\n let root = select(\"body\");\n const isSandboxed = config2.securityLevel === SECURITY_LVL_SANDBOX;\n const isLooseSecurityLevel = config2.securityLevel === SECURITY_LVL_LOOSE;\n const fontFamily = config2.fontFamily;\n if (svgContainingElement !== void 0) {\n if (svgContainingElement) {\n svgContainingElement.innerHTML = \"\";\n }\n if (isSandboxed) {\n const iframe = sandboxedIframe(select(svgContainingElement), iFrameID);\n root = select(iframe.nodes()[0].contentDocument.body);\n root.node().style.margin = 0;\n } else {\n root = select(svgContainingElement);\n }\n appendDivSvgG(root, id2, enclosingDivID, `font-family: ${fontFamily}`, XMLNS_XLINK_STD);\n } else {\n removeExistingElements(document, id2, enclosingDivID, iFrameID);\n if (isSandboxed) {\n const iframe = sandboxedIframe(select(\"body\"), iFrameID);\n root = select(iframe.nodes()[0].contentDocument.body);\n root.node().style.margin = 0;\n } else {\n root = select(\"body\");\n }\n appendDivSvgG(root, id2, enclosingDivID);\n }\n text = encodeEntities(text);\n let diag;\n let parseEncounteredException;\n try {\n diag = await getDiagramFromText(text, { title: processed.title });\n } catch (error) {\n diag = new Diagram(\"error\");\n parseEncounteredException = error;\n }\n const element = root.select(enclosingDivID_selector).node();\n const diagramType = diag.type;\n const svg = element.firstChild;\n const firstChild = svg.firstChild;\n const diagramClassDefs = (_b = (_a = diag.renderer).getClasses) == null ? void 0 : _b.call(_a, text, diag);\n const rules = createUserStyles(config2, diagramType, diagramClassDefs, idSelector);\n const style1 = document.createElement(\"style\");\n style1.innerHTML = rules;\n svg.insertBefore(style1, firstChild);\n try {\n await diag.renderer.draw(text, id2, version, diag);\n } catch (e) {\n errorRenderer.draw(text, id2, version);\n throw e;\n }\n const svgNode = root.select(`${enclosingDivID_selector} svg`);\n const a11yTitle = (_d = (_c = diag.db).getAccTitle) == null ? void 0 : _d.call(_c);\n const a11yDescr = (_f = (_e = diag.db).getAccDescription) == null ? void 0 : _f.call(_e);\n addA11yInfo(diagramType, svgNode, a11yTitle, a11yDescr);\n root.select(`[id=\"${id2}\"]`).selectAll(\"foreignobject > *\").attr(\"xmlns\", XMLNS_XHTML_STD);\n let svgCode = root.select(enclosingDivID_selector).node().innerHTML;\n log$1.debug(\"config.arrowMarkerAbsolute\", config2.arrowMarkerAbsolute);\n svgCode = cleanUpSvgCode(svgCode, isSandboxed, evaluate(config2.arrowMarkerAbsolute));\n if (isSandboxed) {\n const svgEl = root.select(enclosingDivID_selector + \" svg\").node();\n svgCode = putIntoIFrame(svgCode, svgEl);\n } else if (!isLooseSecurityLevel) {\n svgCode = DOMPurify.sanitize(svgCode, {\n ADD_TAGS: DOMPURIFY_TAGS,\n ADD_ATTR: DOMPURIFY_ATTR\n });\n }\n attachFunctions();\n if (parseEncounteredException) {\n throw parseEncounteredException;\n }\n const tmpElementSelector = isSandboxed ? iFrameID_selector : enclosingDivID_selector;\n const node = select(tmpElementSelector).node();\n if (node && \"remove\" in node) {\n node.remove();\n }\n return {\n svg: svgCode,\n bindFunctions: diag.db.bindFunctions\n };\n};\nfunction initialize$1(options = {}) {\n var _a;\n if ((options == null ? void 0 : options.fontFamily) && !((_a = options.themeVariables) == null ? void 0 : _a.fontFamily)) {\n if (!options.themeVariables) {\n options.themeVariables = {};\n }\n options.themeVariables.fontFamily = options.fontFamily;\n }\n saveConfigFromInitialize(options);\n if ((options == null ? void 0 : options.theme) && options.theme in theme) {\n options.themeVariables = theme[options.theme].getThemeVariables(\n options.themeVariables\n );\n } else if (options) {\n options.themeVariables = theme.default.getThemeVariables(options.themeVariables);\n }\n const config2 = typeof options === \"object\" ? setSiteConfig(options) : getSiteConfig();\n setLogLevel$1(config2.logLevel);\n addDiagrams();\n}\nfunction addA11yInfo(diagramType, svgNode, a11yTitle, a11yDescr) {\n setA11yDiagramInfo(svgNode, diagramType);\n addSVGa11yTitleDescription(svgNode, a11yTitle, a11yDescr, svgNode.attr(\"id\"));\n}\nconst mermaidAPI = Object.freeze({\n render: render$1,\n parse: parse$1,\n getDiagramFromText,\n initialize: initialize$1,\n getConfig: getConfig$1,\n setConfig: setConfig$1,\n getSiteConfig,\n updateSiteConfig,\n reset: () => {\n reset();\n },\n globalReset: () => {\n reset(defaultConfig$1);\n },\n defaultConfig: defaultConfig$1\n});\nsetLogLevel$1(getConfig$1().logLevel);\nreset(getConfig$1());\nconst loadRegisteredDiagrams = async () => {\n log$1.debug(`Loading registered diagrams`);\n const results = await Promise.allSettled(\n Object.entries(detectors).map(async ([key, { detector: detector2, loader: loader2 }]) => {\n if (loader2) {\n try {\n getDiagram(key);\n } catch (error) {\n try {\n const { diagram: diagram2, id: id2 } = await loader2();\n registerDiagram(id2, diagram2, detector2);\n } catch (err) {\n log$1.error(`Failed to load external diagram with key ${key}. Removing from detectors.`);\n delete detectors[key];\n throw err;\n }\n }\n }\n })\n );\n const failed = results.filter((result) => result.status === \"rejected\");\n if (failed.length > 0) {\n log$1.error(`Failed to load ${failed.length} external diagrams`);\n for (const res of failed) {\n log$1.error(res);\n }\n throw new Error(`Failed to load ${failed.length} external diagrams`);\n }\n};\nconst handleError = (error, errors, parseError) => {\n log$1.warn(error);\n if (isDetailedError(error)) {\n if (parseError) {\n parseError(error.str, error.hash);\n }\n errors.push({ ...error, message: error.str, error });\n } else {\n if (parseError) {\n parseError(error);\n }\n if (error instanceof Error) {\n errors.push({\n str: error.message,\n message: error.message,\n hash: error.name,\n error\n });\n }\n }\n};\nconst run = async function(options = {\n querySelector: \".mermaid\"\n}) {\n try {\n await runThrowsErrors(options);\n } catch (e) {\n if (isDetailedError(e)) {\n log$1.error(e.str);\n }\n if (mermaid.parseError) {\n mermaid.parseError(e);\n }\n if (!options.suppressErrors) {\n log$1.error(\"Use the suppressErrors option to suppress these errors\");\n throw e;\n }\n }\n};\nconst runThrowsErrors = async function({ postRenderCallback, querySelector, nodes } = {\n querySelector: \".mermaid\"\n}) {\n const conf = mermaidAPI.getConfig();\n log$1.debug(`${!postRenderCallback ? \"No \" : \"\"}Callback function found`);\n let nodesToProcess;\n if (nodes) {\n nodesToProcess = nodes;\n } else if (querySelector) {\n nodesToProcess = document.querySelectorAll(querySelector);\n } else {\n throw new Error(\"Nodes and querySelector are both undefined\");\n }\n log$1.debug(`Found ${nodesToProcess.length} diagrams`);\n if ((conf == null ? void 0 : conf.startOnLoad) !== void 0) {\n log$1.debug(\"Start On Load: \" + (conf == null ? void 0 : conf.startOnLoad));\n mermaidAPI.updateSiteConfig({ startOnLoad: conf == null ? void 0 : conf.startOnLoad });\n }\n const idGenerator = new utils.InitIDGenerator(conf.deterministicIds, conf.deterministicIDSeed);\n let txt;\n const errors = [];\n for (const element of Array.from(nodesToProcess)) {\n log$1.info(\"Rendering diagram: \" + element.id);\n /*! Check if previously processed */\n if (element.getAttribute(\"data-processed\")) {\n continue;\n }\n element.setAttribute(\"data-processed\", \"true\");\n const id2 = `mermaid-${idGenerator.next()}`;\n txt = element.innerHTML;\n txt = dedent(utils.entityDecode(txt)).trim().replace(//gi, \"
      \");\n const init2 = utils.detectInit(txt);\n if (init2) {\n log$1.debug(\"Detected early reinit: \", init2);\n }\n try {\n const { svg, bindFunctions } = await render(id2, txt, element);\n element.innerHTML = svg;\n if (postRenderCallback) {\n await postRenderCallback(id2);\n }\n if (bindFunctions) {\n bindFunctions(element);\n }\n } catch (error) {\n handleError(error, errors, mermaid.parseError);\n }\n }\n if (errors.length > 0) {\n throw errors[0];\n }\n};\nconst initialize = function(config2) {\n mermaidAPI.initialize(config2);\n};\nconst init = async function(config2, nodes, callback) {\n log$1.warn(\"mermaid.init is deprecated. Please use run instead.\");\n if (config2) {\n initialize(config2);\n }\n const runOptions = { postRenderCallback: callback, querySelector: \".mermaid\" };\n if (typeof nodes === \"string\") {\n runOptions.querySelector = nodes;\n } else if (nodes) {\n if (nodes instanceof HTMLElement) {\n runOptions.nodes = [nodes];\n } else {\n runOptions.nodes = nodes;\n }\n }\n await run(runOptions);\n};\nconst registerExternalDiagrams = async (diagrams2, {\n lazyLoad = true\n} = {}) => {\n registerLazyLoadedDiagrams(...diagrams2);\n if (lazyLoad === false) {\n await loadRegisteredDiagrams();\n }\n};\nconst contentLoaded = function() {\n if (mermaid.startOnLoad) {\n const { startOnLoad } = mermaidAPI.getConfig();\n if (startOnLoad) {\n mermaid.run().catch((err) => log$1.error(\"Mermaid failed to initialize\", err));\n }\n }\n};\nif (typeof document !== \"undefined\") {\n /*!\n * Wait for document loaded before starting the execution\n */\n window.addEventListener(\"load\", contentLoaded, false);\n}\nconst setParseErrorHandler = function(parseErrorHandler) {\n mermaid.parseError = parseErrorHandler;\n};\nconst executionQueue = [];\nlet executionQueueRunning = false;\nconst executeQueue = async () => {\n if (executionQueueRunning) {\n return;\n }\n executionQueueRunning = true;\n while (executionQueue.length > 0) {\n const f = executionQueue.shift();\n if (f) {\n try {\n await f();\n } catch (e) {\n log$1.error(\"Error executing queue\", e);\n }\n }\n }\n executionQueueRunning = false;\n};\nconst parse = async (text, parseOptions) => {\n return new Promise((resolve, reject) => {\n const performCall = () => new Promise((res, rej) => {\n mermaidAPI.parse(text, parseOptions).then(\n (r) => {\n res(r);\n resolve(r);\n },\n (e) => {\n var _a;\n log$1.error(\"Error parsing\", e);\n (_a = mermaid.parseError) == null ? void 0 : _a.call(mermaid, e);\n rej(e);\n reject(e);\n }\n );\n });\n executionQueue.push(performCall);\n executeQueue().catch(reject);\n });\n};\nconst render = (id2, text, container) => {\n return new Promise((resolve, reject) => {\n const performCall = () => new Promise((res, rej) => {\n mermaidAPI.render(id2, text, container).then(\n (r) => {\n res(r);\n resolve(r);\n },\n (e) => {\n var _a;\n log$1.error(\"Error parsing\", e);\n (_a = mermaid.parseError) == null ? void 0 : _a.call(mermaid, e);\n rej(e);\n reject(e);\n }\n );\n });\n executionQueue.push(performCall);\n executeQueue().catch(reject);\n });\n};\nconst mermaid = {\n startOnLoad: true,\n mermaidAPI,\n parse,\n render,\n init,\n run,\n registerExternalDiagrams,\n initialize,\n parseError: void 0,\n contentLoaded,\n setParseErrorHandler,\n detectType\n};\nexport {\n defaultConfig$2 as A,\n cleanAndMerge as B,\n parseFontSize as C,\n getThemeVariables$2 as D,\n getConfig$1 as E,\n addFunction as F,\n generateId as G,\n lineBreakRegex as H,\n defaultConfig as I,\n decodeEntities as J,\n commonDb as K,\n mermaid as L,\n ZERO_WIDTH_SPACE as Z,\n getAccDescription as a,\n setAccDescription as b,\n getConfig as c,\n sanitizeText$2 as d,\n common$1 as e,\n assignWithDepth$1 as f,\n getAccTitle as g,\n calculateTextWidth as h,\n configureSvgSize as i,\n calculateTextHeight as j,\n getStylesFromArray as k,\n log$1 as l,\n evaluate as m,\n interpolateToCurve as n,\n setupGraphViewbox$1 as o,\n setConfig as p,\n setDiagramTitle as q,\n getDiagramTitle as r,\n setAccTitle as s,\n clear as t,\n utils as u,\n parseGenericTypes as v,\n wrapLabel as w,\n random as x,\n setupGraphViewbox as y,\n selectSvgElement as z\n};\n", "export var MS = '-ms-'\nexport var MOZ = '-moz-'\nexport var WEBKIT = '-webkit-'\n\nexport var COMMENT = 'comm'\nexport var RULESET = 'rule'\nexport var DECLARATION = 'decl'\n\nexport var PAGE = '@page'\nexport var MEDIA = '@media'\nexport var IMPORT = '@import'\nexport var CHARSET = '@charset'\nexport var VIEWPORT = '@viewport'\nexport var SUPPORTS = '@supports'\nexport var DOCUMENT = '@document'\nexport var NAMESPACE = '@namespace'\nexport var KEYFRAMES = '@keyframes'\nexport var FONT_FACE = '@font-face'\nexport var COUNTER_STYLE = '@counter-style'\nexport var FONT_FEATURE_VALUES = '@font-feature-values'\n", "/**\n * @param {number}\n * @return {number}\n */\nexport var abs = Math.abs\n\n/**\n * @param {number}\n * @return {string}\n */\nexport var from = String.fromCharCode\n\n/**\n * @param {object}\n * @return {object}\n */\nexport var assign = Object.assign\n\n/**\n * @param {string} value\n * @param {number} length\n * @return {number}\n */\nexport function hash (value, length) {\n\treturn charat(value, 0) ^ 45 ? (((((((length << 2) ^ charat(value, 0)) << 2) ^ charat(value, 1)) << 2) ^ charat(value, 2)) << 2) ^ charat(value, 3) : 0\n}\n\n/**\n * @param {string} value\n * @return {string}\n */\nexport function trim (value) {\n\treturn value.trim()\n}\n\n/**\n * @param {string} value\n * @param {RegExp} pattern\n * @return {string?}\n */\nexport function match (value, pattern) {\n\treturn (value = pattern.exec(value)) ? value[0] : value\n}\n\n/**\n * @param {string} value\n * @param {(string|RegExp)} pattern\n * @param {string} replacement\n * @return {string}\n */\nexport function replace (value, pattern, replacement) {\n\treturn value.replace(pattern, replacement)\n}\n\n/**\n * @param {string} value\n * @param {string} search\n * @return {number}\n */\nexport function indexof (value, search) {\n\treturn value.indexOf(search)\n}\n\n/**\n * @param {string} value\n * @param {number} index\n * @return {number}\n */\nexport function charat (value, index) {\n\treturn value.charCodeAt(index) | 0\n}\n\n/**\n * @param {string} value\n * @param {number} begin\n * @param {number} end\n * @return {string}\n */\nexport function substr (value, begin, end) {\n\treturn value.slice(begin, end)\n}\n\n/**\n * @param {string} value\n * @return {number}\n */\nexport function strlen (value) {\n\treturn value.length\n}\n\n/**\n * @param {any[]} value\n * @return {number}\n */\nexport function sizeof (value) {\n\treturn value.length\n}\n\n/**\n * @param {any} value\n * @param {any[]} array\n * @return {any}\n */\nexport function append (value, array) {\n\treturn array.push(value), value\n}\n\n/**\n * @param {string[]} array\n * @param {function} callback\n * @return {string}\n */\nexport function combine (array, callback) {\n\treturn array.map(callback).join('')\n}\n", "import {from, trim, charat, strlen, substr, append, assign} from './Utility.js'\n\nexport var line = 1\nexport var column = 1\nexport var length = 0\nexport var position = 0\nexport var character = 0\nexport var characters = ''\n\n/**\n * @param {string} value\n * @param {object | null} root\n * @param {object | null} parent\n * @param {string} type\n * @param {string[] | string} props\n * @param {object[] | string} children\n * @param {number} length\n */\nexport function node (value, root, parent, type, props, children, length) {\n\treturn {value: value, root: root, parent: parent, type: type, props: props, children: children, line: line, column: column, length: length, return: ''}\n}\n\n/**\n * @param {object} root\n * @param {object} props\n * @return {object}\n */\nexport function copy (root, props) {\n\treturn assign(node('', null, null, '', null, null, 0), root, {length: -root.length}, props)\n}\n\n/**\n * @return {number}\n */\nexport function char () {\n\treturn character\n}\n\n/**\n * @return {number}\n */\nexport function prev () {\n\tcharacter = position > 0 ? charat(characters, --position) : 0\n\n\tif (column--, character === 10)\n\t\tcolumn = 1, line--\n\n\treturn character\n}\n\n/**\n * @return {number}\n */\nexport function next () {\n\tcharacter = position < length ? charat(characters, position++) : 0\n\n\tif (column++, character === 10)\n\t\tcolumn = 1, line++\n\n\treturn character\n}\n\n/**\n * @return {number}\n */\nexport function peek () {\n\treturn charat(characters, position)\n}\n\n/**\n * @return {number}\n */\nexport function caret () {\n\treturn position\n}\n\n/**\n * @param {number} begin\n * @param {number} end\n * @return {string}\n */\nexport function slice (begin, end) {\n\treturn substr(characters, begin, end)\n}\n\n/**\n * @param {number} type\n * @return {number}\n */\nexport function token (type) {\n\tswitch (type) {\n\t\t// \\0 \\t \\n \\r \\s whitespace token\n\t\tcase 0: case 9: case 10: case 13: case 32:\n\t\t\treturn 5\n\t\t// ! + , / > @ ~ isolate token\n\t\tcase 33: case 43: case 44: case 47: case 62: case 64: case 126:\n\t\t// ; { } breakpoint token\n\t\tcase 59: case 123: case 125:\n\t\t\treturn 4\n\t\t// : accompanied token\n\t\tcase 58:\n\t\t\treturn 3\n\t\t// \" ' ( [ opening delimit token\n\t\tcase 34: case 39: case 40: case 91:\n\t\t\treturn 2\n\t\t// ) ] closing delimit token\n\t\tcase 41: case 93:\n\t\t\treturn 1\n\t}\n\n\treturn 0\n}\n\n/**\n * @param {string} value\n * @return {any[]}\n */\nexport function alloc (value) {\n\treturn line = column = 1, length = strlen(characters = value), position = 0, []\n}\n\n/**\n * @param {any} value\n * @return {any}\n */\nexport function dealloc (value) {\n\treturn characters = '', value\n}\n\n/**\n * @param {number} type\n * @return {string}\n */\nexport function delimit (type) {\n\treturn trim(slice(position - 1, delimiter(type === 91 ? type + 2 : type === 40 ? type + 1 : type)))\n}\n\n/**\n * @param {string} value\n * @return {string[]}\n */\nexport function tokenize (value) {\n\treturn dealloc(tokenizer(alloc(value)))\n}\n\n/**\n * @param {number} type\n * @return {string}\n */\nexport function whitespace (type) {\n\twhile (character = peek())\n\t\tif (character < 33)\n\t\t\tnext()\n\t\telse\n\t\t\tbreak\n\n\treturn token(type) > 2 || token(character) > 3 ? '' : ' '\n}\n\n/**\n * @param {string[]} children\n * @return {string[]}\n */\nexport function tokenizer (children) {\n\twhile (next())\n\t\tswitch (token(character)) {\n\t\t\tcase 0: append(identifier(position - 1), children)\n\t\t\t\tbreak\n\t\t\tcase 2: append(delimit(character), children)\n\t\t\t\tbreak\n\t\t\tdefault: append(from(character), children)\n\t\t}\n\n\treturn children\n}\n\n/**\n * @param {number} index\n * @param {number} count\n * @return {string}\n */\nexport function escaping (index, count) {\n\twhile (--count && next())\n\t\t// not 0-9 A-F a-f\n\t\tif (character < 48 || character > 102 || (character > 57 && character < 65) || (character > 70 && character < 97))\n\t\t\tbreak\n\n\treturn slice(index, caret() + (count < 6 && peek() == 32 && next() == 32))\n}\n\n/**\n * @param {number} type\n * @return {number}\n */\nexport function delimiter (type) {\n\twhile (next())\n\t\tswitch (character) {\n\t\t\t// ] ) \" '\n\t\t\tcase type:\n\t\t\t\treturn position\n\t\t\t// \" '\n\t\t\tcase 34: case 39:\n\t\t\t\tif (type !== 34 && type !== 39)\n\t\t\t\t\tdelimiter(character)\n\t\t\t\tbreak\n\t\t\t// (\n\t\t\tcase 40:\n\t\t\t\tif (type === 41)\n\t\t\t\t\tdelimiter(type)\n\t\t\t\tbreak\n\t\t\t// \\\n\t\t\tcase 92:\n\t\t\t\tnext()\n\t\t\t\tbreak\n\t\t}\n\n\treturn position\n}\n\n/**\n * @param {number} type\n * @param {number} index\n * @return {number}\n */\nexport function commenter (type, index) {\n\twhile (next())\n\t\t// //\n\t\tif (type + character === 47 + 10)\n\t\t\tbreak\n\t\t// /*\n\t\telse if (type + character === 42 + 42 && peek() === 47)\n\t\t\tbreak\n\n\treturn '/*' + slice(index, position - 1) + '*' + from(type === 47 ? type : next())\n}\n\n/**\n * @param {number} index\n * @return {string}\n */\nexport function identifier (index) {\n\twhile (!token(peek()))\n\t\tnext()\n\n\treturn slice(index, position)\n}\n", "import {COMMENT, RULESET, DECLARATION} from './Enum.js'\nimport {abs, charat, trim, from, sizeof, strlen, substr, append, replace, indexof} from './Utility.js'\nimport {node, char, prev, next, peek, caret, alloc, dealloc, delimit, whitespace, escaping, identifier, commenter} from './Tokenizer.js'\n\n/**\n * @param {string} value\n * @return {object[]}\n */\nexport function compile (value) {\n\treturn dealloc(parse('', null, null, null, [''], value = alloc(value), 0, [0], value))\n}\n\n/**\n * @param {string} value\n * @param {object} root\n * @param {object?} parent\n * @param {string[]} rule\n * @param {string[]} rules\n * @param {string[]} rulesets\n * @param {number[]} pseudo\n * @param {number[]} points\n * @param {string[]} declarations\n * @return {object}\n */\nexport function parse (value, root, parent, rule, rules, rulesets, pseudo, points, declarations) {\n\tvar index = 0\n\tvar offset = 0\n\tvar length = pseudo\n\tvar atrule = 0\n\tvar property = 0\n\tvar previous = 0\n\tvar variable = 1\n\tvar scanning = 1\n\tvar ampersand = 1\n\tvar character = 0\n\tvar type = ''\n\tvar props = rules\n\tvar children = rulesets\n\tvar reference = rule\n\tvar characters = type\n\n\twhile (scanning)\n\t\tswitch (previous = character, character = next()) {\n\t\t\t// (\n\t\t\tcase 40:\n\t\t\t\tif (previous != 108 && charat(characters, length - 1) == 58) {\n\t\t\t\t\tif (indexof(characters += replace(delimit(character), '&', '&\\f'), '&\\f') != -1)\n\t\t\t\t\t\tampersand = -1\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t// \" ' [\n\t\t\tcase 34: case 39: case 91:\n\t\t\t\tcharacters += delimit(character)\n\t\t\t\tbreak\n\t\t\t// \\t \\n \\r \\s\n\t\t\tcase 9: case 10: case 13: case 32:\n\t\t\t\tcharacters += whitespace(previous)\n\t\t\t\tbreak\n\t\t\t// \\\n\t\t\tcase 92:\n\t\t\t\tcharacters += escaping(caret() - 1, 7)\n\t\t\t\tcontinue\n\t\t\t// /\n\t\t\tcase 47:\n\t\t\t\tswitch (peek()) {\n\t\t\t\t\tcase 42: case 47:\n\t\t\t\t\t\tappend(comment(commenter(next(), caret()), root, parent), declarations)\n\t\t\t\t\t\tbreak\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tcharacters += '/'\n\t\t\t\t}\n\t\t\t\tbreak\n\t\t\t// {\n\t\t\tcase 123 * variable:\n\t\t\t\tpoints[index++] = strlen(characters) * ampersand\n\t\t\t// } ; \\0\n\t\t\tcase 125 * variable: case 59: case 0:\n\t\t\t\tswitch (character) {\n\t\t\t\t\t// \\0 }\n\t\t\t\t\tcase 0: case 125: scanning = 0\n\t\t\t\t\t// ;\n\t\t\t\t\tcase 59 + offset:\n\t\t\t\t\t\tif (property > 0 && (strlen(characters) - length))\n\t\t\t\t\t\t\tappend(property > 32 ? declaration(characters + ';', rule, parent, length - 1) : declaration(replace(characters, ' ', '') + ';', rule, parent, length - 2), declarations)\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// @ ;\n\t\t\t\t\tcase 59: characters += ';'\n\t\t\t\t\t// { rule/at-rule\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tappend(reference = ruleset(characters, root, parent, index, offset, rules, points, type, props = [], children = [], length), rulesets)\n\n\t\t\t\t\t\tif (character === 123)\n\t\t\t\t\t\t\tif (offset === 0)\n\t\t\t\t\t\t\t\tparse(characters, root, reference, reference, props, rulesets, length, points, children)\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\tswitch (atrule === 99 && charat(characters, 3) === 110 ? 100 : atrule) {\n\t\t\t\t\t\t\t\t\t// d m s\n\t\t\t\t\t\t\t\t\tcase 100: case 109: case 115:\n\t\t\t\t\t\t\t\t\t\tparse(value, reference, reference, rule && append(ruleset(value, reference, reference, 0, 0, rules, points, type, rules, props = [], length), children), rules, children, length, points, rule ? props : children)\n\t\t\t\t\t\t\t\t\t\tbreak\n\t\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t\tparse(characters, reference, reference, reference, [''], children, 0, points, children)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tindex = offset = property = 0, variable = ampersand = 1, type = characters = '', length = pseudo\n\t\t\t\tbreak\n\t\t\t// :\n\t\t\tcase 58:\n\t\t\t\tlength = 1 + strlen(characters), property = previous\n\t\t\tdefault:\n\t\t\t\tif (variable < 1)\n\t\t\t\t\tif (character == 123)\n\t\t\t\t\t\t--variable\n\t\t\t\t\telse if (character == 125 && variable++ == 0 && prev() == 125)\n\t\t\t\t\t\tcontinue\n\n\t\t\t\tswitch (characters += from(character), character * variable) {\n\t\t\t\t\t// &\n\t\t\t\t\tcase 38:\n\t\t\t\t\t\tampersand = offset > 0 ? 1 : (characters += '\\f', -1)\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// ,\n\t\t\t\t\tcase 44:\n\t\t\t\t\t\tpoints[index++] = (strlen(characters) - 1) * ampersand, ampersand = 1\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// @\n\t\t\t\t\tcase 64:\n\t\t\t\t\t\t// -\n\t\t\t\t\t\tif (peek() === 45)\n\t\t\t\t\t\t\tcharacters += delimit(next())\n\n\t\t\t\t\t\tatrule = peek(), offset = length = strlen(type = characters += identifier(caret())), character++\n\t\t\t\t\t\tbreak\n\t\t\t\t\t// -\n\t\t\t\t\tcase 45:\n\t\t\t\t\t\tif (previous === 45 && strlen(characters) == 2)\n\t\t\t\t\t\t\tvariable = 0\n\t\t\t\t}\n\t\t}\n\n\treturn rulesets\n}\n\n/**\n * @param {string} value\n * @param {object} root\n * @param {object?} parent\n * @param {number} index\n * @param {number} offset\n * @param {string[]} rules\n * @param {number[]} points\n * @param {string} type\n * @param {string[]} props\n * @param {string[]} children\n * @param {number} length\n * @return {object}\n */\nexport function ruleset (value, root, parent, index, offset, rules, points, type, props, children, length) {\n\tvar post = offset - 1\n\tvar rule = offset === 0 ? rules : ['']\n\tvar size = sizeof(rule)\n\n\tfor (var i = 0, j = 0, k = 0; i < index; ++i)\n\t\tfor (var x = 0, y = substr(value, post + 1, post = abs(j = points[i])), z = value; x < size; ++x)\n\t\t\tif (z = trim(j > 0 ? rule[x] + ' ' + y : replace(y, /&\\f/g, rule[x])))\n\t\t\t\tprops[k++] = z\n\n\treturn node(value, root, parent, offset === 0 ? RULESET : type, props, children, length)\n}\n\n/**\n * @param {number} value\n * @param {object} root\n * @param {object?} parent\n * @return {object}\n */\nexport function comment (value, root, parent) {\n\treturn node(value, root, parent, COMMENT, from(char()), substr(value, 2, -2), 0)\n}\n\n/**\n * @param {string} value\n * @param {object} root\n * @param {object?} parent\n * @param {number} length\n * @return {object}\n */\nexport function declaration (value, root, parent, length) {\n\treturn node(value, root, parent, DECLARATION, substr(value, 0, length), substr(value, length + 1, -1), length)\n}\n", "import {IMPORT, COMMENT, RULESET, DECLARATION, KEYFRAMES} from './Enum.js'\nimport {strlen, sizeof} from './Utility.js'\n\n/**\n * @param {object[]} children\n * @param {function} callback\n * @return {string}\n */\nexport function serialize (children, callback) {\n\tvar output = ''\n\tvar length = sizeof(children)\n\n\tfor (var i = 0; i < length; i++)\n\t\toutput += callback(children[i], i, children, callback) || ''\n\n\treturn output\n}\n\n/**\n * @param {object} element\n * @param {number} index\n * @param {object[]} children\n * @param {function} callback\n * @return {string}\n */\nexport function stringify (element, index, children, callback) {\n\tswitch (element.type) {\n\t\tcase IMPORT: case DECLARATION: return element.return = element.return || element.value\n\t\tcase COMMENT: return ''\n\t\tcase KEYFRAMES: return element.return = element.value + '{' + serialize(element.children, callback) + '}'\n\t\tcase RULESET: element.value = element.props.join(',')\n\t}\n\n\treturn strlen(children = serialize(element.children, callback)) ? element.return = element.value + '{' + children + '}' : ''\n}\n"], "mappings": "qDAAA,IAAAA,GAAAC,GAAA,CAAAC,GAAAC,KAAA,EAAC,SAAS,EAAE,EAAE,CAAW,OAAOD,IAAjB,UAAuC,OAAOC,GAApB,IAA2BA,GAAO,QAAQ,EAAE,EAAc,OAAO,QAAnB,YAA2B,OAAO,IAAI,OAAO,CAAC,GAA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ACA,KACA,OACA,MACA,OACA,UACA,OACA,WACA,QACA,MACA,OACA,KACA,WACA,SACA,SACA,IACA,UACA,MACA,WACA,IACA,KACA,KACA,OACA,IACA,OACA,UACA,SACA,SACA,QACA,SACA,SACA,OACA,SACA,SACA,QACA,MACA,UACA,MACA,QACA,QACA,KACA,WACA,WACA,QACA,KACA,QACA,OACA,KACA,QACA,KACA,IACA,KACA,MACA,QACA,KArHyB,CAAD,EAyHbmE,EAAMnE,EAAO,CACxB,MACA,IACA,WACA,cACA,eACA,eACA,gBACA,mBACA,SACA,WACA,OACA,OACA,UACA,SACA,OACA,IACA,QACA,WACA,QACA,QACA,OACA,iBACA,SACA,OACA,WACA,QACA,OACA,UACA,UACA,WACA,iBACA,OACA,OACA,QACA,SACA,SACA,OACA,WACA,QACA,OACA,QACA,OACA,OA3CwB,CAAD,EA8CZoE,EAAapE,EAAO,CAC/B,UACA,gBACA,sBACA,cACA,mBACA,oBACA,oBACA,iBACA,eACA,UACA,UACA,UACA,UACA,UACA,iBACA,UACA,UACA,cACA,eACA,WACA,eACA,qBACA,cACA,SACA,cAzB+B,CAAD,EAgCnBqE,EAAgBrE,EAAO,CAClC,UACA,gBACA,SACA,UACA,YACA,mBACA,iBACA,gBACA,gBACA,gBACA,QACA,YACA,OACA,eACA,YACA,UACA,gBACA,SACA,MACA,aACA,UACA,KAtBkC,CAAD,EAyBtBsE,EAAStE,EAAO,CAC3B,OACA,WACA,SACA,UACA,QACA,SACA,KACA,aACA,gBACA,KACA,KACA,QACA,UACA,WACA,QACA,OACA,KACA,SACA,QACA,SACA,OACA,OACA,UACA,SACA,MACA,QACA,MACA,SACA,aACA,aA9B2B,CAAD,EAmCfuE,EAAmBvE,EAAO,CACrC,UACA,cACA,aACA,WACA,YACA,UACA,UACA,SACA,SACA,QACA,YACA,aACA,iBACA,cACA,MAfqC,CAAD,EAkBzBwE,EAAOxE,EAAO,CAAC,OAAD,CAAD,ECrRbkE,EAAOlE,EAAO,CACzB,SACA,SACA,QACA,MACA,iBACA,eACA,uBACA,WACA,aACA,UACA,SACA,UACA,cACA,cACA,UACA,OACA,QACA,QACA,QACA,OACA,UACA,WACA,eACA,SACA,cACA,WACA,WACA,UACA,MACA,WACA,0BACA,wBACA,WACA,YACA,UACA,eACA,OACA,MACA,UACA,SACA,SACA,OACA,OACA,WACA,KACA,YACA,YACA,QACA,OACA,QACA,OACA,OACA,UACA,OACA,MACA,MACA,YACA,QACA,SACA,MACA,YACA,WACA,QACA,OACA,QACA,UACA,aACA,SACA,OACA,UACA,UACA,cACA,cACA,SACA,UACA,UACA,aACA,WACA,MACA,WACA,MACA,WACA,OACA,OACA,UACA,aACA,QACA,WACA,QACA,OACA,QACA,OACA,UACA,QACA,MACA,SACA,OACA,QACA,UACA,WACA,QACA,YACA,OACA,SACA,SACA,QACA,QACA,QACA,MA7GyB,CAAD,EAgHbmE,EAAMnE,EAAO,CACxB,gBACA,aACA,WACA,qBACA,SACA,gBACA,gBACA,UACA,gBACA,iBACA,QACA,OACA,KACA,QACA,OACA,gBACA,YACA,YACA,QACA,sBACA,8BACA,gBACA,kBACA,KACA,KACA,IACA,KACA,KACA,kBACA,YACA,UACA,UACA,MACA,WACA,YACA,MACA,OACA,eACA,YACA,SACA,cACA,cACA,gBACA,cACA,YACA,mBACA,eACA,aACA,eACA,cACA,KACA,KACA,KACA,KACA,aACA,WACA,gBACA,oBACA,SACA,OACA,KACA,kBACA,KACA,MACA,IACA,KACA,KACA,KACA,KACA,UACA,YACA,aACA,WACA,OACA,eACA,iBACA,eACA,mBACA,iBACA,QACA,aACA,aACA,eACA,eACA,cACA,cACA,mBACA,YACA,MACA,OACA,QACA,SACA,OACA,MACA,OACA,aACA,SACA,WACA,UACA,QACA,SACA,cACA,SACA,WACA,cACA,OACA,aACA,sBACA,mBACA,eACA,SACA,gBACA,sBACA,iBACA,IACA,KACA,KACA,SACA,OACA,OACA,cACA,YACA,UACA,SACA,SACA,QACA,OACA,kBACA,mBACA,mBACA,eACA,cACA,eACA,cACA,aACA,eACA,mBACA,oBACA,iBACA,kBACA,oBACA,iBACA,SACA,eACA,QACA,eACA,iBACA,WACA,UACA,UACA,YACA,mBACA,cACA,kBACA,iBACA,aACA,OACA,KACA,KACA,UACA,SACA,UACA,aACA,UACA,aACA,gBACA,gBACA,QACA,eACA,OACA,eACA,mBACA,mBACA,IACA,KACA,KACA,QACA,IACA,KACA,KACA,IACA,YAtLwB,CAAD,EAyLZsE,EAAStE,EAAO,CAC3B,SACA,cACA,QACA,WACA,QACA,eACA,cACA,aACA,aACA,QACA,MACA,UACA,eACA,WACA,QACA,QACA,SACA,OACA,KACA,UACA,SACA,gBACA,SACA,SACA,iBACA,YACA,WACA,cACA,UACA,UACA,gBACA,WACA,WACA,OACA,WACA,WACA,aACA,UACA,SACA,SACA,cACA,gBACA,uBACA,YACA,YACA,aACA,WACA,iBACA,iBACA,YACA,UACA,QACA,OArD2B,CAAD,EAwDfyE,EAAMzE,EAAO,CACxB,aACA,SACA,cACA,YACA,aALwB,CAAD,EChWZ0E,GAAgBzE,EAAK,2BAAD,EACpB0E,GAAW1E,EAAK,uBAAD,EACf2E,GAAc3E,EAAK,eAAD,EAClB4E,GAAY5E,EAAK,4BAAD,EAChB6E,GAAY7E,EAAK,gBAAD,EAChB8E,GAAiB9E,EAC5B,2FADgC,EAGrB+E,GAAoB/E,EAAK,uBAAD,EACxBgF,GAAkBhF,EAC7B,6DADiC,EAGtBiF,EAAejF,EAAK,SAAD,uLCOhC,IAAMkF,EAAY,IAAO,OAAOC,OAAW,IAAc,KAAOA,OAU1DC,EAA4B,SAAUC,EAAcC,EAAmB,CAEzE,GAAA,OAAOD,GAAiB,UACxB,OAAOA,EAAaE,cAAiB,WAErC,OAAO,KAMLC,IAAAA,EAAS,KACPC,GAAY,wBACdH,GAAqBA,EAAkBI,aAAaD,EAA/B,IACvBD,EAASF,EAAkBK,aAAaF,EAA/B,GAGLG,IAAAA,GAAa,aAAeJ,EAAS,IAAMA,EAAS,IAEtD,GAAA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,eAAkB,IAClB,UAAa,SACb,gBAAmB,GACnB,kBAAqB,6CACrB,kBAAqB,IACrB,KAAQ,GACR,YAAe,GACf,cAAiB,GACjB,eAAkB,EACpB,EACA,MAAS,CACP,YAAe,GACf,eAAkB,GAClB,UAAa,GACb,OAAU,EACV,WAAc,GACd,aAAgB,GAChB,YAAe,GACf,qBAAwB,GACxB,SAAY,GACZ,gBAAmB,GACnB,oBAAuB,EACvB,WAAc,WACd,QAAW,GACX,YAAe,GACf,QAAW,QACb,EACA,QAAW,CACT,YAAe,GACf,eAAkB,GAClB,eAAkB,GAClB,WAAc,IACd,MAAS,IACT,OAAU,GACV,UAAa,GACb,cAAiB,EACjB,WAAc,GACd,cAAiB,GACjB,aAAgB,SAChB,gBAAmB,EACnB,YAAe,GACf,aAAgB,GAChB,eAAkB,0BAClB,WAAc,GACd,gBAAmB,GACnB,cAAiB,KACjB,aAAgB,CACd,UACA,UACA,UACA,UACA,UACA,SACF,EACA,aAAgB,CACd,UACA,UACA,UACA,UACA,UACA,UACA,SACF,EACA,eAAkB,CAChB,MACF,CACF,EACA,MAAS,CACP,YAAe,GACf,eAAkB,GAClB,oBAAuB,GACvB,cAAiB,GACjB,QAAW,EACX,WAAc,GACd,gBAAmB,gBACnB,WAAc,EAChB,EACA,MAAS,CACP,YAAe,GACf,eAAkB,GAClB,cAAiB,GACjB,SAAY,EACZ,QAAW,EACX,WAAc,GACd,WAAc,IACd,WAAc,GACd,UAAa,GACb,WAAc,EACd,YAAe,EACf,eAAkB,KAClB,SAAY,GACZ,YAAe,GACf,iBAAoB,KACpB,kBAAqB,GACrB,OAAU,EACV,gBAAmB,eACrB,EACA,GAAM,CACJ,YAAe,GACf,eAAkB,GAClB,eAAkB,GAClB,gBAAmB,KACnB,eAAkB,IAClB,gBAAmB,GACnB,cAAiB,GACjB,OAAU,OACV,KAAQ,WACR,SAAY,EACd,EACA,IAAO,CACL,YAAe,GACf,aAAgB,GAClB,EACA,cAAiB,CACf,YAAe,GACf,WAAc,IACd,YAAe,IACf,cAAiB,GACjB,aAAgB,GAChB,gBAAmB,EACnB,kBAAqB,EACrB,kBAAqB,EACrB,mBAAsB,GACtB,mBAAsB,GACtB,sBAAyB,GACzB,uBAA0B,EAC1B,iBAAoB,EACpB,mBAAsB,GACtB,YAAe,EACf,cAAiB,MACjB,cAAiB,OACjB,kCAAqC,EACrC,kCAAqC,CACvC,EACA,QAAW,CACT,YAAe,GACf,MAAS,IACT,OAAU,IACV,cAAiB,GACjB,aAAgB,GAChB,UAAa,GACb,MAAS,CACP,KAAQ,4BACR,UAAa,GACb,cAAiB,GACjB,aAAgB,EAChB,UAAa,GACb,cAAiB,GACjB,aAAgB,EAChB,SAAY,GACZ,WAAc,EACd,UAAa,EACb,aAAgB,GAChB,cAAiB,CACnB,EACA,MAAS,CACP,KAAQ,4BACR,UAAa,GACb,cAAiB,GACjB,aAAgB,EAChB,UAAa,GACb,cAAiB,GACjB,aAAgB,EAChB,SAAY,GACZ,WAAc,EACd,UAAa,EACb,aAAgB,GAChB,cAAiB,CACnB,EACA,iBAAoB,WACpB,yBAA4B,EAC9B,EACA,YAAe,CACb,YAAe,GACf,UAAa,UACb,WAAc,OACd,iBAAoB,QACpB,kBAAqB,OACrB,eAAkB,IAClB,gBAAmB,IACnB,SAAY,GACZ,aAAgB,GAChB,YAAe,EACjB,EACA,QAAW,CACT,YAAe,GACf,QAAW,GACX,aAAgB,GAClB,EACA,SAAY,CACV,YAAe,GACf,eAAkB,GAClB,eAAkB,GAClB,WAAc,IACd,MAAS,IACT,OAAU,GACV,UAAa,GACb,cAAiB,EACjB,WAAc,GACd,cAAiB,GACjB,aAAgB,SAChB,gBAAmB,EACnB,YAAe,GACf,aAAgB,GAChB,eAAkB,0BAClB,WAAc,GACd,gBAAmB,GACnB,cAAiB,KACjB,aAAgB,CACd,UACA,UACA,UACA,UACA,UACA,SACF,EACA,aAAgB,CACd,UACA,UACA,UACA,UACA,UACA,UACA,SACF,EACA,eAAkB,CAChB,MACF,E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AAMC,EAAc,IAAM,IAAI,QAAQ,CAAC3zB,EAAK4zB,IAAQ,CAClDnC,GAAW,OAAOhwB,EAAK7G,EAAMk5B,CAAS,EAAE,KACrCD,GAAM,CACL7zB,EAAI6zB,CAAC,EACLJ,EAAQI,CAAC,CACX,EACCtb,GAAM,CACL,IAAIzd,EACJjB,EAAM,MAAM,gBAAiB0e,CAAC,GAC7Bzd,EAAKo3B,GAAQ,aAAe,MAAgBp3B,EAAG,KAAKo3B,GAAS3Z,CAAC,EAC/Dqb,EAAIrb,CAAC,EACLmb,EAAOnb,CAAC,CACV,CACF,CACF,CAAC,EACD8a,GAAe,KAAKM,CAAW,EAC/BJ,GAAa,EAAE,MAAMG,CAAM,CAC7B,CAAC,EAEGxB,GAAU,CACd,YAAa,GACb,WAAAT,GACA,MAAA+B,GACA,OAAAd,GACA,KAAAE,GACA,IAAAZ,GACA,yBAAAe,GACA,WAAAJ,GACA,WAAY,OACZ,cAAAM,GACA,qBAAAE,GACA,WAAA9xB,EACF", "names": ["require_dayjs_min", "__commonJSMin", "exports", "module", "n", "r", "i", "s", "u", "a", "o", "f", "c", "d", "l", "$", "y", "M", "t", "e", "m", "g", "D", "p", "_", "S", "w", "O", "h", "v", "T", "require_dist", "__commonJSMin", "exports", "invalidProtocolRegex", "htmlEntitiesRegex", "htmlCtrlEntityRegex", "ctrlCharactersRegex", "urlSchemeRegex", "relativeFirstCharacters", "isRelativeUrlWithoutProtocol", "url", "decodeHtmlCharacters", "str", "match", "dec", "sanitizeUrl", "sanitizedUrl", "urlSchemeParseResults", "urlScheme", "entries", "setPrototypeOf", "isFrozen", "getPrototypeOf", "getOwnPropertyDescriptor", "Object", "freeze", "seal", "create", "apply", "construct", "Reflect", "fun", "thisValue", "args", "x", "Func", "arrayForEach", "unapply", "Array", "prototype", "forEach", "arrayPop", "pop", "arrayPush", "push", "stringToLowerCase", "String", "toLowerCase", "stringToString", "toString", "stringMatch", "match", "stringReplace", "replace", "stringIndexOf", "indexOf", "stringTrim", "trim", "regExpTest", "RegExp", "test", "typeErrorCreate", "unconstruct", "TypeError", "func", "thisArg", "_len", "_key", "_len2", "_key2", "addToSet", "set", "array", "transformCaseFunc", "_transformCaseFunc", "l", "length", "element", "lcElement", "clone", "object", "newObject", "property", "value", "lookupGetter", "prop", "desc", "get", "fallbackValue", "console", "warn", "html", "svg", "svgFilters", "svgDisallowed", "mathMl", "mathMlDisallowed", "text", "xml", "MUSTACHE_EXPR", "ERB_EXPR", "TMPLIT_EXPR", "DATA_ATTR", "ARIA_ATTR", "IS_ALLOWED_URI", "IS_SCRIPT_OR_DATA", "ATTR_WHITESPACE", "DOCTYPE_NAME", "getGlobal", "window", "_createTrustedTypesPolicy", "trustedTypes", "purifyHostElement", "createPolicy", "suffix", "ATTR_NAME", "hasAttribute", "getAttribute", "policyName", "createHTML", "createScriptURL", "scriptUrl", "createDOMPurify", "DOMPurify", "root", "version", "VERSION", "removed", "document", "nodeType", "isSupported", "originalDocument", "currentScript", "DocumentFragment", "HTMLTemplateElement", "Node", "Element", "NodeFilter", "NamedNodeMap", "MozNamedAttrMap", "HTMLFormElement", "DOMParser", "ElementPrototype", "cloneNode", "getNextSibling", "getChildNodes", "getParentNode", "template", "createElement", "content", "ownerDocument", "trustedTypesPolicy", "emptyHTML", "implementation", "createNodeIterator", "createDocumentFragment", "getElementsByTagName", "importNode", "hooks", "createHTMLDocument", "undefined", "EXPRESSIONS", "ALLOWED_TAGS", "DEFAULT_ALLOWED_TAGS", "TAGS", "ALLOWED_ATTR", "DEFAULT_ALLOWED_ATTR", "ATTRS", "CUSTOM_ELEMENT_HANDLING", "tagNameCheck", "writable", "configurable", "enumerable", "attributeNameCheck", "allowCustomizedBuiltInElements", "FORBID_TAGS", "FORBID_ATTR", "ALLOW_ARIA_ATTR", "ALLOW_DATA_ATTR", "ALLOW_UNKNOWN_PROTOCOLS", "ALLOW_SELF_CLOSE_IN_ATTR", "SAFE_FOR_TEMPLATES", "WHOLE_DOCUMENT", "SET_CONFIG", "FORCE_BODY", "RETURN_DOM", "RETURN_DOM_FRAGMENT", "RETURN_TRUSTED_TYPE", "SANITIZE_DOM", "SANITIZE_NAMED_PROPS", "SANITIZE_NAMED_PROPS_PREFIX", "KEEP_CONTENT", "IN_PLACE", "USE_PROFILES", "FORBID_CONTENTS", "DEFAULT_FORBID_CONTENTS", "DATA_URI_TAGS", "DEFAULT_DATA_URI_TAGS", "URI_SAFE_ATTRIBUTES", "DEFAULT_URI_SAFE_ATTRIBUTES", "MATHML_NAMESPACE", "SVG_NAMESPACE", "HTML_NAMESPACE", "NAMESPACE", "IS_EMPTY_INPUT", "ALLOWED_NAMESPACES", "DEFAULT_ALLOWED_NAMESPACES", "PARSER_MEDIA_TYPE", "SUPPORTED_PARSER_MEDIA_TYPES", "DEFAULT_PARSER_MEDIA_TYPE", "CONFIG", "formElement", "isRegexOrFunction", "testValue", "Function", "_parseConfig", "cfg", "ADD_URI_SAFE_ATTR", "ADD_DATA_URI_TAGS", "ALLOWED_URI_REGEXP", "ADD_TAGS", "ADD_ATTR", "table", "tbody", "TRUSTED_TYPES_POLICY", "MATHML_TEXT_INTEGRATION_POINTS", "HTML_INTEGRATION_POINTS", "COMMON_SVG_AND_HTML_ELEMENTS", "ALL_SVG_TAGS", "ALL_MATHML_TAGS", "_checkValidNamespace", "parent", "tagName", "namespaceURI", "parentTagName", "Boolean", "_forceRemove", "node", "parentNode", "removeChild", "remove", "_removeAttribute", "name", "attribute", "getAttributeNode", "from", "removeAttribute", "setAttribute", "_initDocument", "dirty", "doc", "leadingWhitespace", "matches", "dirtyPayload", "parseFromString", "documentElement", "createDocument", "innerHTML", "body", "insertBefore", "createTextNode", "childNodes", "call", "_createIterator", "SHOW_ELEMENT", "SHOW_COMMENT", "SHOW_TEXT", "_isClobbered", "elm", "nodeName", "textContent", "attributes", "hasChildNodes", "_isNode", "_executeHook", "entryPoint", "currentNode", "data", "hook", "_sanitizeElements", "allowedTags", "firstElementChild", "_basicCustomElementTest", "childCount", "i", "_isValidAttribute", "lcTag", "lcName", "_sanitizeAttributes", "attr", "hookEvent", "attrName", "attrValue", "keepAttr", "allowedAttributes", "forceKeepAttr", "getAttributeType", "setAttributeNS", "_sanitizeShadowDOM", "fragment", "shadowNode", "shadowIterator", "nextNode", "sanitize", "importedNode", "returnNode", "appendChild", "firstChild", "nodeIterator", "shadowroot", "shadowrootmode", "serializedHTML", "outerHTML", "doctype", "setConfig", "clearConfig", "isValidAttribute", "tag", "addHook", "hookFunction", "removeHook", "removeHooks", "removeAllHooks", "purify", "dedent", "templ", "values", "_i", "strings", "indentLengths", "arr", "str", "matches", "match", "_a", "_b", "pattern_1", "string", "value", "i", "endentations", "endentation", "indentedValue", "max", "values", "valueof", "value", "index", "min", "values", "valueof", "value", "index", "ascending", "a", "b", "descending", "a", "b", "bisector", "f", "compare1", "compare2", "delta", "ascending", "d", "x", "descending", "zero", "left", "a", "lo", "hi", "mid", "right", "center", "i", "number", "x", "ascendingBisect", "bisector", "ascending", "bisectRight", "bisectLeft", "bisectCenter", "number", "bisect_default", "InternMap", "entries", "key", "keyof", "value", "intern_get", "intern_set", "intern_delete", "intern_get", "_intern", "_key", "value", "key", "intern_set", "intern_delete", "keyof", "e10", "e5", "e2", "tickSpec", "start", "stop", "count", "step", "power", "error", "factor", "i1", "i2", "inc", "ticks", "reverse", "n", "i", "tickIncrement", "tickStep", "range", "start", "stop", "step", "n", "identity_default", "x", "top", "right", "bottom", "left", "epsilon", "translateX", "x", "translateY", "y", "number", "scale", "d", "center", "offset", "entering", "axis", "orient", "tickArguments", "tickValues", "tickFormat", "tickSizeInner", "tickSizeOuter", "tickPadding", "k", "transform", "context", "values", "format", "identity_default", "spacing", "range", "range0", "range1", "position", "selection", "path", "tick", "tickExit", "tickEnter", "line", "text", "p", "_", "axisTop", "axisBottom", "scale", "axis", "bottom", "none", "selector_default", "selector", "select_default", "select", "selector_default", "groups", "m", "subgroups", "j", "group", "n", "subgroup", "node", "subnode", "i", "Selection", "array", "x", "empty", "selectorAll_default", "selector", "arrayAll", "select", "array", "selectAll_default", "selectorAll_default", "groups", "m", "subgroups", "parents", "j", "group", "n", "node", "i", "Selection", "matcher_default", "selector", "childMatcher", "node", "find", "childFind", "match", "childFirst", "selectChild_default", "childMatcher", "filter", "children", "childrenFilter", "match", "selectChildren_default", "childMatcher", "filter_default", "match", "matcher_default", "groups", "m", "subgroups", "j", "group", "n", "subgroup", "node", "i", "Selection", "sparse_default", "update", "enter_default", "Selection", "sparse_default", "EnterNode", "parent", "datum", "child", "next", "selector", "constant_default", "x", "bindIndex", "parent", "group", "enter", "update", "exit", "data", "i", "node", "groupLength", "dataLength", "EnterNode", "bindKey", "key", "nodeByKeyValue", "keyValues", "keyValue", "datum", "data_default", "value", "bind", "parents", "groups", "constant_default", "m", "j", "arraylike", "enterGroup", "updateGroup", "exitGroup", "i0", "i1", "previous", "next", "Selection", "exit_default", "Selection", "sparse_default", "join_default", "onenter", "onupdate", "onexit", "enter", "update", "exit", "merge_default", "context", "selection", "groups0", "groups1", "m0", "m1", "m", "merges", "j", "group0", "group1", "n", "merge", "node", "i", "Selection", "order_default", "groups", "j", "m", "group", "i", "next", "node", "sort_default", "compare", "ascending", "compareNode", "a", "b", "groups", "m", "sortgroups", "j", "group", "n", "sortgroup", "node", "i", "Selection", "call_default", "callback", "nodes_default", "node_default", "groups", "j", "m", "group", "i", "node", "size_default", "size", "node", "empty_default", "each_default", "callback", "groups", "j", "m", "group", "i", "n", "node", "xhtml", "namespaces_default", "namespace_default", "name", "prefix", "i", "namespaces_default", "attrRemove", "name", "attrRemoveNS", "fullname", "attrConstant", "value", "attrConstantNS", "attrFunction", "v", "attrFunctionNS", "attr_default", "namespace_default", "node", "window_default", "node", "styleRemove", "name", "styleConstant", "value", "priority", "styleFunction", "v", "style_default", "styleValue", "node", "window_default", "propertyRemove", "name", "propertyConstant", "value", "propertyFunction", "v", "property_default", "classArray", "string", "classList", "node", "ClassList", "name", "i", "classedAdd", "names", "list", "n", "classedRemove", "classedTrue", "classedFalse", "classedFunction", "value", "classed_default", "textRemove", "textConstant", "value", "textFunction", "v", "text_default", "htmlRemove", "htmlConstant", "value", "htmlFunction", "v", "html_default", "raise", "raise_default", "lower", "lower_default", "creatorInherit", "name", "document", "uri", "xhtml", "creatorFixed", "fullname", "creator_default", "namespace_default", "append_default", "name", "create", "creator_default", "constantNull", "insert_default", "name", "before", "create", "creator_default", "select", "selector_default", "remove", "parent", "remove_default", "selection_cloneShallow", "clone", "parent", "selection_cloneDeep", "clone_default", "deep", "datum_default", "value", "contextListener", "listener", "event", "parseTypenames", "typenames", "t", "name", "onRemove", "typename", "on", "j", "m", "o", "onAdd", "value", "options", "on_default", "i", "dispatchEvent", "node", "type", "params", "window", "window_default", "event", "dispatchConstant", "dispatchFunction", "dispatch_default", "iterator_default", "groups", "j", "m", "group", "i", "node", "root", "Selection", "groups", "parents", "selection", "selection_selection", "select_default", "selectAll_default", "selectChild_default", "selectChildren_default", "filter_default", "data_default", "enter_default", "exit_default", "join_default", "merge_default", "order_default", "sort_default", "call_default", "nodes_default", "node_default", "size_default", "empty_default", "each_default", "attr_default", "style_default", "property_default", "classed_default", "text_default", "html_default", "raise_default", "lower_default", "append_default", "insert_default", "remove_default", "clone_default", "datum_default", "on_default", "dispatch_default", "iterator_default", "selection_default", "select_default", "selector", "Selection", "root", "selectAll_default", "selector", "Selection", "array", "root", "define_default", "constructor", "factory", "prototype", "extend", "parent", "definition", "key", "Color", "darker", "brighter", "reI", "reN", "reP", "reHex", "reRgbInteger", "reRgbPercent", "reRgbaInteger", "reRgbaPercent", "reHslPercent", "reHslaPercent", "named", "define_default", "color", "channels", "color_formatHex", "color_formatHex8", "color_formatHsl", "color_formatRgb", "hslConvert", "format", "m", "l", "rgbn", "Rgb", "rgba", "hsla", "n", "r", "g", "b", "a", "rgbConvert", "o", "rgb", "opacity", "extend", "k", "clampi", "clampa", "rgb_formatHex", "rgb_formatHex8", "rgb_formatRgb", "hex", "value", "h", "s", "Hsl", "min", "max", "hsl", "m2", "m1", "hsl2rgb", "clamph", "clampt", "radians", "degrees", "K", "Xn", "Yn", "Zn", "t0", "t1", "t2", "t3", "labConvert", "o", "Lab", "Hcl", "hcl2lab", "Rgb", "rgbConvert", "r", "rgb2lrgb", "g", "b", "y", "xyz2lab", "x", "z", "lab", "l", "a", "b", "opacity", "labConvert", "Lab", "define_default", "extend", "Color", "k", "K", "y", "x", "z", "Xn", "lab2xyz", "Yn", "Zn", "Rgb", "lrgb2rgb", "xyz2lab", "t3", "t2", "t0", "t1", "rgb2lrgb", "hclConvert", "o", "Hcl", "h", "degrees", "hcl", "h", "c", "l", "opacity", "hclConvert", "Hcl", "hcl2lab", "o", "Lab", "radians", "define_default", "extend", "Color", "k", "K", "constant_default", "x", "linear", "a", "d", "t", "exponential", "b", "y", "hue", "constant_default", "gamma", "nogamma", "hcl", "hue", "start", "end", "h", "c", "nogamma", "l", "opacity", "t", "hcl_default", "hclLong", "basis", "t1", "v0", "v1", "v2", "v3", "t2", "t3", "basis_default", "values", "n", "t", "basisClosed_default", "values", "n", "t", "v0", "v1", "v2", "v3", "basis", "rgb_default", "rgbGamma", "y", "color", "gamma", "rgb", "start", "end", "r", "g", "b", "opacity", "nogamma", "t", "rgbSpline", "spline", "colors", "n", "i", "rgbBasis", "basis_default", "rgbBasisClosed", "basisClosed_default", "numberArray_default", "a", "b", "n", "c", "i", "t", "isNumberArray", "x", "genericArray", "a", "b", "nb", "na", "x", "c", "i", "value_default", "t", "date_default", "a", "b", "d", "t", "number_default", "a", "b", "t", "object_default", "a", "b", "i", "c", "k", "value_default", "t", "reA", "reB", "zero", "b", "one", "t", "string_default", "a", "bi", "am", "bm", "bs", "i", "q", "number_default", "o", "value_default", "a", "b", "t", "c", "constant_default", "number_default", "color", "rgb_default", "string_default", "date_default", "isNumberArray", "numberArray_default", "genericArray", "object_default", "round_default", "a", "b", "t", "degrees", "identity", "decompose_default", "a", "b", "c", "d", "e", "f", "scaleX", "scaleY", "skewX", "svgNode", "parseCss", "value", "m", "identity", "decompose_default", "parseSvg", "interpolateTransform", "parse", "pxComma", "pxParen", "degParen", "pop", "s", "translate", "xa", "ya", "xb", "yb", "q", "i", "number_default", "rotate", "a", "b", "skewX", "scale", "t", "n", "o", "interpolateTransformCss", "parseCss", "interpolateTransformSvg", "parseSvg", "initRange", "domain", "range", "implicit", "ordinal", "index", "InternMap", "domain", "range", "unknown", "scale", "d", "i", "_", "value", "initRange", "band", "scale", "ordinal", "domain", "ordinalRange", "r0", "r1", "step", "bandwidth", "round", "paddingInner", "paddingOuter", "align", "rescale", "n", "reverse", "start", "stop", "values", "range", "i", "_", "initRange", "constants", "x", "number", "x", "unit", "identity", "x", "normalize", "a", "b", "constants", "clamper", "t", "bimap", "domain", "range", "interpolate", "d0", "d1", "r0", "r1", "polymap", "j", "d", "r", "i", "bisect_default", "copy", "source", "target", "transformer", "value_default", "transform", "untransform", "unknown", "clamp", "piecewise", "output", "input", "rescale", "n", "scale", "y", "number_default", "_", "number", "round_default", "u", "continuous", "formatDecimal_default", "x", "formatDecimalParts", "p", "i", "coefficient", "exponent_default", "x", "formatDecimalParts", "formatGroup_default", "grouping", "thousands", "value", "width", "i", "t", "j", "g", "length", "formatNumerals_default", "numerals", "value", "i", "re", "formatSpecifier", "specifier", "match", "FormatSpecifier", "formatTrim_default", "s", "out", "n", "i", "i0", "i1", "prefixExponent", "formatPrefixAuto_default", "x", "p", "d", "formatDecimalParts", "coefficient", "exponent", "i", "n", "formatRounded_default", "x", "p", "d", "formatDecimalParts", "coefficient", "exponent", "formatTypes_default", "x", "p", "formatDecimal_default", "formatRounded_default", "formatPrefixAuto_default", "identity_default", "x", "map", "prefixes", "locale_default", "locale", "group", "identity_default", "formatGroup_default", "currencyPrefix", "currencySuffix", "decimal", "numerals", "formatNumerals_default", "percent", "minus", "nan", "newFormat", "specifier", "formatSpecifier", "fill", "align", "sign", "symbol", "zero", "width", "comma", "precision", "trim", "type", "formatTypes_default", "prefix", "suffix", "formatType", "maybeSuffix", "format", "value", "valuePrefix", "valueSuffix", "i", "n", "c", "valueNegative", "formatTrim_default", "prefixExponent", "length", "padding", "formatPrefix", "f", "e", "exponent_default", "k", "locale", "format", "formatPrefix", "defaultLocale", "definition", "locale_default", "precisionFixed_default", "step", "exponent_default", "precisionPrefix_default", "step", "value", "exponent_default", "precisionRound_default", "step", "max", "exponent_default", "tickFormat", "start", "stop", "count", "specifier", "step", "tickStep", "precision", "formatSpecifier", "value", "precisionPrefix_default", "formatPrefix", "precisionRound_default", "precisionFixed_default", "format", "linearish", "scale", "domain", "count", "d", "ticks", "specifier", "tickFormat", "i0", "i1", "start", "stop", "prestep", "step", "maxIter", "tickIncrement", "linear", "continuous", "copy", "initRange", "t0", "t1", "timeInterval", "floori", "offseti", "count", "field", "interval", "date", "d0", "d1", "step", "start", "stop", "range", "previous", "test", "end", "d", "millisecond", "timeInterval", "date", "step", "start", "end", "k", "milliseconds", "second", "timeInterval", "date", "step", "start", "end", "seconds", "timeMinute", "timeInterval", "date", "step", "start", "end", "timeMinutes", "utcMinute", "utcMinutes", "timeHour", "timeInterval", "date", "step", "start", "end", "timeHours", "utcHour", "utcHours", "timeDay", "timeInterval", "date", "step", "start", "end", "timeDays", "utcDay", "utcDays", "unixDay", "unixDays", "timeWeekday", "i", "timeInterval", "date", "step", "start", "end", "timeSunday", "timeMonday", "timeTuesday", "timeWednesday", "timeThursday", "timeFriday", "timeSaturday", "timeSundays", "timeMondays", "timeTuesdays", "timeWednesdays", "timeThursdays", "timeFridays", "timeSaturdays", "utcWeekday", "utcSunday", "utcMonday", "utcTuesday", "utcWednesday", "utcThursday", "utcFriday", "utcSaturday", "utcSundays", "utcMondays", "utcTuesdays", "utcWednesdays", "utcThursdays", "utcFridays", "utcSaturdays", "timeMonth", "timeInterval", "date", "step", "start", "end", "timeMonths", "utcMonth", "utcMonths", "timeYear", "timeInterval", "date", "step", "start", "end", "k", "timeYears", "utcYear", "utcYears", "ticker", "year", "month", "week", "day", "hour", "minute", "tickIntervals", "second", "ticks", "start", "stop", "count", "reverse", "interval", "tickInterval", "target", "i", "bisector", "step", "tickStep", "millisecond", "t", "utcTicks", "utcTickInterval", "utcYear", "utcMonth", "utcSunday", "unixDay", "utcHour", "utcMinute", "timeTicks", "timeTickInterval", "timeYear", "timeMonth", "timeSunday", "timeDay", "timeHour", "timeMinute", "localDate", "d", "date", "utcDate", "newDate", "y", "m", "formatLocale", "locale", "locale_dateTime", "locale_date", "locale_time", "locale_periods", "locale_weekdays", "locale_shortWeekdays", "locale_months", "locale_shortMonths", "periodRe", "formatRe", "periodLookup", "formatLookup", "weekdayRe", "weekdayLookup", "shortWeekdayRe", "shortWeekdayLookup", "monthRe", "monthLookup", "shortMonthRe", "shortMonthLookup", "formats", "formatShortWeekday", "formatWeekday", "formatShortMonth", "formatMonth", "formatDayOfMonth", "formatMicroseconds", "formatYearISO", "formatFullYearISO", "formatHour24", "formatHour12", "formatDayOfYear", "formatMilliseconds", "formatMonthNumber", "formatMinutes", "formatPeriod", "formatQuarter", "formatUnixTimestamp", "formatUnixTimestampSeconds", "formatSeconds", "formatWeekdayNumberMonday", "formatWeekNumberSunday", "formatWeekNumberISO", "formatWeekdayNumberSunday", "formatWeekNumberMonday", "formatYear", "formatFullYear", "formatZone", "formatLiteralPercent", "utcFormats", "formatUTCShortWeekday", "formatUTCWeekday", "formatUTCShortMonth", "formatUTCMonth", "formatUTCDayOfMonth", "formatUTCMicroseconds", "formatUTCYearISO", "formatUTCFullYearISO", "formatUTCHour24", "formatUTCHour12", "formatUTCDayOfYear", "formatUTCMilliseconds", "formatUTCMonthNumber", "formatUTCMinutes", "formatUTCPeriod", "formatUTCQuarter", "formatUTCSeconds", "formatUTCWeekdayNumberMonday", "formatUTCWeekNumberSunday", "formatUTCWeekNumberISO", "formatUTCWeekdayNumberSunday", "formatUTCWeekNumberMonday", "formatUTCYear", "formatUTCFullYear", "formatUTCZone", "parses", "parseShortWeekday", "parseWeekday", "parseShortMonth", "parseMonth", "parseLocaleDateTime", "parseDayOfMonth", "parseMicroseconds", "parseYear", "parseFullYear", "parseHour24", "parseDayOfYear", "parseMilliseconds", "parseMonthNumber", "parseMinutes", "parsePeriod", "parseQuarter", "parseUnixTimestamp", "parseUnixTimestampSeconds", "parseSeconds", "parseWeekdayNumberMonday", "parseWeekNumberSunday", "parseWeekNumberISO", "parseWeekdayNumberSunday", "parseWeekNumberMonday", "parseLocaleDate", "parseLocaleTime", "parseZone", "parseLiteralPercent", "newFormat", "specifier", "string", "i", "j", "n", "c", "pad", "format", "pads", "newParse", "Z", "parseSpecifier", "week", "day", "utcMonday", "utcDay", "timeMonday", "timeDay", "parse", "f", "p", "numberRe", "percentRe", "requoteRe", "value", "fill", "width", "sign", "length", "requote", "s", "names", "name", "timeYear", "timeSunday", "dISO", "timeThursday", "z", "utcYear", "dow", "utcSunday", "UTCdISO", "utcThursday", "locale", "timeFormat", "timeParse", "utcFormat", "utcParse", "defaultLocale", "definition", "formatLocale", "nice", "domain", "interval", "i0", "i1", "x0", "x1", "t", "date", "number", "calendar", "ticks", "tickInterval", "year", "month", "week", "day", "hour", "minute", "second", "format", "scale", "continuous", "invert", "domain", "formatMillisecond", "formatSecond", "formatMinute", "formatHour", "formatDay", "formatWeek", "formatMonth", "formatYear", "tickFormat", "y", "_", "interval", "d", "count", "specifier", "nice", "copy", "time", "initRange", "timeTicks", "timeTickInterval", "timeYear", "timeMonth", "timeSunday", "timeDay", "timeHour", "timeMinute", "timeFormat", "colors_default", "specifier", "n", "colors", "Tableau10_default", "colors_default", "constant_default", "x", "abs", "atan2", "cos", "max", "min", "sin", "sqrt", "epsilon", "pi", "halfPi", "tau", "acos", "x", "asin", "pi", "tau", "epsilon", "tauEpsilon", "append", "strings", "i", "n", "appendRound", "digits", "d", "k", "Path", "x", "y", "x1", "y1", "x2", "y2", "r", "x0", "y0", "x21", "y21", "x01", "y01", "l01_2", "x20", "y20", "l21_2", "l20_2", "l21", "l01", "l", "t01", "t21", "a0", "a1", "ccw", "dx", "dy", "cw", "da", "w", "h", "path", "withPath", "shape", "digits", "_", "d", "Path", "arcInnerRadius", "d", "arcOuterRadius", "arcStartAngle", "arcEndAngle", "arcPadAngle", "intersect", "x0", "y0", "x1", "y1", "x2", "y2", "x3", "y3", "x10", "y10", "x32", "y32", "t", "epsilon", "cornerTangents", "r1", "rc", "cw", "x01", "y01", "lo", "sqrt", "ox", "oy", "x11", "y11", "x00", "y00", "dx", "dy", "d2", "r", "D", "max", "cx0", "cy0", "cx1", "cy1", "dx0", "dy0", "dx1", "dy1", "arc_default", "innerRadius", "outerRadius", "cornerRadius", "constant_default", "padRadius", "startAngle", "endAngle", "padAngle", "context", "path", "withPath", "arc", "buffer", "r0", "a0", "halfPi", "a1", "da", "abs", "tau", "cos", "sin", "a01", "a11", "a00", "a10", "da0", "da1", "ap", "rp", "min", "rc0", "rc1", "t0", "t1", "p0", "asin", "p1", "oc", "pi", "ax", "ay", "bx", "by", "kc", "acos", "lc", "atan2", "a", "_", "Linear", "context", "x", "y", "linear_default", "slice", "array_default", "x", "x", "p", "y", "line_default", "x", "y", "defined", "constant_default", "context", "curve", "linear_default", "output", "path", "withPath", "line", "data", "i", "n", "array_default", "d", "defined0", "buffer", "_", "descending_default", "a", "b", "identity_default", "d", "pie_default", "value", "identity_default", "sortValues", "descending_default", "sort", "startAngle", "constant_default", "endAngle", "tau", "padAngle", "pie", "data", "i", "n", "array_default", "j", "k", "sum", "index", "arcs", "a0", "da", "a1", "p", "pa", "v", "_", "point", "that", "x", "y", "Basis", "context", "basis_default", "Bump", "context", "x", "y", "bumpX", "context", "Bump", "bumpY", "noop_default", "BasisClosed", "context", "noop_default", "x", "y", "point", "basisClosed_default", "BasisOpen", "context", "x", "y", "x0", "y0", "point", "basisOpen_default", "Bundle", "context", "beta", "Basis", "x", "y", "j", "x0", "y0", "dx", "dy", "i", "t", "bundle_default", "custom", "bundle", "point", "that", "x", "y", "Cardinal", "context", "tension", "cardinal_default", "custom", "cardinal", "CardinalClosed", "context", "tension", "noop_default", "x", "y", "point", "cardinalClosed_default", "custom", "cardinal", "CardinalOpen", "context", "tension", "x", "y", "point", "cardinalOpen_default", "custom", "cardinal", "point", "that", "x", "y", "x1", "y1", "x2", "y2", "epsilon", "a", "n", "b", "m", "CatmullRom", "context", "alpha", "x23", "y23", "catmullRom_default", "custom", "catmullRom", "Cardinal", "CatmullRomClosed", "context", "alpha", "noop_default", "x", "y", "x23", "y23", "point", "catmullRomClosed_default", "custom", "catmullRom", "CardinalClosed", "CatmullRomOpen", "context", "alpha", "x", "y", "x23", "y23", "point", "catmullRomOpen_default", "custom", "catmullRom", "CardinalOpen", "LinearClosed", "context", "noop_default", "x", "y", "linearClosed_default", "sign", "x", "slope3", "that", "x2", "y2", "h0", "h1", "s0", "s1", "p", "slope2", "t", "h", "point", "t0", "t1", "x0", "y0", "x1", "y1", "dx", "MonotoneX", "context", "y", "MonotoneY", "ReflectContext", "monotoneX", "monotoneY", "Natural", "context", "x", "y", "n", "px", "controlPoints", "py", "i0", "i1", "i", "m", "a", "b", "r", "natural_default", "Step", "context", "t", "x", "y", "x1", "step_default", "stepBefore", "stepAfter", "noop", "dispatch", "i", "n", "_", "t", "Dispatch", "parseTypenames", "typenames", "types", "name", "typename", "callback", "T", "get", "set", "copy", "type", "that", "args", "c", "dispatch_default", "frame", "timeout", "interval", "pokeDelay", "taskHead", "taskTail", "clockLast", "clockNow", "clockSkew", "clock", "setFrame", "f", "now", "clearNow", "Timer", "timer", "callback", "delay", "time", "sleep", "t", "timerFlush", "wake", "nap", "poke", "t0", "t1", "t2", "timeout_default", "callback", "delay", "time", "t", "Timer", "elapsed", "emptyOn", "dispatch_default", "emptyTween", "CREATED", "SCHEDULED", "STARTING", "STARTED", "RUNNING", "ENDING", "ENDED", "schedule_default", "node", "name", "id", "index", "group", "timing", "schedules", "create", "init", "schedule", "get", "set", "self", "tween", "timer", "elapsed", "start", "i", "j", "n", "o", "stop", "timeout_default", "tick", "t", "interrupt_default", "node", "name", "schedules", "schedule", "active", "empty", "i", "STARTING", "ENDING", "ENDED", "interrupt_default", "name", "tweenRemove", "id", "name", "tween0", "tween1", "schedule", "set", "tween", "i", "n", "tweenFunction", "value", "t", "tween_default", "get", "tweenValue", "transition", "node", "interpolate_default", "a", "b", "c", "number_default", "color", "rgb_default", "string_default", "attrRemove", "name", "attrRemoveNS", "fullname", "attrConstant", "interpolate", "value1", "string00", "string1", "interpolate0", "string0", "attrConstantNS", "attrFunction", "value", "string10", "attrFunctionNS", "attr_default", "namespace_default", "interpolateTransformSvg", "interpolate_default", "tweenValue", "attrInterpolate", "name", "i", "t", "attrInterpolateNS", "fullname", "attrTweenNS", "value", "t0", "i0", "tween", "attrTween", "attrTween_default", "key", "namespace_default", "delayFunction", "id", "value", "init", "delayConstant", "delay_default", "get", "durationFunction", "id", "value", "set", "durationConstant", "duration_default", "get", "easeConstant", "id", "value", "set", "ease_default", "get", "easeVarying", "id", "value", "v", "set", "easeVarying_default", "filter_default", "match", "matcher_default", "groups", "m", "subgroups", "j", "group", "n", "subgroup", "node", "i", "Transition", "merge_default", "transition", "groups0", "groups1", "m0", "m1", "m", "merges", "j", "group0", "group1", "n", "merge", "node", "i", "Transition", "start", "name", "t", "i", "onFunction", "id", "listener", "on0", "on1", "sit", "init", "set", "schedule", "on", "on_default", "get", "removeFunction", "id", "parent", "i", "remove_default", "select_default", "select", "name", "id", "selector_default", "groups", "m", "subgroups", "j", "group", "n", "subgroup", "node", "subnode", "i", "schedule_default", "get", "Transition", "selectAll_default", "select", "name", "id", "selectorAll_default", "groups", "m", "subgroups", "parents", "j", "group", "n", "node", "i", "children", "child", "inherit", "get", "k", "l", "schedule_default", "Transition", "Selection", "selection_default", "styleNull", "name", "interpolate", "string00", "string10", "interpolate0", "string0", "styleValue", "string1", "styleRemove", "styleConstant", "value1", "styleFunction", "value", "styleMaybeRemove", "id", "on0", "on1", "listener0", "key", "event", "remove", "schedule", "set", "on", "listener", "style_default", "priority", "interpolateTransformCss", "interpolate_default", "tweenValue", "styleInterpolate", "name", "i", "priority", "t", "styleTween", "value", "i0", "tween", "styleTween_default", "key", "textConstant", "value", "textFunction", "value1", "text_default", "tweenValue", "textInterpolate", "i", "t", "textTween", "value", "t0", "i0", "tween", "textTween_default", "key", "transition_default", "name", "id0", "id1", "newId", "groups", "m", "j", "group", "n", "node", "i", "inherit", "get", "schedule_default", "Transition", "end_default", "on0", "on1", "that", "id", "size", "resolve", "reject", "cancel", "end", "schedule", "set", "on", "id", "Transition", "groups", "parents", "name", "transition", "selection_default", "newId", "selection_prototype", "select_default", "selectAll_default", "filter_default", "merge_default", "transition_default", "on_default", "attr_default", "attrTween_default", "style_default", "styleTween_default", "text_default", "textTween_default", "remove_default", "tween_default", "delay_default", "duration_default", "ease_default", "easeVarying_default", "end_default", "cubicInOut", "defaultTiming", "cubicInOut", "inherit", "node", "id", "timing", "transition_default", "name", "Transition", "newId", "now", "groups", "m", "j", "group", "n", "i", "schedule_default", "selection_default", "interrupt_default", "transition_default", "abs", "max", "min", "number1", "e", "number2", "X", "type", "x", "xy", "Y", "y", "XY", "type", "responseText", "response", "text_default", "input", "init", "parser", "type", "input", "init", "text_default", "text", "xml_default", "html", "svg", "Transform", "k", "x", "y", "point", "location", "identity", "transform", "node", "Channel", "r", "g", "b", "h", "s", "l", "a", "c", "n", "p", "q", "t", "channel", "max", "min", "d", "channel_default", "Lang", "number", "lower", "upper", "lang_default", "Unit", "dec", "hex", "unit_default", "Utils", "channel_default", "lang_default", "unit_default", "utils_default", "DEC2HEX", "i", "utils_default", "TYPE", "Type", "TYPE", "type", "type_default", "Channels", "data", "color", "type_default", "TYPE", "h", "s", "l", "utils_default", "g", "b", "r", "a", "channels_default", "channels", "channels_default", "reusable_default", "Hex", "color", "match", "hex", "dec", "length", "hasAlpha", "isFullLength", "multiplier", "bits", "bitsOffset", "mask", "reusable_default", "channels", "r", "g", "b", "a", "DEC2HEX", "hex_default", "HSL", "hue", "match", "number", "unit", "utils_default", "color", "charCode", "h", "s", "l", "isAlphaPercentage", "reusable_default", "channels", "a", "hsl_default", "Keyword", "color", "hex", "hex_default", "channels", "name", "keyword_default", "RGB", "color", "charCode", "match", "r", "isRedPercentage", "g", "isGreenPercentage", "b", "isBluePercentage", "a", "isAlphaPercentage", "reusable_default", "utils_default", "channels", "rgb_default", "Color", "keyword_default", "hex_default", "rgb_default", "hsl_default", "color", "channels", "TYPE", "color_default", "luminance", "color", "r", "g", "b", "color_default", "utils_default", "luminance_default", "isLight", "color", "luminance_default", "is_light_default", "isDark", "color", "is_light_default", "is_dark_default", "adjustChannel", "color", "channel", "amount", "channels", "color_default", "amountCurrent", "amountNext", "utils_default", "adjust_channel_default", "lighten", "color", "amount", "adjust_channel_default", "lighten_default", "darken", "color", "amount", "adjust_channel_default", "darken_default", "change", "color", "channels", "ch", "color_default", "c", "utils_default", "change_default", "rgba", "r", "g", "b", "a", "change_default", "channels", "reusable_default", "utils_default", "color_default", "rgba_default", "channel", "color", "utils_default", "color_default", "channel_default", "adjust", "color", "channels", "ch", "color_default", "changes", "c", "change_default", "adjust_default", "mix", "color1", "color2", "weight", "r1", "g1", "b1", "a1", "color_default", "r2", "g2", "b2", "a2", "weightScale", "weightNormalized", "alphaDelta", "weight1", "weight2", "r", "g", "b", "a", "rgba_default", "mix_default", "invert", "color", "weight", "inverse", "color_default", "mix_default", "invert_default", "freeGlobal", "freeGlobal_default", "freeSelf", "root", "freeGlobal_default", "root_default", "Symbol", "root_default", "Symbol_default", "objectProto", "hasOwnProperty", "nativeObjectToString", "symToStringTag", "Symbol_default", "getRawTag", "value", "isOwn", "tag", "unmasked", "result", "getRawTag_default", "objectProto", "nativeObjectToString", "objectToString", "value", "objectToString_default", "nullTag", "undefinedTag", "symToStringTag", "Symbol_default", "baseGetTag", "value", "getRawTag_default", "objectToString_default", "baseGetTag_default", "isObject", "value", "type", "isObject_default", "asyncTag", "funcTag", "genTag", "proxyTag", "isFunction", "value", "isObject_default", "tag", "baseGetTag_default", "isFunction_default", "coreJsData", "root_default", "coreJsData_default", "maskSrcKey", "uid", "coreJsData_default", "isMasked", "func", "isMasked_default", "funcProto", "funcToString", "toSource", "func", "toSource_default", "reRegExpChar", "reIsHostCtor", "funcProto", "objectProto", "funcToString", "hasOwnProperty", "reIsNative", "baseIsNative", "value", "isObject_default", "isMasked_default", "pattern", "isFunction_default", "toSource_default", "baseIsNative_default", "getValue", "object", "key", "getValue_default", "getNative", "object", "key", "value", "getValue_default", "baseIsNative_default", "getNative_default", "nativeCreate", "getNative_default", "nativeCreate_default", "hashClear", "nativeCreate_default", "hashClear_default", "hashDelete", "key", "result", "hashDelete_default", "HASH_UNDEFINED", "objectProto", "hasOwnProperty", "hashGet", "key", "data", "nativeCreate_default", "result", "hashGet_default", "objectProto", "hasOwnProperty", "hashHas", "key", "data", "nativeCreate_default", "hashHas_default", "HASH_UNDEFINED", "hashSet", "key", "value", "data", "nativeCreate_default", "hashSet_default", "Hash", "entries", "index", "length", "entry", "hashClear_default", "hashDelete_default", "hashGet_default", "hashHas_default", "hashSet_default", "Hash_default", "listCacheClear", "listCacheClear_default", "eq", "value", "other", "eq_default", "assocIndexOf", "array", "key", "length", "eq_default", "assocIndexOf_default", "arrayProto", "splice", "listCacheDelete", "key", "data", "index", "assocIndexOf_default", "lastIndex", "listCacheDelete_default", "listCacheGet", "key", "data", "index", "assocIndexOf_default", "listCacheGet_default", "listCacheHas", "key", "assocIndexOf_default", "listCacheHas_default", "listCacheSet", "key", "value", "data", "index", "assocIndexOf_default", "listCacheSet_default", "ListCache", "entries", "index", "length", "entry", "listCacheClear_default", "listCacheDelete_default", "listCacheGet_default", "listCacheHas_default", "listCacheSet_default", "ListCache_default", "Map", "getNative_default", "root_default", "Map_default", "mapCacheClear", "Hash_default", "Map_default", "ListCache_default", "mapCacheClear_default", "isKeyable", "value", "type", "isKeyable_default", "getMapData", "map", "key", "data", "isKeyable_default", "getMapData_default", "mapCacheDelete", "key", "result", "getMapData_default", "mapCacheDelete_default", "mapCacheGet", "key", "getMapData_default", "mapCacheGet_default", "mapCacheHas", "key", "getMapData_default", "mapCacheHas_default", "mapCacheSet", "key", "value", "data", "getMapData_default", "size", "mapCacheSet_default", "MapCache", "entries", "index", "length", "entry", "mapCacheClear_default", "mapCacheDelete_default", "mapCacheGet_default", "mapCacheHas_default", "mapCacheSet_default", "MapCache_default", "FUNC_ERROR_TEXT", "memoize", "func", "resolver", "memoized", "args", "key", "cache", "result", "MapCache_default", "memoize_default", "stackClear", "ListCache_default", "stackClear_default", "stackDelete", "key", "data", "result", "stackDelete_default", "stackGet", "key", "stackGet_default", "stackHas", "key", "stackHas_default", "LARGE_ARRAY_SIZE", "stackSet", "key", "value", "data", "ListCache_default", "pairs", "Map_default", "MapCache_default", "stackSet_default", "Stack", "entries", "data", "ListCache_default", "stackClear_default", "stackDelete_default", "stackGet_default", "stackHas_default", "stackSet_default", "Stack_default", "defineProperty", "func", "getNative_default", "defineProperty_default", "baseAssignValue", "object", "key", "value", "defineProperty_default", "baseAssignValue_default", "assignMergeValue", "object", "key", "value", "eq_default", "baseAssignValue_default", "assignMergeValue_default", "createBaseFor", "fromRight", "object", "iteratee", "keysFunc", "index", "iterable", "props", "length", "key", "createBaseFor_default", "baseFor", "createBaseFor_default", "baseFor_default", "freeExports", "freeModule", "moduleExports", "Buffer", "root_default", "allocUnsafe", "cloneBuffer", "buffer", "isDeep", "length", "result", "cloneBuffer_default", "Uint8Array", "root_default", "Uint8Array_default", "cloneArrayBuffer", "arrayBuffer", "result", "Uint8Array_default", "cloneArrayBuffer_default", "cloneTypedArray", "typedArray", "isDeep", "buffer", "cloneArrayBuffer_default", "cloneTypedArray_default", "copyArray", "source", "array", "index", "length", "copyArray_default", "objectCreate", "baseCreate", "object", "proto", "isObject_default", "result", "baseCreate_default", "overArg", "func", "transform", "arg", "overArg_default", "getPrototype", "overArg_default", "getPrototype_default", "objectProto", "isPrototype", "value", "Ctor", "proto", "isPrototype_default", "initCloneObject", "object", "isPrototype_default", "baseCreate_default", "getPrototype_default", "initCloneObject_default", "isObjectLike", "value", "isObjectLike_default", "argsTag", "baseIsArguments", "value", "isObjectLike_default", "baseGetTag_default", "baseIsArguments_default", "objectProto", "hasOwnProperty", "propertyIsEnumerable", "isArguments", "baseIsArguments_default", "value", "isObjectLike_default", "isArguments_default", "isArray", "isArray_default", "MAX_SAFE_INTEGER", "isLength", "value", "isLength_default", "isArrayLike", "value", "isLength_default", "isFunction_default", "isArrayLike_default", "isArrayLikeObject", "value", "isObjectLike_default", "isArrayLike_default", "isArrayLikeObject_default", "stubFalse", "stubFalse_default", "freeExports", "freeModule", "moduleExports", "Buffer", "root_default", "nativeIsBuffer", "isBuffer", "stubFalse_default", "isBuffer_default", "objectTag", "funcProto", "objectProto", "funcToString", "hasOwnProperty", "objectCtorString", "isPlainObject", "value", "isObjectLike_default", "baseGetTag_default", "proto", "getPrototype_default", "Ctor", "isPlainObject_default", "argsTag", "arrayTag", "boolTag", "dateTag", "errorTag", "funcTag", "mapTag", "numberTag", "objectTag", "regexpTag", "setTag", "stringTag", "weakMapTag", "arrayBufferTag", "dataViewTag", "float32Tag", "float64Tag", "int8Tag", "int16Tag", "int32Tag", "uint8Tag", "uint8ClampedTag", "uint16Tag", "uint32Tag", "typedArrayTags", "baseIsTypedArray", "value", "isObjectLike_default", "isLength_default", "baseGetTag_default", "baseIsTypedArray_default", "baseUnary", "func", "value", "baseUnary_default", "freeExports", "freeModule", "moduleExports", "freeProcess", "freeGlobal_default", "nodeUtil", "types", "nodeUtil_default", "nodeIsTypedArray", "nodeUtil_default", "isTypedArray", "baseUnary_default", "baseIsTypedArray_default", "isTypedArray_default", "safeGet", "object", "key", "safeGet_default", "objectProto", "hasOwnProperty", "assignValue", "object", "key", "value", "objValue", "eq_default", "baseAssignValue_default", "assignValue_default", "copyObject", "source", "props", "object", "customizer", "isNew", "index", "length", "key", "newValue", "baseAssignValue_default", "assignValue_default", "copyObject_default", "baseTimes", "n", "iteratee", "index", "result", "baseTimes_default", "MAX_SAFE_INTEGER", "reIsUint", "isIndex", "value", "length", "type", "isIndex_default", "objectProto", "hasOwnProperty", "arrayLikeKeys", "value", "inherited", "isArr", "isArray_default", "isArg", "isArguments_default", "isBuff", "isBuffer_default", "isType", "isTypedArray_default", "skipIndexes", "result", "baseTimes_default", "length", "key", "isIndex_default", "arrayLikeKeys_default", "nativeKeysIn", "object", "result", "key", "nativeKeysIn_default", "objectProto", "hasOwnProperty", "baseKeysIn", "object", "isObject_default", "nativeKeysIn_default", "isProto", "isPrototype_default", "result", "key", "baseKeysIn_default", "keysIn", "object", "isArrayLike_default", "arrayLikeKeys_default", "baseKeysIn_default", "keysIn_default", "toPlainObject", "value", "copyObject_default", "keysIn_default", "toPlainObject_default", "baseMergeDeep", "object", "source", "key", "srcIndex", "mergeFunc", "customizer", "stack", "objValue", "safeGet_default", "srcValue", "stacked", "assignMergeValue_default", "newValue", "isCommon", "isArr", "isArray_default", "isBuff", "isBuffer_default", "isTyped", "isTypedArray_default", "isArrayLikeObject_default", "copyArray_default", "cloneBuffer_default", "cloneTypedArray_default", "isPlainObject_default", "isArguments_default", "toPlainObject_default", "isObject_default", "isFunction_default", "initCloneObject_default", "baseMergeDeep_default", "baseMerge", "object", "source", "srcIndex", "customizer", "stack", "baseFor_default", "srcValue", "key", "Stack_default", "isObject_default", "baseMergeDeep_default", "newValue", "safeGet_default", "assignMergeValue_default", "keysIn_default", "baseMerge_default", "identity", "value", "identity_default", "apply", "func", "thisArg", "args", "apply_default", "nativeMax", "overRest", "func", "start", "transform", "args", "index", "length", "array", "otherArgs", "apply_default", "overRest_default", "constant", "value", "constant_default", "baseSetToString", "defineProperty_default", "func", "string", "constant_default", "identity_default", "baseSetToString_default", "HOT_COUNT", "HOT_SPAN", "nativeNow", "shortOut", "func", "count", "lastCalled", "stamp", "remaining", "shortOut_default", "setToString", "shortOut_default", "baseSetToString_default", "setToString_default", "baseRest", "func", "start", "setToString_default", "overRest_default", "identity_default", "baseRest_default", "isIterateeCall", "value", "index", "object", "isObject_default", "type", "isArrayLike_default", "isIndex_default", "eq_default", "isIterateeCall_default", "createAssigner", "assigner", "baseRest_default", "object", "sources", "index", "length", "customizer", "guard", "isIterateeCall_default", "source", "createAssigner_default", "merge", "createAssigner_default", "object", "source", "srcIndex", "baseMerge_default", "merge_default", "nativeKeys", "overArg_default", "nativeKeys_default", "objectProto", "hasOwnProperty", "baseKeys", "object", "isPrototype_default", "nativeKeys_default", "result", "key", "baseKeys_default", "DataView", "getNative_default", "root_default", "DataView_default", "Promise", "getNative_default", "root_default", "Promise_default", "Set", "getNative_default", "root_default", "Set_default", "WeakMap", "getNative_default", "root_default", "WeakMap_default", "mapTag", "objectTag", "promiseTag", "setTag", "weakMapTag", "dataViewTag", "dataViewCtorString", "toSource_default", "DataView_default", "mapCtorString", "Map_default", "promiseCtorString", "Promise_default", "setCtorString", "Set_default", "weakMapCtorString", "WeakMap_default", "getTag", "baseGetTag_default", "value", "result", "Ctor", "ctorString", "getTag_default", "mapTag", "setTag", "objectProto", "hasOwnProperty", "isEmpty", "value", "isArrayLike_default", "isArray_default", "isBuffer_default", "isTypedArray_default", "isArguments_default", "tag", "getTag_default", "isPrototype_default", "baseKeys_default", "key", "isEmpty_default", "import_dayjs", "import_sanitize_url", "import_dompurify", "COMMENT", "RULESET", "DECLARATION", "IMPORT", "KEYFRAMES", "abs", "from", "trim", "value", "replace", "value", "pattern", "replacement", "indexof", "search", "charat", "index", "substr", "begin", "end", "strlen", "sizeof", "append", "array", "line", "column", "length", "position", "character", "characters", "node", "value", "root", "parent", "type", "props", "children", "char", "character", "prev", "position", "charat", "characters", "column", "line", "next", "length", "peek", "caret", "slice", "begin", "end", "substr", "token", "type", "alloc", "value", "strlen", "dealloc", "delimit", "trim", "delimiter", "whitespace", "type", "character", "peek", "next", "token", "escaping", "index", "count", "next", "character", "slice", "caret", "peek", "delimiter", "type", "position", "commenter", "from", "identifier", "token", "compile", "value", "dealloc", "parse", "alloc", "root", "parent", "rule", "rules", "rulesets", "pseudo", "points", "declarations", "index", "offset", "length", "atrule", "property", "previous", "variable", "scanning", "ampersand", "character", "type", "props", "children", "reference", "characters", "next", "charat", "indexof", "replace", "delimit", "whitespace", "escaping", "caret", "peek", "append", "comment", "commenter", "strlen", "declaration", "ruleset", "prev", "from", "identifier", "post", "size", "sizeof", "i", "j", "k", "x", "y", "substr", "abs", "z", "trim", "node", "RULESET", "COMMENT", "char", "DECLARATION", "serialize", "children", "callback", "output", "length", "sizeof", "i", "stringify", "element", "index", "IMPORT", "DECLARATION", "COMMENT", "KEYFRAMES", "RULESET", "strlen", "LEVELS", "log$1", "_args", "setLogLevel$1", "level", "numericLevel", "format", "dayjs", "lineBreakRegex", "getRows", "s", "breakToPlaceholder", "removeScript", "txt", "DOMPurify", "sanitizeMore", "text", "config2", "_a", "placeholderToBreak", "sanitizeText$2", "sanitizeTextOrArray", "a", "x", "hasBreaks", "splitBreaks", "getUrl", "useAbsolute", "url", "evaluate", "val", "getMax", "values", "newValues", "value", "getMin", "parseGenericTypes", "input", "inputSets", "output", "thisSet", "previousSet", "nextSet", "shouldCombineSets", "processSet", "countOccurrence", "string", "substring", "prevCount", "nextCount", "tildeCount", "hasStartingTilde", "chars", "first", "last", "common$1", "mkBorder", "col", "darkMode", "adjust_default", "oldAttributeBackgroundColorOdd", "oldAttributeBackgroundColorEven", "Theme$4", "_b", "_c", "_d", "_e", "_f", "_g", "_h", "_i", "_j", "_k", "invert_default", "darken_default", "lighten_default", "i", "multiplier", "is_dark_default", "overrides", "keys", "k", "getThemeVariables$4", "userOverrides", "theme2", "Theme$3", "rgba_default", "getThemeVariables$3", "Theme$2", "getThemeVariables$2", "Theme$1", "getThemeVariables$1", "Theme5", "getThemeVariables", "theme", "defaultConfigJson", "config", "keyify", "obj", "prefix", "res", "el", "configKeys", "defaultConfig$2", "sanitizeDirective", "args", "arg", "key", "cssMatchers", "cssKey", "sanitizeCss", "str2", "startCnt", "endCnt", "element", "frontMatterRegex", "directiveRegex", "anyCommentRegex", "UnknownDiagramError", "message", "detectors", "detectType", "detector2", "registerLazyLoadedDiagrams", "diagrams2", "id2", "loader2", "addDetector", "getDiagramLoader", "assignWithDepth", "dst", "src", "depth", "clobber", "assignWithDepth$1", "ZERO_WIDTH_SPACE", "d3CurveTypes", "basis_default", "basisClosed_default", "basisOpen_default", "bumpX", "bumpY", "bundle_default", "cardinalClosed_default", "cardinalOpen_default", "cardinal_default", "catmullRomClosed_default", "catmullRomOpen_default", "catmullRom_default", "linear_default", "linearClosed_default", "monotoneX", "monotoneY", "natural_default", "step_default", "stepAfter", "stepBefore", "directiveWithoutOpen", "detectInit", "inits", "detectDirective", "results", "init2", "type2", "prop", "commentWithoutDirectives", "match", "result", "type22", "error", "removeDirectives", "isSubstringInArray", "arr", "interpolateToCurve", "interpolate", "defaultCurve", "curveName", "formatUrl", "linkStr", "runFunc", "functionName", "params", "arrPaths", "len", "fnName", "distance", "p1", "p2", "traverseEdge", "points", "prevPoint", "totalDistance", "point", "remainingDistance", "calculatePoint", "calcLabelPosition", "roundNumber", "num", "precision", "factor", "distanceToTraverse", "vectorDistance", "distanceRatio", "calcCardinalityPosition", "isRelationTypePresent", "initialPosition", "center", "d", "angle", "cardinalityPosition", "calcTerminalLabelPosition", "terminalMarkerSize", "position", "_points", "distanceToCardinalityPoint", "getStylesFromArray", "style", "labelStyle", "cnt", "generateId", "makeRandomHex", "length", "characters", "charactersLength", "random", "options", "getTextObj", "drawSimpleText", "elem", "textData", "nText", "_fontSizePx", "parseFontSize", "textElem", "span", "wrapLabel", "memoize_default", "label", "maxWidth", "words", "completedLines", "nextLine", "word", "index", "wordLength", "calculateTextWidth", "nextLineLength", "hyphenatedStrings", "remainingWord", "breakString", "line", "hyphenCharacter", "lines", "currentLine", "character", "currentCharacter", "isLastLine", "hyphenatedNextLine", "calculateTextHeight", "calculateTextDimensions", "fontSize", "fontFamily", "fontWeight", "fontFamilies", "dims", "body", "select_default", "g", "fontFamily2", "cHeight", "dim", "textObj", "bBox", "InitIDGenerator", "deterministic", "seed", "decoder", "entityDecode", "html", "isDetailedError", "insertTitle", "parent", "cssClass", "titleTopMargin", "title", "bounds", "fontSizeNumber", "cleanAndMerge", "defaultData", "data", "merge_default", "utils", "version", "defaultConfig$1", "siteConfig", "configFromInitialize", "directives", "currentConfig", "updateCurrentConfig", "siteCfg", "_directives", "cfg", "sumOfDirectives", "sanitize", "tmpConfigFromInitialize", "themeVariables", "checkConfig", "setSiteConfig", "conf", "saveConfigFromInitialize", "updateSiteConfig", "getSiteConfig", "setConfig$1", "getConfig$1", "addDirective", "directive", "reset", "ConfigWarning", "issuedWarnings", "issueWarning", "warning", "id$k", "detector$k", "loader$l", "diagram2", "plugin$i", "c4", "id$j", "detector$j", "loader$k", "plugin$h", "flowchart", "id$i", "detector$i", "loader$j", "plugin$g", "flowchartV2", "id$h", "detector$h", "loader$i", "plugin$f", "er", "id$g", "detector$g", "loader$h", "plugin$e", "git", "id$f", "detector$f", "loader$g", "plugin$d", "gantt", "id$e", "detector$e", "loader$f", "info", "id$d", "detector$d", "loader$e", "pie", "id$c", "detector$c", "loader$d", "plugin$c", "quadrantChart", "id$b", "detector$b", "loader$c", "plugin$b", "xychart", "id$a", "detector$a", "loader$b", "plugin$a", "requirement", "id$9", "detector$9", "loader$a", "plugin$9", "sequence", "id$8", "detector$8", "loader$9", "plugin$8", "classDiagram", "id$7", "detector$7", "loader$8", "plugin$7", "classDiagramV2", "id$6", "detector$6", "loader$7", "plugin$6", "state", "id$5", "detector$5", "loader$6", "plugin$5", "stateV2", "id$4", "detector$4", "loader$5", "plugin$4", "journey", "d3Attrs", "d3Elem", "attrs", "attr", "calculateSvgSizeAttrs", "height", "width", "useMaxWidth", "configureSvgSize", "svgElem", "setupGraphViewbox$1", "graph", "padding", "svgBounds", "sWidth", "sHeight", "vBox", "themes", "getStyles", "userStyles", "diagramStyles", "addStylesForDiagram", "diagramTheme", "getStyles$1", "accTitle", "diagramTitle", "accDescription", "sanitizeText$1", "clear", "setAccTitle", "getAccTitle", "setAccDescription", "getAccDescription", "setDiagramTitle", "getDiagramTitle", "commonDb", "log", "setLogLevel", "getConfig", "setConfig", "defaultConfig", "sanitizeText", "setupGraphViewbox", "getCommonDb", "diagrams", "registerDiagram", "getDiagram", "name", "DiagramNotFoundError", "selectSvgElement", "securityLevel", "root", "doc", "draw", "_text", "version2", "svg", "renderer", "errorRenderer", "diagram", "errorDiagram", "id$3", "detector$3", "loader$4", "plugin$3", "flowchartElk", "id$2", "detector$2", "loader$3", "plugin$2", "timeline", "id$1", "detector$1", "loader$2", "plugin$1", "mindmap", "id", "detector", "loader$1", "plugin", "sankey", "hasLoadedDiagrams", "addDiagrams", "Diagram", "metadata", "cnf", "e", "getDiagramFromText", "interactionFunctions", "addFunction", "func", "attachFunctions", "f", "SVG_ROLE", "setA11yDiagramInfo", "diagramType", "addSVGa11yTitleDescription", "a11yTitle", "a11yDesc", "baseId", "descId", "titleId", "cleanupComments", "isNothing", "subject", "isObject", "toArray", "sequence2", "extend", "target", "source", "sourceKeys", "repeat", "count", "cycle", "isNegativeZero", "number", "isNothing_1", "isObject_1", "toArray_1", "repeat_1", "isNegativeZero_1", "extend_1", "common", "formatError", "exception2", "compact", "where", "YAMLException$1", "reason", "mark", "exception", "getLine", "buffer", "lineStart", "lineEnd", "maxLineLength", "head", "tail", "maxHalfLength", "padStart", "max", "makeSnippet", "re", "lineStarts", "lineEnds", "foundLineNo", "lineNoLength", "snippet", "TYPE_CONSTRUCTOR_OPTIONS", "YAML_NODE_KINDS", "compileStyleAliases", "map2", "alias", "Type$1", "tag", "type", "compileList", "schema2", "currentType", "newIndex", "previousType", "previousIndex", "compileMap", "collectType", "Schema$1", "definition", "implicit", "explicit", "type$1", "schema", "str", "seq", "map", "failsafe", "resolveYamlNull", "constructYamlNull", "isNull", "object", "_null", "resolveYamlBoolean", "constructYamlBoolean", "isBoolean", "bool", "isHexCode", "c", "isOctCode", "isDecCode", "resolveYamlInteger", "hasDigits", "ch", "constructYamlInteger", "sign", "isInteger", "int", "YAML_FLOAT_PATTERN", "resolveYamlFloat", "constructYamlFloat", "SCIENTIFIC_WITHOUT_DOT", "representYamlFloat", "isFloat", "float", "json", "core", "YAML_DATE_REGEXP", "YAML_TIMESTAMP_REGEXP", "resolveYamlTimestamp", "constructYamlTimestamp", "year", "month", "day", "hour", "minute", "second", "fraction", "delta", "tz_hour", "tz_minute", "date", "representYamlTimestamp", "timestamp", "resolveYamlMerge", "merge", "BASE64_MAP", "resolveYamlBinary", "code", "idx", "bitlen", "constructYamlBinary", "tailbits", "bits", "representYamlBinary", "isBinary", "binary", "_hasOwnProperty$3", "_toString$2", "resolveYamlOmap", "objectKeys", "pair", "pairKey", "pairHasKey", "constructYamlOmap", "omap", "_toString$1", "resolveYamlPairs", "constructYamlPairs", "pairs", "_hasOwnProperty$2", "resolveYamlSet", "constructYamlSet", "set", "_default", "_hasOwnProperty$1", "CONTEXT_FLOW_IN", "CONTEXT_FLOW_OUT", "CONTEXT_BLOCK_IN", "CONTEXT_BLOCK_OUT", "CHOMPING_CLIP", "CHOMPING_STRIP", "CHOMPING_KEEP", "PATTERN_NON_PRINTABLE", "PATTERN_NON_ASCII_LINE_BREAKS", "PATTERN_FLOW_INDICATORS", "PATTERN_TAG_HANDLE", "PATTERN_TAG_URI", "_class", "is_EOL", "is_WHITE_SPACE", "is_WS_OR_EOL", "is_FLOW_INDICATOR", "fromHexCode", "lc", "escapedHexLen", "fromDecimalCode", "simpleEscapeSequence", "charFromCodepoint", "simpleEscapeCheck", "simpleEscapeMap", "State$1", "generateError", "state2", "throwError", "throwWarning", "directiveHandlers", "major", "minor", "handle", "captureSegment", "start", "end", "checkJson", "_position", "_length", "_character", "_result", "mergeMappings", "destination", "overridableKeys", "quantity", "storeMappingPair", "keyTag", "keyNode", "valueNode", "startLine", "startLineStart", "startPos", "readLineBreak", "skipSeparationSpace", "allowComments", "checkIndent", "lineBreaks", "testDocumentSeparator", "writeFoldedLines", "readPlainScalar", "nodeIndent", "withinFlowCollection", "preceding", "following", "captureStart", "captureEnd", "hasPendingContent", "_line", "_lineStart", "_lineIndent", "_kind", "readSingleQuotedScalar", "readDoubleQuotedScalar", "hexLength", "hexResult", "tmp", "readFlowCollection", "readNext", "_pos", "_tag", "_anchor", "terminator", "isPair", "isExplicitPair", "isMapping", "composeNode", "readBlockScalar", "folding", "chomping", "didReadContent", "detectedIndent", "textIndent", "emptyLines", "atMoreIndented", "readBlockSequence", "detected", "readBlockMapping", "flowIndent", "allowCompact", "_keyLine", "_keyLineStart", "_keyPos", "atExplicitKey", "readTagProperty", "isVerbatim", "isNamed", "tagHandle", "tagName", "readAnchorProperty", "readAlias", "parentIndent", "nodeContext", "allowToSeek", "allowBlockStyles", "allowBlockScalars", "allowBlockCollections", "indentStatus", "atNewLine", "hasContent", "typeIndex", "typeQuantity", "typeList", "blockIndent", "readDocument", "documentStart", "directiveName", "directiveArgs", "hasDirectives", "loadDocuments", "nullpos", "loadAll$1", "iterator", "documents", "load$1", "loadAll_1", "load_1", "loader", "JSON_SCHEMA", "load", "extractFrontMatter", "matches", "parsed", "cleanupText", "attributes", "processFrontmatter", "displayMode", "processDirectives", "initDirective", "wrapDirectives", "preprocessDiagram", "cleanedCode", "frontMatterResult", "directiveResult", "MAX_TEXTLENGTH", "MAX_TEXTLENGTH_EXCEEDED_MSG", "SECURITY_LVL_SANDBOX", "SECURITY_LVL_LOOSE", "XMLNS_SVG_STD", "XMLNS_XLINK_STD", "XMLNS_XHTML_STD", "IFRAME_WIDTH", "IFRAME_HEIGHT", "IFRAME_STYLES", "IFRAME_BODY_STYLE", "IFRAME_SANDBOX_OPTS", "IFRAME_NOT_SUPPORTED_MSG", "DOMPURIFY_TAGS", "DOMPURIFY_ATTR", "processAndSetConfigs", "processed", "parse$1", "parseOptions", "encodeEntities", "innerTxt", "decodeEntities", "cssImportantStyles", "cssClasses", "createCssStyles", "classDefs", "cssStyles", "isEmpty_default", "cssElements", "classId", "styleClassDef", "cssElement", "createUserStyles", "graphType", "svgId", "userCSSstyles", "allStyles", "serialize", "compile", "stringify", "cleanUpSvgCode", "svgCode", "inSandboxMode", "useArrowMarkerUrls", "cleanedUpSvg", "putIntoIFrame", "svgElement", "base64encodedSrc", "appendDivSvgG", "parentRoot", "enclosingDivId", "divStyle", "svgXlink", "enclosingDiv", "svgNode", "sandboxedIframe", "parentNode", "iFrameId", "removeExistingElements", "divId", "render$1", "svgContainingElement", "idSelector", "iFrameID", "iFrameID_selector", "enclosingDivID", "enclosingDivID_selector", "isSandboxed", "isLooseSecurityLevel", "iframe", "diag", "parseEncounteredException", "firstChild", "diagramClassDefs", "rules", "style1", "a11yDescr", "addA11yInfo", "svgEl", "node", "initialize$1", "mermaidAPI", "loadRegisteredDiagrams", "failed", "err", "handleError", "errors", "parseError", "run", "runThrowsErrors", "mermaid", "postRenderCallback", "querySelector", "nodes", "nodesToProcess", "idGenerator", "dedent", "bindFunctions", "render", "initialize", "init", "callback", "runOptions", "registerExternalDiagrams", "lazyLoad", "contentLoaded", "startOnLoad", "setParseErrorHandler", "parseErrorHandler", "executionQueue", "executionQueueRunning", "executeQueue", "parse", "resolve", "reject", "performCall", "rej", "r", "container"] } diff --git a/docs/public/chunk-3BJWU2V2.min.js b/docs/public/chunk-NAH225X5.min.js similarity index 99% rename from docs/public/chunk-3BJWU2V2.min.js rename to docs/public/chunk-NAH225X5.min.js index 39f3a56e..8bb7e9d0 100644 --- a/docs/public/chunk-3BJWU2V2.min.js +++ b/docs/public/chunk-NAH225X5.min.js @@ -1,4 +1,4 @@ -import{$ as _e,Aa as nr,Ba as hr,Ca as Ur,Da as jr,Ea as B,Fa as Wr,P as ze,Q as k,R as Pr,S as D,T as Rr,U as Mr,V as Ke,W as Ve,X as H,Y as He,Z as Fr,_ as Xe,aa as Br,ba as Ze,ca as $e,da as Je,ea as Qe,fa as F,ga as Dr,ha as _,ia as rt,ja as G,ka as et,la as Tr,na as mr,oa as pr,pa as tt,qa as lr,ra as X,sa as Gr,ta as ot,ua as U,va as j,wa as nt,xa as P,ya as at,za as cr}from"./chunk-65WDIALL.min.js";var Vn="[object Symbol]";function Hn(r){return typeof r=="symbol"||F(r)&&Pr(r)==Vn}var N=Hn;function Xn(r,e){for(var t=-1,o=r==null?0:r.length,n=Array(o);++t-1}var bt=ha;function xa(r){return G(r)?ot(r):Ur(r)}var E=xa;var _a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,va=/^\w*$/;function ga(r,e){if(_(r))return!1;var t=typeof r;return t=="number"||t=="symbol"||t=="boolean"||r==null||N(r)?!0:va.test(r)||!_a.test(r)||e!=null&&r in Object(e)}var _r=ga;var ba=500;function ya(r){var e=Ve(r,function(o){return t.size===ba&&t.clear(),o}),t=e.cache;return e}var yt=ya;var wa=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ea=/\\(\\)?/g,Ia=yt(function(r){var e=[];return r.charCodeAt(0)===46&&e.push(""),r.replace(wa,function(t,o,n,a){e.push(n?a.replace(Ea,"$1"):o||t)}),e}),wt=Ia;function Aa(r){return r==null?"":ut(r)}var zr=Aa;function Ta(r,e){return _(r)?r:_r(r,e)?[r]:wt(zr(r))}var Z=Ta;var Oa=1/0;function Sa(r){if(typeof r=="string"||N(r))return r;var e=r+"";return e=="0"&&1/r==-Oa?"-0":e}var q=Sa;function La(r,e){e=Z(e,r);for(var t=0,o=e.length;r!=null&&t0&&t(f)?e>1?Tt(f,e-1,t,o,n):vr(n,f):o||(n[n.length]=f)}return n}var gr=Tt;function Pa(r){var e=r==null?0:r.length;return e?gr(r,1):[]}var R=Pa;function Ra(r){return at(nt(r,void 0,R),r+"")}var Ot=Ra;var Ma="\\ud800-\\udfff",Fa="\\u0300-\\u036f",Ba="\\ufe20-\\ufe2f",Da="\\u20d0-\\u20ff",Ga=Fa+Ba+Da,Ua="\\ufe0e\\ufe0f",ja="\\u200d",Wa=RegExp("["+ja+Ma+Ga+Ua+"]");function qa(r){return Wa.test(r)}var St=qa;function Ya(r,e,t,o){var n=-1,a=r==null?0:r.length;for(o&&a&&(t=r[++n]);++nf))return!1;var u=a.get(r),m=a.get(e);if(u&&m)return u==e&&m==r;var p=-1,l=!0,x=t&Ef?new Qr:void 0;for(a.set(r,e),a.set(e,r);++p2?e[2]:void 0;for(n&&nr(e[0],e[1],n)&&(o=1);++t-1?n[a?e[i]:i]:void 0}}var wo=Es;var Is=Math.max;function As(r,e,t){var o=r==null?0:r.length;if(!o)return-1;var n=t==null?0:ht(t);return n<0&&(n=Is(o+n,0)),Yr(r,O(e,3),n)}var Eo=As;var Ts=wo(Eo),Ir=Ts;function Os(r,e){var t=-1,o=G(r)?Array(r.length):[];return J(r,function(n,a,i){o[++t]=e(n,a,i)}),o}var de=Os;function Ss(r,e){var t=_(r)?W:de;return t(r,O(e,3))}var g=Ss;function Ls(r,e){return r==null?r:Fr(r,Er(e),U)}var ye=Ls;function Ns(r,e){return r&&wr(r,Er(e))}var we=Ns;function Cs(r,e){return r>e}var Io=Cs;var ks=Object.prototype,Ps=ks.hasOwnProperty;function Rs(r,e){return r!=null&&Ps.call(r,e)}var Ao=Rs;function Ms(r,e){return r!=null&&ie(r,e,Ao)}var c=Ms;var Fs="[object String]";function Bs(r){return typeof r=="string"||!_(r)&&F(r)&&Pr(r)==Fs}var To=Bs;function Ds(r,e){return W(e,function(t){return r[t]})}var Oo=Ds;function Gs(r){return r==null?[]:Oo(r,E(r))}var C=Gs;function Us(r){return r===void 0}var I=Us;function js(r,e){return re||a&&i&&s&&!f&&!u||o&&i&&s||!t&&s||!n)return 1;if(!o&&!a&&!u&&r=f)return s;var u=t[o];return s*(u=="desc"?-1:1)}}return r.index-e.index}var ko=$s;function Js(r,e,t){e.length?e=W(e,function(a){return _(a)?function(i){return $(i,a.length===1?a[0]:a)}:a}):e=[j];var o=-1;e=W(e,mr(O));var n=de(r,function(a,i,f){var s=W(e,function(u){return u(a)});return{criteria:s,index:++o,value:a}});return No(n,function(a,i){return ko(a,i,t)})}var Po=Js;var Qs=se("length"),Ro=Qs;var Fo="\\ud800-\\udfff",ru="\\u0300-\\u036f",eu="\\ufe20-\\ufe2f",tu="\\u20d0-\\u20ff",ou=ru+eu+tu,nu="\\ufe0e\\ufe0f",au="["+Fo+"]",Ee="["+ou+"]",Ie="\\ud83c[\\udffb-\\udfff]",iu="(?:"+Ee+"|"+Ie+")",Bo="[^"+Fo+"]",Do="(?:\\ud83c[\\udde6-\\uddff]){2}",Go="[\\ud800-\\udbff][\\udc00-\\udfff]",fu="\\u200d",Uo=iu+"?",jo="["+nu+"]?",su="(?:"+fu+"(?:"+[Bo,Do,Go].join("|")+")"+jo+Uo+")*",uu=jo+Uo+su,du="(?:"+[Bo+Ee+"?",Ee,Do,Go,au].join("|")+")",Mo=RegExp(Ie+"(?="+Ie+")|"+du+uu,"g");function mu(r){for(var e=Mo.lastIndex=0;Mo.test(r);)++e;return e}var Wo=mu;function pu(r){return St(r)?Wo(r):Ro(r)}var qo=pu;function lu(r,e){return Lo(r,e,function(t,o){return fe(r,o)})}var Yo=lu;var cu=Ot(function(r,e){return r==null?{}:Yo(r,e)}),fr=cu;var hu=Math.ceil,xu=Math.max;function _u(r,e,t,o){for(var n=-1,a=xu(hu((e-r)/(t||1)),0),i=Array(a);a--;)i[o?a:++n]=r,r+=t;return i}var zo=_u;function vu(r){return function(e,t,o){return o&&typeof o!="number"&&nr(e,t,o)&&(t=o=void 0),e=xr(e),t===void 0?(t=e,e=0):t=xr(t),o=o===void 0?e1&&nr(r,e[0],e[1])?e=[]:t>2&&nr(e[0],e[1],e[2])&&(e=[e[0]]),Po(r,gr(e,1),[])}),z=Au;var Tu=1/0,Ou=jr&&1/yr(new jr([,-0]))[1]==Tu?function(r){return new jr(r)}:xt,Ho=Ou;var Su=200;function Lu(r,e,t){var o=-1,n=bt,a=r.length,i=!0,f=[],s=f;if(t)i=!1,n=bo;else if(a>=Su){var u=e?null:Ho(r);if(u)return yr(u);i=!1,n=re,s=new Qr}else s=e?[]:f;r:for(;++o1?n.setNode(a,t):n.setNode(a)}),this}setNode(e,t){return c(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=ur,this._children[e]={},this._children[ur][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return c(this._nodes,e)}removeNode(e){var t=this;if(c(this._nodes,e)){var o=function(n){t.removeEdge(t._edgeObjs[n])};delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],d(this.children(e),function(n){t.setParent(n)}),delete this._children[e]),d(E(this._in[e]),o),delete this._in[e],delete this._preds[e],d(E(this._out[e]),o),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(I(t))t=ur;else{t+="";for(var o=t;!I(o);o=this.parent(o))if(o===e)throw new Error("Setting "+t+" as parent of "+e+" would create a cycle");this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==ur)return t}}children(e){if(I(e)&&(e=ur),this._isCompound){var t=this._children[e];if(t)return E(t)}else{if(e===ur)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var t=this._preds[e];if(t)return E(t)}successors(e){var t=this._sucs[e];if(t)return E(t)}neighbors(e){var t=this.predecessors(e);if(t)return Te(t,this.successors(e))}isLeaf(e){var t;return this.isDirected()?t=this.successors(e):t=this.neighbors(e),t.length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var o=this;d(this._nodes,function(i,f){e(f)&&t.setNode(f,i)}),d(this._edgeObjs,function(i){t.hasNode(i.v)&&t.hasNode(i.w)&&t.setEdge(i,o.edge(i))});var n={};function a(i){var f=o.parent(i);return f===void 0||t.hasNode(f)?(n[i]=f,f):f in n?n[f]:a(f)}return this._isCompound&&d(t.nodes(),function(i){t.setParent(i,a(i))}),t}setDefaultEdgeLabel(e){return Rr(e)||(e=P(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return C(this._edgeObjs)}setPath(e,t){var o=this,n=arguments;return Y(e,function(a,i){return n.length>1?o.setEdge(a,i,t):o.setEdge(a,i),i}),this}setEdge(){var e,t,o,n,a=!1,i=arguments[0];typeof i=="object"&&i!==null&&"v"in i?(e=i.v,t=i.w,o=i.name,arguments.length===2&&(n=arguments[1],a=!0)):(e=i,t=arguments[1],o=arguments[3],arguments.length>2&&(n=arguments[2],a=!0)),e=""+e,t=""+t,I(o)||(o=""+o);var f=Sr(this._isDirected,e,t,o);if(c(this._edgeLabels,f))return a&&(this._edgeLabels[f]=n),this;if(!I(o)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[f]=a?n:this._defaultEdgeLabelFn(e,t,o);var s=Fu(this._isDirected,e,t,o);return e=s.v,t=s.w,Object.freeze(s),this._edgeObjs[f]=s,Jo(this._preds[t],e),Jo(this._sucs[e],t),this._in[t][f]=s,this._out[e][f]=s,this._edgeCount++,this}edge(e,t,o){var n=arguments.length===1?Oe(this._isDirected,arguments[0]):Sr(this._isDirected,e,t,o);return this._edgeLabels[n]}hasEdge(e,t,o){var n=arguments.length===1?Oe(this._isDirected,arguments[0]):Sr(this._isDirected,e,t,o);return c(this._edgeLabels,n)}removeEdge(e,t,o){var n=arguments.length===1?Oe(this._isDirected,arguments[0]):Sr(this._isDirected,e,t,o),a=this._edgeObjs[n];return a&&(e=a.v,t=a.w,delete this._edgeLabels[n],delete this._edgeObjs[n],Qo(this._preds[t],e),Qo(this._sucs[e],t),delete this._in[t][n],delete this._out[e][n],this._edgeCount--),this}inEdges(e,t){var o=this._in[e];if(o){var n=C(o);return t?S(n,function(a){return a.v===t}):n}}outEdges(e,t){var o=this._out[e];if(o){var n=C(o);return t?S(n,function(a){return a.w===t}):n}}nodeEdges(e,t){var o=this.inEdges(e,t);if(o)return o.concat(this.outEdges(e,t))}};A.prototype._nodeCount=0;A.prototype._edgeCount=0;function Jo(r,e){r[e]?r[e]++:r[e]=1}function Qo(r,e){--r[e]||delete r[e]}function Sr(r,e,t,o){var n=""+e,a=""+t;if(!r&&n>a){var i=n;n=a,a=i}return n+$o+a+$o+(I(o)?Mu:o)}function Fu(r,e,t,o){var n=""+e,a=""+t;if(!r&&n>a){var i=n;n=a,a=i}var f={v:n,w:a};return o&&(f.name=o),f}function Oe(r,e){return Sr(r,e.v,e.w,e.name)}function K(r,e,t,o){var n;do n=sr(o);while(r.hasNode(n));return t.dummy=e,r.setNode(n,t),n}function rn(r){var e=new A().setGraph(r.graph());return d(r.nodes(),function(t){e.setNode(t,r.node(t))}),d(r.edges(),function(t){var o=e.edge(t.v,t.w)||{weight:0,minlen:1},n=r.edge(t);e.setEdge(t.v,t.w,{weight:o.weight+n.weight,minlen:Math.max(o.minlen,n.minlen)})}),e}function le(r){var e=new A({multigraph:r.isMultigraph()}).setGraph(r.graph());return d(r.nodes(),function(t){r.children(t).length||e.setNode(t,r.node(t))}),d(r.edges(),function(t){e.setEdge(t,r.edge(t))}),e}function Se(r,e){var t=r.x,o=r.y,n=e.x-t,a=e.y-o,i=r.width/2,f=r.height/2;if(!n&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var s,u;return Math.abs(a)*i>Math.abs(n)*f?(a<0&&(f=-f),s=f*n/a,u=f):(n<0&&(i=-i),s=i,u=i*a/n),{x:t+s,y:o+u}}function rr(r){var e=g(M(Ne(r)+1),function(){return[]});return d(r.nodes(),function(t){var o=r.node(t),n=o.rank;I(n)||(e[n][o.order]=t)}),e}function en(r){var e=V(g(r.nodes(),function(t){return r.node(t).rank}));d(r.nodes(),function(t){var o=r.node(t);c(o,"rank")&&(o.rank-=e)})}function tn(r){var e=V(g(r.nodes(),function(a){return r.node(a).rank})),t=[];d(r.nodes(),function(a){var i=r.node(a).rank-e;t[i]||(t[i]=[]),t[i].push(a)});var o=0,n=r.graph().nodeRankFactor;d(t,function(a,i){I(a)&&i%n!==0?--o:o&&d(a,function(f){r.node(f).rank+=o})})}function Le(r,e,t,o){var n={width:0,height:0};return arguments.length>=4&&(n.rank=t,n.order=o),K(r,"border",n,e)}function Ne(r){return L(g(r.nodes(),function(e){var t=r.node(e).rank;if(!I(t))return t}))}function on(r,e){var t={lhs:[],rhs:[]};return d(r,function(o){e(o)?t.lhs.push(o):t.rhs.push(o)}),t}function nn(r,e){var t=ue();try{return e()}finally{console.log(r+" time: "+(ue()-t)+"ms")}}function an(r,e){return e()}function sn(r){function e(t){var o=r.children(t),n=r.node(t);if(o.length&&d(o,e),c(n,"minRank")){n.borderLeft=[],n.borderRight=[];for(var a=n.minRank,i=n.maxRank+1;a0;--f)if(i=e[f].dequeue(),i){o=o.concat(Pe(r,e,t,i,!0));break}}}return o}function Pe(r,e,t,o,n){var a=n?[]:void 0;return d(r.inEdges(o.v),function(i){var f=r.edge(i),s=r.node(i.v);n&&a.push({v:i.v,w:i.w}),s.out-=f,Re(e,t,s)}),d(r.outEdges(o.v),function(i){var f=r.edge(i),s=i.w,u=r.node(s);u.in-=f,Re(e,t,u)}),r.removeNode(o.v),a}function qu(r,e){var t=new A,o=0,n=0;d(r.nodes(),function(f){t.setNode(f,{v:f,in:0,out:0})}),d(r.edges(),function(f){var s=t.edge(f.v,f.w)||0,u=e(f),m=s+u;t.setEdge(f.v,f.w,m),n=Math.max(n,t.node(f.v).out+=u),o=Math.max(o,t.node(f.w).in+=u)});var a=M(n+o+3).map(function(){return new ce}),i=o+1;return d(t.nodes(),function(f){Re(a,i,t.node(f))}),{graph:t,buckets:a,zeroIdx:i}}function Re(r,e,t){t.out?t.in?r[t.out-t.in+e].enqueue(t):r[r.length-1].enqueue(t):r[0].enqueue(t)}function hn(r){var e=r.graph().acyclicer==="greedy"?cn(r,t(r)):Yu(r);d(e,function(o){var n=r.edge(o);r.removeEdge(o),n.forwardName=o.name,n.reversed=!0,r.setEdge(o.w,o.v,n,sr("rev"))});function t(o){return function(n){return o.edge(n).weight}}}function Yu(r){var e=[],t={},o={};function n(a){c(o,a)||(o[a]=!0,t[a]=!0,d(r.outEdges(a),function(i){c(t,i.w)?e.push(i):n(i.w)}),delete t[a])}return d(r.nodes(),n),e}function xn(r){d(r.edges(),function(e){var t=r.edge(e);if(t.reversed){r.removeEdge(e);var o=t.forwardName;delete t.reversed,delete t.forwardName,r.setEdge(e.w,e.v,t,o)}})}function vn(r){r.graph().dummyChains=[],d(r.edges(),function(e){zu(r,e)})}function zu(r,e){var t=e.v,o=r.node(t).rank,n=e.w,a=r.node(n).rank,i=e.name,f=r.edge(e),s=f.labelRank;if(a!==o+1){r.removeEdge(e);var u,m,p;for(p=0,++o;oi.lim&&(f=i,s=!0);var u=S(e.edges(),function(m){return s===wn(r,r.node(m.v),f)&&s!==wn(r,r.node(m.w),f)});return ir(u,function(m){return dr(e,m)})}function On(r,e,t,o){var n=t.v,a=t.w;r.removeEdge(n,a),r.setEdge(o.v,o.w,{}),Ge(r),De(r,e),rd(r,e)}function rd(r,e){var t=Ir(r.nodes(),function(n){return!e.node(n).parent}),o=Be(r,t);o=o.slice(1),d(o,function(n){var a=r.node(n).parent,i=e.edge(n,a),f=!1;i||(i=e.edge(a,n),f=!0),e.node(n).rank=e.node(a).rank+(f?i.minlen:-i.minlen)})}function ed(r,e,t){return r.hasEdge(e,t)}function wn(r,e,t){return t.low<=e.lim&&e.lim<=t.lim}function Ue(r){switch(r.graph().ranker){case"network-simplex":Sn(r);break;case"tight-tree":od(r);break;case"longest-path":td(r);break;default:Sn(r)}}var td=Lr;function od(r){Lr(r),he(r)}function Sn(r){tr(r)}function Ln(r){var e=K(r,"root",{},"_root"),t=nd(r),o=L(C(t))-1,n=2*o+1;r.graph().nestingRoot=e,d(r.edges(),function(i){r.edge(i).minlen*=n});var a=ad(r)+1;d(r.children(),function(i){Nn(r,e,n,a,o,t,i)}),r.graph().nodeRankFactor=n}function Nn(r,e,t,o,n,a,i){var f=r.children(i);if(!f.length){i!==e&&r.setEdge(e,i,{weight:0,minlen:t});return}var s=Le(r,"_bt"),u=Le(r,"_bb"),m=r.node(i);r.setParent(s,i),m.borderTop=s,r.setParent(u,i),m.borderBottom=u,d(f,function(p){Nn(r,e,t,o,n,a,p);var l=r.node(p),x=l.borderTop?l.borderTop:p,h=l.borderBottom?l.borderBottom:p,v=l.borderTop?o:2*o,w=x!==h?1:n-a[i]+1;r.setEdge(s,x,{weight:v,minlen:w,nestingEdge:!0}),r.setEdge(h,u,{weight:v,minlen:w,nestingEdge:!0})}),r.parent(i)||r.setEdge(e,s,{weight:0,minlen:n+a[i]})}function nd(r){var e={};function t(o,n){var a=r.children(o);a&&a.length&&d(a,function(i){t(i,n+1)}),e[o]=n}return d(r.children(),function(o){t(o,1)}),e}function ad(r){return Y(r.edges(),function(e,t){return e+r.edge(t).weight},0)}function Cn(r){var e=r.graph();r.removeNode(e.nestingRoot),delete e.nestingRoot,d(r.edges(),function(t){var o=r.edge(t);o.nestingEdge&&r.removeEdge(t)})}function kn(r,e,t){var o={},n;d(t,function(a){for(var i=r.parent(a),f,s;i;){if(f=r.parent(i),f?(s=o[f],o[f]=i):(s=n,n=i),s&&s!==i){e.setEdge(s,i);return}i=f}})}function Pn(r,e,t){var o=fd(r),n=new A({compound:!0}).setGraph({root:o}).setDefaultNodeLabel(function(a){return r.node(a)});return d(r.nodes(),function(a){var i=r.node(a),f=r.parent(a);(i.rank===e||i.minRank<=e&&e<=i.maxRank)&&(n.setNode(a),n.setParent(a,f||o),d(r[t](a),function(s){var u=s.v===a?s.w:s.v,m=n.edge(u,a),p=I(m)?0:m.weight;n.setEdge(u,a,{weight:r.edge(s).weight+p})}),c(i,"minRank")&&n.setNode(a,{borderLeft:i.borderLeft[e],borderRight:i.borderRight[e]}))}),n}function fd(r){for(var e;r.hasNode(e=sr("_root")););return e}function Rn(r,e){for(var t=0,o=1;o0;)m%2&&(p+=f[m+1]),m=m-1>>1,f[m]+=u.weight;s+=u.weight*p})),s}function Mn(r){var e={},t=S(r.nodes(),function(f){return!r.children(f).length}),o=L(g(t,function(f){return r.node(f).rank})),n=g(M(o+1),function(){return[]});function a(f){if(!c(e,f)){e[f]=!0;var s=r.node(f);n[s.rank].push(f),d(r.successors(f),a)}}var i=z(t,function(f){return r.node(f).rank});return d(i,a),n}function Fn(r,e){return g(e,function(t){var o=r.inEdges(t);if(o.length){var n=Y(o,function(a,i){var f=r.edge(i),s=r.node(i.v);return{sum:a.sum+f.weight*s.order,weight:a.weight+f.weight}},{sum:0,weight:0});return{v:t,barycenter:n.sum/n.weight,weight:n.weight}}else return{v:t}})}function Bn(r,e){var t={};d(r,function(n,a){var i=t[n.v]={indegree:0,in:[],out:[],vs:[n.v],i:a};I(n.barycenter)||(i.barycenter=n.barycenter,i.weight=n.weight)}),d(e.edges(),function(n){var a=t[n.v],i=t[n.w];!I(a)&&!I(i)&&(i.indegree++,a.out.push(t[n.w]))});var o=S(t,function(n){return!n.indegree});return ud(o)}function ud(r){var e=[];function t(a){return function(i){i.merged||(I(i.barycenter)||I(a.barycenter)||i.barycenter>=a.barycenter)&&dd(a,i)}}function o(a){return function(i){i.in.push(a),--i.indegree===0&&r.push(i)}}for(;r.length;){var n=r.pop();e.push(n),d(n.in.reverse(),t(n)),d(n.out,o(n))}return g(S(e,function(a){return!a.merged}),function(a){return fr(a,["vs","i","barycenter","weight"])})}function dd(r,e){var t=0,o=0;r.weight&&(t+=r.barycenter*r.weight,o+=r.weight),e.weight&&(t+=e.barycenter*e.weight,o+=e.weight),r.vs=e.vs.concat(r.vs),r.barycenter=t/o,r.weight=o,r.i=Math.min(e.i,r.i),e.merged=!0}function Gn(r,e){var t=on(r,function(m){return c(m,"barycenter")}),o=t.lhs,n=z(t.rhs,function(m){return-m.i}),a=[],i=0,f=0,s=0;o.sort(md(!!e)),s=Dn(a,n,s),d(o,function(m){s+=m.vs.length,a.push(m.vs),i+=m.barycenter*m.weight,f+=m.weight,s=Dn(a,n,s)});var u={vs:R(a)};return f&&(u.barycenter=i/f,u.weight=f),u}function Dn(r,e,t){for(var o;e.length&&(o=Q(e)).i<=t;)e.pop(),r.push(o.vs),t++;return t}function md(r){return function(e,t){return e.barycentert.barycenter?1:r?t.i-e.i:e.i-t.i}}function je(r,e,t,o){var n=r.children(e),a=r.node(e),i=a?a.borderLeft:void 0,f=a?a.borderRight:void 0,s={};i&&(n=S(n,function(h){return h!==i&&h!==f}));var u=Fn(r,n);d(u,function(h){if(r.children(h.v).length){var v=je(r,h.v,t,o);s[h.v]=v,c(v,"barycenter")&&ld(h,v)}});var m=Bn(u,t);pd(m,s);var p=Gn(m,o);if(i&&(p.vs=R([i,p.vs,f]),r.predecessors(i).length)){var l=r.node(r.predecessors(i)[0]),x=r.node(r.predecessors(f)[0]);c(p,"barycenter")||(p.barycenter=0,p.weight=0),p.barycenter=(p.barycenter*p.weight+l.order+x.order)/(p.weight+2),p.weight+=2}return p}function pd(r,e){d(r,function(t){t.vs=R(t.vs.map(function(o){return e[o]?e[o].vs:o}))})}function ld(r,e){I(r.barycenter)?(r.barycenter=e.barycenter,r.weight=e.weight):(r.barycenter=(r.barycenter*r.weight+e.barycenter*e.weight)/(r.weight+e.weight),r.weight+=e.weight)}function Wn(r){var e=Ne(r),t=Un(r,M(1,e+1),"inEdges"),o=Un(r,M(e-1,-1,-1),"outEdges"),n=Mn(r);jn(r,n);for(var a=Number.POSITIVE_INFINITY,i,f=0,s=0;s<4;++f,++s){cd(f%2?t:o,f%4>=2),n=rr(r);var u=Rn(r,n);ui||f>e[s].lim));for(u=s,s=o;(s=r.parent(s))!==u;)a.push(s);return{path:n.concat(a.reverse()),lca:u}}function xd(r){var e={},t=0;function o(n){var a=t;d(r.children(n),o),e[n]={low:a,lim:t++}}return d(r.children(),o),e}function _d(r,e){var t={};function o(n,a){var i=0,f=0,s=n.length,u=Q(a);return d(a,function(m,p){var l=gd(r,m),x=l?r.node(l).order:s;(l||m===u)&&(d(a.slice(f,p+1),function(h){d(r.predecessors(h),function(v){var w=r.node(v),T=w.order;(Tu)&&Yn(t,l,m)})})}function n(a,i){var f=-1,s,u=0;return d(i,function(m,p){if(r.node(m).dummy==="border"){var l=r.predecessors(m);l.length&&(s=r.node(l[0]).order,o(i,u,p,f,s),u=p,f=s)}o(i,u,i.length,s,a.length)}),i}return Y(e,n),t}function gd(r,e){if(r.node(e).dummy)return Ir(r.predecessors(e),function(t){return r.node(t).dummy})}function Yn(r,e,t){if(e>t){var o=e;e=t,t=o}var n=r[e];n||(r[e]=n={}),n[t]=!0}function bd(r,e,t){if(e>t){var o=e;e=t,t=o}return c(r[e],t)}function yd(r,e,t,o){var n={},a={},i={};return d(e,function(f){d(f,function(s,u){n[s]=s,a[s]=s,i[s]=u})}),d(e,function(f){var s=-1;d(f,function(u){var m=o(u);if(m.length){m=z(m,function(v){return i[v]});for(var p=(m.length-1)/2,l=Math.floor(p),x=Math.ceil(p);l<=x;++l){var h=m[l];a[u]===u&&s-1}var bt=ha;function xa(r){return G(r)?ot(r):Ur(r)}var E=xa;var _a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,va=/^\w*$/;function ga(r,e){if(_(r))return!1;var t=typeof r;return t=="number"||t=="symbol"||t=="boolean"||r==null||N(r)?!0:va.test(r)||!_a.test(r)||e!=null&&r in Object(e)}var _r=ga;var ba=500;function ya(r){var e=Ve(r,function(o){return t.size===ba&&t.clear(),o}),t=e.cache;return e}var yt=ya;var wa=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Ea=/\\(\\)?/g,Ia=yt(function(r){var e=[];return r.charCodeAt(0)===46&&e.push(""),r.replace(wa,function(t,o,n,a){e.push(n?a.replace(Ea,"$1"):o||t)}),e}),wt=Ia;function Aa(r){return r==null?"":ut(r)}var zr=Aa;function Ta(r,e){return _(r)?r:_r(r,e)?[r]:wt(zr(r))}var Z=Ta;var Oa=1/0;function Sa(r){if(typeof r=="string"||N(r))return r;var e=r+"";return e=="0"&&1/r==-Oa?"-0":e}var q=Sa;function La(r,e){e=Z(e,r);for(var t=0,o=e.length;r!=null&&t0&&t(f)?e>1?Tt(f,e-1,t,o,n):vr(n,f):o||(n[n.length]=f)}return n}var gr=Tt;function Pa(r){var e=r==null?0:r.length;return e?gr(r,1):[]}var R=Pa;function Ra(r){return at(nt(r,void 0,R),r+"")}var Ot=Ra;var Ma="\\ud800-\\udfff",Fa="\\u0300-\\u036f",Ba="\\ufe20-\\ufe2f",Da="\\u20d0-\\u20ff",Ga=Fa+Ba+Da,Ua="\\ufe0e\\ufe0f",ja="\\u200d",Wa=RegExp("["+ja+Ma+Ga+Ua+"]");function qa(r){return Wa.test(r)}var St=qa;function Ya(r,e,t,o){var n=-1,a=r==null?0:r.length;for(o&&a&&(t=r[++n]);++nf))return!1;var u=a.get(r),m=a.get(e);if(u&&m)return u==e&&m==r;var p=-1,l=!0,x=t&Ef?new Qr:void 0;for(a.set(r,e),a.set(e,r);++p2?e[2]:void 0;for(n&&nr(e[0],e[1],n)&&(o=1);++t-1?n[a?e[i]:i]:void 0}}var wo=Es;var Is=Math.max;function As(r,e,t){var o=r==null?0:r.length;if(!o)return-1;var n=t==null?0:ht(t);return n<0&&(n=Is(o+n,0)),Yr(r,O(e,3),n)}var Eo=As;var Ts=wo(Eo),Ir=Ts;function Os(r,e){var t=-1,o=G(r)?Array(r.length):[];return J(r,function(n,a,i){o[++t]=e(n,a,i)}),o}var de=Os;function Ss(r,e){var t=_(r)?W:de;return t(r,O(e,3))}var g=Ss;function Ls(r,e){return r==null?r:Fr(r,Er(e),U)}var ye=Ls;function Ns(r,e){return r&&wr(r,Er(e))}var we=Ns;function Cs(r,e){return r>e}var Io=Cs;var ks=Object.prototype,Ps=ks.hasOwnProperty;function Rs(r,e){return r!=null&&Ps.call(r,e)}var Ao=Rs;function Ms(r,e){return r!=null&&ie(r,e,Ao)}var c=Ms;var Fs="[object String]";function Bs(r){return typeof r=="string"||!_(r)&&F(r)&&Pr(r)==Fs}var To=Bs;function Ds(r,e){return W(e,function(t){return r[t]})}var Oo=Ds;function Gs(r){return r==null?[]:Oo(r,E(r))}var C=Gs;function Us(r){return r===void 0}var I=Us;function js(r,e){return re||a&&i&&s&&!f&&!u||o&&i&&s||!t&&s||!n)return 1;if(!o&&!a&&!u&&r=f)return s;var u=t[o];return s*(u=="desc"?-1:1)}}return r.index-e.index}var ko=$s;function Js(r,e,t){e.length?e=W(e,function(a){return _(a)?function(i){return $(i,a.length===1?a[0]:a)}:a}):e=[j];var o=-1;e=W(e,mr(O));var n=de(r,function(a,i,f){var s=W(e,function(u){return u(a)});return{criteria:s,index:++o,value:a}});return No(n,function(a,i){return ko(a,i,t)})}var Po=Js;var Qs=se("length"),Ro=Qs;var Fo="\\ud800-\\udfff",ru="\\u0300-\\u036f",eu="\\ufe20-\\ufe2f",tu="\\u20d0-\\u20ff",ou=ru+eu+tu,nu="\\ufe0e\\ufe0f",au="["+Fo+"]",Ee="["+ou+"]",Ie="\\ud83c[\\udffb-\\udfff]",iu="(?:"+Ee+"|"+Ie+")",Bo="[^"+Fo+"]",Do="(?:\\ud83c[\\udde6-\\uddff]){2}",Go="[\\ud800-\\udbff][\\udc00-\\udfff]",fu="\\u200d",Uo=iu+"?",jo="["+nu+"]?",su="(?:"+fu+"(?:"+[Bo,Do,Go].join("|")+")"+jo+Uo+")*",uu=jo+Uo+su,du="(?:"+[Bo+Ee+"?",Ee,Do,Go,au].join("|")+")",Mo=RegExp(Ie+"(?="+Ie+")|"+du+uu,"g");function mu(r){for(var e=Mo.lastIndex=0;Mo.test(r);)++e;return e}var Wo=mu;function pu(r){return St(r)?Wo(r):Ro(r)}var qo=pu;function lu(r,e){return Lo(r,e,function(t,o){return fe(r,o)})}var Yo=lu;var cu=Ot(function(r,e){return r==null?{}:Yo(r,e)}),fr=cu;var hu=Math.ceil,xu=Math.max;function _u(r,e,t,o){for(var n=-1,a=xu(hu((e-r)/(t||1)),0),i=Array(a);a--;)i[o?a:++n]=r,r+=t;return i}var zo=_u;function vu(r){return function(e,t,o){return o&&typeof o!="number"&&nr(e,t,o)&&(t=o=void 0),e=xr(e),t===void 0?(t=e,e=0):t=xr(t),o=o===void 0?e1&&nr(r,e[0],e[1])?e=[]:t>2&&nr(e[0],e[1],e[2])&&(e=[e[0]]),Po(r,gr(e,1),[])}),z=Au;var Tu=1/0,Ou=jr&&1/yr(new jr([,-0]))[1]==Tu?function(r){return new jr(r)}:xt,Ho=Ou;var Su=200;function Lu(r,e,t){var o=-1,n=bt,a=r.length,i=!0,f=[],s=f;if(t)i=!1,n=bo;else if(a>=Su){var u=e?null:Ho(r);if(u)return yr(u);i=!1,n=re,s=new Qr}else s=e?[]:f;r:for(;++o1?n.setNode(a,t):n.setNode(a)}),this}setNode(e,t){return c(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=ur,this._children[e]={},this._children[ur][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return c(this._nodes,e)}removeNode(e){var t=this;if(c(this._nodes,e)){var o=function(n){t.removeEdge(t._edgeObjs[n])};delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],d(this.children(e),function(n){t.setParent(n)}),delete this._children[e]),d(E(this._in[e]),o),delete this._in[e],delete this._preds[e],d(E(this._out[e]),o),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(I(t))t=ur;else{t+="";for(var o=t;!I(o);o=this.parent(o))if(o===e)throw new Error("Setting "+t+" as parent of "+e+" would create a cycle");this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==ur)return t}}children(e){if(I(e)&&(e=ur),this._isCompound){var t=this._children[e];if(t)return E(t)}else{if(e===ur)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var t=this._preds[e];if(t)return E(t)}successors(e){var t=this._sucs[e];if(t)return E(t)}neighbors(e){var t=this.predecessors(e);if(t)return Te(t,this.successors(e))}isLeaf(e){var t;return this.isDirected()?t=this.successors(e):t=this.neighbors(e),t.length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var o=this;d(this._nodes,function(i,f){e(f)&&t.setNode(f,i)}),d(this._edgeObjs,function(i){t.hasNode(i.v)&&t.hasNode(i.w)&&t.setEdge(i,o.edge(i))});var n={};function a(i){var f=o.parent(i);return f===void 0||t.hasNode(f)?(n[i]=f,f):f in n?n[f]:a(f)}return this._isCompound&&d(t.nodes(),function(i){t.setParent(i,a(i))}),t}setDefaultEdgeLabel(e){return Rr(e)||(e=P(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return C(this._edgeObjs)}setPath(e,t){var o=this,n=arguments;return Y(e,function(a,i){return n.length>1?o.setEdge(a,i,t):o.setEdge(a,i),i}),this}setEdge(){var e,t,o,n,a=!1,i=arguments[0];typeof i=="object"&&i!==null&&"v"in i?(e=i.v,t=i.w,o=i.name,arguments.length===2&&(n=arguments[1],a=!0)):(e=i,t=arguments[1],o=arguments[3],arguments.length>2&&(n=arguments[2],a=!0)),e=""+e,t=""+t,I(o)||(o=""+o);var f=Sr(this._isDirected,e,t,o);if(c(this._edgeLabels,f))return a&&(this._edgeLabels[f]=n),this;if(!I(o)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[f]=a?n:this._defaultEdgeLabelFn(e,t,o);var s=Fu(this._isDirected,e,t,o);return e=s.v,t=s.w,Object.freeze(s),this._edgeObjs[f]=s,Jo(this._preds[t],e),Jo(this._sucs[e],t),this._in[t][f]=s,this._out[e][f]=s,this._edgeCount++,this}edge(e,t,o){var n=arguments.length===1?Oe(this._isDirected,arguments[0]):Sr(this._isDirected,e,t,o);return this._edgeLabels[n]}hasEdge(e,t,o){var n=arguments.length===1?Oe(this._isDirected,arguments[0]):Sr(this._isDirected,e,t,o);return c(this._edgeLabels,n)}removeEdge(e,t,o){var n=arguments.length===1?Oe(this._isDirected,arguments[0]):Sr(this._isDirected,e,t,o),a=this._edgeObjs[n];return a&&(e=a.v,t=a.w,delete this._edgeLabels[n],delete this._edgeObjs[n],Qo(this._preds[t],e),Qo(this._sucs[e],t),delete this._in[t][n],delete this._out[e][n],this._edgeCount--),this}inEdges(e,t){var o=this._in[e];if(o){var n=C(o);return t?S(n,function(a){return a.v===t}):n}}outEdges(e,t){var o=this._out[e];if(o){var n=C(o);return t?S(n,function(a){return a.w===t}):n}}nodeEdges(e,t){var o=this.inEdges(e,t);if(o)return o.concat(this.outEdges(e,t))}};A.prototype._nodeCount=0;A.prototype._edgeCount=0;function Jo(r,e){r[e]?r[e]++:r[e]=1}function Qo(r,e){--r[e]||delete r[e]}function Sr(r,e,t,o){var n=""+e,a=""+t;if(!r&&n>a){var i=n;n=a,a=i}return n+$o+a+$o+(I(o)?Mu:o)}function Fu(r,e,t,o){var n=""+e,a=""+t;if(!r&&n>a){var i=n;n=a,a=i}var f={v:n,w:a};return o&&(f.name=o),f}function Oe(r,e){return Sr(r,e.v,e.w,e.name)}function K(r,e,t,o){var n;do n=sr(o);while(r.hasNode(n));return t.dummy=e,r.setNode(n,t),n}function rn(r){var e=new A().setGraph(r.graph());return d(r.nodes(),function(t){e.setNode(t,r.node(t))}),d(r.edges(),function(t){var o=e.edge(t.v,t.w)||{weight:0,minlen:1},n=r.edge(t);e.setEdge(t.v,t.w,{weight:o.weight+n.weight,minlen:Math.max(o.minlen,n.minlen)})}),e}function le(r){var e=new A({multigraph:r.isMultigraph()}).setGraph(r.graph());return d(r.nodes(),function(t){r.children(t).length||e.setNode(t,r.node(t))}),d(r.edges(),function(t){e.setEdge(t,r.edge(t))}),e}function Se(r,e){var t=r.x,o=r.y,n=e.x-t,a=e.y-o,i=r.width/2,f=r.height/2;if(!n&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var s,u;return Math.abs(a)*i>Math.abs(n)*f?(a<0&&(f=-f),s=f*n/a,u=f):(n<0&&(i=-i),s=i,u=i*a/n),{x:t+s,y:o+u}}function rr(r){var e=g(M(Ne(r)+1),function(){return[]});return d(r.nodes(),function(t){var o=r.node(t),n=o.rank;I(n)||(e[n][o.order]=t)}),e}function en(r){var e=V(g(r.nodes(),function(t){return r.node(t).rank}));d(r.nodes(),function(t){var o=r.node(t);c(o,"rank")&&(o.rank-=e)})}function tn(r){var e=V(g(r.nodes(),function(a){return r.node(a).rank})),t=[];d(r.nodes(),function(a){var i=r.node(a).rank-e;t[i]||(t[i]=[]),t[i].push(a)});var o=0,n=r.graph().nodeRankFactor;d(t,function(a,i){I(a)&&i%n!==0?--o:o&&d(a,function(f){r.node(f).rank+=o})})}function Le(r,e,t,o){var n={width:0,height:0};return arguments.length>=4&&(n.rank=t,n.order=o),K(r,"border",n,e)}function Ne(r){return L(g(r.nodes(),function(e){var t=r.node(e).rank;if(!I(t))return t}))}function on(r,e){var t={lhs:[],rhs:[]};return d(r,function(o){e(o)?t.lhs.push(o):t.rhs.push(o)}),t}function nn(r,e){var t=ue();try{return e()}finally{console.log(r+" time: "+(ue()-t)+"ms")}}function an(r,e){return e()}function sn(r){function e(t){var o=r.children(t),n=r.node(t);if(o.length&&d(o,e),c(n,"minRank")){n.borderLeft=[],n.borderRight=[];for(var a=n.minRank,i=n.maxRank+1;a0;--f)if(i=e[f].dequeue(),i){o=o.concat(Pe(r,e,t,i,!0));break}}}return o}function Pe(r,e,t,o,n){var a=n?[]:void 0;return d(r.inEdges(o.v),function(i){var f=r.edge(i),s=r.node(i.v);n&&a.push({v:i.v,w:i.w}),s.out-=f,Re(e,t,s)}),d(r.outEdges(o.v),function(i){var f=r.edge(i),s=i.w,u=r.node(s);u.in-=f,Re(e,t,u)}),r.removeNode(o.v),a}function qu(r,e){var t=new A,o=0,n=0;d(r.nodes(),function(f){t.setNode(f,{v:f,in:0,out:0})}),d(r.edges(),function(f){var s=t.edge(f.v,f.w)||0,u=e(f),m=s+u;t.setEdge(f.v,f.w,m),n=Math.max(n,t.node(f.v).out+=u),o=Math.max(o,t.node(f.w).in+=u)});var a=M(n+o+3).map(function(){return new ce}),i=o+1;return d(t.nodes(),function(f){Re(a,i,t.node(f))}),{graph:t,buckets:a,zeroIdx:i}}function Re(r,e,t){t.out?t.in?r[t.out-t.in+e].enqueue(t):r[r.length-1].enqueue(t):r[0].enqueue(t)}function hn(r){var e=r.graph().acyclicer==="greedy"?cn(r,t(r)):Yu(r);d(e,function(o){var n=r.edge(o);r.removeEdge(o),n.forwardName=o.name,n.reversed=!0,r.setEdge(o.w,o.v,n,sr("rev"))});function t(o){return function(n){return o.edge(n).weight}}}function Yu(r){var e=[],t={},o={};function n(a){c(o,a)||(o[a]=!0,t[a]=!0,d(r.outEdges(a),function(i){c(t,i.w)?e.push(i):n(i.w)}),delete t[a])}return d(r.nodes(),n),e}function xn(r){d(r.edges(),function(e){var t=r.edge(e);if(t.reversed){r.removeEdge(e);var o=t.forwardName;delete t.reversed,delete t.forwardName,r.setEdge(e.w,e.v,t,o)}})}function vn(r){r.graph().dummyChains=[],d(r.edges(),function(e){zu(r,e)})}function zu(r,e){var t=e.v,o=r.node(t).rank,n=e.w,a=r.node(n).rank,i=e.name,f=r.edge(e),s=f.labelRank;if(a!==o+1){r.removeEdge(e);var u,m,p;for(p=0,++o;oi.lim&&(f=i,s=!0);var u=S(e.edges(),function(m){return s===wn(r,r.node(m.v),f)&&s!==wn(r,r.node(m.w),f)});return ir(u,function(m){return dr(e,m)})}function On(r,e,t,o){var n=t.v,a=t.w;r.removeEdge(n,a),r.setEdge(o.v,o.w,{}),Ge(r),De(r,e),rd(r,e)}function rd(r,e){var t=Ir(r.nodes(),function(n){return!e.node(n).parent}),o=Be(r,t);o=o.slice(1),d(o,function(n){var a=r.node(n).parent,i=e.edge(n,a),f=!1;i||(i=e.edge(a,n),f=!0),e.node(n).rank=e.node(a).rank+(f?i.minlen:-i.minlen)})}function ed(r,e,t){return r.hasEdge(e,t)}function wn(r,e,t){return t.low<=e.lim&&e.lim<=t.lim}function Ue(r){switch(r.graph().ranker){case"network-simplex":Sn(r);break;case"tight-tree":od(r);break;case"longest-path":td(r);break;default:Sn(r)}}var td=Lr;function od(r){Lr(r),he(r)}function Sn(r){tr(r)}function Ln(r){var e=K(r,"root",{},"_root"),t=nd(r),o=L(C(t))-1,n=2*o+1;r.graph().nestingRoot=e,d(r.edges(),function(i){r.edge(i).minlen*=n});var a=ad(r)+1;d(r.children(),function(i){Nn(r,e,n,a,o,t,i)}),r.graph().nodeRankFactor=n}function Nn(r,e,t,o,n,a,i){var f=r.children(i);if(!f.length){i!==e&&r.setEdge(e,i,{weight:0,minlen:t});return}var s=Le(r,"_bt"),u=Le(r,"_bb"),m=r.node(i);r.setParent(s,i),m.borderTop=s,r.setParent(u,i),m.borderBottom=u,d(f,function(p){Nn(r,e,t,o,n,a,p);var l=r.node(p),x=l.borderTop?l.borderTop:p,h=l.borderBottom?l.borderBottom:p,v=l.borderTop?o:2*o,w=x!==h?1:n-a[i]+1;r.setEdge(s,x,{weight:v,minlen:w,nestingEdge:!0}),r.setEdge(h,u,{weight:v,minlen:w,nestingEdge:!0})}),r.parent(i)||r.setEdge(e,s,{weight:0,minlen:n+a[i]})}function nd(r){var e={};function t(o,n){var a=r.children(o);a&&a.length&&d(a,function(i){t(i,n+1)}),e[o]=n}return d(r.children(),function(o){t(o,1)}),e}function ad(r){return Y(r.edges(),function(e,t){return e+r.edge(t).weight},0)}function Cn(r){var e=r.graph();r.removeNode(e.nestingRoot),delete e.nestingRoot,d(r.edges(),function(t){var o=r.edge(t);o.nestingEdge&&r.removeEdge(t)})}function kn(r,e,t){var o={},n;d(t,function(a){for(var i=r.parent(a),f,s;i;){if(f=r.parent(i),f?(s=o[f],o[f]=i):(s=n,n=i),s&&s!==i){e.setEdge(s,i);return}i=f}})}function Pn(r,e,t){var o=fd(r),n=new A({compound:!0}).setGraph({root:o}).setDefaultNodeLabel(function(a){return r.node(a)});return d(r.nodes(),function(a){var i=r.node(a),f=r.parent(a);(i.rank===e||i.minRank<=e&&e<=i.maxRank)&&(n.setNode(a),n.setParent(a,f||o),d(r[t](a),function(s){var u=s.v===a?s.w:s.v,m=n.edge(u,a),p=I(m)?0:m.weight;n.setEdge(u,a,{weight:r.edge(s).weight+p})}),c(i,"minRank")&&n.setNode(a,{borderLeft:i.borderLeft[e],borderRight:i.borderRight[e]}))}),n}function fd(r){for(var e;r.hasNode(e=sr("_root")););return e}function Rn(r,e){for(var t=0,o=1;o0;)m%2&&(p+=f[m+1]),m=m-1>>1,f[m]+=u.weight;s+=u.weight*p})),s}function Mn(r){var e={},t=S(r.nodes(),function(f){return!r.children(f).length}),o=L(g(t,function(f){return r.node(f).rank})),n=g(M(o+1),function(){return[]});function a(f){if(!c(e,f)){e[f]=!0;var s=r.node(f);n[s.rank].push(f),d(r.successors(f),a)}}var i=z(t,function(f){return r.node(f).rank});return d(i,a),n}function Fn(r,e){return g(e,function(t){var o=r.inEdges(t);if(o.length){var n=Y(o,function(a,i){var f=r.edge(i),s=r.node(i.v);return{sum:a.sum+f.weight*s.order,weight:a.weight+f.weight}},{sum:0,weight:0});return{v:t,barycenter:n.sum/n.weight,weight:n.weight}}else return{v:t}})}function Bn(r,e){var t={};d(r,function(n,a){var i=t[n.v]={indegree:0,in:[],out:[],vs:[n.v],i:a};I(n.barycenter)||(i.barycenter=n.barycenter,i.weight=n.weight)}),d(e.edges(),function(n){var a=t[n.v],i=t[n.w];!I(a)&&!I(i)&&(i.indegree++,a.out.push(t[n.w]))});var o=S(t,function(n){return!n.indegree});return ud(o)}function ud(r){var e=[];function t(a){return function(i){i.merged||(I(i.barycenter)||I(a.barycenter)||i.barycenter>=a.barycenter)&&dd(a,i)}}function o(a){return function(i){i.in.push(a),--i.indegree===0&&r.push(i)}}for(;r.length;){var n=r.pop();e.push(n),d(n.in.reverse(),t(n)),d(n.out,o(n))}return g(S(e,function(a){return!a.merged}),function(a){return fr(a,["vs","i","barycenter","weight"])})}function dd(r,e){var t=0,o=0;r.weight&&(t+=r.barycenter*r.weight,o+=r.weight),e.weight&&(t+=e.barycenter*e.weight,o+=e.weight),r.vs=e.vs.concat(r.vs),r.barycenter=t/o,r.weight=o,r.i=Math.min(e.i,r.i),e.merged=!0}function Gn(r,e){var t=on(r,function(m){return c(m,"barycenter")}),o=t.lhs,n=z(t.rhs,function(m){return-m.i}),a=[],i=0,f=0,s=0;o.sort(md(!!e)),s=Dn(a,n,s),d(o,function(m){s+=m.vs.length,a.push(m.vs),i+=m.barycenter*m.weight,f+=m.weight,s=Dn(a,n,s)});var u={vs:R(a)};return f&&(u.barycenter=i/f,u.weight=f),u}function Dn(r,e,t){for(var o;e.length&&(o=Q(e)).i<=t;)e.pop(),r.push(o.vs),t++;return t}function md(r){return function(e,t){return e.barycentert.barycenter?1:r?t.i-e.i:e.i-t.i}}function je(r,e,t,o){var n=r.children(e),a=r.node(e),i=a?a.borderLeft:void 0,f=a?a.borderRight:void 0,s={};i&&(n=S(n,function(h){return h!==i&&h!==f}));var u=Fn(r,n);d(u,function(h){if(r.children(h.v).length){var v=je(r,h.v,t,o);s[h.v]=v,c(v,"barycenter")&&ld(h,v)}});var m=Bn(u,t);pd(m,s);var p=Gn(m,o);if(i&&(p.vs=R([i,p.vs,f]),r.predecessors(i).length)){var l=r.node(r.predecessors(i)[0]),x=r.node(r.predecessors(f)[0]);c(p,"barycenter")||(p.barycenter=0,p.weight=0),p.barycenter=(p.barycenter*p.weight+l.order+x.order)/(p.weight+2),p.weight+=2}return p}function pd(r,e){d(r,function(t){t.vs=R(t.vs.map(function(o){return e[o]?e[o].vs:o}))})}function ld(r,e){I(r.barycenter)?(r.barycenter=e.barycenter,r.weight=e.weight):(r.barycenter=(r.barycenter*r.weight+e.barycenter*e.weight)/(r.weight+e.weight),r.weight+=e.weight)}function Wn(r){var e=Ne(r),t=Un(r,M(1,e+1),"inEdges"),o=Un(r,M(e-1,-1,-1),"outEdges"),n=Mn(r);jn(r,n);for(var a=Number.POSITIVE_INFINITY,i,f=0,s=0;s<4;++f,++s){cd(f%2?t:o,f%4>=2),n=rr(r);var u=Rn(r,n);ui||f>e[s].lim));for(u=s,s=o;(s=r.parent(s))!==u;)a.push(s);return{path:n.concat(a.reverse()),lca:u}}function xd(r){var e={},t=0;function o(n){var a=t;d(r.children(n),o),e[n]={low:a,lim:t++}}return d(r.children(),o),e}function _d(r,e){var t={};function o(n,a){var i=0,f=0,s=n.length,u=Q(a);return d(a,function(m,p){var l=gd(r,m),x=l?r.node(l).order:s;(l||m===u)&&(d(a.slice(f,p+1),function(h){d(r.predecessors(h),function(v){var w=r.node(v),T=w.order;(Tu)&&Yn(t,l,m)})})}function n(a,i){var f=-1,s,u=0;return d(i,function(m,p){if(r.node(m).dummy==="border"){var l=r.predecessors(m);l.length&&(s=r.node(l[0]).order,o(i,u,p,f,s),u=p,f=s)}o(i,u,i.length,s,a.length)}),i}return Y(e,n),t}function gd(r,e){if(r.node(e).dummy)return Ir(r.predecessors(e),function(t){return r.node(t).dummy})}function Yn(r,e,t){if(e>t){var o=e;e=t,t=o}var n=r[e];n||(r[e]=n={}),n[t]=!0}function bd(r,e,t){if(e>t){var o=e;e=t,t=o}return c(r[e],t)}function yd(r,e,t,o){var n={},a={},i={};return d(e,function(f){d(f,function(s,u){n[s]=s,a[s]=s,i[s]=u})}),d(e,function(f){var s=-1;d(f,function(u){var m=o(u);if(m.length){m=z(m,function(v){return i[v]});for(var p=(m.length-1)/2,l=Math.floor(p),x=Math.ceil(p);l<=x;++l){var h=m[l];a[u]===u&&s0)&&t[s-1].push(t[s]),this.$=t[s-1];break;case 4:case 176:this.$=t[s];break;case 11:r.setDirection("TB"),this.$="TB";break;case 12:r.setDirection(t[s-1]),this.$=t[s-1];break;case 27:this.$=t[s-1].nodes;break;case 28:case 29:case 30:case 31:case 32:this.$=[];break;case 33:this.$=r.addSubGraph(t[s-6],t[s-1],t[s-4]);break;case 34:this.$=r.addSubGraph(t[s-3],t[s-1],t[s-3]);break;case 35:this.$=r.addSubGraph(void 0,t[s-1],void 0);break;case 37:this.$=t[s].trim(),r.setAccTitle(this.$);break;case 38:case 39:this.$=t[s].trim(),r.setAccDescription(this.$);break;case 43:r.addLink(t[s-2].stmt,t[s],t[s-1]),this.$={stmt:t[s],nodes:t[s].concat(t[s-2].nodes)};break;case 44:r.addLink(t[s-3].stmt,t[s-1],t[s-2]),this.$={stmt:t[s-1],nodes:t[s-1].concat(t[s-3].nodes)};break;case 45:this.$={stmt:t[s-1],nodes:t[s-1]};break;case 46:this.$={stmt:t[s],nodes:t[s]};break;case 47:this.$=[t[s]];break;case 48:this.$=t[s-4].concat(t[s]);break;case 49:this.$=t[s];break;case 50:this.$=t[s-2],r.setClass(t[s-2],t[s]);break;case 51:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"square");break;case 52:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"doublecircle");break;case 53:this.$=t[s-5],r.addVertex(t[s-5],t[s-2],"circle");break;case 54:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"ellipse");break;case 55:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"stadium");break;case 56:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"subroutine");break;case 57:this.$=t[s-7],r.addVertex(t[s-7],t[s-1],"rect",void 0,void 0,void 0,Object.fromEntries([[t[s-5],t[s-3]]]));break;case 58:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"cylinder");break;case 59:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"round");break;case 60:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"diamond");break;case 61:this.$=t[s-5],r.addVertex(t[s-5],t[s-2],"hexagon");break;case 62:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"odd");break;case 63:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"trapezoid");break;case 64:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"inv_trapezoid");break;case 65:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"lean_right");break;case 66:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"lean_left");break;case 67:this.$=t[s],r.addVertex(t[s]);break;case 68:t[s-1].text=t[s],this.$=t[s-1];break;case 69:case 70:t[s-2].text=t[s-1],this.$=t[s-2];break;case 71:this.$=t[s];break;case 72:var j=r.destructLink(t[s],t[s-2]);this.$={type:j.type,stroke:j.stroke,length:j.length,text:t[s-1]};break;case 73:this.$={text:t[s],type:"text"};break;case 74:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 75:this.$={text:t[s],type:"string"};break;case 76:this.$={text:t[s],type:"markdown"};break;case 77:var j=r.destructLink(t[s]);this.$={type:j.type,stroke:j.stroke,length:j.length};break;case 78:this.$=t[s-1];break;case 79:this.$={text:t[s],type:"text"};break;case 80:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 81:this.$={text:t[s],type:"string"};break;case 82:case 97:this.$={text:t[s],type:"markdown"};break;case 94:this.$={text:t[s],type:"text"};break;case 95:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 96:this.$={text:t[s],type:"text"};break;case 98:this.$=t[s-4],r.addClass(t[s-2],t[s]);break;case 99:this.$=t[s-4],r.setClass(t[s-2],t[s]);break;case 100:case 108:this.$=t[s-1],r.setClickEvent(t[s-1],t[s]);break;case 101:case 109:this.$=t[s-3],r.setClickEvent(t[s-3],t[s-2]),r.setTooltip(t[s-3],t[s]);break;case 102:this.$=t[s-2],r.setClickEvent(t[s-2],t[s-1],t[s]);break;case 103:this.$=t[s-4],r.setClickEvent(t[s-4],t[s-3],t[s-2]),r.setTooltip(t[s-4],t[s]);break;case 104:this.$=t[s-2],r.setLink(t[s-2],t[s]);break;case 105:this.$=t[s-4],r.setLink(t[s-4],t[s-2]),r.setTooltip(t[s-4],t[s]);break;case 106:this.$=t[s-4],r.setLink(t[s-4],t[s-2],t[s]);break;case 107:this.$=t[s-6],r.setLink(t[s-6],t[s-4],t[s]),r.setTooltip(t[s-6],t[s-2]);break;case 110:this.$=t[s-1],r.setLink(t[s-1],t[s]);break;case 111:this.$=t[s-3],r.setLink(t[s-3],t[s-2]),r.setTooltip(t[s-3],t[s]);break;case 112:this.$=t[s-3],r.setLink(t[s-3],t[s-2],t[s]);break;case 113:this.$=t[s-5],r.setLink(t[s-5],t[s-4],t[s]),r.setTooltip(t[s-5],t[s-2]);break;case 114:this.$=t[s-4],r.addVertex(t[s-2],void 0,void 0,t[s]);break;case 115:this.$=t[s-4],r.updateLink([t[s-2]],t[s]);break;case 116:this.$=t[s-4],r.updateLink(t[s-2],t[s]);break;case 117:this.$=t[s-8],r.updateLinkInterpolate([t[s-6]],t[s-2]),r.updateLink([t[s-6]],t[s]);break;case 118:this.$=t[s-8],r.updateLinkInterpolate(t[s-6],t[s-2]),r.updateLink(t[s-6],t[s]);break;case 119:this.$=t[s-6],r.updateLinkInterpolate([t[s-4]],t[s]);break;case 120:this.$=t[s-6],r.updateLinkInterpolate(t[s-4],t[s]);break;case 121:case 123:this.$=[t[s]];break;case 122:case 124:t[s-2].push(t[s]),this.$=t[s-2];break;case 126:this.$=t[s-1]+t[s];break;case 174:this.$=t[s];break;case 175:this.$=t[s-1]+""+t[s];break;case 177:this.$=t[s-1]+""+t[s];break;case 178:this.$={stmt:"dir",value:"TB"};break;case 179:this.$={stmt:"dir",value:"BT"};break;case 180:this.$={stmt:"dir",value:"RL"};break;case 181:this.$={stmt:"dir",value:"LR"};break}},table:[{3:1,4:2,9:u,10:i,12:n},{1:[3]},e(c,l,{5:6}),{4:7,9:u,10:i,12:n},{4:8,9:u,10:i,12:n},{13:[1,9],14:[1,10]},{1:[2,1],6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},e(c,[2,9]),e(c,[2,10]),e(c,[2,11]),{8:[1,54],9:[1,55],10:I1,15:53,18:56},e(b,[2,3]),e(b,[2,4]),e(b,[2,5]),e(b,[2,6]),e(b,[2,7]),e(b,[2,8]),{8:H,9:W,11:Q,21:58,39:59,70:63,73:[1,64],75:[1,65]},{8:H,9:W,11:Q,21:66},{8:H,9:W,11:Q,21:67},{8:H,9:W,11:Q,21:68},{8:H,9:W,11:Q,21:69},{8:H,9:W,11:Q,21:70},{8:H,9:W,10:[1,71],11:Q,21:72},e(b,[2,36]),{35:[1,73]},{37:[1,74]},e(b,[2,39]),e(q1,[2,46],{18:75,10:I1}),{10:[1,76]},{10:[1,77]},{10:[1,78]},{10:[1,79]},{14:k1,42:b1,58:g1,77:[1,83],86:D1,92:[1,80],94:[1,81],98:82,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1,117:84},e(b,[2,178]),e(b,[2,179]),e(b,[2,180]),e(b,[2,181]),e(H1,[2,47]),e(H1,[2,49],{44:[1,96]}),e(N,[2,67],{110:109,29:[1,97],42:S,46:[1,98],48:[1,99],50:[1,100],52:[1,101],54:[1,102],56:[1,103],58:k,61:[1,104],63:[1,105],65:[1,106],66:[1,107],68:[1,108],86:B,99:x,102:y,103:m,106:v,108:V,111:L,112:I,113:R}),e(M,[2,174]),e(M,[2,135]),e(M,[2,136]),e(M,[2,137]),e(M,[2,138]),e(M,[2,139]),e(M,[2,140]),e(M,[2,141]),e(M,[2,142]),e(M,[2,143]),e(M,[2,144]),e(M,[2,145]),e(c,[2,12]),e(c,[2,18]),e(c,[2,19]),{9:[1,110]},e(Et,[2,26],{18:111,10:I1}),e(b,[2,27]),{40:112,41:38,42:S,43:39,45:40,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},e(b,[2,40]),e(b,[2,41]),e(b,[2,42]),e(R1,[2,71],{71:113,60:[1,115],72:[1,114]}),{74:116,76:117,77:[1,118],78:[1,119],113:kt,116:bt},e([42,58,60,72,86,99,102,103,106,108,111,112,113],[2,77]),e(b,[2,28]),e(b,[2,29]),e(b,[2,30]),e(b,[2,31]),e(b,[2,32]),{10:gt,12:Dt,14:Ft,27:Tt,28:122,32:Ct,42:St,58:_t,73:Bt,77:[1,124],78:[1,125],80:135,81:xt,82:yt,83:mt,84:vt,85:Vt,86:Lt,87:It,88:123,102:Rt,106:Nt,108:Ot,111:Pt,112:wt,113:Ut},e(nt,l,{5:148}),e(b,[2,37]),e(b,[2,38]),e(q1,[2,45],{42:Gt}),{42:S,45:150,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{99:[1,151],100:152,102:[1,153]},{42:S,45:154,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{42:S,45:155,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},e(T,[2,100],{10:[1,156],93:[1,157]}),{77:[1,158]},e(T,[2,108],{117:160,10:[1,159],14:k1,42:b1,58:g1,86:D1,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1}),e(T,[2,110],{10:[1,161]}),e(K,[2,176]),e(K,[2,163]),e(K,[2,164]),e(K,[2,165]),e(K,[2,166]),e(K,[2,167]),e(K,[2,168]),e(K,[2,169]),e(K,[2,170]),e(K,[2,171]),e(K,[2,172]),e(K,[2,173]),{42:S,45:162,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{30:163,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:171,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:173,48:[1,172],65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:174,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:175,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:176,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{106:[1,177]},{30:178,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:179,63:[1,180],65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:181,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:182,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:183,65:f,77:P,78:w,79:164,113:A,114:d,115:E},e(M,[2,175]),e(c,[2,20]),e(Et,[2,25]),e(q1,[2,43],{18:184,10:I1}),e(R1,[2,68],{10:[1,185]}),{10:[1,186]},{30:187,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{75:[1,188],76:189,113:kt,116:bt},e(y1,[2,73]),e(y1,[2,75]),e(y1,[2,76]),e(y1,[2,161]),e(y1,[2,162]),{8:H,9:W,10:gt,11:Q,12:Dt,14:Ft,21:191,27:Tt,29:[1,190],32:Ct,42:St,58:_t,73:Bt,80:135,81:xt,82:yt,83:mt,84:vt,85:Vt,86:Lt,87:It,88:192,102:Rt,106:Nt,108:Ot,111:Pt,112:wt,113:Ut},e(g,[2,94]),e(g,[2,96]),e(g,[2,97]),e(g,[2,150]),e(g,[2,151]),e(g,[2,152]),e(g,[2,153]),e(g,[2,154]),e(g,[2,155]),e(g,[2,156]),e(g,[2,157]),e(g,[2,158]),e(g,[2,159]),e(g,[2,160]),e(g,[2,83]),e(g,[2,84]),e(g,[2,85]),e(g,[2,86]),e(g,[2,87]),e(g,[2,88]),e(g,[2,89]),e(g,[2,90]),e(g,[2,91]),e(g,[2,92]),e(g,[2,93]),{6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,32:[1,193],33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},{10:I1,18:194},{10:[1,195],42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:109,111:L,112:I,113:R},{10:[1,196]},{10:[1,197],103:[1,198]},e(Mt,[2,121]),{10:[1,199],42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:109,111:L,112:I,113:R},{10:[1,200],42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:109,111:L,112:I,113:R},{77:[1,201]},e(T,[2,102],{10:[1,202]}),e(T,[2,104],{10:[1,203]}),{77:[1,204]},e(K,[2,177]),{77:[1,205],95:[1,206]},e(H1,[2,50],{110:109,42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,111:L,112:I,113:R}),{31:[1,207],65:f,79:208,113:A,114:d,115:E},e(l1,[2,79]),e(l1,[2,81]),e(l1,[2,82]),e(l1,[2,146]),e(l1,[2,147]),e(l1,[2,148]),e(l1,[2,149]),{47:[1,209],65:f,79:208,113:A,114:d,115:E},{30:210,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{49:[1,211],65:f,79:208,113:A,114:d,115:E},{51:[1,212],65:f,79:208,113:A,114:d,115:E},{53:[1,213],65:f,79:208,113:A,114:d,115:E},{55:[1,214],65:f,79:208,113:A,114:d,115:E},{58:[1,215]},{62:[1,216],65:f,79:208,113:A,114:d,115:E},{64:[1,217],65:f,79:208,113:A,114:d,115:E},{30:218,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{31:[1,219],65:f,79:208,113:A,114:d,115:E},{65:f,67:[1,220],69:[1,221],79:208,113:A,114:d,115:E},{65:f,67:[1,223],69:[1,222],79:208,113:A,114:d,115:E},e(q1,[2,44],{42:Gt}),e(R1,[2,70]),e(R1,[2,69]),{60:[1,224],65:f,79:208,113:A,114:d,115:E},e(R1,[2,72]),e(y1,[2,74]),{30:225,65:f,77:P,78:w,79:164,113:A,114:d,115:E},e(nt,l,{5:226}),e(g,[2,95]),e(b,[2,35]),{41:227,42:S,43:39,45:40,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{10:Z,58:J,81:$,89:228,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{10:Z,58:J,81:$,89:239,101:[1,240],102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{10:Z,58:J,81:$,89:241,101:[1,242],102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{102:[1,243]},{10:Z,58:J,81:$,89:244,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{42:S,45:245,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},e(T,[2,101]),{77:[1,246]},{77:[1,247],95:[1,248]},e(T,[2,109]),e(T,[2,111],{10:[1,249]}),e(T,[2,112]),e(N,[2,51]),e(l1,[2,80]),e(N,[2,52]),{49:[1,250],65:f,79:208,113:A,114:d,115:E},e(N,[2,59]),e(N,[2,54]),e(N,[2,55]),e(N,[2,56]),{106:[1,251]},e(N,[2,58]),e(N,[2,60]),{64:[1,252],65:f,79:208,113:A,114:d,115:E},e(N,[2,62]),e(N,[2,63]),e(N,[2,65]),e(N,[2,64]),e(N,[2,66]),e([10,42,58,86,99,102,103,106,108,111,112,113],[2,78]),{31:[1,253],65:f,79:208,113:A,114:d,115:E},{6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,32:[1,254],33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},e(H1,[2,48]),e(T,[2,114],{103:m1}),e(Kt,[2,123],{105:256,10:Z,58:J,81:$,102:t1,106:e1,107:s1,108:u1,109:i1}),e(q,[2,125]),e(q,[2,127]),e(q,[2,128]),e(q,[2,129]),e(q,[2,130]),e(q,[2,131]),e(q,[2,132]),e(q,[2,133]),e(q,[2,134]),e(T,[2,115],{103:m1}),{10:[1,257]},e(T,[2,116],{103:m1}),{10:[1,258]},e(Mt,[2,122]),e(T,[2,98],{103:m1}),e(T,[2,99],{110:109,42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,111:L,112:I,113:R}),e(T,[2,103]),e(T,[2,105],{10:[1,259]}),e(T,[2,106]),{95:[1,260]},{49:[1,261]},{60:[1,262]},{64:[1,263]},{8:H,9:W,11:Q,21:264},e(b,[2,34]),{10:Z,58:J,81:$,102:t1,104:265,105:230,106:e1,107:s1,108:u1,109:i1},e(q,[2,126]),{14:k1,42:b1,58:g1,86:D1,98:266,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1,117:84},{14:k1,42:b1,58:g1,86:D1,98:267,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1,117:84},{95:[1,268]},e(T,[2,113]),e(N,[2,53]),{30:269,65:f,77:P,78:w,79:164,113:A,114:d,115:E},e(N,[2,61]),e(nt,l,{5:270}),e(Kt,[2,124],{105:256,10:Z,58:J,81:$,102:t1,106:e1,107:s1,108:u1,109:i1}),e(T,[2,119],{117:160,10:[1,271],14:k1,42:b1,58:g1,86:D1,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1}),e(T,[2,120],{117:160,10:[1,272],14:k1,42:b1,58:g1,86:D1,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1}),e(T,[2,107]),{31:[1,273],65:f,79:208,113:A,114:d,115:E},{6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,32:[1,274],33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},{10:Z,58:J,81:$,89:275,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{10:Z,58:J,81:$,89:276,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},e(N,[2,57]),e(b,[2,33]),e(T,[2,117],{103:m1}),e(T,[2,118],{103:m1})],defaultActions:{},parseError:function(a,o){if(o.recoverable)this.trace(a);else{var p=new Error(a);throw p.hash=o,p}},parse:function(a){var o=this,p=[0],r=[],C=[null],t=[],N1=this.table,s="",j=0,jt=0,Ie=2,Yt=1,Re=t.slice.call(arguments,1),_=Object.create(this.lexer),d1={yy:{}};for(var ot in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ot)&&(d1.yy[ot]=this.yy[ot]);_.setInput(a,d1.yy),d1.yy.lexer=_,d1.yy.parser=this,typeof _.yylloc>"u"&&(_.yylloc={});var lt=_.yylloc;t.push(lt);var Ne=_.options&&_.options.ranges;typeof d1.yy.parseError=="function"?this.parseError=d1.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Oe(){var n1;return n1=r.pop()||_.lex()||Yt,typeof n1!="number"&&(n1 instanceof Array&&(r=n1,n1=r.pop()),n1=o.symbols_[n1]||n1),n1}for(var G,E1,Y,ht,v1={},W1,r1,Xt,Q1;;){if(E1=p[p.length-1],this.defaultActions[E1]?Y=this.defaultActions[E1]:((G===null||typeof G>"u")&&(G=Oe()),Y=N1[E1]&&N1[E1][G]),typeof Y>"u"||!Y.length||!Y[0]){var pt="";Q1=[];for(W1 in N1[E1])this.terminals_[W1]&&W1>Ie&&Q1.push("'"+this.terminals_[W1]+"'");_.showPosition?pt="Parse error on line "+(j+1)+`: +import{Ga as O1,La as zt,Za as Z1,bb as qt,cb as Ht,db as Wt,eb as Qt,fb as Zt,gb as Jt,h as V1,hb as $t,jb as J1,lb as te}from"./chunk-JUXSCBYR.min.js";var ft=function(){var e=function(h1,a,o,p){for(o=o||{},p=h1.length;p--;o[h1[p]]=a);return o},u=[1,4],i=[1,3],n=[1,5],c=[1,8,9,10,11,27,34,36,38,42,58,81,82,83,84,85,86,99,102,103,106,108,111,112,113,118,119,120,121],l=[2,2],h=[1,13],U=[1,14],F=[1,15],O=[1,16],z=[1,23],c1=[1,25],f1=[1,26],A1=[1,27],S=[1,49],k=[1,48],o1=[1,29],U1=[1,30],G1=[1,31],M1=[1,32],K1=[1,33],B=[1,44],x=[1,46],y=[1,42],m=[1,47],v=[1,43],V=[1,50],L=[1,45],I=[1,51],R=[1,52],j1=[1,34],Y1=[1,35],X1=[1,36],z1=[1,37],I1=[1,57],b=[1,8,9,10,11,27,32,34,36,38,42,58,81,82,83,84,85,86,99,102,103,106,108,111,112,113,118,119,120,121],H=[1,61],W=[1,60],Q=[1,62],q1=[8,9,11,73,75],k1=[1,88],b1=[1,93],g1=[1,92],D1=[1,89],F1=[1,85],T1=[1,91],C1=[1,87],S1=[1,94],_1=[1,90],B1=[1,95],x1=[1,86],H1=[8,9,10,11,73,75],N=[8,9,10,11,44,73,75],M=[8,9,10,11,29,42,44,46,48,50,52,54,56,58,61,63,65,66,68,73,75,86,99,102,103,106,108,111,112,113],Et=[8,9,11,42,58,73,75,86,99,102,103,106,108,111,112,113],R1=[42,58,86,99,102,103,106,108,111,112,113],kt=[1,121],bt=[1,120],gt=[1,128],Dt=[1,142],Ft=[1,143],Tt=[1,144],Ct=[1,145],St=[1,130],_t=[1,132],Bt=[1,136],xt=[1,137],yt=[1,138],mt=[1,139],vt=[1,140],Vt=[1,141],Lt=[1,146],It=[1,147],Rt=[1,126],Nt=[1,127],Ot=[1,134],Pt=[1,129],wt=[1,133],Ut=[1,131],nt=[8,9,10,11,27,32,34,36,38,42,58,81,82,83,84,85,86,99,102,103,106,108,111,112,113,118,119,120,121],Gt=[1,149],T=[8,9,11],K=[8,9,10,11,14,42,58,86,102,103,106,108,111,112,113],f=[1,169],P=[1,165],w=[1,166],A=[1,170],d=[1,167],E=[1,168],y1=[75,113,116],g=[8,9,10,11,12,14,27,29,32,42,58,73,81,82,83,84,85,86,87,102,106,108,111,112,113],Mt=[10,103],l1=[31,47,49,51,53,55,60,62,64,65,67,69,113,114,115],Z=[1,235],J=[1,233],$=[1,237],t1=[1,231],e1=[1,232],s1=[1,234],u1=[1,236],i1=[1,238],m1=[1,255],Kt=[8,9,11,103],q=[8,9,10,11,58,81,102,103,106,107,108,109],at={trace:function(){},yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,SEMI:8,NEWLINE:9,SPACE:10,EOF:11,GRAPH:12,NODIR:13,DIR:14,FirstStmtSeperator:15,ending:16,endToken:17,spaceList:18,spaceListNewline:19,verticeStatement:20,separator:21,styleStatement:22,linkStyleStatement:23,classDefStatement:24,classStatement:25,clickStatement:26,subgraph:27,textNoTags:28,SQS:29,text:30,SQE:31,end:32,direction:33,acc_title:34,acc_title_value:35,acc_descr:36,acc_descr_value:37,acc_descr_multiline_value:38,link:39,node:40,styledVertex:41,AMP:42,vertex:43,STYLE_SEPARATOR:44,idString:45,DOUBLECIRCLESTART:46,DOUBLECIRCLEEND:47,PS:48,PE:49,"(-":50,"-)":51,STADIUMSTART:52,STADIUMEND:53,SUBROUTINESTART:54,SUBROUTINEEND:55,VERTEX_WITH_PROPS_START:56,"NODE_STRING[field]":57,COLON:58,"NODE_STRING[value]":59,PIPE:60,CYLINDERSTART:61,CYLINDEREND:62,DIAMOND_START:63,DIAMOND_STOP:64,TAGEND:65,TRAPSTART:66,TRAPEND:67,INVTRAPSTART:68,INVTRAPEND:69,linkStatement:70,arrowText:71,TESTSTR:72,START_LINK:73,edgeText:74,LINK:75,edgeTextToken:76,STR:77,MD_STR:78,textToken:79,keywords:80,STYLE:81,LINKSTYLE:82,CLASSDEF:83,CLASS:84,CLICK:85,DOWN:86,UP:87,textNoTagsToken:88,stylesOpt:89,"idString[vertex]":90,"idString[class]":91,CALLBACKNAME:92,CALLBACKARGS:93,HREF:94,LINK_TARGET:95,"STR[link]":96,"STR[tooltip]":97,alphaNum:98,DEFAULT:99,numList:100,INTERPOLATE:101,NUM:102,COMMA:103,style:104,styleComponent:105,NODE_STRING:106,UNIT:107,BRKT:108,PCT:109,idStringToken:110,MINUS:111,MULT:112,UNICODE_TEXT:113,TEXT:114,TAGSTART:115,EDGE_TEXT:116,alphaNumToken:117,direction_tb:118,direction_bt:119,direction_rl:120,direction_lr:121,$accept:0,$end:1},terminals_:{2:"error",8:"SEMI",9:"NEWLINE",10:"SPACE",11:"EOF",12:"GRAPH",13:"NODIR",14:"DIR",27:"subgraph",29:"SQS",31:"SQE",32:"end",34:"acc_title",35:"acc_title_value",36:"acc_descr",37:"acc_descr_value",38:"acc_descr_multiline_value",42:"AMP",44:"STYLE_SEPARATOR",46:"DOUBLECIRCLESTART",47:"DOUBLECIRCLEEND",48:"PS",49:"PE",50:"(-",51:"-)",52:"STADIUMSTART",53:"STADIUMEND",54:"SUBROUTINESTART",55:"SUBROUTINEEND",56:"VERTEX_WITH_PROPS_START",57:"NODE_STRING[field]",58:"COLON",59:"NODE_STRING[value]",60:"PIPE",61:"CYLINDERSTART",62:"CYLINDEREND",63:"DIAMOND_START",64:"DIAMOND_STOP",65:"TAGEND",66:"TRAPSTART",67:"TRAPEND",68:"INVTRAPSTART",69:"INVTRAPEND",72:"TESTSTR",73:"START_LINK",75:"LINK",77:"STR",78:"MD_STR",81:"STYLE",82:"LINKSTYLE",83:"CLASSDEF",84:"CLASS",85:"CLICK",86:"DOWN",87:"UP",90:"idString[vertex]",91:"idString[class]",92:"CALLBACKNAME",93:"CALLBACKARGS",94:"HREF",95:"LINK_TARGET",96:"STR[link]",97:"STR[tooltip]",99:"DEFAULT",101:"INTERPOLATE",102:"NUM",103:"COMMA",106:"NODE_STRING",107:"UNIT",108:"BRKT",109:"PCT",111:"MINUS",112:"MULT",113:"UNICODE_TEXT",114:"TEXT",115:"TAGSTART",116:"EDGE_TEXT",118:"direction_tb",119:"direction_bt",120:"direction_rl",121:"direction_lr"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,3],[16,2],[16,1],[17,1],[17,1],[17,1],[15,1],[15,1],[15,2],[19,2],[19,2],[19,1],[19,1],[18,2],[18,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,6],[7,4],[7,1],[7,2],[7,2],[7,1],[21,1],[21,1],[21,1],[20,3],[20,4],[20,2],[20,1],[40,1],[40,5],[41,1],[41,3],[43,4],[43,4],[43,6],[43,4],[43,4],[43,4],[43,8],[43,4],[43,4],[43,4],[43,6],[43,4],[43,4],[43,4],[43,4],[43,4],[43,1],[39,2],[39,3],[39,3],[39,1],[39,3],[74,1],[74,2],[74,1],[74,1],[70,1],[71,3],[30,1],[30,2],[30,1],[30,1],[80,1],[80,1],[80,1],[80,1],[80,1],[80,1],[80,1],[80,1],[80,1],[80,1],[80,1],[28,1],[28,2],[28,1],[28,1],[24,5],[25,5],[26,2],[26,4],[26,3],[26,5],[26,3],[26,5],[26,5],[26,7],[26,2],[26,4],[26,2],[26,4],[26,4],[26,6],[22,5],[23,5],[23,5],[23,9],[23,9],[23,7],[23,7],[100,1],[100,3],[89,1],[89,3],[104,1],[104,2],[105,1],[105,1],[105,1],[105,1],[105,1],[105,1],[105,1],[105,1],[110,1],[110,1],[110,1],[110,1],[110,1],[110,1],[110,1],[110,1],[110,1],[110,1],[110,1],[79,1],[79,1],[79,1],[79,1],[88,1],[88,1],[88,1],[88,1],[88,1],[88,1],[88,1],[88,1],[88,1],[88,1],[88,1],[76,1],[76,1],[117,1],[117,1],[117,1],[117,1],[117,1],[117,1],[117,1],[117,1],[117,1],[117,1],[117,1],[45,1],[45,2],[98,1],[98,2],[33,1],[33,1],[33,1],[33,1]],performAction:function(a,o,p,r,C,t,N1){var s=t.length-1;switch(C){case 2:this.$=[];break;case 3:(!Array.isArray(t[s])||t[s].length>0)&&t[s-1].push(t[s]),this.$=t[s-1];break;case 4:case 176:this.$=t[s];break;case 11:r.setDirection("TB"),this.$="TB";break;case 12:r.setDirection(t[s-1]),this.$=t[s-1];break;case 27:this.$=t[s-1].nodes;break;case 28:case 29:case 30:case 31:case 32:this.$=[];break;case 33:this.$=r.addSubGraph(t[s-6],t[s-1],t[s-4]);break;case 34:this.$=r.addSubGraph(t[s-3],t[s-1],t[s-3]);break;case 35:this.$=r.addSubGraph(void 0,t[s-1],void 0);break;case 37:this.$=t[s].trim(),r.setAccTitle(this.$);break;case 38:case 39:this.$=t[s].trim(),r.setAccDescription(this.$);break;case 43:r.addLink(t[s-2].stmt,t[s],t[s-1]),this.$={stmt:t[s],nodes:t[s].concat(t[s-2].nodes)};break;case 44:r.addLink(t[s-3].stmt,t[s-1],t[s-2]),this.$={stmt:t[s-1],nodes:t[s-1].concat(t[s-3].nodes)};break;case 45:this.$={stmt:t[s-1],nodes:t[s-1]};break;case 46:this.$={stmt:t[s],nodes:t[s]};break;case 47:this.$=[t[s]];break;case 48:this.$=t[s-4].concat(t[s]);break;case 49:this.$=t[s];break;case 50:this.$=t[s-2],r.setClass(t[s-2],t[s]);break;case 51:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"square");break;case 52:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"doublecircle");break;case 53:this.$=t[s-5],r.addVertex(t[s-5],t[s-2],"circle");break;case 54:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"ellipse");break;case 55:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"stadium");break;case 56:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"subroutine");break;case 57:this.$=t[s-7],r.addVertex(t[s-7],t[s-1],"rect",void 0,void 0,void 0,Object.fromEntries([[t[s-5],t[s-3]]]));break;case 58:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"cylinder");break;case 59:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"round");break;case 60:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"diamond");break;case 61:this.$=t[s-5],r.addVertex(t[s-5],t[s-2],"hexagon");break;case 62:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"odd");break;case 63:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"trapezoid");break;case 64:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"inv_trapezoid");break;case 65:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"lean_right");break;case 66:this.$=t[s-3],r.addVertex(t[s-3],t[s-1],"lean_left");break;case 67:this.$=t[s],r.addVertex(t[s]);break;case 68:t[s-1].text=t[s],this.$=t[s-1];break;case 69:case 70:t[s-2].text=t[s-1],this.$=t[s-2];break;case 71:this.$=t[s];break;case 72:var j=r.destructLink(t[s],t[s-2]);this.$={type:j.type,stroke:j.stroke,length:j.length,text:t[s-1]};break;case 73:this.$={text:t[s],type:"text"};break;case 74:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 75:this.$={text:t[s],type:"string"};break;case 76:this.$={text:t[s],type:"markdown"};break;case 77:var j=r.destructLink(t[s]);this.$={type:j.type,stroke:j.stroke,length:j.length};break;case 78:this.$=t[s-1];break;case 79:this.$={text:t[s],type:"text"};break;case 80:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 81:this.$={text:t[s],type:"string"};break;case 82:case 97:this.$={text:t[s],type:"markdown"};break;case 94:this.$={text:t[s],type:"text"};break;case 95:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 96:this.$={text:t[s],type:"text"};break;case 98:this.$=t[s-4],r.addClass(t[s-2],t[s]);break;case 99:this.$=t[s-4],r.setClass(t[s-2],t[s]);break;case 100:case 108:this.$=t[s-1],r.setClickEvent(t[s-1],t[s]);break;case 101:case 109:this.$=t[s-3],r.setClickEvent(t[s-3],t[s-2]),r.setTooltip(t[s-3],t[s]);break;case 102:this.$=t[s-2],r.setClickEvent(t[s-2],t[s-1],t[s]);break;case 103:this.$=t[s-4],r.setClickEvent(t[s-4],t[s-3],t[s-2]),r.setTooltip(t[s-4],t[s]);break;case 104:this.$=t[s-2],r.setLink(t[s-2],t[s]);break;case 105:this.$=t[s-4],r.setLink(t[s-4],t[s-2]),r.setTooltip(t[s-4],t[s]);break;case 106:this.$=t[s-4],r.setLink(t[s-4],t[s-2],t[s]);break;case 107:this.$=t[s-6],r.setLink(t[s-6],t[s-4],t[s]),r.setTooltip(t[s-6],t[s-2]);break;case 110:this.$=t[s-1],r.setLink(t[s-1],t[s]);break;case 111:this.$=t[s-3],r.setLink(t[s-3],t[s-2]),r.setTooltip(t[s-3],t[s]);break;case 112:this.$=t[s-3],r.setLink(t[s-3],t[s-2],t[s]);break;case 113:this.$=t[s-5],r.setLink(t[s-5],t[s-4],t[s]),r.setTooltip(t[s-5],t[s-2]);break;case 114:this.$=t[s-4],r.addVertex(t[s-2],void 0,void 0,t[s]);break;case 115:this.$=t[s-4],r.updateLink([t[s-2]],t[s]);break;case 116:this.$=t[s-4],r.updateLink(t[s-2],t[s]);break;case 117:this.$=t[s-8],r.updateLinkInterpolate([t[s-6]],t[s-2]),r.updateLink([t[s-6]],t[s]);break;case 118:this.$=t[s-8],r.updateLinkInterpolate(t[s-6],t[s-2]),r.updateLink(t[s-6],t[s]);break;case 119:this.$=t[s-6],r.updateLinkInterpolate([t[s-4]],t[s]);break;case 120:this.$=t[s-6],r.updateLinkInterpolate(t[s-4],t[s]);break;case 121:case 123:this.$=[t[s]];break;case 122:case 124:t[s-2].push(t[s]),this.$=t[s-2];break;case 126:this.$=t[s-1]+t[s];break;case 174:this.$=t[s];break;case 175:this.$=t[s-1]+""+t[s];break;case 177:this.$=t[s-1]+""+t[s];break;case 178:this.$={stmt:"dir",value:"TB"};break;case 179:this.$={stmt:"dir",value:"BT"};break;case 180:this.$={stmt:"dir",value:"RL"};break;case 181:this.$={stmt:"dir",value:"LR"};break}},table:[{3:1,4:2,9:u,10:i,12:n},{1:[3]},e(c,l,{5:6}),{4:7,9:u,10:i,12:n},{4:8,9:u,10:i,12:n},{13:[1,9],14:[1,10]},{1:[2,1],6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},e(c,[2,9]),e(c,[2,10]),e(c,[2,11]),{8:[1,54],9:[1,55],10:I1,15:53,18:56},e(b,[2,3]),e(b,[2,4]),e(b,[2,5]),e(b,[2,6]),e(b,[2,7]),e(b,[2,8]),{8:H,9:W,11:Q,21:58,39:59,70:63,73:[1,64],75:[1,65]},{8:H,9:W,11:Q,21:66},{8:H,9:W,11:Q,21:67},{8:H,9:W,11:Q,21:68},{8:H,9:W,11:Q,21:69},{8:H,9:W,11:Q,21:70},{8:H,9:W,10:[1,71],11:Q,21:72},e(b,[2,36]),{35:[1,73]},{37:[1,74]},e(b,[2,39]),e(q1,[2,46],{18:75,10:I1}),{10:[1,76]},{10:[1,77]},{10:[1,78]},{10:[1,79]},{14:k1,42:b1,58:g1,77:[1,83],86:D1,92:[1,80],94:[1,81],98:82,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1,117:84},e(b,[2,178]),e(b,[2,179]),e(b,[2,180]),e(b,[2,181]),e(H1,[2,47]),e(H1,[2,49],{44:[1,96]}),e(N,[2,67],{110:109,29:[1,97],42:S,46:[1,98],48:[1,99],50:[1,100],52:[1,101],54:[1,102],56:[1,103],58:k,61:[1,104],63:[1,105],65:[1,106],66:[1,107],68:[1,108],86:B,99:x,102:y,103:m,106:v,108:V,111:L,112:I,113:R}),e(M,[2,174]),e(M,[2,135]),e(M,[2,136]),e(M,[2,137]),e(M,[2,138]),e(M,[2,139]),e(M,[2,140]),e(M,[2,141]),e(M,[2,142]),e(M,[2,143]),e(M,[2,144]),e(M,[2,145]),e(c,[2,12]),e(c,[2,18]),e(c,[2,19]),{9:[1,110]},e(Et,[2,26],{18:111,10:I1}),e(b,[2,27]),{40:112,41:38,42:S,43:39,45:40,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},e(b,[2,40]),e(b,[2,41]),e(b,[2,42]),e(R1,[2,71],{71:113,60:[1,115],72:[1,114]}),{74:116,76:117,77:[1,118],78:[1,119],113:kt,116:bt},e([42,58,60,72,86,99,102,103,106,108,111,112,113],[2,77]),e(b,[2,28]),e(b,[2,29]),e(b,[2,30]),e(b,[2,31]),e(b,[2,32]),{10:gt,12:Dt,14:Ft,27:Tt,28:122,32:Ct,42:St,58:_t,73:Bt,77:[1,124],78:[1,125],80:135,81:xt,82:yt,83:mt,84:vt,85:Vt,86:Lt,87:It,88:123,102:Rt,106:Nt,108:Ot,111:Pt,112:wt,113:Ut},e(nt,l,{5:148}),e(b,[2,37]),e(b,[2,38]),e(q1,[2,45],{42:Gt}),{42:S,45:150,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{99:[1,151],100:152,102:[1,153]},{42:S,45:154,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{42:S,45:155,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},e(T,[2,100],{10:[1,156],93:[1,157]}),{77:[1,158]},e(T,[2,108],{117:160,10:[1,159],14:k1,42:b1,58:g1,86:D1,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1}),e(T,[2,110],{10:[1,161]}),e(K,[2,176]),e(K,[2,163]),e(K,[2,164]),e(K,[2,165]),e(K,[2,166]),e(K,[2,167]),e(K,[2,168]),e(K,[2,169]),e(K,[2,170]),e(K,[2,171]),e(K,[2,172]),e(K,[2,173]),{42:S,45:162,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{30:163,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:171,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:173,48:[1,172],65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:174,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:175,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:176,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{106:[1,177]},{30:178,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:179,63:[1,180],65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:181,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:182,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{30:183,65:f,77:P,78:w,79:164,113:A,114:d,115:E},e(M,[2,175]),e(c,[2,20]),e(Et,[2,25]),e(q1,[2,43],{18:184,10:I1}),e(R1,[2,68],{10:[1,185]}),{10:[1,186]},{30:187,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{75:[1,188],76:189,113:kt,116:bt},e(y1,[2,73]),e(y1,[2,75]),e(y1,[2,76]),e(y1,[2,161]),e(y1,[2,162]),{8:H,9:W,10:gt,11:Q,12:Dt,14:Ft,21:191,27:Tt,29:[1,190],32:Ct,42:St,58:_t,73:Bt,80:135,81:xt,82:yt,83:mt,84:vt,85:Vt,86:Lt,87:It,88:192,102:Rt,106:Nt,108:Ot,111:Pt,112:wt,113:Ut},e(g,[2,94]),e(g,[2,96]),e(g,[2,97]),e(g,[2,150]),e(g,[2,151]),e(g,[2,152]),e(g,[2,153]),e(g,[2,154]),e(g,[2,155]),e(g,[2,156]),e(g,[2,157]),e(g,[2,158]),e(g,[2,159]),e(g,[2,160]),e(g,[2,83]),e(g,[2,84]),e(g,[2,85]),e(g,[2,86]),e(g,[2,87]),e(g,[2,88]),e(g,[2,89]),e(g,[2,90]),e(g,[2,91]),e(g,[2,92]),e(g,[2,93]),{6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,32:[1,193],33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},{10:I1,18:194},{10:[1,195],42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:109,111:L,112:I,113:R},{10:[1,196]},{10:[1,197],103:[1,198]},e(Mt,[2,121]),{10:[1,199],42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:109,111:L,112:I,113:R},{10:[1,200],42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:109,111:L,112:I,113:R},{77:[1,201]},e(T,[2,102],{10:[1,202]}),e(T,[2,104],{10:[1,203]}),{77:[1,204]},e(K,[2,177]),{77:[1,205],95:[1,206]},e(H1,[2,50],{110:109,42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,111:L,112:I,113:R}),{31:[1,207],65:f,79:208,113:A,114:d,115:E},e(l1,[2,79]),e(l1,[2,81]),e(l1,[2,82]),e(l1,[2,146]),e(l1,[2,147]),e(l1,[2,148]),e(l1,[2,149]),{47:[1,209],65:f,79:208,113:A,114:d,115:E},{30:210,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{49:[1,211],65:f,79:208,113:A,114:d,115:E},{51:[1,212],65:f,79:208,113:A,114:d,115:E},{53:[1,213],65:f,79:208,113:A,114:d,115:E},{55:[1,214],65:f,79:208,113:A,114:d,115:E},{58:[1,215]},{62:[1,216],65:f,79:208,113:A,114:d,115:E},{64:[1,217],65:f,79:208,113:A,114:d,115:E},{30:218,65:f,77:P,78:w,79:164,113:A,114:d,115:E},{31:[1,219],65:f,79:208,113:A,114:d,115:E},{65:f,67:[1,220],69:[1,221],79:208,113:A,114:d,115:E},{65:f,67:[1,223],69:[1,222],79:208,113:A,114:d,115:E},e(q1,[2,44],{42:Gt}),e(R1,[2,70]),e(R1,[2,69]),{60:[1,224],65:f,79:208,113:A,114:d,115:E},e(R1,[2,72]),e(y1,[2,74]),{30:225,65:f,77:P,78:w,79:164,113:A,114:d,115:E},e(nt,l,{5:226}),e(g,[2,95]),e(b,[2,35]),{41:227,42:S,43:39,45:40,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},{10:Z,58:J,81:$,89:228,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{10:Z,58:J,81:$,89:239,101:[1,240],102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{10:Z,58:J,81:$,89:241,101:[1,242],102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{102:[1,243]},{10:Z,58:J,81:$,89:244,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{42:S,45:245,58:k,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R},e(T,[2,101]),{77:[1,246]},{77:[1,247],95:[1,248]},e(T,[2,109]),e(T,[2,111],{10:[1,249]}),e(T,[2,112]),e(N,[2,51]),e(l1,[2,80]),e(N,[2,52]),{49:[1,250],65:f,79:208,113:A,114:d,115:E},e(N,[2,59]),e(N,[2,54]),e(N,[2,55]),e(N,[2,56]),{106:[1,251]},e(N,[2,58]),e(N,[2,60]),{64:[1,252],65:f,79:208,113:A,114:d,115:E},e(N,[2,62]),e(N,[2,63]),e(N,[2,65]),e(N,[2,64]),e(N,[2,66]),e([10,42,58,86,99,102,103,106,108,111,112,113],[2,78]),{31:[1,253],65:f,79:208,113:A,114:d,115:E},{6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,32:[1,254],33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},e(H1,[2,48]),e(T,[2,114],{103:m1}),e(Kt,[2,123],{105:256,10:Z,58:J,81:$,102:t1,106:e1,107:s1,108:u1,109:i1}),e(q,[2,125]),e(q,[2,127]),e(q,[2,128]),e(q,[2,129]),e(q,[2,130]),e(q,[2,131]),e(q,[2,132]),e(q,[2,133]),e(q,[2,134]),e(T,[2,115],{103:m1}),{10:[1,257]},e(T,[2,116],{103:m1}),{10:[1,258]},e(Mt,[2,122]),e(T,[2,98],{103:m1}),e(T,[2,99],{110:109,42:S,58:k,86:B,99:x,102:y,103:m,106:v,108:V,111:L,112:I,113:R}),e(T,[2,103]),e(T,[2,105],{10:[1,259]}),e(T,[2,106]),{95:[1,260]},{49:[1,261]},{60:[1,262]},{64:[1,263]},{8:H,9:W,11:Q,21:264},e(b,[2,34]),{10:Z,58:J,81:$,102:t1,104:265,105:230,106:e1,107:s1,108:u1,109:i1},e(q,[2,126]),{14:k1,42:b1,58:g1,86:D1,98:266,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1,117:84},{14:k1,42:b1,58:g1,86:D1,98:267,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1,117:84},{95:[1,268]},e(T,[2,113]),e(N,[2,53]),{30:269,65:f,77:P,78:w,79:164,113:A,114:d,115:E},e(N,[2,61]),e(nt,l,{5:270}),e(Kt,[2,124],{105:256,10:Z,58:J,81:$,102:t1,106:e1,107:s1,108:u1,109:i1}),e(T,[2,119],{117:160,10:[1,271],14:k1,42:b1,58:g1,86:D1,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1}),e(T,[2,120],{117:160,10:[1,272],14:k1,42:b1,58:g1,86:D1,102:F1,103:T1,106:C1,108:S1,111:_1,112:B1,113:x1}),e(T,[2,107]),{31:[1,273],65:f,79:208,113:A,114:d,115:E},{6:11,7:12,8:h,9:U,10:F,11:O,20:17,22:18,23:19,24:20,25:21,26:22,27:z,32:[1,274],33:24,34:c1,36:f1,38:A1,40:28,41:38,42:S,43:39,45:40,58:k,81:o1,82:U1,83:G1,84:M1,85:K1,86:B,99:x,102:y,103:m,106:v,108:V,110:41,111:L,112:I,113:R,118:j1,119:Y1,120:X1,121:z1},{10:Z,58:J,81:$,89:275,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},{10:Z,58:J,81:$,89:276,102:t1,104:229,105:230,106:e1,107:s1,108:u1,109:i1},e(N,[2,57]),e(b,[2,33]),e(T,[2,117],{103:m1}),e(T,[2,118],{103:m1})],defaultActions:{},parseError:function(a,o){if(o.recoverable)this.trace(a);else{var p=new Error(a);throw p.hash=o,p}},parse:function(a){var o=this,p=[0],r=[],C=[null],t=[],N1=this.table,s="",j=0,jt=0,Ie=2,Yt=1,Re=t.slice.call(arguments,1),_=Object.create(this.lexer),d1={yy:{}};for(var ot in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ot)&&(d1.yy[ot]=this.yy[ot]);_.setInput(a,d1.yy),d1.yy.lexer=_,d1.yy.parser=this,typeof _.yylloc>"u"&&(_.yylloc={});var lt=_.yylloc;t.push(lt);var Ne=_.options&&_.options.ranges;typeof d1.yy.parseError=="function"?this.parseError=d1.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Oe(){var n1;return n1=r.pop()||_.lex()||Yt,typeof n1!="number"&&(n1 instanceof Array&&(r=n1,n1=r.pop()),n1=o.symbols_[n1]||n1),n1}for(var G,E1,Y,ht,v1={},W1,r1,Xt,Q1;;){if(E1=p[p.length-1],this.defaultActions[E1]?Y=this.defaultActions[E1]:((G===null||typeof G>"u")&&(G=Oe()),Y=N1[E1]&&N1[E1][G]),typeof Y>"u"||!Y.length||!Y[0]){var pt="";Q1=[];for(W1 in N1[E1])this.terminals_[W1]&&W1>Ie&&Q1.push("'"+this.terminals_[W1]+"'");_.showPosition?pt="Parse error on line "+(j+1)+`: `+_.showPosition()+` Expecting `+Q1.join(", ")+", got '"+(this.terminals_[G]||G)+"'":pt="Parse error on line "+(j+1)+": Unexpected "+(G==Yt?"end of input":"'"+(this.terminals_[G]||G)+"'"),this.parseError(pt,{text:_.match,token:this.terminals_[G]||G,line:_.yylineno,loc:lt,expected:Q1})}if(Y[0]instanceof Array&&Y.length>1)throw new Error("Parse Error: multiple actions possible at state: "+E1+", token: "+G);switch(Y[0]){case 1:p.push(G),C.push(_.yytext),t.push(_.yylloc),p.push(Y[1]),G=null,jt=_.yyleng,s=_.yytext,j=_.yylineno,lt=_.yylloc;break;case 2:if(r1=this.productions_[Y[1]][1],v1.$=C[C.length-r1],v1._$={first_line:t[t.length-(r1||1)].first_line,last_line:t[t.length-1].last_line,first_column:t[t.length-(r1||1)].first_column,last_column:t[t.length-1].last_column},Ne&&(v1._$.range=[t[t.length-(r1||1)].range[0],t[t.length-1].range[1]]),ht=this.performAction.apply(v1,[s,jt,j,d1.yy,Y[1],C,t].concat(Re)),typeof ht<"u")return ht;r1&&(p=p.slice(0,-1*r1*2),C=C.slice(0,-1*r1),t=t.slice(0,-1*r1)),p.push(this.productions_[Y[1]][0]),C.push(v1.$),t.push(v1._$),Xt=N1[p[p.length-2]][p[p.length-1]],p.push(Xt);break;case 3:return!0}}return!0}},Le=function(){var h1={EOF:1,parseError:function(o,p){if(this.yy.parser)this.yy.parser.parseError(o,p);else throw new Error(o)},setInput:function(a,o){return this.yy=o||this.yy||{},this._input=a,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var a=this._input[0];this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a;var o=a.match(/(?:\r\n?|\n).*/g);return o?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),a},unput:function(a){var o=a.length,p=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-o),this.offset-=o;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),p.length-1&&(this.yylineno-=p.length-1);var C=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:p?(p.length===r.length?this.yylloc.first_column:0)+r[r.length-p.length].length-p[0].length:this.yylloc.first_column-o},this.options.ranges&&(this.yylloc.range=[C[0],C[0]+this.yyleng-o]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(a){this.unput(this.match.slice(a))},pastInput:function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var a=this.pastInput(),o=new Array(a.length+1).join("-");return a+this.upcomingInput()+` `+o+"^"},test_match:function(a,o){var p,r,C;if(this.options.backtrack_lexer&&(C={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(C.yylloc.range=this.yylloc.range.slice(0))),r=a[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(a[0].length),this.matched+=a[0],p=this.performAction.call(this,this.yy,this,o,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),p)return p;if(this._backtrack){for(var t in C)this[t]=C[t];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var a,o,p,r;this._more||(this.yytext="",this.match="");for(var C=this._currentRules(),t=0;to[0].length)){if(o=p,r=t,this.options.backtrack_lexer){if(a=this.test_match(p,C[t]),a!==!1)return a;if(this._backtrack){o=!1;continue}else return!1}else if(!this.options.flex)break}return o?(a=this.test_match(o,C[r]),a!==!1?a:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text. -`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var o=this.next();return o||this.lex()},begin:function(o){this.conditionStack.push(o)},popState:function(){var o=this.conditionStack.length-1;return o>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(o){return o=this.conditionStack.length-1-Math.abs(o||0),o>=0?this.conditionStack[o]:"INITIAL"},pushState:function(o){this.begin(o)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(o,p,r,C){switch(r){case 0:return this.begin("acc_title"),34;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),36;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:this.begin("callbackname");break;case 8:this.popState();break;case 9:this.popState(),this.begin("callbackargs");break;case 10:return 92;case 11:this.popState();break;case 12:return 93;case 13:return"MD_STR";case 14:this.popState();break;case 15:this.begin("md_string");break;case 16:return"STR";case 17:this.popState();break;case 18:this.pushState("string");break;case 19:return 81;case 20:return 99;case 21:return 82;case 22:return 101;case 23:return 83;case 24:return 84;case 25:return 94;case 26:this.begin("click");break;case 27:this.popState();break;case 28:return 85;case 29:return o.lex.firstGraph()&&this.begin("dir"),12;case 30:return o.lex.firstGraph()&&this.begin("dir"),12;case 31:return o.lex.firstGraph()&&this.begin("dir"),12;case 32:return 27;case 33:return 32;case 34:return 95;case 35:return 95;case 36:return 95;case 37:return 95;case 38:return this.popState(),13;case 39:return this.popState(),14;case 40:return this.popState(),14;case 41:return this.popState(),14;case 42:return this.popState(),14;case 43:return this.popState(),14;case 44:return this.popState(),14;case 45:return this.popState(),14;case 46:return this.popState(),14;case 47:return this.popState(),14;case 48:return this.popState(),14;case 49:return 118;case 50:return 119;case 51:return 120;case 52:return 121;case 53:return 102;case 54:return 108;case 55:return 44;case 56:return 58;case 57:return 42;case 58:return 8;case 59:return 103;case 60:return 112;case 61:return this.popState(),75;case 62:return this.pushState("edgeText"),73;case 63:return 116;case 64:return this.popState(),75;case 65:return this.pushState("thickEdgeText"),73;case 66:return 116;case 67:return this.popState(),75;case 68:return this.pushState("dottedEdgeText"),73;case 69:return 116;case 70:return 75;case 71:return this.popState(),51;case 72:return"TEXT";case 73:return this.pushState("ellipseText"),50;case 74:return this.popState(),53;case 75:return this.pushState("text"),52;case 76:return this.popState(),55;case 77:return this.pushState("text"),54;case 78:return 56;case 79:return this.pushState("text"),65;case 80:return this.popState(),62;case 81:return this.pushState("text"),61;case 82:return this.popState(),47;case 83:return this.pushState("text"),46;case 84:return this.popState(),67;case 85:return this.popState(),69;case 86:return 114;case 87:return this.pushState("trapText"),66;case 88:return this.pushState("trapText"),68;case 89:return 115;case 90:return 65;case 91:return 87;case 92:return"SEP";case 93:return 86;case 94:return 112;case 95:return 108;case 96:return 42;case 97:return 106;case 98:return 111;case 99:return 113;case 100:return this.popState(),60;case 101:return this.pushState("text"),60;case 102:return this.popState(),49;case 103:return this.pushState("text"),48;case 104:return this.popState(),31;case 105:return this.pushState("text"),29;case 106:return this.popState(),64;case 107:return this.pushState("text"),63;case 108:return"TEXT";case 109:return"QUOTE";case 110:return 9;case 111:return 10;case 112:return 11}},rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:flowchart-elk\b)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:[^=]|=(?!))/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:[^\.]|\.(?!))/,/^(?:\s*~~[\~]+\s*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|(?!\)+))/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|[^\\\[\]\(\)\{\}\/]+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09C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F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:[^\[\]\(\)\{\}\|\"]+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{callbackargs:{rules:[11,12,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},callbackname:{rules:[8,9,10,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},href:{rules:[15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},click:{rules:[15,18,27,28,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},dottedEdgeText:{rules:[15,18,67,69,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},thickEdgeText:{rules:[15,18,64,66,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},edgeText:{rules:[15,18,61,63,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},trapText:{rules:[15,18,70,73,75,77,81,83,84,85,86,87,88,101,103,105,107],inclusive:!1},ellipseText:{rules:[15,18,70,71,72,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},text:{rules:[15,18,70,73,74,75,76,77,80,81,82,83,87,88,100,101,102,103,104,105,106,107,108],inclusive:!1},vertex:{rules:[15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},dir:{rules:[15,18,38,39,40,41,42,43,44,45,46,47,48,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},acc_descr_multiline:{rules:[5,6,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},acc_descr:{rules:[3,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},acc_title:{rules:[1,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},md_string:{rules:[13,14,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},string:{rules:[15,16,17,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},INITIAL:{rules:[0,2,4,7,15,18,19,20,21,22,23,24,25,26,29,30,31,32,33,34,35,36,37,49,50,51,52,53,54,55,56,57,58,59,60,61,62,64,65,67,68,70,73,75,77,78,79,81,83,87,88,89,90,91,92,93,94,95,96,97,98,99,101,103,105,107,109,110,111,112],inclusive:!0}}};return h1}();at.lexer=Le;function ct(){this.yy={}}return ct.prototype=at,at.Parser=ct,new ct}();ft.parser=ft;var qe=ft,Pe="flowchart-",ee=0,dt=J1(),D={},p1=[],L1={},a1=[],tt={},et={},$1=0,At=!0,X,st,ut=[],it=e=>zt.sanitizeText(e,dt),w1=function(e){let u=Object.keys(D);for(let i of u)if(D[i].id===e)return D[i].domId;return e},se=function(e,u,i,n,c,l,h={}){let U,F=e;F!==void 0&&F.trim().length!==0&&(D[F]===void 0&&(D[F]={id:F,labelType:"text",domId:Pe+F+"-"+ee,styles:[],classes:[]}),ee++,u!==void 0?(dt=J1(),U=it(u.text.trim()),D[F].labelType=u.type,U[0]==='"'&&U[U.length-1]==='"'&&(U=U.substring(1,U.length-1)),D[F].text=U):D[F].text===void 0&&(D[F].text=e),i!==void 0&&(D[F].type=i),n?.forEach(function(O){D[F].styles.push(O)}),c?.forEach(function(O){D[F].classes.push(O)}),l!==void 0&&(D[F].dir=l),D[F].props===void 0?D[F].props=h:h!==void 0&&Object.assign(D[F].props,h))},ue=function(e,u,i){let l={start:e,end:u,type:void 0,text:"",labelType:"text"};O1.info("abc78 Got edge...",l);let h=i.text;if(h!==void 0&&(l.text=it(h.text.trim()),l.text[0]==='"'&&l.text[l.text.length-1]==='"'&&(l.text=l.text.substring(1,l.text.length-1)),l.labelType=h.type),i!==void 0&&(l.type=i.type,l.stroke=i.stroke,l.length=i.length),l?.length>10&&(l.length=10),p1.length<280)O1.info("abc78 pushing edge..."),p1.push(l);else throw new Error("Too many edges")},ie=function(e,u,i){O1.info("addLink (abc78)",e,u,i);let n,c;for(n=0;n/)&&(X="LR"),X.match(/.*v/)&&(X="TB"),X==="TD"&&(X="TB")},rt=function(e,u){e.split(",").forEach(function(i){let n=i;D[n]!==void 0&&D[n].classes.push(u),tt[n]!==void 0&&tt[n].classes.push(u)})},we=function(e,u){e.split(",").forEach(function(i){u!==void 0&&(et[st==="gen-1"?w1(i):i]=it(u))})},Ue=function(e,u,i){let n=w1(e);if(J1().securityLevel!=="loose"||u===void 0)return;let c=[];if(typeof i=="string"){c=i.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let l=0;l")),c.classed("hover",!0)}).on("mouseout",function(){u.transition().duration(500).style("opacity",0),V1(this).classed("hover",!1)})};ut.push(ke);var be=function(e="gen-1"){D={},L1={},p1=[],ut=[ke],a1=[],tt={},$1=0,et={},At=!0,st=e,qt()},ge=e=>{st=e||"gen-2"},De=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},Fe=function(e,u,i){let n=e.text.trim(),c=i.text;e===i&&i.text.match(/\s/)&&(n=void 0);function l(z){let c1={boolean:{},number:{},string:{}},f1=[],A1;return{nodeList:z.filter(function(k){let o1=typeof k;return k.stmt&&k.stmt==="dir"?(A1=k.value,!1):k.trim()===""?!1:o1 in c1?c1[o1].hasOwnProperty(k)?!1:c1[o1][k]=!0:f1.includes(k)?!1:f1.push(k)}),dir:A1}}let h=[],{nodeList:U,dir:F}=l(h.concat.apply(h,u));if(h=U,st==="gen-1")for(let z=0;z2e3)return;if(Te[P1]=u,a1[u].id===e)return{result:!0,count:0};let n=0,c=1;for(;n=0){let h=Ce(e,l);if(h.result)return{result:!0,count:c+h.count};c=c+h.count}n=n+1}return{result:!1,count:c}},Se=function(e){return Te[e]},_e=function(){P1=-1,a1.length>0&&Ce("none",a1.length-1)},Be=function(){return a1},xe=()=>At?(At=!1,!0):!1,Me=e=>{let u=e.trim(),i="arrow_open";switch(u[0]){case"<":i="arrow_point",u=u.slice(1);break;case"x":i="arrow_cross",u=u.slice(1);break;case"o":i="arrow_circle",u=u.slice(1);break}let n="normal";return u.includes("=")&&(n="thick"),u.includes(".")&&(n="dotted"),{type:i,stroke:n}},Ke=(e,u)=>{let i=u.length,n=0;for(let c=0;c{let u=e.trim(),i=u.slice(0,-1),n="arrow_open";switch(u.slice(-1)){case"x":n="arrow_cross",u[0]==="x"&&(n="double_"+n,i=i.slice(1));break;case">":n="arrow_point",u[0]==="<"&&(n="double_"+n,i=i.slice(1));break;case"o":n="arrow_circle",u[0]==="o"&&(n="double_"+n,i=i.slice(1));break}let c="normal",l=i.length-1;i[0]==="="&&(c="thick"),i[0]==="~"&&(c="invisible");let h=Ke(".",i);return h&&(c="dotted",l=h),{type:n,stroke:c,length:l}},ye=(e,u)=>{let i=je(e),n;if(u){if(n=Me(u),n.stroke!==i.stroke)return{type:"INVALID",stroke:"INVALID"};if(n.type==="arrow_open")n.type=i.type;else{if(n.type!==i.type)return{type:"INVALID",stroke:"INVALID"};n.type="double_"+n.type}return n.type==="double_arrow"&&(n.type="double_arrow_point"),n.length=i.length,n}return i},me=(e,u)=>{let i=!1;return e.forEach(n=>{n.nodes.indexOf(u)>=0&&(i=!0)}),i},ve=(e,u)=>{let i=[];return e.nodes.forEach((n,c)=>{me(u,n)||i.push(e.nodes[c])}),{nodes:i}},Ve={firstGraph:xe},Ye={defaultConfig:()=>te.flowchart,setAccTitle:Ht,getAccTitle:Wt,getAccDescription:Zt,setAccDescription:Qt,addVertex:se,lookUpDomId:w1,addLink:ie,updateLinkInterpolate:re,updateLink:ne,addClass:ae,setDirection:ce,setClass:rt,setTooltip:we,getTooltip:le,setClickEvent:he,setLink:oe,bindFunctions:pe,getDirection:fe,getVertices:Ae,getEdges:de,getClasses:Ee,clear:be,setGen:ge,defaultStyle:De,addSubGraph:Fe,getDepthFirstPos:Se,indexNodes:_e,getSubGraphs:Be,destructLink:ye,lex:Ve,exists:me,makeUniq:ve,setDiagramTitle:Jt,getDiagramTitle:$t},He=Object.freeze(Object.defineProperty({__proto__:null,addClass:ae,addLink:ie,addSingleLink:ue,addSubGraph:Fe,addVertex:se,bindFunctions:pe,clear:be,default:Ye,defaultStyle:De,destructLink:ye,firstGraph:xe,getClasses:Ee,getDepthFirstPos:Se,getDirection:fe,getEdges:de,getSubGraphs:Be,getTooltip:le,getVertices:Ae,indexNodes:_e,lex:Ve,lookUpDomId:w1,setClass:rt,setClickEvent:he,setDirection:ce,setGen:ge,setLink:oe,updateLink:ne,updateLinkInterpolate:re},Symbol.toStringTag,{value:"Module"}));export{qe as a,Ye as b,He as c}; -//# sourceMappingURL=chunk-WJ45NKHW.min.js.map +`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var o=this.next();return o||this.lex()},begin:function(o){this.conditionStack.push(o)},popState:function(){var o=this.conditionStack.length-1;return o>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(o){return o=this.conditionStack.length-1-Math.abs(o||0),o>=0?this.conditionStack[o]:"INITIAL"},pushState:function(o){this.begin(o)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(o,p,r,C){switch(r){case 0:return this.begin("acc_title"),34;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),36;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:this.begin("callbackname");break;case 8:this.popState();break;case 9:this.popState(),this.begin("callbackargs");break;case 10:return 92;case 11:this.popState();break;case 12:return 93;case 13:return"MD_STR";case 14:this.popState();break;case 15:this.begin("md_string");break;case 16:return"STR";case 17:this.popState();break;case 18:this.pushState("string");break;case 19:return 81;case 20:return 99;case 21:return 82;case 22:return 101;case 23:return 83;case 24:return 84;case 25:return 94;case 26:this.begin("click");break;case 27:this.popState();break;case 28:return 85;case 29:return o.lex.firstGraph()&&this.begin("dir"),12;case 30:return o.lex.firstGraph()&&this.begin("dir"),12;case 31:return o.lex.firstGraph()&&this.begin("dir"),12;case 32:return 27;case 33:return 32;case 34:return 95;case 35:return 95;case 36:return 95;case 37:return 95;case 38:return this.popState(),13;case 39:return this.popState(),14;case 40:return this.popState(),14;case 41:return this.popState(),14;case 42:return this.popState(),14;case 43:return this.popState(),14;case 44:return this.popState(),14;case 45:return this.popState(),14;case 46:return this.popState(),14;case 47:return this.popState(),14;case 48:return this.popState(),14;case 49:return 118;case 50:return 119;case 51:return 120;case 52:return 121;case 53:return 102;case 54:return 108;case 55:return 44;case 56:return 58;case 57:return 42;case 58:return 8;case 59:return 103;case 60:return 112;case 61:return this.popState(),75;case 62:return this.pushState("edgeText"),73;case 63:return 116;case 64:return this.popState(),75;case 65:return this.pushState("thickEdgeText"),73;case 66:return 116;case 67:return this.popState(),75;case 68:return this.pushState("dottedEdgeText"),73;case 69:return 116;case 70:return 75;case 71:return this.popState(),51;case 72:return"TEXT";case 73:return this.pushState("ellipseText"),50;case 74:return this.popState(),53;case 75:return this.pushState("text"),52;case 76:return this.popState(),55;case 77:return this.pushState("text"),54;case 78:return 56;case 79:return this.pushState("text"),65;case 80:return this.popState(),62;case 81:return this.pushState("text"),61;case 82:return this.popState(),47;case 83:return this.pushState("text"),46;case 84:return this.popState(),67;case 85:return this.popState(),69;case 86:return 114;case 87:return this.pushState("trapText"),66;case 88:return this.pushState("trapText"),68;case 89:return 115;case 90:return 65;case 91:return 87;case 92:return"SEP";case 93:return 86;case 94:return 112;case 95:return 108;case 96:return 42;case 97:return 106;case 98:return 111;case 99:return 113;case 100:return this.popState(),60;case 101:return this.pushState("text"),60;case 102:return this.popState(),49;case 103:return this.pushState("text"),48;case 104:return this.popState(),31;case 105:return this.pushState("text"),29;case 106:return this.popState(),64;case 107:return this.pushState("text"),63;case 108:return"TEXT";case 109:return"QUOTE";case 110:return 9;case 111:return 10;case 112:return 11}},rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:flowchart-elk\b)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:[^=]|=(?!))/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:[^\.]|\.(?!))/,/^(?:\s*~~[\~]+\s*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|[^\\\[\]\(\)\{\}\/]+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\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EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:[^\[\]\(\)\{\}\|\"]+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{callbackargs:{rules:[11,12,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},callbackname:{rules:[8,9,10,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},href:{rules:[15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},click:{rules:[15,18,27,28,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},dottedEdgeText:{rules:[15,18,67,69,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},thickEdgeText:{rules:[15,18,64,66,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},edgeText:{rules:[15,18,61,63,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},trapText:{rules:[15,18,70,73,75,77,81,83,84,85,86,87,88,101,103,105,107],inclusive:!1},ellipseText:{rules:[15,18,70,71,72,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},text:{rules:[15,18,70,73,74,75,76,77,80,81,82,83,87,88,100,101,102,103,104,105,106,107,108],inclusive:!1},vertex:{rules:[15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},dir:{rules:[15,18,38,39,40,41,42,43,44,45,46,47,48,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},acc_descr_multiline:{rules:[5,6,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},acc_descr:{rules:[3,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},acc_title:{rules:[1,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},md_string:{rules:[13,14,15,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},string:{rules:[15,16,17,18,70,73,75,77,81,83,87,88,101,103,105,107],inclusive:!1},INITIAL:{rules:[0,2,4,7,15,18,19,20,21,22,23,24,25,26,29,30,31,32,33,34,35,36,37,49,50,51,52,53,54,55,56,57,58,59,60,61,62,64,65,67,68,70,73,75,77,78,79,81,83,87,88,89,90,91,92,93,94,95,96,97,98,99,101,103,105,107,109,110,111,112],inclusive:!0}}};return h1}();at.lexer=Le;function ct(){this.yy={}}return ct.prototype=at,at.Parser=ct,new ct}();ft.parser=ft;var qe=ft,Pe="flowchart-",ee=0,dt=J1(),D={},p1=[],L1={},a1=[],tt={},et={},$1=0,At=!0,X,st,ut=[],it=e=>zt.sanitizeText(e,dt),w1=function(e){let u=Object.keys(D);for(let i of u)if(D[i].id===e)return D[i].domId;return e},se=function(e,u,i,n,c,l,h={}){let U,F=e;F!==void 0&&F.trim().length!==0&&(D[F]===void 0&&(D[F]={id:F,labelType:"text",domId:Pe+F+"-"+ee,styles:[],classes:[]}),ee++,u!==void 0?(dt=J1(),U=it(u.text.trim()),D[F].labelType=u.type,U[0]==='"'&&U[U.length-1]==='"'&&(U=U.substring(1,U.length-1)),D[F].text=U):D[F].text===void 0&&(D[F].text=e),i!==void 0&&(D[F].type=i),n?.forEach(function(O){D[F].styles.push(O)}),c?.forEach(function(O){D[F].classes.push(O)}),l!==void 0&&(D[F].dir=l),D[F].props===void 0?D[F].props=h:h!==void 0&&Object.assign(D[F].props,h))},ue=function(e,u,i){let l={start:e,end:u,type:void 0,text:"",labelType:"text"};O1.info("abc78 Got edge...",l);let h=i.text;if(h!==void 0&&(l.text=it(h.text.trim()),l.text[0]==='"'&&l.text[l.text.length-1]==='"'&&(l.text=l.text.substring(1,l.text.length-1)),l.labelType=h.type),i!==void 0&&(l.type=i.type,l.stroke=i.stroke,l.length=i.length),l?.length>10&&(l.length=10),p1.length<280)O1.info("abc78 pushing edge..."),p1.push(l);else throw new Error("Too many edges")},ie=function(e,u,i){O1.info("addLink (abc78)",e,u,i);let n,c;for(n=0;n/)&&(X="LR"),X.match(/.*v/)&&(X="TB"),X==="TD"&&(X="TB")},rt=function(e,u){e.split(",").forEach(function(i){let n=i;D[n]!==void 0&&D[n].classes.push(u),tt[n]!==void 0&&tt[n].classes.push(u)})},we=function(e,u){e.split(",").forEach(function(i){u!==void 0&&(et[st==="gen-1"?w1(i):i]=it(u))})},Ue=function(e,u,i){let n=w1(e);if(J1().securityLevel!=="loose"||u===void 0)return;let c=[];if(typeof i=="string"){c=i.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let l=0;l")),c.classed("hover",!0)}).on("mouseout",function(){u.transition().duration(500).style("opacity",0),V1(this).classed("hover",!1)})};ut.push(ke);var be=function(e="gen-1"){D={},L1={},p1=[],ut=[ke],a1=[],tt={},$1=0,et={},At=!0,st=e,qt()},ge=e=>{st=e||"gen-2"},De=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},Fe=function(e,u,i){let n=e.text.trim(),c=i.text;e===i&&i.text.match(/\s/)&&(n=void 0);function l(z){let c1={boolean:{},number:{},string:{}},f1=[],A1;return{nodeList:z.filter(function(k){let o1=typeof k;return k.stmt&&k.stmt==="dir"?(A1=k.value,!1):k.trim()===""?!1:o1 in c1?c1[o1].hasOwnProperty(k)?!1:c1[o1][k]=!0:f1.includes(k)?!1:f1.push(k)}),dir:A1}}let h=[],{nodeList:U,dir:F}=l(h.concat.apply(h,u));if(h=U,st==="gen-1")for(let z=0;z2e3)return;if(Te[P1]=u,a1[u].id===e)return{result:!0,count:0};let n=0,c=1;for(;n=0){let h=Ce(e,l);if(h.result)return{result:!0,count:c+h.count};c=c+h.count}n=n+1}return{result:!1,count:c}},Se=function(e){return Te[e]},_e=function(){P1=-1,a1.length>0&&Ce("none",a1.length-1)},Be=function(){return a1},xe=()=>At?(At=!1,!0):!1,Me=e=>{let u=e.trim(),i="arrow_open";switch(u[0]){case"<":i="arrow_point",u=u.slice(1);break;case"x":i="arrow_cross",u=u.slice(1);break;case"o":i="arrow_circle",u=u.slice(1);break}let n="normal";return u.includes("=")&&(n="thick"),u.includes(".")&&(n="dotted"),{type:i,stroke:n}},Ke=(e,u)=>{let i=u.length,n=0;for(let c=0;c{let u=e.trim(),i=u.slice(0,-1),n="arrow_open";switch(u.slice(-1)){case"x":n="arrow_cross",u[0]==="x"&&(n="double_"+n,i=i.slice(1));break;case">":n="arrow_point",u[0]==="<"&&(n="double_"+n,i=i.slice(1));break;case"o":n="arrow_circle",u[0]==="o"&&(n="double_"+n,i=i.slice(1));break}let c="normal",l=i.length-1;i[0]==="="&&(c="thick"),i[0]==="~"&&(c="invisible");let h=Ke(".",i);return h&&(c="dotted",l=h),{type:n,stroke:c,length:l}},ye=(e,u)=>{let i=je(e),n;if(u){if(n=Me(u),n.stroke!==i.stroke)return{type:"INVALID",stroke:"INVALID"};if(n.type==="arrow_open")n.type=i.type;else{if(n.type!==i.type)return{type:"INVALID",stroke:"INVALID"};n.type="double_"+n.type}return n.type==="double_arrow"&&(n.type="double_arrow_point"),n.length=i.length,n}return i},me=(e,u)=>{let i=!1;return e.forEach(n=>{n.nodes.indexOf(u)>=0&&(i=!0)}),i},ve=(e,u)=>{let i=[];return e.nodes.forEach((n,c)=>{me(u,n)||i.push(e.nodes[c])}),{nodes:i}},Ve={firstGraph:xe},Ye={defaultConfig:()=>te.flowchart,setAccTitle:Ht,getAccTitle:Wt,getAccDescription:Zt,setAccDescription:Qt,addVertex:se,lookUpDomId:w1,addLink:ie,updateLinkInterpolate:re,updateLink:ne,addClass:ae,setDirection:ce,setClass:rt,setTooltip:we,getTooltip:le,setClickEvent:he,setLink:oe,bindFunctions:pe,getDirection:fe,getVertices:Ae,getEdges:de,getClasses:Ee,clear:be,setGen:ge,defaultStyle:De,addSubGraph:Fe,getDepthFirstPos:Se,indexNodes:_e,getSubGraphs:Be,destructLink:ye,lex:Ve,exists:me,makeUniq:ve,setDiagramTitle:Jt,getDiagramTitle:$t},He=Object.freeze(Object.defineProperty({__proto__:null,addClass:ae,addLink:ie,addSingleLink:ue,addSubGraph:Fe,addVertex:se,bindFunctions:pe,clear:be,default:Ye,defaultStyle:De,destructLink:ye,firstGraph:xe,getClasses:Ee,getDepthFirstPos:Se,getDirection:fe,getEdges:de,getSubGraphs:Be,getTooltip:le,getVertices:Ae,indexNodes:_e,lex:Ve,lookUpDomId:w1,setClass:rt,setClickEvent:he,setDirection:ce,setGen:ge,setLink:oe,updateLink:ne,updateLinkInterpolate:re},Symbol.toStringTag,{value:"Module"}));export{qe as a,Ye as b,He as c}; +//# sourceMappingURL=chunk-NJUUHU62.min.js.map diff --git a/docs/public/chunk-WJ45NKHW.min.js.map b/docs/public/chunk-NJUUHU62.min.js.map similarity index 83% rename from docs/public/chunk-WJ45NKHW.min.js.map rename to docs/public/chunk-NJUUHU62.min.js.map index d34aa6a0..477dc7c8 100644 --- a/docs/public/chunk-WJ45NKHW.min.js.map +++ b/docs/public/chunk-NJUUHU62.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/flowDb-1972c806.js"], - "sourcesContent": ["import { select } from \"d3\";\nimport { I as defaultConfig, s as setAccTitle, g as getAccTitle, a as getAccDescription, b as setAccDescription, q as setDiagramTitle, r as getDiagramTitle, c as getConfig, l as log, u as utils, t as clear$1, e as common } from \"./mermaid-8af3addd.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 4], $V1 = [1, 3], $V2 = [1, 5], $V3 = [1, 8, 9, 10, 11, 27, 34, 36, 38, 42, 58, 81, 82, 83, 84, 85, 86, 99, 102, 103, 106, 108, 111, 112, 113, 118, 119, 120, 121], $V4 = [2, 2], $V5 = [1, 13], $V6 = [1, 14], $V7 = [1, 15], $V8 = [1, 16], $V9 = [1, 23], $Va = [1, 25], $Vb = [1, 26], $Vc = [1, 27], $Vd = [1, 49], $Ve = [1, 48], $Vf = [1, 29], $Vg = [1, 30], $Vh = [1, 31], $Vi = [1, 32], $Vj = [1, 33], $Vk = [1, 44], $Vl = [1, 46], $Vm = [1, 42], $Vn = [1, 47], $Vo = [1, 43], $Vp = [1, 50], $Vq = [1, 45], $Vr = [1, 51], $Vs = [1, 52], $Vt = [1, 34], $Vu = [1, 35], $Vv = [1, 36], $Vw = [1, 37], $Vx = [1, 57], $Vy = [1, 8, 9, 10, 11, 27, 32, 34, 36, 38, 42, 58, 81, 82, 83, 84, 85, 86, 99, 102, 103, 106, 108, 111, 112, 113, 118, 119, 120, 121], $Vz = [1, 61], $VA = [1, 60], $VB = [1, 62], $VC = [8, 9, 11, 73, 75], $VD = [1, 88], $VE = [1, 93], $VF = [1, 92], $VG = [1, 89], $VH = [1, 85], $VI = [1, 91], $VJ = [1, 87], $VK = [1, 94], $VL = [1, 90], $VM = [1, 95], $VN = [1, 86], $VO = [8, 9, 10, 11, 73, 75], $VP = [8, 9, 10, 11, 44, 73, 75], $VQ = [8, 9, 10, 11, 29, 42, 44, 46, 48, 50, 52, 54, 56, 58, 61, 63, 65, 66, 68, 73, 75, 86, 99, 102, 103, 106, 108, 111, 112, 113], $VR = [8, 9, 11, 42, 58, 73, 75, 86, 99, 102, 103, 106, 108, 111, 112, 113], $VS = [42, 58, 86, 99, 102, 103, 106, 108, 111, 112, 113], $VT = [1, 121], $VU = [1, 120], $VV = [1, 128], $VW = [1, 142], $VX = [1, 143], $VY = [1, 144], $VZ = [1, 145], $V_ = [1, 130], $V$ = [1, 132], $V01 = [1, 136], $V11 = [1, 137], $V21 = [1, 138], $V31 = [1, 139], $V41 = [1, 140], $V51 = [1, 141], $V61 = [1, 146], $V71 = [1, 147], $V81 = [1, 126], $V91 = [1, 127], $Va1 = [1, 134], $Vb1 = [1, 129], $Vc1 = [1, 133], $Vd1 = [1, 131], $Ve1 = [8, 9, 10, 11, 27, 32, 34, 36, 38, 42, 58, 81, 82, 83, 84, 85, 86, 99, 102, 103, 106, 108, 111, 112, 113, 118, 119, 120, 121], $Vf1 = [1, 149], $Vg1 = [8, 9, 11], $Vh1 = [8, 9, 10, 11, 14, 42, 58, 86, 102, 103, 106, 108, 111, 112, 113], $Vi1 = [1, 169], $Vj1 = [1, 165], $Vk1 = [1, 166], $Vl1 = [1, 170], $Vm1 = [1, 167], $Vn1 = [1, 168], $Vo1 = [75, 113, 116], $Vp1 = [8, 9, 10, 11, 12, 14, 27, 29, 32, 42, 58, 73, 81, 82, 83, 84, 85, 86, 87, 102, 106, 108, 111, 112, 113], $Vq1 = [10, 103], $Vr1 = [31, 47, 49, 51, 53, 55, 60, 62, 64, 65, 67, 69, 113, 114, 115], $Vs1 = [1, 235], $Vt1 = [1, 233], $Vu1 = [1, 237], $Vv1 = [1, 231], $Vw1 = [1, 232], $Vx1 = [1, 234], $Vy1 = [1, 236], $Vz1 = [1, 238], $VA1 = [1, 255], $VB1 = [8, 9, 11, 103], $VC1 = [8, 9, 10, 11, 58, 81, 102, 103, 106, 107, 108, 109];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"graphConfig\": 4, \"document\": 5, \"line\": 6, \"statement\": 7, \"SEMI\": 8, \"NEWLINE\": 9, \"SPACE\": 10, \"EOF\": 11, \"GRAPH\": 12, \"NODIR\": 13, \"DIR\": 14, \"FirstStmtSeperator\": 15, \"ending\": 16, \"endToken\": 17, \"spaceList\": 18, \"spaceListNewline\": 19, \"verticeStatement\": 20, \"separator\": 21, \"styleStatement\": 22, \"linkStyleStatement\": 23, \"classDefStatement\": 24, \"classStatement\": 25, \"clickStatement\": 26, \"subgraph\": 27, \"textNoTags\": 28, \"SQS\": 29, \"text\": 30, \"SQE\": 31, \"end\": 32, \"direction\": 33, \"acc_title\": 34, \"acc_title_value\": 35, \"acc_descr\": 36, \"acc_descr_value\": 37, \"acc_descr_multiline_value\": 38, \"link\": 39, \"node\": 40, \"styledVertex\": 41, \"AMP\": 42, \"vertex\": 43, \"STYLE_SEPARATOR\": 44, \"idString\": 45, \"DOUBLECIRCLESTART\": 46, \"DOUBLECIRCLEEND\": 47, \"PS\": 48, \"PE\": 49, \"(-\": 50, \"-)\": 51, \"STADIUMSTART\": 52, \"STADIUMEND\": 53, \"SUBROUTINESTART\": 54, \"SUBROUTINEEND\": 55, \"VERTEX_WITH_PROPS_START\": 56, \"NODE_STRING[field]\": 57, \"COLON\": 58, \"NODE_STRING[value]\": 59, \"PIPE\": 60, \"CYLINDERSTART\": 61, \"CYLINDEREND\": 62, \"DIAMOND_START\": 63, \"DIAMOND_STOP\": 64, \"TAGEND\": 65, \"TRAPSTART\": 66, \"TRAPEND\": 67, \"INVTRAPSTART\": 68, \"INVTRAPEND\": 69, \"linkStatement\": 70, \"arrowText\": 71, \"TESTSTR\": 72, \"START_LINK\": 73, \"edgeText\": 74, \"LINK\": 75, \"edgeTextToken\": 76, \"STR\": 77, \"MD_STR\": 78, \"textToken\": 79, \"keywords\": 80, \"STYLE\": 81, \"LINKSTYLE\": 82, \"CLASSDEF\": 83, \"CLASS\": 84, \"CLICK\": 85, \"DOWN\": 86, \"UP\": 87, \"textNoTagsToken\": 88, \"stylesOpt\": 89, \"idString[vertex]\": 90, \"idString[class]\": 91, \"CALLBACKNAME\": 92, \"CALLBACKARGS\": 93, \"HREF\": 94, \"LINK_TARGET\": 95, \"STR[link]\": 96, \"STR[tooltip]\": 97, \"alphaNum\": 98, \"DEFAULT\": 99, \"numList\": 100, \"INTERPOLATE\": 101, \"NUM\": 102, \"COMMA\": 103, \"style\": 104, \"styleComponent\": 105, \"NODE_STRING\": 106, \"UNIT\": 107, \"BRKT\": 108, \"PCT\": 109, \"idStringToken\": 110, \"MINUS\": 111, \"MULT\": 112, \"UNICODE_TEXT\": 113, \"TEXT\": 114, \"TAGSTART\": 115, \"EDGE_TEXT\": 116, \"alphaNumToken\": 117, \"direction_tb\": 118, \"direction_bt\": 119, \"direction_rl\": 120, \"direction_lr\": 121, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 8: \"SEMI\", 9: \"NEWLINE\", 10: \"SPACE\", 11: \"EOF\", 12: \"GRAPH\", 13: \"NODIR\", 14: \"DIR\", 27: \"subgraph\", 29: \"SQS\", 31: \"SQE\", 32: \"end\", 34: \"acc_title\", 35: \"acc_title_value\", 36: \"acc_descr\", 37: \"acc_descr_value\", 38: \"acc_descr_multiline_value\", 42: \"AMP\", 44: \"STYLE_SEPARATOR\", 46: \"DOUBLECIRCLESTART\", 47: \"DOUBLECIRCLEEND\", 48: \"PS\", 49: \"PE\", 50: \"(-\", 51: \"-)\", 52: \"STADIUMSTART\", 53: \"STADIUMEND\", 54: \"SUBROUTINESTART\", 55: \"SUBROUTINEEND\", 56: \"VERTEX_WITH_PROPS_START\", 57: \"NODE_STRING[field]\", 58: \"COLON\", 59: \"NODE_STRING[value]\", 60: \"PIPE\", 61: \"CYLINDERSTART\", 62: \"CYLINDEREND\", 63: \"DIAMOND_START\", 64: \"DIAMOND_STOP\", 65: \"TAGEND\", 66: \"TRAPSTART\", 67: \"TRAPEND\", 68: \"INVTRAPSTART\", 69: \"INVTRAPEND\", 72: \"TESTSTR\", 73: \"START_LINK\", 75: \"LINK\", 77: \"STR\", 78: \"MD_STR\", 81: \"STYLE\", 82: \"LINKSTYLE\", 83: \"CLASSDEF\", 84: \"CLASS\", 85: \"CLICK\", 86: \"DOWN\", 87: \"UP\", 90: \"idString[vertex]\", 91: \"idString[class]\", 92: \"CALLBACKNAME\", 93: \"CALLBACKARGS\", 94: \"HREF\", 95: \"LINK_TARGET\", 96: \"STR[link]\", 97: \"STR[tooltip]\", 99: \"DEFAULT\", 101: \"INTERPOLATE\", 102: \"NUM\", 103: \"COMMA\", 106: \"NODE_STRING\", 107: \"UNIT\", 108: \"BRKT\", 109: \"PCT\", 111: \"MINUS\", 112: \"MULT\", 113: \"UNICODE_TEXT\", 114: \"TEXT\", 115: \"TAGSTART\", 116: \"EDGE_TEXT\", 118: \"direction_tb\", 119: \"direction_bt\", 120: \"direction_rl\", 121: \"direction_lr\" },\n productions_: [0, [3, 2], [5, 0], [5, 2], [6, 1], [6, 1], [6, 1], [6, 1], [6, 1], [4, 2], [4, 2], [4, 2], [4, 3], [16, 2], [16, 1], [17, 1], [17, 1], [17, 1], [15, 1], [15, 1], [15, 2], [19, 2], [19, 2], [19, 1], [19, 1], [18, 2], [18, 1], [7, 2], [7, 2], [7, 2], [7, 2], [7, 2], [7, 2], [7, 9], [7, 6], [7, 4], [7, 1], [7, 2], [7, 2], [7, 1], [21, 1], [21, 1], [21, 1], [20, 3], [20, 4], [20, 2], [20, 1], [40, 1], [40, 5], [41, 1], [41, 3], [43, 4], [43, 4], [43, 6], [43, 4], [43, 4], [43, 4], [43, 8], [43, 4], [43, 4], [43, 4], [43, 6], [43, 4], [43, 4], [43, 4], [43, 4], [43, 4], [43, 1], [39, 2], [39, 3], [39, 3], [39, 1], [39, 3], [74, 1], [74, 2], [74, 1], [74, 1], [70, 1], [71, 3], [30, 1], [30, 2], [30, 1], [30, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [28, 1], [28, 2], [28, 1], [28, 1], [24, 5], [25, 5], [26, 2], [26, 4], [26, 3], [26, 5], [26, 3], [26, 5], [26, 5], [26, 7], [26, 2], [26, 4], [26, 2], [26, 4], [26, 4], [26, 6], [22, 5], [23, 5], [23, 5], [23, 9], [23, 9], [23, 7], [23, 7], [100, 1], [100, 3], [89, 1], [89, 3], [104, 1], [104, 2], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [79, 1], [79, 1], [79, 1], [79, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [76, 1], [76, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [45, 1], [45, 2], [98, 1], [98, 2], [33, 1], [33, 1], [33, 1], [33, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 2:\n this.$ = [];\n break;\n case 3:\n if (!Array.isArray($$[$0]) || $$[$0].length > 0) {\n $$[$0 - 1].push($$[$0]);\n }\n this.$ = $$[$0 - 1];\n break;\n case 4:\n case 176:\n this.$ = $$[$0];\n break;\n case 11:\n yy.setDirection(\"TB\");\n this.$ = \"TB\";\n break;\n case 12:\n yy.setDirection($$[$0 - 1]);\n this.$ = $$[$0 - 1];\n break;\n case 27:\n this.$ = $$[$0 - 1].nodes;\n break;\n case 28:\n case 29:\n case 30:\n case 31:\n case 32:\n this.$ = [];\n break;\n case 33:\n this.$ = yy.addSubGraph($$[$0 - 6], $$[$0 - 1], $$[$0 - 4]);\n break;\n case 34:\n this.$ = yy.addSubGraph($$[$0 - 3], $$[$0 - 1], $$[$0 - 3]);\n break;\n case 35:\n this.$ = yy.addSubGraph(void 0, $$[$0 - 1], void 0);\n break;\n case 37:\n this.$ = $$[$0].trim();\n yy.setAccTitle(this.$);\n break;\n case 38:\n case 39:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 43:\n yy.addLink($$[$0 - 2].stmt, $$[$0], $$[$0 - 1]);\n this.$ = { stmt: $$[$0], nodes: $$[$0].concat($$[$0 - 2].nodes) };\n break;\n case 44:\n yy.addLink($$[$0 - 3].stmt, $$[$0 - 1], $$[$0 - 2]);\n this.$ = { stmt: $$[$0 - 1], nodes: $$[$0 - 1].concat($$[$0 - 3].nodes) };\n break;\n case 45:\n this.$ = { stmt: $$[$0 - 1], nodes: $$[$0 - 1] };\n break;\n case 46:\n this.$ = { stmt: $$[$0], nodes: $$[$0] };\n break;\n case 47:\n this.$ = [$$[$0]];\n break;\n case 48:\n this.$ = $$[$0 - 4].concat($$[$0]);\n break;\n case 49:\n this.$ = $$[$0];\n break;\n case 50:\n this.$ = $$[$0 - 2];\n yy.setClass($$[$0 - 2], $$[$0]);\n break;\n case 51:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"square\");\n break;\n case 52:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"doublecircle\");\n break;\n case 53:\n this.$ = $$[$0 - 5];\n yy.addVertex($$[$0 - 5], $$[$0 - 2], \"circle\");\n break;\n case 54:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"ellipse\");\n break;\n case 55:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"stadium\");\n break;\n case 56:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"subroutine\");\n break;\n case 57:\n this.$ = $$[$0 - 7];\n yy.addVertex($$[$0 - 7], $$[$0 - 1], \"rect\", void 0, void 0, void 0, Object.fromEntries([[$$[$0 - 5], $$[$0 - 3]]]));\n break;\n case 58:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"cylinder\");\n break;\n case 59:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"round\");\n break;\n case 60:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"diamond\");\n break;\n case 61:\n this.$ = $$[$0 - 5];\n yy.addVertex($$[$0 - 5], $$[$0 - 2], \"hexagon\");\n break;\n case 62:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"odd\");\n break;\n case 63:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"trapezoid\");\n break;\n case 64:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"inv_trapezoid\");\n break;\n case 65:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"lean_right\");\n break;\n case 66:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"lean_left\");\n break;\n case 67:\n this.$ = $$[$0];\n yy.addVertex($$[$0]);\n break;\n case 68:\n $$[$0 - 1].text = $$[$0];\n this.$ = $$[$0 - 1];\n break;\n case 69:\n case 70:\n $$[$0 - 2].text = $$[$0 - 1];\n this.$ = $$[$0 - 2];\n break;\n case 71:\n this.$ = $$[$0];\n break;\n case 72:\n var inf = yy.destructLink($$[$0], $$[$0 - 2]);\n this.$ = { \"type\": inf.type, \"stroke\": inf.stroke, \"length\": inf.length, \"text\": $$[$0 - 1] };\n break;\n case 73:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 74:\n this.$ = { text: $$[$0 - 1].text + \"\" + $$[$0], type: $$[$0 - 1].type };\n break;\n case 75:\n this.$ = { text: $$[$0], type: \"string\" };\n break;\n case 76:\n this.$ = { text: $$[$0], type: \"markdown\" };\n break;\n case 77:\n var inf = yy.destructLink($$[$0]);\n this.$ = { \"type\": inf.type, \"stroke\": inf.stroke, \"length\": inf.length };\n break;\n case 78:\n this.$ = $$[$0 - 1];\n break;\n case 79:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 80:\n this.$ = { text: $$[$0 - 1].text + \"\" + $$[$0], type: $$[$0 - 1].type };\n break;\n case 81:\n this.$ = { text: $$[$0], type: \"string\" };\n break;\n case 82:\n case 97:\n this.$ = { text: $$[$0], type: \"markdown\" };\n break;\n case 94:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 95:\n this.$ = { text: $$[$0 - 1].text + \"\" + $$[$0], type: $$[$0 - 1].type };\n break;\n case 96:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 98:\n this.$ = $$[$0 - 4];\n yy.addClass($$[$0 - 2], $$[$0]);\n break;\n case 99:\n this.$ = $$[$0 - 4];\n yy.setClass($$[$0 - 2], $$[$0]);\n break;\n case 100:\n case 108:\n this.$ = $$[$0 - 1];\n yy.setClickEvent($$[$0 - 1], $$[$0]);\n break;\n case 101:\n case 109:\n this.$ = $$[$0 - 3];\n yy.setClickEvent($$[$0 - 3], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 102:\n this.$ = $$[$0 - 2];\n yy.setClickEvent($$[$0 - 2], $$[$0 - 1], $$[$0]);\n break;\n case 103:\n this.$ = $$[$0 - 4];\n yy.setClickEvent($$[$0 - 4], $$[$0 - 3], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 4], $$[$0]);\n break;\n case 104:\n this.$ = $$[$0 - 2];\n yy.setLink($$[$0 - 2], $$[$0]);\n break;\n case 105:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 4], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 4], $$[$0]);\n break;\n case 106:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 4], $$[$0 - 2], $$[$0]);\n break;\n case 107:\n this.$ = $$[$0 - 6];\n yy.setLink($$[$0 - 6], $$[$0 - 4], $$[$0]);\n yy.setTooltip($$[$0 - 6], $$[$0 - 2]);\n break;\n case 110:\n this.$ = $$[$0 - 1];\n yy.setLink($$[$0 - 1], $$[$0]);\n break;\n case 111:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 3], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 112:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 3], $$[$0 - 2], $$[$0]);\n break;\n case 113:\n this.$ = $$[$0 - 5];\n yy.setLink($$[$0 - 5], $$[$0 - 4], $$[$0]);\n yy.setTooltip($$[$0 - 5], $$[$0 - 2]);\n break;\n case 114:\n this.$ = $$[$0 - 4];\n yy.addVertex($$[$0 - 2], void 0, void 0, $$[$0]);\n break;\n case 115:\n this.$ = $$[$0 - 4];\n yy.updateLink([$$[$0 - 2]], $$[$0]);\n break;\n case 116:\n this.$ = $$[$0 - 4];\n yy.updateLink($$[$0 - 2], $$[$0]);\n break;\n case 117:\n this.$ = $$[$0 - 8];\n yy.updateLinkInterpolate([$$[$0 - 6]], $$[$0 - 2]);\n yy.updateLink([$$[$0 - 6]], $$[$0]);\n break;\n case 118:\n this.$ = $$[$0 - 8];\n yy.updateLinkInterpolate($$[$0 - 6], $$[$0 - 2]);\n yy.updateLink($$[$0 - 6], $$[$0]);\n break;\n case 119:\n this.$ = $$[$0 - 6];\n yy.updateLinkInterpolate([$$[$0 - 4]], $$[$0]);\n break;\n case 120:\n this.$ = $$[$0 - 6];\n yy.updateLinkInterpolate($$[$0 - 4], $$[$0]);\n break;\n case 121:\n case 123:\n this.$ = [$$[$0]];\n break;\n case 122:\n case 124:\n $$[$0 - 2].push($$[$0]);\n this.$ = $$[$0 - 2];\n break;\n case 126:\n this.$ = $$[$0 - 1] + $$[$0];\n break;\n case 174:\n this.$ = $$[$0];\n break;\n case 175:\n this.$ = $$[$0 - 1] + \"\" + $$[$0];\n break;\n case 177:\n this.$ = $$[$0 - 1] + \"\" + $$[$0];\n break;\n case 178:\n this.$ = { stmt: \"dir\", value: \"TB\" };\n break;\n case 179:\n this.$ = { stmt: \"dir\", value: \"BT\" };\n break;\n case 180:\n this.$ = { stmt: \"dir\", value: \"RL\" };\n break;\n case 181:\n this.$ = { stmt: \"dir\", value: \"LR\" };\n break;\n }\n },\n table: [{ 3: 1, 4: 2, 9: $V0, 10: $V1, 12: $V2 }, { 1: [3] }, o($V3, $V4, { 5: 6 }), { 4: 7, 9: $V0, 10: $V1, 12: $V2 }, { 4: 8, 9: $V0, 10: $V1, 12: $V2 }, { 13: [1, 9], 14: [1, 10] }, { 1: [2, 1], 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, o($V3, [2, 9]), o($V3, [2, 10]), o($V3, [2, 11]), { 8: [1, 54], 9: [1, 55], 10: $Vx, 15: 53, 18: 56 }, o($Vy, [2, 3]), o($Vy, [2, 4]), o($Vy, [2, 5]), o($Vy, [2, 6]), o($Vy, [2, 7]), o($Vy, [2, 8]), { 8: $Vz, 9: $VA, 11: $VB, 21: 58, 39: 59, 70: 63, 73: [1, 64], 75: [1, 65] }, { 8: $Vz, 9: $VA, 11: $VB, 21: 66 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 67 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 68 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 69 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 70 }, { 8: $Vz, 9: $VA, 10: [1, 71], 11: $VB, 21: 72 }, o($Vy, [2, 36]), { 35: [1, 73] }, { 37: [1, 74] }, o($Vy, [2, 39]), o($VC, [2, 46], { 18: 75, 10: $Vx }), { 10: [1, 76] }, { 10: [1, 77] }, { 10: [1, 78] }, { 10: [1, 79] }, { 14: $VD, 42: $VE, 58: $VF, 77: [1, 83], 86: $VG, 92: [1, 80], 94: [1, 81], 98: 82, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN, 117: 84 }, o($Vy, [2, 178]), o($Vy, [2, 179]), o($Vy, [2, 180]), o($Vy, [2, 181]), o($VO, [2, 47]), o($VO, [2, 49], { 44: [1, 96] }), o($VP, [2, 67], { 110: 109, 29: [1, 97], 42: $Vd, 46: [1, 98], 48: [1, 99], 50: [1, 100], 52: [1, 101], 54: [1, 102], 56: [1, 103], 58: $Ve, 61: [1, 104], 63: [1, 105], 65: [1, 106], 66: [1, 107], 68: [1, 108], 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 111: $Vq, 112: $Vr, 113: $Vs }), o($VQ, [2, 174]), o($VQ, [2, 135]), o($VQ, [2, 136]), o($VQ, [2, 137]), o($VQ, [2, 138]), o($VQ, [2, 139]), o($VQ, [2, 140]), o($VQ, [2, 141]), o($VQ, [2, 142]), o($VQ, [2, 143]), o($VQ, [2, 144]), o($VQ, [2, 145]), o($V3, [2, 12]), o($V3, [2, 18]), o($V3, [2, 19]), { 9: [1, 110] }, o($VR, [2, 26], { 18: 111, 10: $Vx }), o($Vy, [2, 27]), { 40: 112, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, o($Vy, [2, 40]), o($Vy, [2, 41]), o($Vy, [2, 42]), o($VS, [2, 71], { 71: 113, 60: [1, 115], 72: [1, 114] }), { 74: 116, 76: 117, 77: [1, 118], 78: [1, 119], 113: $VT, 116: $VU }, o([42, 58, 60, 72, 86, 99, 102, 103, 106, 108, 111, 112, 113], [2, 77]), o($Vy, [2, 28]), o($Vy, [2, 29]), o($Vy, [2, 30]), o($Vy, [2, 31]), o($Vy, [2, 32]), { 10: $VV, 12: $VW, 14: $VX, 27: $VY, 28: 122, 32: $VZ, 42: $V_, 58: $V$, 73: $V01, 77: [1, 124], 78: [1, 125], 80: 135, 81: $V11, 82: $V21, 83: $V31, 84: $V41, 85: $V51, 86: $V61, 87: $V71, 88: 123, 102: $V81, 106: $V91, 108: $Va1, 111: $Vb1, 112: $Vc1, 113: $Vd1 }, o($Ve1, $V4, { 5: 148 }), o($Vy, [2, 37]), o($Vy, [2, 38]), o($VC, [2, 45], { 42: $Vf1 }), { 42: $Vd, 45: 150, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 99: [1, 151], 100: 152, 102: [1, 153] }, { 42: $Vd, 45: 154, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 42: $Vd, 45: 155, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, o($Vg1, [2, 100], { 10: [1, 156], 93: [1, 157] }), { 77: [1, 158] }, o($Vg1, [2, 108], { 117: 160, 10: [1, 159], 14: $VD, 42: $VE, 58: $VF, 86: $VG, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN }), o($Vg1, [2, 110], { 10: [1, 161] }), o($Vh1, [2, 176]), o($Vh1, [2, 163]), o($Vh1, [2, 164]), o($Vh1, [2, 165]), o($Vh1, [2, 166]), o($Vh1, [2, 167]), o($Vh1, [2, 168]), o($Vh1, [2, 169]), o($Vh1, [2, 170]), o($Vh1, [2, 171]), o($Vh1, [2, 172]), o($Vh1, [2, 173]), { 42: $Vd, 45: 162, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 30: 163, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 171, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 173, 48: [1, 172], 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 174, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 175, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 176, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 106: [1, 177] }, { 30: 178, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 179, 63: [1, 180], 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 181, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 182, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 183, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VQ, [2, 175]), o($V3, [2, 20]), o($VR, [2, 25]), o($VC, [2, 43], { 18: 184, 10: $Vx }), o($VS, [2, 68], { 10: [1, 185] }), { 10: [1, 186] }, { 30: 187, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 75: [1, 188], 76: 189, 113: $VT, 116: $VU }, o($Vo1, [2, 73]), o($Vo1, [2, 75]), o($Vo1, [2, 76]), o($Vo1, [2, 161]), o($Vo1, [2, 162]), { 8: $Vz, 9: $VA, 10: $VV, 11: $VB, 12: $VW, 14: $VX, 21: 191, 27: $VY, 29: [1, 190], 32: $VZ, 42: $V_, 58: $V$, 73: $V01, 80: 135, 81: $V11, 82: $V21, 83: $V31, 84: $V41, 85: $V51, 86: $V61, 87: $V71, 88: 192, 102: $V81, 106: $V91, 108: $Va1, 111: $Vb1, 112: $Vc1, 113: $Vd1 }, o($Vp1, [2, 94]), o($Vp1, [2, 96]), o($Vp1, [2, 97]), o($Vp1, [2, 150]), o($Vp1, [2, 151]), o($Vp1, [2, 152]), o($Vp1, [2, 153]), o($Vp1, [2, 154]), o($Vp1, [2, 155]), o($Vp1, [2, 156]), o($Vp1, [2, 157]), o($Vp1, [2, 158]), o($Vp1, [2, 159]), o($Vp1, [2, 160]), o($Vp1, [2, 83]), o($Vp1, [2, 84]), o($Vp1, [2, 85]), o($Vp1, [2, 86]), o($Vp1, [2, 87]), o($Vp1, [2, 88]), o($Vp1, [2, 89]), o($Vp1, [2, 90]), o($Vp1, [2, 91]), o($Vp1, [2, 92]), o($Vp1, [2, 93]), { 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 32: [1, 193], 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, { 10: $Vx, 18: 194 }, { 10: [1, 195], 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 109, 111: $Vq, 112: $Vr, 113: $Vs }, { 10: [1, 196] }, { 10: [1, 197], 103: [1, 198] }, o($Vq1, [2, 121]), { 10: [1, 199], 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 109, 111: $Vq, 112: $Vr, 113: $Vs }, { 10: [1, 200], 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 109, 111: $Vq, 112: $Vr, 113: $Vs }, { 77: [1, 201] }, o($Vg1, [2, 102], { 10: [1, 202] }), o($Vg1, [2, 104], { 10: [1, 203] }), { 77: [1, 204] }, o($Vh1, [2, 177]), { 77: [1, 205], 95: [1, 206] }, o($VO, [2, 50], { 110: 109, 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 111: $Vq, 112: $Vr, 113: $Vs }), { 31: [1, 207], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($Vr1, [2, 79]), o($Vr1, [2, 81]), o($Vr1, [2, 82]), o($Vr1, [2, 146]), o($Vr1, [2, 147]), o($Vr1, [2, 148]), o($Vr1, [2, 149]), { 47: [1, 209], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 210, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 49: [1, 211], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 51: [1, 212], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 53: [1, 213], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 55: [1, 214], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 58: [1, 215] }, { 62: [1, 216], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 64: [1, 217], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 218, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 31: [1, 219], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 65: $Vi1, 67: [1, 220], 69: [1, 221], 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 65: $Vi1, 67: [1, 223], 69: [1, 222], 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VC, [2, 44], { 42: $Vf1 }), o($VS, [2, 70]), o($VS, [2, 69]), { 60: [1, 224], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VS, [2, 72]), o($Vo1, [2, 74]), { 30: 225, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($Ve1, $V4, { 5: 226 }), o($Vp1, [2, 95]), o($Vy, [2, 35]), { 41: 227, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 228, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 239, 101: [1, 240], 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 241, 101: [1, 242], 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 102: [1, 243] }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 244, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 42: $Vd, 45: 245, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, o($Vg1, [2, 101]), { 77: [1, 246] }, { 77: [1, 247], 95: [1, 248] }, o($Vg1, [2, 109]), o($Vg1, [2, 111], { 10: [1, 249] }), o($Vg1, [2, 112]), o($VP, [2, 51]), o($Vr1, [2, 80]), o($VP, [2, 52]), { 49: [1, 250], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VP, [2, 59]), o($VP, [2, 54]), o($VP, [2, 55]), o($VP, [2, 56]), { 106: [1, 251] }, o($VP, [2, 58]), o($VP, [2, 60]), { 64: [1, 252], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VP, [2, 62]), o($VP, [2, 63]), o($VP, [2, 65]), o($VP, [2, 64]), o($VP, [2, 66]), o([10, 42, 58, 86, 99, 102, 103, 106, 108, 111, 112, 113], [2, 78]), { 31: [1, 253], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 32: [1, 254], 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, o($VO, [2, 48]), o($Vg1, [2, 114], { 103: $VA1 }), o($VB1, [2, 123], { 105: 256, 10: $Vs1, 58: $Vt1, 81: $Vu1, 102: $Vv1, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }), o($VC1, [2, 125]), o($VC1, [2, 127]), o($VC1, [2, 128]), o($VC1, [2, 129]), o($VC1, [2, 130]), o($VC1, [2, 131]), o($VC1, [2, 132]), o($VC1, [2, 133]), o($VC1, [2, 134]), o($Vg1, [2, 115], { 103: $VA1 }), { 10: [1, 257] }, o($Vg1, [2, 116], { 103: $VA1 }), { 10: [1, 258] }, o($Vq1, [2, 122]), o($Vg1, [2, 98], { 103: $VA1 }), o($Vg1, [2, 99], { 110: 109, 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 111: $Vq, 112: $Vr, 113: $Vs }), o($Vg1, [2, 103]), o($Vg1, [2, 105], { 10: [1, 259] }), o($Vg1, [2, 106]), { 95: [1, 260] }, { 49: [1, 261] }, { 60: [1, 262] }, { 64: [1, 263] }, { 8: $Vz, 9: $VA, 11: $VB, 21: 264 }, o($Vy, [2, 34]), { 10: $Vs1, 58: $Vt1, 81: $Vu1, 102: $Vv1, 104: 265, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, o($VC1, [2, 126]), { 14: $VD, 42: $VE, 58: $VF, 86: $VG, 98: 266, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN, 117: 84 }, { 14: $VD, 42: $VE, 58: $VF, 86: $VG, 98: 267, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN, 117: 84 }, { 95: [1, 268] }, o($Vg1, [2, 113]), o($VP, [2, 53]), { 30: 269, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VP, [2, 61]), o($Ve1, $V4, { 5: 270 }), o($VB1, [2, 124], { 105: 256, 10: $Vs1, 58: $Vt1, 81: $Vu1, 102: $Vv1, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }), o($Vg1, [2, 119], { 117: 160, 10: [1, 271], 14: $VD, 42: $VE, 58: $VF, 86: $VG, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN }), o($Vg1, [2, 120], { 117: 160, 10: [1, 272], 14: $VD, 42: $VE, 58: $VF, 86: $VG, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN }), o($Vg1, [2, 107]), { 31: [1, 273], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 32: [1, 274], 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 275, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 276, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, o($VP, [2, 57]), o($Vy, [2, 33]), o($Vg1, [2, 117], { 103: $VA1 }), o($Vg1, [2, 118], { 103: $VA1 })],\n defaultActions: {},\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex2() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex2();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex2() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: {},\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n this.begin(\"acc_title\");\n return 34;\n case 1:\n this.popState();\n return \"acc_title_value\";\n case 2:\n this.begin(\"acc_descr\");\n return 36;\n case 3:\n this.popState();\n return \"acc_descr_value\";\n case 4:\n this.begin(\"acc_descr_multiline\");\n break;\n case 5:\n this.popState();\n break;\n case 6:\n return \"acc_descr_multiline_value\";\n case 7:\n this.begin(\"callbackname\");\n break;\n case 8:\n this.popState();\n break;\n case 9:\n this.popState();\n this.begin(\"callbackargs\");\n break;\n case 10:\n return 92;\n case 11:\n this.popState();\n break;\n case 12:\n return 93;\n case 13:\n return \"MD_STR\";\n case 14:\n this.popState();\n break;\n case 15:\n this.begin(\"md_string\");\n break;\n case 16:\n return \"STR\";\n case 17:\n this.popState();\n break;\n case 18:\n this.pushState(\"string\");\n break;\n case 19:\n return 81;\n case 20:\n return 99;\n case 21:\n return 82;\n case 22:\n return 101;\n case 23:\n return 83;\n case 24:\n return 84;\n case 25:\n return 94;\n case 26:\n this.begin(\"click\");\n break;\n case 27:\n this.popState();\n break;\n case 28:\n return 85;\n case 29:\n if (yy.lex.firstGraph()) {\n this.begin(\"dir\");\n }\n return 12;\n case 30:\n if (yy.lex.firstGraph()) {\n this.begin(\"dir\");\n }\n return 12;\n case 31:\n if (yy.lex.firstGraph()) {\n this.begin(\"dir\");\n }\n return 12;\n case 32:\n return 27;\n case 33:\n return 32;\n case 34:\n return 95;\n case 35:\n return 95;\n case 36:\n return 95;\n case 37:\n return 95;\n case 38:\n this.popState();\n return 13;\n case 39:\n this.popState();\n return 14;\n case 40:\n this.popState();\n return 14;\n case 41:\n this.popState();\n return 14;\n case 42:\n this.popState();\n return 14;\n case 43:\n this.popState();\n return 14;\n case 44:\n this.popState();\n return 14;\n case 45:\n this.popState();\n return 14;\n case 46:\n this.popState();\n return 14;\n case 47:\n this.popState();\n return 14;\n case 48:\n this.popState();\n return 14;\n case 49:\n return 118;\n case 50:\n return 119;\n case 51:\n return 120;\n case 52:\n return 121;\n case 53:\n return 102;\n case 54:\n return 108;\n case 55:\n return 44;\n case 56:\n return 58;\n case 57:\n return 42;\n case 58:\n return 8;\n case 59:\n return 103;\n case 60:\n return 112;\n case 61:\n this.popState();\n return 75;\n case 62:\n this.pushState(\"edgeText\");\n return 73;\n case 63:\n return 116;\n case 64:\n this.popState();\n return 75;\n case 65:\n this.pushState(\"thickEdgeText\");\n return 73;\n case 66:\n return 116;\n case 67:\n this.popState();\n return 75;\n case 68:\n this.pushState(\"dottedEdgeText\");\n return 73;\n case 69:\n return 116;\n case 70:\n return 75;\n case 71:\n this.popState();\n return 51;\n case 72:\n return \"TEXT\";\n case 73:\n this.pushState(\"ellipseText\");\n return 50;\n case 74:\n this.popState();\n return 53;\n case 75:\n this.pushState(\"text\");\n return 52;\n case 76:\n this.popState();\n return 55;\n case 77:\n this.pushState(\"text\");\n return 54;\n case 78:\n return 56;\n case 79:\n this.pushState(\"text\");\n return 65;\n case 80:\n this.popState();\n return 62;\n case 81:\n this.pushState(\"text\");\n return 61;\n case 82:\n this.popState();\n return 47;\n case 83:\n this.pushState(\"text\");\n return 46;\n case 84:\n this.popState();\n return 67;\n case 85:\n this.popState();\n return 69;\n case 86:\n return 114;\n case 87:\n this.pushState(\"trapText\");\n return 66;\n case 88:\n this.pushState(\"trapText\");\n return 68;\n case 89:\n return 115;\n case 90:\n return 65;\n case 91:\n return 87;\n case 92:\n return \"SEP\";\n case 93:\n return 86;\n case 94:\n return 112;\n case 95:\n return 108;\n case 96:\n return 42;\n case 97:\n return 106;\n case 98:\n return 111;\n case 99:\n return 113;\n case 100:\n this.popState();\n return 60;\n case 101:\n this.pushState(\"text\");\n return 60;\n case 102:\n this.popState();\n return 49;\n case 103:\n this.pushState(\"text\");\n return 48;\n case 104:\n this.popState();\n return 31;\n case 105:\n this.pushState(\"text\");\n return 29;\n case 106:\n this.popState();\n return 64;\n case 107:\n this.pushState(\"text\");\n return 63;\n case 108:\n return \"TEXT\";\n case 109:\n return \"QUOTE\";\n case 110:\n return 9;\n case 111:\n return 10;\n case 112:\n return 11;\n }\n },\n rules: [/^(?:accTitle\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*\\{\\s*)/, /^(?:[\\}])/, /^(?:[^\\}]*)/, /^(?:call[\\s]+)/, /^(?:\\([\\s]*\\))/, /^(?:\\()/, /^(?:[^(]*)/, /^(?:\\))/, /^(?:[^)]*)/, /^(?:[^`\"]+)/, /^(?:[`][\"])/, /^(?:[\"][`])/, /^(?:[^\"]+)/, /^(?:[\"])/, /^(?:[\"])/, /^(?:style\\b)/, /^(?:default\\b)/, /^(?:linkStyle\\b)/, /^(?:interpolate\\b)/, /^(?:classDef\\b)/, /^(?:class\\b)/, /^(?:href[\\s])/, /^(?:click[\\s]+)/, /^(?:[\\s\\n])/, /^(?:[^\\s\\n]*)/, /^(?:flowchart-elk\\b)/, /^(?:graph\\b)/, /^(?:flowchart\\b)/, /^(?:subgraph\\b)/, /^(?:end\\b\\s*)/, /^(?:_self\\b)/, /^(?:_blank\\b)/, /^(?:_parent\\b)/, /^(?:_top\\b)/, /^(?:(\\r?\\n)*\\s*\\n)/, /^(?:\\s*LR\\b)/, /^(?:\\s*RL\\b)/, /^(?:\\s*TB\\b)/, /^(?:\\s*BT\\b)/, /^(?:\\s*TD\\b)/, /^(?:\\s*BR\\b)/, /^(?:\\s*<)/, /^(?:\\s*>)/, /^(?:\\s*\\^)/, /^(?:\\s*v\\b)/, /^(?:.*direction\\s+TB[^\\n]*)/, /^(?:.*direction\\s+BT[^\\n]*)/, /^(?:.*direction\\s+RL[^\\n]*)/, /^(?:.*direction\\s+LR[^\\n]*)/, /^(?:[0-9]+)/, /^(?:#)/, /^(?::::)/, /^(?::)/, /^(?:&)/, /^(?:;)/, /^(?:,)/, /^(?:\\*)/, /^(?:\\s*[xo<]?--+[-xo>]\\s*)/, /^(?:\\s*[xo<]?--\\s*)/, /^(?:[^-]|-(?!-)+)/, /^(?:\\s*[xo<]?==+[=xo>]\\s*)/, /^(?:\\s*[xo<]?==\\s*)/, /^(?:[^=]|=(?!))/, /^(?:\\s*[xo<]?-?\\.+-[xo>]?\\s*)/, /^(?:\\s*[xo<]?-\\.\\s*)/, /^(?:[^\\.]|\\.(?!))/, /^(?:\\s*~~[\\~]+\\s*)/, /^(?:[-/\\)][\\)])/, /^(?:[^\\(\\)\\[\\]\\{\\}]|(?!\\)+))/, /^(?:\\(-)/, /^(?:\\]\\))/, /^(?:\\(\\[)/, /^(?:\\]\\])/, /^(?:\\[\\[)/, /^(?:\\[\\|)/, /^(?:>)/, /^(?:\\)\\])/, /^(?:\\[\\()/, /^(?:\\)\\)\\))/, /^(?:\\(\\(\\()/, /^(?:[\\\\(?=\\])][\\]])/, /^(?:\\/(?=\\])\\])/, /^(?:\\/(?!\\])|\\\\(?!\\])|[^\\\\\\[\\]\\(\\)\\{\\}\\/]+)/, /^(?:\\[\\/)/, /^(?:\\[\\\\)/, /^(?:<)/, /^(?:>)/, /^(?:\\^)/, /^(?:\\\\\\|)/, /^(?:v\\b)/, /^(?:\\*)/, /^(?:#)/, /^(?:&)/, /^(?:([A-Za-z0-9!\"\\#$%&'*+\\.`?\\\\_\\/]|-(?=[^\\>\\-\\.])|(?!))+)/, /^(?:-)/, /^(?:[\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6]|[\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377]|[\\u037A-\\u037D\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5]|[\\u03F7-\\u0481\\u048A-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA]|[\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE]|[\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA]|[\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u08A0]|[\\u08A2-\\u08AC\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0977]|[\\u0979-\\u097F\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2]|[\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A]|[\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39]|[\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8]|[\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C]|[\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C]|[\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99]|[\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0]|[\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C33\\u0C35-\\u0C39\\u0C3D]|[\\u0C58\\u0C59\\u0C60\\u0C61\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3]|[\\u0CB5-\\u0CB9\\u0CBD\\u0CDE\\u0CE0\\u0CE1\\u0CF1\\u0CF2\\u0D05-\\u0D0C\\u0D0E-\\u0D10]|[\\u0D12-\\u0D3A\\u0D3D\\u0D4E\\u0D60\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1]|[\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32\\u0E33\\u0E40-\\u0E46\\u0E81]|[\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3]|[\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6]|[\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A]|[\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081]|[\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D]|[\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0]|[\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310]|[\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C]|[\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u1700-\\u170C\\u170E-\\u1711]|[\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7]|[\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191C]|[\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19C1-\\u19C7\\u1A00-\\u1A16]|[\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF]|[\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1CE9-\\u1CEC]|[\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D]|[\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D]|[\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3]|[\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F]|[\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128]|[\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184]|[\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3]|[\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6]|[\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE]|[\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C]|[\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D]|[\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC]|[\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B]|[\\uA640-\\uA66E\\uA67F-\\uA697\\uA6A0-\\uA6E5\\uA717-\\uA71F\\uA722-\\uA788]|[\\uA78B-\\uA78E\\uA790-\\uA793\\uA7A0-\\uA7AA\\uA7F8-\\uA801\\uA803-\\uA805]|[\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB]|[\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uAA00-\\uAA28]|[\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA80-\\uAAAF\\uAAB1\\uAAB5]|[\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4]|[\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E]|[\\uABC0-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D]|[\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36]|[\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D]|[\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC]|[\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF]|[\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC])/, /^(?:\\|)/, /^(?:\\|)/, /^(?:\\))/, /^(?:\\()/, /^(?:\\])/, /^(?:\\[)/, /^(?:(\\}))/, /^(?:\\{)/, /^(?:[^\\[\\]\\(\\)\\{\\}\\|\\\"]+)/, /^(?:\")/, /^(?:(\\r?\\n)+)/, /^(?:\\s)/, /^(?:$)/],\n conditions: { \"callbackargs\": { \"rules\": [11, 12, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"callbackname\": { \"rules\": [8, 9, 10, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"href\": { \"rules\": [15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"click\": { \"rules\": [15, 18, 27, 28, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"dottedEdgeText\": { \"rules\": [15, 18, 67, 69, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"thickEdgeText\": { \"rules\": [15, 18, 64, 66, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"edgeText\": { \"rules\": [15, 18, 61, 63, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"trapText\": { \"rules\": [15, 18, 70, 73, 75, 77, 81, 83, 84, 85, 86, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"ellipseText\": { \"rules\": [15, 18, 70, 71, 72, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"text\": { \"rules\": [15, 18, 70, 73, 74, 75, 76, 77, 80, 81, 82, 83, 87, 88, 100, 101, 102, 103, 104, 105, 106, 107, 108], \"inclusive\": false }, \"vertex\": { \"rules\": [15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"dir\": { \"rules\": [15, 18, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"acc_descr_multiline\": { \"rules\": [5, 6, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"acc_descr\": { \"rules\": [3, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"acc_title\": { \"rules\": [1, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"md_string\": { \"rules\": [13, 14, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"string\": { \"rules\": [15, 16, 17, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 2, 4, 7, 15, 18, 19, 20, 21, 22, 23, 24, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 64, 65, 67, 68, 70, 73, 75, 77, 78, 79, 81, 83, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 101, 103, 105, 107, 109, 110, 111, 112], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nconst MERMAID_DOM_ID_PREFIX = \"flowchart-\";\nlet vertexCounter = 0;\nlet config = getConfig();\nlet vertices = {};\nlet edges = [];\nlet classes = {};\nlet subGraphs = [];\nlet subGraphLookup = {};\nlet tooltips = {};\nlet subCount = 0;\nlet firstGraphFlag = true;\nlet direction;\nlet version;\nlet funs = [];\nconst sanitizeText = (txt) => common.sanitizeText(txt, config);\nconst lookUpDomId = function(id) {\n const veritceKeys = Object.keys(vertices);\n for (const veritceKey of veritceKeys) {\n if (vertices[veritceKey].id === id) {\n return vertices[veritceKey].domId;\n }\n }\n return id;\n};\nconst addVertex = function(_id, textObj, type, style, classes2, dir, props = {}) {\n let txt;\n let id = _id;\n if (id === void 0) {\n return;\n }\n if (id.trim().length === 0) {\n return;\n }\n if (vertices[id] === void 0) {\n vertices[id] = {\n id,\n labelType: \"text\",\n domId: MERMAID_DOM_ID_PREFIX + id + \"-\" + vertexCounter,\n styles: [],\n classes: []\n };\n }\n vertexCounter++;\n if (textObj !== void 0) {\n config = getConfig();\n txt = sanitizeText(textObj.text.trim());\n vertices[id].labelType = textObj.type;\n if (txt[0] === '\"' && txt[txt.length - 1] === '\"') {\n txt = txt.substring(1, txt.length - 1);\n }\n vertices[id].text = txt;\n } else {\n if (vertices[id].text === void 0) {\n vertices[id].text = _id;\n }\n }\n if (type !== void 0) {\n vertices[id].type = type;\n }\n if (style !== void 0 && style !== null) {\n style.forEach(function(s) {\n vertices[id].styles.push(s);\n });\n }\n if (classes2 !== void 0 && classes2 !== null) {\n classes2.forEach(function(s) {\n vertices[id].classes.push(s);\n });\n }\n if (dir !== void 0) {\n vertices[id].dir = dir;\n }\n if (vertices[id].props === void 0) {\n vertices[id].props = props;\n } else if (props !== void 0) {\n Object.assign(vertices[id].props, props);\n }\n};\nconst addSingleLink = function(_start, _end, type) {\n let start = _start;\n let end = _end;\n const edge = { start, end, type: void 0, text: \"\", labelType: \"text\" };\n log.info(\"abc78 Got edge...\", edge);\n const linkTextObj = type.text;\n if (linkTextObj !== void 0) {\n edge.text = sanitizeText(linkTextObj.text.trim());\n if (edge.text[0] === '\"' && edge.text[edge.text.length - 1] === '\"') {\n edge.text = edge.text.substring(1, edge.text.length - 1);\n }\n edge.labelType = linkTextObj.type;\n }\n if (type !== void 0) {\n edge.type = type.type;\n edge.stroke = type.stroke;\n edge.length = type.length;\n }\n if ((edge == null ? void 0 : edge.length) > 10) {\n edge.length = 10;\n }\n if (edges.length < 280) {\n log.info(\"abc78 pushing edge...\");\n edges.push(edge);\n } else {\n throw new Error(\"Too many edges\");\n }\n};\nconst addLink = function(_start, _end, type) {\n log.info(\"addLink (abc78)\", _start, _end, type);\n let i, j;\n for (i = 0; i < _start.length; i++) {\n for (j = 0; j < _end.length; j++) {\n addSingleLink(_start[i], _end[j], type);\n }\n }\n};\nconst updateLinkInterpolate = function(positions, interp) {\n positions.forEach(function(pos) {\n if (pos === \"default\") {\n edges.defaultInterpolate = interp;\n } else {\n edges[pos].interpolate = interp;\n }\n });\n};\nconst updateLink = function(positions, style) {\n positions.forEach(function(pos) {\n if (pos === \"default\") {\n edges.defaultStyle = style;\n } else {\n if (utils.isSubstringInArray(\"fill\", style) === -1) {\n style.push(\"fill:none\");\n }\n edges[pos].style = style;\n }\n });\n};\nconst addClass = function(ids, style) {\n ids.split(\",\").forEach(function(id) {\n if (classes[id] === void 0) {\n classes[id] = { id, styles: [], textStyles: [] };\n }\n if (style !== void 0 && style !== null) {\n style.forEach(function(s) {\n if (s.match(\"color\")) {\n const newStyle = s.replace(\"fill\", \"bgFill\").replace(\"color\", \"fill\");\n classes[id].textStyles.push(newStyle);\n }\n classes[id].styles.push(s);\n });\n }\n });\n};\nconst setDirection = function(dir) {\n direction = dir;\n if (direction.match(/.*/)) {\n direction = \"LR\";\n }\n if (direction.match(/.*v/)) {\n direction = \"TB\";\n }\n if (direction === \"TD\") {\n direction = \"TB\";\n }\n};\nconst setClass = function(ids, className) {\n ids.split(\",\").forEach(function(_id) {\n let id = _id;\n if (vertices[id] !== void 0) {\n vertices[id].classes.push(className);\n }\n if (subGraphLookup[id] !== void 0) {\n subGraphLookup[id].classes.push(className);\n }\n });\n};\nconst setTooltip = function(ids, tooltip) {\n ids.split(\",\").forEach(function(id) {\n if (tooltip !== void 0) {\n tooltips[version === \"gen-1\" ? lookUpDomId(id) : id] = sanitizeText(tooltip);\n }\n });\n};\nconst setClickFun = function(id, functionName, functionArgs) {\n let domId = lookUpDomId(id);\n if (getConfig().securityLevel !== \"loose\") {\n return;\n }\n if (functionName === void 0) {\n return;\n }\n let argList = [];\n if (typeof functionArgs === \"string\") {\n argList = functionArgs.split(/,(?=(?:(?:[^\"]*\"){2})*[^\"]*$)/);\n for (let i = 0; i < argList.length; i++) {\n let item = argList[i].trim();\n if (item.charAt(0) === '\"' && item.charAt(item.length - 1) === '\"') {\n item = item.substr(1, item.length - 2);\n }\n argList[i] = item;\n }\n }\n if (argList.length === 0) {\n argList.push(id);\n }\n if (vertices[id] !== void 0) {\n vertices[id].haveCallback = true;\n funs.push(function() {\n const elem = document.querySelector(`[id=\"${domId}\"]`);\n if (elem !== null) {\n elem.addEventListener(\n \"click\",\n function() {\n utils.runFunc(functionName, ...argList);\n },\n false\n );\n }\n });\n }\n};\nconst setLink = function(ids, linkStr, target) {\n ids.split(\",\").forEach(function(id) {\n if (vertices[id] !== void 0) {\n vertices[id].link = utils.formatUrl(linkStr, config);\n vertices[id].linkTarget = target;\n }\n });\n setClass(ids, \"clickable\");\n};\nconst getTooltip = function(id) {\n if (tooltips.hasOwnProperty(id)) {\n return tooltips[id];\n }\n return void 0;\n};\nconst setClickEvent = function(ids, functionName, functionArgs) {\n ids.split(\",\").forEach(function(id) {\n setClickFun(id, functionName, functionArgs);\n });\n setClass(ids, \"clickable\");\n};\nconst bindFunctions = function(element) {\n funs.forEach(function(fun) {\n fun(element);\n });\n};\nconst getDirection = function() {\n return direction.trim();\n};\nconst getVertices = function() {\n return vertices;\n};\nconst getEdges = function() {\n return edges;\n};\nconst getClasses = function() {\n return classes;\n};\nconst setupToolTips = function(element) {\n let tooltipElem = select(\".mermaidTooltip\");\n if ((tooltipElem._groups || tooltipElem)[0][0] === null) {\n tooltipElem = select(\"body\").append(\"div\").attr(\"class\", \"mermaidTooltip\").style(\"opacity\", 0);\n }\n const svg = select(element).select(\"svg\");\n const nodes = svg.selectAll(\"g.node\");\n nodes.on(\"mouseover\", function() {\n const el = select(this);\n const title = el.attr(\"title\");\n if (title === null) {\n return;\n }\n const rect = this.getBoundingClientRect();\n tooltipElem.transition().duration(200).style(\"opacity\", \".9\");\n tooltipElem.text(el.attr(\"title\")).style(\"left\", window.scrollX + rect.left + (rect.right - rect.left) / 2 + \"px\").style(\"top\", window.scrollY + rect.top - 14 + document.body.scrollTop + \"px\");\n tooltipElem.html(tooltipElem.html().replace(/<br\\/>/g, \"
      \"));\n el.classed(\"hover\", true);\n }).on(\"mouseout\", function() {\n tooltipElem.transition().duration(500).style(\"opacity\", 0);\n const el = select(this);\n el.classed(\"hover\", false);\n });\n};\nfuns.push(setupToolTips);\nconst clear = function(ver = \"gen-1\") {\n vertices = {};\n classes = {};\n edges = [];\n funs = [setupToolTips];\n subGraphs = [];\n subGraphLookup = {};\n subCount = 0;\n tooltips = {};\n firstGraphFlag = true;\n version = ver;\n clear$1();\n};\nconst setGen = (ver) => {\n version = ver || \"gen-2\";\n};\nconst defaultStyle = function() {\n return \"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;\";\n};\nconst addSubGraph = function(_id, list, _title) {\n let id = _id.text.trim();\n let title = _title.text;\n if (_id === _title && _title.text.match(/\\s/)) {\n id = void 0;\n }\n function uniq(a) {\n const prims = { boolean: {}, number: {}, string: {} };\n const objs = [];\n let dir2;\n const nodeList2 = a.filter(function(item) {\n const type = typeof item;\n if (item.stmt && item.stmt === \"dir\") {\n dir2 = item.value;\n return false;\n }\n if (item.trim() === \"\") {\n return false;\n }\n if (type in prims) {\n return prims[type].hasOwnProperty(item) ? false : prims[type][item] = true;\n } else {\n return objs.includes(item) ? false : objs.push(item);\n }\n });\n return { nodeList: nodeList2, dir: dir2 };\n }\n let nodeList = [];\n const { nodeList: nl, dir } = uniq(nodeList.concat.apply(nodeList, list));\n nodeList = nl;\n if (version === \"gen-1\") {\n for (let i = 0; i < nodeList.length; i++) {\n nodeList[i] = lookUpDomId(nodeList[i]);\n }\n }\n id = id || \"subGraph\" + subCount;\n title = title || \"\";\n title = sanitizeText(title);\n subCount = subCount + 1;\n const subGraph = {\n id,\n nodes: nodeList,\n title: title.trim(),\n classes: [],\n dir,\n labelType: _title.type\n };\n log.info(\"Adding\", subGraph.id, subGraph.nodes, subGraph.dir);\n subGraph.nodes = makeUniq(subGraph, subGraphs).nodes;\n subGraphs.push(subGraph);\n subGraphLookup[id] = subGraph;\n return id;\n};\nconst getPosForId = function(id) {\n for (const [i, subGraph] of subGraphs.entries()) {\n if (subGraph.id === id) {\n return i;\n }\n }\n return -1;\n};\nlet secCount = -1;\nconst posCrossRef = [];\nconst indexNodes2 = function(id, pos) {\n const nodes = subGraphs[pos].nodes;\n secCount = secCount + 1;\n if (secCount > 2e3) {\n return;\n }\n posCrossRef[secCount] = pos;\n if (subGraphs[pos].id === id) {\n return {\n result: true,\n count: 0\n };\n }\n let count = 0;\n let posCount = 1;\n while (count < nodes.length) {\n const childPos = getPosForId(nodes[count]);\n if (childPos >= 0) {\n const res = indexNodes2(id, childPos);\n if (res.result) {\n return {\n result: true,\n count: posCount + res.count\n };\n } else {\n posCount = posCount + res.count;\n }\n }\n count = count + 1;\n }\n return {\n result: false,\n count: posCount\n };\n};\nconst getDepthFirstPos = function(pos) {\n return posCrossRef[pos];\n};\nconst indexNodes = function() {\n secCount = -1;\n if (subGraphs.length > 0) {\n indexNodes2(\"none\", subGraphs.length - 1);\n }\n};\nconst getSubGraphs = function() {\n return subGraphs;\n};\nconst firstGraph = () => {\n if (firstGraphFlag) {\n firstGraphFlag = false;\n return true;\n }\n return false;\n};\nconst destructStartLink = (_str) => {\n let str = _str.trim();\n let type = \"arrow_open\";\n switch (str[0]) {\n case \"<\":\n type = \"arrow_point\";\n str = str.slice(1);\n break;\n case \"x\":\n type = \"arrow_cross\";\n str = str.slice(1);\n break;\n case \"o\":\n type = \"arrow_circle\";\n str = str.slice(1);\n break;\n }\n let stroke = \"normal\";\n if (str.includes(\"=\")) {\n stroke = \"thick\";\n }\n if (str.includes(\".\")) {\n stroke = \"dotted\";\n }\n return { type, stroke };\n};\nconst countChar = (char, str) => {\n const length = str.length;\n let count = 0;\n for (let i = 0; i < length; ++i) {\n if (str[i] === char) {\n ++count;\n }\n }\n return count;\n};\nconst destructEndLink = (_str) => {\n const str = _str.trim();\n let line = str.slice(0, -1);\n let type = \"arrow_open\";\n switch (str.slice(-1)) {\n case \"x\":\n type = \"arrow_cross\";\n if (str[0] === \"x\") {\n type = \"double_\" + type;\n line = line.slice(1);\n }\n break;\n case \">\":\n type = \"arrow_point\";\n if (str[0] === \"<\") {\n type = \"double_\" + type;\n line = line.slice(1);\n }\n break;\n case \"o\":\n type = \"arrow_circle\";\n if (str[0] === \"o\") {\n type = \"double_\" + type;\n line = line.slice(1);\n }\n break;\n }\n let stroke = \"normal\";\n let length = line.length - 1;\n if (line[0] === \"=\") {\n stroke = \"thick\";\n }\n if (line[0] === \"~\") {\n stroke = \"invisible\";\n }\n let dots = countChar(\".\", line);\n if (dots) {\n stroke = \"dotted\";\n length = dots;\n }\n return { type, stroke, length };\n};\nconst destructLink = (_str, _startStr) => {\n const info = destructEndLink(_str);\n let startInfo;\n if (_startStr) {\n startInfo = destructStartLink(_startStr);\n if (startInfo.stroke !== info.stroke) {\n return { type: \"INVALID\", stroke: \"INVALID\" };\n }\n if (startInfo.type === \"arrow_open\") {\n startInfo.type = info.type;\n } else {\n if (startInfo.type !== info.type) {\n return { type: \"INVALID\", stroke: \"INVALID\" };\n }\n startInfo.type = \"double_\" + startInfo.type;\n }\n if (startInfo.type === \"double_arrow\") {\n startInfo.type = \"double_arrow_point\";\n }\n startInfo.length = info.length;\n return startInfo;\n }\n return info;\n};\nconst exists = (allSgs, _id) => {\n let res = false;\n allSgs.forEach((sg) => {\n const pos = sg.nodes.indexOf(_id);\n if (pos >= 0) {\n res = true;\n }\n });\n return res;\n};\nconst makeUniq = (sg, allSubgraphs) => {\n const res = [];\n sg.nodes.forEach((_id, pos) => {\n if (!exists(allSubgraphs, _id)) {\n res.push(sg.nodes[pos]);\n }\n });\n return { nodes: res };\n};\nconst lex = {\n firstGraph\n};\nconst flowDb = {\n defaultConfig: () => defaultConfig.flowchart,\n setAccTitle,\n getAccTitle,\n getAccDescription,\n setAccDescription,\n addVertex,\n lookUpDomId,\n addLink,\n updateLinkInterpolate,\n updateLink,\n addClass,\n setDirection,\n setClass,\n setTooltip,\n getTooltip,\n setClickEvent,\n setLink,\n bindFunctions,\n getDirection,\n getVertices,\n getEdges,\n getClasses,\n clear,\n setGen,\n defaultStyle,\n addSubGraph,\n getDepthFirstPos,\n indexNodes,\n getSubGraphs,\n destructLink,\n lex,\n exists,\n makeUniq,\n setDiagramTitle,\n getDiagramTitle\n};\nconst db = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({\n __proto__: null,\n addClass,\n addLink,\n addSingleLink,\n addSubGraph,\n addVertex,\n bindFunctions,\n clear,\n default: flowDb,\n defaultStyle,\n destructLink,\n firstGraph,\n getClasses,\n getDepthFirstPos,\n getDirection,\n getEdges,\n getSubGraphs,\n getTooltip,\n getVertices,\n indexNodes,\n lex,\n lookUpDomId,\n setClass,\n setClickEvent,\n setDirection,\n setGen,\n setLink,\n updateLink,\n updateLinkInterpolate\n}, Symbol.toStringTag, { value: \"Module\" }));\nexport {\n db as d,\n flowDb as f,\n parser$1 as p\n};\n"], - "mappings": "yJAEA,IAAIA,GAAS,UAAW,CACtB,IAAIC,EAAI,SAASC,GAAGC,EAAGC,EAAIC,EAAG,CAC5B,IAAKD,EAAKA,GAAM,CAAC,EAAGC,EAAIH,GAAE,OAAQG,IAAKD,EAAGF,GAAEG,CAAC,CAAC,EAAIF,EACh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,EAEX,GACT,IAAK,IACH,OAAIA,EAAG,IAAI,WAAW,GACpB,KAAK,MAAM,KAAK,EAEX,GACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,UAAU,EAClB,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,eAAe,EACvB,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,gBAAgB,EACxB,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,MAAO,OACT,IAAK,IACH,YAAK,UAAU,aAAa,EACrB,GACT,IA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ACA,IAAAQ,GACA,OAAAJ,GACA,SAAA3B,GACA,gBAAAsC,GACA,gBAAAC,EACF,EACMC,GAAqB,OAAO,OAAuB,OAAO,eAAe,CAC7E,UAAW,KACX,SAAAxF,GACA,QAAAR,GACA,cAAAN,GACA,YAAAkD,GACA,UAAA3D,GACA,cAAA2C,GACA,MAAAY,GACA,QAASgD,GACT,aAAA7C,GACA,aAAAoC,GACA,WAAAV,GACA,WAAAnC,GACA,iBAAAgC,GACA,aAAAnC,GACA,SAAAE,GACA,aAAAmC,GACA,WAAA1C,GACA,YAAAM,GACA,WAAAmC,GACA,IAAAoB,GACA,YAAA1G,GACA,SAAA+B,GACA,cAAAe,GACA,aAAAhB,GACA,OAAA+B,GACA,QAAAnB,GACA,WAAAjB,GACA,sBAAAJ,EACF,EAAG,OAAO,YAAa,CAAE,MAAO,QAAS,CAAC,CAAC", + "sources": ["../../node_modules/mermaid/dist/flowDb-170db09d.js"], + "sourcesContent": ["import { select } from \"d3\";\nimport { I as defaultConfig, s as setAccTitle, g as getAccTitle, a as getAccDescription, b as setAccDescription, q as setDiagramTitle, r as getDiagramTitle, c as getConfig, l as log, u as utils, t as clear$1, e as common } from \"./mermaid-934d9bea.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 4], $V1 = [1, 3], $V2 = [1, 5], $V3 = [1, 8, 9, 10, 11, 27, 34, 36, 38, 42, 58, 81, 82, 83, 84, 85, 86, 99, 102, 103, 106, 108, 111, 112, 113, 118, 119, 120, 121], $V4 = [2, 2], $V5 = [1, 13], $V6 = [1, 14], $V7 = [1, 15], $V8 = [1, 16], $V9 = [1, 23], $Va = [1, 25], $Vb = [1, 26], $Vc = [1, 27], $Vd = [1, 49], $Ve = [1, 48], $Vf = [1, 29], $Vg = [1, 30], $Vh = [1, 31], $Vi = [1, 32], $Vj = [1, 33], $Vk = [1, 44], $Vl = [1, 46], $Vm = [1, 42], $Vn = [1, 47], $Vo = [1, 43], $Vp = [1, 50], $Vq = [1, 45], $Vr = [1, 51], $Vs = [1, 52], $Vt = [1, 34], $Vu = [1, 35], $Vv = [1, 36], $Vw = [1, 37], $Vx = [1, 57], $Vy = [1, 8, 9, 10, 11, 27, 32, 34, 36, 38, 42, 58, 81, 82, 83, 84, 85, 86, 99, 102, 103, 106, 108, 111, 112, 113, 118, 119, 120, 121], $Vz = [1, 61], $VA = [1, 60], $VB = [1, 62], $VC = [8, 9, 11, 73, 75], $VD = [1, 88], $VE = [1, 93], $VF = [1, 92], $VG = [1, 89], $VH = [1, 85], $VI = [1, 91], $VJ = [1, 87], $VK = [1, 94], $VL = [1, 90], $VM = [1, 95], $VN = [1, 86], $VO = [8, 9, 10, 11, 73, 75], $VP = [8, 9, 10, 11, 44, 73, 75], $VQ = [8, 9, 10, 11, 29, 42, 44, 46, 48, 50, 52, 54, 56, 58, 61, 63, 65, 66, 68, 73, 75, 86, 99, 102, 103, 106, 108, 111, 112, 113], $VR = [8, 9, 11, 42, 58, 73, 75, 86, 99, 102, 103, 106, 108, 111, 112, 113], $VS = [42, 58, 86, 99, 102, 103, 106, 108, 111, 112, 113], $VT = [1, 121], $VU = [1, 120], $VV = [1, 128], $VW = [1, 142], $VX = [1, 143], $VY = [1, 144], $VZ = [1, 145], $V_ = [1, 130], $V$ = [1, 132], $V01 = [1, 136], $V11 = [1, 137], $V21 = [1, 138], $V31 = [1, 139], $V41 = [1, 140], $V51 = [1, 141], $V61 = [1, 146], $V71 = [1, 147], $V81 = [1, 126], $V91 = [1, 127], $Va1 = [1, 134], $Vb1 = [1, 129], $Vc1 = [1, 133], $Vd1 = [1, 131], $Ve1 = [8, 9, 10, 11, 27, 32, 34, 36, 38, 42, 58, 81, 82, 83, 84, 85, 86, 99, 102, 103, 106, 108, 111, 112, 113, 118, 119, 120, 121], $Vf1 = [1, 149], $Vg1 = [8, 9, 11], $Vh1 = [8, 9, 10, 11, 14, 42, 58, 86, 102, 103, 106, 108, 111, 112, 113], $Vi1 = [1, 169], $Vj1 = [1, 165], $Vk1 = [1, 166], $Vl1 = [1, 170], $Vm1 = [1, 167], $Vn1 = [1, 168], $Vo1 = [75, 113, 116], $Vp1 = [8, 9, 10, 11, 12, 14, 27, 29, 32, 42, 58, 73, 81, 82, 83, 84, 85, 86, 87, 102, 106, 108, 111, 112, 113], $Vq1 = [10, 103], $Vr1 = [31, 47, 49, 51, 53, 55, 60, 62, 64, 65, 67, 69, 113, 114, 115], $Vs1 = [1, 235], $Vt1 = [1, 233], $Vu1 = [1, 237], $Vv1 = [1, 231], $Vw1 = [1, 232], $Vx1 = [1, 234], $Vy1 = [1, 236], $Vz1 = [1, 238], $VA1 = [1, 255], $VB1 = [8, 9, 11, 103], $VC1 = [8, 9, 10, 11, 58, 81, 102, 103, 106, 107, 108, 109];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"graphConfig\": 4, \"document\": 5, \"line\": 6, \"statement\": 7, \"SEMI\": 8, \"NEWLINE\": 9, \"SPACE\": 10, \"EOF\": 11, \"GRAPH\": 12, \"NODIR\": 13, \"DIR\": 14, \"FirstStmtSeperator\": 15, \"ending\": 16, \"endToken\": 17, \"spaceList\": 18, \"spaceListNewline\": 19, \"verticeStatement\": 20, \"separator\": 21, \"styleStatement\": 22, \"linkStyleStatement\": 23, \"classDefStatement\": 24, \"classStatement\": 25, \"clickStatement\": 26, \"subgraph\": 27, \"textNoTags\": 28, \"SQS\": 29, \"text\": 30, \"SQE\": 31, \"end\": 32, \"direction\": 33, \"acc_title\": 34, \"acc_title_value\": 35, \"acc_descr\": 36, \"acc_descr_value\": 37, \"acc_descr_multiline_value\": 38, \"link\": 39, \"node\": 40, \"styledVertex\": 41, \"AMP\": 42, \"vertex\": 43, \"STYLE_SEPARATOR\": 44, \"idString\": 45, \"DOUBLECIRCLESTART\": 46, \"DOUBLECIRCLEEND\": 47, \"PS\": 48, \"PE\": 49, \"(-\": 50, \"-)\": 51, \"STADIUMSTART\": 52, \"STADIUMEND\": 53, \"SUBROUTINESTART\": 54, \"SUBROUTINEEND\": 55, \"VERTEX_WITH_PROPS_START\": 56, \"NODE_STRING[field]\": 57, \"COLON\": 58, \"NODE_STRING[value]\": 59, \"PIPE\": 60, \"CYLINDERSTART\": 61, \"CYLINDEREND\": 62, \"DIAMOND_START\": 63, \"DIAMOND_STOP\": 64, \"TAGEND\": 65, \"TRAPSTART\": 66, \"TRAPEND\": 67, \"INVTRAPSTART\": 68, \"INVTRAPEND\": 69, \"linkStatement\": 70, \"arrowText\": 71, \"TESTSTR\": 72, \"START_LINK\": 73, \"edgeText\": 74, \"LINK\": 75, \"edgeTextToken\": 76, \"STR\": 77, \"MD_STR\": 78, \"textToken\": 79, \"keywords\": 80, \"STYLE\": 81, \"LINKSTYLE\": 82, \"CLASSDEF\": 83, \"CLASS\": 84, \"CLICK\": 85, \"DOWN\": 86, \"UP\": 87, \"textNoTagsToken\": 88, \"stylesOpt\": 89, \"idString[vertex]\": 90, \"idString[class]\": 91, \"CALLBACKNAME\": 92, \"CALLBACKARGS\": 93, \"HREF\": 94, \"LINK_TARGET\": 95, \"STR[link]\": 96, \"STR[tooltip]\": 97, \"alphaNum\": 98, \"DEFAULT\": 99, \"numList\": 100, \"INTERPOLATE\": 101, \"NUM\": 102, \"COMMA\": 103, \"style\": 104, \"styleComponent\": 105, \"NODE_STRING\": 106, \"UNIT\": 107, \"BRKT\": 108, \"PCT\": 109, \"idStringToken\": 110, \"MINUS\": 111, \"MULT\": 112, \"UNICODE_TEXT\": 113, \"TEXT\": 114, \"TAGSTART\": 115, \"EDGE_TEXT\": 116, \"alphaNumToken\": 117, \"direction_tb\": 118, \"direction_bt\": 119, \"direction_rl\": 120, \"direction_lr\": 121, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 8: \"SEMI\", 9: \"NEWLINE\", 10: \"SPACE\", 11: \"EOF\", 12: \"GRAPH\", 13: \"NODIR\", 14: \"DIR\", 27: \"subgraph\", 29: \"SQS\", 31: \"SQE\", 32: \"end\", 34: \"acc_title\", 35: \"acc_title_value\", 36: \"acc_descr\", 37: \"acc_descr_value\", 38: \"acc_descr_multiline_value\", 42: \"AMP\", 44: \"STYLE_SEPARATOR\", 46: \"DOUBLECIRCLESTART\", 47: \"DOUBLECIRCLEEND\", 48: \"PS\", 49: \"PE\", 50: \"(-\", 51: \"-)\", 52: \"STADIUMSTART\", 53: \"STADIUMEND\", 54: \"SUBROUTINESTART\", 55: \"SUBROUTINEEND\", 56: \"VERTEX_WITH_PROPS_START\", 57: \"NODE_STRING[field]\", 58: \"COLON\", 59: \"NODE_STRING[value]\", 60: \"PIPE\", 61: \"CYLINDERSTART\", 62: \"CYLINDEREND\", 63: \"DIAMOND_START\", 64: \"DIAMOND_STOP\", 65: \"TAGEND\", 66: \"TRAPSTART\", 67: \"TRAPEND\", 68: \"INVTRAPSTART\", 69: \"INVTRAPEND\", 72: \"TESTSTR\", 73: \"START_LINK\", 75: \"LINK\", 77: \"STR\", 78: \"MD_STR\", 81: \"STYLE\", 82: \"LINKSTYLE\", 83: \"CLASSDEF\", 84: \"CLASS\", 85: \"CLICK\", 86: \"DOWN\", 87: \"UP\", 90: \"idString[vertex]\", 91: \"idString[class]\", 92: \"CALLBACKNAME\", 93: \"CALLBACKARGS\", 94: \"HREF\", 95: \"LINK_TARGET\", 96: \"STR[link]\", 97: \"STR[tooltip]\", 99: \"DEFAULT\", 101: \"INTERPOLATE\", 102: \"NUM\", 103: \"COMMA\", 106: \"NODE_STRING\", 107: \"UNIT\", 108: \"BRKT\", 109: \"PCT\", 111: \"MINUS\", 112: \"MULT\", 113: \"UNICODE_TEXT\", 114: \"TEXT\", 115: \"TAGSTART\", 116: \"EDGE_TEXT\", 118: \"direction_tb\", 119: \"direction_bt\", 120: \"direction_rl\", 121: \"direction_lr\" },\n productions_: [0, [3, 2], [5, 0], [5, 2], [6, 1], [6, 1], [6, 1], [6, 1], [6, 1], [4, 2], [4, 2], [4, 2], [4, 3], [16, 2], [16, 1], [17, 1], [17, 1], [17, 1], [15, 1], [15, 1], [15, 2], [19, 2], [19, 2], [19, 1], [19, 1], [18, 2], [18, 1], [7, 2], [7, 2], [7, 2], [7, 2], [7, 2], [7, 2], [7, 9], [7, 6], [7, 4], [7, 1], [7, 2], [7, 2], [7, 1], [21, 1], [21, 1], [21, 1], [20, 3], [20, 4], [20, 2], [20, 1], [40, 1], [40, 5], [41, 1], [41, 3], [43, 4], [43, 4], [43, 6], [43, 4], [43, 4], [43, 4], [43, 8], [43, 4], [43, 4], [43, 4], [43, 6], [43, 4], [43, 4], [43, 4], [43, 4], [43, 4], [43, 1], [39, 2], [39, 3], [39, 3], [39, 1], [39, 3], [74, 1], [74, 2], [74, 1], [74, 1], [70, 1], [71, 3], [30, 1], [30, 2], [30, 1], [30, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [80, 1], [28, 1], [28, 2], [28, 1], [28, 1], [24, 5], [25, 5], [26, 2], [26, 4], [26, 3], [26, 5], [26, 3], [26, 5], [26, 5], [26, 7], [26, 2], [26, 4], [26, 2], [26, 4], [26, 4], [26, 6], [22, 5], [23, 5], [23, 5], [23, 9], [23, 9], [23, 7], [23, 7], [100, 1], [100, 3], [89, 1], [89, 3], [104, 1], [104, 2], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [105, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [110, 1], [79, 1], [79, 1], [79, 1], [79, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [88, 1], [76, 1], [76, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [117, 1], [45, 1], [45, 2], [98, 1], [98, 2], [33, 1], [33, 1], [33, 1], [33, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 2:\n this.$ = [];\n break;\n case 3:\n if (!Array.isArray($$[$0]) || $$[$0].length > 0) {\n $$[$0 - 1].push($$[$0]);\n }\n this.$ = $$[$0 - 1];\n break;\n case 4:\n case 176:\n this.$ = $$[$0];\n break;\n case 11:\n yy.setDirection(\"TB\");\n this.$ = \"TB\";\n break;\n case 12:\n yy.setDirection($$[$0 - 1]);\n this.$ = $$[$0 - 1];\n break;\n case 27:\n this.$ = $$[$0 - 1].nodes;\n break;\n case 28:\n case 29:\n case 30:\n case 31:\n case 32:\n this.$ = [];\n break;\n case 33:\n this.$ = yy.addSubGraph($$[$0 - 6], $$[$0 - 1], $$[$0 - 4]);\n break;\n case 34:\n this.$ = yy.addSubGraph($$[$0 - 3], $$[$0 - 1], $$[$0 - 3]);\n break;\n case 35:\n this.$ = yy.addSubGraph(void 0, $$[$0 - 1], void 0);\n break;\n case 37:\n this.$ = $$[$0].trim();\n yy.setAccTitle(this.$);\n break;\n case 38:\n case 39:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 43:\n yy.addLink($$[$0 - 2].stmt, $$[$0], $$[$0 - 1]);\n this.$ = { stmt: $$[$0], nodes: $$[$0].concat($$[$0 - 2].nodes) };\n break;\n case 44:\n yy.addLink($$[$0 - 3].stmt, $$[$0 - 1], $$[$0 - 2]);\n this.$ = { stmt: $$[$0 - 1], nodes: $$[$0 - 1].concat($$[$0 - 3].nodes) };\n break;\n case 45:\n this.$ = { stmt: $$[$0 - 1], nodes: $$[$0 - 1] };\n break;\n case 46:\n this.$ = { stmt: $$[$0], nodes: $$[$0] };\n break;\n case 47:\n this.$ = [$$[$0]];\n break;\n case 48:\n this.$ = $$[$0 - 4].concat($$[$0]);\n break;\n case 49:\n this.$ = $$[$0];\n break;\n case 50:\n this.$ = $$[$0 - 2];\n yy.setClass($$[$0 - 2], $$[$0]);\n break;\n case 51:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"square\");\n break;\n case 52:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"doublecircle\");\n break;\n case 53:\n this.$ = $$[$0 - 5];\n yy.addVertex($$[$0 - 5], $$[$0 - 2], \"circle\");\n break;\n case 54:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"ellipse\");\n break;\n case 55:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"stadium\");\n break;\n case 56:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"subroutine\");\n break;\n case 57:\n this.$ = $$[$0 - 7];\n yy.addVertex($$[$0 - 7], $$[$0 - 1], \"rect\", void 0, void 0, void 0, Object.fromEntries([[$$[$0 - 5], $$[$0 - 3]]]));\n break;\n case 58:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"cylinder\");\n break;\n case 59:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"round\");\n break;\n case 60:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"diamond\");\n break;\n case 61:\n this.$ = $$[$0 - 5];\n yy.addVertex($$[$0 - 5], $$[$0 - 2], \"hexagon\");\n break;\n case 62:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"odd\");\n break;\n case 63:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"trapezoid\");\n break;\n case 64:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"inv_trapezoid\");\n break;\n case 65:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"lean_right\");\n break;\n case 66:\n this.$ = $$[$0 - 3];\n yy.addVertex($$[$0 - 3], $$[$0 - 1], \"lean_left\");\n break;\n case 67:\n this.$ = $$[$0];\n yy.addVertex($$[$0]);\n break;\n case 68:\n $$[$0 - 1].text = $$[$0];\n this.$ = $$[$0 - 1];\n break;\n case 69:\n case 70:\n $$[$0 - 2].text = $$[$0 - 1];\n this.$ = $$[$0 - 2];\n break;\n case 71:\n this.$ = $$[$0];\n break;\n case 72:\n var inf = yy.destructLink($$[$0], $$[$0 - 2]);\n this.$ = { \"type\": inf.type, \"stroke\": inf.stroke, \"length\": inf.length, \"text\": $$[$0 - 1] };\n break;\n case 73:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 74:\n this.$ = { text: $$[$0 - 1].text + \"\" + $$[$0], type: $$[$0 - 1].type };\n break;\n case 75:\n this.$ = { text: $$[$0], type: \"string\" };\n break;\n case 76:\n this.$ = { text: $$[$0], type: \"markdown\" };\n break;\n case 77:\n var inf = yy.destructLink($$[$0]);\n this.$ = { \"type\": inf.type, \"stroke\": inf.stroke, \"length\": inf.length };\n break;\n case 78:\n this.$ = $$[$0 - 1];\n break;\n case 79:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 80:\n this.$ = { text: $$[$0 - 1].text + \"\" + $$[$0], type: $$[$0 - 1].type };\n break;\n case 81:\n this.$ = { text: $$[$0], type: \"string\" };\n break;\n case 82:\n case 97:\n this.$ = { text: $$[$0], type: \"markdown\" };\n break;\n case 94:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 95:\n this.$ = { text: $$[$0 - 1].text + \"\" + $$[$0], type: $$[$0 - 1].type };\n break;\n case 96:\n this.$ = { text: $$[$0], type: \"text\" };\n break;\n case 98:\n this.$ = $$[$0 - 4];\n yy.addClass($$[$0 - 2], $$[$0]);\n break;\n case 99:\n this.$ = $$[$0 - 4];\n yy.setClass($$[$0 - 2], $$[$0]);\n break;\n case 100:\n case 108:\n this.$ = $$[$0 - 1];\n yy.setClickEvent($$[$0 - 1], $$[$0]);\n break;\n case 101:\n case 109:\n this.$ = $$[$0 - 3];\n yy.setClickEvent($$[$0 - 3], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 102:\n this.$ = $$[$0 - 2];\n yy.setClickEvent($$[$0 - 2], $$[$0 - 1], $$[$0]);\n break;\n case 103:\n this.$ = $$[$0 - 4];\n yy.setClickEvent($$[$0 - 4], $$[$0 - 3], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 4], $$[$0]);\n break;\n case 104:\n this.$ = $$[$0 - 2];\n yy.setLink($$[$0 - 2], $$[$0]);\n break;\n case 105:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 4], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 4], $$[$0]);\n break;\n case 106:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 4], $$[$0 - 2], $$[$0]);\n break;\n case 107:\n this.$ = $$[$0 - 6];\n yy.setLink($$[$0 - 6], $$[$0 - 4], $$[$0]);\n yy.setTooltip($$[$0 - 6], $$[$0 - 2]);\n break;\n case 110:\n this.$ = $$[$0 - 1];\n yy.setLink($$[$0 - 1], $$[$0]);\n break;\n case 111:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 3], $$[$0 - 2]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 112:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 3], $$[$0 - 2], $$[$0]);\n break;\n case 113:\n this.$ = $$[$0 - 5];\n yy.setLink($$[$0 - 5], $$[$0 - 4], $$[$0]);\n yy.setTooltip($$[$0 - 5], $$[$0 - 2]);\n break;\n case 114:\n this.$ = $$[$0 - 4];\n yy.addVertex($$[$0 - 2], void 0, void 0, $$[$0]);\n break;\n case 115:\n this.$ = $$[$0 - 4];\n yy.updateLink([$$[$0 - 2]], $$[$0]);\n break;\n case 116:\n this.$ = $$[$0 - 4];\n yy.updateLink($$[$0 - 2], $$[$0]);\n break;\n case 117:\n this.$ = $$[$0 - 8];\n yy.updateLinkInterpolate([$$[$0 - 6]], $$[$0 - 2]);\n yy.updateLink([$$[$0 - 6]], $$[$0]);\n break;\n case 118:\n this.$ = $$[$0 - 8];\n yy.updateLinkInterpolate($$[$0 - 6], $$[$0 - 2]);\n yy.updateLink($$[$0 - 6], $$[$0]);\n break;\n case 119:\n this.$ = $$[$0 - 6];\n yy.updateLinkInterpolate([$$[$0 - 4]], $$[$0]);\n break;\n case 120:\n this.$ = $$[$0 - 6];\n yy.updateLinkInterpolate($$[$0 - 4], $$[$0]);\n break;\n case 121:\n case 123:\n this.$ = [$$[$0]];\n break;\n case 122:\n case 124:\n $$[$0 - 2].push($$[$0]);\n this.$ = $$[$0 - 2];\n break;\n case 126:\n this.$ = $$[$0 - 1] + $$[$0];\n break;\n case 174:\n this.$ = $$[$0];\n break;\n case 175:\n this.$ = $$[$0 - 1] + \"\" + $$[$0];\n break;\n case 177:\n this.$ = $$[$0 - 1] + \"\" + $$[$0];\n break;\n case 178:\n this.$ = { stmt: \"dir\", value: \"TB\" };\n break;\n case 179:\n this.$ = { stmt: \"dir\", value: \"BT\" };\n break;\n case 180:\n this.$ = { stmt: \"dir\", value: \"RL\" };\n break;\n case 181:\n this.$ = { stmt: \"dir\", value: \"LR\" };\n break;\n }\n },\n table: [{ 3: 1, 4: 2, 9: $V0, 10: $V1, 12: $V2 }, { 1: [3] }, o($V3, $V4, { 5: 6 }), { 4: 7, 9: $V0, 10: $V1, 12: $V2 }, { 4: 8, 9: $V0, 10: $V1, 12: $V2 }, { 13: [1, 9], 14: [1, 10] }, { 1: [2, 1], 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, o($V3, [2, 9]), o($V3, [2, 10]), o($V3, [2, 11]), { 8: [1, 54], 9: [1, 55], 10: $Vx, 15: 53, 18: 56 }, o($Vy, [2, 3]), o($Vy, [2, 4]), o($Vy, [2, 5]), o($Vy, [2, 6]), o($Vy, [2, 7]), o($Vy, [2, 8]), { 8: $Vz, 9: $VA, 11: $VB, 21: 58, 39: 59, 70: 63, 73: [1, 64], 75: [1, 65] }, { 8: $Vz, 9: $VA, 11: $VB, 21: 66 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 67 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 68 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 69 }, { 8: $Vz, 9: $VA, 11: $VB, 21: 70 }, { 8: $Vz, 9: $VA, 10: [1, 71], 11: $VB, 21: 72 }, o($Vy, [2, 36]), { 35: [1, 73] }, { 37: [1, 74] }, o($Vy, [2, 39]), o($VC, [2, 46], { 18: 75, 10: $Vx }), { 10: [1, 76] }, { 10: [1, 77] }, { 10: [1, 78] }, { 10: [1, 79] }, { 14: $VD, 42: $VE, 58: $VF, 77: [1, 83], 86: $VG, 92: [1, 80], 94: [1, 81], 98: 82, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN, 117: 84 }, o($Vy, [2, 178]), o($Vy, [2, 179]), o($Vy, [2, 180]), o($Vy, [2, 181]), o($VO, [2, 47]), o($VO, [2, 49], { 44: [1, 96] }), o($VP, [2, 67], { 110: 109, 29: [1, 97], 42: $Vd, 46: [1, 98], 48: [1, 99], 50: [1, 100], 52: [1, 101], 54: [1, 102], 56: [1, 103], 58: $Ve, 61: [1, 104], 63: [1, 105], 65: [1, 106], 66: [1, 107], 68: [1, 108], 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 111: $Vq, 112: $Vr, 113: $Vs }), o($VQ, [2, 174]), o($VQ, [2, 135]), o($VQ, [2, 136]), o($VQ, [2, 137]), o($VQ, [2, 138]), o($VQ, [2, 139]), o($VQ, [2, 140]), o($VQ, [2, 141]), o($VQ, [2, 142]), o($VQ, [2, 143]), o($VQ, [2, 144]), o($VQ, [2, 145]), o($V3, [2, 12]), o($V3, [2, 18]), o($V3, [2, 19]), { 9: [1, 110] }, o($VR, [2, 26], { 18: 111, 10: $Vx }), o($Vy, [2, 27]), { 40: 112, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, o($Vy, [2, 40]), o($Vy, [2, 41]), o($Vy, [2, 42]), o($VS, [2, 71], { 71: 113, 60: [1, 115], 72: [1, 114] }), { 74: 116, 76: 117, 77: [1, 118], 78: [1, 119], 113: $VT, 116: $VU }, o([42, 58, 60, 72, 86, 99, 102, 103, 106, 108, 111, 112, 113], [2, 77]), o($Vy, [2, 28]), o($Vy, [2, 29]), o($Vy, [2, 30]), o($Vy, [2, 31]), o($Vy, [2, 32]), { 10: $VV, 12: $VW, 14: $VX, 27: $VY, 28: 122, 32: $VZ, 42: $V_, 58: $V$, 73: $V01, 77: [1, 124], 78: [1, 125], 80: 135, 81: $V11, 82: $V21, 83: $V31, 84: $V41, 85: $V51, 86: $V61, 87: $V71, 88: 123, 102: $V81, 106: $V91, 108: $Va1, 111: $Vb1, 112: $Vc1, 113: $Vd1 }, o($Ve1, $V4, { 5: 148 }), o($Vy, [2, 37]), o($Vy, [2, 38]), o($VC, [2, 45], { 42: $Vf1 }), { 42: $Vd, 45: 150, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 99: [1, 151], 100: 152, 102: [1, 153] }, { 42: $Vd, 45: 154, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 42: $Vd, 45: 155, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, o($Vg1, [2, 100], { 10: [1, 156], 93: [1, 157] }), { 77: [1, 158] }, o($Vg1, [2, 108], { 117: 160, 10: [1, 159], 14: $VD, 42: $VE, 58: $VF, 86: $VG, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN }), o($Vg1, [2, 110], { 10: [1, 161] }), o($Vh1, [2, 176]), o($Vh1, [2, 163]), o($Vh1, [2, 164]), o($Vh1, [2, 165]), o($Vh1, [2, 166]), o($Vh1, [2, 167]), o($Vh1, [2, 168]), o($Vh1, [2, 169]), o($Vh1, [2, 170]), o($Vh1, [2, 171]), o($Vh1, [2, 172]), o($Vh1, [2, 173]), { 42: $Vd, 45: 162, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 30: 163, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 171, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 173, 48: [1, 172], 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 174, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 175, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 176, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 106: [1, 177] }, { 30: 178, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 179, 63: [1, 180], 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 181, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 182, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 183, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VQ, [2, 175]), o($V3, [2, 20]), o($VR, [2, 25]), o($VC, [2, 43], { 18: 184, 10: $Vx }), o($VS, [2, 68], { 10: [1, 185] }), { 10: [1, 186] }, { 30: 187, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 75: [1, 188], 76: 189, 113: $VT, 116: $VU }, o($Vo1, [2, 73]), o($Vo1, [2, 75]), o($Vo1, [2, 76]), o($Vo1, [2, 161]), o($Vo1, [2, 162]), { 8: $Vz, 9: $VA, 10: $VV, 11: $VB, 12: $VW, 14: $VX, 21: 191, 27: $VY, 29: [1, 190], 32: $VZ, 42: $V_, 58: $V$, 73: $V01, 80: 135, 81: $V11, 82: $V21, 83: $V31, 84: $V41, 85: $V51, 86: $V61, 87: $V71, 88: 192, 102: $V81, 106: $V91, 108: $Va1, 111: $Vb1, 112: $Vc1, 113: $Vd1 }, o($Vp1, [2, 94]), o($Vp1, [2, 96]), o($Vp1, [2, 97]), o($Vp1, [2, 150]), o($Vp1, [2, 151]), o($Vp1, [2, 152]), o($Vp1, [2, 153]), o($Vp1, [2, 154]), o($Vp1, [2, 155]), o($Vp1, [2, 156]), o($Vp1, [2, 157]), o($Vp1, [2, 158]), o($Vp1, [2, 159]), o($Vp1, [2, 160]), o($Vp1, [2, 83]), o($Vp1, [2, 84]), o($Vp1, [2, 85]), o($Vp1, [2, 86]), o($Vp1, [2, 87]), o($Vp1, [2, 88]), o($Vp1, [2, 89]), o($Vp1, [2, 90]), o($Vp1, [2, 91]), o($Vp1, [2, 92]), o($Vp1, [2, 93]), { 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 32: [1, 193], 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, { 10: $Vx, 18: 194 }, { 10: [1, 195], 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 109, 111: $Vq, 112: $Vr, 113: $Vs }, { 10: [1, 196] }, { 10: [1, 197], 103: [1, 198] }, o($Vq1, [2, 121]), { 10: [1, 199], 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 109, 111: $Vq, 112: $Vr, 113: $Vs }, { 10: [1, 200], 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 109, 111: $Vq, 112: $Vr, 113: $Vs }, { 77: [1, 201] }, o($Vg1, [2, 102], { 10: [1, 202] }), o($Vg1, [2, 104], { 10: [1, 203] }), { 77: [1, 204] }, o($Vh1, [2, 177]), { 77: [1, 205], 95: [1, 206] }, o($VO, [2, 50], { 110: 109, 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 111: $Vq, 112: $Vr, 113: $Vs }), { 31: [1, 207], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($Vr1, [2, 79]), o($Vr1, [2, 81]), o($Vr1, [2, 82]), o($Vr1, [2, 146]), o($Vr1, [2, 147]), o($Vr1, [2, 148]), o($Vr1, [2, 149]), { 47: [1, 209], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 210, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 49: [1, 211], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 51: [1, 212], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 53: [1, 213], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 55: [1, 214], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 58: [1, 215] }, { 62: [1, 216], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 64: [1, 217], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 30: 218, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 31: [1, 219], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 65: $Vi1, 67: [1, 220], 69: [1, 221], 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 65: $Vi1, 67: [1, 223], 69: [1, 222], 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VC, [2, 44], { 42: $Vf1 }), o($VS, [2, 70]), o($VS, [2, 69]), { 60: [1, 224], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VS, [2, 72]), o($Vo1, [2, 74]), { 30: 225, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($Ve1, $V4, { 5: 226 }), o($Vp1, [2, 95]), o($Vy, [2, 35]), { 41: 227, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 228, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 239, 101: [1, 240], 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 241, 101: [1, 242], 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 102: [1, 243] }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 244, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 42: $Vd, 45: 245, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs }, o($Vg1, [2, 101]), { 77: [1, 246] }, { 77: [1, 247], 95: [1, 248] }, o($Vg1, [2, 109]), o($Vg1, [2, 111], { 10: [1, 249] }), o($Vg1, [2, 112]), o($VP, [2, 51]), o($Vr1, [2, 80]), o($VP, [2, 52]), { 49: [1, 250], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VP, [2, 59]), o($VP, [2, 54]), o($VP, [2, 55]), o($VP, [2, 56]), { 106: [1, 251] }, o($VP, [2, 58]), o($VP, [2, 60]), { 64: [1, 252], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VP, [2, 62]), o($VP, [2, 63]), o($VP, [2, 65]), o($VP, [2, 64]), o($VP, [2, 66]), o([10, 42, 58, 86, 99, 102, 103, 106, 108, 111, 112, 113], [2, 78]), { 31: [1, 253], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 32: [1, 254], 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, o($VO, [2, 48]), o($Vg1, [2, 114], { 103: $VA1 }), o($VB1, [2, 123], { 105: 256, 10: $Vs1, 58: $Vt1, 81: $Vu1, 102: $Vv1, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }), o($VC1, [2, 125]), o($VC1, [2, 127]), o($VC1, [2, 128]), o($VC1, [2, 129]), o($VC1, [2, 130]), o($VC1, [2, 131]), o($VC1, [2, 132]), o($VC1, [2, 133]), o($VC1, [2, 134]), o($Vg1, [2, 115], { 103: $VA1 }), { 10: [1, 257] }, o($Vg1, [2, 116], { 103: $VA1 }), { 10: [1, 258] }, o($Vq1, [2, 122]), o($Vg1, [2, 98], { 103: $VA1 }), o($Vg1, [2, 99], { 110: 109, 42: $Vd, 58: $Ve, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 111: $Vq, 112: $Vr, 113: $Vs }), o($Vg1, [2, 103]), o($Vg1, [2, 105], { 10: [1, 259] }), o($Vg1, [2, 106]), { 95: [1, 260] }, { 49: [1, 261] }, { 60: [1, 262] }, { 64: [1, 263] }, { 8: $Vz, 9: $VA, 11: $VB, 21: 264 }, o($Vy, [2, 34]), { 10: $Vs1, 58: $Vt1, 81: $Vu1, 102: $Vv1, 104: 265, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, o($VC1, [2, 126]), { 14: $VD, 42: $VE, 58: $VF, 86: $VG, 98: 266, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN, 117: 84 }, { 14: $VD, 42: $VE, 58: $VF, 86: $VG, 98: 267, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN, 117: 84 }, { 95: [1, 268] }, o($Vg1, [2, 113]), o($VP, [2, 53]), { 30: 269, 65: $Vi1, 77: $Vj1, 78: $Vk1, 79: 164, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, o($VP, [2, 61]), o($Ve1, $V4, { 5: 270 }), o($VB1, [2, 124], { 105: 256, 10: $Vs1, 58: $Vt1, 81: $Vu1, 102: $Vv1, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }), o($Vg1, [2, 119], { 117: 160, 10: [1, 271], 14: $VD, 42: $VE, 58: $VF, 86: $VG, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN }), o($Vg1, [2, 120], { 117: 160, 10: [1, 272], 14: $VD, 42: $VE, 58: $VF, 86: $VG, 102: $VH, 103: $VI, 106: $VJ, 108: $VK, 111: $VL, 112: $VM, 113: $VN }), o($Vg1, [2, 107]), { 31: [1, 273], 65: $Vi1, 79: 208, 113: $Vl1, 114: $Vm1, 115: $Vn1 }, { 6: 11, 7: 12, 8: $V5, 9: $V6, 10: $V7, 11: $V8, 20: 17, 22: 18, 23: 19, 24: 20, 25: 21, 26: 22, 27: $V9, 32: [1, 274], 33: 24, 34: $Va, 36: $Vb, 38: $Vc, 40: 28, 41: 38, 42: $Vd, 43: 39, 45: 40, 58: $Ve, 81: $Vf, 82: $Vg, 83: $Vh, 84: $Vi, 85: $Vj, 86: $Vk, 99: $Vl, 102: $Vm, 103: $Vn, 106: $Vo, 108: $Vp, 110: 41, 111: $Vq, 112: $Vr, 113: $Vs, 118: $Vt, 119: $Vu, 120: $Vv, 121: $Vw }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 275, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, { 10: $Vs1, 58: $Vt1, 81: $Vu1, 89: 276, 102: $Vv1, 104: 229, 105: 230, 106: $Vw1, 107: $Vx1, 108: $Vy1, 109: $Vz1 }, o($VP, [2, 57]), o($Vy, [2, 33]), o($Vg1, [2, 117], { 103: $VA1 }), o($Vg1, [2, 118], { 103: $VA1 })],\n defaultActions: {},\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex2() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex2();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex2() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: {},\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n this.begin(\"acc_title\");\n return 34;\n case 1:\n this.popState();\n return \"acc_title_value\";\n case 2:\n this.begin(\"acc_descr\");\n return 36;\n case 3:\n this.popState();\n return \"acc_descr_value\";\n case 4:\n this.begin(\"acc_descr_multiline\");\n break;\n case 5:\n this.popState();\n break;\n case 6:\n return \"acc_descr_multiline_value\";\n case 7:\n this.begin(\"callbackname\");\n break;\n case 8:\n this.popState();\n break;\n case 9:\n this.popState();\n this.begin(\"callbackargs\");\n break;\n case 10:\n return 92;\n case 11:\n this.popState();\n break;\n case 12:\n return 93;\n case 13:\n return \"MD_STR\";\n case 14:\n this.popState();\n break;\n case 15:\n this.begin(\"md_string\");\n break;\n case 16:\n return \"STR\";\n case 17:\n this.popState();\n break;\n case 18:\n this.pushState(\"string\");\n break;\n case 19:\n return 81;\n case 20:\n return 99;\n case 21:\n return 82;\n case 22:\n return 101;\n case 23:\n return 83;\n case 24:\n return 84;\n case 25:\n return 94;\n case 26:\n this.begin(\"click\");\n break;\n case 27:\n this.popState();\n break;\n case 28:\n return 85;\n case 29:\n if (yy.lex.firstGraph()) {\n this.begin(\"dir\");\n }\n return 12;\n case 30:\n if (yy.lex.firstGraph()) {\n this.begin(\"dir\");\n }\n return 12;\n case 31:\n if (yy.lex.firstGraph()) {\n this.begin(\"dir\");\n }\n return 12;\n case 32:\n return 27;\n case 33:\n return 32;\n case 34:\n return 95;\n case 35:\n return 95;\n case 36:\n return 95;\n case 37:\n return 95;\n case 38:\n this.popState();\n return 13;\n case 39:\n this.popState();\n return 14;\n case 40:\n this.popState();\n return 14;\n case 41:\n this.popState();\n return 14;\n case 42:\n this.popState();\n return 14;\n case 43:\n this.popState();\n return 14;\n case 44:\n this.popState();\n return 14;\n case 45:\n this.popState();\n return 14;\n case 46:\n this.popState();\n return 14;\n case 47:\n this.popState();\n return 14;\n case 48:\n this.popState();\n return 14;\n case 49:\n return 118;\n case 50:\n return 119;\n case 51:\n return 120;\n case 52:\n return 121;\n case 53:\n return 102;\n case 54:\n return 108;\n case 55:\n return 44;\n case 56:\n return 58;\n case 57:\n return 42;\n case 58:\n return 8;\n case 59:\n return 103;\n case 60:\n return 112;\n case 61:\n this.popState();\n return 75;\n case 62:\n this.pushState(\"edgeText\");\n return 73;\n case 63:\n return 116;\n case 64:\n this.popState();\n return 75;\n case 65:\n this.pushState(\"thickEdgeText\");\n return 73;\n case 66:\n return 116;\n case 67:\n this.popState();\n return 75;\n case 68:\n this.pushState(\"dottedEdgeText\");\n return 73;\n case 69:\n return 116;\n case 70:\n return 75;\n case 71:\n this.popState();\n return 51;\n case 72:\n return \"TEXT\";\n case 73:\n this.pushState(\"ellipseText\");\n return 50;\n case 74:\n this.popState();\n return 53;\n case 75:\n this.pushState(\"text\");\n return 52;\n case 76:\n this.popState();\n return 55;\n case 77:\n this.pushState(\"text\");\n return 54;\n case 78:\n return 56;\n case 79:\n this.pushState(\"text\");\n return 65;\n case 80:\n this.popState();\n return 62;\n case 81:\n this.pushState(\"text\");\n return 61;\n case 82:\n this.popState();\n return 47;\n case 83:\n this.pushState(\"text\");\n return 46;\n case 84:\n this.popState();\n return 67;\n case 85:\n this.popState();\n return 69;\n case 86:\n return 114;\n case 87:\n this.pushState(\"trapText\");\n return 66;\n case 88:\n this.pushState(\"trapText\");\n return 68;\n case 89:\n return 115;\n case 90:\n return 65;\n case 91:\n return 87;\n case 92:\n return \"SEP\";\n case 93:\n return 86;\n case 94:\n return 112;\n case 95:\n return 108;\n case 96:\n return 42;\n case 97:\n return 106;\n case 98:\n return 111;\n case 99:\n return 113;\n case 100:\n this.popState();\n return 60;\n case 101:\n this.pushState(\"text\");\n return 60;\n case 102:\n this.popState();\n return 49;\n case 103:\n this.pushState(\"text\");\n return 48;\n case 104:\n this.popState();\n return 31;\n case 105:\n this.pushState(\"text\");\n return 29;\n case 106:\n this.popState();\n return 64;\n case 107:\n this.pushState(\"text\");\n return 63;\n case 108:\n return \"TEXT\";\n case 109:\n return \"QUOTE\";\n case 110:\n return 9;\n case 111:\n return 10;\n case 112:\n return 11;\n }\n },\n rules: [/^(?:accTitle\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*\\{\\s*)/, /^(?:[\\}])/, /^(?:[^\\}]*)/, /^(?:call[\\s]+)/, /^(?:\\([\\s]*\\))/, /^(?:\\()/, /^(?:[^(]*)/, /^(?:\\))/, /^(?:[^)]*)/, /^(?:[^`\"]+)/, /^(?:[`][\"])/, /^(?:[\"][`])/, /^(?:[^\"]+)/, /^(?:[\"])/, /^(?:[\"])/, /^(?:style\\b)/, /^(?:default\\b)/, /^(?:linkStyle\\b)/, /^(?:interpolate\\b)/, /^(?:classDef\\b)/, /^(?:class\\b)/, /^(?:href[\\s])/, /^(?:click[\\s]+)/, /^(?:[\\s\\n])/, /^(?:[^\\s\\n]*)/, /^(?:flowchart-elk\\b)/, /^(?:graph\\b)/, /^(?:flowchart\\b)/, /^(?:subgraph\\b)/, /^(?:end\\b\\s*)/, /^(?:_self\\b)/, /^(?:_blank\\b)/, /^(?:_parent\\b)/, /^(?:_top\\b)/, /^(?:(\\r?\\n)*\\s*\\n)/, /^(?:\\s*LR\\b)/, /^(?:\\s*RL\\b)/, /^(?:\\s*TB\\b)/, /^(?:\\s*BT\\b)/, /^(?:\\s*TD\\b)/, /^(?:\\s*BR\\b)/, /^(?:\\s*<)/, /^(?:\\s*>)/, /^(?:\\s*\\^)/, /^(?:\\s*v\\b)/, /^(?:.*direction\\s+TB[^\\n]*)/, /^(?:.*direction\\s+BT[^\\n]*)/, /^(?:.*direction\\s+RL[^\\n]*)/, /^(?:.*direction\\s+LR[^\\n]*)/, /^(?:[0-9]+)/, /^(?:#)/, /^(?::::)/, /^(?::)/, /^(?:&)/, /^(?:;)/, /^(?:,)/, /^(?:\\*)/, /^(?:\\s*[xo<]?--+[-xo>]\\s*)/, /^(?:\\s*[xo<]?--\\s*)/, /^(?:[^-]|-(?!-)+)/, /^(?:\\s*[xo<]?==+[=xo>]\\s*)/, /^(?:\\s*[xo<]?==\\s*)/, /^(?:[^=]|=(?!))/, /^(?:\\s*[xo<]?-?\\.+-[xo>]?\\s*)/, /^(?:\\s*[xo<]?-\\.\\s*)/, /^(?:[^\\.]|\\.(?!))/, /^(?:\\s*~~[\\~]+\\s*)/, /^(?:[-/\\)][\\)])/, /^(?:[^\\(\\)\\[\\]\\{\\}]|!\\)+)/, /^(?:\\(-)/, /^(?:\\]\\))/, /^(?:\\(\\[)/, /^(?:\\]\\])/, /^(?:\\[\\[)/, /^(?:\\[\\|)/, /^(?:>)/, /^(?:\\)\\])/, /^(?:\\[\\()/, /^(?:\\)\\)\\))/, /^(?:\\(\\(\\()/, /^(?:[\\\\(?=\\])][\\]])/, /^(?:\\/(?=\\])\\])/, /^(?:\\/(?!\\])|\\\\(?!\\])|[^\\\\\\[\\]\\(\\)\\{\\}\\/]+)/, /^(?:\\[\\/)/, /^(?:\\[\\\\)/, /^(?:<)/, /^(?:>)/, /^(?:\\^)/, /^(?:\\\\\\|)/, /^(?:v\\b)/, /^(?:\\*)/, /^(?:#)/, /^(?:&)/, /^(?:([A-Za-z0-9!\"\\#$%&'*+\\.`?\\\\_\\/]|-(?=[^\\>\\-\\.])|(?!))+)/, /^(?:-)/, /^(?:[\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6]|[\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377]|[\\u037A-\\u037D\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5]|[\\u03F7-\\u0481\\u048A-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA]|[\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE]|[\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA]|[\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u08A0]|[\\u08A2-\\u08AC\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0977]|[\\u0979-\\u097F\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2]|[\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A]|[\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39]|[\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8]|[\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C]|[\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C]|[\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99]|[\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0]|[\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C33\\u0C35-\\u0C39\\u0C3D]|[\\u0C58\\u0C59\\u0C60\\u0C61\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3]|[\\u0CB5-\\u0CB9\\u0CBD\\u0CDE\\u0CE0\\u0CE1\\u0CF1\\u0CF2\\u0D05-\\u0D0C\\u0D0E-\\u0D10]|[\\u0D12-\\u0D3A\\u0D3D\\u0D4E\\u0D60\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1]|[\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32\\u0E33\\u0E40-\\u0E46\\u0E81]|[\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3]|[\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6]|[\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A]|[\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081]|[\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D]|[\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0]|[\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310]|[\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C]|[\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u1700-\\u170C\\u170E-\\u1711]|[\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7]|[\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191C]|[\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19C1-\\u19C7\\u1A00-\\u1A16]|[\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF]|[\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1CE9-\\u1CEC]|[\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D]|[\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D]|[\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3]|[\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F]|[\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128]|[\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184]|[\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3]|[\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6]|[\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE]|[\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C]|[\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D]|[\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC]|[\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B]|[\\uA640-\\uA66E\\uA67F-\\uA697\\uA6A0-\\uA6E5\\uA717-\\uA71F\\uA722-\\uA788]|[\\uA78B-\\uA78E\\uA790-\\uA793\\uA7A0-\\uA7AA\\uA7F8-\\uA801\\uA803-\\uA805]|[\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB]|[\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uAA00-\\uAA28]|[\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA80-\\uAAAF\\uAAB1\\uAAB5]|[\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4]|[\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E]|[\\uABC0-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D]|[\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36]|[\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D]|[\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC]|[\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF]|[\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC])/, /^(?:\\|)/, /^(?:\\|)/, /^(?:\\))/, /^(?:\\()/, /^(?:\\])/, /^(?:\\[)/, /^(?:(\\}))/, /^(?:\\{)/, /^(?:[^\\[\\]\\(\\)\\{\\}\\|\\\"]+)/, /^(?:\")/, /^(?:(\\r?\\n)+)/, /^(?:\\s)/, /^(?:$)/],\n conditions: { \"callbackargs\": { \"rules\": [11, 12, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"callbackname\": { \"rules\": [8, 9, 10, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"href\": { \"rules\": [15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"click\": { \"rules\": [15, 18, 27, 28, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"dottedEdgeText\": { \"rules\": [15, 18, 67, 69, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"thickEdgeText\": { \"rules\": [15, 18, 64, 66, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"edgeText\": { \"rules\": [15, 18, 61, 63, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"trapText\": { \"rules\": [15, 18, 70, 73, 75, 77, 81, 83, 84, 85, 86, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"ellipseText\": { \"rules\": [15, 18, 70, 71, 72, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"text\": { \"rules\": [15, 18, 70, 73, 74, 75, 76, 77, 80, 81, 82, 83, 87, 88, 100, 101, 102, 103, 104, 105, 106, 107, 108], \"inclusive\": false }, \"vertex\": { \"rules\": [15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"dir\": { \"rules\": [15, 18, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"acc_descr_multiline\": { \"rules\": [5, 6, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"acc_descr\": { \"rules\": [3, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"acc_title\": { \"rules\": [1, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"md_string\": { \"rules\": [13, 14, 15, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"string\": { \"rules\": [15, 16, 17, 18, 70, 73, 75, 77, 81, 83, 87, 88, 101, 103, 105, 107], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 2, 4, 7, 15, 18, 19, 20, 21, 22, 23, 24, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 64, 65, 67, 68, 70, 73, 75, 77, 78, 79, 81, 83, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 101, 103, 105, 107, 109, 110, 111, 112], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nconst MERMAID_DOM_ID_PREFIX = \"flowchart-\";\nlet vertexCounter = 0;\nlet config = getConfig();\nlet vertices = {};\nlet edges = [];\nlet classes = {};\nlet subGraphs = [];\nlet subGraphLookup = {};\nlet tooltips = {};\nlet subCount = 0;\nlet firstGraphFlag = true;\nlet direction;\nlet version;\nlet funs = [];\nconst sanitizeText = (txt) => common.sanitizeText(txt, config);\nconst lookUpDomId = function(id) {\n const veritceKeys = Object.keys(vertices);\n for (const veritceKey of veritceKeys) {\n if (vertices[veritceKey].id === id) {\n return vertices[veritceKey].domId;\n }\n }\n return id;\n};\nconst addVertex = function(_id, textObj, type, style, classes2, dir, props = {}) {\n let txt;\n let id = _id;\n if (id === void 0) {\n return;\n }\n if (id.trim().length === 0) {\n return;\n }\n if (vertices[id] === void 0) {\n vertices[id] = {\n id,\n labelType: \"text\",\n domId: MERMAID_DOM_ID_PREFIX + id + \"-\" + vertexCounter,\n styles: [],\n classes: []\n };\n }\n vertexCounter++;\n if (textObj !== void 0) {\n config = getConfig();\n txt = sanitizeText(textObj.text.trim());\n vertices[id].labelType = textObj.type;\n if (txt[0] === '\"' && txt[txt.length - 1] === '\"') {\n txt = txt.substring(1, txt.length - 1);\n }\n vertices[id].text = txt;\n } else {\n if (vertices[id].text === void 0) {\n vertices[id].text = _id;\n }\n }\n if (type !== void 0) {\n vertices[id].type = type;\n }\n if (style !== void 0 && style !== null) {\n style.forEach(function(s) {\n vertices[id].styles.push(s);\n });\n }\n if (classes2 !== void 0 && classes2 !== null) {\n classes2.forEach(function(s) {\n vertices[id].classes.push(s);\n });\n }\n if (dir !== void 0) {\n vertices[id].dir = dir;\n }\n if (vertices[id].props === void 0) {\n vertices[id].props = props;\n } else if (props !== void 0) {\n Object.assign(vertices[id].props, props);\n }\n};\nconst addSingleLink = function(_start, _end, type) {\n let start = _start;\n let end = _end;\n const edge = { start, end, type: void 0, text: \"\", labelType: \"text\" };\n log.info(\"abc78 Got edge...\", edge);\n const linkTextObj = type.text;\n if (linkTextObj !== void 0) {\n edge.text = sanitizeText(linkTextObj.text.trim());\n if (edge.text[0] === '\"' && edge.text[edge.text.length - 1] === '\"') {\n edge.text = edge.text.substring(1, edge.text.length - 1);\n }\n edge.labelType = linkTextObj.type;\n }\n if (type !== void 0) {\n edge.type = type.type;\n edge.stroke = type.stroke;\n edge.length = type.length;\n }\n if ((edge == null ? void 0 : edge.length) > 10) {\n edge.length = 10;\n }\n if (edges.length < 280) {\n log.info(\"abc78 pushing edge...\");\n edges.push(edge);\n } else {\n throw new Error(\"Too many edges\");\n }\n};\nconst addLink = function(_start, _end, type) {\n log.info(\"addLink (abc78)\", _start, _end, type);\n let i, j;\n for (i = 0; i < _start.length; i++) {\n for (j = 0; j < _end.length; j++) {\n addSingleLink(_start[i], _end[j], type);\n }\n }\n};\nconst updateLinkInterpolate = function(positions, interp) {\n positions.forEach(function(pos) {\n if (pos === \"default\") {\n edges.defaultInterpolate = interp;\n } else {\n edges[pos].interpolate = interp;\n }\n });\n};\nconst updateLink = function(positions, style) {\n positions.forEach(function(pos) {\n if (pos === \"default\") {\n edges.defaultStyle = style;\n } else {\n if (utils.isSubstringInArray(\"fill\", style) === -1) {\n style.push(\"fill:none\");\n }\n edges[pos].style = style;\n }\n });\n};\nconst addClass = function(ids, style) {\n ids.split(\",\").forEach(function(id) {\n if (classes[id] === void 0) {\n classes[id] = { id, styles: [], textStyles: [] };\n }\n if (style !== void 0 && style !== null) {\n style.forEach(function(s) {\n if (s.match(\"color\")) {\n const newStyle = s.replace(\"fill\", \"bgFill\").replace(\"color\", \"fill\");\n classes[id].textStyles.push(newStyle);\n }\n classes[id].styles.push(s);\n });\n }\n });\n};\nconst setDirection = function(dir) {\n direction = dir;\n if (direction.match(/.*/)) {\n direction = \"LR\";\n }\n if (direction.match(/.*v/)) {\n direction = \"TB\";\n }\n if (direction === \"TD\") {\n direction = \"TB\";\n }\n};\nconst setClass = function(ids, className) {\n ids.split(\",\").forEach(function(_id) {\n let id = _id;\n if (vertices[id] !== void 0) {\n vertices[id].classes.push(className);\n }\n if (subGraphLookup[id] !== void 0) {\n subGraphLookup[id].classes.push(className);\n }\n });\n};\nconst setTooltip = function(ids, tooltip) {\n ids.split(\",\").forEach(function(id) {\n if (tooltip !== void 0) {\n tooltips[version === \"gen-1\" ? lookUpDomId(id) : id] = sanitizeText(tooltip);\n }\n });\n};\nconst setClickFun = function(id, functionName, functionArgs) {\n let domId = lookUpDomId(id);\n if (getConfig().securityLevel !== \"loose\") {\n return;\n }\n if (functionName === void 0) {\n return;\n }\n let argList = [];\n if (typeof functionArgs === \"string\") {\n argList = functionArgs.split(/,(?=(?:(?:[^\"]*\"){2})*[^\"]*$)/);\n for (let i = 0; i < argList.length; i++) {\n let item = argList[i].trim();\n if (item.charAt(0) === '\"' && item.charAt(item.length - 1) === '\"') {\n item = item.substr(1, item.length - 2);\n }\n argList[i] = item;\n }\n }\n if (argList.length === 0) {\n argList.push(id);\n }\n if (vertices[id] !== void 0) {\n vertices[id].haveCallback = true;\n funs.push(function() {\n const elem = document.querySelector(`[id=\"${domId}\"]`);\n if (elem !== null) {\n elem.addEventListener(\n \"click\",\n function() {\n utils.runFunc(functionName, ...argList);\n },\n false\n );\n }\n });\n }\n};\nconst setLink = function(ids, linkStr, target) {\n ids.split(\",\").forEach(function(id) {\n if (vertices[id] !== void 0) {\n vertices[id].link = utils.formatUrl(linkStr, config);\n vertices[id].linkTarget = target;\n }\n });\n setClass(ids, \"clickable\");\n};\nconst getTooltip = function(id) {\n if (tooltips.hasOwnProperty(id)) {\n return tooltips[id];\n }\n return void 0;\n};\nconst setClickEvent = function(ids, functionName, functionArgs) {\n ids.split(\",\").forEach(function(id) {\n setClickFun(id, functionName, functionArgs);\n });\n setClass(ids, \"clickable\");\n};\nconst bindFunctions = function(element) {\n funs.forEach(function(fun) {\n fun(element);\n });\n};\nconst getDirection = function() {\n return direction.trim();\n};\nconst getVertices = function() {\n return vertices;\n};\nconst getEdges = function() {\n return edges;\n};\nconst getClasses = function() {\n return classes;\n};\nconst setupToolTips = function(element) {\n let tooltipElem = select(\".mermaidTooltip\");\n if ((tooltipElem._groups || tooltipElem)[0][0] === null) {\n tooltipElem = select(\"body\").append(\"div\").attr(\"class\", \"mermaidTooltip\").style(\"opacity\", 0);\n }\n const svg = select(element).select(\"svg\");\n const nodes = svg.selectAll(\"g.node\");\n nodes.on(\"mouseover\", function() {\n const el = select(this);\n const title = el.attr(\"title\");\n if (title === null) {\n return;\n }\n const rect = this.getBoundingClientRect();\n tooltipElem.transition().duration(200).style(\"opacity\", \".9\");\n tooltipElem.text(el.attr(\"title\")).style(\"left\", window.scrollX + rect.left + (rect.right - rect.left) / 2 + \"px\").style(\"top\", window.scrollY + rect.top - 14 + document.body.scrollTop + \"px\");\n tooltipElem.html(tooltipElem.html().replace(/<br\\/>/g, \"
      \"));\n el.classed(\"hover\", true);\n }).on(\"mouseout\", function() {\n tooltipElem.transition().duration(500).style(\"opacity\", 0);\n const el = select(this);\n el.classed(\"hover\", false);\n });\n};\nfuns.push(setupToolTips);\nconst clear = function(ver = \"gen-1\") {\n vertices = {};\n classes = {};\n edges = [];\n funs = [setupToolTips];\n subGraphs = [];\n subGraphLookup = {};\n subCount = 0;\n tooltips = {};\n firstGraphFlag = true;\n version = ver;\n clear$1();\n};\nconst setGen = (ver) => {\n version = ver || \"gen-2\";\n};\nconst defaultStyle = function() {\n return \"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;\";\n};\nconst addSubGraph = function(_id, list, _title) {\n let id = _id.text.trim();\n let title = _title.text;\n if (_id === _title && _title.text.match(/\\s/)) {\n id = void 0;\n }\n function uniq(a) {\n const prims = { boolean: {}, number: {}, string: {} };\n const objs = [];\n let dir2;\n const nodeList2 = a.filter(function(item) {\n const type = typeof item;\n if (item.stmt && item.stmt === \"dir\") {\n dir2 = item.value;\n return false;\n }\n if (item.trim() === \"\") {\n return false;\n }\n if (type in prims) {\n return prims[type].hasOwnProperty(item) ? false : prims[type][item] = true;\n } else {\n return objs.includes(item) ? false : objs.push(item);\n }\n });\n return { nodeList: nodeList2, dir: dir2 };\n }\n let nodeList = [];\n const { nodeList: nl, dir } = uniq(nodeList.concat.apply(nodeList, list));\n nodeList = nl;\n if (version === \"gen-1\") {\n for (let i = 0; i < nodeList.length; i++) {\n nodeList[i] = lookUpDomId(nodeList[i]);\n }\n }\n id = id || \"subGraph\" + subCount;\n title = title || \"\";\n title = sanitizeText(title);\n subCount = subCount + 1;\n const subGraph = {\n id,\n nodes: nodeList,\n title: title.trim(),\n classes: [],\n dir,\n labelType: _title.type\n };\n log.info(\"Adding\", subGraph.id, subGraph.nodes, subGraph.dir);\n subGraph.nodes = makeUniq(subGraph, subGraphs).nodes;\n subGraphs.push(subGraph);\n subGraphLookup[id] = subGraph;\n return id;\n};\nconst getPosForId = function(id) {\n for (const [i, subGraph] of subGraphs.entries()) {\n if (subGraph.id === id) {\n return i;\n }\n }\n return -1;\n};\nlet secCount = -1;\nconst posCrossRef = [];\nconst indexNodes2 = function(id, pos) {\n const nodes = subGraphs[pos].nodes;\n secCount = secCount + 1;\n if (secCount > 2e3) {\n return;\n }\n posCrossRef[secCount] = pos;\n if (subGraphs[pos].id === id) {\n return {\n result: true,\n count: 0\n };\n }\n let count = 0;\n let posCount = 1;\n while (count < nodes.length) {\n const childPos = getPosForId(nodes[count]);\n if (childPos >= 0) {\n const res = indexNodes2(id, childPos);\n if (res.result) {\n return {\n result: true,\n count: posCount + res.count\n };\n } else {\n posCount = posCount + res.count;\n }\n }\n count = count + 1;\n }\n return {\n result: false,\n count: posCount\n };\n};\nconst getDepthFirstPos = function(pos) {\n return posCrossRef[pos];\n};\nconst indexNodes = function() {\n secCount = -1;\n if (subGraphs.length > 0) {\n indexNodes2(\"none\", subGraphs.length - 1);\n }\n};\nconst getSubGraphs = function() {\n return subGraphs;\n};\nconst firstGraph = () => {\n if (firstGraphFlag) {\n firstGraphFlag = false;\n return true;\n }\n return false;\n};\nconst destructStartLink = (_str) => {\n let str = _str.trim();\n let type = \"arrow_open\";\n switch (str[0]) {\n case \"<\":\n type = \"arrow_point\";\n str = str.slice(1);\n break;\n case \"x\":\n type = \"arrow_cross\";\n str = str.slice(1);\n break;\n case \"o\":\n type = \"arrow_circle\";\n str = str.slice(1);\n break;\n }\n let stroke = \"normal\";\n if (str.includes(\"=\")) {\n stroke = \"thick\";\n }\n if (str.includes(\".\")) {\n stroke = \"dotted\";\n }\n return { type, stroke };\n};\nconst countChar = (char, str) => {\n const length = str.length;\n let count = 0;\n for (let i = 0; i < length; ++i) {\n if (str[i] === char) {\n ++count;\n }\n }\n return count;\n};\nconst destructEndLink = (_str) => {\n const str = _str.trim();\n let line = str.slice(0, -1);\n let type = \"arrow_open\";\n switch (str.slice(-1)) {\n case \"x\":\n type = \"arrow_cross\";\n if (str[0] === \"x\") {\n type = \"double_\" + type;\n line = line.slice(1);\n }\n break;\n case \">\":\n type = \"arrow_point\";\n if (str[0] === \"<\") {\n type = \"double_\" + type;\n line = line.slice(1);\n }\n break;\n case \"o\":\n type = \"arrow_circle\";\n if (str[0] === \"o\") {\n type = \"double_\" + type;\n line = line.slice(1);\n }\n break;\n }\n let stroke = \"normal\";\n let length = line.length - 1;\n if (line[0] === \"=\") {\n stroke = \"thick\";\n }\n if (line[0] === \"~\") {\n stroke = \"invisible\";\n }\n let dots = countChar(\".\", line);\n if (dots) {\n stroke = \"dotted\";\n length = dots;\n }\n return { type, stroke, length };\n};\nconst destructLink = (_str, _startStr) => {\n const info = destructEndLink(_str);\n let startInfo;\n if (_startStr) {\n startInfo = destructStartLink(_startStr);\n if (startInfo.stroke !== info.stroke) {\n return { type: \"INVALID\", stroke: \"INVALID\" };\n }\n if (startInfo.type === \"arrow_open\") {\n startInfo.type = info.type;\n } else {\n if (startInfo.type !== info.type) {\n return { type: \"INVALID\", stroke: \"INVALID\" };\n }\n startInfo.type = \"double_\" + startInfo.type;\n }\n if (startInfo.type === \"double_arrow\") {\n startInfo.type = \"double_arrow_point\";\n }\n startInfo.length = info.length;\n return startInfo;\n }\n return info;\n};\nconst exists = (allSgs, _id) => {\n let res = false;\n allSgs.forEach((sg) => {\n const pos = sg.nodes.indexOf(_id);\n if (pos >= 0) {\n res = true;\n }\n });\n return res;\n};\nconst makeUniq = (sg, allSubgraphs) => {\n const res = [];\n sg.nodes.forEach((_id, pos) => {\n if (!exists(allSubgraphs, _id)) {\n res.push(sg.nodes[pos]);\n }\n });\n return { nodes: res };\n};\nconst lex = {\n firstGraph\n};\nconst flowDb = {\n defaultConfig: () => defaultConfig.flowchart,\n setAccTitle,\n getAccTitle,\n getAccDescription,\n setAccDescription,\n addVertex,\n lookUpDomId,\n addLink,\n updateLinkInterpolate,\n updateLink,\n addClass,\n setDirection,\n setClass,\n setTooltip,\n getTooltip,\n setClickEvent,\n setLink,\n bindFunctions,\n getDirection,\n getVertices,\n getEdges,\n getClasses,\n clear,\n setGen,\n defaultStyle,\n addSubGraph,\n getDepthFirstPos,\n indexNodes,\n getSubGraphs,\n destructLink,\n lex,\n exists,\n makeUniq,\n setDiagramTitle,\n getDiagramTitle\n};\nconst db = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({\n __proto__: null,\n addClass,\n addLink,\n addSingleLink,\n addSubGraph,\n addVertex,\n bindFunctions,\n clear,\n default: flowDb,\n defaultStyle,\n destructLink,\n firstGraph,\n getClasses,\n getDepthFirstPos,\n getDirection,\n getEdges,\n getSubGraphs,\n getTooltip,\n getVertices,\n indexNodes,\n lex,\n lookUpDomId,\n setClass,\n setClickEvent,\n setDirection,\n setGen,\n setLink,\n updateLink,\n updateLinkInterpolate\n}, Symbol.toStringTag, { value: \"Module\" }));\nexport {\n db as d,\n flowDb as f,\n parser$1 as p\n};\n"], + "mappings": "yJAEA,IAAIA,GAAS,UAAW,CACtB,IAAIC,EAAI,SAASC,GAAGC,EAAGC,EAAIC,EAAG,CAC5B,IAAKD,EAAKA,GAAM,CAAC,EAAGC,EAAIH,GAAE,OAAQG,IAAKD,EAAGF,GAAEG,CAAC,CAAC,EAAIF,EAChD,CACF,OAAOC,CACT,EAAGE,EAAM,CAAC,EAAG,CAAC,EAAGC,EAAM,CAAC,EAAG,CAAC,EAAGC,EAAM,CAAC,EAAG,CAAC,EAAGC,EAAM,CAAC,EAAG,EAAG,EAAG,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,GAAG,EAAGC,EAAM,CAAC,EAAG,CAAC,EAAGC,EAAM,CAAC,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K,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,UAAU,EAClB,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,eAAe,EACvB,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,gBAAgB,EACxB,GACT,IAAK,IACH,MAAO,KACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,MAAO,OACT,IAAK,IACH,YAAK,UAAU,aAAa,EACrB,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,MAAM,EACd,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,MAAM,EACd,GACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,YAAK,UAAU,MAAM,EACd,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,MAAM,EACd,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,UAAU,MAAM,EACd,GACT,IAAK,IACH,YAAK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A,WAAAmC,GACA,IAAAoB,GACA,YAAA1G,GACA,SAAA+B,GACA,cAAAe,GACA,aAAAhB,GACA,OAAA+B,GACA,QAAAnB,GACA,WAAAjB,GACA,sBAAAJ,EACF,EAAG,OAAO,YAAa,CAAE,MAAO,QAAS,CAAC,CAAC", "names": ["parser", "o", "k", "v", "o2", "l", "$V0", "$V1", "$V2", "$V3", "$V4", "$V5", "$V6", "$V7", "$V8", "$V9", "$Va", "$Vb", "$Vc", "$Vd", "$Ve", "$Vf", "$Vg", "$Vh", "$Vi", "$Vj", "$Vk", "$Vl", "$Vm", "$Vn", "$Vo", "$Vp", "$Vq", "$Vr", "$Vs", "$Vt", "$Vu", "$Vv", "$Vw", "$Vx", "$Vy", "$Vz", "$VA", "$VB", "$VC", "$VD", "$VE", "$VF", "$VG", "$VH", "$VI", "$VJ", "$VK", "$VL", "$VM", "$VN", "$VO", "$VP", "$VQ", "$VR", "$VS", "$VT", "$VU", "$VV", "$VW", "$VX", "$VY", "$VZ", "$V_", "$V$", "$V01", "$V11", "$V21", "$V31", "$V41", "$V51", "$V61", "$V71", "$V81", "$V91", "$Va1", "$Vb1", "$Vc1", "$Vd1", "$Ve1", "$Vf1", "$Vg1", "$Vh1", "$Vi1", "$Vj1", "$Vk1", "$Vl1", "$Vm1", "$Vn1", "$Vo1", "$Vp1", "$Vq1", "$Vr1", "$Vs1", "$Vt1", "$Vu1", "$Vv1", "$Vw1", "$Vx1", "$Vy1", "$Vz1", "$VA1", "$VB1", "$VC1", "parser2", "yytext", "yyleng", "yylineno", "yy", "yystate", "$$", "_$", "$0", "inf", "str", "hash", "error", "input", "self", "stack", "tstack", "vstack", "lstack", "table", "TERROR", "EOF", "args", "lexer2", "sharedState", "yyloc", "ranges", "lex2", "token", "symbol", "state", "action", "r", "yyval", "p", "len", "newState", "expected", "errStr", "lexer", "ch", "lines", "oldLines", "n", "past", "next", "pre", "c", "match", "indexed_rule", "backup", "tempMatch", "index", "rules", "i", "condition", "yy_", "$avoiding_name_collisions", "YY_START", "Parser", "parser$1", "MERMAID_DOM_ID_PREFIX", "vertexCounter", "config", "getConfig", "vertices", "edges", "classes", "subGraphs", "subGraphLookup", "tooltips", "subCount", "firstGraphFlag", "direction", "version", "funs", "sanitizeText", "txt", "common$1", "lookUpDomId", "id", "veritceKeys", "veritceKey", "addVertex", "_id", "textObj", "type", "style", "classes2", "dir", "props", "s", "addSingleLink", "_start", "_end", "edge", "log$1", "linkTextObj", "addLink", "j", "updateLinkInterpolate", "positions", "interp", "pos", "updateLink", "utils", "addClass", "ids", "newStyle", "setDirection", "setClass", "className", "setTooltip", "tooltip", "setClickFun", "functionName", "functionArgs", "domId", "argList", "item", "elem", "setLink", "linkStr", "target", "getTooltip", "setClickEvent", "bindFunctions", "element", "fun", "getDirection", "getVertices", "getEdges", "getClasses", "setupToolTips", "tooltipElem", "select_default", "el", "rect", "clear", "ver", "setGen", "defaultStyle", "addSubGraph", "list", "_title", "title", "uniq", "a", "prims", "objs", "dir2", "nodeList", "nl", "subGraph", "makeUniq", "getPosForId", "secCount", "posCrossRef", "indexNodes2", "nodes", "count", "posCount", "childPos", "res", "getDepthFirstPos", "indexNodes", "getSubGraphs", "firstGraph", "destructStartLink", "_str", "stroke", "countChar", "char", "length", "destructEndLink", "line", "dots", "destructLink", "_startStr", "info", "startInfo", "exists", "allSgs", "sg", "allSubgraphs", "lex", "flowDb", "defaultConfig", "setAccTitle", "getAccTitle", "getAccDescription", "setAccDescription", "setDiagramTitle", "getDiagramTitle", "db"] } diff --git a/docs/public/chunk-F3IAZVFZ.min.js b/docs/public/chunk-NRFNOXYN.min.js similarity index 99% rename from docs/public/chunk-F3IAZVFZ.min.js rename to docs/public/chunk-NRFNOXYN.min.js index cf3fa883..9a8aea8c 100644 --- a/docs/public/chunk-F3IAZVFZ.min.js +++ b/docs/public/chunk-NRFNOXYN.min.js @@ -1,4 +1,4 @@ -import{Ga as we,Ia as Pe,Ka as te,La as S,Za as Be,bb as Ve,cb as Ge,db as Me,eb as Ue,fb as ze,gb as Ye,h as P,hb as Ke,jb as F}from"./chunk-65WDIALL.min.js";var _e=function(){var e=function(L,u,a,o){for(a=a||{},o=L.length;o--;a[L[o]]=u);return a},n=[1,16],r=[1,17],h=[1,18],l=[1,37],A=[1,38],g=[1,24],D=[1,22],B=[1,23],_=[1,29],re=[1,30],ae=[1,31],le=[1,32],ce=[1,33],oe=[1,34],he=[1,25],Ae=[1,26],pe=[1,27],fe=[1,28],d=[1,42],E=[1,39],C=[1,40],m=[1,41],k=[1,43],de=[1,9],c=[1,8,9],Y=[1,54],K=[1,55],j=[1,56],Q=[1,57],X=[1,58],Ee=[1,59],Ce=[1,60],q=[1,8,9,38],Le=[1,71],G=[1,8,9,12,13,21,36,38,41,58,59,60,61,62,63,64,69,71],W=[1,8,9,12,13,19,21,36,38,41,45,58,59,60,61,62,63,64,69,71,84,86,87,88,89],H=[13,84,86,87,88,89],M=[13,63,64,84,86,87,88,89],xe=[13,58,59,60,61,62,84,86,87,88,89],me=[1,90],be=[1,8,9,36,38,41],J=[1,8,9,21],ge={trace:function(){},yy:{},symbols_:{error:2,start:3,mermaidDoc:4,statements:5,graphConfig:6,CLASS_DIAGRAM:7,NEWLINE:8,EOF:9,statement:10,classLabel:11,SQS:12,STR:13,SQE:14,namespaceName:15,alphaNumToken:16,className:17,classLiteralName:18,GENERICTYPE:19,relationStatement:20,LABEL:21,namespaceStatement:22,classStatement:23,memberStatement:24,annotationStatement:25,clickStatement:26,cssClassStatement:27,noteStatement:28,direction:29,acc_title:30,acc_title_value:31,acc_descr:32,acc_descr_value:33,acc_descr_multiline_value:34,namespaceIdentifier:35,STRUCT_START:36,classStatements:37,STRUCT_STOP:38,NAMESPACE:39,classIdentifier:40,STYLE_SEPARATOR:41,members:42,CLASS:43,ANNOTATION_START:44,ANNOTATION_END:45,MEMBER:46,SEPARATOR:47,relation:48,NOTE_FOR:49,noteText:50,NOTE:51,direction_tb:52,direction_bt:53,direction_rl:54,direction_lr:55,relationType:56,lineType:57,AGGREGATION:58,EXTENSION:59,COMPOSITION:60,DEPENDENCY:61,LOLLIPOP:62,LINE:63,DOTTED_LINE:64,CALLBACK:65,LINK:66,LINK_TARGET:67,CLICK:68,CALLBACK_NAME:69,CALLBACK_ARGS:70,HREF:71,CSSCLASS:72,commentToken:73,textToken:74,graphCodeTokens:75,textNoTagsToken:76,TAGSTART:77,TAGEND:78,"==":79,"--":80,PCT:81,DEFAULT:82,SPACE:83,MINUS:84,keywords:85,UNICODE_TEXT:86,NUM:87,ALPHA:88,BQUOTE_STR:89,$accept:0,$end:1},terminals_:{2:"error",7:"CLASS_DIAGRAM",8:"NEWLINE",9:"EOF",12:"SQS",13:"STR",14:"SQE",19:"GENERICTYPE",21:"LABEL",30:"acc_title",31:"acc_title_value",32:"acc_descr",33:"acc_descr_value",34:"acc_descr_multiline_value",36:"STRUCT_START",38:"STRUCT_STOP",39:"NAMESPACE",41:"STYLE_SEPARATOR",43:"CLASS",44:"ANNOTATION_START",45:"ANNOTATION_END",46:"MEMBER",47:"SEPARATOR",49:"NOTE_FOR",51:"NOTE",52:"direction_tb",53:"direction_bt",54:"direction_rl",55:"direction_lr",58:"AGGREGATION",59:"EXTENSION",60:"COMPOSITION",61:"DEPENDENCY",62:"LOLLIPOP",63:"LINE",64:"DOTTED_LINE",65:"CALLBACK",66:"LINK",67:"LINK_TARGET",68:"CLICK",69:"CALLBACK_NAME",70:"CALLBACK_ARGS",71:"HREF",72:"CSSCLASS",75:"graphCodeTokens",77:"TAGSTART",78:"TAGEND",79:"==",80:"--",81:"PCT",82:"DEFAULT",83:"SPACE",84:"MINUS",85:"keywords",86:"UNICODE_TEXT",87:"NUM",88:"ALPHA",89:"BQUOTE_STR"},productions_:[0,[3,1],[3,1],[4,1],[6,4],[5,1],[5,2],[5,3],[11,3],[15,1],[15,2],[17,1],[17,1],[17,2],[17,2],[17,2],[10,1],[10,2],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,2],[10,1],[22,4],[22,5],[35,2],[37,1],[37,2],[37,3],[23,1],[23,3],[23,4],[23,6],[40,2],[40,3],[25,4],[42,1],[42,2],[24,1],[24,2],[24,1],[24,1],[20,3],[20,4],[20,4],[20,5],[28,3],[28,2],[29,1],[29,1],[29,1],[29,1],[48,3],[48,2],[48,2],[48,1],[56,1],[56,1],[56,1],[56,1],[56,1],[57,1],[57,1],[26,3],[26,4],[26,3],[26,4],[26,4],[26,5],[26,3],[26,4],[26,4],[26,5],[26,4],[26,5],[26,5],[26,6],[27,3],[73,1],[73,1],[74,1],[74,1],[74,1],[74,1],[74,1],[74,1],[74,1],[76,1],[76,1],[76,1],[76,1],[16,1],[16,1],[16,1],[16,1],[18,1],[50,1]],performAction:function(u,a,o,i,p,t,U){var s=t.length-1;switch(p){case 8:this.$=t[s-1];break;case 9:case 11:case 12:this.$=t[s];break;case 10:case 13:this.$=t[s-1]+t[s];break;case 14:case 15:this.$=t[s-1]+"~"+t[s]+"~";break;case 16:i.addRelation(t[s]);break;case 17:t[s-1].title=i.cleanupLabel(t[s]),i.addRelation(t[s-1]);break;case 26:this.$=t[s].trim(),i.setAccTitle(this.$);break;case 27:case 28:this.$=t[s].trim(),i.setAccDescription(this.$);break;case 29:i.addClassesToNamespace(t[s-3],t[s-1]);break;case 30:i.addClassesToNamespace(t[s-4],t[s-1]);break;case 31:this.$=t[s],i.addNamespace(t[s]);break;case 32:this.$=[t[s]];break;case 33:this.$=[t[s-1]];break;case 34:t[s].unshift(t[s-2]),this.$=t[s];break;case 36:i.setCssClass(t[s-2],t[s]);break;case 37:i.addMembers(t[s-3],t[s-1]);break;case 38:i.setCssClass(t[s-5],t[s-3]),i.addMembers(t[s-5],t[s-1]);break;case 39:this.$=t[s],i.addClass(t[s]);break;case 40:this.$=t[s-1],i.addClass(t[s-1]),i.setClassLabel(t[s-1],t[s]);break;case 41:i.addAnnotation(t[s],t[s-2]);break;case 42:this.$=[t[s]];break;case 43:t[s].push(t[s-1]),this.$=t[s];break;case 44:break;case 45:i.addMember(t[s-1],i.cleanupLabel(t[s]));break;case 46:break;case 47:break;case 48:this.$={id1:t[s-2],id2:t[s],relation:t[s-1],relationTitle1:"none",relationTitle2:"none"};break;case 49:this.$={id1:t[s-3],id2:t[s],relation:t[s-1],relationTitle1:t[s-2],relationTitle2:"none"};break;case 50:this.$={id1:t[s-3],id2:t[s],relation:t[s-2],relationTitle1:"none",relationTitle2:t[s-1]};break;case 51:this.$={id1:t[s-4],id2:t[s],relation:t[s-2],relationTitle1:t[s-3],relationTitle2:t[s-1]};break;case 52:i.addNote(t[s],t[s-1]);break;case 53:i.addNote(t[s]);break;case 54:i.setDirection("TB");break;case 55:i.setDirection("BT");break;case 56:i.setDirection("RL");break;case 57:i.setDirection("LR");break;case 58:this.$={type1:t[s-2],type2:t[s],lineType:t[s-1]};break;case 59:this.$={type1:"none",type2:t[s],lineType:t[s-1]};break;case 60:this.$={type1:t[s-1],type2:"none",lineType:t[s]};break;case 61:this.$={type1:"none",type2:"none",lineType:t[s]};break;case 62:this.$=i.relationType.AGGREGATION;break;case 63:this.$=i.relationType.EXTENSION;break;case 64:this.$=i.relationType.COMPOSITION;break;case 65:this.$=i.relationType.DEPENDENCY;break;case 66:this.$=i.relationType.LOLLIPOP;break;case 67:this.$=i.lineType.LINE;break;case 68:this.$=i.lineType.DOTTED_LINE;break;case 69:case 75:this.$=t[s-2],i.setClickEvent(t[s-1],t[s]);break;case 70:case 76:this.$=t[s-3],i.setClickEvent(t[s-2],t[s-1]),i.setTooltip(t[s-2],t[s]);break;case 71:this.$=t[s-2],i.setLink(t[s-1],t[s]);break;case 72:this.$=t[s-3],i.setLink(t[s-2],t[s-1],t[s]);break;case 73:this.$=t[s-3],i.setLink(t[s-2],t[s-1]),i.setTooltip(t[s-2],t[s]);break;case 74:this.$=t[s-4],i.setLink(t[s-3],t[s-2],t[s]),i.setTooltip(t[s-3],t[s-1]);break;case 77:this.$=t[s-3],i.setClickEvent(t[s-2],t[s-1],t[s]);break;case 78:this.$=t[s-4],i.setClickEvent(t[s-3],t[s-2],t[s-1]),i.setTooltip(t[s-3],t[s]);break;case 79:this.$=t[s-3],i.setLink(t[s-2],t[s]);break;case 80:this.$=t[s-4],i.setLink(t[s-3],t[s-1],t[s]);break;case 81:this.$=t[s-4],i.setLink(t[s-3],t[s-1]),i.setTooltip(t[s-3],t[s]);break;case 82:this.$=t[s-5],i.setLink(t[s-4],t[s-2],t[s]),i.setTooltip(t[s-4],t[s-1]);break;case 83:i.setCssClass(t[s-1],t[s]);break}},table:[{3:1,4:2,5:3,6:4,7:[1,6],10:5,16:35,17:19,18:36,20:7,22:8,23:9,24:10,25:11,26:12,27:13,28:14,29:15,30:n,32:r,34:h,35:20,39:l,40:21,43:A,44:g,46:D,47:B,49:_,51:re,52:ae,53:le,54:ce,55:oe,65:he,66:Ae,68:pe,72:fe,84:d,86:E,87:C,88:m,89:k},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},e(de,[2,5],{8:[1,44]}),{8:[1,45]},e(c,[2,16],{21:[1,46]}),e(c,[2,18]),e(c,[2,19]),e(c,[2,20]),e(c,[2,21]),e(c,[2,22]),e(c,[2,23]),e(c,[2,24]),e(c,[2,25]),{31:[1,47]},{33:[1,48]},e(c,[2,28]),e(c,[2,44],{48:49,56:52,57:53,13:[1,50],21:[1,51],58:Y,59:K,60:j,61:Q,62:X,63:Ee,64:Ce}),{36:[1,61]},e(q,[2,35],{36:[1,63],41:[1,62]}),e(c,[2,46]),e(c,[2,47]),{16:64,84:d,86:E,87:C,88:m},{16:35,17:65,18:36,84:d,86:E,87:C,88:m,89:k},{16:35,17:66,18:36,84:d,86:E,87:C,88:m,89:k},{16:35,17:67,18:36,84:d,86:E,87:C,88:m,89:k},{13:[1,68]},{16:35,17:69,18:36,84:d,86:E,87:C,88:m,89:k},{13:Le,50:70},e(c,[2,54]),e(c,[2,55]),e(c,[2,56]),e(c,[2,57]),e(G,[2,11],{16:35,18:36,17:72,19:[1,73],84:d,86:E,87:C,88:m,89:k}),e(G,[2,12],{19:[1,74]}),{15:75,16:76,84:d,86:E,87:C,88:m},{16:35,17:77,18:36,84:d,86:E,87:C,88:m,89:k},e(W,[2,97]),e(W,[2,98]),e(W,[2,99]),e(W,[2,100]),e([1,8,9,12,13,19,21,36,38,41,58,59,60,61,62,63,64,69,71],[2,101]),e(de,[2,6],{10:5,20:7,22:8,23:9,24:10,25:11,26:12,27:13,28:14,29:15,17:19,35:20,40:21,16:35,18:36,5:78,30:n,32:r,34:h,39:l,43:A,44:g,46:D,47:B,49:_,51:re,52:ae,53:le,54:ce,55:oe,65:he,66:Ae,68:pe,72:fe,84:d,86:E,87:C,88:m,89:k}),{5:79,10:5,16:35,17:19,18:36,20:7,22:8,23:9,24:10,25:11,26:12,27:13,28:14,29:15,30:n,32:r,34:h,35:20,39:l,40:21,43:A,44:g,46:D,47:B,49:_,51:re,52:ae,53:le,54:ce,55:oe,65:he,66:Ae,68:pe,72:fe,84:d,86:E,87:C,88:m,89:k},e(c,[2,17]),e(c,[2,26]),e(c,[2,27]),{13:[1,81],16:35,17:80,18:36,84:d,86:E,87:C,88:m,89:k},{48:82,56:52,57:53,58:Y,59:K,60:j,61:Q,62:X,63:Ee,64:Ce},e(c,[2,45]),{57:83,63:Ee,64:Ce},e(H,[2,61],{56:84,58:Y,59:K,60:j,61:Q,62:X}),e(M,[2,62]),e(M,[2,63]),e(M,[2,64]),e(M,[2,65]),e(M,[2,66]),e(xe,[2,67]),e(xe,[2,68]),{8:[1,86],23:87,37:85,40:21,43:A},{16:88,84:d,86:E,87:C,88:m},{42:89,46:me},{45:[1,91]},{13:[1,92]},{13:[1,93]},{69:[1,94],71:[1,95]},{16:96,84:d,86:E,87:C,88:m},{13:Le,50:97},e(c,[2,53]),e(c,[2,102]),e(G,[2,13]),e(G,[2,14]),e(G,[2,15]),{36:[2,31]},{15:98,16:76,36:[2,9],84:d,86:E,87:C,88:m},e(be,[2,39],{11:99,12:[1,100]}),e(de,[2,7]),{9:[1,101]},e(J,[2,48]),{16:35,17:102,18:36,84:d,86:E,87:C,88:m,89:k},{13:[1,104],16:35,17:103,18:36,84:d,86:E,87:C,88:m,89:k},e(H,[2,60],{56:105,58:Y,59:K,60:j,61:Q,62:X}),e(H,[2,59]),{38:[1,106]},{23:87,37:107,40:21,43:A},{8:[1,108],38:[2,32]},e(q,[2,36],{36:[1,109]}),{38:[1,110]},{38:[2,42],42:111,46:me},{16:35,17:112,18:36,84:d,86:E,87:C,88:m,89:k},e(c,[2,69],{13:[1,113]}),e(c,[2,71],{13:[1,115],67:[1,114]}),e(c,[2,75],{13:[1,116],70:[1,117]}),{13:[1,118]},e(c,[2,83]),e(c,[2,52]),{36:[2,10]},e(be,[2,40]),{13:[1,119]},{1:[2,4]},e(J,[2,50]),e(J,[2,49]),{16:35,17:120,18:36,84:d,86:E,87:C,88:m,89:k},e(H,[2,58]),e(c,[2,29]),{38:[1,121]},{23:87,37:122,38:[2,33],40:21,43:A},{42:123,46:me},e(q,[2,37]),{38:[2,43]},e(c,[2,41]),e(c,[2,70]),e(c,[2,72]),e(c,[2,73],{67:[1,124]}),e(c,[2,76]),e(c,[2,77],{13:[1,125]}),e(c,[2,79],{13:[1,127],67:[1,126]}),{14:[1,128]},e(J,[2,51]),e(c,[2,30]),{38:[2,34]},{38:[1,129]},e(c,[2,74]),e(c,[2,78]),e(c,[2,80]),e(c,[2,81],{67:[1,130]}),e(be,[2,8]),e(q,[2,38]),e(c,[2,82])],defaultActions:{2:[2,1],3:[2,2],4:[2,3],75:[2,31],98:[2,10],101:[2,4],111:[2,43],122:[2,34]},parseError:function(u,a){if(a.recoverable)this.trace(u);else{var o=new Error(u);throw o.hash=a,o}},parse:function(u){var a=this,o=[0],i=[],p=[null],t=[],U=this.table,s="",Z=0,Ie=0,Ze=2,Oe=1,$e=t.slice.call(arguments,1),b=Object.create(this.lexer),I={yy:{}};for(var Te in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Te)&&(I.yy[Te]=this.yy[Te]);b.setInput(u,I.yy),I.yy.lexer=b,I.yy.parser=this,typeof b.yylloc>"u"&&(b.yylloc={});var Fe=b.yylloc;t.push(Fe);var et=b.options&&b.options.ranges;typeof I.yy.parseError=="function"?this.parseError=I.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function tt(){var v;return v=i.pop()||b.lex()||Oe,typeof v!="number"&&(v instanceof Array&&(i=v,v=i.pop()),v=a.symbols_[v]||v),v}for(var T,O,y,ye,w={},$,N,Re,ee;;){if(O=o[o.length-1],this.defaultActions[O]?y=this.defaultActions[O]:((T===null||typeof T>"u")&&(T=tt()),y=U[O]&&U[O][T]),typeof y>"u"||!y.length||!y[0]){var De="";ee=[];for($ in U[O])this.terminals_[$]&&$>Ze&&ee.push("'"+this.terminals_[$]+"'");b.showPosition?De="Parse error on line "+(Z+1)+`: +import{Ga as we,Ia as Pe,Ka as te,La as S,Za as Be,bb as Ve,cb as Ge,db as Me,eb as Ue,fb as ze,gb as Ye,h as P,hb as Ke,jb as F}from"./chunk-JUXSCBYR.min.js";var _e=function(){var e=function(L,u,a,o){for(a=a||{},o=L.length;o--;a[L[o]]=u);return a},n=[1,16],r=[1,17],h=[1,18],l=[1,37],A=[1,38],g=[1,24],D=[1,22],B=[1,23],_=[1,29],re=[1,30],ae=[1,31],le=[1,32],ce=[1,33],oe=[1,34],he=[1,25],Ae=[1,26],pe=[1,27],fe=[1,28],d=[1,42],E=[1,39],C=[1,40],m=[1,41],k=[1,43],de=[1,9],c=[1,8,9],Y=[1,54],K=[1,55],j=[1,56],Q=[1,57],X=[1,58],Ee=[1,59],Ce=[1,60],q=[1,8,9,38],Le=[1,71],G=[1,8,9,12,13,21,36,38,41,58,59,60,61,62,63,64,69,71],W=[1,8,9,12,13,19,21,36,38,41,45,58,59,60,61,62,63,64,69,71,84,86,87,88,89],H=[13,84,86,87,88,89],M=[13,63,64,84,86,87,88,89],xe=[13,58,59,60,61,62,84,86,87,88,89],me=[1,90],be=[1,8,9,36,38,41],J=[1,8,9,21],ge={trace:function(){},yy:{},symbols_:{error:2,start:3,mermaidDoc:4,statements:5,graphConfig:6,CLASS_DIAGRAM:7,NEWLINE:8,EOF:9,statement:10,classLabel:11,SQS:12,STR:13,SQE:14,namespaceName:15,alphaNumToken:16,className:17,classLiteralName:18,GENERICTYPE:19,relationStatement:20,LABEL:21,namespaceStatement:22,classStatement:23,memberStatement:24,annotationStatement:25,clickStatement:26,cssClassStatement:27,noteStatement:28,direction:29,acc_title:30,acc_title_value:31,acc_descr:32,acc_descr_value:33,acc_descr_multiline_value:34,namespaceIdentifier:35,STRUCT_START:36,classStatements:37,STRUCT_STOP:38,NAMESPACE:39,classIdentifier:40,STYLE_SEPARATOR:41,members:42,CLASS:43,ANNOTATION_START:44,ANNOTATION_END:45,MEMBER:46,SEPARATOR:47,relation:48,NOTE_FOR:49,noteText:50,NOTE:51,direction_tb:52,direction_bt:53,direction_rl:54,direction_lr:55,relationType:56,lineType:57,AGGREGATION:58,EXTENSION:59,COMPOSITION:60,DEPENDENCY:61,LOLLIPOP:62,LINE:63,DOTTED_LINE:64,CALLBACK:65,LINK:66,LINK_TARGET:67,CLICK:68,CALLBACK_NAME:69,CALLBACK_ARGS:70,HREF:71,CSSCLASS:72,commentToken:73,textToken:74,graphCodeTokens:75,textNoTagsToken:76,TAGSTART:77,TAGEND:78,"==":79,"--":80,PCT:81,DEFAULT:82,SPACE:83,MINUS:84,keywords:85,UNICODE_TEXT:86,NUM:87,ALPHA:88,BQUOTE_STR:89,$accept:0,$end:1},terminals_:{2:"error",7:"CLASS_DIAGRAM",8:"NEWLINE",9:"EOF",12:"SQS",13:"STR",14:"SQE",19:"GENERICTYPE",21:"LABEL",30:"acc_title",31:"acc_title_value",32:"acc_descr",33:"acc_descr_value",34:"acc_descr_multiline_value",36:"STRUCT_START",38:"STRUCT_STOP",39:"NAMESPACE",41:"STYLE_SEPARATOR",43:"CLASS",44:"ANNOTATION_START",45:"ANNOTATION_END",46:"MEMBER",47:"SEPARATOR",49:"NOTE_FOR",51:"NOTE",52:"direction_tb",53:"direction_bt",54:"direction_rl",55:"direction_lr",58:"AGGREGATION",59:"EXTENSION",60:"COMPOSITION",61:"DEPENDENCY",62:"LOLLIPOP",63:"LINE",64:"DOTTED_LINE",65:"CALLBACK",66:"LINK",67:"LINK_TARGET",68:"CLICK",69:"CALLBACK_NAME",70:"CALLBACK_ARGS",71:"HREF",72:"CSSCLASS",75:"graphCodeTokens",77:"TAGSTART",78:"TAGEND",79:"==",80:"--",81:"PCT",82:"DEFAULT",83:"SPACE",84:"MINUS",85:"keywords",86:"UNICODE_TEXT",87:"NUM",88:"ALPHA",89:"BQUOTE_STR"},productions_:[0,[3,1],[3,1],[4,1],[6,4],[5,1],[5,2],[5,3],[11,3],[15,1],[15,2],[17,1],[17,1],[17,2],[17,2],[17,2],[10,1],[10,2],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,2],[10,1],[22,4],[22,5],[35,2],[37,1],[37,2],[37,3],[23,1],[23,3],[23,4],[23,6],[40,2],[40,3],[25,4],[42,1],[42,2],[24,1],[24,2],[24,1],[24,1],[20,3],[20,4],[20,4],[20,5],[28,3],[28,2],[29,1],[29,1],[29,1],[29,1],[48,3],[48,2],[48,2],[48,1],[56,1],[56,1],[56,1],[56,1],[56,1],[57,1],[57,1],[26,3],[26,4],[26,3],[26,4],[26,4],[26,5],[26,3],[26,4],[26,4],[26,5],[26,4],[26,5],[26,5],[26,6],[27,3],[73,1],[73,1],[74,1],[74,1],[74,1],[74,1],[74,1],[74,1],[74,1],[76,1],[76,1],[76,1],[76,1],[16,1],[16,1],[16,1],[16,1],[18,1],[50,1]],performAction:function(u,a,o,i,p,t,U){var s=t.length-1;switch(p){case 8:this.$=t[s-1];break;case 9:case 11:case 12:this.$=t[s];break;case 10:case 13:this.$=t[s-1]+t[s];break;case 14:case 15:this.$=t[s-1]+"~"+t[s]+"~";break;case 16:i.addRelation(t[s]);break;case 17:t[s-1].title=i.cleanupLabel(t[s]),i.addRelation(t[s-1]);break;case 26:this.$=t[s].trim(),i.setAccTitle(this.$);break;case 27:case 28:this.$=t[s].trim(),i.setAccDescription(this.$);break;case 29:i.addClassesToNamespace(t[s-3],t[s-1]);break;case 30:i.addClassesToNamespace(t[s-4],t[s-1]);break;case 31:this.$=t[s],i.addNamespace(t[s]);break;case 32:this.$=[t[s]];break;case 33:this.$=[t[s-1]];break;case 34:t[s].unshift(t[s-2]),this.$=t[s];break;case 36:i.setCssClass(t[s-2],t[s]);break;case 37:i.addMembers(t[s-3],t[s-1]);break;case 38:i.setCssClass(t[s-5],t[s-3]),i.addMembers(t[s-5],t[s-1]);break;case 39:this.$=t[s],i.addClass(t[s]);break;case 40:this.$=t[s-1],i.addClass(t[s-1]),i.setClassLabel(t[s-1],t[s]);break;case 41:i.addAnnotation(t[s],t[s-2]);break;case 42:this.$=[t[s]];break;case 43:t[s].push(t[s-1]),this.$=t[s];break;case 44:break;case 45:i.addMember(t[s-1],i.cleanupLabel(t[s]));break;case 46:break;case 47:break;case 48:this.$={id1:t[s-2],id2:t[s],relation:t[s-1],relationTitle1:"none",relationTitle2:"none"};break;case 49:this.$={id1:t[s-3],id2:t[s],relation:t[s-1],relationTitle1:t[s-2],relationTitle2:"none"};break;case 50:this.$={id1:t[s-3],id2:t[s],relation:t[s-2],relationTitle1:"none",relationTitle2:t[s-1]};break;case 51:this.$={id1:t[s-4],id2:t[s],relation:t[s-2],relationTitle1:t[s-3],relationTitle2:t[s-1]};break;case 52:i.addNote(t[s],t[s-1]);break;case 53:i.addNote(t[s]);break;case 54:i.setDirection("TB");break;case 55:i.setDirection("BT");break;case 56:i.setDirection("RL");break;case 57:i.setDirection("LR");break;case 58:this.$={type1:t[s-2],type2:t[s],lineType:t[s-1]};break;case 59:this.$={type1:"none",type2:t[s],lineType:t[s-1]};break;case 60:this.$={type1:t[s-1],type2:"none",lineType:t[s]};break;case 61:this.$={type1:"none",type2:"none",lineType:t[s]};break;case 62:this.$=i.relationType.AGGREGATION;break;case 63:this.$=i.relationType.EXTENSION;break;case 64:this.$=i.relationType.COMPOSITION;break;case 65:this.$=i.relationType.DEPENDENCY;break;case 66:this.$=i.relationType.LOLLIPOP;break;case 67:this.$=i.lineType.LINE;break;case 68:this.$=i.lineType.DOTTED_LINE;break;case 69:case 75:this.$=t[s-2],i.setClickEvent(t[s-1],t[s]);break;case 70:case 76:this.$=t[s-3],i.setClickEvent(t[s-2],t[s-1]),i.setTooltip(t[s-2],t[s]);break;case 71:this.$=t[s-2],i.setLink(t[s-1],t[s]);break;case 72:this.$=t[s-3],i.setLink(t[s-2],t[s-1],t[s]);break;case 73:this.$=t[s-3],i.setLink(t[s-2],t[s-1]),i.setTooltip(t[s-2],t[s]);break;case 74:this.$=t[s-4],i.setLink(t[s-3],t[s-2],t[s]),i.setTooltip(t[s-3],t[s-1]);break;case 77:this.$=t[s-3],i.setClickEvent(t[s-2],t[s-1],t[s]);break;case 78:this.$=t[s-4],i.setClickEvent(t[s-3],t[s-2],t[s-1]),i.setTooltip(t[s-3],t[s]);break;case 79:this.$=t[s-3],i.setLink(t[s-2],t[s]);break;case 80:this.$=t[s-4],i.setLink(t[s-3],t[s-1],t[s]);break;case 81:this.$=t[s-4],i.setLink(t[s-3],t[s-1]),i.setTooltip(t[s-3],t[s]);break;case 82:this.$=t[s-5],i.setLink(t[s-4],t[s-2],t[s]),i.setTooltip(t[s-4],t[s-1]);break;case 83:i.setCssClass(t[s-1],t[s]);break}},table:[{3:1,4:2,5:3,6:4,7:[1,6],10:5,16:35,17:19,18:36,20:7,22:8,23:9,24:10,25:11,26:12,27:13,28:14,29:15,30:n,32:r,34:h,35:20,39:l,40:21,43:A,44:g,46:D,47:B,49:_,51:re,52:ae,53:le,54:ce,55:oe,65:he,66:Ae,68:pe,72:fe,84:d,86:E,87:C,88:m,89:k},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},e(de,[2,5],{8:[1,44]}),{8:[1,45]},e(c,[2,16],{21:[1,46]}),e(c,[2,18]),e(c,[2,19]),e(c,[2,20]),e(c,[2,21]),e(c,[2,22]),e(c,[2,23]),e(c,[2,24]),e(c,[2,25]),{31:[1,47]},{33:[1,48]},e(c,[2,28]),e(c,[2,44],{48:49,56:52,57:53,13:[1,50],21:[1,51],58:Y,59:K,60:j,61:Q,62:X,63:Ee,64:Ce}),{36:[1,61]},e(q,[2,35],{36:[1,63],41:[1,62]}),e(c,[2,46]),e(c,[2,47]),{16:64,84:d,86:E,87:C,88:m},{16:35,17:65,18:36,84:d,86:E,87:C,88:m,89:k},{16:35,17:66,18:36,84:d,86:E,87:C,88:m,89:k},{16:35,17:67,18:36,84:d,86:E,87:C,88:m,89:k},{13:[1,68]},{16:35,17:69,18:36,84:d,86:E,87:C,88:m,89:k},{13:Le,50:70},e(c,[2,54]),e(c,[2,55]),e(c,[2,56]),e(c,[2,57]),e(G,[2,11],{16:35,18:36,17:72,19:[1,73],84:d,86:E,87:C,88:m,89:k}),e(G,[2,12],{19:[1,74]}),{15:75,16:76,84:d,86:E,87:C,88:m},{16:35,17:77,18:36,84:d,86:E,87:C,88:m,89:k},e(W,[2,97]),e(W,[2,98]),e(W,[2,99]),e(W,[2,100]),e([1,8,9,12,13,19,21,36,38,41,58,59,60,61,62,63,64,69,71],[2,101]),e(de,[2,6],{10:5,20:7,22:8,23:9,24:10,25:11,26:12,27:13,28:14,29:15,17:19,35:20,40:21,16:35,18:36,5:78,30:n,32:r,34:h,39:l,43:A,44:g,46:D,47:B,49:_,51:re,52:ae,53:le,54:ce,55:oe,65:he,66:Ae,68:pe,72:fe,84:d,86:E,87:C,88:m,89:k}),{5:79,10:5,16:35,17:19,18:36,20:7,22:8,23:9,24:10,25:11,26:12,27:13,28:14,29:15,30:n,32:r,34:h,35:20,39:l,40:21,43:A,44:g,46:D,47:B,49:_,51:re,52:ae,53:le,54:ce,55:oe,65:he,66:Ae,68:pe,72:fe,84:d,86:E,87:C,88:m,89:k},e(c,[2,17]),e(c,[2,26]),e(c,[2,27]),{13:[1,81],16:35,17:80,18:36,84:d,86:E,87:C,88:m,89:k},{48:82,56:52,57:53,58:Y,59:K,60:j,61:Q,62:X,63:Ee,64:Ce},e(c,[2,45]),{57:83,63:Ee,64:Ce},e(H,[2,61],{56:84,58:Y,59:K,60:j,61:Q,62:X}),e(M,[2,62]),e(M,[2,63]),e(M,[2,64]),e(M,[2,65]),e(M,[2,66]),e(xe,[2,67]),e(xe,[2,68]),{8:[1,86],23:87,37:85,40:21,43:A},{16:88,84:d,86:E,87:C,88:m},{42:89,46:me},{45:[1,91]},{13:[1,92]},{13:[1,93]},{69:[1,94],71:[1,95]},{16:96,84:d,86:E,87:C,88:m},{13:Le,50:97},e(c,[2,53]),e(c,[2,102]),e(G,[2,13]),e(G,[2,14]),e(G,[2,15]),{36:[2,31]},{15:98,16:76,36:[2,9],84:d,86:E,87:C,88:m},e(be,[2,39],{11:99,12:[1,100]}),e(de,[2,7]),{9:[1,101]},e(J,[2,48]),{16:35,17:102,18:36,84:d,86:E,87:C,88:m,89:k},{13:[1,104],16:35,17:103,18:36,84:d,86:E,87:C,88:m,89:k},e(H,[2,60],{56:105,58:Y,59:K,60:j,61:Q,62:X}),e(H,[2,59]),{38:[1,106]},{23:87,37:107,40:21,43:A},{8:[1,108],38:[2,32]},e(q,[2,36],{36:[1,109]}),{38:[1,110]},{38:[2,42],42:111,46:me},{16:35,17:112,18:36,84:d,86:E,87:C,88:m,89:k},e(c,[2,69],{13:[1,113]}),e(c,[2,71],{13:[1,115],67:[1,114]}),e(c,[2,75],{13:[1,116],70:[1,117]}),{13:[1,118]},e(c,[2,83]),e(c,[2,52]),{36:[2,10]},e(be,[2,40]),{13:[1,119]},{1:[2,4]},e(J,[2,50]),e(J,[2,49]),{16:35,17:120,18:36,84:d,86:E,87:C,88:m,89:k},e(H,[2,58]),e(c,[2,29]),{38:[1,121]},{23:87,37:122,38:[2,33],40:21,43:A},{42:123,46:me},e(q,[2,37]),{38:[2,43]},e(c,[2,41]),e(c,[2,70]),e(c,[2,72]),e(c,[2,73],{67:[1,124]}),e(c,[2,76]),e(c,[2,77],{13:[1,125]}),e(c,[2,79],{13:[1,127],67:[1,126]}),{14:[1,128]},e(J,[2,51]),e(c,[2,30]),{38:[2,34]},{38:[1,129]},e(c,[2,74]),e(c,[2,78]),e(c,[2,80]),e(c,[2,81],{67:[1,130]}),e(be,[2,8]),e(q,[2,38]),e(c,[2,82])],defaultActions:{2:[2,1],3:[2,2],4:[2,3],75:[2,31],98:[2,10],101:[2,4],111:[2,43],122:[2,34]},parseError:function(u,a){if(a.recoverable)this.trace(u);else{var o=new Error(u);throw o.hash=a,o}},parse:function(u){var a=this,o=[0],i=[],p=[null],t=[],U=this.table,s="",Z=0,Ie=0,Ze=2,Oe=1,$e=t.slice.call(arguments,1),b=Object.create(this.lexer),I={yy:{}};for(var Te in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Te)&&(I.yy[Te]=this.yy[Te]);b.setInput(u,I.yy),I.yy.lexer=b,I.yy.parser=this,typeof b.yylloc>"u"&&(b.yylloc={});var Fe=b.yylloc;t.push(Fe);var et=b.options&&b.options.ranges;typeof I.yy.parseError=="function"?this.parseError=I.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function tt(){var v;return v=i.pop()||b.lex()||Oe,typeof v!="number"&&(v instanceof Array&&(i=v,v=i.pop()),v=a.symbols_[v]||v),v}for(var T,O,y,ye,w={},$,N,Re,ee;;){if(O=o[o.length-1],this.defaultActions[O]?y=this.defaultActions[O]:((T===null||typeof T>"u")&&(T=tt()),y=U[O]&&U[O][T]),typeof y>"u"||!y.length||!y[0]){var De="";ee=[];for($ in U[O])this.terminals_[$]&&$>Ze&&ee.push("'"+this.terminals_[$]+"'");b.showPosition?De="Parse error on line "+(Z+1)+`: `+b.showPosition()+` Expecting `+ee.join(", ")+", got '"+(this.terminals_[T]||T)+"'":De="Parse error on line "+(Z+1)+": Unexpected "+(T==Oe?"end of input":"'"+(this.terminals_[T]||T)+"'"),this.parseError(De,{text:b.match,token:this.terminals_[T]||T,line:b.yylineno,loc:Fe,expected:ee})}if(y[0]instanceof Array&&y.length>1)throw new Error("Parse Error: multiple actions possible at state: "+O+", token: "+T);switch(y[0]){case 1:o.push(T),p.push(b.yytext),t.push(b.yylloc),o.push(y[1]),T=null,Ie=b.yyleng,s=b.yytext,Z=b.yylineno,Fe=b.yylloc;break;case 2:if(N=this.productions_[y[1]][1],w.$=p[p.length-N],w._$={first_line:t[t.length-(N||1)].first_line,last_line:t[t.length-1].last_line,first_column:t[t.length-(N||1)].first_column,last_column:t[t.length-1].last_column},et&&(w._$.range=[t[t.length-(N||1)].range[0],t[t.length-1].range[1]]),ye=this.performAction.apply(w,[s,Ie,Z,I.yy,y[1],p,t].concat($e)),typeof ye<"u")return ye;N&&(o=o.slice(0,-1*N*2),p=p.slice(0,-1*N),t=t.slice(0,-1*N)),o.push(this.productions_[y[1]][0]),p.push(w.$),t.push(w._$),Re=U[o[o.length-2]][o[o.length-1]],o.push(Re);break;case 3:return!0}}return!0}},Je=function(){var L={EOF:1,parseError:function(a,o){if(this.yy.parser)this.yy.parser.parseError(a,o);else throw new Error(a)},setInput:function(u,a){return this.yy=a||this.yy||{},this._input=u,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var u=this._input[0];this.yytext+=u,this.yyleng++,this.offset++,this.match+=u,this.matched+=u;var a=u.match(/(?:\r\n?|\n).*/g);return a?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),u},unput:function(u){var a=u.length,o=u.split(/(?:\r\n?|\n)/g);this._input=u+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-a),this.offset-=a;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),o.length-1&&(this.yylineno-=o.length-1);var p=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:o?(o.length===i.length?this.yylloc.first_column:0)+i[i.length-o.length].length-o[0].length:this.yylloc.first_column-a},this.options.ranges&&(this.yylloc.range=[p[0],p[0]+this.yyleng-a]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(u){this.unput(this.match.slice(u))},pastInput:function(){var u=this.matched.substr(0,this.matched.length-this.match.length);return(u.length>20?"...":"")+u.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var u=this.match;return u.length<20&&(u+=this._input.substr(0,20-u.length)),(u.substr(0,20)+(u.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var u=this.pastInput(),a=new Array(u.length+1).join("-");return u+this.upcomingInput()+` @@ -157,4 +157,4 @@ g.classGroup line { fill: ${e.textColor}; } `,xt=_t;export{vt as a,Lt as b,xt as c}; -//# sourceMappingURL=chunk-F3IAZVFZ.min.js.map +//# sourceMappingURL=chunk-NRFNOXYN.min.js.map diff --git a/docs/public/chunk-F3IAZVFZ.min.js.map b/docs/public/chunk-NRFNOXYN.min.js.map similarity index 99% rename from docs/public/chunk-F3IAZVFZ.min.js.map rename to docs/public/chunk-NRFNOXYN.min.js.map index cd87454d..9d756d02 100644 --- a/docs/public/chunk-F3IAZVFZ.min.js.map +++ b/docs/public/chunk-NRFNOXYN.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/styles-3dcbcfbf.js"], - "sourcesContent": ["import { select } from \"d3\";\nimport { d as sanitizeText$1, c as getConfig, v as parseGenericTypes, s as setAccTitle, g as getAccTitle, a as getAccDescription, b as setAccDescription, q as setDiagramTitle, r as getDiagramTitle, e as common, t as clear$1, l as log, u as utils } from \"./mermaid-8af3addd.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 16], $V1 = [1, 17], $V2 = [1, 18], $V3 = [1, 37], $V4 = [1, 38], $V5 = [1, 24], $V6 = [1, 22], $V7 = [1, 23], $V8 = [1, 29], $V9 = [1, 30], $Va = [1, 31], $Vb = [1, 32], $Vc = [1, 33], $Vd = [1, 34], $Ve = [1, 25], $Vf = [1, 26], $Vg = [1, 27], $Vh = [1, 28], $Vi = [1, 42], $Vj = [1, 39], $Vk = [1, 40], $Vl = [1, 41], $Vm = [1, 43], $Vn = [1, 9], $Vo = [1, 8, 9], $Vp = [1, 54], $Vq = [1, 55], $Vr = [1, 56], $Vs = [1, 57], $Vt = [1, 58], $Vu = [1, 59], $Vv = [1, 60], $Vw = [1, 8, 9, 38], $Vx = [1, 71], $Vy = [1, 8, 9, 12, 13, 21, 36, 38, 41, 58, 59, 60, 61, 62, 63, 64, 69, 71], $Vz = [1, 8, 9, 12, 13, 19, 21, 36, 38, 41, 45, 58, 59, 60, 61, 62, 63, 64, 69, 71, 84, 86, 87, 88, 89], $VA = [13, 84, 86, 87, 88, 89], $VB = [13, 63, 64, 84, 86, 87, 88, 89], $VC = [13, 58, 59, 60, 61, 62, 84, 86, 87, 88, 89], $VD = [1, 90], $VE = [1, 8, 9, 36, 38, 41], $VF = [1, 8, 9, 21];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"mermaidDoc\": 4, \"statements\": 5, \"graphConfig\": 6, \"CLASS_DIAGRAM\": 7, \"NEWLINE\": 8, \"EOF\": 9, \"statement\": 10, \"classLabel\": 11, \"SQS\": 12, \"STR\": 13, \"SQE\": 14, \"namespaceName\": 15, \"alphaNumToken\": 16, \"className\": 17, \"classLiteralName\": 18, \"GENERICTYPE\": 19, \"relationStatement\": 20, \"LABEL\": 21, \"namespaceStatement\": 22, \"classStatement\": 23, \"memberStatement\": 24, \"annotationStatement\": 25, \"clickStatement\": 26, \"cssClassStatement\": 27, \"noteStatement\": 28, \"direction\": 29, \"acc_title\": 30, \"acc_title_value\": 31, \"acc_descr\": 32, \"acc_descr_value\": 33, \"acc_descr_multiline_value\": 34, \"namespaceIdentifier\": 35, \"STRUCT_START\": 36, \"classStatements\": 37, \"STRUCT_STOP\": 38, \"NAMESPACE\": 39, \"classIdentifier\": 40, \"STYLE_SEPARATOR\": 41, \"members\": 42, \"CLASS\": 43, \"ANNOTATION_START\": 44, \"ANNOTATION_END\": 45, \"MEMBER\": 46, \"SEPARATOR\": 47, \"relation\": 48, \"NOTE_FOR\": 49, \"noteText\": 50, \"NOTE\": 51, \"direction_tb\": 52, \"direction_bt\": 53, \"direction_rl\": 54, \"direction_lr\": 55, \"relationType\": 56, \"lineType\": 57, \"AGGREGATION\": 58, \"EXTENSION\": 59, \"COMPOSITION\": 60, \"DEPENDENCY\": 61, \"LOLLIPOP\": 62, \"LINE\": 63, \"DOTTED_LINE\": 64, \"CALLBACK\": 65, \"LINK\": 66, \"LINK_TARGET\": 67, \"CLICK\": 68, \"CALLBACK_NAME\": 69, \"CALLBACK_ARGS\": 70, \"HREF\": 71, \"CSSCLASS\": 72, \"commentToken\": 73, \"textToken\": 74, \"graphCodeTokens\": 75, \"textNoTagsToken\": 76, \"TAGSTART\": 77, \"TAGEND\": 78, \"==\": 79, \"--\": 80, \"PCT\": 81, \"DEFAULT\": 82, \"SPACE\": 83, \"MINUS\": 84, \"keywords\": 85, \"UNICODE_TEXT\": 86, \"NUM\": 87, \"ALPHA\": 88, \"BQUOTE_STR\": 89, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 7: \"CLASS_DIAGRAM\", 8: \"NEWLINE\", 9: \"EOF\", 12: \"SQS\", 13: \"STR\", 14: \"SQE\", 19: \"GENERICTYPE\", 21: \"LABEL\", 30: \"acc_title\", 31: \"acc_title_value\", 32: \"acc_descr\", 33: \"acc_descr_value\", 34: \"acc_descr_multiline_value\", 36: \"STRUCT_START\", 38: \"STRUCT_STOP\", 39: \"NAMESPACE\", 41: \"STYLE_SEPARATOR\", 43: \"CLASS\", 44: \"ANNOTATION_START\", 45: \"ANNOTATION_END\", 46: \"MEMBER\", 47: \"SEPARATOR\", 49: \"NOTE_FOR\", 51: \"NOTE\", 52: \"direction_tb\", 53: \"direction_bt\", 54: \"direction_rl\", 55: \"direction_lr\", 58: \"AGGREGATION\", 59: \"EXTENSION\", 60: \"COMPOSITION\", 61: \"DEPENDENCY\", 62: \"LOLLIPOP\", 63: \"LINE\", 64: \"DOTTED_LINE\", 65: \"CALLBACK\", 66: \"LINK\", 67: \"LINK_TARGET\", 68: \"CLICK\", 69: \"CALLBACK_NAME\", 70: \"CALLBACK_ARGS\", 71: \"HREF\", 72: \"CSSCLASS\", 75: \"graphCodeTokens\", 77: \"TAGSTART\", 78: \"TAGEND\", 79: \"==\", 80: \"--\", 81: \"PCT\", 82: \"DEFAULT\", 83: \"SPACE\", 84: \"MINUS\", 85: \"keywords\", 86: \"UNICODE_TEXT\", 87: \"NUM\", 88: \"ALPHA\", 89: \"BQUOTE_STR\" },\n productions_: [0, [3, 1], [3, 1], [4, 1], [6, 4], [5, 1], [5, 2], [5, 3], [11, 3], [15, 1], [15, 2], [17, 1], [17, 1], [17, 2], [17, 2], [17, 2], [10, 1], [10, 2], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 2], [10, 2], [10, 1], [22, 4], [22, 5], [35, 2], [37, 1], [37, 2], [37, 3], [23, 1], [23, 3], [23, 4], [23, 6], [40, 2], [40, 3], [25, 4], [42, 1], [42, 2], [24, 1], [24, 2], [24, 1], [24, 1], [20, 3], [20, 4], [20, 4], [20, 5], [28, 3], [28, 2], [29, 1], [29, 1], [29, 1], [29, 1], [48, 3], [48, 2], [48, 2], [48, 1], [56, 1], [56, 1], [56, 1], [56, 1], [56, 1], [57, 1], [57, 1], [26, 3], [26, 4], [26, 3], [26, 4], [26, 4], [26, 5], [26, 3], [26, 4], [26, 4], [26, 5], [26, 4], [26, 5], [26, 5], [26, 6], [27, 3], [73, 1], [73, 1], [74, 1], [74, 1], [74, 1], [74, 1], [74, 1], [74, 1], [74, 1], [76, 1], [76, 1], [76, 1], [76, 1], [16, 1], [16, 1], [16, 1], [16, 1], [18, 1], [50, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 8:\n this.$ = $$[$0 - 1];\n break;\n case 9:\n case 11:\n case 12:\n this.$ = $$[$0];\n break;\n case 10:\n case 13:\n this.$ = $$[$0 - 1] + $$[$0];\n break;\n case 14:\n case 15:\n this.$ = $$[$0 - 1] + \"~\" + $$[$0] + \"~\";\n break;\n case 16:\n yy.addRelation($$[$0]);\n break;\n case 17:\n $$[$0 - 1].title = yy.cleanupLabel($$[$0]);\n yy.addRelation($$[$0 - 1]);\n break;\n case 26:\n this.$ = $$[$0].trim();\n yy.setAccTitle(this.$);\n break;\n case 27:\n case 28:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 29:\n yy.addClassesToNamespace($$[$0 - 3], $$[$0 - 1]);\n break;\n case 30:\n yy.addClassesToNamespace($$[$0 - 4], $$[$0 - 1]);\n break;\n case 31:\n this.$ = $$[$0];\n yy.addNamespace($$[$0]);\n break;\n case 32:\n this.$ = [$$[$0]];\n break;\n case 33:\n this.$ = [$$[$0 - 1]];\n break;\n case 34:\n $$[$0].unshift($$[$0 - 2]);\n this.$ = $$[$0];\n break;\n case 36:\n yy.setCssClass($$[$0 - 2], $$[$0]);\n break;\n case 37:\n yy.addMembers($$[$0 - 3], $$[$0 - 1]);\n break;\n case 38:\n yy.setCssClass($$[$0 - 5], $$[$0 - 3]);\n yy.addMembers($$[$0 - 5], $$[$0 - 1]);\n break;\n case 39:\n this.$ = $$[$0];\n yy.addClass($$[$0]);\n break;\n case 40:\n this.$ = $$[$0 - 1];\n yy.addClass($$[$0 - 1]);\n yy.setClassLabel($$[$0 - 1], $$[$0]);\n break;\n case 41:\n yy.addAnnotation($$[$0], $$[$0 - 2]);\n break;\n case 42:\n this.$ = [$$[$0]];\n break;\n case 43:\n $$[$0].push($$[$0 - 1]);\n this.$ = $$[$0];\n break;\n case 44:\n break;\n case 45:\n yy.addMember($$[$0 - 1], yy.cleanupLabel($$[$0]));\n break;\n case 46:\n break;\n case 47:\n break;\n case 48:\n this.$ = { \"id1\": $$[$0 - 2], \"id2\": $$[$0], relation: $$[$0 - 1], relationTitle1: \"none\", relationTitle2: \"none\" };\n break;\n case 49:\n this.$ = { id1: $$[$0 - 3], id2: $$[$0], relation: $$[$0 - 1], relationTitle1: $$[$0 - 2], relationTitle2: \"none\" };\n break;\n case 50:\n this.$ = { id1: $$[$0 - 3], id2: $$[$0], relation: $$[$0 - 2], relationTitle1: \"none\", relationTitle2: $$[$0 - 1] };\n break;\n case 51:\n this.$ = { id1: $$[$0 - 4], id2: $$[$0], relation: $$[$0 - 2], relationTitle1: $$[$0 - 3], relationTitle2: $$[$0 - 1] };\n break;\n case 52:\n yy.addNote($$[$0], $$[$0 - 1]);\n break;\n case 53:\n yy.addNote($$[$0]);\n break;\n case 54:\n yy.setDirection(\"TB\");\n break;\n case 55:\n yy.setDirection(\"BT\");\n break;\n case 56:\n yy.setDirection(\"RL\");\n break;\n case 57:\n yy.setDirection(\"LR\");\n break;\n case 58:\n this.$ = { type1: $$[$0 - 2], type2: $$[$0], lineType: $$[$0 - 1] };\n break;\n case 59:\n this.$ = { type1: \"none\", type2: $$[$0], lineType: $$[$0 - 1] };\n break;\n case 60:\n this.$ = { type1: $$[$0 - 1], type2: \"none\", lineType: $$[$0] };\n break;\n case 61:\n this.$ = { type1: \"none\", type2: \"none\", lineType: $$[$0] };\n break;\n case 62:\n this.$ = yy.relationType.AGGREGATION;\n break;\n case 63:\n this.$ = yy.relationType.EXTENSION;\n break;\n case 64:\n this.$ = yy.relationType.COMPOSITION;\n break;\n case 65:\n this.$ = yy.relationType.DEPENDENCY;\n break;\n case 66:\n this.$ = yy.relationType.LOLLIPOP;\n break;\n case 67:\n this.$ = yy.lineType.LINE;\n break;\n case 68:\n this.$ = yy.lineType.DOTTED_LINE;\n break;\n case 69:\n case 75:\n this.$ = $$[$0 - 2];\n yy.setClickEvent($$[$0 - 1], $$[$0]);\n break;\n case 70:\n case 76:\n this.$ = $$[$0 - 3];\n yy.setClickEvent($$[$0 - 2], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 2], $$[$0]);\n break;\n case 71:\n this.$ = $$[$0 - 2];\n yy.setLink($$[$0 - 1], $$[$0]);\n break;\n case 72:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 2], $$[$0 - 1], $$[$0]);\n break;\n case 73:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 2], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 2], $$[$0]);\n break;\n case 74:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 3], $$[$0 - 2], $$[$0]);\n yy.setTooltip($$[$0 - 3], $$[$0 - 1]);\n break;\n case 77:\n this.$ = $$[$0 - 3];\n yy.setClickEvent($$[$0 - 2], $$[$0 - 1], $$[$0]);\n break;\n case 78:\n this.$ = $$[$0 - 4];\n yy.setClickEvent($$[$0 - 3], $$[$0 - 2], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 79:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 2], $$[$0]);\n break;\n case 80:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 3], $$[$0 - 1], $$[$0]);\n break;\n case 81:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 3], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 82:\n this.$ = $$[$0 - 5];\n yy.setLink($$[$0 - 4], $$[$0 - 2], $$[$0]);\n yy.setTooltip($$[$0 - 4], $$[$0 - 1]);\n break;\n case 83:\n yy.setCssClass($$[$0 - 1], $$[$0]);\n break;\n }\n },\n table: [{ 3: 1, 4: 2, 5: 3, 6: 4, 7: [1, 6], 10: 5, 16: 35, 17: 19, 18: 36, 20: 7, 22: 8, 23: 9, 24: 10, 25: 11, 26: 12, 27: 13, 28: 14, 29: 15, 30: $V0, 32: $V1, 34: $V2, 35: 20, 39: $V3, 40: 21, 43: $V4, 44: $V5, 46: $V6, 47: $V7, 49: $V8, 51: $V9, 52: $Va, 53: $Vb, 54: $Vc, 55: $Vd, 65: $Ve, 66: $Vf, 68: $Vg, 72: $Vh, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 1: [3] }, { 1: [2, 1] }, { 1: [2, 2] }, { 1: [2, 3] }, o($Vn, [2, 5], { 8: [1, 44] }), { 8: [1, 45] }, o($Vo, [2, 16], { 21: [1, 46] }), o($Vo, [2, 18]), o($Vo, [2, 19]), o($Vo, [2, 20]), o($Vo, [2, 21]), o($Vo, [2, 22]), o($Vo, [2, 23]), o($Vo, [2, 24]), o($Vo, [2, 25]), { 31: [1, 47] }, { 33: [1, 48] }, o($Vo, [2, 28]), o($Vo, [2, 44], { 48: 49, 56: 52, 57: 53, 13: [1, 50], 21: [1, 51], 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt, 63: $Vu, 64: $Vv }), { 36: [1, 61] }, o($Vw, [2, 35], { 36: [1, 63], 41: [1, 62] }), o($Vo, [2, 46]), o($Vo, [2, 47]), { 16: 64, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 16: 35, 17: 65, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 16: 35, 17: 66, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 16: 35, 17: 67, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 13: [1, 68] }, { 16: 35, 17: 69, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 13: $Vx, 50: 70 }, o($Vo, [2, 54]), o($Vo, [2, 55]), o($Vo, [2, 56]), o($Vo, [2, 57]), o($Vy, [2, 11], { 16: 35, 18: 36, 17: 72, 19: [1, 73], 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }), o($Vy, [2, 12], { 19: [1, 74] }), { 15: 75, 16: 76, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 16: 35, 17: 77, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($Vz, [2, 97]), o($Vz, [2, 98]), o($Vz, [2, 99]), o($Vz, [2, 100]), o([1, 8, 9, 12, 13, 19, 21, 36, 38, 41, 58, 59, 60, 61, 62, 63, 64, 69, 71], [2, 101]), o($Vn, [2, 6], { 10: 5, 20: 7, 22: 8, 23: 9, 24: 10, 25: 11, 26: 12, 27: 13, 28: 14, 29: 15, 17: 19, 35: 20, 40: 21, 16: 35, 18: 36, 5: 78, 30: $V0, 32: $V1, 34: $V2, 39: $V3, 43: $V4, 44: $V5, 46: $V6, 47: $V7, 49: $V8, 51: $V9, 52: $Va, 53: $Vb, 54: $Vc, 55: $Vd, 65: $Ve, 66: $Vf, 68: $Vg, 72: $Vh, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }), { 5: 79, 10: 5, 16: 35, 17: 19, 18: 36, 20: 7, 22: 8, 23: 9, 24: 10, 25: 11, 26: 12, 27: 13, 28: 14, 29: 15, 30: $V0, 32: $V1, 34: $V2, 35: 20, 39: $V3, 40: 21, 43: $V4, 44: $V5, 46: $V6, 47: $V7, 49: $V8, 51: $V9, 52: $Va, 53: $Vb, 54: $Vc, 55: $Vd, 65: $Ve, 66: $Vf, 68: $Vg, 72: $Vh, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($Vo, [2, 17]), o($Vo, [2, 26]), o($Vo, [2, 27]), { 13: [1, 81], 16: 35, 17: 80, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 48: 82, 56: 52, 57: 53, 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt, 63: $Vu, 64: $Vv }, o($Vo, [2, 45]), { 57: 83, 63: $Vu, 64: $Vv }, o($VA, [2, 61], { 56: 84, 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt }), o($VB, [2, 62]), o($VB, [2, 63]), o($VB, [2, 64]), o($VB, [2, 65]), o($VB, [2, 66]), o($VC, [2, 67]), o($VC, [2, 68]), { 8: [1, 86], 23: 87, 37: 85, 40: 21, 43: $V4 }, { 16: 88, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 42: 89, 46: $VD }, { 45: [1, 91] }, { 13: [1, 92] }, { 13: [1, 93] }, { 69: [1, 94], 71: [1, 95] }, { 16: 96, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 13: $Vx, 50: 97 }, o($Vo, [2, 53]), o($Vo, [2, 102]), o($Vy, [2, 13]), o($Vy, [2, 14]), o($Vy, [2, 15]), { 36: [2, 31] }, { 15: 98, 16: 76, 36: [2, 9], 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, o($VE, [2, 39], { 11: 99, 12: [1, 100] }), o($Vn, [2, 7]), { 9: [1, 101] }, o($VF, [2, 48]), { 16: 35, 17: 102, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 13: [1, 104], 16: 35, 17: 103, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($VA, [2, 60], { 56: 105, 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt }), o($VA, [2, 59]), { 38: [1, 106] }, { 23: 87, 37: 107, 40: 21, 43: $V4 }, { 8: [1, 108], 38: [2, 32] }, o($Vw, [2, 36], { 36: [1, 109] }), { 38: [1, 110] }, { 38: [2, 42], 42: 111, 46: $VD }, { 16: 35, 17: 112, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($Vo, [2, 69], { 13: [1, 113] }), o($Vo, [2, 71], { 13: [1, 115], 67: [1, 114] }), o($Vo, [2, 75], { 13: [1, 116], 70: [1, 117] }), { 13: [1, 118] }, o($Vo, [2, 83]), o($Vo, [2, 52]), { 36: [2, 10] }, o($VE, [2, 40]), { 13: [1, 119] }, { 1: [2, 4] }, o($VF, [2, 50]), o($VF, [2, 49]), { 16: 35, 17: 120, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($VA, [2, 58]), o($Vo, [2, 29]), { 38: [1, 121] }, { 23: 87, 37: 122, 38: [2, 33], 40: 21, 43: $V4 }, { 42: 123, 46: $VD }, o($Vw, [2, 37]), { 38: [2, 43] }, o($Vo, [2, 41]), o($Vo, [2, 70]), o($Vo, [2, 72]), o($Vo, [2, 73], { 67: [1, 124] }), o($Vo, [2, 76]), o($Vo, [2, 77], { 13: [1, 125] }), o($Vo, [2, 79], { 13: [1, 127], 67: [1, 126] }), { 14: [1, 128] }, o($VF, [2, 51]), o($Vo, [2, 30]), { 38: [2, 34] }, { 38: [1, 129] }, o($Vo, [2, 74]), o($Vo, [2, 78]), o($Vo, [2, 80]), o($Vo, [2, 81], { 67: [1, 130] }), o($VE, [2, 8]), o($Vw, [2, 38]), o($Vo, [2, 82])],\n defaultActions: { 2: [2, 1], 3: [2, 2], 4: [2, 3], 75: [2, 31], 98: [2, 10], 101: [2, 4], 111: [2, 43], 122: [2, 34] },\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: {},\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n return 52;\n case 1:\n return 53;\n case 2:\n return 54;\n case 3:\n return 55;\n case 4:\n break;\n case 5:\n break;\n case 6:\n this.begin(\"acc_title\");\n return 30;\n case 7:\n this.popState();\n return \"acc_title_value\";\n case 8:\n this.begin(\"acc_descr\");\n return 32;\n case 9:\n this.popState();\n return \"acc_descr_value\";\n case 10:\n this.begin(\"acc_descr_multiline\");\n break;\n case 11:\n this.popState();\n break;\n case 12:\n return \"acc_descr_multiline_value\";\n case 13:\n return 8;\n case 14:\n break;\n case 15:\n return 7;\n case 16:\n return 7;\n case 17:\n return \"EDGE_STATE\";\n case 18:\n this.begin(\"callback_name\");\n break;\n case 19:\n this.popState();\n break;\n case 20:\n this.popState();\n this.begin(\"callback_args\");\n break;\n case 21:\n return 69;\n case 22:\n this.popState();\n break;\n case 23:\n return 70;\n case 24:\n this.popState();\n break;\n case 25:\n return \"STR\";\n case 26:\n this.begin(\"string\");\n break;\n case 27:\n this.begin(\"namespace\");\n return 39;\n case 28:\n this.popState();\n return 8;\n case 29:\n break;\n case 30:\n this.begin(\"namespace-body\");\n return 36;\n case 31:\n this.popState();\n return 38;\n case 32:\n return \"EOF_IN_STRUCT\";\n case 33:\n return 8;\n case 34:\n break;\n case 35:\n return \"EDGE_STATE\";\n case 36:\n this.begin(\"class\");\n return 43;\n case 37:\n this.popState();\n return 8;\n case 38:\n break;\n case 39:\n this.popState();\n this.popState();\n return 38;\n case 40:\n this.begin(\"class-body\");\n return 36;\n case 41:\n this.popState();\n return 38;\n case 42:\n return \"EOF_IN_STRUCT\";\n case 43:\n return \"EDGE_STATE\";\n case 44:\n return \"OPEN_IN_STRUCT\";\n case 45:\n break;\n case 46:\n return \"MEMBER\";\n case 47:\n return 72;\n case 48:\n return 65;\n case 49:\n return 66;\n case 50:\n return 68;\n case 51:\n return 49;\n case 52:\n return 51;\n case 53:\n return 44;\n case 54:\n return 45;\n case 55:\n return 71;\n case 56:\n this.popState();\n break;\n case 57:\n return \"GENERICTYPE\";\n case 58:\n this.begin(\"generic\");\n break;\n case 59:\n this.popState();\n break;\n case 60:\n return \"BQUOTE_STR\";\n case 61:\n this.begin(\"bqstring\");\n break;\n case 62:\n return 67;\n case 63:\n return 67;\n case 64:\n return 67;\n case 65:\n return 67;\n case 66:\n return 59;\n case 67:\n return 59;\n case 68:\n return 61;\n case 69:\n return 61;\n case 70:\n return 60;\n case 71:\n return 58;\n case 72:\n return 62;\n case 73:\n return 63;\n case 74:\n return 64;\n case 75:\n return 21;\n case 76:\n return 41;\n case 77:\n return 84;\n case 78:\n return \"DOT\";\n case 79:\n return \"PLUS\";\n case 80:\n return 81;\n case 81:\n return \"EQUALS\";\n case 82:\n return \"EQUALS\";\n case 83:\n return 88;\n case 84:\n return 12;\n case 85:\n return 14;\n case 86:\n return \"PUNCTUATION\";\n case 87:\n return 87;\n case 88:\n return 86;\n case 89:\n return 83;\n case 90:\n return 9;\n }\n },\n rules: [/^(?:.*direction\\s+TB[^\\n]*)/, /^(?:.*direction\\s+BT[^\\n]*)/, /^(?:.*direction\\s+RL[^\\n]*)/, /^(?:.*direction\\s+LR[^\\n]*)/, /^(?:%%(?!\\{)*[^\\n]*(\\r?\\n?)+)/, /^(?:%%[^\\n]*(\\r?\\n)*)/, /^(?:accTitle\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*\\{\\s*)/, /^(?:[\\}])/, /^(?:[^\\}]*)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:classDiagram-v2\\b)/, /^(?:classDiagram\\b)/, /^(?:\\[\\*\\])/, /^(?:call[\\s]+)/, /^(?:\\([\\s]*\\))/, /^(?:\\()/, /^(?:[^(]*)/, /^(?:\\))/, /^(?:[^)]*)/, /^(?:[\"])/, /^(?:[^\"]*)/, /^(?:[\"])/, /^(?:namespace\\b)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:[{])/, /^(?:[}])/, /^(?:$)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:\\[\\*\\])/, /^(?:class\\b)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:[}])/, /^(?:[{])/, /^(?:[}])/, /^(?:$)/, /^(?:\\[\\*\\])/, /^(?:[{])/, /^(?:[\\n])/, /^(?:[^{}\\n]*)/, /^(?:cssClass\\b)/, /^(?:callback\\b)/, /^(?:link\\b)/, /^(?:click\\b)/, /^(?:note for\\b)/, /^(?:note\\b)/, /^(?:<<)/, /^(?:>>)/, /^(?:href\\b)/, /^(?:[~])/, /^(?:[^~]*)/, /^(?:~)/, /^(?:[`])/, /^(?:[^`]+)/, /^(?:[`])/, /^(?:_self\\b)/, /^(?:_blank\\b)/, /^(?:_parent\\b)/, /^(?:_top\\b)/, /^(?:\\s*<\\|)/, /^(?:\\s*\\|>)/, /^(?:\\s*>)/, /^(?:\\s*<)/, /^(?:\\s*\\*)/, /^(?:\\s*o\\b)/, /^(?:\\s*\\(\\))/, /^(?:--)/, /^(?:\\.\\.)/, /^(?::{1}[^:\\n;]+)/, /^(?::{3})/, /^(?:-)/, /^(?:\\.)/, /^(?:\\+)/, /^(?:%)/, /^(?:=)/, /^(?:=)/, /^(?:\\w+)/, /^(?:\\[)/, /^(?:\\])/, /^(?:[!\"#$%&'*+,-.`?\\\\/])/, /^(?:[0-9]+)/, /^(?:[\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6]|[\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377]|[\\u037A-\\u037D\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5]|[\\u03F7-\\u0481\\u048A-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA]|[\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE]|[\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA]|[\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u08A0]|[\\u08A2-\\u08AC\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0977]|[\\u0979-\\u097F\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2]|[\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A]|[\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39]|[\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8]|[\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C]|[\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35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260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0]|[\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310]|[\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C]|[\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u1700-\\u170C\\u170E-\\u1711]|[\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7]|[\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191C]|[\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19C1-\\u19C7\\u1A00-\\u1A16]|[\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF]|[\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1CE9-\\u1CEC]|[\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D]|[\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D]|[\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3]|[\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F]|[\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128]|[\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184]|[\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3]|[\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6]|[\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE]|[\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C]|[\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D]|[\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC]|[\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B]|[\\uA640-\\uA66E\\uA67F-\\uA697\\uA6A0-\\uA6E5\\uA717-\\uA71F\\uA722-\\uA788]|[\\uA78B-\\uA78E\\uA790-\\uA793\\uA7A0-\\uA7AA\\uA7F8-\\uA801\\uA803-\\uA805]|[\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB]|[\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uAA00-\\uAA28]|[\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA80-\\uAAAF\\uAAB1\\uAAB5]|[\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4]|[\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E]|[\\uABC0-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D]|[\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36]|[\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D]|[\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC]|[\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF]|[\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC])/, /^(?:\\s)/, /^(?:$)/],\n conditions: { \"namespace-body\": { \"rules\": [26, 31, 32, 33, 34, 35, 36, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"namespace\": { \"rules\": [26, 27, 28, 29, 30, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"class-body\": { \"rules\": [26, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"class\": { \"rules\": [26, 37, 38, 39, 40, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"acc_descr_multiline\": { \"rules\": [11, 12, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"acc_descr\": { \"rules\": [9, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"acc_title\": { \"rules\": [7, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"callback_args\": { \"rules\": [22, 23, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"callback_name\": { \"rules\": [19, 20, 21, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"href\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"struct\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"generic\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"bqstring\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"string\": { \"rules\": [24, 25, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 1, 2, 3, 4, 5, 6, 8, 10, 13, 14, 15, 16, 17, 18, 26, 27, 36, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nconst visibilityValues = [\"#\", \"+\", \"~\", \"-\", \"\"];\nclass ClassMember {\n constructor(input, memberType) {\n this.memberType = memberType;\n this.visibility = \"\";\n this.classifier = \"\";\n const sanitizedInput = sanitizeText$1(input, getConfig());\n this.parseMember(sanitizedInput);\n }\n getDisplayDetails() {\n let displayText = this.visibility + parseGenericTypes(this.id);\n if (this.memberType === \"method\") {\n displayText += `(${parseGenericTypes(this.parameters.trim())})`;\n if (this.returnType) {\n displayText += \" : \" + parseGenericTypes(this.returnType);\n }\n }\n displayText = displayText.trim();\n const cssStyle = this.parseClassifier();\n return {\n displayText,\n cssStyle\n };\n }\n parseMember(input) {\n let potentialClassifier = \"\";\n if (this.memberType === \"method\") {\n const methodRegEx = /([#+~-])?(.+)\\((.*)\\)([\\s$*])?(.*)([$*])?/;\n const match = input.match(methodRegEx);\n if (match) {\n const detectedVisibility = match[1] ? match[1].trim() : \"\";\n if (visibilityValues.includes(detectedVisibility)) {\n this.visibility = detectedVisibility;\n }\n this.id = match[2].trim();\n this.parameters = match[3] ? match[3].trim() : \"\";\n potentialClassifier = match[4] ? match[4].trim() : \"\";\n this.returnType = match[5] ? match[5].trim() : \"\";\n if (potentialClassifier === \"\") {\n const lastChar = this.returnType.substring(this.returnType.length - 1);\n if (lastChar.match(/[$*]/)) {\n potentialClassifier = lastChar;\n this.returnType = this.returnType.substring(0, this.returnType.length - 1);\n }\n }\n }\n } else {\n const length = input.length;\n const firstChar = input.substring(0, 1);\n const lastChar = input.substring(length - 1);\n if (visibilityValues.includes(firstChar)) {\n this.visibility = firstChar;\n }\n if (lastChar.match(/[*?]/)) {\n potentialClassifier = lastChar;\n }\n this.id = input.substring(\n this.visibility === \"\" ? 0 : 1,\n potentialClassifier === \"\" ? length : length - 1\n );\n }\n this.classifier = potentialClassifier;\n }\n parseClassifier() {\n switch (this.classifier) {\n case \"*\":\n return \"font-style:italic;\";\n case \"$\":\n return \"text-decoration:underline;\";\n default:\n return \"\";\n }\n }\n}\nconst MERMAID_DOM_ID_PREFIX = \"classId-\";\nlet relations = [];\nlet classes = {};\nlet notes = [];\nlet classCounter = 0;\nlet namespaces = {};\nlet namespaceCounter = 0;\nlet functions = [];\nconst sanitizeText = (txt) => common.sanitizeText(txt, getConfig());\nconst splitClassNameAndType = function(_id) {\n const id = common.sanitizeText(_id, getConfig());\n let genericType = \"\";\n let className = id;\n if (id.indexOf(\"~\") > 0) {\n const split = id.split(\"~\");\n className = sanitizeText(split[0]);\n genericType = sanitizeText(split[1]);\n }\n return { className, type: genericType };\n};\nconst setClassLabel = function(_id, label) {\n const id = common.sanitizeText(_id, getConfig());\n if (label) {\n label = sanitizeText(label);\n }\n const { className } = splitClassNameAndType(id);\n classes[className].label = label;\n};\nconst addClass = function(_id) {\n const id = common.sanitizeText(_id, getConfig());\n const { className, type } = splitClassNameAndType(id);\n if (Object.hasOwn(classes, className)) {\n return;\n }\n const name = common.sanitizeText(className, getConfig());\n classes[name] = {\n id: name,\n type,\n label: name,\n cssClasses: [],\n methods: [],\n members: [],\n annotations: [],\n domId: MERMAID_DOM_ID_PREFIX + name + \"-\" + classCounter\n };\n classCounter++;\n};\nconst lookUpDomId = function(_id) {\n const id = common.sanitizeText(_id, getConfig());\n if (id in classes) {\n return classes[id].domId;\n }\n throw new Error(\"Class not found: \" + id);\n};\nconst clear = function() {\n relations = [];\n classes = {};\n notes = [];\n functions = [];\n functions.push(setupToolTips);\n namespaces = {};\n namespaceCounter = 0;\n clear$1();\n};\nconst getClass = function(id) {\n return classes[id];\n};\nconst getClasses = function() {\n return classes;\n};\nconst getRelations = function() {\n return relations;\n};\nconst getNotes = function() {\n return notes;\n};\nconst addRelation = function(relation) {\n log.debug(\"Adding relation: \" + JSON.stringify(relation));\n addClass(relation.id1);\n addClass(relation.id2);\n relation.id1 = splitClassNameAndType(relation.id1).className;\n relation.id2 = splitClassNameAndType(relation.id2).className;\n relation.relationTitle1 = common.sanitizeText(relation.relationTitle1.trim(), getConfig());\n relation.relationTitle2 = common.sanitizeText(relation.relationTitle2.trim(), getConfig());\n relations.push(relation);\n};\nconst addAnnotation = function(className, annotation) {\n const validatedClassName = splitClassNameAndType(className).className;\n classes[validatedClassName].annotations.push(annotation);\n};\nconst addMember = function(className, member) {\n addClass(className);\n const validatedClassName = splitClassNameAndType(className).className;\n const theClass = classes[validatedClassName];\n if (typeof member === \"string\") {\n const memberString = member.trim();\n if (memberString.startsWith(\"<<\") && memberString.endsWith(\">>\")) {\n theClass.annotations.push(sanitizeText(memberString.substring(2, memberString.length - 2)));\n } else if (memberString.indexOf(\")\") > 0) {\n theClass.methods.push(new ClassMember(memberString, \"method\"));\n } else if (memberString) {\n theClass.members.push(new ClassMember(memberString, \"attribute\"));\n }\n }\n};\nconst addMembers = function(className, members) {\n if (Array.isArray(members)) {\n members.reverse();\n members.forEach((member) => addMember(className, member));\n }\n};\nconst addNote = function(text, className) {\n const note = {\n id: `note${notes.length}`,\n class: className,\n text\n };\n notes.push(note);\n};\nconst cleanupLabel = function(label) {\n if (label.startsWith(\":\")) {\n label = label.substring(1);\n }\n return sanitizeText(label.trim());\n};\nconst setCssClass = function(ids, className) {\n ids.split(\",\").forEach(function(_id) {\n let id = _id;\n if (_id[0].match(/\\d/)) {\n id = MERMAID_DOM_ID_PREFIX + id;\n }\n if (classes[id] !== void 0) {\n classes[id].cssClasses.push(className);\n }\n });\n};\nconst setTooltip = function(ids, tooltip) {\n ids.split(\",\").forEach(function(id) {\n if (tooltip !== void 0) {\n classes[id].tooltip = sanitizeText(tooltip);\n }\n });\n};\nconst getTooltip = function(id, namespace) {\n if (namespace) {\n return namespaces[namespace].classes[id].tooltip;\n }\n return classes[id].tooltip;\n};\nconst setLink = function(ids, linkStr, target) {\n const config = getConfig();\n ids.split(\",\").forEach(function(_id) {\n let id = _id;\n if (_id[0].match(/\\d/)) {\n id = MERMAID_DOM_ID_PREFIX + id;\n }\n if (classes[id] !== void 0) {\n classes[id].link = utils.formatUrl(linkStr, config);\n if (config.securityLevel === \"sandbox\") {\n classes[id].linkTarget = \"_top\";\n } else if (typeof target === \"string\") {\n classes[id].linkTarget = sanitizeText(target);\n } else {\n classes[id].linkTarget = \"_blank\";\n }\n }\n });\n setCssClass(ids, \"clickable\");\n};\nconst setClickEvent = function(ids, functionName, functionArgs) {\n ids.split(\",\").forEach(function(id) {\n setClickFunc(id, functionName, functionArgs);\n classes[id].haveCallback = true;\n });\n setCssClass(ids, \"clickable\");\n};\nconst setClickFunc = function(_domId, functionName, functionArgs) {\n const domId = common.sanitizeText(_domId, getConfig());\n const config = getConfig();\n if (config.securityLevel !== \"loose\") {\n return;\n }\n if (functionName === void 0) {\n return;\n }\n const id = domId;\n if (classes[id] !== void 0) {\n const elemId = lookUpDomId(id);\n let argList = [];\n if (typeof functionArgs === \"string\") {\n argList = functionArgs.split(/,(?=(?:(?:[^\"]*\"){2})*[^\"]*$)/);\n for (let i = 0; i < argList.length; i++) {\n let item = argList[i].trim();\n if (item.charAt(0) === '\"' && item.charAt(item.length - 1) === '\"') {\n item = item.substr(1, item.length - 2);\n }\n argList[i] = item;\n }\n }\n if (argList.length === 0) {\n argList.push(elemId);\n }\n functions.push(function() {\n const elem = document.querySelector(`[id=\"${elemId}\"]`);\n if (elem !== null) {\n elem.addEventListener(\n \"click\",\n function() {\n utils.runFunc(functionName, ...argList);\n },\n false\n );\n }\n });\n }\n};\nconst bindFunctions = function(element) {\n functions.forEach(function(fun) {\n fun(element);\n });\n};\nconst lineType = {\n LINE: 0,\n DOTTED_LINE: 1\n};\nconst relationType = {\n AGGREGATION: 0,\n EXTENSION: 1,\n COMPOSITION: 2,\n DEPENDENCY: 3,\n LOLLIPOP: 4\n};\nconst setupToolTips = function(element) {\n let tooltipElem = select(\".mermaidTooltip\");\n if ((tooltipElem._groups || tooltipElem)[0][0] === null) {\n tooltipElem = select(\"body\").append(\"div\").attr(\"class\", \"mermaidTooltip\").style(\"opacity\", 0);\n }\n const svg = select(element).select(\"svg\");\n const nodes = svg.selectAll(\"g.node\");\n nodes.on(\"mouseover\", function() {\n const el = select(this);\n const title = el.attr(\"title\");\n if (title === null) {\n return;\n }\n const rect = this.getBoundingClientRect();\n tooltipElem.transition().duration(200).style(\"opacity\", \".9\");\n tooltipElem.text(el.attr(\"title\")).style(\"left\", window.scrollX + rect.left + (rect.right - rect.left) / 2 + \"px\").style(\"top\", window.scrollY + rect.top - 14 + document.body.scrollTop + \"px\");\n tooltipElem.html(tooltipElem.html().replace(/<br\\/>/g, \"
      \"));\n el.classed(\"hover\", true);\n }).on(\"mouseout\", function() {\n tooltipElem.transition().duration(500).style(\"opacity\", 0);\n const el = select(this);\n el.classed(\"hover\", false);\n });\n};\nfunctions.push(setupToolTips);\nlet direction = \"TB\";\nconst getDirection = () => direction;\nconst setDirection = (dir) => {\n direction = dir;\n};\nconst addNamespace = function(id) {\n if (namespaces[id] !== void 0) {\n return;\n }\n namespaces[id] = {\n id,\n classes: {},\n children: {},\n domId: MERMAID_DOM_ID_PREFIX + id + \"-\" + namespaceCounter\n };\n namespaceCounter++;\n};\nconst getNamespace = function(name) {\n return namespaces[name];\n};\nconst getNamespaces = function() {\n return namespaces;\n};\nconst addClassesToNamespace = function(id, classNames) {\n if (namespaces[id] !== void 0) {\n classNames.map((className) => {\n classes[className].parent = id;\n namespaces[id].classes[className] = classes[className];\n });\n }\n};\nconst db = {\n setAccTitle,\n getAccTitle,\n getAccDescription,\n setAccDescription,\n getConfig: () => getConfig().class,\n addClass,\n bindFunctions,\n clear,\n getClass,\n getClasses,\n getNotes,\n addAnnotation,\n addNote,\n getRelations,\n addRelation,\n getDirection,\n setDirection,\n addMember,\n addMembers,\n cleanupLabel,\n lineType,\n relationType,\n setClickEvent,\n setCssClass,\n setLink,\n getTooltip,\n setTooltip,\n lookUpDomId,\n setDiagramTitle,\n getDiagramTitle,\n setClassLabel,\n addNamespace,\n addClassesToNamespace,\n getNamespace,\n getNamespaces\n};\nconst getStyles = (options) => `g.classGroup text {\n fill: ${options.nodeBorder || options.classText};\n stroke: none;\n font-family: ${options.fontFamily};\n font-size: 10px;\n\n .title {\n font-weight: bolder;\n }\n\n}\n\n.nodeLabel, .edgeLabel {\n color: ${options.classText};\n}\n.edgeLabel .label rect {\n fill: ${options.mainBkg};\n}\n.label text {\n fill: ${options.classText};\n}\n.edgeLabel .label span {\n background: ${options.mainBkg};\n}\n\n.classTitle {\n font-weight: bolder;\n}\n.node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n stroke-width: 1px;\n }\n\n\n.divider {\n stroke: ${options.nodeBorder};\n stroke-width: 1;\n}\n\ng.clickable {\n cursor: pointer;\n}\n\ng.classGroup rect {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n}\n\ng.classGroup line {\n stroke: ${options.nodeBorder};\n stroke-width: 1;\n}\n\n.classLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ${options.mainBkg};\n opacity: 0.5;\n}\n\n.classLabel .label {\n fill: ${options.nodeBorder};\n font-size: 10px;\n}\n\n.relation {\n stroke: ${options.lineColor};\n stroke-width: 1;\n fill: none;\n}\n\n.dashed-line{\n stroke-dasharray: 3;\n}\n\n.dotted-line{\n stroke-dasharray: 1 2;\n}\n\n#compositionStart, .composition {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#compositionEnd, .composition {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#extensionStart, .extension {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#extensionEnd, .extension {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#aggregationStart, .aggregation {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#aggregationEnd, .aggregation {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#lollipopStart, .lollipop {\n fill: ${options.mainBkg} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#lollipopEnd, .lollipop {\n fill: ${options.mainBkg} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n.edgeTerminals {\n font-size: 11px;\n}\n\n.classTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${options.textColor};\n}\n`;\nconst styles = getStyles;\nexport {\n db as d,\n parser$1 as p,\n styles as s\n};\n"], + "sources": ["../../node_modules/mermaid/dist/styles-4ba6ed67.js"], + "sourcesContent": ["import { select } from \"d3\";\nimport { d as sanitizeText$1, c as getConfig, v as parseGenericTypes, s as setAccTitle, g as getAccTitle, a as getAccDescription, b as setAccDescription, q as setDiagramTitle, r as getDiagramTitle, e as common, t as clear$1, l as log, u as utils } from \"./mermaid-934d9bea.js\";\nvar parser = function() {\n var o = function(k, v, o2, l) {\n for (o2 = o2 || {}, l = k.length; l--; o2[k[l]] = v)\n ;\n return o2;\n }, $V0 = [1, 16], $V1 = [1, 17], $V2 = [1, 18], $V3 = [1, 37], $V4 = [1, 38], $V5 = [1, 24], $V6 = [1, 22], $V7 = [1, 23], $V8 = [1, 29], $V9 = [1, 30], $Va = [1, 31], $Vb = [1, 32], $Vc = [1, 33], $Vd = [1, 34], $Ve = [1, 25], $Vf = [1, 26], $Vg = [1, 27], $Vh = [1, 28], $Vi = [1, 42], $Vj = [1, 39], $Vk = [1, 40], $Vl = [1, 41], $Vm = [1, 43], $Vn = [1, 9], $Vo = [1, 8, 9], $Vp = [1, 54], $Vq = [1, 55], $Vr = [1, 56], $Vs = [1, 57], $Vt = [1, 58], $Vu = [1, 59], $Vv = [1, 60], $Vw = [1, 8, 9, 38], $Vx = [1, 71], $Vy = [1, 8, 9, 12, 13, 21, 36, 38, 41, 58, 59, 60, 61, 62, 63, 64, 69, 71], $Vz = [1, 8, 9, 12, 13, 19, 21, 36, 38, 41, 45, 58, 59, 60, 61, 62, 63, 64, 69, 71, 84, 86, 87, 88, 89], $VA = [13, 84, 86, 87, 88, 89], $VB = [13, 63, 64, 84, 86, 87, 88, 89], $VC = [13, 58, 59, 60, 61, 62, 84, 86, 87, 88, 89], $VD = [1, 90], $VE = [1, 8, 9, 36, 38, 41], $VF = [1, 8, 9, 21];\n var parser2 = {\n trace: function trace() {\n },\n yy: {},\n symbols_: { \"error\": 2, \"start\": 3, \"mermaidDoc\": 4, \"statements\": 5, \"graphConfig\": 6, \"CLASS_DIAGRAM\": 7, \"NEWLINE\": 8, \"EOF\": 9, \"statement\": 10, \"classLabel\": 11, \"SQS\": 12, \"STR\": 13, \"SQE\": 14, \"namespaceName\": 15, \"alphaNumToken\": 16, \"className\": 17, \"classLiteralName\": 18, \"GENERICTYPE\": 19, \"relationStatement\": 20, \"LABEL\": 21, \"namespaceStatement\": 22, \"classStatement\": 23, \"memberStatement\": 24, \"annotationStatement\": 25, \"clickStatement\": 26, \"cssClassStatement\": 27, \"noteStatement\": 28, \"direction\": 29, \"acc_title\": 30, \"acc_title_value\": 31, \"acc_descr\": 32, \"acc_descr_value\": 33, \"acc_descr_multiline_value\": 34, \"namespaceIdentifier\": 35, \"STRUCT_START\": 36, \"classStatements\": 37, \"STRUCT_STOP\": 38, \"NAMESPACE\": 39, \"classIdentifier\": 40, \"STYLE_SEPARATOR\": 41, \"members\": 42, \"CLASS\": 43, \"ANNOTATION_START\": 44, \"ANNOTATION_END\": 45, \"MEMBER\": 46, \"SEPARATOR\": 47, \"relation\": 48, \"NOTE_FOR\": 49, \"noteText\": 50, \"NOTE\": 51, \"direction_tb\": 52, \"direction_bt\": 53, \"direction_rl\": 54, \"direction_lr\": 55, \"relationType\": 56, \"lineType\": 57, \"AGGREGATION\": 58, \"EXTENSION\": 59, \"COMPOSITION\": 60, \"DEPENDENCY\": 61, \"LOLLIPOP\": 62, \"LINE\": 63, \"DOTTED_LINE\": 64, \"CALLBACK\": 65, \"LINK\": 66, \"LINK_TARGET\": 67, \"CLICK\": 68, \"CALLBACK_NAME\": 69, \"CALLBACK_ARGS\": 70, \"HREF\": 71, \"CSSCLASS\": 72, \"commentToken\": 73, \"textToken\": 74, \"graphCodeTokens\": 75, \"textNoTagsToken\": 76, \"TAGSTART\": 77, \"TAGEND\": 78, \"==\": 79, \"--\": 80, \"PCT\": 81, \"DEFAULT\": 82, \"SPACE\": 83, \"MINUS\": 84, \"keywords\": 85, \"UNICODE_TEXT\": 86, \"NUM\": 87, \"ALPHA\": 88, \"BQUOTE_STR\": 89, \"$accept\": 0, \"$end\": 1 },\n terminals_: { 2: \"error\", 7: \"CLASS_DIAGRAM\", 8: \"NEWLINE\", 9: \"EOF\", 12: \"SQS\", 13: \"STR\", 14: \"SQE\", 19: \"GENERICTYPE\", 21: \"LABEL\", 30: \"acc_title\", 31: \"acc_title_value\", 32: \"acc_descr\", 33: \"acc_descr_value\", 34: \"acc_descr_multiline_value\", 36: \"STRUCT_START\", 38: \"STRUCT_STOP\", 39: \"NAMESPACE\", 41: \"STYLE_SEPARATOR\", 43: \"CLASS\", 44: \"ANNOTATION_START\", 45: \"ANNOTATION_END\", 46: \"MEMBER\", 47: \"SEPARATOR\", 49: \"NOTE_FOR\", 51: \"NOTE\", 52: \"direction_tb\", 53: \"direction_bt\", 54: \"direction_rl\", 55: \"direction_lr\", 58: \"AGGREGATION\", 59: \"EXTENSION\", 60: \"COMPOSITION\", 61: \"DEPENDENCY\", 62: \"LOLLIPOP\", 63: \"LINE\", 64: \"DOTTED_LINE\", 65: \"CALLBACK\", 66: \"LINK\", 67: \"LINK_TARGET\", 68: \"CLICK\", 69: \"CALLBACK_NAME\", 70: \"CALLBACK_ARGS\", 71: \"HREF\", 72: \"CSSCLASS\", 75: \"graphCodeTokens\", 77: \"TAGSTART\", 78: \"TAGEND\", 79: \"==\", 80: \"--\", 81: \"PCT\", 82: \"DEFAULT\", 83: \"SPACE\", 84: \"MINUS\", 85: \"keywords\", 86: \"UNICODE_TEXT\", 87: \"NUM\", 88: \"ALPHA\", 89: \"BQUOTE_STR\" },\n productions_: [0, [3, 1], [3, 1], [4, 1], [6, 4], [5, 1], [5, 2], [5, 3], [11, 3], [15, 1], [15, 2], [17, 1], [17, 1], [17, 2], [17, 2], [17, 2], [10, 1], [10, 2], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 1], [10, 2], [10, 2], [10, 1], [22, 4], [22, 5], [35, 2], [37, 1], [37, 2], [37, 3], [23, 1], [23, 3], [23, 4], [23, 6], [40, 2], [40, 3], [25, 4], [42, 1], [42, 2], [24, 1], [24, 2], [24, 1], [24, 1], [20, 3], [20, 4], [20, 4], [20, 5], [28, 3], [28, 2], [29, 1], [29, 1], [29, 1], [29, 1], [48, 3], [48, 2], [48, 2], [48, 1], [56, 1], [56, 1], [56, 1], [56, 1], [56, 1], [57, 1], [57, 1], [26, 3], [26, 4], [26, 3], [26, 4], [26, 4], [26, 5], [26, 3], [26, 4], [26, 4], [26, 5], [26, 4], [26, 5], [26, 5], [26, 6], [27, 3], [73, 1], [73, 1], [74, 1], [74, 1], [74, 1], [74, 1], [74, 1], [74, 1], [74, 1], [76, 1], [76, 1], [76, 1], [76, 1], [16, 1], [16, 1], [16, 1], [16, 1], [18, 1], [50, 1]],\n performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate, $$, _$) {\n var $0 = $$.length - 1;\n switch (yystate) {\n case 8:\n this.$ = $$[$0 - 1];\n break;\n case 9:\n case 11:\n case 12:\n this.$ = $$[$0];\n break;\n case 10:\n case 13:\n this.$ = $$[$0 - 1] + $$[$0];\n break;\n case 14:\n case 15:\n this.$ = $$[$0 - 1] + \"~\" + $$[$0] + \"~\";\n break;\n case 16:\n yy.addRelation($$[$0]);\n break;\n case 17:\n $$[$0 - 1].title = yy.cleanupLabel($$[$0]);\n yy.addRelation($$[$0 - 1]);\n break;\n case 26:\n this.$ = $$[$0].trim();\n yy.setAccTitle(this.$);\n break;\n case 27:\n case 28:\n this.$ = $$[$0].trim();\n yy.setAccDescription(this.$);\n break;\n case 29:\n yy.addClassesToNamespace($$[$0 - 3], $$[$0 - 1]);\n break;\n case 30:\n yy.addClassesToNamespace($$[$0 - 4], $$[$0 - 1]);\n break;\n case 31:\n this.$ = $$[$0];\n yy.addNamespace($$[$0]);\n break;\n case 32:\n this.$ = [$$[$0]];\n break;\n case 33:\n this.$ = [$$[$0 - 1]];\n break;\n case 34:\n $$[$0].unshift($$[$0 - 2]);\n this.$ = $$[$0];\n break;\n case 36:\n yy.setCssClass($$[$0 - 2], $$[$0]);\n break;\n case 37:\n yy.addMembers($$[$0 - 3], $$[$0 - 1]);\n break;\n case 38:\n yy.setCssClass($$[$0 - 5], $$[$0 - 3]);\n yy.addMembers($$[$0 - 5], $$[$0 - 1]);\n break;\n case 39:\n this.$ = $$[$0];\n yy.addClass($$[$0]);\n break;\n case 40:\n this.$ = $$[$0 - 1];\n yy.addClass($$[$0 - 1]);\n yy.setClassLabel($$[$0 - 1], $$[$0]);\n break;\n case 41:\n yy.addAnnotation($$[$0], $$[$0 - 2]);\n break;\n case 42:\n this.$ = [$$[$0]];\n break;\n case 43:\n $$[$0].push($$[$0 - 1]);\n this.$ = $$[$0];\n break;\n case 44:\n break;\n case 45:\n yy.addMember($$[$0 - 1], yy.cleanupLabel($$[$0]));\n break;\n case 46:\n break;\n case 47:\n break;\n case 48:\n this.$ = { \"id1\": $$[$0 - 2], \"id2\": $$[$0], relation: $$[$0 - 1], relationTitle1: \"none\", relationTitle2: \"none\" };\n break;\n case 49:\n this.$ = { id1: $$[$0 - 3], id2: $$[$0], relation: $$[$0 - 1], relationTitle1: $$[$0 - 2], relationTitle2: \"none\" };\n break;\n case 50:\n this.$ = { id1: $$[$0 - 3], id2: $$[$0], relation: $$[$0 - 2], relationTitle1: \"none\", relationTitle2: $$[$0 - 1] };\n break;\n case 51:\n this.$ = { id1: $$[$0 - 4], id2: $$[$0], relation: $$[$0 - 2], relationTitle1: $$[$0 - 3], relationTitle2: $$[$0 - 1] };\n break;\n case 52:\n yy.addNote($$[$0], $$[$0 - 1]);\n break;\n case 53:\n yy.addNote($$[$0]);\n break;\n case 54:\n yy.setDirection(\"TB\");\n break;\n case 55:\n yy.setDirection(\"BT\");\n break;\n case 56:\n yy.setDirection(\"RL\");\n break;\n case 57:\n yy.setDirection(\"LR\");\n break;\n case 58:\n this.$ = { type1: $$[$0 - 2], type2: $$[$0], lineType: $$[$0 - 1] };\n break;\n case 59:\n this.$ = { type1: \"none\", type2: $$[$0], lineType: $$[$0 - 1] };\n break;\n case 60:\n this.$ = { type1: $$[$0 - 1], type2: \"none\", lineType: $$[$0] };\n break;\n case 61:\n this.$ = { type1: \"none\", type2: \"none\", lineType: $$[$0] };\n break;\n case 62:\n this.$ = yy.relationType.AGGREGATION;\n break;\n case 63:\n this.$ = yy.relationType.EXTENSION;\n break;\n case 64:\n this.$ = yy.relationType.COMPOSITION;\n break;\n case 65:\n this.$ = yy.relationType.DEPENDENCY;\n break;\n case 66:\n this.$ = yy.relationType.LOLLIPOP;\n break;\n case 67:\n this.$ = yy.lineType.LINE;\n break;\n case 68:\n this.$ = yy.lineType.DOTTED_LINE;\n break;\n case 69:\n case 75:\n this.$ = $$[$0 - 2];\n yy.setClickEvent($$[$0 - 1], $$[$0]);\n break;\n case 70:\n case 76:\n this.$ = $$[$0 - 3];\n yy.setClickEvent($$[$0 - 2], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 2], $$[$0]);\n break;\n case 71:\n this.$ = $$[$0 - 2];\n yy.setLink($$[$0 - 1], $$[$0]);\n break;\n case 72:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 2], $$[$0 - 1], $$[$0]);\n break;\n case 73:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 2], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 2], $$[$0]);\n break;\n case 74:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 3], $$[$0 - 2], $$[$0]);\n yy.setTooltip($$[$0 - 3], $$[$0 - 1]);\n break;\n case 77:\n this.$ = $$[$0 - 3];\n yy.setClickEvent($$[$0 - 2], $$[$0 - 1], $$[$0]);\n break;\n case 78:\n this.$ = $$[$0 - 4];\n yy.setClickEvent($$[$0 - 3], $$[$0 - 2], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 79:\n this.$ = $$[$0 - 3];\n yy.setLink($$[$0 - 2], $$[$0]);\n break;\n case 80:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 3], $$[$0 - 1], $$[$0]);\n break;\n case 81:\n this.$ = $$[$0 - 4];\n yy.setLink($$[$0 - 3], $$[$0 - 1]);\n yy.setTooltip($$[$0 - 3], $$[$0]);\n break;\n case 82:\n this.$ = $$[$0 - 5];\n yy.setLink($$[$0 - 4], $$[$0 - 2], $$[$0]);\n yy.setTooltip($$[$0 - 4], $$[$0 - 1]);\n break;\n case 83:\n yy.setCssClass($$[$0 - 1], $$[$0]);\n break;\n }\n },\n table: [{ 3: 1, 4: 2, 5: 3, 6: 4, 7: [1, 6], 10: 5, 16: 35, 17: 19, 18: 36, 20: 7, 22: 8, 23: 9, 24: 10, 25: 11, 26: 12, 27: 13, 28: 14, 29: 15, 30: $V0, 32: $V1, 34: $V2, 35: 20, 39: $V3, 40: 21, 43: $V4, 44: $V5, 46: $V6, 47: $V7, 49: $V8, 51: $V9, 52: $Va, 53: $Vb, 54: $Vc, 55: $Vd, 65: $Ve, 66: $Vf, 68: $Vg, 72: $Vh, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 1: [3] }, { 1: [2, 1] }, { 1: [2, 2] }, { 1: [2, 3] }, o($Vn, [2, 5], { 8: [1, 44] }), { 8: [1, 45] }, o($Vo, [2, 16], { 21: [1, 46] }), o($Vo, [2, 18]), o($Vo, [2, 19]), o($Vo, [2, 20]), o($Vo, [2, 21]), o($Vo, [2, 22]), o($Vo, [2, 23]), o($Vo, [2, 24]), o($Vo, [2, 25]), { 31: [1, 47] }, { 33: [1, 48] }, o($Vo, [2, 28]), o($Vo, [2, 44], { 48: 49, 56: 52, 57: 53, 13: [1, 50], 21: [1, 51], 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt, 63: $Vu, 64: $Vv }), { 36: [1, 61] }, o($Vw, [2, 35], { 36: [1, 63], 41: [1, 62] }), o($Vo, [2, 46]), o($Vo, [2, 47]), { 16: 64, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 16: 35, 17: 65, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 16: 35, 17: 66, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 16: 35, 17: 67, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 13: [1, 68] }, { 16: 35, 17: 69, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 13: $Vx, 50: 70 }, o($Vo, [2, 54]), o($Vo, [2, 55]), o($Vo, [2, 56]), o($Vo, [2, 57]), o($Vy, [2, 11], { 16: 35, 18: 36, 17: 72, 19: [1, 73], 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }), o($Vy, [2, 12], { 19: [1, 74] }), { 15: 75, 16: 76, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 16: 35, 17: 77, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($Vz, [2, 97]), o($Vz, [2, 98]), o($Vz, [2, 99]), o($Vz, [2, 100]), o([1, 8, 9, 12, 13, 19, 21, 36, 38, 41, 58, 59, 60, 61, 62, 63, 64, 69, 71], [2, 101]), o($Vn, [2, 6], { 10: 5, 20: 7, 22: 8, 23: 9, 24: 10, 25: 11, 26: 12, 27: 13, 28: 14, 29: 15, 17: 19, 35: 20, 40: 21, 16: 35, 18: 36, 5: 78, 30: $V0, 32: $V1, 34: $V2, 39: $V3, 43: $V4, 44: $V5, 46: $V6, 47: $V7, 49: $V8, 51: $V9, 52: $Va, 53: $Vb, 54: $Vc, 55: $Vd, 65: $Ve, 66: $Vf, 68: $Vg, 72: $Vh, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }), { 5: 79, 10: 5, 16: 35, 17: 19, 18: 36, 20: 7, 22: 8, 23: 9, 24: 10, 25: 11, 26: 12, 27: 13, 28: 14, 29: 15, 30: $V0, 32: $V1, 34: $V2, 35: 20, 39: $V3, 40: 21, 43: $V4, 44: $V5, 46: $V6, 47: $V7, 49: $V8, 51: $V9, 52: $Va, 53: $Vb, 54: $Vc, 55: $Vd, 65: $Ve, 66: $Vf, 68: $Vg, 72: $Vh, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($Vo, [2, 17]), o($Vo, [2, 26]), o($Vo, [2, 27]), { 13: [1, 81], 16: 35, 17: 80, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 48: 82, 56: 52, 57: 53, 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt, 63: $Vu, 64: $Vv }, o($Vo, [2, 45]), { 57: 83, 63: $Vu, 64: $Vv }, o($VA, [2, 61], { 56: 84, 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt }), o($VB, [2, 62]), o($VB, [2, 63]), o($VB, [2, 64]), o($VB, [2, 65]), o($VB, [2, 66]), o($VC, [2, 67]), o($VC, [2, 68]), { 8: [1, 86], 23: 87, 37: 85, 40: 21, 43: $V4 }, { 16: 88, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 42: 89, 46: $VD }, { 45: [1, 91] }, { 13: [1, 92] }, { 13: [1, 93] }, { 69: [1, 94], 71: [1, 95] }, { 16: 96, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, { 13: $Vx, 50: 97 }, o($Vo, [2, 53]), o($Vo, [2, 102]), o($Vy, [2, 13]), o($Vy, [2, 14]), o($Vy, [2, 15]), { 36: [2, 31] }, { 15: 98, 16: 76, 36: [2, 9], 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl }, o($VE, [2, 39], { 11: 99, 12: [1, 100] }), o($Vn, [2, 7]), { 9: [1, 101] }, o($VF, [2, 48]), { 16: 35, 17: 102, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, { 13: [1, 104], 16: 35, 17: 103, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($VA, [2, 60], { 56: 105, 58: $Vp, 59: $Vq, 60: $Vr, 61: $Vs, 62: $Vt }), o($VA, [2, 59]), { 38: [1, 106] }, { 23: 87, 37: 107, 40: 21, 43: $V4 }, { 8: [1, 108], 38: [2, 32] }, o($Vw, [2, 36], { 36: [1, 109] }), { 38: [1, 110] }, { 38: [2, 42], 42: 111, 46: $VD }, { 16: 35, 17: 112, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($Vo, [2, 69], { 13: [1, 113] }), o($Vo, [2, 71], { 13: [1, 115], 67: [1, 114] }), o($Vo, [2, 75], { 13: [1, 116], 70: [1, 117] }), { 13: [1, 118] }, o($Vo, [2, 83]), o($Vo, [2, 52]), { 36: [2, 10] }, o($VE, [2, 40]), { 13: [1, 119] }, { 1: [2, 4] }, o($VF, [2, 50]), o($VF, [2, 49]), { 16: 35, 17: 120, 18: 36, 84: $Vi, 86: $Vj, 87: $Vk, 88: $Vl, 89: $Vm }, o($VA, [2, 58]), o($Vo, [2, 29]), { 38: [1, 121] }, { 23: 87, 37: 122, 38: [2, 33], 40: 21, 43: $V4 }, { 42: 123, 46: $VD }, o($Vw, [2, 37]), { 38: [2, 43] }, o($Vo, [2, 41]), o($Vo, [2, 70]), o($Vo, [2, 72]), o($Vo, [2, 73], { 67: [1, 124] }), o($Vo, [2, 76]), o($Vo, [2, 77], { 13: [1, 125] }), o($Vo, [2, 79], { 13: [1, 127], 67: [1, 126] }), { 14: [1, 128] }, o($VF, [2, 51]), o($Vo, [2, 30]), { 38: [2, 34] }, { 38: [1, 129] }, o($Vo, [2, 74]), o($Vo, [2, 78]), o($Vo, [2, 80]), o($Vo, [2, 81], { 67: [1, 130] }), o($VE, [2, 8]), o($Vw, [2, 38]), o($Vo, [2, 82])],\n defaultActions: { 2: [2, 1], 3: [2, 2], 4: [2, 3], 75: [2, 31], 98: [2, 10], 101: [2, 4], 111: [2, 43], 122: [2, 34] },\n parseError: function parseError(str, hash) {\n if (hash.recoverable) {\n this.trace(str);\n } else {\n var error = new Error(str);\n error.hash = hash;\n throw error;\n }\n },\n parse: function parse(input) {\n var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = \"\", yylineno = 0, yyleng = 0, TERROR = 2, EOF = 1;\n var args = lstack.slice.call(arguments, 1);\n var lexer2 = Object.create(this.lexer);\n var sharedState = { yy: {} };\n for (var k in this.yy) {\n if (Object.prototype.hasOwnProperty.call(this.yy, k)) {\n sharedState.yy[k] = this.yy[k];\n }\n }\n lexer2.setInput(input, sharedState.yy);\n sharedState.yy.lexer = lexer2;\n sharedState.yy.parser = this;\n if (typeof lexer2.yylloc == \"undefined\") {\n lexer2.yylloc = {};\n }\n var yyloc = lexer2.yylloc;\n lstack.push(yyloc);\n var ranges = lexer2.options && lexer2.options.ranges;\n if (typeof sharedState.yy.parseError === \"function\") {\n this.parseError = sharedState.yy.parseError;\n } else {\n this.parseError = Object.getPrototypeOf(this).parseError;\n }\n function lex() {\n var token;\n token = tstack.pop() || lexer2.lex() || EOF;\n if (typeof token !== \"number\") {\n if (token instanceof Array) {\n tstack = token;\n token = tstack.pop();\n }\n token = self.symbols_[token] || token;\n }\n return token;\n }\n var symbol, state, action, r, yyval = {}, p, len, newState, expected;\n while (true) {\n state = stack[stack.length - 1];\n if (this.defaultActions[state]) {\n action = this.defaultActions[state];\n } else {\n if (symbol === null || typeof symbol == \"undefined\") {\n symbol = lex();\n }\n action = table[state] && table[state][symbol];\n }\n if (typeof action === \"undefined\" || !action.length || !action[0]) {\n var errStr = \"\";\n expected = [];\n for (p in table[state]) {\n if (this.terminals_[p] && p > TERROR) {\n expected.push(\"'\" + this.terminals_[p] + \"'\");\n }\n }\n if (lexer2.showPosition) {\n errStr = \"Parse error on line \" + (yylineno + 1) + \":\\n\" + lexer2.showPosition() + \"\\nExpecting \" + expected.join(\", \") + \", got '\" + (this.terminals_[symbol] || symbol) + \"'\";\n } else {\n errStr = \"Parse error on line \" + (yylineno + 1) + \": Unexpected \" + (symbol == EOF ? \"end of input\" : \"'\" + (this.terminals_[symbol] || symbol) + \"'\");\n }\n this.parseError(errStr, {\n text: lexer2.match,\n token: this.terminals_[symbol] || symbol,\n line: lexer2.yylineno,\n loc: yyloc,\n expected\n });\n }\n if (action[0] instanceof Array && action.length > 1) {\n throw new Error(\"Parse Error: multiple actions possible at state: \" + state + \", token: \" + symbol);\n }\n switch (action[0]) {\n case 1:\n stack.push(symbol);\n vstack.push(lexer2.yytext);\n lstack.push(lexer2.yylloc);\n stack.push(action[1]);\n symbol = null;\n {\n yyleng = lexer2.yyleng;\n yytext = lexer2.yytext;\n yylineno = lexer2.yylineno;\n yyloc = lexer2.yylloc;\n }\n break;\n case 2:\n len = this.productions_[action[1]][1];\n yyval.$ = vstack[vstack.length - len];\n yyval._$ = {\n first_line: lstack[lstack.length - (len || 1)].first_line,\n last_line: lstack[lstack.length - 1].last_line,\n first_column: lstack[lstack.length - (len || 1)].first_column,\n last_column: lstack[lstack.length - 1].last_column\n };\n if (ranges) {\n yyval._$.range = [\n lstack[lstack.length - (len || 1)].range[0],\n lstack[lstack.length - 1].range[1]\n ];\n }\n r = this.performAction.apply(yyval, [\n yytext,\n yyleng,\n yylineno,\n sharedState.yy,\n action[1],\n vstack,\n lstack\n ].concat(args));\n if (typeof r !== \"undefined\") {\n return r;\n }\n if (len) {\n stack = stack.slice(0, -1 * len * 2);\n vstack = vstack.slice(0, -1 * len);\n lstack = lstack.slice(0, -1 * len);\n }\n stack.push(this.productions_[action[1]][0]);\n vstack.push(yyval.$);\n lstack.push(yyval._$);\n newState = table[stack[stack.length - 2]][stack[stack.length - 1]];\n stack.push(newState);\n break;\n case 3:\n return true;\n }\n }\n return true;\n }\n };\n var lexer = function() {\n var lexer2 = {\n EOF: 1,\n parseError: function parseError(str, hash) {\n if (this.yy.parser) {\n this.yy.parser.parseError(str, hash);\n } else {\n throw new Error(str);\n }\n },\n // resets the lexer, sets new input\n setInput: function(input, yy) {\n this.yy = yy || this.yy || {};\n this._input = input;\n this._more = this._backtrack = this.done = false;\n this.yylineno = this.yyleng = 0;\n this.yytext = this.matched = this.match = \"\";\n this.conditionStack = [\"INITIAL\"];\n this.yylloc = {\n first_line: 1,\n first_column: 0,\n last_line: 1,\n last_column: 0\n };\n if (this.options.ranges) {\n this.yylloc.range = [0, 0];\n }\n this.offset = 0;\n return this;\n },\n // consumes and returns one char from the input\n input: function() {\n var ch = this._input[0];\n this.yytext += ch;\n this.yyleng++;\n this.offset++;\n this.match += ch;\n this.matched += ch;\n var lines = ch.match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno++;\n this.yylloc.last_line++;\n } else {\n this.yylloc.last_column++;\n }\n if (this.options.ranges) {\n this.yylloc.range[1]++;\n }\n this._input = this._input.slice(1);\n return ch;\n },\n // unshifts one char (or a string) into the input\n unput: function(ch) {\n var len = ch.length;\n var lines = ch.split(/(?:\\r\\n?|\\n)/g);\n this._input = ch + this._input;\n this.yytext = this.yytext.substr(0, this.yytext.length - len);\n this.offset -= len;\n var oldLines = this.match.split(/(?:\\r\\n?|\\n)/g);\n this.match = this.match.substr(0, this.match.length - 1);\n this.matched = this.matched.substr(0, this.matched.length - 1);\n if (lines.length - 1) {\n this.yylineno -= lines.length - 1;\n }\n var r = this.yylloc.range;\n this.yylloc = {\n first_line: this.yylloc.first_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.first_column,\n last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len\n };\n if (this.options.ranges) {\n this.yylloc.range = [r[0], r[0] + this.yyleng - len];\n }\n this.yyleng = this.yytext.length;\n return this;\n },\n // When called from action, caches matched text and appends it on next action\n more: function() {\n this._more = true;\n return this;\n },\n // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.\n reject: function() {\n if (this.options.backtrack_lexer) {\n this._backtrack = true;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n return this;\n },\n // retain first n characters of the match\n less: function(n) {\n this.unput(this.match.slice(n));\n },\n // displays already matched input, i.e. for error messages\n pastInput: function() {\n var past = this.matched.substr(0, this.matched.length - this.match.length);\n return (past.length > 20 ? \"...\" : \"\") + past.substr(-20).replace(/\\n/g, \"\");\n },\n // displays upcoming input, i.e. for error messages\n upcomingInput: function() {\n var next = this.match;\n if (next.length < 20) {\n next += this._input.substr(0, 20 - next.length);\n }\n return (next.substr(0, 20) + (next.length > 20 ? \"...\" : \"\")).replace(/\\n/g, \"\");\n },\n // displays the character position where the lexing error occurred, i.e. for error messages\n showPosition: function() {\n var pre = this.pastInput();\n var c = new Array(pre.length + 1).join(\"-\");\n return pre + this.upcomingInput() + \"\\n\" + c + \"^\";\n },\n // test the lexed token: return FALSE when not a match, otherwise return token\n test_match: function(match, indexed_rule) {\n var token, lines, backup;\n if (this.options.backtrack_lexer) {\n backup = {\n yylineno: this.yylineno,\n yylloc: {\n first_line: this.yylloc.first_line,\n last_line: this.last_line,\n first_column: this.yylloc.first_column,\n last_column: this.yylloc.last_column\n },\n yytext: this.yytext,\n match: this.match,\n matches: this.matches,\n matched: this.matched,\n yyleng: this.yyleng,\n offset: this.offset,\n _more: this._more,\n _input: this._input,\n yy: this.yy,\n conditionStack: this.conditionStack.slice(0),\n done: this.done\n };\n if (this.options.ranges) {\n backup.yylloc.range = this.yylloc.range.slice(0);\n }\n }\n lines = match[0].match(/(?:\\r\\n?|\\n).*/g);\n if (lines) {\n this.yylineno += lines.length;\n }\n this.yylloc = {\n first_line: this.yylloc.last_line,\n last_line: this.yylineno + 1,\n first_column: this.yylloc.last_column,\n last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\\r?\\n?/)[0].length : this.yylloc.last_column + match[0].length\n };\n this.yytext += match[0];\n this.match += match[0];\n this.matches = match;\n this.yyleng = this.yytext.length;\n if (this.options.ranges) {\n this.yylloc.range = [this.offset, this.offset += this.yyleng];\n }\n this._more = false;\n this._backtrack = false;\n this._input = this._input.slice(match[0].length);\n this.matched += match[0];\n token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);\n if (this.done && this._input) {\n this.done = false;\n }\n if (token) {\n return token;\n } else if (this._backtrack) {\n for (var k in backup) {\n this[k] = backup[k];\n }\n return false;\n }\n return false;\n },\n // return next match in input\n next: function() {\n if (this.done) {\n return this.EOF;\n }\n if (!this._input) {\n this.done = true;\n }\n var token, match, tempMatch, index;\n if (!this._more) {\n this.yytext = \"\";\n this.match = \"\";\n }\n var rules = this._currentRules();\n for (var i = 0; i < rules.length; i++) {\n tempMatch = this._input.match(this.rules[rules[i]]);\n if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {\n match = tempMatch;\n index = i;\n if (this.options.backtrack_lexer) {\n token = this.test_match(tempMatch, rules[i]);\n if (token !== false) {\n return token;\n } else if (this._backtrack) {\n match = false;\n continue;\n } else {\n return false;\n }\n } else if (!this.options.flex) {\n break;\n }\n }\n }\n if (match) {\n token = this.test_match(match, rules[index]);\n if (token !== false) {\n return token;\n }\n return false;\n }\n if (this._input === \"\") {\n return this.EOF;\n } else {\n return this.parseError(\"Lexical error on line \" + (this.yylineno + 1) + \". Unrecognized text.\\n\" + this.showPosition(), {\n text: \"\",\n token: null,\n line: this.yylineno\n });\n }\n },\n // return next match that has a token\n lex: function lex() {\n var r = this.next();\n if (r) {\n return r;\n } else {\n return this.lex();\n }\n },\n // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)\n begin: function begin(condition) {\n this.conditionStack.push(condition);\n },\n // pop the previously active lexer condition state off the condition stack\n popState: function popState() {\n var n = this.conditionStack.length - 1;\n if (n > 0) {\n return this.conditionStack.pop();\n } else {\n return this.conditionStack[0];\n }\n },\n // produce the lexer rule set which is active for the currently active lexer condition state\n _currentRules: function _currentRules() {\n if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {\n return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;\n } else {\n return this.conditions[\"INITIAL\"].rules;\n }\n },\n // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available\n topState: function topState(n) {\n n = this.conditionStack.length - 1 - Math.abs(n || 0);\n if (n >= 0) {\n return this.conditionStack[n];\n } else {\n return \"INITIAL\";\n }\n },\n // alias for begin(condition)\n pushState: function pushState(condition) {\n this.begin(condition);\n },\n // return the number of states currently on the stack\n stateStackSize: function stateStackSize() {\n return this.conditionStack.length;\n },\n options: {},\n performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {\n switch ($avoiding_name_collisions) {\n case 0:\n return 52;\n case 1:\n return 53;\n case 2:\n return 54;\n case 3:\n return 55;\n case 4:\n break;\n case 5:\n break;\n case 6:\n this.begin(\"acc_title\");\n return 30;\n case 7:\n this.popState();\n return \"acc_title_value\";\n case 8:\n this.begin(\"acc_descr\");\n return 32;\n case 9:\n this.popState();\n return \"acc_descr_value\";\n case 10:\n this.begin(\"acc_descr_multiline\");\n break;\n case 11:\n this.popState();\n break;\n case 12:\n return \"acc_descr_multiline_value\";\n case 13:\n return 8;\n case 14:\n break;\n case 15:\n return 7;\n case 16:\n return 7;\n case 17:\n return \"EDGE_STATE\";\n case 18:\n this.begin(\"callback_name\");\n break;\n case 19:\n this.popState();\n break;\n case 20:\n this.popState();\n this.begin(\"callback_args\");\n break;\n case 21:\n return 69;\n case 22:\n this.popState();\n break;\n case 23:\n return 70;\n case 24:\n this.popState();\n break;\n case 25:\n return \"STR\";\n case 26:\n this.begin(\"string\");\n break;\n case 27:\n this.begin(\"namespace\");\n return 39;\n case 28:\n this.popState();\n return 8;\n case 29:\n break;\n case 30:\n this.begin(\"namespace-body\");\n return 36;\n case 31:\n this.popState();\n return 38;\n case 32:\n return \"EOF_IN_STRUCT\";\n case 33:\n return 8;\n case 34:\n break;\n case 35:\n return \"EDGE_STATE\";\n case 36:\n this.begin(\"class\");\n return 43;\n case 37:\n this.popState();\n return 8;\n case 38:\n break;\n case 39:\n this.popState();\n this.popState();\n return 38;\n case 40:\n this.begin(\"class-body\");\n return 36;\n case 41:\n this.popState();\n return 38;\n case 42:\n return \"EOF_IN_STRUCT\";\n case 43:\n return \"EDGE_STATE\";\n case 44:\n return \"OPEN_IN_STRUCT\";\n case 45:\n break;\n case 46:\n return \"MEMBER\";\n case 47:\n return 72;\n case 48:\n return 65;\n case 49:\n return 66;\n case 50:\n return 68;\n case 51:\n return 49;\n case 52:\n return 51;\n case 53:\n return 44;\n case 54:\n return 45;\n case 55:\n return 71;\n case 56:\n this.popState();\n break;\n case 57:\n return \"GENERICTYPE\";\n case 58:\n this.begin(\"generic\");\n break;\n case 59:\n this.popState();\n break;\n case 60:\n return \"BQUOTE_STR\";\n case 61:\n this.begin(\"bqstring\");\n break;\n case 62:\n return 67;\n case 63:\n return 67;\n case 64:\n return 67;\n case 65:\n return 67;\n case 66:\n return 59;\n case 67:\n return 59;\n case 68:\n return 61;\n case 69:\n return 61;\n case 70:\n return 60;\n case 71:\n return 58;\n case 72:\n return 62;\n case 73:\n return 63;\n case 74:\n return 64;\n case 75:\n return 21;\n case 76:\n return 41;\n case 77:\n return 84;\n case 78:\n return \"DOT\";\n case 79:\n return \"PLUS\";\n case 80:\n return 81;\n case 81:\n return \"EQUALS\";\n case 82:\n return \"EQUALS\";\n case 83:\n return 88;\n case 84:\n return 12;\n case 85:\n return 14;\n case 86:\n return \"PUNCTUATION\";\n case 87:\n return 87;\n case 88:\n return 86;\n case 89:\n return 83;\n case 90:\n return 9;\n }\n },\n rules: [/^(?:.*direction\\s+TB[^\\n]*)/, /^(?:.*direction\\s+BT[^\\n]*)/, /^(?:.*direction\\s+RL[^\\n]*)/, /^(?:.*direction\\s+LR[^\\n]*)/, /^(?:%%(?!\\{)*[^\\n]*(\\r?\\n?)+)/, /^(?:%%[^\\n]*(\\r?\\n)*)/, /^(?:accTitle\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*:\\s*)/, /^(?:(?!\\n||)*[^\\n]*)/, /^(?:accDescr\\s*\\{\\s*)/, /^(?:[\\}])/, /^(?:[^\\}]*)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:classDiagram-v2\\b)/, /^(?:classDiagram\\b)/, /^(?:\\[\\*\\])/, /^(?:call[\\s]+)/, /^(?:\\([\\s]*\\))/, /^(?:\\()/, /^(?:[^(]*)/, /^(?:\\))/, /^(?:[^)]*)/, /^(?:[\"])/, /^(?:[^\"]*)/, /^(?:[\"])/, /^(?:namespace\\b)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:[{])/, /^(?:[}])/, /^(?:$)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:\\[\\*\\])/, /^(?:class\\b)/, /^(?:\\s*(\\r?\\n)+)/, /^(?:\\s+)/, /^(?:[}])/, /^(?:[{])/, /^(?:[}])/, /^(?:$)/, /^(?:\\[\\*\\])/, /^(?:[{])/, /^(?:[\\n])/, /^(?:[^{}\\n]*)/, /^(?:cssClass\\b)/, /^(?:callback\\b)/, /^(?:link\\b)/, /^(?:click\\b)/, /^(?:note for\\b)/, /^(?:note\\b)/, /^(?:<<)/, /^(?:>>)/, /^(?:href\\b)/, /^(?:[~])/, /^(?:[^~]*)/, /^(?:~)/, /^(?:[`])/, /^(?:[^`]+)/, /^(?:[`])/, /^(?:_self\\b)/, /^(?:_blank\\b)/, /^(?:_parent\\b)/, /^(?:_top\\b)/, /^(?:\\s*<\\|)/, /^(?:\\s*\\|>)/, /^(?:\\s*>)/, /^(?:\\s*<)/, /^(?:\\s*\\*)/, /^(?:\\s*o\\b)/, /^(?:\\s*\\(\\))/, /^(?:--)/, /^(?:\\.\\.)/, /^(?::{1}[^:\\n;]+)/, /^(?::{3})/, /^(?:-)/, /^(?:\\.)/, /^(?:\\+)/, /^(?:%)/, /^(?:=)/, /^(?:=)/, /^(?:\\w+)/, /^(?:\\[)/, /^(?:\\])/, /^(?:[!\"#$%&'*+,-.`?\\\\/])/, /^(?:[0-9]+)/, /^(?:[\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6]|[\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377]|[\\u037A-\\u037D\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5]|[\\u03F7-\\u0481\\u048A-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA]|[\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE]|[\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA]|[\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u08A0]|[\\u08A2-\\u08AC\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0977]|[\\u0979-\\u097F\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2]|[\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A]|[\\u0A0F\\u0A10\\u0A13-\\u0A28\\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B3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6]|[\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A]|[\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081]|[\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D]|[\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0]|[\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310]|[\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C]|[\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u1700-\\u170C\\u170E-\\u1711]|[\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7]|[\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191C]|[\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19C1-\\u19C7\\u1A00-\\u1A16]|[\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF]|[\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1CE9-\\u1CEC]|[\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D]|[\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D]|[\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3]|[\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F]|[\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128]|[\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184]|[\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3]|[\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6]|[\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE]|[\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C]|[\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D]|[\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC]|[\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B]|[\\uA640-\\uA66E\\uA67F-\\uA697\\uA6A0-\\uA6E5\\uA717-\\uA71F\\uA722-\\uA788]|[\\uA78B-\\uA78E\\uA790-\\uA793\\uA7A0-\\uA7AA\\uA7F8-\\uA801\\uA803-\\uA805]|[\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB]|[\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uAA00-\\uAA28]|[\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA80-\\uAAAF\\uAAB1\\uAAB5]|[\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4]|[\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E]|[\\uABC0-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D]|[\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36]|[\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D]|[\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC]|[\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF]|[\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC])/, /^(?:\\s)/, /^(?:$)/],\n conditions: { \"namespace-body\": { \"rules\": [26, 31, 32, 33, 34, 35, 36, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"namespace\": { \"rules\": [26, 27, 28, 29, 30, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"class-body\": { \"rules\": [26, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"class\": { \"rules\": [26, 37, 38, 39, 40, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"acc_descr_multiline\": { \"rules\": [11, 12, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"acc_descr\": { \"rules\": [9, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"acc_title\": { \"rules\": [7, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"callback_args\": { \"rules\": [22, 23, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"callback_name\": { \"rules\": [19, 20, 21, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"href\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"struct\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"generic\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"bqstring\": { \"rules\": [26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"string\": { \"rules\": [24, 25, 26, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": false }, \"INITIAL\": { \"rules\": [0, 1, 2, 3, 4, 5, 6, 8, 10, 13, 14, 15, 16, 17, 18, 26, 27, 36, 47, 48, 49, 50, 51, 52, 53, 54, 55, 58, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90], \"inclusive\": true } }\n };\n return lexer2;\n }();\n parser2.lexer = lexer;\n function Parser() {\n this.yy = {};\n }\n Parser.prototype = parser2;\n parser2.Parser = Parser;\n return new Parser();\n}();\nparser.parser = parser;\nconst parser$1 = parser;\nconst visibilityValues = [\"#\", \"+\", \"~\", \"-\", \"\"];\nclass ClassMember {\n constructor(input, memberType) {\n this.memberType = memberType;\n this.visibility = \"\";\n this.classifier = \"\";\n const sanitizedInput = sanitizeText$1(input, getConfig());\n this.parseMember(sanitizedInput);\n }\n getDisplayDetails() {\n let displayText = this.visibility + parseGenericTypes(this.id);\n if (this.memberType === \"method\") {\n displayText += `(${parseGenericTypes(this.parameters.trim())})`;\n if (this.returnType) {\n displayText += \" : \" + parseGenericTypes(this.returnType);\n }\n }\n displayText = displayText.trim();\n const cssStyle = this.parseClassifier();\n return {\n displayText,\n cssStyle\n };\n }\n parseMember(input) {\n let potentialClassifier = \"\";\n if (this.memberType === \"method\") {\n const methodRegEx = /([#+~-])?(.+)\\((.*)\\)([\\s$*])?(.*)([$*])?/;\n const match = input.match(methodRegEx);\n if (match) {\n const detectedVisibility = match[1] ? match[1].trim() : \"\";\n if (visibilityValues.includes(detectedVisibility)) {\n this.visibility = detectedVisibility;\n }\n this.id = match[2].trim();\n this.parameters = match[3] ? match[3].trim() : \"\";\n potentialClassifier = match[4] ? match[4].trim() : \"\";\n this.returnType = match[5] ? match[5].trim() : \"\";\n if (potentialClassifier === \"\") {\n const lastChar = this.returnType.substring(this.returnType.length - 1);\n if (lastChar.match(/[$*]/)) {\n potentialClassifier = lastChar;\n this.returnType = this.returnType.substring(0, this.returnType.length - 1);\n }\n }\n }\n } else {\n const length = input.length;\n const firstChar = input.substring(0, 1);\n const lastChar = input.substring(length - 1);\n if (visibilityValues.includes(firstChar)) {\n this.visibility = firstChar;\n }\n if (lastChar.match(/[*?]/)) {\n potentialClassifier = lastChar;\n }\n this.id = input.substring(\n this.visibility === \"\" ? 0 : 1,\n potentialClassifier === \"\" ? length : length - 1\n );\n }\n this.classifier = potentialClassifier;\n }\n parseClassifier() {\n switch (this.classifier) {\n case \"*\":\n return \"font-style:italic;\";\n case \"$\":\n return \"text-decoration:underline;\";\n default:\n return \"\";\n }\n }\n}\nconst MERMAID_DOM_ID_PREFIX = \"classId-\";\nlet relations = [];\nlet classes = {};\nlet notes = [];\nlet classCounter = 0;\nlet namespaces = {};\nlet namespaceCounter = 0;\nlet functions = [];\nconst sanitizeText = (txt) => common.sanitizeText(txt, getConfig());\nconst splitClassNameAndType = function(_id) {\n const id = common.sanitizeText(_id, getConfig());\n let genericType = \"\";\n let className = id;\n if (id.indexOf(\"~\") > 0) {\n const split = id.split(\"~\");\n className = sanitizeText(split[0]);\n genericType = sanitizeText(split[1]);\n }\n return { className, type: genericType };\n};\nconst setClassLabel = function(_id, label) {\n const id = common.sanitizeText(_id, getConfig());\n if (label) {\n label = sanitizeText(label);\n }\n const { className } = splitClassNameAndType(id);\n classes[className].label = label;\n};\nconst addClass = function(_id) {\n const id = common.sanitizeText(_id, getConfig());\n const { className, type } = splitClassNameAndType(id);\n if (Object.hasOwn(classes, className)) {\n return;\n }\n const name = common.sanitizeText(className, getConfig());\n classes[name] = {\n id: name,\n type,\n label: name,\n cssClasses: [],\n methods: [],\n members: [],\n annotations: [],\n domId: MERMAID_DOM_ID_PREFIX + name + \"-\" + classCounter\n };\n classCounter++;\n};\nconst lookUpDomId = function(_id) {\n const id = common.sanitizeText(_id, getConfig());\n if (id in classes) {\n return classes[id].domId;\n }\n throw new Error(\"Class not found: \" + id);\n};\nconst clear = function() {\n relations = [];\n classes = {};\n notes = [];\n functions = [];\n functions.push(setupToolTips);\n namespaces = {};\n namespaceCounter = 0;\n clear$1();\n};\nconst getClass = function(id) {\n return classes[id];\n};\nconst getClasses = function() {\n return classes;\n};\nconst getRelations = function() {\n return relations;\n};\nconst getNotes = function() {\n return notes;\n};\nconst addRelation = function(relation) {\n log.debug(\"Adding relation: \" + JSON.stringify(relation));\n addClass(relation.id1);\n addClass(relation.id2);\n relation.id1 = splitClassNameAndType(relation.id1).className;\n relation.id2 = splitClassNameAndType(relation.id2).className;\n relation.relationTitle1 = common.sanitizeText(relation.relationTitle1.trim(), getConfig());\n relation.relationTitle2 = common.sanitizeText(relation.relationTitle2.trim(), getConfig());\n relations.push(relation);\n};\nconst addAnnotation = function(className, annotation) {\n const validatedClassName = splitClassNameAndType(className).className;\n classes[validatedClassName].annotations.push(annotation);\n};\nconst addMember = function(className, member) {\n addClass(className);\n const validatedClassName = splitClassNameAndType(className).className;\n const theClass = classes[validatedClassName];\n if (typeof member === \"string\") {\n const memberString = member.trim();\n if (memberString.startsWith(\"<<\") && memberString.endsWith(\">>\")) {\n theClass.annotations.push(sanitizeText(memberString.substring(2, memberString.length - 2)));\n } else if (memberString.indexOf(\")\") > 0) {\n theClass.methods.push(new ClassMember(memberString, \"method\"));\n } else if (memberString) {\n theClass.members.push(new ClassMember(memberString, \"attribute\"));\n }\n }\n};\nconst addMembers = function(className, members) {\n if (Array.isArray(members)) {\n members.reverse();\n members.forEach((member) => addMember(className, member));\n }\n};\nconst addNote = function(text, className) {\n const note = {\n id: `note${notes.length}`,\n class: className,\n text\n };\n notes.push(note);\n};\nconst cleanupLabel = function(label) {\n if (label.startsWith(\":\")) {\n label = label.substring(1);\n }\n return sanitizeText(label.trim());\n};\nconst setCssClass = function(ids, className) {\n ids.split(\",\").forEach(function(_id) {\n let id = _id;\n if (_id[0].match(/\\d/)) {\n id = MERMAID_DOM_ID_PREFIX + id;\n }\n if (classes[id] !== void 0) {\n classes[id].cssClasses.push(className);\n }\n });\n};\nconst setTooltip = function(ids, tooltip) {\n ids.split(\",\").forEach(function(id) {\n if (tooltip !== void 0) {\n classes[id].tooltip = sanitizeText(tooltip);\n }\n });\n};\nconst getTooltip = function(id, namespace) {\n if (namespace) {\n return namespaces[namespace].classes[id].tooltip;\n }\n return classes[id].tooltip;\n};\nconst setLink = function(ids, linkStr, target) {\n const config = getConfig();\n ids.split(\",\").forEach(function(_id) {\n let id = _id;\n if (_id[0].match(/\\d/)) {\n id = MERMAID_DOM_ID_PREFIX + id;\n }\n if (classes[id] !== void 0) {\n classes[id].link = utils.formatUrl(linkStr, config);\n if (config.securityLevel === \"sandbox\") {\n classes[id].linkTarget = \"_top\";\n } else if (typeof target === \"string\") {\n classes[id].linkTarget = sanitizeText(target);\n } else {\n classes[id].linkTarget = \"_blank\";\n }\n }\n });\n setCssClass(ids, \"clickable\");\n};\nconst setClickEvent = function(ids, functionName, functionArgs) {\n ids.split(\",\").forEach(function(id) {\n setClickFunc(id, functionName, functionArgs);\n classes[id].haveCallback = true;\n });\n setCssClass(ids, \"clickable\");\n};\nconst setClickFunc = function(_domId, functionName, functionArgs) {\n const domId = common.sanitizeText(_domId, getConfig());\n const config = getConfig();\n if (config.securityLevel !== \"loose\") {\n return;\n }\n if (functionName === void 0) {\n return;\n }\n const id = domId;\n if (classes[id] !== void 0) {\n const elemId = lookUpDomId(id);\n let argList = [];\n if (typeof functionArgs === \"string\") {\n argList = functionArgs.split(/,(?=(?:(?:[^\"]*\"){2})*[^\"]*$)/);\n for (let i = 0; i < argList.length; i++) {\n let item = argList[i].trim();\n if (item.charAt(0) === '\"' && item.charAt(item.length - 1) === '\"') {\n item = item.substr(1, item.length - 2);\n }\n argList[i] = item;\n }\n }\n if (argList.length === 0) {\n argList.push(elemId);\n }\n functions.push(function() {\n const elem = document.querySelector(`[id=\"${elemId}\"]`);\n if (elem !== null) {\n elem.addEventListener(\n \"click\",\n function() {\n utils.runFunc(functionName, ...argList);\n },\n false\n );\n }\n });\n }\n};\nconst bindFunctions = function(element) {\n functions.forEach(function(fun) {\n fun(element);\n });\n};\nconst lineType = {\n LINE: 0,\n DOTTED_LINE: 1\n};\nconst relationType = {\n AGGREGATION: 0,\n EXTENSION: 1,\n COMPOSITION: 2,\n DEPENDENCY: 3,\n LOLLIPOP: 4\n};\nconst setupToolTips = function(element) {\n let tooltipElem = select(\".mermaidTooltip\");\n if ((tooltipElem._groups || tooltipElem)[0][0] === null) {\n tooltipElem = select(\"body\").append(\"div\").attr(\"class\", \"mermaidTooltip\").style(\"opacity\", 0);\n }\n const svg = select(element).select(\"svg\");\n const nodes = svg.selectAll(\"g.node\");\n nodes.on(\"mouseover\", function() {\n const el = select(this);\n const title = el.attr(\"title\");\n if (title === null) {\n return;\n }\n const rect = this.getBoundingClientRect();\n tooltipElem.transition().duration(200).style(\"opacity\", \".9\");\n tooltipElem.text(el.attr(\"title\")).style(\"left\", window.scrollX + rect.left + (rect.right - rect.left) / 2 + \"px\").style(\"top\", window.scrollY + rect.top - 14 + document.body.scrollTop + \"px\");\n tooltipElem.html(tooltipElem.html().replace(/<br\\/>/g, \"
      \"));\n el.classed(\"hover\", true);\n }).on(\"mouseout\", function() {\n tooltipElem.transition().duration(500).style(\"opacity\", 0);\n const el = select(this);\n el.classed(\"hover\", false);\n });\n};\nfunctions.push(setupToolTips);\nlet direction = \"TB\";\nconst getDirection = () => direction;\nconst setDirection = (dir) => {\n direction = dir;\n};\nconst addNamespace = function(id) {\n if (namespaces[id] !== void 0) {\n return;\n }\n namespaces[id] = {\n id,\n classes: {},\n children: {},\n domId: MERMAID_DOM_ID_PREFIX + id + \"-\" + namespaceCounter\n };\n namespaceCounter++;\n};\nconst getNamespace = function(name) {\n return namespaces[name];\n};\nconst getNamespaces = function() {\n return namespaces;\n};\nconst addClassesToNamespace = function(id, classNames) {\n if (namespaces[id] !== void 0) {\n classNames.map((className) => {\n classes[className].parent = id;\n namespaces[id].classes[className] = classes[className];\n });\n }\n};\nconst db = {\n setAccTitle,\n getAccTitle,\n getAccDescription,\n setAccDescription,\n getConfig: () => getConfig().class,\n addClass,\n bindFunctions,\n clear,\n getClass,\n getClasses,\n getNotes,\n addAnnotation,\n addNote,\n getRelations,\n addRelation,\n getDirection,\n setDirection,\n addMember,\n addMembers,\n cleanupLabel,\n lineType,\n relationType,\n setClickEvent,\n setCssClass,\n setLink,\n getTooltip,\n setTooltip,\n lookUpDomId,\n setDiagramTitle,\n getDiagramTitle,\n setClassLabel,\n addNamespace,\n addClassesToNamespace,\n getNamespace,\n getNamespaces\n};\nconst getStyles = (options) => `g.classGroup text {\n fill: ${options.nodeBorder || options.classText};\n stroke: none;\n font-family: ${options.fontFamily};\n font-size: 10px;\n\n .title {\n font-weight: bolder;\n }\n\n}\n\n.nodeLabel, .edgeLabel {\n color: ${options.classText};\n}\n.edgeLabel .label rect {\n fill: ${options.mainBkg};\n}\n.label text {\n fill: ${options.classText};\n}\n.edgeLabel .label span {\n background: ${options.mainBkg};\n}\n\n.classTitle {\n font-weight: bolder;\n}\n.node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n stroke-width: 1px;\n }\n\n\n.divider {\n stroke: ${options.nodeBorder};\n stroke-width: 1;\n}\n\ng.clickable {\n cursor: pointer;\n}\n\ng.classGroup rect {\n fill: ${options.mainBkg};\n stroke: ${options.nodeBorder};\n}\n\ng.classGroup line {\n stroke: ${options.nodeBorder};\n stroke-width: 1;\n}\n\n.classLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ${options.mainBkg};\n opacity: 0.5;\n}\n\n.classLabel .label {\n fill: ${options.nodeBorder};\n font-size: 10px;\n}\n\n.relation {\n stroke: ${options.lineColor};\n stroke-width: 1;\n fill: none;\n}\n\n.dashed-line{\n stroke-dasharray: 3;\n}\n\n.dotted-line{\n stroke-dasharray: 1 2;\n}\n\n#compositionStart, .composition {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#compositionEnd, .composition {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ${options.lineColor} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#extensionStart, .extension {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#extensionEnd, .extension {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#aggregationStart, .aggregation {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#aggregationEnd, .aggregation {\n fill: transparent !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#lollipopStart, .lollipop {\n fill: ${options.mainBkg} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n#lollipopEnd, .lollipop {\n fill: ${options.mainBkg} !important;\n stroke: ${options.lineColor} !important;\n stroke-width: 1;\n}\n\n.edgeTerminals {\n font-size: 11px;\n}\n\n.classTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${options.textColor};\n}\n`;\nconst styles = getStyles;\nexport {\n db as d,\n parser$1 as p,\n styles as s\n};\n"], "mappings": "+JAEA,IAAIA,GAAS,UAAW,CACtB,IAAIC,EAAI,SAASC,EAAGC,EAAGC,EAAIC,EAAG,CAC5B,IAAKD,EAAKA,GAAM,CAAC,EAAGC,EAAIH,EAAE,OAAQG,IAAKD,EAAGF,EAAEG,CAAC,CAAC,EAAIF,EAChD,CACF,OAAOC,CACT,EAAGE,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,EAAM,CAAC,EAAG,EAAE,EAAGC,GAAM,CAAC,EAAG,EAAE,EAAGC,GAAM,CAAC,EAAG,EAAE,EAAGC,GAAM,CAAC,EAAG,EAAE,EAAGC,GAAM,CAAC,EAAG,EAAE,EAAGC,GAAM,CAAC,EAAG,EAAE,EAAGC,GAAM,CAAC,EAAG,EAAE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EACf,GACT,IAAK,GACH,YAAK,SAAS,EACP,kBACT,IAAK,GACH,YAAK,MAAM,WAAW,EACf,GACT,IAAK,GACH,YAAK,SAAS,EACP,kBACT,IAAK,IACH,KAAK,MAAM,qBAAqB,EAChC,MACF,IAAK,IACH,KAAK,SAAS,EACd,MACF,IAAK,IACH,MAAO,4BACT,IAAK,IACH,MAAO,GACT,IAAK,IACH,MACF,IAAK,IACH,MAAO,GACT,IAAK,IACH,MAAO,GACT,IAAK,IACH,MAAO,aACT,IAAK,IACH,KAAK,MAAM,eAAe,EAC1B,MACF,IAAK,IACH,KAAK,SAAS,EACd,MACF,IAAK,IACH,KAAK,SAAS,EACd,KAAK,MAAM,eAAe,EAC1B,MACF,IAAK,IACH,MAAO,IACT,IAAK,IACH,KAAK,SAAS,EACd,MACF,IAAK,IACH,MAAO,IACT,IAAK,IACH,KAAK,SAAS,EACd,MACF,IAAK,IACH,MAAO,MACT,IAAK,IACH,KAAK,MAAM,QAAQ,EACnB,MACF,IAAK,IACH,YAAK,MAAM,WAAW,EACf,GACT,IAAK,IACH,YAAK,SAAS,EACP,EACT,IAAK,IACH,MACF,IAAK,IACH,YAAK,MAAM,gBAAgB,EACpB,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,MAAO,gBACT,IAAK,IACH,MAAO,GACT,IAAK,IACH,MACF,IAAK,IACH,MAAO,aACT,IAAK,IACH,YAAK,MAAM,OAAO,EACX,GACT,IAAK,IACH,YAAK,SAAS,EACP,EACT,IAAK,IACH,MACF,IAAK,IACH,YAAK,SAAS,EACd,KAAK,SAAS,EACP,GACT,IAAK,IACH,YAAK,MAAM,YAAY,EAChB,GACT,IAAK,IACH,YAAK,SAAS,EACP,GACT,IAAK,IACH,MAAO,gBACT,IAAK,IACH,MAAO,aACT,IAAK,IACH,MAAO,iBACT,IAAK,IACH,MACF,IAAK,IACH,MAAO,SACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO,IACT,IAAK,IACH,MAAO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AAA,YACbA,EAAQ,SAAS;AAAA;AAAA;AAAA;AAAA;AAAA,UAKnBA,EAAQ,OAAO;AAAA,YACbA,EAAQ,SAAS;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,UAWnBA,EAAQ,SAAS;AAAA;AAAA,EAGrBC,GAASF", "names": ["parser", "o", "k", "v", "o2", "l", "$V0", "$V1", "$V2", "$V3", "$V4", "$V5", "$V6", "$V7", "$V8", "$V9", "$Va", "$Vb", "$Vc", "$Vd", "$Ve", "$Vf", "$Vg", "$Vh", "$Vi", "$Vj", "$Vk", "$Vl", "$Vm", "$Vn", "$Vo", "$Vp", "$Vq", "$Vr", "$Vs", "$Vt", "$Vu", "$Vv", "$Vw", "$Vx", "$Vy", "$Vz", "$VA", "$VB", "$VC", "$VD", "$VE", "$VF", "parser2", "yytext", "yyleng", "yylineno", "yy", "yystate", "$$", "_$", "$0", "str", "hash", "error", "input", "self", "stack", "tstack", "vstack", "lstack", "table", "TERROR", "EOF", "args", "lexer2", "sharedState", "yyloc", "ranges", "lex", "token", "symbol", "state", "action", "r", "yyval", "p", "len", "newState", "expected", "errStr", "lexer", "ch", "lines", "oldLines", "n", "past", "next", "pre", "c", "match", "indexed_rule", "backup", "tempMatch", "index", "rules", "i", "condition", "yy_", "$avoiding_name_collisions", "YY_START", "Parser", "parser$1", "visibilityValues", "ClassMember", "memberType", "sanitizedInput", "sanitizeText$2", "getConfig", "displayText", "parseGenericTypes", "cssStyle", "potentialClassifier", "methodRegEx", "detectedVisibility", "lastChar", "length", "firstChar", "MERMAID_DOM_ID_PREFIX", "relations", "classes", "notes", "classCounter", "namespaces", "namespaceCounter", "functions", "sanitizeText", "txt", "common$1", "splitClassNameAndType", "_id", "id", "genericType", "className", "split", "setClassLabel", "label", "addClass", "type", "name", "lookUpDomId", "clear", "setupToolTips", "getClass", "getClasses", "getRelations", "getNotes", "addRelation", "relation", "log$1", "addAnnotation", "annotation", "validatedClassName", "addMember", "member", "theClass", "memberString", "addMembers", "members", "addNote", "text", "note", "cleanupLabel", "setCssClass", "ids", "setTooltip", "tooltip", "getTooltip", "namespace", "setLink", "linkStr", "target", "config", "utils", "setClickEvent", "functionName", "functionArgs", "setClickFunc", "_domId", "domId", "elemId", "argList", "item", "elem", "bindFunctions", "element", "fun", "lineType", "relationType", "tooltipElem", "select_default", "el", "rect", "direction", "getDirection", "setDirection", "dir", "addNamespace", "getNamespace", "getNamespaces", "addClassesToNamespace", "classNames", "db", "setAccTitle", "getAccTitle", "getAccDescription", "setAccDescription", "setDiagramTitle", "getDiagramTitle", "getStyles", "options", "styles"] } diff --git a/docs/public/chunk-ESYVBUIP.min.js b/docs/public/chunk-NV7BXRXJ.min.js similarity index 99% rename from docs/public/chunk-ESYVBUIP.min.js rename to docs/public/chunk-NV7BXRXJ.min.js index 7f61d273..a43f67af 100644 --- a/docs/public/chunk-ESYVBUIP.min.js +++ b/docs/public/chunk-NV7BXRXJ.min.js @@ -1,5 +1,5 @@ -import{b as Q}from"./chunk-TYUXPGKI.min.js";import{G as K,Ga as x,I as G,Ia as V,Ja as H,Za as W,h as E,jb as w,pb as A}from"./chunk-65WDIALL.min.js";var ct=(a,t,r,n)=>{t.forEach(e=>{ut[e](a,r,n)})},ht=(a,t,r)=>{x.trace("Making markers for ",r),a.append("defs").append("marker").attr("id",r+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},ot=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},ft=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},pt=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},yt=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),a.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)},dt=(a,t,r)=>{a.append("marker").attr("id",r+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",6).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),a.append("marker").attr("id",r+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},xt=(a,t,r)=>{a.append("marker").attr("id",r+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),a.append("marker").attr("id",r+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},bt=(a,t,r)=>{a.append("marker").attr("id",r+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),a.append("marker").attr("id",r+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},gt=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},ut={extension:ht,composition:ot,aggregation:ft,dependency:pt,lollipop:yt,point:dt,circle:xt,cross:bt,barb:gt},rr=ct;function wt(a,t){t&&a.attr("style",t)}function mt(a){let t=E(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),r=t.append("xhtml:div"),n=a.label,e=a.isNode?"nodeLabel":"edgeLabel";return r.html('"+n+""),wt(r,a.labelStyle),r.style("display","inline-block"),r.style("white-space","nowrap"),r.attr("xmlns","http://www.w3.org/1999/xhtml"),t.node()}var kt=(a,t,r,n)=>{let e=a||"";if(typeof e=="object"&&(e=e[0]),H(w().flowchart.htmlLabels)){e=e.replace(/\\n|\n/g,"
      "),x.info("vertexText"+e);let i={isNode:n,label:A(e).replace(/fa[blrs]?:fa-[\w-]+/g,l=>``),labelStyle:t.replace("fill:","color:")};return mt(i)}else{let i=document.createElementNS("http://www.w3.org/2000/svg","text");i.setAttribute("style",t.replace("color:","fill:"));let s=[];typeof e=="string"?s=e.split(/\\n|\n|/gi):Array.isArray(e)?s=e:s=[];for(let l of s){let c=document.createElementNS("http://www.w3.org/2000/svg","tspan");c.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),c.setAttribute("dy","1em"),c.setAttribute("x","0"),r?c.setAttribute("class","title-row"):c.setAttribute("class","row"),c.textContent=l.trim(),i.appendChild(c)}return i}},I=kt,_=async(a,t,r,n)=>{let e,i=t.useHtmlLabels||H(w().flowchart.htmlLabels);r?e=r:e="node default";let s=a.insert("g").attr("class",e).attr("id",t.domId||t.id),l=s.insert("g").attr("class","label").attr("style",t.labelStyle),c;t.labelText===void 0?c="":c=typeof t.labelText=="string"?t.labelText:t.labelText[0];let o=l.node(),h;t.labelType==="markdown"?h=Q(l,V(A(c),w()),{useHtmlLabels:i,width:t.width||w().flowchart.wrappingWidth,classes:"markdown-node-label"}):h=o.appendChild(I(V(A(c),w()),t.labelStyle,!1,n));let f=h.getBBox(),y=t.padding/2;if(H(w().flowchart.htmlLabels)){let p=h.children[0],u=E(h),k=p.getElementsByTagName("img");if(k){let g=c.replace(/]*>/g,"").trim()==="";await Promise.all([...k].map(d=>new Promise(b=>{function M(){if(d.style.display="flex",d.style.flexDirection="column",g){let C=w().fontSize?w().fontSize:window.getComputedStyle(document.body).fontSize,X=5;d.style.width=parseInt(C,10)*X+"px"}else d.style.width="100%";b(d)}setTimeout(()=>{d.complete&&M()}),d.addEventListener("error",M),d.addEventListener("load",M)})))}f=p.getBoundingClientRect(),u.attr("width",f.width),u.attr("height",f.height)}return i?l.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"):l.attr("transform","translate(0, "+-f.height/2+")"),t.centerLabel&&l.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),l.insert("rect",":first-child"),{shapeSvg:s,bbox:f,halfPadding:y,label:l}},v=(a,t)=>{let r=t.node().getBBox();a.width=r.width,a.height=r.height};function $(a,t,r,n){return a.insert("polygon",":first-child").attr("points",n.map(function(e){return e.x+","+e.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+r/2+")")}function vt(a,t){return a.intersect(t)}function it(a,t,r,n){var e=a.x,i=a.y,s=e-n.x,l=i-n.y,c=Math.sqrt(t*t*l*l+r*r*s*s),o=Math.abs(t*r*s/c);n.x0}function Et(a,t,r){var n=a.x,e=a.y,i=[],s=Number.POSITIVE_INFINITY,l=Number.POSITIVE_INFINITY;typeof t.forEach=="function"?t.forEach(function(u){s=Math.min(s,u.x),l=Math.min(l,u.y)}):(s=Math.min(s,t.x),l=Math.min(l,t.y));for(var c=n-a.width/2-s,o=e-a.height/2-l,h=0;h1&&i.sort(function(u,k){var g=u.x-r.x,d=u.y-r.y,b=Math.sqrt(g*g+d*d),M=k.x-r.x,C=k.y-r.y,X=Math.sqrt(M*M+C*C);return b{var r=a.x,n=a.y,e=t.x-r,i=t.y-n,s=a.width/2,l=a.height/2,c,o;return Math.abs(i)*s>Math.abs(e)*l?(i<0&&(l=-l),c=i===0?0:l*e/i,o=l):(e<0&&(s=-s),c=s,o=e===0?0:s*i/e),{x:r+c,y:n+o}},Mt=Bt,m={node:vt,circle:Lt,ellipse:it,polygon:Et,rect:Mt},_t=async(a,t)=>{t.useHtmlLabels||w().flowchart.htmlLabels||(t.centerLabel=!0);let{shapeSvg:n,bbox:e,halfPadding:i}=await _(a,t,"node "+t.classes,!0);x.info("Classes = ",t.classes);let s=n.insert("rect",":first-child");return s.attr("rx",t.rx).attr("ry",t.ry).attr("x",-e.width/2-i).attr("y",-e.height/2-i).attr("width",e.width+t.padding).attr("height",e.height+t.padding),v(t,s),t.intersect=function(l){return m.rect(t,l)},n},Ct=_t,tt=a=>a?" "+a:"",R=(a,t)=>`${t||"node default"}${tt(a.classes)} ${tt(a.class)}`,rt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=e+i,l=[{x:s/2,y:0},{x:s,y:-s/2},{x:s/2,y:-s},{x:0,y:-s/2}];x.info("Question main (Circle)");let c=$(r,s,s,l);return c.attr("style",t.style),v(t,c),t.intersect=function(o){return x.warn("Intersect called"),m.polygon(t,l,o)},r},Tt=(a,t)=>{let r=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),n=28,e=[{x:0,y:n/2},{x:n/2,y:0},{x:0,y:-n/2},{x:-n/2,y:0}];return r.insert("polygon",":first-child").attr("points",e.map(function(s){return s.x+","+s.y}).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),t.width=28,t.height=28,t.intersect=function(s){return m.circle(t,14,s)},r},Rt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=4,i=n.height+t.padding,s=i/e,l=n.width+2*s+t.padding,c=[{x:s,y:0},{x:l-s,y:0},{x:l,y:-i/2},{x:l-s,y:-i},{x:s,y:-i},{x:0,y:-i/2}],o=$(r,l,i,c);return o.attr("style",t.style),v(t,o),t.intersect=function(h){return m.polygon(t,c,h)},r},It=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:-i/2,y:0},{x:e,y:0},{x:e,y:-i},{x:-i/2,y:-i},{x:0,y:-i/2}];return $(r,e,i,s).attr("style",t.style),t.width=e+i,t.height=i,t.intersect=function(c){return m.polygon(t,s,c)},r},Ht=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:-2*i/6,y:0},{x:e-i/6,y:0},{x:e+2*i/6,y:-i},{x:i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Nt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:2*i/6,y:0},{x:e+i/6,y:0},{x:e-2*i/6,y:-i},{x:-i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},$t=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:-2*i/6,y:0},{x:e+2*i/6,y:0},{x:e-i/6,y:-i},{x:i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Ot=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:i/6,y:0},{x:e-i/6,y:0},{x:e+2*i/6,y:-i},{x:-2*i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Xt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:0,y:0},{x:e+i/2,y:0},{x:e,y:-i/2},{x:e+i/2,y:-i},{x:0,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Yt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=e/2,s=i/(2.5+e/50),l=n.height+s+t.padding,c="M 0,"+s+" a "+i+","+s+" 0,0,0 "+e+" 0 a "+i+","+s+" 0,0,0 "+-e+" 0 l 0,"+l+" a "+i+","+s+" 0,0,0 "+e+" 0 l 0,"+-l,o=r.attr("label-offset-y",s).insert("path",":first-child").attr("style",t.style).attr("d",c).attr("transform","translate("+-e/2+","+-(l/2+s)+")");return v(t,o),t.intersect=function(h){let f=m.rect(t,h),y=f.x-t.x;if(i!=0&&(Math.abs(y)t.height/2-s)){let p=s*s*(1-y*y/(i*i));p!=0&&(p=Math.sqrt(p)),p=s-p,h.y-t.y>0&&(p=-p),f.y+=p}return f},r},Wt=async(a,t)=>{let{shapeSvg:r,bbox:n,halfPadding:e}=await _(a,t,"node "+t.classes+" "+t.class,!0),i=r.insert("rect",":first-child"),s=n.width+t.padding,l=n.height+t.padding;if(i.attr("class","basic label-container").attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("x",-n.width/2-e).attr("y",-n.height/2-e).attr("width",s).attr("height",l),t.props){let c=new Set(Object.keys(t.props));t.props.borders&&(nt(i,t.props.borders,s,l),c.delete("borders")),c.forEach(o=>{x.warn(`Unknown node property ${o}`)})}return v(t,i),t.intersect=function(c){return m.rect(t,c)},r},Dt=async(a,t)=>{let{shapeSvg:r}=await _(a,t,"label",!0);x.trace("Classes = ",t.class);let n=r.insert("rect",":first-child"),e=0,i=0;if(n.attr("width",e).attr("height",i),r.attr("class","label edgeLabel"),t.props){let s=new Set(Object.keys(t.props));t.props.borders&&(nt(n,t.props.borders,e,i),s.delete("borders")),s.forEach(l=>{x.warn(`Unknown node property ${l}`)})}return v(t,n),t.intersect=function(s){return m.rect(t,s)},r};function nt(a,t,r,n){let e=[],i=l=>{e.push(l,0)},s=l=>{e.push(0,l)};t.includes("t")?(x.debug("add top border"),i(r)):s(r),t.includes("r")?(x.debug("add right border"),i(n)):s(n),t.includes("b")?(x.debug("add bottom border"),i(r)):s(r),t.includes("l")?(x.debug("add left border"),i(n)):s(n),a.attr("stroke-dasharray",e.join(" "))}var jt=(a,t)=>{let r;t.classes?r="node "+t.classes:r="node default";let n=a.insert("g").attr("class",r).attr("id",t.domId||t.id),e=n.insert("rect",":first-child"),i=n.insert("line"),s=n.insert("g").attr("class","label"),l=t.labelText.flat?t.labelText.flat():t.labelText,c="";typeof l=="object"?c=l[0]:c=l,x.info("Label text abc79",c,l,typeof l=="object");let o=s.node().appendChild(I(c,t.labelStyle,!0,!0)),h={width:0,height:0};if(H(w().flowchart.htmlLabels)){let k=o.children[0],g=E(o);h=k.getBoundingClientRect(),g.attr("width",h.width),g.attr("height",h.height)}x.info("Text 2",l);let f=l.slice(1,l.length),y=o.getBBox(),p=s.node().appendChild(I(f.join?f.join("
      "):f,t.labelStyle,!0,!0));if(H(w().flowchart.htmlLabels)){let k=p.children[0],g=E(p);h=k.getBoundingClientRect(),g.attr("width",h.width),g.attr("height",h.height)}let u=t.padding/2;return E(p).attr("transform","translate( "+(h.width>y.width?0:(y.width-h.width)/2)+", "+(y.height+u+5)+")"),E(o).attr("transform","translate( "+(h.width{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.height+t.padding,i=n.width+e/4+t.padding,s=r.insert("rect",":first-child").attr("style",t.style).attr("rx",e/2).attr("ry",e/2).attr("x",-i/2).attr("y",-e/2).attr("width",i).attr("height",e);return v(t,s),t.intersect=function(l){return m.rect(t,l)},r},Ut=async(a,t)=>{let{shapeSvg:r,bbox:n,halfPadding:e}=await _(a,t,R(t,void 0),!0),i=r.insert("circle",":first-child");return i.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",n.width/2+e).attr("width",n.width+t.padding).attr("height",n.height+t.padding),x.info("Circle main"),v(t,i),t.intersect=function(s){return x.info("Circle intersect",t,n.width/2+e,s),m.circle(t,n.width/2+e,s)},r},zt=async(a,t)=>{let{shapeSvg:r,bbox:n,halfPadding:e}=await _(a,t,R(t,void 0),!0),i=5,s=r.insert("g",":first-child"),l=s.insert("circle"),c=s.insert("circle");return s.attr("class",t.class),l.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",n.width/2+e+i).attr("width",n.width+t.padding+i*2).attr("height",n.height+t.padding+i*2),c.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",n.width/2+e).attr("width",n.width+t.padding).attr("height",n.height+t.padding),x.info("DoubleCircle main"),v(t,l),t.intersect=function(o){return x.info("DoubleCircle intersect",t,n.width/2+e+i,o),m.circle(t,n.width/2+e+i,o)},r},Zt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:0,y:0},{x:e,y:0},{x:e,y:-i},{x:0,y:-i},{x:0,y:0},{x:-8,y:0},{x:e+8,y:0},{x:e+8,y:-i},{x:-8,y:-i},{x:-8,y:0}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Ft=(a,t)=>{let r=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),n=r.insert("circle",":first-child");return n.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),v(t,n),t.intersect=function(e){return m.circle(t,7,e)},r},at=(a,t,r)=>{let n=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),e=70,i=10;r==="LR"&&(e=10,i=70);let s=n.append("rect").attr("x",-1*e/2).attr("y",-1*i/2).attr("width",e).attr("height",i).attr("class","fork-join");return v(t,s),t.height=t.height+t.padding/2,t.width=t.width+t.padding/2,t.intersect=function(l){return m.rect(t,l)},n},Jt=(a,t)=>{let r=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),n=r.insert("circle",":first-child"),e=r.insert("circle",":first-child");return e.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),n.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),v(t,e),t.intersect=function(i){return m.circle(t,7,i)},r},Qt=(a,t)=>{let r=t.padding/2,n=4,e=8,i;t.classes?i="node "+t.classes:i="node default";let s=a.insert("g").attr("class",i).attr("id",t.domId||t.id),l=s.insert("rect",":first-child"),c=s.insert("line"),o=s.insert("line"),h=0,f=n,y=s.insert("g").attr("class","label"),p=0,u=t.classData.annotations&&t.classData.annotations[0],k=t.classData.annotations[0]?"\xAB"+t.classData.annotations[0]+"\xBB":"",g=y.node().appendChild(I(k,t.labelStyle,!0,!0)),d=g.getBBox();if(H(w().flowchart.htmlLabels)){let L=g.children[0],S=E(g);d=L.getBoundingClientRect(),S.attr("width",d.width),S.attr("height",d.height)}t.classData.annotations[0]&&(f+=d.height+n,h+=d.width);let b=t.classData.label;t.classData.type!==void 0&&t.classData.type!==""&&(w().flowchart.htmlLabels?b+="<"+t.classData.type+">":b+="<"+t.classData.type+">");let M=y.node().appendChild(I(b,t.labelStyle,!0,!0));E(M).attr("class","classTitle");let C=M.getBBox();if(H(w().flowchart.htmlLabels)){let L=M.children[0],S=E(M);C=L.getBoundingClientRect(),S.attr("width",C.width),S.attr("height",C.height)}f+=C.height+n,C.width>h&&(h=C.width);let X=[];t.classData.members.forEach(L=>{let S=L.getDisplayDetails(),Y=S.displayText;w().flowchart.htmlLabels&&(Y=Y.replace(//g,">"));let N=y.node().appendChild(I(Y,S.cssStyle?S.cssStyle:t.labelStyle,!0,!0)),T=N.getBBox();if(H(w().flowchart.htmlLabels)){let J=N.children[0],j=E(N);T=J.getBoundingClientRect(),j.attr("width",T.width),j.attr("height",T.height)}T.width>h&&(h=T.width),f+=T.height+n,X.push(N)}),f+=e;let q=[];if(t.classData.methods.forEach(L=>{let S=L.getDisplayDetails(),Y=S.displayText;w().flowchart.htmlLabels&&(Y=Y.replace(//g,">"));let N=y.node().appendChild(I(Y,S.cssStyle?S.cssStyle:t.labelStyle,!0,!0)),T=N.getBBox();if(H(w().flowchart.htmlLabels)){let J=N.children[0],j=E(N);T=J.getBoundingClientRect(),j.attr("width",T.width),j.attr("height",T.height)}T.width>h&&(h=T.width),f+=T.height+n,q.push(N)}),f+=e,u){let L=(h-d.width)/2;E(g).attr("transform","translate( "+(-1*h/2+L)+", "+-1*f/2+")"),p=d.height+n}let lt=(h-C.width)/2;return E(M).attr("transform","translate( "+(-1*h/2+lt)+", "+(-1*f/2+p)+")"),p+=C.height+n,c.attr("class","divider").attr("x1",-h/2-r).attr("x2",h/2+r).attr("y1",-f/2-r+e+p).attr("y2",-f/2-r+e+p),p+=e,X.forEach(L=>{E(L).attr("transform","translate( "+-h/2+", "+(-1*f/2+p+e/2)+")");let S=L?.getBBox();p+=(S?.height??0)+n}),p+=e,o.attr("class","divider").attr("x1",-h/2-r).attr("x2",h/2+r).attr("y1",-f/2-r+e+p).attr("y2",-f/2-r+e+p),p+=e,q.forEach(L=>{E(L).attr("transform","translate( "+-h/2+", "+(-1*f/2+p)+")");let S=L?.getBBox();p+=(S?.height??0)+n}),l.attr("class","outer title-state").attr("x",-h/2-r).attr("y",-(f/2)-r).attr("width",h+t.padding).attr("height",f+t.padding),v(t,l),t.intersect=function(L){return m.rect(t,L)},s},et={rhombus:rt,question:rt,rect:Wt,labelRect:Dt,rectWithTitle:jt,choice:Tt,circle:Ut,doublecircle:zt,stadium:At,hexagon:Rt,rect_left_inv_arrow:It,lean_right:Ht,lean_left:Nt,trapezoid:$t,inv_trapezoid:Ot,rect_right_inv_arrow:Xt,cylinder:Yt,start:Ft,end:Jt,note:Ct,subroutine:Zt,fork:at,join:at,class_box:Qt},D={},ar=async(a,t,r)=>{let n,e;if(t.link){let i;w().securityLevel==="sandbox"?i="_top":t.linkTarget&&(i=t.linkTarget||"_blank"),n=a.insert("svg:a").attr("xlink:href",t.link).attr("target",i),e=await et[t.shape](n,t,r)}else e=await et[t.shape](a,t,r),n=e;return t.tooltip&&e.attr("title",t.tooltip),t.class&&e.attr("class","node default "+t.class),D[t.id]=n,t.haveCallback&&D[t.id].attr("class",D[t.id].attr("class")+" clickable"),n},er=(a,t)=>{D[t.id]=a},sr=()=>{D={}},ir=a=>{let t=D[a.id];x.trace("Transforming node",a.diff,a,"translate("+(a.x-a.width/2-5)+", "+a.width/2+")");let r=8,n=a.diff||0;return a.clusterNode?t.attr("transform","translate("+(a.x+n-a.width/2)+", "+(a.y-a.height/2-r)+")"):t.attr("transform","translate("+a.x+", "+a.y+")"),n},O={aggregation:18,extension:18,composition:18,dependency:6,lollipop:13.5,arrow_point:5.3};function U(a,t){a=Z(a),t=Z(t);let[r,n]=[a.x,a.y],[e,i]=[t.x,t.y],s=e-r,l=i-n;return{angle:Math.atan(l/s),deltaX:s,deltaY:l}}var Z=a=>Array.isArray(a)?{x:a[0],y:a[1]}:a,Vt=a=>({x:function(t,r,n){let e=0;if(r===0&&Object.hasOwn(O,a.arrowTypeStart)){let{angle:i,deltaX:s}=U(n[0],n[1]);e=O[a.arrowTypeStart]*Math.cos(i)*(s>=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(O,a.arrowTypeEnd)){let{angle:i,deltaX:s}=U(n[n.length-1],n[n.length-2]);e=O[a.arrowTypeEnd]*Math.cos(i)*(s>=0?1:-1)}return Z(t).x+e},y:function(t,r,n){let e=0;if(r===0&&Object.hasOwn(O,a.arrowTypeStart)){let{angle:i,deltaY:s}=U(n[0],n[1]);e=O[a.arrowTypeStart]*Math.abs(Math.sin(i))*(s>=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(O,a.arrowTypeEnd)){let{angle:i,deltaY:s}=U(n[n.length-1],n[n.length-2]);e=O[a.arrowTypeEnd]*Math.abs(Math.sin(i))*(s>=0?1:-1)}return Z(t).y+e}}),F={},B={},nr=()=>{F={},B={}},lr=(a,t)=>{let r=H(w().flowchart.htmlLabels),n=t.labelType==="markdown"?Q(a,t.label,{style:t.labelStyle,useHtmlLabels:r,addSvgBackground:!0}):I(t.label,t.labelStyle);x.info("abc82",t,t.labelType);let e=a.insert("g").attr("class","edgeLabel"),i=e.insert("g").attr("class","label");i.node().appendChild(n);let s=n.getBBox();if(r){let c=n.children[0],o=E(n);s=c.getBoundingClientRect(),o.attr("width",s.width),o.attr("height",s.height)}i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),F[t.id]=e,t.width=s.width,t.height=s.height;let l;if(t.startLabelLeft){let c=I(t.startLabelLeft,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),B[t.id]||(B[t.id]={}),B[t.id].startLeft=o,z(l,t.startLabelLeft)}if(t.startLabelRight){let c=I(t.startLabelRight,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=o.node().appendChild(c),h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),B[t.id]||(B[t.id]={}),B[t.id].startRight=o,z(l,t.startLabelRight)}if(t.endLabelLeft){let c=I(t.endLabelLeft,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),o.node().appendChild(c),B[t.id]||(B[t.id]={}),B[t.id].endLeft=o,z(l,t.endLabelLeft)}if(t.endLabelRight){let c=I(t.endLabelRight,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),o.node().appendChild(c),B[t.id]||(B[t.id]={}),B[t.id].endRight=o,z(l,t.endLabelRight)}return n};function z(a,t){w().flowchart.htmlLabels&&a&&(a.style.width=t.length*9+"px",a.style.height="12px")}var cr=(a,t)=>{x.info("Moving label abc78 ",a.id,a.label,F[a.id]);let r=t.updatedPath?t.updatedPath:t.originalPath;if(a.label){let n=F[a.id],e=a.x,i=a.y;if(r){let s=W.calcLabelPosition(r);x.info("Moving label "+a.label+" from (",e,",",i,") to (",s.x,",",s.y,") abc78"),t.updatedPath&&(e=s.x,i=s.y)}n.attr("transform","translate("+e+", "+i+")")}if(a.startLabelLeft){let n=B[a.id].startLeft,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeStart?10:0,"start_left",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}if(a.startLabelRight){let n=B[a.id].startRight,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeStart?10:0,"start_right",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}if(a.endLabelLeft){let n=B[a.id].endLeft,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeEnd?10:0,"end_left",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}if(a.endLabelRight){let n=B[a.id].endRight,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeEnd?10:0,"end_right",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}},qt=(a,t)=>{let r=a.x,n=a.y,e=Math.abs(t.x-r),i=Math.abs(t.y-n),s=a.width/2,l=a.height/2;return e>=s||i>=l},Kt=(a,t,r)=>{x.warn(`intersection calc abc89: +import{b as Q}from"./chunk-ZMRDHQ6H.min.js";import{G as K,Ga as x,I as G,Ia as V,Ja as H,Za as W,h as E,jb as w,pb as A}from"./chunk-JUXSCBYR.min.js";var ct=(a,t,r,n)=>{t.forEach(e=>{ut[e](a,r,n)})},ht=(a,t,r)=>{x.trace("Making markers for ",r),a.append("defs").append("marker").attr("id",r+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},ot=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},ft=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},pt=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),a.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},yt=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),a.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)},dt=(a,t,r)=>{a.append("marker").attr("id",r+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",6).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),a.append("marker").attr("id",r+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},xt=(a,t,r)=>{a.append("marker").attr("id",r+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),a.append("marker").attr("id",r+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},bt=(a,t,r)=>{a.append("marker").attr("id",r+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),a.append("marker").attr("id",r+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},gt=(a,t,r)=>{a.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},ut={extension:ht,composition:ot,aggregation:ft,dependency:pt,lollipop:yt,point:dt,circle:xt,cross:bt,barb:gt},rr=ct;function wt(a,t){t&&a.attr("style",t)}function mt(a){let t=E(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),r=t.append("xhtml:div"),n=a.label,e=a.isNode?"nodeLabel":"edgeLabel";return r.html('"+n+""),wt(r,a.labelStyle),r.style("display","inline-block"),r.style("white-space","nowrap"),r.attr("xmlns","http://www.w3.org/1999/xhtml"),t.node()}var kt=(a,t,r,n)=>{let e=a||"";if(typeof e=="object"&&(e=e[0]),H(w().flowchart.htmlLabels)){e=e.replace(/\\n|\n/g,"
      "),x.info("vertexText"+e);let i={isNode:n,label:A(e).replace(/fa[blrs]?:fa-[\w-]+/g,l=>``),labelStyle:t.replace("fill:","color:")};return mt(i)}else{let i=document.createElementNS("http://www.w3.org/2000/svg","text");i.setAttribute("style",t.replace("color:","fill:"));let s=[];typeof e=="string"?s=e.split(/\\n|\n|/gi):Array.isArray(e)?s=e:s=[];for(let l of s){let c=document.createElementNS("http://www.w3.org/2000/svg","tspan");c.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),c.setAttribute("dy","1em"),c.setAttribute("x","0"),r?c.setAttribute("class","title-row"):c.setAttribute("class","row"),c.textContent=l.trim(),i.appendChild(c)}return i}},I=kt,_=async(a,t,r,n)=>{let e,i=t.useHtmlLabels||H(w().flowchart.htmlLabels);r?e=r:e="node default";let s=a.insert("g").attr("class",e).attr("id",t.domId||t.id),l=s.insert("g").attr("class","label").attr("style",t.labelStyle),c;t.labelText===void 0?c="":c=typeof t.labelText=="string"?t.labelText:t.labelText[0];let o=l.node(),h;t.labelType==="markdown"?h=Q(l,V(A(c),w()),{useHtmlLabels:i,width:t.width||w().flowchart.wrappingWidth,classes:"markdown-node-label"}):h=o.appendChild(I(V(A(c),w()),t.labelStyle,!1,n));let f=h.getBBox(),y=t.padding/2;if(H(w().flowchart.htmlLabels)){let p=h.children[0],u=E(h),k=p.getElementsByTagName("img");if(k){let g=c.replace(/]*>/g,"").trim()==="";await Promise.all([...k].map(d=>new Promise(b=>{function M(){if(d.style.display="flex",d.style.flexDirection="column",g){let C=w().fontSize?w().fontSize:window.getComputedStyle(document.body).fontSize,X=5;d.style.width=parseInt(C,10)*X+"px"}else d.style.width="100%";b(d)}setTimeout(()=>{d.complete&&M()}),d.addEventListener("error",M),d.addEventListener("load",M)})))}f=p.getBoundingClientRect(),u.attr("width",f.width),u.attr("height",f.height)}return i?l.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"):l.attr("transform","translate(0, "+-f.height/2+")"),t.centerLabel&&l.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),l.insert("rect",":first-child"),{shapeSvg:s,bbox:f,halfPadding:y,label:l}},v=(a,t)=>{let r=t.node().getBBox();a.width=r.width,a.height=r.height};function $(a,t,r,n){return a.insert("polygon",":first-child").attr("points",n.map(function(e){return e.x+","+e.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+r/2+")")}function vt(a,t){return a.intersect(t)}function it(a,t,r,n){var e=a.x,i=a.y,s=e-n.x,l=i-n.y,c=Math.sqrt(t*t*l*l+r*r*s*s),o=Math.abs(t*r*s/c);n.x0}function Et(a,t,r){var n=a.x,e=a.y,i=[],s=Number.POSITIVE_INFINITY,l=Number.POSITIVE_INFINITY;typeof t.forEach=="function"?t.forEach(function(u){s=Math.min(s,u.x),l=Math.min(l,u.y)}):(s=Math.min(s,t.x),l=Math.min(l,t.y));for(var c=n-a.width/2-s,o=e-a.height/2-l,h=0;h1&&i.sort(function(u,k){var g=u.x-r.x,d=u.y-r.y,b=Math.sqrt(g*g+d*d),M=k.x-r.x,C=k.y-r.y,X=Math.sqrt(M*M+C*C);return b{var r=a.x,n=a.y,e=t.x-r,i=t.y-n,s=a.width/2,l=a.height/2,c,o;return Math.abs(i)*s>Math.abs(e)*l?(i<0&&(l=-l),c=i===0?0:l*e/i,o=l):(e<0&&(s=-s),c=s,o=e===0?0:s*i/e),{x:r+c,y:n+o}},Mt=Bt,m={node:vt,circle:Lt,ellipse:it,polygon:Et,rect:Mt},_t=async(a,t)=>{t.useHtmlLabels||w().flowchart.htmlLabels||(t.centerLabel=!0);let{shapeSvg:n,bbox:e,halfPadding:i}=await _(a,t,"node "+t.classes,!0);x.info("Classes = ",t.classes);let s=n.insert("rect",":first-child");return s.attr("rx",t.rx).attr("ry",t.ry).attr("x",-e.width/2-i).attr("y",-e.height/2-i).attr("width",e.width+t.padding).attr("height",e.height+t.padding),v(t,s),t.intersect=function(l){return m.rect(t,l)},n},Ct=_t,tt=a=>a?" "+a:"",R=(a,t)=>`${t||"node default"}${tt(a.classes)} ${tt(a.class)}`,rt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=e+i,l=[{x:s/2,y:0},{x:s,y:-s/2},{x:s/2,y:-s},{x:0,y:-s/2}];x.info("Question main (Circle)");let c=$(r,s,s,l);return c.attr("style",t.style),v(t,c),t.intersect=function(o){return x.warn("Intersect called"),m.polygon(t,l,o)},r},Tt=(a,t)=>{let r=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),n=28,e=[{x:0,y:n/2},{x:n/2,y:0},{x:0,y:-n/2},{x:-n/2,y:0}];return r.insert("polygon",":first-child").attr("points",e.map(function(s){return s.x+","+s.y}).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),t.width=28,t.height=28,t.intersect=function(s){return m.circle(t,14,s)},r},Rt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=4,i=n.height+t.padding,s=i/e,l=n.width+2*s+t.padding,c=[{x:s,y:0},{x:l-s,y:0},{x:l,y:-i/2},{x:l-s,y:-i},{x:s,y:-i},{x:0,y:-i/2}],o=$(r,l,i,c);return o.attr("style",t.style),v(t,o),t.intersect=function(h){return m.polygon(t,c,h)},r},It=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:-i/2,y:0},{x:e,y:0},{x:e,y:-i},{x:-i/2,y:-i},{x:0,y:-i/2}];return $(r,e,i,s).attr("style",t.style),t.width=e+i,t.height=i,t.intersect=function(c){return m.polygon(t,s,c)},r},Ht=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:-2*i/6,y:0},{x:e-i/6,y:0},{x:e+2*i/6,y:-i},{x:i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Nt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:2*i/6,y:0},{x:e+i/6,y:0},{x:e-2*i/6,y:-i},{x:-i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},$t=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:-2*i/6,y:0},{x:e+2*i/6,y:0},{x:e-i/6,y:-i},{x:i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Ot=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:i/6,y:0},{x:e-i/6,y:0},{x:e+2*i/6,y:-i},{x:-2*i/6,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Xt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:0,y:0},{x:e+i/2,y:0},{x:e,y:-i/2},{x:e+i/2,y:-i},{x:0,y:-i}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Yt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=e/2,s=i/(2.5+e/50),l=n.height+s+t.padding,c="M 0,"+s+" a "+i+","+s+" 0,0,0 "+e+" 0 a "+i+","+s+" 0,0,0 "+-e+" 0 l 0,"+l+" a "+i+","+s+" 0,0,0 "+e+" 0 l 0,"+-l,o=r.attr("label-offset-y",s).insert("path",":first-child").attr("style",t.style).attr("d",c).attr("transform","translate("+-e/2+","+-(l/2+s)+")");return v(t,o),t.intersect=function(h){let f=m.rect(t,h),y=f.x-t.x;if(i!=0&&(Math.abs(y)t.height/2-s)){let p=s*s*(1-y*y/(i*i));p!=0&&(p=Math.sqrt(p)),p=s-p,h.y-t.y>0&&(p=-p),f.y+=p}return f},r},Wt=async(a,t)=>{let{shapeSvg:r,bbox:n,halfPadding:e}=await _(a,t,"node "+t.classes+" "+t.class,!0),i=r.insert("rect",":first-child"),s=n.width+t.padding,l=n.height+t.padding;if(i.attr("class","basic label-container").attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("x",-n.width/2-e).attr("y",-n.height/2-e).attr("width",s).attr("height",l),t.props){let c=new Set(Object.keys(t.props));t.props.borders&&(nt(i,t.props.borders,s,l),c.delete("borders")),c.forEach(o=>{x.warn(`Unknown node property ${o}`)})}return v(t,i),t.intersect=function(c){return m.rect(t,c)},r},Dt=async(a,t)=>{let{shapeSvg:r}=await _(a,t,"label",!0);x.trace("Classes = ",t.class);let n=r.insert("rect",":first-child"),e=0,i=0;if(n.attr("width",e).attr("height",i),r.attr("class","label edgeLabel"),t.props){let s=new Set(Object.keys(t.props));t.props.borders&&(nt(n,t.props.borders,e,i),s.delete("borders")),s.forEach(l=>{x.warn(`Unknown node property ${l}`)})}return v(t,n),t.intersect=function(s){return m.rect(t,s)},r};function nt(a,t,r,n){let e=[],i=l=>{e.push(l,0)},s=l=>{e.push(0,l)};t.includes("t")?(x.debug("add top border"),i(r)):s(r),t.includes("r")?(x.debug("add right border"),i(n)):s(n),t.includes("b")?(x.debug("add bottom border"),i(r)):s(r),t.includes("l")?(x.debug("add left border"),i(n)):s(n),a.attr("stroke-dasharray",e.join(" "))}var jt=(a,t)=>{let r;t.classes?r="node "+t.classes:r="node default";let n=a.insert("g").attr("class",r).attr("id",t.domId||t.id),e=n.insert("rect",":first-child"),i=n.insert("line"),s=n.insert("g").attr("class","label"),l=t.labelText.flat?t.labelText.flat():t.labelText,c="";typeof l=="object"?c=l[0]:c=l,x.info("Label text abc79",c,l,typeof l=="object");let o=s.node().appendChild(I(c,t.labelStyle,!0,!0)),h={width:0,height:0};if(H(w().flowchart.htmlLabels)){let k=o.children[0],g=E(o);h=k.getBoundingClientRect(),g.attr("width",h.width),g.attr("height",h.height)}x.info("Text 2",l);let f=l.slice(1,l.length),y=o.getBBox(),p=s.node().appendChild(I(f.join?f.join("
      "):f,t.labelStyle,!0,!0));if(H(w().flowchart.htmlLabels)){let k=p.children[0],g=E(p);h=k.getBoundingClientRect(),g.attr("width",h.width),g.attr("height",h.height)}let u=t.padding/2;return E(p).attr("transform","translate( "+(h.width>y.width?0:(y.width-h.width)/2)+", "+(y.height+u+5)+")"),E(o).attr("transform","translate( "+(h.width{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.height+t.padding,i=n.width+e/4+t.padding,s=r.insert("rect",":first-child").attr("style",t.style).attr("rx",e/2).attr("ry",e/2).attr("x",-i/2).attr("y",-e/2).attr("width",i).attr("height",e);return v(t,s),t.intersect=function(l){return m.rect(t,l)},r},Ut=async(a,t)=>{let{shapeSvg:r,bbox:n,halfPadding:e}=await _(a,t,R(t,void 0),!0),i=r.insert("circle",":first-child");return i.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",n.width/2+e).attr("width",n.width+t.padding).attr("height",n.height+t.padding),x.info("Circle main"),v(t,i),t.intersect=function(s){return x.info("Circle intersect",t,n.width/2+e,s),m.circle(t,n.width/2+e,s)},r},zt=async(a,t)=>{let{shapeSvg:r,bbox:n,halfPadding:e}=await _(a,t,R(t,void 0),!0),i=5,s=r.insert("g",":first-child"),l=s.insert("circle"),c=s.insert("circle");return s.attr("class",t.class),l.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",n.width/2+e+i).attr("width",n.width+t.padding+i*2).attr("height",n.height+t.padding+i*2),c.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",n.width/2+e).attr("width",n.width+t.padding).attr("height",n.height+t.padding),x.info("DoubleCircle main"),v(t,l),t.intersect=function(o){return x.info("DoubleCircle intersect",t,n.width/2+e+i,o),m.circle(t,n.width/2+e+i,o)},r},Zt=async(a,t)=>{let{shapeSvg:r,bbox:n}=await _(a,t,R(t,void 0),!0),e=n.width+t.padding,i=n.height+t.padding,s=[{x:0,y:0},{x:e,y:0},{x:e,y:-i},{x:0,y:-i},{x:0,y:0},{x:-8,y:0},{x:e+8,y:0},{x:e+8,y:-i},{x:-8,y:-i},{x:-8,y:0}],l=$(r,e,i,s);return l.attr("style",t.style),v(t,l),t.intersect=function(c){return m.polygon(t,s,c)},r},Ft=(a,t)=>{let r=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),n=r.insert("circle",":first-child");return n.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),v(t,n),t.intersect=function(e){return m.circle(t,7,e)},r},at=(a,t,r)=>{let n=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),e=70,i=10;r==="LR"&&(e=10,i=70);let s=n.append("rect").attr("x",-1*e/2).attr("y",-1*i/2).attr("width",e).attr("height",i).attr("class","fork-join");return v(t,s),t.height=t.height+t.padding/2,t.width=t.width+t.padding/2,t.intersect=function(l){return m.rect(t,l)},n},Jt=(a,t)=>{let r=a.insert("g").attr("class","node default").attr("id",t.domId||t.id),n=r.insert("circle",":first-child"),e=r.insert("circle",":first-child");return e.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),n.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),v(t,e),t.intersect=function(i){return m.circle(t,7,i)},r},Qt=(a,t)=>{let r=t.padding/2,n=4,e=8,i;t.classes?i="node "+t.classes:i="node default";let s=a.insert("g").attr("class",i).attr("id",t.domId||t.id),l=s.insert("rect",":first-child"),c=s.insert("line"),o=s.insert("line"),h=0,f=n,y=s.insert("g").attr("class","label"),p=0,u=t.classData.annotations&&t.classData.annotations[0],k=t.classData.annotations[0]?"\xAB"+t.classData.annotations[0]+"\xBB":"",g=y.node().appendChild(I(k,t.labelStyle,!0,!0)),d=g.getBBox();if(H(w().flowchart.htmlLabels)){let L=g.children[0],S=E(g);d=L.getBoundingClientRect(),S.attr("width",d.width),S.attr("height",d.height)}t.classData.annotations[0]&&(f+=d.height+n,h+=d.width);let b=t.classData.label;t.classData.type!==void 0&&t.classData.type!==""&&(w().flowchart.htmlLabels?b+="<"+t.classData.type+">":b+="<"+t.classData.type+">");let M=y.node().appendChild(I(b,t.labelStyle,!0,!0));E(M).attr("class","classTitle");let C=M.getBBox();if(H(w().flowchart.htmlLabels)){let L=M.children[0],S=E(M);C=L.getBoundingClientRect(),S.attr("width",C.width),S.attr("height",C.height)}f+=C.height+n,C.width>h&&(h=C.width);let X=[];t.classData.members.forEach(L=>{let S=L.getDisplayDetails(),Y=S.displayText;w().flowchart.htmlLabels&&(Y=Y.replace(//g,">"));let N=y.node().appendChild(I(Y,S.cssStyle?S.cssStyle:t.labelStyle,!0,!0)),T=N.getBBox();if(H(w().flowchart.htmlLabels)){let J=N.children[0],j=E(N);T=J.getBoundingClientRect(),j.attr("width",T.width),j.attr("height",T.height)}T.width>h&&(h=T.width),f+=T.height+n,X.push(N)}),f+=e;let q=[];if(t.classData.methods.forEach(L=>{let S=L.getDisplayDetails(),Y=S.displayText;w().flowchart.htmlLabels&&(Y=Y.replace(//g,">"));let N=y.node().appendChild(I(Y,S.cssStyle?S.cssStyle:t.labelStyle,!0,!0)),T=N.getBBox();if(H(w().flowchart.htmlLabels)){let J=N.children[0],j=E(N);T=J.getBoundingClientRect(),j.attr("width",T.width),j.attr("height",T.height)}T.width>h&&(h=T.width),f+=T.height+n,q.push(N)}),f+=e,u){let L=(h-d.width)/2;E(g).attr("transform","translate( "+(-1*h/2+L)+", "+-1*f/2+")"),p=d.height+n}let lt=(h-C.width)/2;return E(M).attr("transform","translate( "+(-1*h/2+lt)+", "+(-1*f/2+p)+")"),p+=C.height+n,c.attr("class","divider").attr("x1",-h/2-r).attr("x2",h/2+r).attr("y1",-f/2-r+e+p).attr("y2",-f/2-r+e+p),p+=e,X.forEach(L=>{E(L).attr("transform","translate( "+-h/2+", "+(-1*f/2+p+e/2)+")");let S=L?.getBBox();p+=(S?.height??0)+n}),p+=e,o.attr("class","divider").attr("x1",-h/2-r).attr("x2",h/2+r).attr("y1",-f/2-r+e+p).attr("y2",-f/2-r+e+p),p+=e,q.forEach(L=>{E(L).attr("transform","translate( "+-h/2+", "+(-1*f/2+p)+")");let S=L?.getBBox();p+=(S?.height??0)+n}),l.attr("class","outer title-state").attr("x",-h/2-r).attr("y",-(f/2)-r).attr("width",h+t.padding).attr("height",f+t.padding),v(t,l),t.intersect=function(L){return m.rect(t,L)},s},et={rhombus:rt,question:rt,rect:Wt,labelRect:Dt,rectWithTitle:jt,choice:Tt,circle:Ut,doublecircle:zt,stadium:At,hexagon:Rt,rect_left_inv_arrow:It,lean_right:Ht,lean_left:Nt,trapezoid:$t,inv_trapezoid:Ot,rect_right_inv_arrow:Xt,cylinder:Yt,start:Ft,end:Jt,note:Ct,subroutine:Zt,fork:at,join:at,class_box:Qt},D={},ar=async(a,t,r)=>{let n,e;if(t.link){let i;w().securityLevel==="sandbox"?i="_top":t.linkTarget&&(i=t.linkTarget||"_blank"),n=a.insert("svg:a").attr("xlink:href",t.link).attr("target",i),e=await et[t.shape](n,t,r)}else e=await et[t.shape](a,t,r),n=e;return t.tooltip&&e.attr("title",t.tooltip),t.class&&e.attr("class","node default "+t.class),D[t.id]=n,t.haveCallback&&D[t.id].attr("class",D[t.id].attr("class")+" clickable"),n},er=(a,t)=>{D[t.id]=a},sr=()=>{D={}},ir=a=>{let t=D[a.id];x.trace("Transforming node",a.diff,a,"translate("+(a.x-a.width/2-5)+", "+a.width/2+")");let r=8,n=a.diff||0;return a.clusterNode?t.attr("transform","translate("+(a.x+n-a.width/2)+", "+(a.y-a.height/2-r)+")"):t.attr("transform","translate("+a.x+", "+a.y+")"),n},O={aggregation:18,extension:18,composition:18,dependency:6,lollipop:13.5,arrow_point:5.3};function U(a,t){a=Z(a),t=Z(t);let[r,n]=[a.x,a.y],[e,i]=[t.x,t.y],s=e-r,l=i-n;return{angle:Math.atan(l/s),deltaX:s,deltaY:l}}var Z=a=>Array.isArray(a)?{x:a[0],y:a[1]}:a,Vt=a=>({x:function(t,r,n){let e=0;if(r===0&&Object.hasOwn(O,a.arrowTypeStart)){let{angle:i,deltaX:s}=U(n[0],n[1]);e=O[a.arrowTypeStart]*Math.cos(i)*(s>=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(O,a.arrowTypeEnd)){let{angle:i,deltaX:s}=U(n[n.length-1],n[n.length-2]);e=O[a.arrowTypeEnd]*Math.cos(i)*(s>=0?1:-1)}return Z(t).x+e},y:function(t,r,n){let e=0;if(r===0&&Object.hasOwn(O,a.arrowTypeStart)){let{angle:i,deltaY:s}=U(n[0],n[1]);e=O[a.arrowTypeStart]*Math.abs(Math.sin(i))*(s>=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(O,a.arrowTypeEnd)){let{angle:i,deltaY:s}=U(n[n.length-1],n[n.length-2]);e=O[a.arrowTypeEnd]*Math.abs(Math.sin(i))*(s>=0?1:-1)}return Z(t).y+e}}),F={},B={},nr=()=>{F={},B={}},lr=(a,t)=>{let r=H(w().flowchart.htmlLabels),n=t.labelType==="markdown"?Q(a,t.label,{style:t.labelStyle,useHtmlLabels:r,addSvgBackground:!0}):I(t.label,t.labelStyle);x.info("abc82",t,t.labelType);let e=a.insert("g").attr("class","edgeLabel"),i=e.insert("g").attr("class","label");i.node().appendChild(n);let s=n.getBBox();if(r){let c=n.children[0],o=E(n);s=c.getBoundingClientRect(),o.attr("width",s.width),o.attr("height",s.height)}i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),F[t.id]=e,t.width=s.width,t.height=s.height;let l;if(t.startLabelLeft){let c=I(t.startLabelLeft,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),B[t.id]||(B[t.id]={}),B[t.id].startLeft=o,z(l,t.startLabelLeft)}if(t.startLabelRight){let c=I(t.startLabelRight,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=o.node().appendChild(c),h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),B[t.id]||(B[t.id]={}),B[t.id].startRight=o,z(l,t.startLabelRight)}if(t.endLabelLeft){let c=I(t.endLabelLeft,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),o.node().appendChild(c),B[t.id]||(B[t.id]={}),B[t.id].endLeft=o,z(l,t.endLabelLeft)}if(t.endLabelRight){let c=I(t.endLabelRight,t.labelStyle),o=a.insert("g").attr("class","edgeTerminals"),h=o.insert("g").attr("class","inner");l=h.node().appendChild(c);let f=c.getBBox();h.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),o.node().appendChild(c),B[t.id]||(B[t.id]={}),B[t.id].endRight=o,z(l,t.endLabelRight)}return n};function z(a,t){w().flowchart.htmlLabels&&a&&(a.style.width=t.length*9+"px",a.style.height="12px")}var cr=(a,t)=>{x.info("Moving label abc78 ",a.id,a.label,F[a.id]);let r=t.updatedPath?t.updatedPath:t.originalPath;if(a.label){let n=F[a.id],e=a.x,i=a.y;if(r){let s=W.calcLabelPosition(r);x.info("Moving label "+a.label+" from (",e,",",i,") to (",s.x,",",s.y,") abc78"),t.updatedPath&&(e=s.x,i=s.y)}n.attr("transform","translate("+e+", "+i+")")}if(a.startLabelLeft){let n=B[a.id].startLeft,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeStart?10:0,"start_left",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}if(a.startLabelRight){let n=B[a.id].startRight,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeStart?10:0,"start_right",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}if(a.endLabelLeft){let n=B[a.id].endLeft,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeEnd?10:0,"end_left",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}if(a.endLabelRight){let n=B[a.id].endRight,e=a.x,i=a.y;if(r){let s=W.calcTerminalLabelPosition(a.arrowTypeEnd?10:0,"end_right",r);e=s.x,i=s.y}n.attr("transform","translate("+e+", "+i+")")}},qt=(a,t)=>{let r=a.x,n=a.y,e=Math.abs(t.x-r),i=Math.abs(t.y-n),s=a.width/2,l=a.height/2;return e>=s||i>=l},Kt=(a,t,r)=>{x.warn(`intersection calc abc89: outsidePoint: ${JSON.stringify(t)} insidePoint : ${JSON.stringify(r)} node : x:${a.x} y:${a.y} w:${a.width} h:${a.height}`);let n=a.x,e=a.y,i=Math.abs(n-r.x),s=a.width/2,l=r.xMath.abs(n-t.x)*c){let f=r.y{x.warn("abc88 cutPathAtIntersect",a,t);let r=[],n=a[0],e=!1;return a.forEach(i=>{if(x.info("abc88 checking point",i,t),!qt(t,i)&&!e){let s=Kt(t,n,i);x.warn("abc88 inside",i,n,s),x.warn("abc88 intersection",s);let l=!1;r.forEach(c=>{l=l||c.x===s.x&&c.y===s.y}),r.some(c=>c.x===s.x&&c.y===s.y)?x.warn("abc88 no intersect",s,r):r.push(s),e=!0}else x.warn("abc88 outside",i,n),n=i,e||r.push(i)}),x.warn("abc88 returning points",r),r},hr=function(a,t,r,n,e,i,s){let l=r.points,c=!1,o=i.node(t.v);var h=i.node(t.w);x.info("abc88 InsertEdge: ",r),h.intersect&&o.intersect&&(l=l.slice(1,r.points.length-1),l.unshift(o.intersect(l[0])),x.info("Last point",l[l.length-1],h,h.intersect(l[l.length-1])),l.push(h.intersect(l[l.length-1]))),r.toCluster&&(x.info("to cluster abc88",n[r.toCluster]),l=st(r.points,n[r.toCluster].node),c=!0),r.fromCluster&&(x.info("from cluster abc88",n[r.fromCluster]),l=st(l.reverse(),n[r.fromCluster].node).reverse(),c=!0);let f=l.filter(C=>!Number.isNaN(C.y)),y=G;r.curve&&(e==="graph"||e==="flowchart")&&(y=r.curve);let{x:p,y:u}=Vt(r),k=K().x(p).y(u).curve(y),g;switch(r.thickness){case"normal":g="edge-thickness-normal";break;case"thick":g="edge-thickness-thick";break;case"invisible":g="edge-thickness-thick";break;default:g=""}switch(r.pattern){case"solid":g+=" edge-pattern-solid";break;case"dotted":g+=" edge-pattern-dotted";break;case"dashed":g+=" edge-pattern-dashed";break}let d=a.append("path").attr("d",k(f)).attr("id",r.id).attr("class"," "+g+(r.classes?" "+r.classes:"")).attr("style",r.style),b="";switch((w().flowchart.arrowMarkerAbsolute||w().state.arrowMarkerAbsolute)&&(b=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,b=b.replace(/\(/g,"\\("),b=b.replace(/\)/g,"\\)")),x.info("arrowTypeStart",r.arrowTypeStart),x.info("arrowTypeEnd",r.arrowTypeEnd),r.arrowTypeStart){case"arrow_cross":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-crossStart)");break;case"arrow_point":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-pointStart)");break;case"arrow_barb":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-barbStart)");break;case"arrow_circle":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-circleStart)");break;case"aggregation":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-aggregationStart)");break;case"extension":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-extensionStart)");break;case"composition":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-compositionStart)");break;case"dependency":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-dependencyStart)");break;case"lollipop":d.attr("marker-start","url("+b+"#"+s+"_"+e+"-lollipopStart)");break}switch(r.arrowTypeEnd){case"arrow_cross":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-crossEnd)");break;case"arrow_point":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-pointEnd)");break;case"arrow_barb":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-barbEnd)");break;case"arrow_circle":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-circleEnd)");break;case"aggregation":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-aggregationEnd)");break;case"extension":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-extensionEnd)");break;case"composition":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-compositionEnd)");break;case"dependency":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-dependencyEnd)");break;case"lollipop":d.attr("marker-end","url("+b+"#"+s+"_"+e+"-lollipopEnd)");break}let M={};return c&&(M.updatedPath=l),M.originalPath=r.points,M};export{rr as a,I as b,_ as c,v as d,Mt as e,ar as f,er as g,sr as h,ir as i,Vt as j,nr as k,lr as l,cr as m,hr as n}; -//# sourceMappingURL=chunk-ESYVBUIP.min.js.map +//# sourceMappingURL=chunk-NV7BXRXJ.min.js.map diff --git a/docs/public/chunk-ESYVBUIP.min.js.map b/docs/public/chunk-NV7BXRXJ.min.js.map similarity index 99% rename from docs/public/chunk-ESYVBUIP.min.js.map rename to docs/public/chunk-NV7BXRXJ.min.js.map index 92704af1..2410bf27 100644 --- a/docs/public/chunk-ESYVBUIP.min.js.map +++ b/docs/public/chunk-NV7BXRXJ.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/edges-f2ad444c.js"], - "sourcesContent": ["import { l as log, m as evaluate, c as getConfig, J as decodeEntities, d as sanitizeText, u as utils } from \"./mermaid-8af3addd.js\";\nimport { select, line, curveBasis } from \"d3\";\nimport { a as createText } from \"./createText-62fc7601.js\";\nconst insertMarkers = (elem, markerArray, type, id) => {\n markerArray.forEach((markerName) => {\n markers[markerName](elem, type, id);\n });\n};\nconst extension = (elem, type, id) => {\n log.trace(\"Making markers for \", id);\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-extensionStart\").attr(\"class\", \"marker extension \" + type).attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,7 L18,13 V 1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-extensionEnd\").attr(\"class\", \"marker extension \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 V 13 L18,7 Z\");\n};\nconst composition = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-compositionStart\").attr(\"class\", \"marker composition \" + type).attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-compositionEnd\").attr(\"class\", \"marker composition \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n};\nconst aggregation = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-aggregationStart\").attr(\"class\", \"marker aggregation \" + type).attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-aggregationEnd\").attr(\"class\", \"marker aggregation \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n};\nconst dependency = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-dependencyStart\").attr(\"class\", \"marker dependency \" + type).attr(\"refX\", 6).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 5,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-dependencyEnd\").attr(\"class\", \"marker dependency \" + type).attr(\"refX\", 13).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L14,7 L9,1 Z\");\n};\nconst lollipop = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-lollipopStart\").attr(\"class\", \"marker lollipop \" + type).attr(\"refX\", 13).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"circle\").attr(\"stroke\", \"black\").attr(\"fill\", \"transparent\").attr(\"cx\", 7).attr(\"cy\", 7).attr(\"r\", 6);\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-lollipopEnd\").attr(\"class\", \"marker lollipop \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"circle\").attr(\"stroke\", \"black\").attr(\"fill\", \"transparent\").attr(\"cx\", 7).attr(\"cy\", 7).attr(\"r\", 6);\n};\nconst point = (elem, type, id) => {\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-pointEnd\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", 6).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 0 0 L 10 5 L 0 10 z\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-pointStart\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", 4.5).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 0 5 L 10 10 L 10 0 z\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n};\nconst circle$1 = (elem, type, id) => {\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-circleEnd\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", 11).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"circle\").attr(\"cx\", \"5\").attr(\"cy\", \"5\").attr(\"r\", \"5\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-circleStart\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", -1).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"circle\").attr(\"cx\", \"5\").attr(\"cy\", \"5\").attr(\"r\", \"5\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n};\nconst cross = (elem, type, id) => {\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-crossEnd\").attr(\"class\", \"marker cross \" + type).attr(\"viewBox\", \"0 0 11 11\").attr(\"refX\", 12).attr(\"refY\", 5.2).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 l 9,9 M 10,1 l -9,9\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 2).style(\"stroke-dasharray\", \"1,0\");\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-crossStart\").attr(\"class\", \"marker cross \" + type).attr(\"viewBox\", \"0 0 11 11\").attr(\"refX\", -1).attr(\"refY\", 5.2).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 l 9,9 M 10,1 l -9,9\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 2).style(\"stroke-dasharray\", \"1,0\");\n};\nconst barb = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-barbEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 14).attr(\"markerUnits\", \"strokeWidth\").attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 19,7 L9,13 L14,7 L9,1 Z\");\n};\nconst markers = {\n extension,\n composition,\n aggregation,\n dependency,\n lollipop,\n point,\n circle: circle$1,\n cross,\n barb\n};\nconst insertMarkers$1 = insertMarkers;\nfunction applyStyle(dom, styleFn) {\n if (styleFn) {\n dom.attr(\"style\", styleFn);\n }\n}\nfunction addHtmlLabel(node) {\n const fo = select(document.createElementNS(\"http://www.w3.org/2000/svg\", \"foreignObject\"));\n const div = fo.append(\"xhtml:div\");\n const label = node.label;\n const labelClass = node.isNode ? \"nodeLabel\" : \"edgeLabel\";\n div.html(\n '\" + label + \"\"\n );\n applyStyle(div, node.labelStyle);\n div.style(\"display\", \"inline-block\");\n div.style(\"white-space\", \"nowrap\");\n div.attr(\"xmlns\", \"http://www.w3.org/1999/xhtml\");\n return fo.node();\n}\nconst createLabel = (_vertexText, style, isTitle, isNode) => {\n let vertexText = _vertexText || \"\";\n if (typeof vertexText === \"object\") {\n vertexText = vertexText[0];\n }\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n vertexText = vertexText.replace(/\\\\n|\\n/g, \"
      \");\n log.info(\"vertexText\" + vertexText);\n const node = {\n isNode,\n label: decodeEntities(vertexText).replace(\n /fa[blrs]?:fa-[\\w-]+/g,\n (s) => ``\n ),\n labelStyle: style.replace(\"fill:\", \"color:\")\n };\n let vertexNode = addHtmlLabel(node);\n return vertexNode;\n } else {\n const svgLabel = document.createElementNS(\"http://www.w3.org/2000/svg\", \"text\");\n svgLabel.setAttribute(\"style\", style.replace(\"color:\", \"fill:\"));\n let rows = [];\n if (typeof vertexText === \"string\") {\n rows = vertexText.split(/\\\\n|\\n|/gi);\n } else if (Array.isArray(vertexText)) {\n rows = vertexText;\n } else {\n rows = [];\n }\n for (const row of rows) {\n const tspan = document.createElementNS(\"http://www.w3.org/2000/svg\", \"tspan\");\n tspan.setAttributeNS(\"http://www.w3.org/XML/1998/namespace\", \"xml:space\", \"preserve\");\n tspan.setAttribute(\"dy\", \"1em\");\n tspan.setAttribute(\"x\", \"0\");\n if (isTitle) {\n tspan.setAttribute(\"class\", \"title-row\");\n } else {\n tspan.setAttribute(\"class\", \"row\");\n }\n tspan.textContent = row.trim();\n svgLabel.appendChild(tspan);\n }\n return svgLabel;\n }\n};\nconst createLabel$1 = createLabel;\nconst labelHelper = async (parent, node, _classes, isNode) => {\n let classes;\n const useHtmlLabels = node.useHtmlLabels || evaluate(getConfig().flowchart.htmlLabels);\n if (!_classes) {\n classes = \"node default\";\n } else {\n classes = _classes;\n }\n const shapeSvg = parent.insert(\"g\").attr(\"class\", classes).attr(\"id\", node.domId || node.id);\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"label\").attr(\"style\", node.labelStyle);\n let labelText;\n if (node.labelText === void 0) {\n labelText = \"\";\n } else {\n labelText = typeof node.labelText === \"string\" ? node.labelText : node.labelText[0];\n }\n const textNode = label.node();\n let text;\n if (node.labelType === \"markdown\") {\n text = createText(label, sanitizeText(decodeEntities(labelText), getConfig()), {\n useHtmlLabels,\n width: node.width || getConfig().flowchart.wrappingWidth,\n classes: \"markdown-node-label\"\n });\n } else {\n text = textNode.appendChild(\n createLabel$1(\n sanitizeText(decodeEntities(labelText), getConfig()),\n node.labelStyle,\n false,\n isNode\n )\n );\n }\n let bbox = text.getBBox();\n const halfPadding = node.padding / 2;\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n const images = div.getElementsByTagName(\"img\");\n if (images) {\n const noImgText = labelText.replace(/]*>/g, \"\").trim() === \"\";\n await Promise.all(\n [...images].map(\n (img) => new Promise((res) => {\n function setupImage() {\n img.style.display = \"flex\";\n img.style.flexDirection = \"column\";\n if (noImgText) {\n const bodyFontSize = getConfig().fontSize ? getConfig().fontSize : window.getComputedStyle(document.body).fontSize;\n const enlargingFactor = 5;\n img.style.width = parseInt(bodyFontSize, 10) * enlargingFactor + \"px\";\n } else {\n img.style.width = \"100%\";\n }\n res(img);\n }\n setTimeout(() => {\n if (img.complete) {\n setupImage();\n }\n });\n img.addEventListener(\"error\", setupImage);\n img.addEventListener(\"load\", setupImage);\n })\n )\n );\n }\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n if (useHtmlLabels) {\n label.attr(\"transform\", \"translate(\" + -bbox.width / 2 + \", \" + -bbox.height / 2 + \")\");\n } else {\n label.attr(\"transform\", \"translate(0, \" + -bbox.height / 2 + \")\");\n }\n if (node.centerLabel) {\n label.attr(\"transform\", \"translate(\" + -bbox.width / 2 + \", \" + -bbox.height / 2 + \")\");\n }\n label.insert(\"rect\", \":first-child\");\n return { shapeSvg, bbox, halfPadding, label };\n};\nconst updateNodeBounds = (node, element) => {\n const bbox = element.node().getBBox();\n node.width = bbox.width;\n node.height = bbox.height;\n};\nfunction insertPolygonShape(parent, w, h, points) {\n return parent.insert(\"polygon\", \":first-child\").attr(\n \"points\",\n points.map(function(d) {\n return d.x + \",\" + d.y;\n }).join(\" \")\n ).attr(\"class\", \"label-container\").attr(\"transform\", \"translate(\" + -w / 2 + \",\" + h / 2 + \")\");\n}\nfunction intersectNode(node, point2) {\n return node.intersect(point2);\n}\nfunction intersectEllipse(node, rx, ry, point2) {\n var cx = node.x;\n var cy = node.y;\n var px = cx - point2.x;\n var py = cy - point2.y;\n var det = Math.sqrt(rx * rx * py * py + ry * ry * px * px);\n var dx = Math.abs(rx * ry * px / det);\n if (point2.x < cx) {\n dx = -dx;\n }\n var dy = Math.abs(rx * ry * py / det);\n if (point2.y < cy) {\n dy = -dy;\n }\n return { x: cx + dx, y: cy + dy };\n}\nfunction intersectCircle(node, rx, point2) {\n return intersectEllipse(node, rx, rx, point2);\n}\nfunction intersectLine(p1, p2, q1, q2) {\n var a1, a2, b1, b2, c1, c2;\n var r1, r2, r3, r4;\n var denom, offset, num;\n var x, y;\n a1 = p2.y - p1.y;\n b1 = p1.x - p2.x;\n c1 = p2.x * p1.y - p1.x * p2.y;\n r3 = a1 * q1.x + b1 * q1.y + c1;\n r4 = a1 * q2.x + b1 * q2.y + c1;\n if (r3 !== 0 && r4 !== 0 && sameSign(r3, r4)) {\n return;\n }\n a2 = q2.y - q1.y;\n b2 = q1.x - q2.x;\n c2 = q2.x * q1.y - q1.x * q2.y;\n r1 = a2 * p1.x + b2 * p1.y + c2;\n r2 = a2 * p2.x + b2 * p2.y + c2;\n if (r1 !== 0 && r2 !== 0 && sameSign(r1, r2)) {\n return;\n }\n denom = a1 * b2 - a2 * b1;\n if (denom === 0) {\n return;\n }\n offset = Math.abs(denom / 2);\n num = b1 * c2 - b2 * c1;\n x = num < 0 ? (num - offset) / denom : (num + offset) / denom;\n num = a2 * c1 - a1 * c2;\n y = num < 0 ? (num - offset) / denom : (num + offset) / denom;\n return { x, y };\n}\nfunction sameSign(r1, r2) {\n return r1 * r2 > 0;\n}\nfunction intersectPolygon(node, polyPoints, point2) {\n var x1 = node.x;\n var y1 = node.y;\n var intersections = [];\n var minX = Number.POSITIVE_INFINITY;\n var minY = Number.POSITIVE_INFINITY;\n if (typeof polyPoints.forEach === \"function\") {\n polyPoints.forEach(function(entry) {\n minX = Math.min(minX, entry.x);\n minY = Math.min(minY, entry.y);\n });\n } else {\n minX = Math.min(minX, polyPoints.x);\n minY = Math.min(minY, polyPoints.y);\n }\n var left = x1 - node.width / 2 - minX;\n var top = y1 - node.height / 2 - minY;\n for (var i = 0; i < polyPoints.length; i++) {\n var p1 = polyPoints[i];\n var p2 = polyPoints[i < polyPoints.length - 1 ? i + 1 : 0];\n var intersect2 = intersectLine(\n node,\n point2,\n { x: left + p1.x, y: top + p1.y },\n { x: left + p2.x, y: top + p2.y }\n );\n if (intersect2) {\n intersections.push(intersect2);\n }\n }\n if (!intersections.length) {\n return node;\n }\n if (intersections.length > 1) {\n intersections.sort(function(p, q) {\n var pdx = p.x - point2.x;\n var pdy = p.y - point2.y;\n var distp = Math.sqrt(pdx * pdx + pdy * pdy);\n var qdx = q.x - point2.x;\n var qdy = q.y - point2.y;\n var distq = Math.sqrt(qdx * qdx + qdy * qdy);\n return distp < distq ? -1 : distp === distq ? 0 : 1;\n });\n }\n return intersections[0];\n}\nconst intersectRect = (node, point2) => {\n var x = node.x;\n var y = node.y;\n var dx = point2.x - x;\n var dy = point2.y - y;\n var w = node.width / 2;\n var h = node.height / 2;\n var sx, sy;\n if (Math.abs(dy) * w > Math.abs(dx) * h) {\n if (dy < 0) {\n h = -h;\n }\n sx = dy === 0 ? 0 : h * dx / dy;\n sy = h;\n } else {\n if (dx < 0) {\n w = -w;\n }\n sx = w;\n sy = dx === 0 ? 0 : w * dy / dx;\n }\n return { x: x + sx, y: y + sy };\n};\nconst intersectRect$1 = intersectRect;\nconst intersect = {\n node: intersectNode,\n circle: intersectCircle,\n ellipse: intersectEllipse,\n polygon: intersectPolygon,\n rect: intersectRect$1\n};\nconst note = async (parent, node) => {\n const useHtmlLabels = node.useHtmlLabels || getConfig().flowchart.htmlLabels;\n if (!useHtmlLabels) {\n node.centerLabel = true;\n }\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n \"node \" + node.classes,\n true\n );\n log.info(\"Classes = \", node.classes);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n rect2.attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", -bbox.width / 2 - halfPadding).attr(\"y\", -bbox.height / 2 - halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst note$1 = note;\nconst formatClass = (str) => {\n if (str) {\n return \" \" + str;\n }\n return \"\";\n};\nconst getClassesFromNode = (node, otherClasses) => {\n return `${otherClasses ? otherClasses : \"node default\"}${formatClass(node.classes)} ${formatClass(\n node.class\n )}`;\n};\nconst question = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const s = w + h;\n const points = [\n { x: s / 2, y: 0 },\n { x: s, y: -s / 2 },\n { x: s / 2, y: -s },\n { x: 0, y: -s / 2 }\n ];\n log.info(\"Question main (Circle)\");\n const questionElem = insertPolygonShape(shapeSvg, s, s, points);\n questionElem.attr(\"style\", node.style);\n updateNodeBounds(node, questionElem);\n node.intersect = function(point2) {\n log.warn(\"Intersect called\");\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst choice = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n const s = 28;\n const points = [\n { x: 0, y: s / 2 },\n { x: s / 2, y: 0 },\n { x: 0, y: -s / 2 },\n { x: -s / 2, y: 0 }\n ];\n const choice2 = shapeSvg.insert(\"polygon\", \":first-child\").attr(\n \"points\",\n points.map(function(d) {\n return d.x + \",\" + d.y;\n }).join(\" \")\n );\n choice2.attr(\"class\", \"state-start\").attr(\"r\", 7).attr(\"width\", 28).attr(\"height\", 28);\n node.width = 28;\n node.height = 28;\n node.intersect = function(point2) {\n return intersect.circle(node, 14, point2);\n };\n return shapeSvg;\n};\nconst hexagon = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const f = 4;\n const h = bbox.height + node.padding;\n const m = h / f;\n const w = bbox.width + 2 * m + node.padding;\n const points = [\n { x: m, y: 0 },\n { x: w - m, y: 0 },\n { x: w, y: -h / 2 },\n { x: w - m, y: -h },\n { x: m, y: -h },\n { x: 0, y: -h / 2 }\n ];\n const hex = insertPolygonShape(shapeSvg, w, h, points);\n hex.attr(\"style\", node.style);\n updateNodeBounds(node, hex);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst rect_left_inv_arrow = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: -h / 2, y: 0 },\n { x: w, y: 0 },\n { x: w, y: -h },\n { x: -h / 2, y: -h },\n { x: 0, y: -h / 2 }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n node.width = w + h;\n node.height = h;\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst lean_right = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(parent, node, getClassesFromNode(node), true);\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: -2 * h / 6, y: 0 },\n { x: w - h / 6, y: 0 },\n { x: w + 2 * h / 6, y: -h },\n { x: h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst lean_left = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: 2 * h / 6, y: 0 },\n { x: w + h / 6, y: 0 },\n { x: w - 2 * h / 6, y: -h },\n { x: -h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst trapezoid = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: -2 * h / 6, y: 0 },\n { x: w + 2 * h / 6, y: 0 },\n { x: w - h / 6, y: -h },\n { x: h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst inv_trapezoid = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: h / 6, y: 0 },\n { x: w - h / 6, y: 0 },\n { x: w + 2 * h / 6, y: -h },\n { x: -2 * h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst rect_right_inv_arrow = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: 0, y: 0 },\n { x: w + h / 2, y: 0 },\n { x: w, y: -h / 2 },\n { x: w + h / 2, y: -h },\n { x: 0, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst cylinder = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const rx = w / 2;\n const ry = rx / (2.5 + w / 50);\n const h = bbox.height + ry + node.padding;\n const shape = \"M 0,\" + ry + \" a \" + rx + \",\" + ry + \" 0,0,0 \" + w + \" 0 a \" + rx + \",\" + ry + \" 0,0,0 \" + -w + \" 0 l 0,\" + h + \" a \" + rx + \",\" + ry + \" 0,0,0 \" + w + \" 0 l 0,\" + -h;\n const el = shapeSvg.attr(\"label-offset-y\", ry).insert(\"path\", \":first-child\").attr(\"style\", node.style).attr(\"d\", shape).attr(\"transform\", \"translate(\" + -w / 2 + \",\" + -(h / 2 + ry) + \")\");\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n const pos = intersect.rect(node, point2);\n const x = pos.x - node.x;\n if (rx != 0 && (Math.abs(x) < node.width / 2 || Math.abs(x) == node.width / 2 && Math.abs(pos.y - node.y) > node.height / 2 - ry)) {\n let y = ry * ry * (1 - x * x / (rx * rx));\n if (y != 0) {\n y = Math.sqrt(y);\n }\n y = ry - y;\n if (point2.y - node.y > 0) {\n y = -y;\n }\n pos.y += y;\n }\n return pos;\n };\n return shapeSvg;\n};\nconst rect = async (parent, node) => {\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n \"node \" + node.classes + \" \" + node.class,\n true\n );\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const totalWidth = bbox.width + node.padding;\n const totalHeight = bbox.height + node.padding;\n rect2.attr(\"class\", \"basic label-container\").attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", -bbox.width / 2 - halfPadding).attr(\"y\", -bbox.height / 2 - halfPadding).attr(\"width\", totalWidth).attr(\"height\", totalHeight);\n if (node.props) {\n const propKeys = new Set(Object.keys(node.props));\n if (node.props.borders) {\n applyNodePropertyBorders(rect2, node.props.borders, totalWidth, totalHeight);\n propKeys.delete(\"borders\");\n }\n propKeys.forEach((propKey) => {\n log.warn(`Unknown node property ${propKey}`);\n });\n }\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst labelRect = async (parent, node) => {\n const { shapeSvg } = await labelHelper(parent, node, \"label\", true);\n log.trace(\"Classes = \", node.class);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const totalWidth = 0;\n const totalHeight = 0;\n rect2.attr(\"width\", totalWidth).attr(\"height\", totalHeight);\n shapeSvg.attr(\"class\", \"label edgeLabel\");\n if (node.props) {\n const propKeys = new Set(Object.keys(node.props));\n if (node.props.borders) {\n applyNodePropertyBorders(rect2, node.props.borders, totalWidth, totalHeight);\n propKeys.delete(\"borders\");\n }\n propKeys.forEach((propKey) => {\n log.warn(`Unknown node property ${propKey}`);\n });\n }\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nfunction applyNodePropertyBorders(rect2, borders, totalWidth, totalHeight) {\n const strokeDashArray = [];\n const addBorder = (length) => {\n strokeDashArray.push(length, 0);\n };\n const skipBorder = (length) => {\n strokeDashArray.push(0, length);\n };\n if (borders.includes(\"t\")) {\n log.debug(\"add top border\");\n addBorder(totalWidth);\n } else {\n skipBorder(totalWidth);\n }\n if (borders.includes(\"r\")) {\n log.debug(\"add right border\");\n addBorder(totalHeight);\n } else {\n skipBorder(totalHeight);\n }\n if (borders.includes(\"b\")) {\n log.debug(\"add bottom border\");\n addBorder(totalWidth);\n } else {\n skipBorder(totalWidth);\n }\n if (borders.includes(\"l\")) {\n log.debug(\"add left border\");\n addBorder(totalHeight);\n } else {\n skipBorder(totalHeight);\n }\n rect2.attr(\"stroke-dasharray\", strokeDashArray.join(\" \"));\n}\nconst rectWithTitle = (parent, node) => {\n let classes;\n if (!node.classes) {\n classes = \"node default\";\n } else {\n classes = \"node \" + node.classes;\n }\n const shapeSvg = parent.insert(\"g\").attr(\"class\", classes).attr(\"id\", node.domId || node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const innerLine = shapeSvg.insert(\"line\");\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"label\");\n const text2 = node.labelText.flat ? node.labelText.flat() : node.labelText;\n let title = \"\";\n if (typeof text2 === \"object\") {\n title = text2[0];\n } else {\n title = text2;\n }\n log.info(\"Label text abc79\", title, text2, typeof text2 === \"object\");\n const text = label.node().appendChild(createLabel$1(title, node.labelStyle, true, true));\n let bbox = { width: 0, height: 0 };\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n log.info(\"Text 2\", text2);\n const textRows = text2.slice(1, text2.length);\n let titleBox = text.getBBox();\n const descr = label.node().appendChild(\n createLabel$1(textRows.join ? textRows.join(\"
      \") : textRows, node.labelStyle, true, true)\n );\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = descr.children[0];\n const dv = select(descr);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n const halfPadding = node.padding / 2;\n select(descr).attr(\n \"transform\",\n \"translate( \" + // (titleBox.width - bbox.width) / 2 +\n (bbox.width > titleBox.width ? 0 : (titleBox.width - bbox.width) / 2) + \", \" + (titleBox.height + halfPadding + 5) + \")\"\n );\n select(text).attr(\n \"transform\",\n \"translate( \" + // (titleBox.width - bbox.width) / 2 +\n (bbox.width < titleBox.width ? 0 : -(titleBox.width - bbox.width) / 2) + \", 0)\"\n );\n bbox = label.node().getBBox();\n label.attr(\n \"transform\",\n \"translate(\" + -bbox.width / 2 + \", \" + (-bbox.height / 2 - halfPadding + 3) + \")\"\n );\n rect2.attr(\"class\", \"outer title-state\").attr(\"x\", -bbox.width / 2 - halfPadding).attr(\"y\", -bbox.height / 2 - halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n innerLine.attr(\"class\", \"divider\").attr(\"x1\", -bbox.width / 2 - halfPadding).attr(\"x2\", bbox.width / 2 + halfPadding).attr(\"y1\", -bbox.height / 2 - halfPadding + titleBox.height + halfPadding).attr(\"y2\", -bbox.height / 2 - halfPadding + titleBox.height + halfPadding);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst stadium = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const h = bbox.height + node.padding;\n const w = bbox.width + h / 4 + node.padding;\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\").attr(\"style\", node.style).attr(\"rx\", h / 2).attr(\"ry\", h / 2).attr(\"x\", -w / 2).attr(\"y\", -h / 2).attr(\"width\", w).attr(\"height\", h);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst circle = async (parent, node) => {\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const circle2 = shapeSvg.insert(\"circle\", \":first-child\");\n circle2.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"r\", bbox.width / 2 + halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n log.info(\"Circle main\");\n updateNodeBounds(node, circle2);\n node.intersect = function(point2) {\n log.info(\"Circle intersect\", node, bbox.width / 2 + halfPadding, point2);\n return intersect.circle(node, bbox.width / 2 + halfPadding, point2);\n };\n return shapeSvg;\n};\nconst doublecircle = async (parent, node) => {\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const gap = 5;\n const circleGroup = shapeSvg.insert(\"g\", \":first-child\");\n const outerCircle = circleGroup.insert(\"circle\");\n const innerCircle = circleGroup.insert(\"circle\");\n circleGroup.attr(\"class\", node.class);\n outerCircle.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"r\", bbox.width / 2 + halfPadding + gap).attr(\"width\", bbox.width + node.padding + gap * 2).attr(\"height\", bbox.height + node.padding + gap * 2);\n innerCircle.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"r\", bbox.width / 2 + halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n log.info(\"DoubleCircle main\");\n updateNodeBounds(node, outerCircle);\n node.intersect = function(point2) {\n log.info(\"DoubleCircle intersect\", node, bbox.width / 2 + halfPadding + gap, point2);\n return intersect.circle(node, bbox.width / 2 + halfPadding + gap, point2);\n };\n return shapeSvg;\n};\nconst subroutine = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: 0, y: 0 },\n { x: w, y: 0 },\n { x: w, y: -h },\n { x: 0, y: -h },\n { x: 0, y: 0 },\n { x: -8, y: 0 },\n { x: w + 8, y: 0 },\n { x: w + 8, y: -h },\n { x: -8, y: -h },\n { x: -8, y: 0 }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst start = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n const circle2 = shapeSvg.insert(\"circle\", \":first-child\");\n circle2.attr(\"class\", \"state-start\").attr(\"r\", 7).attr(\"width\", 14).attr(\"height\", 14);\n updateNodeBounds(node, circle2);\n node.intersect = function(point2) {\n return intersect.circle(node, 7, point2);\n };\n return shapeSvg;\n};\nconst forkJoin = (parent, node, dir) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n let width = 70;\n let height = 10;\n if (dir === \"LR\") {\n width = 10;\n height = 70;\n }\n const shape = shapeSvg.append(\"rect\").attr(\"x\", -1 * width / 2).attr(\"y\", -1 * height / 2).attr(\"width\", width).attr(\"height\", height).attr(\"class\", \"fork-join\");\n updateNodeBounds(node, shape);\n node.height = node.height + node.padding / 2;\n node.width = node.width + node.padding / 2;\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst end = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n const innerCircle = shapeSvg.insert(\"circle\", \":first-child\");\n const circle2 = shapeSvg.insert(\"circle\", \":first-child\");\n circle2.attr(\"class\", \"state-start\").attr(\"r\", 7).attr(\"width\", 14).attr(\"height\", 14);\n innerCircle.attr(\"class\", \"state-end\").attr(\"r\", 5).attr(\"width\", 10).attr(\"height\", 10);\n updateNodeBounds(node, circle2);\n node.intersect = function(point2) {\n return intersect.circle(node, 7, point2);\n };\n return shapeSvg;\n};\nconst class_box = (parent, node) => {\n const halfPadding = node.padding / 2;\n const rowPadding = 4;\n const lineHeight = 8;\n let classes;\n if (!node.classes) {\n classes = \"node default\";\n } else {\n classes = \"node \" + node.classes;\n }\n const shapeSvg = parent.insert(\"g\").attr(\"class\", classes).attr(\"id\", node.domId || node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const topLine = shapeSvg.insert(\"line\");\n const bottomLine = shapeSvg.insert(\"line\");\n let maxWidth = 0;\n let maxHeight = rowPadding;\n const labelContainer = shapeSvg.insert(\"g\").attr(\"class\", \"label\");\n let verticalPos = 0;\n const hasInterface = node.classData.annotations && node.classData.annotations[0];\n const interfaceLabelText = node.classData.annotations[0] ? \"\u00AB\" + node.classData.annotations[0] + \"\u00BB\" : \"\";\n const interfaceLabel = labelContainer.node().appendChild(createLabel$1(interfaceLabelText, node.labelStyle, true, true));\n let interfaceBBox = interfaceLabel.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = interfaceLabel.children[0];\n const dv = select(interfaceLabel);\n interfaceBBox = div.getBoundingClientRect();\n dv.attr(\"width\", interfaceBBox.width);\n dv.attr(\"height\", interfaceBBox.height);\n }\n if (node.classData.annotations[0]) {\n maxHeight += interfaceBBox.height + rowPadding;\n maxWidth += interfaceBBox.width;\n }\n let classTitleString = node.classData.label;\n if (node.classData.type !== void 0 && node.classData.type !== \"\") {\n if (getConfig().flowchart.htmlLabels) {\n classTitleString += \"<\" + node.classData.type + \">\";\n } else {\n classTitleString += \"<\" + node.classData.type + \">\";\n }\n }\n const classTitleLabel = labelContainer.node().appendChild(createLabel$1(classTitleString, node.labelStyle, true, true));\n select(classTitleLabel).attr(\"class\", \"classTitle\");\n let classTitleBBox = classTitleLabel.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = classTitleLabel.children[0];\n const dv = select(classTitleLabel);\n classTitleBBox = div.getBoundingClientRect();\n dv.attr(\"width\", classTitleBBox.width);\n dv.attr(\"height\", classTitleBBox.height);\n }\n maxHeight += classTitleBBox.height + rowPadding;\n if (classTitleBBox.width > maxWidth) {\n maxWidth = classTitleBBox.width;\n }\n const classAttributes = [];\n node.classData.members.forEach((member) => {\n const parsedInfo = member.getDisplayDetails();\n let parsedText = parsedInfo.displayText;\n if (getConfig().flowchart.htmlLabels) {\n parsedText = parsedText.replace(//g, \">\");\n }\n const lbl = labelContainer.node().appendChild(\n createLabel$1(\n parsedText,\n parsedInfo.cssStyle ? parsedInfo.cssStyle : node.labelStyle,\n true,\n true\n )\n );\n let bbox = lbl.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = lbl.children[0];\n const dv = select(lbl);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n if (bbox.width > maxWidth) {\n maxWidth = bbox.width;\n }\n maxHeight += bbox.height + rowPadding;\n classAttributes.push(lbl);\n });\n maxHeight += lineHeight;\n const classMethods = [];\n node.classData.methods.forEach((member) => {\n const parsedInfo = member.getDisplayDetails();\n let displayText = parsedInfo.displayText;\n if (getConfig().flowchart.htmlLabels) {\n displayText = displayText.replace(//g, \">\");\n }\n const lbl = labelContainer.node().appendChild(\n createLabel$1(\n displayText,\n parsedInfo.cssStyle ? parsedInfo.cssStyle : node.labelStyle,\n true,\n true\n )\n );\n let bbox = lbl.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = lbl.children[0];\n const dv = select(lbl);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n if (bbox.width > maxWidth) {\n maxWidth = bbox.width;\n }\n maxHeight += bbox.height + rowPadding;\n classMethods.push(lbl);\n });\n maxHeight += lineHeight;\n if (hasInterface) {\n let diffX2 = (maxWidth - interfaceBBox.width) / 2;\n select(interfaceLabel).attr(\n \"transform\",\n \"translate( \" + (-1 * maxWidth / 2 + diffX2) + \", \" + -1 * maxHeight / 2 + \")\"\n );\n verticalPos = interfaceBBox.height + rowPadding;\n }\n let diffX = (maxWidth - classTitleBBox.width) / 2;\n select(classTitleLabel).attr(\n \"transform\",\n \"translate( \" + (-1 * maxWidth / 2 + diffX) + \", \" + (-1 * maxHeight / 2 + verticalPos) + \")\"\n );\n verticalPos += classTitleBBox.height + rowPadding;\n topLine.attr(\"class\", \"divider\").attr(\"x1\", -maxWidth / 2 - halfPadding).attr(\"x2\", maxWidth / 2 + halfPadding).attr(\"y1\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos).attr(\"y2\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos);\n verticalPos += lineHeight;\n classAttributes.forEach((lbl) => {\n select(lbl).attr(\n \"transform\",\n \"translate( \" + -maxWidth / 2 + \", \" + (-1 * maxHeight / 2 + verticalPos + lineHeight / 2) + \")\"\n );\n const memberBBox = lbl == null ? void 0 : lbl.getBBox();\n verticalPos += ((memberBBox == null ? void 0 : memberBBox.height) ?? 0) + rowPadding;\n });\n verticalPos += lineHeight;\n bottomLine.attr(\"class\", \"divider\").attr(\"x1\", -maxWidth / 2 - halfPadding).attr(\"x2\", maxWidth / 2 + halfPadding).attr(\"y1\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos).attr(\"y2\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos);\n verticalPos += lineHeight;\n classMethods.forEach((lbl) => {\n select(lbl).attr(\n \"transform\",\n \"translate( \" + -maxWidth / 2 + \", \" + (-1 * maxHeight / 2 + verticalPos) + \")\"\n );\n const memberBBox = lbl == null ? void 0 : lbl.getBBox();\n verticalPos += ((memberBBox == null ? void 0 : memberBBox.height) ?? 0) + rowPadding;\n });\n rect2.attr(\"class\", \"outer title-state\").attr(\"x\", -maxWidth / 2 - halfPadding).attr(\"y\", -(maxHeight / 2) - halfPadding).attr(\"width\", maxWidth + node.padding).attr(\"height\", maxHeight + node.padding);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst shapes = {\n rhombus: question,\n question,\n rect,\n labelRect,\n rectWithTitle,\n choice,\n circle,\n doublecircle,\n stadium,\n hexagon,\n rect_left_inv_arrow,\n lean_right,\n lean_left,\n trapezoid,\n inv_trapezoid,\n rect_right_inv_arrow,\n cylinder,\n start,\n end,\n note: note$1,\n subroutine,\n fork: forkJoin,\n join: forkJoin,\n class_box\n};\nlet nodeElems = {};\nconst insertNode = async (elem, node, dir) => {\n let newEl;\n let el;\n if (node.link) {\n let target;\n if (getConfig().securityLevel === \"sandbox\") {\n target = \"_top\";\n } else if (node.linkTarget) {\n target = node.linkTarget || \"_blank\";\n }\n newEl = elem.insert(\"svg:a\").attr(\"xlink:href\", node.link).attr(\"target\", target);\n el = await shapes[node.shape](newEl, node, dir);\n } else {\n el = await shapes[node.shape](elem, node, dir);\n newEl = el;\n }\n if (node.tooltip) {\n el.attr(\"title\", node.tooltip);\n }\n if (node.class) {\n el.attr(\"class\", \"node default \" + node.class);\n }\n nodeElems[node.id] = newEl;\n if (node.haveCallback) {\n nodeElems[node.id].attr(\"class\", nodeElems[node.id].attr(\"class\") + \" clickable\");\n }\n return newEl;\n};\nconst setNodeElem = (elem, node) => {\n nodeElems[node.id] = elem;\n};\nconst clear$1 = () => {\n nodeElems = {};\n};\nconst positionNode = (node) => {\n const el = nodeElems[node.id];\n log.trace(\n \"Transforming node\",\n node.diff,\n node,\n \"translate(\" + (node.x - node.width / 2 - 5) + \", \" + node.width / 2 + \")\"\n );\n const padding = 8;\n const diff = node.diff || 0;\n if (node.clusterNode) {\n el.attr(\n \"transform\",\n \"translate(\" + (node.x + diff - node.width / 2) + \", \" + (node.y - node.height / 2 - padding) + \")\"\n );\n } else {\n el.attr(\"transform\", \"translate(\" + node.x + \", \" + node.y + \")\");\n }\n return diff;\n};\nconst markerOffsets = {\n aggregation: 18,\n extension: 18,\n composition: 18,\n dependency: 6,\n lollipop: 13.5,\n arrow_point: 5.3\n};\nfunction calculateDeltaAndAngle(point1, point2) {\n point1 = pointTransformer(point1);\n point2 = pointTransformer(point2);\n const [x1, y1] = [point1.x, point1.y];\n const [x2, y2] = [point2.x, point2.y];\n const deltaX = x2 - x1;\n const deltaY = y2 - y1;\n return { angle: Math.atan(deltaY / deltaX), deltaX, deltaY };\n}\nconst pointTransformer = (data) => {\n if (Array.isArray(data)) {\n return { x: data[0], y: data[1] };\n }\n return data;\n};\nconst getLineFunctionsWithOffset = (edge) => {\n return {\n x: function(d, i, data) {\n let offset = 0;\n if (i === 0 && Object.hasOwn(markerOffsets, edge.arrowTypeStart)) {\n const { angle, deltaX } = calculateDeltaAndAngle(data[0], data[1]);\n offset = markerOffsets[edge.arrowTypeStart] * Math.cos(angle) * (deltaX >= 0 ? 1 : -1);\n } else if (i === data.length - 1 && Object.hasOwn(markerOffsets, edge.arrowTypeEnd)) {\n const { angle, deltaX } = calculateDeltaAndAngle(\n data[data.length - 1],\n data[data.length - 2]\n );\n offset = markerOffsets[edge.arrowTypeEnd] * Math.cos(angle) * (deltaX >= 0 ? 1 : -1);\n }\n return pointTransformer(d).x + offset;\n },\n y: function(d, i, data) {\n let offset = 0;\n if (i === 0 && Object.hasOwn(markerOffsets, edge.arrowTypeStart)) {\n const { angle, deltaY } = calculateDeltaAndAngle(data[0], data[1]);\n offset = markerOffsets[edge.arrowTypeStart] * Math.abs(Math.sin(angle)) * (deltaY >= 0 ? 1 : -1);\n } else if (i === data.length - 1 && Object.hasOwn(markerOffsets, edge.arrowTypeEnd)) {\n const { angle, deltaY } = calculateDeltaAndAngle(\n data[data.length - 1],\n data[data.length - 2]\n );\n offset = markerOffsets[edge.arrowTypeEnd] * Math.abs(Math.sin(angle)) * (deltaY >= 0 ? 1 : -1);\n }\n return pointTransformer(d).y + offset;\n }\n };\n};\nlet edgeLabels = {};\nlet terminalLabels = {};\nconst clear = () => {\n edgeLabels = {};\n terminalLabels = {};\n};\nconst insertEdgeLabel = (elem, edge) => {\n const useHtmlLabels = evaluate(getConfig().flowchart.htmlLabels);\n const labelElement = edge.labelType === \"markdown\" ? createText(elem, edge.label, {\n style: edge.labelStyle,\n useHtmlLabels,\n addSvgBackground: true\n }) : createLabel$1(edge.label, edge.labelStyle);\n log.info(\"abc82\", edge, edge.labelType);\n const edgeLabel = elem.insert(\"g\").attr(\"class\", \"edgeLabel\");\n const label = edgeLabel.insert(\"g\").attr(\"class\", \"label\");\n label.node().appendChild(labelElement);\n let bbox = labelElement.getBBox();\n if (useHtmlLabels) {\n const div = labelElement.children[0];\n const dv = select(labelElement);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n label.attr(\"transform\", \"translate(\" + -bbox.width / 2 + \", \" + -bbox.height / 2 + \")\");\n edgeLabels[edge.id] = edgeLabel;\n edge.width = bbox.width;\n edge.height = bbox.height;\n let fo;\n if (edge.startLabelLeft) {\n const startLabelElement = createLabel$1(edge.startLabelLeft, edge.labelStyle);\n const startEdgeLabelLeft = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = startEdgeLabelLeft.insert(\"g\").attr(\"class\", \"inner\");\n fo = inner.node().appendChild(startLabelElement);\n const slBox = startLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].startLeft = startEdgeLabelLeft;\n setTerminalWidth(fo, edge.startLabelLeft);\n }\n if (edge.startLabelRight) {\n const startLabelElement = createLabel$1(edge.startLabelRight, edge.labelStyle);\n const startEdgeLabelRight = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = startEdgeLabelRight.insert(\"g\").attr(\"class\", \"inner\");\n fo = startEdgeLabelRight.node().appendChild(startLabelElement);\n inner.node().appendChild(startLabelElement);\n const slBox = startLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].startRight = startEdgeLabelRight;\n setTerminalWidth(fo, edge.startLabelRight);\n }\n if (edge.endLabelLeft) {\n const endLabelElement = createLabel$1(edge.endLabelLeft, edge.labelStyle);\n const endEdgeLabelLeft = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = endEdgeLabelLeft.insert(\"g\").attr(\"class\", \"inner\");\n fo = inner.node().appendChild(endLabelElement);\n const slBox = endLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n endEdgeLabelLeft.node().appendChild(endLabelElement);\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].endLeft = endEdgeLabelLeft;\n setTerminalWidth(fo, edge.endLabelLeft);\n }\n if (edge.endLabelRight) {\n const endLabelElement = createLabel$1(edge.endLabelRight, edge.labelStyle);\n const endEdgeLabelRight = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = endEdgeLabelRight.insert(\"g\").attr(\"class\", \"inner\");\n fo = inner.node().appendChild(endLabelElement);\n const slBox = endLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n endEdgeLabelRight.node().appendChild(endLabelElement);\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].endRight = endEdgeLabelRight;\n setTerminalWidth(fo, edge.endLabelRight);\n }\n return labelElement;\n};\nfunction setTerminalWidth(fo, value) {\n if (getConfig().flowchart.htmlLabels && fo) {\n fo.style.width = value.length * 9 + \"px\";\n fo.style.height = \"12px\";\n }\n}\nconst positionEdgeLabel = (edge, paths) => {\n log.info(\"Moving label abc78 \", edge.id, edge.label, edgeLabels[edge.id]);\n let path = paths.updatedPath ? paths.updatedPath : paths.originalPath;\n if (edge.label) {\n const el = edgeLabels[edge.id];\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcLabelPosition(path);\n log.info(\n \"Moving label \" + edge.label + \" from (\",\n x,\n \",\",\n y,\n \") to (\",\n pos.x,\n \",\",\n pos.y,\n \") abc78\"\n );\n if (paths.updatedPath) {\n x = pos.x;\n y = pos.y;\n }\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.startLabelLeft) {\n const el = terminalLabels[edge.id].startLeft;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(edge.arrowTypeStart ? 10 : 0, \"start_left\", path);\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.startLabelRight) {\n const el = terminalLabels[edge.id].startRight;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(\n edge.arrowTypeStart ? 10 : 0,\n \"start_right\",\n path\n );\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.endLabelLeft) {\n const el = terminalLabels[edge.id].endLeft;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(edge.arrowTypeEnd ? 10 : 0, \"end_left\", path);\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.endLabelRight) {\n const el = terminalLabels[edge.id].endRight;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(edge.arrowTypeEnd ? 10 : 0, \"end_right\", path);\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n};\nconst outsideNode = (node, point2) => {\n const x = node.x;\n const y = node.y;\n const dx = Math.abs(point2.x - x);\n const dy = Math.abs(point2.y - y);\n const w = node.width / 2;\n const h = node.height / 2;\n if (dx >= w || dy >= h) {\n return true;\n }\n return false;\n};\nconst intersection = (node, outsidePoint, insidePoint) => {\n log.warn(`intersection calc abc89:\n outsidePoint: ${JSON.stringify(outsidePoint)}\n insidePoint : ${JSON.stringify(insidePoint)}\n node : x:${node.x} y:${node.y} w:${node.width} h:${node.height}`);\n const x = node.x;\n const y = node.y;\n const dx = Math.abs(x - insidePoint.x);\n const w = node.width / 2;\n let r = insidePoint.x < outsidePoint.x ? w - dx : w + dx;\n const h = node.height / 2;\n const Q = Math.abs(outsidePoint.y - insidePoint.y);\n const R = Math.abs(outsidePoint.x - insidePoint.x);\n if (Math.abs(y - outsidePoint.y) * w > Math.abs(x - outsidePoint.x) * h) {\n let q = insidePoint.y < outsidePoint.y ? outsidePoint.y - h - y : y - h - outsidePoint.y;\n r = R * q / Q;\n const res = {\n x: insidePoint.x < outsidePoint.x ? insidePoint.x + r : insidePoint.x - R + r,\n y: insidePoint.y < outsidePoint.y ? insidePoint.y + Q - q : insidePoint.y - Q + q\n };\n if (r === 0) {\n res.x = outsidePoint.x;\n res.y = outsidePoint.y;\n }\n if (R === 0) {\n res.x = outsidePoint.x;\n }\n if (Q === 0) {\n res.y = outsidePoint.y;\n }\n log.warn(`abc89 topp/bott calc, Q ${Q}, q ${q}, R ${R}, r ${r}`, res);\n return res;\n } else {\n if (insidePoint.x < outsidePoint.x) {\n r = outsidePoint.x - w - x;\n } else {\n r = x - w - outsidePoint.x;\n }\n let q = Q * r / R;\n let _x = insidePoint.x < outsidePoint.x ? insidePoint.x + R - r : insidePoint.x - R + r;\n let _y = insidePoint.y < outsidePoint.y ? insidePoint.y + q : insidePoint.y - q;\n log.warn(`sides calc abc89, Q ${Q}, q ${q}, R ${R}, r ${r}`, { _x, _y });\n if (r === 0) {\n _x = outsidePoint.x;\n _y = outsidePoint.y;\n }\n if (R === 0) {\n _x = outsidePoint.x;\n }\n if (Q === 0) {\n _y = outsidePoint.y;\n }\n return { x: _x, y: _y };\n }\n};\nconst cutPathAtIntersect = (_points, boundryNode) => {\n log.warn(\"abc88 cutPathAtIntersect\", _points, boundryNode);\n let points = [];\n let lastPointOutside = _points[0];\n let isInside = false;\n _points.forEach((point2) => {\n log.info(\"abc88 checking point\", point2, boundryNode);\n if (!outsideNode(boundryNode, point2) && !isInside) {\n const inter = intersection(boundryNode, lastPointOutside, point2);\n log.warn(\"abc88 inside\", point2, lastPointOutside, inter);\n log.warn(\"abc88 intersection\", inter);\n let pointPresent = false;\n points.forEach((p) => {\n pointPresent = pointPresent || p.x === inter.x && p.y === inter.y;\n });\n if (!points.some((e) => e.x === inter.x && e.y === inter.y)) {\n points.push(inter);\n } else {\n log.warn(\"abc88 no intersect\", inter, points);\n }\n isInside = true;\n } else {\n log.warn(\"abc88 outside\", point2, lastPointOutside);\n lastPointOutside = point2;\n if (!isInside) {\n points.push(point2);\n }\n }\n });\n log.warn(\"abc88 returning points\", points);\n return points;\n};\nconst insertEdge = function(elem, e, edge, clusterDb, diagramType, graph, id) {\n let points = edge.points;\n let pointsHasChanged = false;\n const tail = graph.node(e.v);\n var head = graph.node(e.w);\n log.info(\"abc88 InsertEdge: \", edge);\n if (head.intersect && tail.intersect) {\n points = points.slice(1, edge.points.length - 1);\n points.unshift(tail.intersect(points[0]));\n log.info(\n \"Last point\",\n points[points.length - 1],\n head,\n head.intersect(points[points.length - 1])\n );\n points.push(head.intersect(points[points.length - 1]));\n }\n if (edge.toCluster) {\n log.info(\"to cluster abc88\", clusterDb[edge.toCluster]);\n points = cutPathAtIntersect(edge.points, clusterDb[edge.toCluster].node);\n pointsHasChanged = true;\n }\n if (edge.fromCluster) {\n log.info(\"from cluster abc88\", clusterDb[edge.fromCluster]);\n points = cutPathAtIntersect(points.reverse(), clusterDb[edge.fromCluster].node).reverse();\n pointsHasChanged = true;\n }\n const lineData = points.filter((p) => !Number.isNaN(p.y));\n let curve = curveBasis;\n if (edge.curve && (diagramType === \"graph\" || diagramType === \"flowchart\")) {\n curve = edge.curve;\n }\n const { x, y } = getLineFunctionsWithOffset(edge);\n const lineFunction = line().x(x).y(y).curve(curve);\n let strokeClasses;\n switch (edge.thickness) {\n case \"normal\":\n strokeClasses = \"edge-thickness-normal\";\n break;\n case \"thick\":\n strokeClasses = \"edge-thickness-thick\";\n break;\n case \"invisible\":\n strokeClasses = \"edge-thickness-thick\";\n break;\n default:\n strokeClasses = \"\";\n }\n switch (edge.pattern) {\n case \"solid\":\n strokeClasses += \" edge-pattern-solid\";\n break;\n case \"dotted\":\n strokeClasses += \" edge-pattern-dotted\";\n break;\n case \"dashed\":\n strokeClasses += \" edge-pattern-dashed\";\n break;\n }\n const svgPath = elem.append(\"path\").attr(\"d\", lineFunction(lineData)).attr(\"id\", edge.id).attr(\"class\", \" \" + strokeClasses + (edge.classes ? \" \" + edge.classes : \"\")).attr(\"style\", edge.style);\n let url = \"\";\n if (getConfig().flowchart.arrowMarkerAbsolute || getConfig().state.arrowMarkerAbsolute) {\n url = window.location.protocol + \"//\" + window.location.host + window.location.pathname + window.location.search;\n url = url.replace(/\\(/g, \"\\\\(\");\n url = url.replace(/\\)/g, \"\\\\)\");\n }\n log.info(\"arrowTypeStart\", edge.arrowTypeStart);\n log.info(\"arrowTypeEnd\", edge.arrowTypeEnd);\n switch (edge.arrowTypeStart) {\n case \"arrow_cross\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-crossStart)\"\n );\n break;\n case \"arrow_point\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-pointStart)\"\n );\n break;\n case \"arrow_barb\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-barbStart)\"\n );\n break;\n case \"arrow_circle\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-circleStart)\"\n );\n break;\n case \"aggregation\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-aggregationStart)\"\n );\n break;\n case \"extension\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-extensionStart)\"\n );\n break;\n case \"composition\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-compositionStart)\"\n );\n break;\n case \"dependency\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-dependencyStart)\"\n );\n break;\n case \"lollipop\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-lollipopStart)\"\n );\n break;\n }\n switch (edge.arrowTypeEnd) {\n case \"arrow_cross\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-crossEnd)\");\n break;\n case \"arrow_point\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-pointEnd)\");\n break;\n case \"arrow_barb\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-barbEnd)\");\n break;\n case \"arrow_circle\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-circleEnd)\");\n break;\n case \"aggregation\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-aggregationEnd)\"\n );\n break;\n case \"extension\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-extensionEnd)\"\n );\n break;\n case \"composition\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-compositionEnd)\"\n );\n break;\n case \"dependency\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-dependencyEnd)\"\n );\n break;\n case \"lollipop\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-lollipopEnd)\"\n );\n break;\n }\n let paths = {};\n if (pointsHasChanged) {\n paths.updatedPath = points;\n }\n paths.originalPath = edge.points;\n return paths;\n};\nexport {\n insertMarkers$1 as a,\n clear$1 as b,\n createLabel$1 as c,\n clear as d,\n insertNode as e,\n insertEdgeLabel as f,\n insertEdge as g,\n positionEdgeLabel as h,\n intersectRect$1 as i,\n getLineFunctionsWithOffset as j,\n labelHelper as l,\n positionNode as p,\n setNodeElem as s,\n updateNodeBounds as u\n};\n"], + "sources": ["../../node_modules/mermaid/dist/edges-80f1ebb6.js"], + "sourcesContent": ["import { l as log, m as evaluate, c as getConfig, J as decodeEntities, d as sanitizeText, u as utils } from \"./mermaid-934d9bea.js\";\nimport { select, line, curveBasis } from \"d3\";\nimport { a as createText } from \"./createText-aebacdfe.js\";\nconst insertMarkers = (elem, markerArray, type, id) => {\n markerArray.forEach((markerName) => {\n markers[markerName](elem, type, id);\n });\n};\nconst extension = (elem, type, id) => {\n log.trace(\"Making markers for \", id);\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-extensionStart\").attr(\"class\", \"marker extension \" + type).attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,7 L18,13 V 1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-extensionEnd\").attr(\"class\", \"marker extension \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 V 13 L18,7 Z\");\n};\nconst composition = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-compositionStart\").attr(\"class\", \"marker composition \" + type).attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-compositionEnd\").attr(\"class\", \"marker composition \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n};\nconst aggregation = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-aggregationStart\").attr(\"class\", \"marker aggregation \" + type).attr(\"refX\", 18).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-aggregationEnd\").attr(\"class\", \"marker aggregation \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n};\nconst dependency = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-dependencyStart\").attr(\"class\", \"marker dependency \" + type).attr(\"refX\", 6).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 5,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-dependencyEnd\").attr(\"class\", \"marker dependency \" + type).attr(\"refX\", 13).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L14,7 L9,1 Z\");\n};\nconst lollipop = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-lollipopStart\").attr(\"class\", \"marker lollipop \" + type).attr(\"refX\", 13).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"circle\").attr(\"stroke\", \"black\").attr(\"fill\", \"transparent\").attr(\"cx\", 7).attr(\"cy\", 7).attr(\"r\", 6);\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-lollipopEnd\").attr(\"class\", \"marker lollipop \" + type).attr(\"refX\", 1).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"circle\").attr(\"stroke\", \"black\").attr(\"fill\", \"transparent\").attr(\"cx\", 7).attr(\"cy\", 7).attr(\"r\", 6);\n};\nconst point = (elem, type, id) => {\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-pointEnd\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", 6).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 0 0 L 10 5 L 0 10 z\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-pointStart\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", 4.5).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 12).attr(\"markerHeight\", 12).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 0 5 L 10 10 L 10 0 z\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n};\nconst circle$1 = (elem, type, id) => {\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-circleEnd\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", 11).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"circle\").attr(\"cx\", \"5\").attr(\"cy\", \"5\").attr(\"r\", \"5\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-circleStart\").attr(\"class\", \"marker \" + type).attr(\"viewBox\", \"0 0 10 10\").attr(\"refX\", -1).attr(\"refY\", 5).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"circle\").attr(\"cx\", \"5\").attr(\"cy\", \"5\").attr(\"r\", \"5\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 1).style(\"stroke-dasharray\", \"1,0\");\n};\nconst cross = (elem, type, id) => {\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-crossEnd\").attr(\"class\", \"marker cross \" + type).attr(\"viewBox\", \"0 0 11 11\").attr(\"refX\", 12).attr(\"refY\", 5.2).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 l 9,9 M 10,1 l -9,9\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 2).style(\"stroke-dasharray\", \"1,0\");\n elem.append(\"marker\").attr(\"id\", id + \"_\" + type + \"-crossStart\").attr(\"class\", \"marker cross \" + type).attr(\"viewBox\", \"0 0 11 11\").attr(\"refX\", -1).attr(\"refY\", 5.2).attr(\"markerUnits\", \"userSpaceOnUse\").attr(\"markerWidth\", 11).attr(\"markerHeight\", 11).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 l 9,9 M 10,1 l -9,9\").attr(\"class\", \"arrowMarkerPath\").style(\"stroke-width\", 2).style(\"stroke-dasharray\", \"1,0\");\n};\nconst barb = (elem, type, id) => {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", id + \"_\" + type + \"-barbEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 14).attr(\"markerUnits\", \"strokeWidth\").attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 19,7 L9,13 L14,7 L9,1 Z\");\n};\nconst markers = {\n extension,\n composition,\n aggregation,\n dependency,\n lollipop,\n point,\n circle: circle$1,\n cross,\n barb\n};\nconst insertMarkers$1 = insertMarkers;\nfunction applyStyle(dom, styleFn) {\n if (styleFn) {\n dom.attr(\"style\", styleFn);\n }\n}\nfunction addHtmlLabel(node) {\n const fo = select(document.createElementNS(\"http://www.w3.org/2000/svg\", \"foreignObject\"));\n const div = fo.append(\"xhtml:div\");\n const label = node.label;\n const labelClass = node.isNode ? \"nodeLabel\" : \"edgeLabel\";\n div.html(\n '\" + label + \"\"\n );\n applyStyle(div, node.labelStyle);\n div.style(\"display\", \"inline-block\");\n div.style(\"white-space\", \"nowrap\");\n div.attr(\"xmlns\", \"http://www.w3.org/1999/xhtml\");\n return fo.node();\n}\nconst createLabel = (_vertexText, style, isTitle, isNode) => {\n let vertexText = _vertexText || \"\";\n if (typeof vertexText === \"object\") {\n vertexText = vertexText[0];\n }\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n vertexText = vertexText.replace(/\\\\n|\\n/g, \"
      \");\n log.info(\"vertexText\" + vertexText);\n const node = {\n isNode,\n label: decodeEntities(vertexText).replace(\n /fa[blrs]?:fa-[\\w-]+/g,\n (s) => ``\n ),\n labelStyle: style.replace(\"fill:\", \"color:\")\n };\n let vertexNode = addHtmlLabel(node);\n return vertexNode;\n } else {\n const svgLabel = document.createElementNS(\"http://www.w3.org/2000/svg\", \"text\");\n svgLabel.setAttribute(\"style\", style.replace(\"color:\", \"fill:\"));\n let rows = [];\n if (typeof vertexText === \"string\") {\n rows = vertexText.split(/\\\\n|\\n|/gi);\n } else if (Array.isArray(vertexText)) {\n rows = vertexText;\n } else {\n rows = [];\n }\n for (const row of rows) {\n const tspan = document.createElementNS(\"http://www.w3.org/2000/svg\", \"tspan\");\n tspan.setAttributeNS(\"http://www.w3.org/XML/1998/namespace\", \"xml:space\", \"preserve\");\n tspan.setAttribute(\"dy\", \"1em\");\n tspan.setAttribute(\"x\", \"0\");\n if (isTitle) {\n tspan.setAttribute(\"class\", \"title-row\");\n } else {\n tspan.setAttribute(\"class\", \"row\");\n }\n tspan.textContent = row.trim();\n svgLabel.appendChild(tspan);\n }\n return svgLabel;\n }\n};\nconst createLabel$1 = createLabel;\nconst labelHelper = async (parent, node, _classes, isNode) => {\n let classes;\n const useHtmlLabels = node.useHtmlLabels || evaluate(getConfig().flowchart.htmlLabels);\n if (!_classes) {\n classes = \"node default\";\n } else {\n classes = _classes;\n }\n const shapeSvg = parent.insert(\"g\").attr(\"class\", classes).attr(\"id\", node.domId || node.id);\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"label\").attr(\"style\", node.labelStyle);\n let labelText;\n if (node.labelText === void 0) {\n labelText = \"\";\n } else {\n labelText = typeof node.labelText === \"string\" ? node.labelText : node.labelText[0];\n }\n const textNode = label.node();\n let text;\n if (node.labelType === \"markdown\") {\n text = createText(label, sanitizeText(decodeEntities(labelText), getConfig()), {\n useHtmlLabels,\n width: node.width || getConfig().flowchart.wrappingWidth,\n classes: \"markdown-node-label\"\n });\n } else {\n text = textNode.appendChild(\n createLabel$1(\n sanitizeText(decodeEntities(labelText), getConfig()),\n node.labelStyle,\n false,\n isNode\n )\n );\n }\n let bbox = text.getBBox();\n const halfPadding = node.padding / 2;\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n const images = div.getElementsByTagName(\"img\");\n if (images) {\n const noImgText = labelText.replace(/]*>/g, \"\").trim() === \"\";\n await Promise.all(\n [...images].map(\n (img) => new Promise((res) => {\n function setupImage() {\n img.style.display = \"flex\";\n img.style.flexDirection = \"column\";\n if (noImgText) {\n const bodyFontSize = getConfig().fontSize ? getConfig().fontSize : window.getComputedStyle(document.body).fontSize;\n const enlargingFactor = 5;\n img.style.width = parseInt(bodyFontSize, 10) * enlargingFactor + \"px\";\n } else {\n img.style.width = \"100%\";\n }\n res(img);\n }\n setTimeout(() => {\n if (img.complete) {\n setupImage();\n }\n });\n img.addEventListener(\"error\", setupImage);\n img.addEventListener(\"load\", setupImage);\n })\n )\n );\n }\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n if (useHtmlLabels) {\n label.attr(\"transform\", \"translate(\" + -bbox.width / 2 + \", \" + -bbox.height / 2 + \")\");\n } else {\n label.attr(\"transform\", \"translate(0, \" + -bbox.height / 2 + \")\");\n }\n if (node.centerLabel) {\n label.attr(\"transform\", \"translate(\" + -bbox.width / 2 + \", \" + -bbox.height / 2 + \")\");\n }\n label.insert(\"rect\", \":first-child\");\n return { shapeSvg, bbox, halfPadding, label };\n};\nconst updateNodeBounds = (node, element) => {\n const bbox = element.node().getBBox();\n node.width = bbox.width;\n node.height = bbox.height;\n};\nfunction insertPolygonShape(parent, w, h, points) {\n return parent.insert(\"polygon\", \":first-child\").attr(\n \"points\",\n points.map(function(d) {\n return d.x + \",\" + d.y;\n }).join(\" \")\n ).attr(\"class\", \"label-container\").attr(\"transform\", \"translate(\" + -w / 2 + \",\" + h / 2 + \")\");\n}\nfunction intersectNode(node, point2) {\n return node.intersect(point2);\n}\nfunction intersectEllipse(node, rx, ry, point2) {\n var cx = node.x;\n var cy = node.y;\n var px = cx - point2.x;\n var py = cy - point2.y;\n var det = Math.sqrt(rx * rx * py * py + ry * ry * px * px);\n var dx = Math.abs(rx * ry * px / det);\n if (point2.x < cx) {\n dx = -dx;\n }\n var dy = Math.abs(rx * ry * py / det);\n if (point2.y < cy) {\n dy = -dy;\n }\n return { x: cx + dx, y: cy + dy };\n}\nfunction intersectCircle(node, rx, point2) {\n return intersectEllipse(node, rx, rx, point2);\n}\nfunction intersectLine(p1, p2, q1, q2) {\n var a1, a2, b1, b2, c1, c2;\n var r1, r2, r3, r4;\n var denom, offset, num;\n var x, y;\n a1 = p2.y - p1.y;\n b1 = p1.x - p2.x;\n c1 = p2.x * p1.y - p1.x * p2.y;\n r3 = a1 * q1.x + b1 * q1.y + c1;\n r4 = a1 * q2.x + b1 * q2.y + c1;\n if (r3 !== 0 && r4 !== 0 && sameSign(r3, r4)) {\n return;\n }\n a2 = q2.y - q1.y;\n b2 = q1.x - q2.x;\n c2 = q2.x * q1.y - q1.x * q2.y;\n r1 = a2 * p1.x + b2 * p1.y + c2;\n r2 = a2 * p2.x + b2 * p2.y + c2;\n if (r1 !== 0 && r2 !== 0 && sameSign(r1, r2)) {\n return;\n }\n denom = a1 * b2 - a2 * b1;\n if (denom === 0) {\n return;\n }\n offset = Math.abs(denom / 2);\n num = b1 * c2 - b2 * c1;\n x = num < 0 ? (num - offset) / denom : (num + offset) / denom;\n num = a2 * c1 - a1 * c2;\n y = num < 0 ? (num - offset) / denom : (num + offset) / denom;\n return { x, y };\n}\nfunction sameSign(r1, r2) {\n return r1 * r2 > 0;\n}\nfunction intersectPolygon(node, polyPoints, point2) {\n var x1 = node.x;\n var y1 = node.y;\n var intersections = [];\n var minX = Number.POSITIVE_INFINITY;\n var minY = Number.POSITIVE_INFINITY;\n if (typeof polyPoints.forEach === \"function\") {\n polyPoints.forEach(function(entry) {\n minX = Math.min(minX, entry.x);\n minY = Math.min(minY, entry.y);\n });\n } else {\n minX = Math.min(minX, polyPoints.x);\n minY = Math.min(minY, polyPoints.y);\n }\n var left = x1 - node.width / 2 - minX;\n var top = y1 - node.height / 2 - minY;\n for (var i = 0; i < polyPoints.length; i++) {\n var p1 = polyPoints[i];\n var p2 = polyPoints[i < polyPoints.length - 1 ? i + 1 : 0];\n var intersect2 = intersectLine(\n node,\n point2,\n { x: left + p1.x, y: top + p1.y },\n { x: left + p2.x, y: top + p2.y }\n );\n if (intersect2) {\n intersections.push(intersect2);\n }\n }\n if (!intersections.length) {\n return node;\n }\n if (intersections.length > 1) {\n intersections.sort(function(p, q) {\n var pdx = p.x - point2.x;\n var pdy = p.y - point2.y;\n var distp = Math.sqrt(pdx * pdx + pdy * pdy);\n var qdx = q.x - point2.x;\n var qdy = q.y - point2.y;\n var distq = Math.sqrt(qdx * qdx + qdy * qdy);\n return distp < distq ? -1 : distp === distq ? 0 : 1;\n });\n }\n return intersections[0];\n}\nconst intersectRect = (node, point2) => {\n var x = node.x;\n var y = node.y;\n var dx = point2.x - x;\n var dy = point2.y - y;\n var w = node.width / 2;\n var h = node.height / 2;\n var sx, sy;\n if (Math.abs(dy) * w > Math.abs(dx) * h) {\n if (dy < 0) {\n h = -h;\n }\n sx = dy === 0 ? 0 : h * dx / dy;\n sy = h;\n } else {\n if (dx < 0) {\n w = -w;\n }\n sx = w;\n sy = dx === 0 ? 0 : w * dy / dx;\n }\n return { x: x + sx, y: y + sy };\n};\nconst intersectRect$1 = intersectRect;\nconst intersect = {\n node: intersectNode,\n circle: intersectCircle,\n ellipse: intersectEllipse,\n polygon: intersectPolygon,\n rect: intersectRect$1\n};\nconst note = async (parent, node) => {\n const useHtmlLabels = node.useHtmlLabels || getConfig().flowchart.htmlLabels;\n if (!useHtmlLabels) {\n node.centerLabel = true;\n }\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n \"node \" + node.classes,\n true\n );\n log.info(\"Classes = \", node.classes);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n rect2.attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", -bbox.width / 2 - halfPadding).attr(\"y\", -bbox.height / 2 - halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst note$1 = note;\nconst formatClass = (str) => {\n if (str) {\n return \" \" + str;\n }\n return \"\";\n};\nconst getClassesFromNode = (node, otherClasses) => {\n return `${otherClasses ? otherClasses : \"node default\"}${formatClass(node.classes)} ${formatClass(\n node.class\n )}`;\n};\nconst question = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const s = w + h;\n const points = [\n { x: s / 2, y: 0 },\n { x: s, y: -s / 2 },\n { x: s / 2, y: -s },\n { x: 0, y: -s / 2 }\n ];\n log.info(\"Question main (Circle)\");\n const questionElem = insertPolygonShape(shapeSvg, s, s, points);\n questionElem.attr(\"style\", node.style);\n updateNodeBounds(node, questionElem);\n node.intersect = function(point2) {\n log.warn(\"Intersect called\");\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst choice = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n const s = 28;\n const points = [\n { x: 0, y: s / 2 },\n { x: s / 2, y: 0 },\n { x: 0, y: -s / 2 },\n { x: -s / 2, y: 0 }\n ];\n const choice2 = shapeSvg.insert(\"polygon\", \":first-child\").attr(\n \"points\",\n points.map(function(d) {\n return d.x + \",\" + d.y;\n }).join(\" \")\n );\n choice2.attr(\"class\", \"state-start\").attr(\"r\", 7).attr(\"width\", 28).attr(\"height\", 28);\n node.width = 28;\n node.height = 28;\n node.intersect = function(point2) {\n return intersect.circle(node, 14, point2);\n };\n return shapeSvg;\n};\nconst hexagon = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const f = 4;\n const h = bbox.height + node.padding;\n const m = h / f;\n const w = bbox.width + 2 * m + node.padding;\n const points = [\n { x: m, y: 0 },\n { x: w - m, y: 0 },\n { x: w, y: -h / 2 },\n { x: w - m, y: -h },\n { x: m, y: -h },\n { x: 0, y: -h / 2 }\n ];\n const hex = insertPolygonShape(shapeSvg, w, h, points);\n hex.attr(\"style\", node.style);\n updateNodeBounds(node, hex);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst rect_left_inv_arrow = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: -h / 2, y: 0 },\n { x: w, y: 0 },\n { x: w, y: -h },\n { x: -h / 2, y: -h },\n { x: 0, y: -h / 2 }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n node.width = w + h;\n node.height = h;\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst lean_right = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(parent, node, getClassesFromNode(node), true);\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: -2 * h / 6, y: 0 },\n { x: w - h / 6, y: 0 },\n { x: w + 2 * h / 6, y: -h },\n { x: h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst lean_left = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: 2 * h / 6, y: 0 },\n { x: w + h / 6, y: 0 },\n { x: w - 2 * h / 6, y: -h },\n { x: -h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst trapezoid = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: -2 * h / 6, y: 0 },\n { x: w + 2 * h / 6, y: 0 },\n { x: w - h / 6, y: -h },\n { x: h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst inv_trapezoid = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: h / 6, y: 0 },\n { x: w - h / 6, y: 0 },\n { x: w + 2 * h / 6, y: -h },\n { x: -2 * h / 6, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst rect_right_inv_arrow = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: 0, y: 0 },\n { x: w + h / 2, y: 0 },\n { x: w, y: -h / 2 },\n { x: w + h / 2, y: -h },\n { x: 0, y: -h }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst cylinder = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const rx = w / 2;\n const ry = rx / (2.5 + w / 50);\n const h = bbox.height + ry + node.padding;\n const shape = \"M 0,\" + ry + \" a \" + rx + \",\" + ry + \" 0,0,0 \" + w + \" 0 a \" + rx + \",\" + ry + \" 0,0,0 \" + -w + \" 0 l 0,\" + h + \" a \" + rx + \",\" + ry + \" 0,0,0 \" + w + \" 0 l 0,\" + -h;\n const el = shapeSvg.attr(\"label-offset-y\", ry).insert(\"path\", \":first-child\").attr(\"style\", node.style).attr(\"d\", shape).attr(\"transform\", \"translate(\" + -w / 2 + \",\" + -(h / 2 + ry) + \")\");\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n const pos = intersect.rect(node, point2);\n const x = pos.x - node.x;\n if (rx != 0 && (Math.abs(x) < node.width / 2 || Math.abs(x) == node.width / 2 && Math.abs(pos.y - node.y) > node.height / 2 - ry)) {\n let y = ry * ry * (1 - x * x / (rx * rx));\n if (y != 0) {\n y = Math.sqrt(y);\n }\n y = ry - y;\n if (point2.y - node.y > 0) {\n y = -y;\n }\n pos.y += y;\n }\n return pos;\n };\n return shapeSvg;\n};\nconst rect = async (parent, node) => {\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n \"node \" + node.classes + \" \" + node.class,\n true\n );\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const totalWidth = bbox.width + node.padding;\n const totalHeight = bbox.height + node.padding;\n rect2.attr(\"class\", \"basic label-container\").attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", -bbox.width / 2 - halfPadding).attr(\"y\", -bbox.height / 2 - halfPadding).attr(\"width\", totalWidth).attr(\"height\", totalHeight);\n if (node.props) {\n const propKeys = new Set(Object.keys(node.props));\n if (node.props.borders) {\n applyNodePropertyBorders(rect2, node.props.borders, totalWidth, totalHeight);\n propKeys.delete(\"borders\");\n }\n propKeys.forEach((propKey) => {\n log.warn(`Unknown node property ${propKey}`);\n });\n }\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst labelRect = async (parent, node) => {\n const { shapeSvg } = await labelHelper(parent, node, \"label\", true);\n log.trace(\"Classes = \", node.class);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const totalWidth = 0;\n const totalHeight = 0;\n rect2.attr(\"width\", totalWidth).attr(\"height\", totalHeight);\n shapeSvg.attr(\"class\", \"label edgeLabel\");\n if (node.props) {\n const propKeys = new Set(Object.keys(node.props));\n if (node.props.borders) {\n applyNodePropertyBorders(rect2, node.props.borders, totalWidth, totalHeight);\n propKeys.delete(\"borders\");\n }\n propKeys.forEach((propKey) => {\n log.warn(`Unknown node property ${propKey}`);\n });\n }\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nfunction applyNodePropertyBorders(rect2, borders, totalWidth, totalHeight) {\n const strokeDashArray = [];\n const addBorder = (length) => {\n strokeDashArray.push(length, 0);\n };\n const skipBorder = (length) => {\n strokeDashArray.push(0, length);\n };\n if (borders.includes(\"t\")) {\n log.debug(\"add top border\");\n addBorder(totalWidth);\n } else {\n skipBorder(totalWidth);\n }\n if (borders.includes(\"r\")) {\n log.debug(\"add right border\");\n addBorder(totalHeight);\n } else {\n skipBorder(totalHeight);\n }\n if (borders.includes(\"b\")) {\n log.debug(\"add bottom border\");\n addBorder(totalWidth);\n } else {\n skipBorder(totalWidth);\n }\n if (borders.includes(\"l\")) {\n log.debug(\"add left border\");\n addBorder(totalHeight);\n } else {\n skipBorder(totalHeight);\n }\n rect2.attr(\"stroke-dasharray\", strokeDashArray.join(\" \"));\n}\nconst rectWithTitle = (parent, node) => {\n let classes;\n if (!node.classes) {\n classes = \"node default\";\n } else {\n classes = \"node \" + node.classes;\n }\n const shapeSvg = parent.insert(\"g\").attr(\"class\", classes).attr(\"id\", node.domId || node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const innerLine = shapeSvg.insert(\"line\");\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"label\");\n const text2 = node.labelText.flat ? node.labelText.flat() : node.labelText;\n let title = \"\";\n if (typeof text2 === \"object\") {\n title = text2[0];\n } else {\n title = text2;\n }\n log.info(\"Label text abc79\", title, text2, typeof text2 === \"object\");\n const text = label.node().appendChild(createLabel$1(title, node.labelStyle, true, true));\n let bbox = { width: 0, height: 0 };\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n log.info(\"Text 2\", text2);\n const textRows = text2.slice(1, text2.length);\n let titleBox = text.getBBox();\n const descr = label.node().appendChild(\n createLabel$1(textRows.join ? textRows.join(\"
      \") : textRows, node.labelStyle, true, true)\n );\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = descr.children[0];\n const dv = select(descr);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n const halfPadding = node.padding / 2;\n select(descr).attr(\n \"transform\",\n \"translate( \" + // (titleBox.width - bbox.width) / 2 +\n (bbox.width > titleBox.width ? 0 : (titleBox.width - bbox.width) / 2) + \", \" + (titleBox.height + halfPadding + 5) + \")\"\n );\n select(text).attr(\n \"transform\",\n \"translate( \" + // (titleBox.width - bbox.width) / 2 +\n (bbox.width < titleBox.width ? 0 : -(titleBox.width - bbox.width) / 2) + \", 0)\"\n );\n bbox = label.node().getBBox();\n label.attr(\n \"transform\",\n \"translate(\" + -bbox.width / 2 + \", \" + (-bbox.height / 2 - halfPadding + 3) + \")\"\n );\n rect2.attr(\"class\", \"outer title-state\").attr(\"x\", -bbox.width / 2 - halfPadding).attr(\"y\", -bbox.height / 2 - halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n innerLine.attr(\"class\", \"divider\").attr(\"x1\", -bbox.width / 2 - halfPadding).attr(\"x2\", bbox.width / 2 + halfPadding).attr(\"y1\", -bbox.height / 2 - halfPadding + titleBox.height + halfPadding).attr(\"y2\", -bbox.height / 2 - halfPadding + titleBox.height + halfPadding);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst stadium = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const h = bbox.height + node.padding;\n const w = bbox.width + h / 4 + node.padding;\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\").attr(\"style\", node.style).attr(\"rx\", h / 2).attr(\"ry\", h / 2).attr(\"x\", -w / 2).attr(\"y\", -h / 2).attr(\"width\", w).attr(\"height\", h);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst circle = async (parent, node) => {\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const circle2 = shapeSvg.insert(\"circle\", \":first-child\");\n circle2.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"r\", bbox.width / 2 + halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n log.info(\"Circle main\");\n updateNodeBounds(node, circle2);\n node.intersect = function(point2) {\n log.info(\"Circle intersect\", node, bbox.width / 2 + halfPadding, point2);\n return intersect.circle(node, bbox.width / 2 + halfPadding, point2);\n };\n return shapeSvg;\n};\nconst doublecircle = async (parent, node) => {\n const { shapeSvg, bbox, halfPadding } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const gap = 5;\n const circleGroup = shapeSvg.insert(\"g\", \":first-child\");\n const outerCircle = circleGroup.insert(\"circle\");\n const innerCircle = circleGroup.insert(\"circle\");\n circleGroup.attr(\"class\", node.class);\n outerCircle.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"r\", bbox.width / 2 + halfPadding + gap).attr(\"width\", bbox.width + node.padding + gap * 2).attr(\"height\", bbox.height + node.padding + gap * 2);\n innerCircle.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"r\", bbox.width / 2 + halfPadding).attr(\"width\", bbox.width + node.padding).attr(\"height\", bbox.height + node.padding);\n log.info(\"DoubleCircle main\");\n updateNodeBounds(node, outerCircle);\n node.intersect = function(point2) {\n log.info(\"DoubleCircle intersect\", node, bbox.width / 2 + halfPadding + gap, point2);\n return intersect.circle(node, bbox.width / 2 + halfPadding + gap, point2);\n };\n return shapeSvg;\n};\nconst subroutine = async (parent, node) => {\n const { shapeSvg, bbox } = await labelHelper(\n parent,\n node,\n getClassesFromNode(node, void 0),\n true\n );\n const w = bbox.width + node.padding;\n const h = bbox.height + node.padding;\n const points = [\n { x: 0, y: 0 },\n { x: w, y: 0 },\n { x: w, y: -h },\n { x: 0, y: -h },\n { x: 0, y: 0 },\n { x: -8, y: 0 },\n { x: w + 8, y: 0 },\n { x: w + 8, y: -h },\n { x: -8, y: -h },\n { x: -8, y: 0 }\n ];\n const el = insertPolygonShape(shapeSvg, w, h, points);\n el.attr(\"style\", node.style);\n updateNodeBounds(node, el);\n node.intersect = function(point2) {\n return intersect.polygon(node, points, point2);\n };\n return shapeSvg;\n};\nconst start = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n const circle2 = shapeSvg.insert(\"circle\", \":first-child\");\n circle2.attr(\"class\", \"state-start\").attr(\"r\", 7).attr(\"width\", 14).attr(\"height\", 14);\n updateNodeBounds(node, circle2);\n node.intersect = function(point2) {\n return intersect.circle(node, 7, point2);\n };\n return shapeSvg;\n};\nconst forkJoin = (parent, node, dir) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n let width = 70;\n let height = 10;\n if (dir === \"LR\") {\n width = 10;\n height = 70;\n }\n const shape = shapeSvg.append(\"rect\").attr(\"x\", -1 * width / 2).attr(\"y\", -1 * height / 2).attr(\"width\", width).attr(\"height\", height).attr(\"class\", \"fork-join\");\n updateNodeBounds(node, shape);\n node.height = node.height + node.padding / 2;\n node.width = node.width + node.padding / 2;\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst end = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"node default\").attr(\"id\", node.domId || node.id);\n const innerCircle = shapeSvg.insert(\"circle\", \":first-child\");\n const circle2 = shapeSvg.insert(\"circle\", \":first-child\");\n circle2.attr(\"class\", \"state-start\").attr(\"r\", 7).attr(\"width\", 14).attr(\"height\", 14);\n innerCircle.attr(\"class\", \"state-end\").attr(\"r\", 5).attr(\"width\", 10).attr(\"height\", 10);\n updateNodeBounds(node, circle2);\n node.intersect = function(point2) {\n return intersect.circle(node, 7, point2);\n };\n return shapeSvg;\n};\nconst class_box = (parent, node) => {\n const halfPadding = node.padding / 2;\n const rowPadding = 4;\n const lineHeight = 8;\n let classes;\n if (!node.classes) {\n classes = \"node default\";\n } else {\n classes = \"node \" + node.classes;\n }\n const shapeSvg = parent.insert(\"g\").attr(\"class\", classes).attr(\"id\", node.domId || node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const topLine = shapeSvg.insert(\"line\");\n const bottomLine = shapeSvg.insert(\"line\");\n let maxWidth = 0;\n let maxHeight = rowPadding;\n const labelContainer = shapeSvg.insert(\"g\").attr(\"class\", \"label\");\n let verticalPos = 0;\n const hasInterface = node.classData.annotations && node.classData.annotations[0];\n const interfaceLabelText = node.classData.annotations[0] ? \"\u00AB\" + node.classData.annotations[0] + \"\u00BB\" : \"\";\n const interfaceLabel = labelContainer.node().appendChild(createLabel$1(interfaceLabelText, node.labelStyle, true, true));\n let interfaceBBox = interfaceLabel.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = interfaceLabel.children[0];\n const dv = select(interfaceLabel);\n interfaceBBox = div.getBoundingClientRect();\n dv.attr(\"width\", interfaceBBox.width);\n dv.attr(\"height\", interfaceBBox.height);\n }\n if (node.classData.annotations[0]) {\n maxHeight += interfaceBBox.height + rowPadding;\n maxWidth += interfaceBBox.width;\n }\n let classTitleString = node.classData.label;\n if (node.classData.type !== void 0 && node.classData.type !== \"\") {\n if (getConfig().flowchart.htmlLabels) {\n classTitleString += \"<\" + node.classData.type + \">\";\n } else {\n classTitleString += \"<\" + node.classData.type + \">\";\n }\n }\n const classTitleLabel = labelContainer.node().appendChild(createLabel$1(classTitleString, node.labelStyle, true, true));\n select(classTitleLabel).attr(\"class\", \"classTitle\");\n let classTitleBBox = classTitleLabel.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = classTitleLabel.children[0];\n const dv = select(classTitleLabel);\n classTitleBBox = div.getBoundingClientRect();\n dv.attr(\"width\", classTitleBBox.width);\n dv.attr(\"height\", classTitleBBox.height);\n }\n maxHeight += classTitleBBox.height + rowPadding;\n if (classTitleBBox.width > maxWidth) {\n maxWidth = classTitleBBox.width;\n }\n const classAttributes = [];\n node.classData.members.forEach((member) => {\n const parsedInfo = member.getDisplayDetails();\n let parsedText = parsedInfo.displayText;\n if (getConfig().flowchart.htmlLabels) {\n parsedText = parsedText.replace(//g, \">\");\n }\n const lbl = labelContainer.node().appendChild(\n createLabel$1(\n parsedText,\n parsedInfo.cssStyle ? parsedInfo.cssStyle : node.labelStyle,\n true,\n true\n )\n );\n let bbox = lbl.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = lbl.children[0];\n const dv = select(lbl);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n if (bbox.width > maxWidth) {\n maxWidth = bbox.width;\n }\n maxHeight += bbox.height + rowPadding;\n classAttributes.push(lbl);\n });\n maxHeight += lineHeight;\n const classMethods = [];\n node.classData.methods.forEach((member) => {\n const parsedInfo = member.getDisplayDetails();\n let displayText = parsedInfo.displayText;\n if (getConfig().flowchart.htmlLabels) {\n displayText = displayText.replace(//g, \">\");\n }\n const lbl = labelContainer.node().appendChild(\n createLabel$1(\n displayText,\n parsedInfo.cssStyle ? parsedInfo.cssStyle : node.labelStyle,\n true,\n true\n )\n );\n let bbox = lbl.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = lbl.children[0];\n const dv = select(lbl);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n if (bbox.width > maxWidth) {\n maxWidth = bbox.width;\n }\n maxHeight += bbox.height + rowPadding;\n classMethods.push(lbl);\n });\n maxHeight += lineHeight;\n if (hasInterface) {\n let diffX2 = (maxWidth - interfaceBBox.width) / 2;\n select(interfaceLabel).attr(\n \"transform\",\n \"translate( \" + (-1 * maxWidth / 2 + diffX2) + \", \" + -1 * maxHeight / 2 + \")\"\n );\n verticalPos = interfaceBBox.height + rowPadding;\n }\n let diffX = (maxWidth - classTitleBBox.width) / 2;\n select(classTitleLabel).attr(\n \"transform\",\n \"translate( \" + (-1 * maxWidth / 2 + diffX) + \", \" + (-1 * maxHeight / 2 + verticalPos) + \")\"\n );\n verticalPos += classTitleBBox.height + rowPadding;\n topLine.attr(\"class\", \"divider\").attr(\"x1\", -maxWidth / 2 - halfPadding).attr(\"x2\", maxWidth / 2 + halfPadding).attr(\"y1\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos).attr(\"y2\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos);\n verticalPos += lineHeight;\n classAttributes.forEach((lbl) => {\n select(lbl).attr(\n \"transform\",\n \"translate( \" + -maxWidth / 2 + \", \" + (-1 * maxHeight / 2 + verticalPos + lineHeight / 2) + \")\"\n );\n const memberBBox = lbl == null ? void 0 : lbl.getBBox();\n verticalPos += ((memberBBox == null ? void 0 : memberBBox.height) ?? 0) + rowPadding;\n });\n verticalPos += lineHeight;\n bottomLine.attr(\"class\", \"divider\").attr(\"x1\", -maxWidth / 2 - halfPadding).attr(\"x2\", maxWidth / 2 + halfPadding).attr(\"y1\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos).attr(\"y2\", -maxHeight / 2 - halfPadding + lineHeight + verticalPos);\n verticalPos += lineHeight;\n classMethods.forEach((lbl) => {\n select(lbl).attr(\n \"transform\",\n \"translate( \" + -maxWidth / 2 + \", \" + (-1 * maxHeight / 2 + verticalPos) + \")\"\n );\n const memberBBox = lbl == null ? void 0 : lbl.getBBox();\n verticalPos += ((memberBBox == null ? void 0 : memberBBox.height) ?? 0) + rowPadding;\n });\n rect2.attr(\"class\", \"outer title-state\").attr(\"x\", -maxWidth / 2 - halfPadding).attr(\"y\", -(maxHeight / 2) - halfPadding).attr(\"width\", maxWidth + node.padding).attr(\"height\", maxHeight + node.padding);\n updateNodeBounds(node, rect2);\n node.intersect = function(point2) {\n return intersect.rect(node, point2);\n };\n return shapeSvg;\n};\nconst shapes = {\n rhombus: question,\n question,\n rect,\n labelRect,\n rectWithTitle,\n choice,\n circle,\n doublecircle,\n stadium,\n hexagon,\n rect_left_inv_arrow,\n lean_right,\n lean_left,\n trapezoid,\n inv_trapezoid,\n rect_right_inv_arrow,\n cylinder,\n start,\n end,\n note: note$1,\n subroutine,\n fork: forkJoin,\n join: forkJoin,\n class_box\n};\nlet nodeElems = {};\nconst insertNode = async (elem, node, dir) => {\n let newEl;\n let el;\n if (node.link) {\n let target;\n if (getConfig().securityLevel === \"sandbox\") {\n target = \"_top\";\n } else if (node.linkTarget) {\n target = node.linkTarget || \"_blank\";\n }\n newEl = elem.insert(\"svg:a\").attr(\"xlink:href\", node.link).attr(\"target\", target);\n el = await shapes[node.shape](newEl, node, dir);\n } else {\n el = await shapes[node.shape](elem, node, dir);\n newEl = el;\n }\n if (node.tooltip) {\n el.attr(\"title\", node.tooltip);\n }\n if (node.class) {\n el.attr(\"class\", \"node default \" + node.class);\n }\n nodeElems[node.id] = newEl;\n if (node.haveCallback) {\n nodeElems[node.id].attr(\"class\", nodeElems[node.id].attr(\"class\") + \" clickable\");\n }\n return newEl;\n};\nconst setNodeElem = (elem, node) => {\n nodeElems[node.id] = elem;\n};\nconst clear$1 = () => {\n nodeElems = {};\n};\nconst positionNode = (node) => {\n const el = nodeElems[node.id];\n log.trace(\n \"Transforming node\",\n node.diff,\n node,\n \"translate(\" + (node.x - node.width / 2 - 5) + \", \" + node.width / 2 + \")\"\n );\n const padding = 8;\n const diff = node.diff || 0;\n if (node.clusterNode) {\n el.attr(\n \"transform\",\n \"translate(\" + (node.x + diff - node.width / 2) + \", \" + (node.y - node.height / 2 - padding) + \")\"\n );\n } else {\n el.attr(\"transform\", \"translate(\" + node.x + \", \" + node.y + \")\");\n }\n return diff;\n};\nconst markerOffsets = {\n aggregation: 18,\n extension: 18,\n composition: 18,\n dependency: 6,\n lollipop: 13.5,\n arrow_point: 5.3\n};\nfunction calculateDeltaAndAngle(point1, point2) {\n point1 = pointTransformer(point1);\n point2 = pointTransformer(point2);\n const [x1, y1] = [point1.x, point1.y];\n const [x2, y2] = [point2.x, point2.y];\n const deltaX = x2 - x1;\n const deltaY = y2 - y1;\n return { angle: Math.atan(deltaY / deltaX), deltaX, deltaY };\n}\nconst pointTransformer = (data) => {\n if (Array.isArray(data)) {\n return { x: data[0], y: data[1] };\n }\n return data;\n};\nconst getLineFunctionsWithOffset = (edge) => {\n return {\n x: function(d, i, data) {\n let offset = 0;\n if (i === 0 && Object.hasOwn(markerOffsets, edge.arrowTypeStart)) {\n const { angle, deltaX } = calculateDeltaAndAngle(data[0], data[1]);\n offset = markerOffsets[edge.arrowTypeStart] * Math.cos(angle) * (deltaX >= 0 ? 1 : -1);\n } else if (i === data.length - 1 && Object.hasOwn(markerOffsets, edge.arrowTypeEnd)) {\n const { angle, deltaX } = calculateDeltaAndAngle(\n data[data.length - 1],\n data[data.length - 2]\n );\n offset = markerOffsets[edge.arrowTypeEnd] * Math.cos(angle) * (deltaX >= 0 ? 1 : -1);\n }\n return pointTransformer(d).x + offset;\n },\n y: function(d, i, data) {\n let offset = 0;\n if (i === 0 && Object.hasOwn(markerOffsets, edge.arrowTypeStart)) {\n const { angle, deltaY } = calculateDeltaAndAngle(data[0], data[1]);\n offset = markerOffsets[edge.arrowTypeStart] * Math.abs(Math.sin(angle)) * (deltaY >= 0 ? 1 : -1);\n } else if (i === data.length - 1 && Object.hasOwn(markerOffsets, edge.arrowTypeEnd)) {\n const { angle, deltaY } = calculateDeltaAndAngle(\n data[data.length - 1],\n data[data.length - 2]\n );\n offset = markerOffsets[edge.arrowTypeEnd] * Math.abs(Math.sin(angle)) * (deltaY >= 0 ? 1 : -1);\n }\n return pointTransformer(d).y + offset;\n }\n };\n};\nlet edgeLabels = {};\nlet terminalLabels = {};\nconst clear = () => {\n edgeLabels = {};\n terminalLabels = {};\n};\nconst insertEdgeLabel = (elem, edge) => {\n const useHtmlLabels = evaluate(getConfig().flowchart.htmlLabels);\n const labelElement = edge.labelType === \"markdown\" ? createText(elem, edge.label, {\n style: edge.labelStyle,\n useHtmlLabels,\n addSvgBackground: true\n }) : createLabel$1(edge.label, edge.labelStyle);\n log.info(\"abc82\", edge, edge.labelType);\n const edgeLabel = elem.insert(\"g\").attr(\"class\", \"edgeLabel\");\n const label = edgeLabel.insert(\"g\").attr(\"class\", \"label\");\n label.node().appendChild(labelElement);\n let bbox = labelElement.getBBox();\n if (useHtmlLabels) {\n const div = labelElement.children[0];\n const dv = select(labelElement);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n label.attr(\"transform\", \"translate(\" + -bbox.width / 2 + \", \" + -bbox.height / 2 + \")\");\n edgeLabels[edge.id] = edgeLabel;\n edge.width = bbox.width;\n edge.height = bbox.height;\n let fo;\n if (edge.startLabelLeft) {\n const startLabelElement = createLabel$1(edge.startLabelLeft, edge.labelStyle);\n const startEdgeLabelLeft = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = startEdgeLabelLeft.insert(\"g\").attr(\"class\", \"inner\");\n fo = inner.node().appendChild(startLabelElement);\n const slBox = startLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].startLeft = startEdgeLabelLeft;\n setTerminalWidth(fo, edge.startLabelLeft);\n }\n if (edge.startLabelRight) {\n const startLabelElement = createLabel$1(edge.startLabelRight, edge.labelStyle);\n const startEdgeLabelRight = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = startEdgeLabelRight.insert(\"g\").attr(\"class\", \"inner\");\n fo = startEdgeLabelRight.node().appendChild(startLabelElement);\n inner.node().appendChild(startLabelElement);\n const slBox = startLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].startRight = startEdgeLabelRight;\n setTerminalWidth(fo, edge.startLabelRight);\n }\n if (edge.endLabelLeft) {\n const endLabelElement = createLabel$1(edge.endLabelLeft, edge.labelStyle);\n const endEdgeLabelLeft = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = endEdgeLabelLeft.insert(\"g\").attr(\"class\", \"inner\");\n fo = inner.node().appendChild(endLabelElement);\n const slBox = endLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n endEdgeLabelLeft.node().appendChild(endLabelElement);\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].endLeft = endEdgeLabelLeft;\n setTerminalWidth(fo, edge.endLabelLeft);\n }\n if (edge.endLabelRight) {\n const endLabelElement = createLabel$1(edge.endLabelRight, edge.labelStyle);\n const endEdgeLabelRight = elem.insert(\"g\").attr(\"class\", \"edgeTerminals\");\n const inner = endEdgeLabelRight.insert(\"g\").attr(\"class\", \"inner\");\n fo = inner.node().appendChild(endLabelElement);\n const slBox = endLabelElement.getBBox();\n inner.attr(\"transform\", \"translate(\" + -slBox.width / 2 + \", \" + -slBox.height / 2 + \")\");\n endEdgeLabelRight.node().appendChild(endLabelElement);\n if (!terminalLabels[edge.id]) {\n terminalLabels[edge.id] = {};\n }\n terminalLabels[edge.id].endRight = endEdgeLabelRight;\n setTerminalWidth(fo, edge.endLabelRight);\n }\n return labelElement;\n};\nfunction setTerminalWidth(fo, value) {\n if (getConfig().flowchart.htmlLabels && fo) {\n fo.style.width = value.length * 9 + \"px\";\n fo.style.height = \"12px\";\n }\n}\nconst positionEdgeLabel = (edge, paths) => {\n log.info(\"Moving label abc78 \", edge.id, edge.label, edgeLabels[edge.id]);\n let path = paths.updatedPath ? paths.updatedPath : paths.originalPath;\n if (edge.label) {\n const el = edgeLabels[edge.id];\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcLabelPosition(path);\n log.info(\n \"Moving label \" + edge.label + \" from (\",\n x,\n \",\",\n y,\n \") to (\",\n pos.x,\n \",\",\n pos.y,\n \") abc78\"\n );\n if (paths.updatedPath) {\n x = pos.x;\n y = pos.y;\n }\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.startLabelLeft) {\n const el = terminalLabels[edge.id].startLeft;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(edge.arrowTypeStart ? 10 : 0, \"start_left\", path);\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.startLabelRight) {\n const el = terminalLabels[edge.id].startRight;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(\n edge.arrowTypeStart ? 10 : 0,\n \"start_right\",\n path\n );\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.endLabelLeft) {\n const el = terminalLabels[edge.id].endLeft;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(edge.arrowTypeEnd ? 10 : 0, \"end_left\", path);\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n if (edge.endLabelRight) {\n const el = terminalLabels[edge.id].endRight;\n let x = edge.x;\n let y = edge.y;\n if (path) {\n const pos = utils.calcTerminalLabelPosition(edge.arrowTypeEnd ? 10 : 0, \"end_right\", path);\n x = pos.x;\n y = pos.y;\n }\n el.attr(\"transform\", \"translate(\" + x + \", \" + y + \")\");\n }\n};\nconst outsideNode = (node, point2) => {\n const x = node.x;\n const y = node.y;\n const dx = Math.abs(point2.x - x);\n const dy = Math.abs(point2.y - y);\n const w = node.width / 2;\n const h = node.height / 2;\n if (dx >= w || dy >= h) {\n return true;\n }\n return false;\n};\nconst intersection = (node, outsidePoint, insidePoint) => {\n log.warn(`intersection calc abc89:\n outsidePoint: ${JSON.stringify(outsidePoint)}\n insidePoint : ${JSON.stringify(insidePoint)}\n node : x:${node.x} y:${node.y} w:${node.width} h:${node.height}`);\n const x = node.x;\n const y = node.y;\n const dx = Math.abs(x - insidePoint.x);\n const w = node.width / 2;\n let r = insidePoint.x < outsidePoint.x ? w - dx : w + dx;\n const h = node.height / 2;\n const Q = Math.abs(outsidePoint.y - insidePoint.y);\n const R = Math.abs(outsidePoint.x - insidePoint.x);\n if (Math.abs(y - outsidePoint.y) * w > Math.abs(x - outsidePoint.x) * h) {\n let q = insidePoint.y < outsidePoint.y ? outsidePoint.y - h - y : y - h - outsidePoint.y;\n r = R * q / Q;\n const res = {\n x: insidePoint.x < outsidePoint.x ? insidePoint.x + r : insidePoint.x - R + r,\n y: insidePoint.y < outsidePoint.y ? insidePoint.y + Q - q : insidePoint.y - Q + q\n };\n if (r === 0) {\n res.x = outsidePoint.x;\n res.y = outsidePoint.y;\n }\n if (R === 0) {\n res.x = outsidePoint.x;\n }\n if (Q === 0) {\n res.y = outsidePoint.y;\n }\n log.warn(`abc89 topp/bott calc, Q ${Q}, q ${q}, R ${R}, r ${r}`, res);\n return res;\n } else {\n if (insidePoint.x < outsidePoint.x) {\n r = outsidePoint.x - w - x;\n } else {\n r = x - w - outsidePoint.x;\n }\n let q = Q * r / R;\n let _x = insidePoint.x < outsidePoint.x ? insidePoint.x + R - r : insidePoint.x - R + r;\n let _y = insidePoint.y < outsidePoint.y ? insidePoint.y + q : insidePoint.y - q;\n log.warn(`sides calc abc89, Q ${Q}, q ${q}, R ${R}, r ${r}`, { _x, _y });\n if (r === 0) {\n _x = outsidePoint.x;\n _y = outsidePoint.y;\n }\n if (R === 0) {\n _x = outsidePoint.x;\n }\n if (Q === 0) {\n _y = outsidePoint.y;\n }\n return { x: _x, y: _y };\n }\n};\nconst cutPathAtIntersect = (_points, boundryNode) => {\n log.warn(\"abc88 cutPathAtIntersect\", _points, boundryNode);\n let points = [];\n let lastPointOutside = _points[0];\n let isInside = false;\n _points.forEach((point2) => {\n log.info(\"abc88 checking point\", point2, boundryNode);\n if (!outsideNode(boundryNode, point2) && !isInside) {\n const inter = intersection(boundryNode, lastPointOutside, point2);\n log.warn(\"abc88 inside\", point2, lastPointOutside, inter);\n log.warn(\"abc88 intersection\", inter);\n let pointPresent = false;\n points.forEach((p) => {\n pointPresent = pointPresent || p.x === inter.x && p.y === inter.y;\n });\n if (!points.some((e) => e.x === inter.x && e.y === inter.y)) {\n points.push(inter);\n } else {\n log.warn(\"abc88 no intersect\", inter, points);\n }\n isInside = true;\n } else {\n log.warn(\"abc88 outside\", point2, lastPointOutside);\n lastPointOutside = point2;\n if (!isInside) {\n points.push(point2);\n }\n }\n });\n log.warn(\"abc88 returning points\", points);\n return points;\n};\nconst insertEdge = function(elem, e, edge, clusterDb, diagramType, graph, id) {\n let points = edge.points;\n let pointsHasChanged = false;\n const tail = graph.node(e.v);\n var head = graph.node(e.w);\n log.info(\"abc88 InsertEdge: \", edge);\n if (head.intersect && tail.intersect) {\n points = points.slice(1, edge.points.length - 1);\n points.unshift(tail.intersect(points[0]));\n log.info(\n \"Last point\",\n points[points.length - 1],\n head,\n head.intersect(points[points.length - 1])\n );\n points.push(head.intersect(points[points.length - 1]));\n }\n if (edge.toCluster) {\n log.info(\"to cluster abc88\", clusterDb[edge.toCluster]);\n points = cutPathAtIntersect(edge.points, clusterDb[edge.toCluster].node);\n pointsHasChanged = true;\n }\n if (edge.fromCluster) {\n log.info(\"from cluster abc88\", clusterDb[edge.fromCluster]);\n points = cutPathAtIntersect(points.reverse(), clusterDb[edge.fromCluster].node).reverse();\n pointsHasChanged = true;\n }\n const lineData = points.filter((p) => !Number.isNaN(p.y));\n let curve = curveBasis;\n if (edge.curve && (diagramType === \"graph\" || diagramType === \"flowchart\")) {\n curve = edge.curve;\n }\n const { x, y } = getLineFunctionsWithOffset(edge);\n const lineFunction = line().x(x).y(y).curve(curve);\n let strokeClasses;\n switch (edge.thickness) {\n case \"normal\":\n strokeClasses = \"edge-thickness-normal\";\n break;\n case \"thick\":\n strokeClasses = \"edge-thickness-thick\";\n break;\n case \"invisible\":\n strokeClasses = \"edge-thickness-thick\";\n break;\n default:\n strokeClasses = \"\";\n }\n switch (edge.pattern) {\n case \"solid\":\n strokeClasses += \" edge-pattern-solid\";\n break;\n case \"dotted\":\n strokeClasses += \" edge-pattern-dotted\";\n break;\n case \"dashed\":\n strokeClasses += \" edge-pattern-dashed\";\n break;\n }\n const svgPath = elem.append(\"path\").attr(\"d\", lineFunction(lineData)).attr(\"id\", edge.id).attr(\"class\", \" \" + strokeClasses + (edge.classes ? \" \" + edge.classes : \"\")).attr(\"style\", edge.style);\n let url = \"\";\n if (getConfig().flowchart.arrowMarkerAbsolute || getConfig().state.arrowMarkerAbsolute) {\n url = window.location.protocol + \"//\" + window.location.host + window.location.pathname + window.location.search;\n url = url.replace(/\\(/g, \"\\\\(\");\n url = url.replace(/\\)/g, \"\\\\)\");\n }\n log.info(\"arrowTypeStart\", edge.arrowTypeStart);\n log.info(\"arrowTypeEnd\", edge.arrowTypeEnd);\n switch (edge.arrowTypeStart) {\n case \"arrow_cross\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-crossStart)\"\n );\n break;\n case \"arrow_point\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-pointStart)\"\n );\n break;\n case \"arrow_barb\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-barbStart)\"\n );\n break;\n case \"arrow_circle\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-circleStart)\"\n );\n break;\n case \"aggregation\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-aggregationStart)\"\n );\n break;\n case \"extension\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-extensionStart)\"\n );\n break;\n case \"composition\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-compositionStart)\"\n );\n break;\n case \"dependency\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-dependencyStart)\"\n );\n break;\n case \"lollipop\":\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-lollipopStart)\"\n );\n break;\n }\n switch (edge.arrowTypeEnd) {\n case \"arrow_cross\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-crossEnd)\");\n break;\n case \"arrow_point\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-pointEnd)\");\n break;\n case \"arrow_barb\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-barbEnd)\");\n break;\n case \"arrow_circle\":\n svgPath.attr(\"marker-end\", \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-circleEnd)\");\n break;\n case \"aggregation\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-aggregationEnd)\"\n );\n break;\n case \"extension\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-extensionEnd)\"\n );\n break;\n case \"composition\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-compositionEnd)\"\n );\n break;\n case \"dependency\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-dependencyEnd)\"\n );\n break;\n case \"lollipop\":\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + id + \"_\" + diagramType + \"-lollipopEnd)\"\n );\n break;\n }\n let paths = {};\n if (pointsHasChanged) {\n paths.updatedPath = points;\n }\n paths.originalPath = edge.points;\n return paths;\n};\nexport {\n insertMarkers$1 as a,\n clear$1 as b,\n createLabel$1 as c,\n clear as d,\n insertNode as e,\n insertEdgeLabel as f,\n insertEdge as g,\n positionEdgeLabel as h,\n intersectRect$1 as i,\n getLineFunctionsWithOffset as j,\n labelHelper as l,\n positionNode as p,\n setNodeElem as s,\n updateNodeBounds as u\n};\n"], "mappings": "sJAGA,IAAMA,GAAgB,CAACC,EAAMC,EAAaC,EAAMC,IAAO,CACrDF,EAAY,QAASG,GAAe,CAClCC,GAAQD,CAAU,EAAEJ,EAAME,EAAMC,CAAE,CACpC,CAAC,CACH,EACMG,GAAY,CAACN,EAAME,EAAMC,IAAO,CACpCI,EAAI,MAAM,sBAAuBJ,CAAE,EACnCH,EAAK,OAAO,MAAM,EAAE,OAAO,QAAQ,EAAE,KAAK,KAAMG,EAAK,IAAMD,EAAO,iBAAiB,EAAE,KAAK,QA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KAAK,aAAc,OAASC,EAAM,IAAM3R,EAAK,IAAM+Q,EAAc,WAAW,EACpF,MACF,IAAK,eACHW,EAAQ,KAAK,aAAc,OAASC,EAAM,IAAM3R,EAAK,IAAM+Q,EAAc,aAAa,EACtF,MACF,IAAK,cACHW,EAAQ,KACN,aACA,OAASC,EAAM,IAAM3R,EAAK,IAAM+Q,EAAc,kBAChD,EACA,MACF,IAAK,YACHW,EAAQ,KACN,aACA,OAASC,EAAM,IAAM3R,EAAK,IAAM+Q,EAAc,gBAChD,EACA,MACF,IAAK,cACHW,EAAQ,KACN,aACA,OAASC,EAAM,IAAM3R,EAAK,IAAM+Q,EAAc,kBAChD,EACA,MACF,IAAK,aACHW,EAAQ,KACN,aACA,OAASC,EAAM,IAAM3R,EAAK,IAAM+Q,EAAc,iBAChD,EACA,MACF,IAAK,WACHW,EAAQ,KACN,aACA,OAASC,EAAM,IAAM3R,EAAK,IAAM+Q,EAAc,eAChD,EACA,KACJ,CACA,IAAItB,EAAQ,CAAC,EACb,OAAIwB,IACFxB,EAAM,YAAcxL,GAEtBwL,EAAM,aAAenB,EAAK,OACnBmB,CACT", "names": ["insertMarkers", "elem", "markerArray", "type", "id", "markerName", "markers", "extension", "log$1", "composition", "aggregation", "dependency", "lollipop", "point", "circle$1", "cross", "barb", "insertMarkers$1", "applyStyle", "dom", "styleFn", "addHtmlLabel", "node", "fo", "select_default", "div", "label", "labelClass", "createLabel", "_vertexText", "style", "isTitle", "isNode", "vertexText", "evaluate", "getConfig", "decodeEntities", "s", "svgLabel", "rows", "row", "tspan", "createLabel$1", "labelHelper", "parent", "_classes", "classes", "useHtmlLabels", "shapeSvg", "labelText", "textNode", "text", "createText", "sanitizeText$2", "bbox", "halfPadding", "dv", "images", "noImgText", "img", "res", "setupImage", "bodyFontSize", "enlargingFactor", "updateNodeBounds", "element", "insertPolygonShape", "w", "h", "points", "d", "intersectNode", "point2", "intersectEllipse", "rx", "ry", "cx", "cy", "px", "py", "det", "dx", "dy", "intersectCircle", "intersectLine", "p1", "p2", "q1", "q2", "a1", "a2", "b1", "b2", "c1", "c2", "r1", "r2", "r3", "r4", "denom", "offset", "num", "x", "y", "sameSign", "intersectPolygon", "polyPoints", "x1", "y1", "intersections", "minX", "minY", "entry", "left", "top", "i", "intersect2", "p", "q", "pdx", "pdy", "distp", "qdx", "qdy", "distq", "intersectRect", "sx", "sy", "intersectRect$1", "intersect", "note", "rect2", "note$1", "formatClass", "str", "getClassesFromNode", "otherClasses", "question", "questionElem", "choice", "hexagon", "f", "m", "hex", "rect_left_inv_arrow", "lean_right", "el", "lean_left", "trapezoid", "inv_trapezoid", "rect_right_inv_arrow", "cylinder", "shape", "pos", "rect", "totalWidth", "totalHeight", "propKeys", "applyNodePropertyBorders", "propKey", "labelRect", "borders", "strokeDashArray", "addBorder", "length", "skipBorder", "rectWithTitle", "innerLine", "text2", "title", "textRows", "titleBox", "descr", "stadium", "circle", "circle2", "doublecircle", "gap", "circleGroup", "outerCircle", "innerCircle", "subroutine", "start", "forkJoin", "dir", "width", "height", "end", "class_box", "rowPadding", "lineHeight", "topLine", "bottomLine", "maxWidth", "maxHeight", "labelContainer", "verticalPos", "hasInterface", "interfaceLabelText", "interfaceLabel", "interfaceBBox", "classTitleString", "classTitleLabel", "classTitleBBox", "classAttributes", "member", "parsedInfo", "parsedText", "lbl", "classMethods", "displayText", "diffX2", "diffX", "memberBBox", "shapes", "nodeElems", "insertNode", "newEl", "target", "setNodeElem", "clear$1", "positionNode", "padding", "diff", "markerOffsets", "calculateDeltaAndAngle", "point1", "pointTransformer", "x2", "y2", "deltaX", "deltaY", "data", "getLineFunctionsWithOffset", "edge", "angle", "edgeLabels", "terminalLabels", "clear", "insertEdgeLabel", "labelElement", "edgeLabel", "startLabelElement", "startEdgeLabelLeft", "inner", "slBox", "setTerminalWidth", "startEdgeLabelRight", "endLabelElement", "endEdgeLabelLeft", "endEdgeLabelRight", "value", "positionEdgeLabel", "paths", "path", "utils", "outsideNode", "intersection", "outsidePoint", "insidePoint", "r", "Q", "R", "_x", "_y", "cutPathAtIntersect", "_points", "boundryNode", "lastPointOutside", "isInside", "inter", "pointPresent", "e", "insertEdge", "clusterDb", "diagramType", "graph", "pointsHasChanged", "tail", "head", "lineData", "curve", "basis_default", "lineFunction", "line_default", "strokeClasses", "svgPath", "url"] } diff --git a/docs/public/chunk-RUC4INDL.min.js b/docs/public/chunk-OZIWJXOC.min.js similarity index 92% rename from docs/public/chunk-RUC4INDL.min.js rename to docs/public/chunk-OZIWJXOC.min.js index cfa47107..85583fd7 100644 --- a/docs/public/chunk-RUC4INDL.min.js +++ b/docs/public/chunk-OZIWJXOC.min.js @@ -1,2 +1,2 @@ -import{Ha as o,c as l}from"./chunk-65WDIALL.min.js";import{d as c}from"./chunk-P42HNYSU.min.js";var i=c(l(),1);var x=(s,t)=>{let r=s.append("rect");if(r.attr("x",t.x),r.attr("y",t.y),r.attr("fill",t.fill),r.attr("stroke",t.stroke),r.attr("width",t.width),r.attr("height",t.height),t.rx!==void 0&&r.attr("rx",t.rx),t.ry!==void 0&&r.attr("ry",t.ry),t.attrs!==void 0)for(let e in t.attrs)r.attr(e,t.attrs[e]);return t.class!==void 0&&r.attr("class",t.class),r},h=(s,t)=>{let r={x:t.startx,y:t.starty,width:t.stopx-t.startx,height:t.stopy-t.starty,fill:t.fill,stroke:t.stroke,class:"rect"};x(s,r).lower()},y=(s,t)=>{let r=t.text.replace(o," "),e=s.append("text");e.attr("x",t.x),e.attr("y",t.y),e.attr("class","legend"),e.style("text-anchor",t.anchor),t.class!==void 0&&e.attr("class",t.class);let n=e.append("tspan");return n.attr("x",t.x+t.textMargin*2),n.text(r),e},p=(s,t,r,e)=>{let n=s.append("image");n.attr("x",t),n.attr("y",r);let a=(0,i.sanitizeUrl)(e);n.attr("xlink:href",a)},g=(s,t,r,e)=>{let n=s.append("use");n.attr("x",t),n.attr("y",r);let a=(0,i.sanitizeUrl)(e);n.attr("xlink:href",`#${a}`)},m=()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),f=()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0});export{x as a,h as b,y as c,p as d,g as e,m as f,f as g}; -//# sourceMappingURL=chunk-RUC4INDL.min.js.map +import{Ha as o,c as l}from"./chunk-JUXSCBYR.min.js";import{d as c}from"./chunk-P42HNYSU.min.js";var i=c(l(),1);var x=(s,t)=>{let r=s.append("rect");if(r.attr("x",t.x),r.attr("y",t.y),r.attr("fill",t.fill),r.attr("stroke",t.stroke),r.attr("width",t.width),r.attr("height",t.height),t.rx!==void 0&&r.attr("rx",t.rx),t.ry!==void 0&&r.attr("ry",t.ry),t.attrs!==void 0)for(let e in t.attrs)r.attr(e,t.attrs[e]);return t.class!==void 0&&r.attr("class",t.class),r},h=(s,t)=>{let r={x:t.startx,y:t.starty,width:t.stopx-t.startx,height:t.stopy-t.starty,fill:t.fill,stroke:t.stroke,class:"rect"};x(s,r).lower()},y=(s,t)=>{let r=t.text.replace(o," "),e=s.append("text");e.attr("x",t.x),e.attr("y",t.y),e.attr("class","legend"),e.style("text-anchor",t.anchor),t.class!==void 0&&e.attr("class",t.class);let n=e.append("tspan");return n.attr("x",t.x+t.textMargin*2),n.text(r),e},p=(s,t,r,e)=>{let n=s.append("image");n.attr("x",t),n.attr("y",r);let a=(0,i.sanitizeUrl)(e);n.attr("xlink:href",a)},g=(s,t,r,e)=>{let n=s.append("use");n.attr("x",t),n.attr("y",r);let a=(0,i.sanitizeUrl)(e);n.attr("xlink:href",`#${a}`)},m=()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),f=()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0});export{x as a,h as b,y as c,p as d,g as e,m as f,f as g}; +//# sourceMappingURL=chunk-OZIWJXOC.min.js.map diff --git a/docs/public/chunk-RUC4INDL.min.js.map b/docs/public/chunk-OZIWJXOC.min.js.map similarity index 97% rename from docs/public/chunk-RUC4INDL.min.js.map rename to docs/public/chunk-OZIWJXOC.min.js.map index cc50f222..546af0dc 100644 --- a/docs/public/chunk-RUC4INDL.min.js.map +++ b/docs/public/chunk-OZIWJXOC.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/svgDrawCommon-4835440b.js"], - "sourcesContent": ["import { sanitizeUrl } from \"@braintree/sanitize-url\";\nimport { H as lineBreakRegex } from \"./mermaid-8af3addd.js\";\nconst drawRect = (element, rectData) => {\n const rectElement = element.append(\"rect\");\n rectElement.attr(\"x\", rectData.x);\n rectElement.attr(\"y\", rectData.y);\n rectElement.attr(\"fill\", rectData.fill);\n rectElement.attr(\"stroke\", rectData.stroke);\n rectElement.attr(\"width\", rectData.width);\n rectElement.attr(\"height\", rectData.height);\n rectData.rx !== void 0 && rectElement.attr(\"rx\", rectData.rx);\n rectData.ry !== void 0 && rectElement.attr(\"ry\", rectData.ry);\n if (rectData.attrs !== void 0) {\n for (const attrKey in rectData.attrs) {\n rectElement.attr(attrKey, rectData.attrs[attrKey]);\n }\n }\n rectData.class !== void 0 && rectElement.attr(\"class\", rectData.class);\n return rectElement;\n};\nconst drawBackgroundRect = (element, bounds) => {\n const rectData = {\n x: bounds.startx,\n y: bounds.starty,\n width: bounds.stopx - bounds.startx,\n height: bounds.stopy - bounds.starty,\n fill: bounds.fill,\n stroke: bounds.stroke,\n class: \"rect\"\n };\n const rectElement = drawRect(element, rectData);\n rectElement.lower();\n};\nconst drawText = (element, textData) => {\n const nText = textData.text.replace(lineBreakRegex, \" \");\n const textElem = element.append(\"text\");\n textElem.attr(\"x\", textData.x);\n textElem.attr(\"y\", textData.y);\n textElem.attr(\"class\", \"legend\");\n textElem.style(\"text-anchor\", textData.anchor);\n textData.class !== void 0 && textElem.attr(\"class\", textData.class);\n const tspan = textElem.append(\"tspan\");\n tspan.attr(\"x\", textData.x + textData.textMargin * 2);\n tspan.text(nText);\n return textElem;\n};\nconst drawImage = (elem, x, y, link) => {\n const imageElement = elem.append(\"image\");\n imageElement.attr(\"x\", x);\n imageElement.attr(\"y\", y);\n const sanitizedLink = sanitizeUrl(link);\n imageElement.attr(\"xlink:href\", sanitizedLink);\n};\nconst drawEmbeddedImage = (element, x, y, link) => {\n const imageElement = element.append(\"use\");\n imageElement.attr(\"x\", x);\n imageElement.attr(\"y\", y);\n const sanitizedLink = sanitizeUrl(link);\n imageElement.attr(\"xlink:href\", `#${sanitizedLink}`);\n};\nconst getNoteRect = () => {\n const noteRectData = {\n x: 0,\n y: 0,\n width: 100,\n height: 100,\n fill: \"#EDF2AE\",\n stroke: \"#666\",\n anchor: \"start\",\n rx: 0,\n ry: 0\n };\n return noteRectData;\n};\nconst getTextObj = () => {\n const testObject = {\n x: 0,\n y: 0,\n width: 100,\n height: 100,\n \"text-anchor\": \"start\",\n style: \"#666\",\n textMargin: 0,\n rx: 0,\n ry: 0,\n tspan: true\n };\n return testObject;\n};\nexport {\n drawBackgroundRect as a,\n drawEmbeddedImage as b,\n drawImage as c,\n drawRect as d,\n getTextObj as e,\n drawText as f,\n getNoteRect as g\n};\n"], + "sources": ["../../node_modules/mermaid/dist/svgDrawCommon-ad5ef572.js"], + "sourcesContent": ["import { sanitizeUrl } from \"@braintree/sanitize-url\";\nimport { H as lineBreakRegex } from \"./mermaid-934d9bea.js\";\nconst drawRect = (element, rectData) => {\n const rectElement = element.append(\"rect\");\n rectElement.attr(\"x\", rectData.x);\n rectElement.attr(\"y\", rectData.y);\n rectElement.attr(\"fill\", rectData.fill);\n rectElement.attr(\"stroke\", rectData.stroke);\n rectElement.attr(\"width\", rectData.width);\n rectElement.attr(\"height\", rectData.height);\n rectData.rx !== void 0 && rectElement.attr(\"rx\", rectData.rx);\n rectData.ry !== void 0 && rectElement.attr(\"ry\", rectData.ry);\n if (rectData.attrs !== void 0) {\n for (const attrKey in rectData.attrs) {\n rectElement.attr(attrKey, rectData.attrs[attrKey]);\n }\n }\n rectData.class !== void 0 && rectElement.attr(\"class\", rectData.class);\n return rectElement;\n};\nconst drawBackgroundRect = (element, bounds) => {\n const rectData = {\n x: bounds.startx,\n y: bounds.starty,\n width: bounds.stopx - bounds.startx,\n height: bounds.stopy - bounds.starty,\n fill: bounds.fill,\n stroke: bounds.stroke,\n class: \"rect\"\n };\n const rectElement = drawRect(element, rectData);\n rectElement.lower();\n};\nconst drawText = (element, textData) => {\n const nText = textData.text.replace(lineBreakRegex, \" \");\n const textElem = element.append(\"text\");\n textElem.attr(\"x\", textData.x);\n textElem.attr(\"y\", textData.y);\n textElem.attr(\"class\", \"legend\");\n textElem.style(\"text-anchor\", textData.anchor);\n textData.class !== void 0 && textElem.attr(\"class\", textData.class);\n const tspan = textElem.append(\"tspan\");\n tspan.attr(\"x\", textData.x + textData.textMargin * 2);\n tspan.text(nText);\n return textElem;\n};\nconst drawImage = (elem, x, y, link) => {\n const imageElement = elem.append(\"image\");\n imageElement.attr(\"x\", x);\n imageElement.attr(\"y\", y);\n const sanitizedLink = sanitizeUrl(link);\n imageElement.attr(\"xlink:href\", sanitizedLink);\n};\nconst drawEmbeddedImage = (element, x, y, link) => {\n const imageElement = element.append(\"use\");\n imageElement.attr(\"x\", x);\n imageElement.attr(\"y\", y);\n const sanitizedLink = sanitizeUrl(link);\n imageElement.attr(\"xlink:href\", `#${sanitizedLink}`);\n};\nconst getNoteRect = () => {\n const noteRectData = {\n x: 0,\n y: 0,\n width: 100,\n height: 100,\n fill: \"#EDF2AE\",\n stroke: \"#666\",\n anchor: \"start\",\n rx: 0,\n ry: 0\n };\n return noteRectData;\n};\nconst getTextObj = () => {\n const testObject = {\n x: 0,\n y: 0,\n width: 100,\n height: 100,\n \"text-anchor\": \"start\",\n style: \"#666\",\n textMargin: 0,\n rx: 0,\n ry: 0,\n tspan: true\n };\n return testObject;\n};\nexport {\n drawBackgroundRect as a,\n drawEmbeddedImage as b,\n drawImage as c,\n drawRect as d,\n getT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,QAASH,EAAS,KAAK,EAClE,IAAMI,EAAQD,EAAS,OAAO,OAAO,EACrC,OAAAC,EAAM,KAAK,IAAKJ,EAAS,EAAIA,EAAS,WAAa,CAAC,EACpDI,EAAM,KAAKH,CAAK,EACTE,CACT,EACME,EAAY,CAACC,EAAMC,EAAGC,EAAGC,IAAS,CACtC,IAAMC,EAAeJ,EAAK,OAAO,OAAO,EACxCI,EAAa,KAAK,IAAKH,CAAC,EACxBG,EAAa,KAAK,IAAKF,CAAC,EACxB,IAAMG,KAAgB,eAAYF,CAAI,EACtCC,EAAa,KAAK,aAAcC,CAAa,CAC/C,EACMC,EAAoB,CAACnB,EAASc,EAAGC,EAAGC,IAAS,CACjD,IAAMC,EAAejB,EAAQ,OAAO,KAAK,EACzCiB,EAAa,KAAK,IAAKH,CAAC,EACxBG,EAAa,KAAK,IAAKF,CAAC,EACxB,IAAMG,KAAgB,eAAYF,CAAI,EACtCC,EAAa,KAAK,aAAc,IAAIC,CAAa,EAAE,CACrD,EACME,EAAc,KACG,CACnB,EAAG,EACH,EAAG,EACH,MAAO,IACP,OAAQ,IACR,KAAM,UACN,OAAQ,OACR,OAAQ,QACR,GAAI,EACJ,GAAI,CACN,GAGIC,EAAa,KACE,CACjB,EAAG,EACH,EAAG,EACH,MAAO,IACP,OAAQ,IACR,cAAe,QACf,MAAO,OACP,WAAY,EACZ,GAAI,EACJ,GAAI,EACJ,MAAO,EACT", "names": ["import_sanitize_url", "drawRect", "element", "rectData", "rectElement", "attrKey", "drawBackgroundRect", "bounds", "drawText", "textData", "nText", "lineBreakRegex", "textElem", "tspan", "drawImage", "elem", "x", "y", "link", "imageElement", "sanitizedLink", "drawEmbeddedImage", "getNoteRect", "getTextObj"] } diff --git a/docs/public/chunk-2DSXJIGN.min.js b/docs/public/chunk-VHIEHVUL.min.js similarity index 97% rename from docs/public/chunk-2DSXJIGN.min.js rename to docs/public/chunk-VHIEHVUL.min.js index 2eae6d71..c87291ce 100644 --- a/docs/public/chunk-2DSXJIGN.min.js +++ b/docs/public/chunk-VHIEHVUL.min.js @@ -1,2 +1,2 @@ -import{a as _,b as O,d as k,e as y,f as F,g as G,h as U,i as T,k as A,l as $,m as H,n as M}from"./chunk-ESYVBUIP.min.js";import{b as R}from"./chunk-TYUXPGKI.min.js";import{a as L,d as D,f as x,j as J,k as P}from"./chunk-3BJWU2V2.min.js";import{Ga as n,Ja as E,h as B,jb as N}from"./chunk-65WDIALL.min.js";function m(e){var t={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:Y(e),edges:Z(e)};return x(e.graph())||(t.value=L(e.graph())),t}function Y(e){return D(e.nodes(),function(t){var i=e.node(t),r=e.parent(t),s={v:t};return x(i)||(s.value=i),x(r)||(s.parent=r),s})}function Z(e){return D(e.edges(),function(t){var i=e.edge(t),r={v:t.v,w:t.w};return x(t.name)||(r.name=t.name),x(i)||(r.value=i),r})}var f={},g={},V={},tt=()=>{g={},V={},f={}},S=(e,t)=>(n.trace("In isDecendant",t," ",e," = ",g[t].includes(e)),!!g[t].includes(e)),et=(e,t)=>(n.info("Decendants of ",t," is ",g[t]),n.info("Edge is ",e),e.v===t||e.w===t?!1:g[t]?g[t].includes(e.v)||S(e.v,t)||S(e.w,t)||g[t].includes(e.w):(n.debug("Tilt, ",t,",not in decendants"),!1)),j=(e,t,i,r)=>{n.warn("Copying children of ",e,"root",r,"data",t.node(e),r);let s=t.children(e)||[];e!==r&&s.push(e),n.warn("Copying (nodes) clusterId",e,"nodes",s),s.forEach(c=>{if(t.children(c).length>0)j(c,t,i,r);else{let d=t.node(c);n.info("cp ",c," to ",r," with parent ",e),i.setNode(c,d),r!==t.parent(c)&&(n.warn("Setting parent",c,t.parent(c)),i.setParent(c,t.parent(c))),e!==r&&c!==e?(n.debug("Setting parent",c,e),i.setParent(c,e)):(n.info("In copy ",e,"root",r,"data",t.node(e),r),n.debug("Not Setting parent for node=",c,"cluster!==rootId",e!==r,"node!==clusterId",c!==e));let l=t.edges(c);n.debug("Copying Edges",l),l.forEach(h=>{n.info("Edge",h);let u=t.edge(h.v,h.w,h.name);n.info("Edge data",u,r);try{et(h,r)?(n.info("Copying as ",h.v,h.w,u,h.name),i.setEdge(h.v,h.w,u,h.name),n.info("newGraph edges ",i.edges(),i.edge(i.edges()[0]))):n.info("Skipping copy of edge ",h.v,"-->",h.w," rootId: ",r," clusterId:",e)}catch(w){n.error(w)}})}n.debug("Removing node",c),t.removeNode(c)})},W=(e,t)=>{let i=t.children(e),r=[...i];for(let s of i)V[s]=e,r=[...r,...W(s,t)];return r},p=(e,t)=>{n.trace("Searching",e);let i=t.children(e);if(n.trace("Searching children of id ",e,i),i.length<1)return n.trace("This is a valid node",e),e;for(let r of i){let s=p(r,t);if(s)return n.trace("Found replacement for",e," => ",s),s}},X=e=>!f[e]||!f[e].externalConnections?e:f[e]?f[e].id:e,it=(e,t)=>{if(!e||t>10){n.debug("Opting out, no graph ");return}else n.debug("Opting in, graph ");e.nodes().forEach(function(i){e.children(i).length>0&&(n.warn("Cluster identified",i," Replacement id in edges: ",p(i,e)),g[i]=W(i,e),f[i]={id:p(i,e),clusterData:e.node(i)})}),e.nodes().forEach(function(i){let r=e.children(i),s=e.edges();r.length>0?(n.debug("Cluster identified",i,g),s.forEach(c=>{if(c.v!==i&&c.w!==i){let d=S(c.v,i),l=S(c.w,i);d^l&&(n.warn("Edge: ",c," leaves cluster ",i),n.warn("Decendants of XXX ",i,": ",g[i]),f[i].externalConnections=!0)}})):n.debug("Not a cluster ",i,g)}),e.edges().forEach(function(i){let r=e.edge(i);n.warn("Edge "+i.v+" -> "+i.w+": "+JSON.stringify(i)),n.warn("Edge "+i.v+" -> "+i.w+": "+JSON.stringify(e.edge(i)));let s=i.v,c=i.w;if(n.warn("Fix XXX",f,"ids:",i.v,i.w,"Translating: ",f[i.v]," --- ",f[i.w]),f[i.v]&&f[i.w]&&f[i.v]===f[i.w]){n.warn("Fixing and trixing link to self - removing XXX",i.v,i.w,i.name),n.warn("Fixing and trixing - removing XXX",i.v,i.w,i.name),s=X(i.v),c=X(i.w),e.removeEdge(i.v,i.w,i.name);let d=i.w+"---"+i.v;e.setNode(d,{domId:d,id:d,labelStyle:"",labelText:r.label,padding:0,shape:"labelRect",style:""});let l=structuredClone(r),h=structuredClone(r);l.label="",l.arrowTypeEnd="none",h.label="",l.fromCluster=i.v,h.toCluster=i.v,e.setEdge(s,d,l,i.name+"-cyclic-special"),e.setEdge(d,c,h,i.name+"-cyclic-special")}else(f[i.v]||f[i.w])&&(n.warn("Fixing and trixing - removing XXX",i.v,i.w,i.name),s=X(i.v),c=X(i.w),e.removeEdge(i.v,i.w,i.name),s!==i.v&&(r.fromCluster=i.v),c!==i.w&&(r.toCluster=i.w),n.warn("Fix Replacing with XXX",s,c,i.name),e.setEdge(s,c,r,i.name))}),n.warn("Adjusted Graph",m(e)),q(e,0),n.trace(f)},q=(e,t)=>{if(n.warn("extractor - ",t,m(e),e.children("D")),t>10){n.error("Bailing out");return}let i=e.nodes(),r=!1;for(let s of i){let c=e.children(s);r=r||c.length>0}if(!r){n.debug("Done, no node has children",e.nodes());return}n.debug("Nodes = ",i,t);for(let s of i)if(n.debug("Extracting node",s,f,f[s]&&!f[s].externalConnections,!e.parent(s),e.node(s),e.children("D")," Depth ",t),!f[s])n.debug("Not a cluster",s,t);else if(!f[s].externalConnections&&e.children(s)&&e.children(s).length>0){n.warn("Cluster without external connections, without a parent and with children",s,t);let d=e.graph().rankdir==="TB"?"LR":"TB";f[s]&&f[s].clusterData&&f[s].clusterData.dir&&(d=f[s].clusterData.dir,n.warn("Fixing dir",f[s].clusterData.dir,d));let l=new J({multigraph:!0,compound:!0}).setGraph({rankdir:d,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});n.warn("Old graph before copy",m(e)),j(s,e,l,s),e.setNode(s,{clusterNode:!0,id:s,clusterData:f[s].clusterData,labelText:f[s].labelText,graph:l}),n.warn("New graph after copy node: (",s,")",m(l)),n.debug("Old graph after copy",m(e))}else n.warn("Cluster ** ",s," **not meeting the criteria !externalConnections:",!f[s].externalConnections," no parent: ",!e.parent(s)," children ",e.children(s)&&e.children(s).length>0,e.children("D"),t),n.debug(f);i=e.nodes(),n.warn("New list of nodes",i);for(let s of i){let c=e.node(s);n.warn(" Now next level",s,c),c.clusterNode&&q(c.graph,t+1)}},z=(e,t)=>{if(t.length===0)return[];let i=Object.assign(t);return t.forEach(r=>{let s=e.children(r),c=z(e,s);i=[...i,...c]}),i},nt=e=>z(e,e.children()),st=(e,t)=>{n.info("Creating subgraph rect for ",t.id,t);let i=e.insert("g").attr("class","cluster"+(t.class?" "+t.class:"")).attr("id",t.id),r=i.insert("rect",":first-child"),s=E(N().flowchart.htmlLabels),c=i.insert("g").attr("class","cluster-label"),d=t.labelType==="markdown"?R(c,t.labelText,{style:t.labelStyle,useHtmlLabels:s}):c.node().appendChild(O(t.labelText,t.labelStyle,void 0,!0)),l=d.getBBox();if(E(N().flowchart.htmlLabels)){let a=d.children[0],o=B(d);l=a.getBoundingClientRect(),o.attr("width",l.width),o.attr("height",l.height)}let h=0*t.padding,u=h/2,w=t.width<=l.width+h?l.width+h:t.width;t.width<=l.width+h?t.diff=(l.width-t.width)/2-t.padding/2:t.diff=-t.padding/2,n.trace("Data ",t,JSON.stringify(t)),r.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-w/2).attr("y",t.y-t.height/2-u).attr("width",w).attr("height",t.height+h),s?c.attr("transform","translate("+(t.x-l.width/2)+", "+(t.y-t.height/2)+")"):c.attr("transform","translate("+t.x+", "+(t.y-t.height/2)+")");let v=r.node().getBBox();return t.width=v.width,t.height=v.height,t.intersect=function(a){return y(t,a)},i},rt=(e,t)=>{let i=e.insert("g").attr("class","note-cluster").attr("id",t.id),r=i.insert("rect",":first-child"),s=0*t.padding,c=s/2;r.attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-t.width/2-c).attr("y",t.y-t.height/2-c).attr("width",t.width+s).attr("height",t.height+s).attr("fill","none");let d=r.node().getBBox();return t.width=d.width,t.height=d.height,t.intersect=function(l){return y(t,l)},i},at=(e,t)=>{let i=e.insert("g").attr("class",t.classes).attr("id",t.id),r=i.insert("rect",":first-child"),s=i.insert("g").attr("class","cluster-label"),c=i.append("rect"),d=s.node().appendChild(O(t.labelText,t.labelStyle,void 0,!0)),l=d.getBBox();if(E(N().flowchart.htmlLabels)){let a=d.children[0],o=B(d);l=a.getBoundingClientRect(),o.attr("width",l.width),o.attr("height",l.height)}l=d.getBBox();let h=0*t.padding,u=h/2,w=t.width<=l.width+t.padding?l.width+t.padding:t.width;t.width<=l.width+t.padding?t.diff=(l.width+t.padding*0-t.width)/2:t.diff=-t.padding/2,r.attr("class","outer").attr("x",t.x-w/2-u).attr("y",t.y-t.height/2-u).attr("width",w+h).attr("height",t.height+h),c.attr("class","inner").attr("x",t.x-w/2-u).attr("y",t.y-t.height/2-u+l.height-1).attr("width",w+h).attr("height",t.height+h-l.height-3),s.attr("transform","translate("+(t.x-l.width/2)+", "+(t.y-t.height/2-t.padding/3+(E(N().flowchart.htmlLabels)?5:3))+")");let v=r.node().getBBox();return t.height=v.height,t.intersect=function(a){return y(t,a)},i},ct=(e,t)=>{let i=e.insert("g").attr("class",t.classes).attr("id",t.id),r=i.insert("rect",":first-child"),s=0*t.padding,c=s/2;r.attr("class","divider").attr("x",t.x-t.width/2-c).attr("y",t.y-t.height/2).attr("width",t.width+s).attr("height",t.height+s);let d=r.node().getBBox();return t.width=d.width,t.height=d.height,t.diff=-t.padding/2,t.intersect=function(l){return y(t,l)},i},ot={rect:st,roundedWithTitle:at,noteGroup:rt,divider:ct},K={},lt=(e,t)=>{n.trace("Inserting cluster");let i=t.shape||"rect";K[t.id]=ot[i](e,t)},ft=()=>{K={}},Q=async(e,t,i,r,s)=>{n.info("Graph in recursive render: XXX",m(t),s);let c=t.graph().rankdir;n.trace("Dir in recursive render - dir:",c);let d=e.insert("g").attr("class","root");t.nodes()?n.info("Recursive render XXX",t.nodes()):n.info("No nodes found for",t),t.edges().length>0&&n.trace("Recursive edges",t.edge(t.edges()[0]));let l=d.insert("g").attr("class","clusters"),h=d.insert("g").attr("class","edgePaths"),u=d.insert("g").attr("class","edgeLabels"),w=d.insert("g").attr("class","nodes");await Promise.all(t.nodes().map(async function(a){let o=t.node(a);if(s!==void 0){let b=JSON.parse(JSON.stringify(s.clusterData));n.info("Setting data for cluster XXX (",a,") ",b,s),t.setNode(s.id,b),t.parent(a)||(n.trace("Setting parent",a,s.id),t.setParent(a,s.id,b))}if(n.info("(Insert) Node XXX"+a+": "+JSON.stringify(t.node(a))),o&&o.clusterNode){n.info("Cluster identified",a,o.width,t.node(a));let b=await Q(w,o.graph,i,r,t.node(a)),C=b.elem;k(o,C),o.diff=b.diff||0,n.info("Node bounds (abc123)",a,o,o.width,o.x,o.y),G(C,o),n.warn("Recursive render complete ",C,o)}else t.children(a).length>0?(n.info("Cluster - the non recursive path XXX",a,o.id,o,t),n.info(p(o.id,t)),f[o.id]={id:p(o.id,t),node:o}):(n.info("Node - the non recursive path",a,o.id,o),await F(w,t.node(a),c))})),t.edges().forEach(function(a){let o=t.edge(a.v,a.w,a.name);n.info("Edge "+a.v+" -> "+a.w+": "+JSON.stringify(a)),n.info("Edge "+a.v+" -> "+a.w+": ",a," ",JSON.stringify(t.edge(a))),n.info("Fix",f,"ids:",a.v,a.w,"Translateing: ",f[a.v],f[a.w]),$(u,o)}),t.edges().forEach(function(a){n.info("Edge "+a.v+" -> "+a.w+": "+JSON.stringify(a))}),n.info("#############################################"),n.info("### Layout ###"),n.info("#############################################"),n.info(t),P(t),n.info("Graph after layout:",m(t));let v=0;return nt(t).forEach(function(a){let o=t.node(a);n.info("Position "+a+": "+JSON.stringify(t.node(a))),n.info("Position "+a+": ("+o.x,","+o.y,") width: ",o.width," height: ",o.height),o&&o.clusterNode?T(o):t.children(a).length>0?(lt(l,o),f[o.id].node=o):T(o)}),t.edges().forEach(function(a){let o=t.edge(a);n.info("Edge "+a.v+" -> "+a.w+": "+JSON.stringify(o),o);let b=M(h,a,o,f,i,t,r);H(o,b)}),t.nodes().forEach(function(a){let o=t.node(a);n.info(a,o.type,o.diff),o.type==="group"&&(v=o.diff)}),{elem:d,diff:v}},yt=async(e,t,i,r,s)=>{_(e,i,r,s),U(),A(),ft(),tt(),n.warn("Graph at first:",JSON.stringify(m(t))),it(t),n.warn("Graph after:",JSON.stringify(m(t))),await Q(e,t,r,s)};export{yt as a}; -//# sourceMappingURL=chunk-2DSXJIGN.min.js.map +import{a as _,b as O,d as k,e as y,f as F,g as G,h as U,i as T,k as A,l as $,m as H,n as M}from"./chunk-NV7BXRXJ.min.js";import{b as R}from"./chunk-ZMRDHQ6H.min.js";import{a as L,d as D,f as x,j as J,k as P}from"./chunk-NAH225X5.min.js";import{Ga as n,Ja as E,h as B,jb as N}from"./chunk-JUXSCBYR.min.js";function m(e){var t={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:Y(e),edges:Z(e)};return x(e.graph())||(t.value=L(e.graph())),t}function Y(e){return D(e.nodes(),function(t){var i=e.node(t),r=e.parent(t),s={v:t};return x(i)||(s.value=i),x(r)||(s.parent=r),s})}function Z(e){return D(e.edges(),function(t){var i=e.edge(t),r={v:t.v,w:t.w};return x(t.name)||(r.name=t.name),x(i)||(r.value=i),r})}var f={},g={},V={},tt=()=>{g={},V={},f={}},S=(e,t)=>(n.trace("In isDecendant",t," ",e," = ",g[t].includes(e)),!!g[t].includes(e)),et=(e,t)=>(n.info("Decendants of ",t," is ",g[t]),n.info("Edge is ",e),e.v===t||e.w===t?!1:g[t]?g[t].includes(e.v)||S(e.v,t)||S(e.w,t)||g[t].includes(e.w):(n.debug("Tilt, ",t,",not in decendants"),!1)),j=(e,t,i,r)=>{n.warn("Copying children of ",e,"root",r,"data",t.node(e),r);let s=t.children(e)||[];e!==r&&s.push(e),n.warn("Copying (nodes) clusterId",e,"nodes",s),s.forEach(c=>{if(t.children(c).length>0)j(c,t,i,r);else{let d=t.node(c);n.info("cp ",c," to ",r," with parent ",e),i.setNode(c,d),r!==t.parent(c)&&(n.warn("Setting parent",c,t.parent(c)),i.setParent(c,t.parent(c))),e!==r&&c!==e?(n.debug("Setting parent",c,e),i.setParent(c,e)):(n.info("In copy ",e,"root",r,"data",t.node(e),r),n.debug("Not Setting parent for node=",c,"cluster!==rootId",e!==r,"node!==clusterId",c!==e));let l=t.edges(c);n.debug("Copying Edges",l),l.forEach(h=>{n.info("Edge",h);let u=t.edge(h.v,h.w,h.name);n.info("Edge data",u,r);try{et(h,r)?(n.info("Copying as ",h.v,h.w,u,h.name),i.setEdge(h.v,h.w,u,h.name),n.info("newGraph edges ",i.edges(),i.edge(i.edges()[0]))):n.info("Skipping copy of edge ",h.v,"-->",h.w," rootId: ",r," clusterId:",e)}catch(w){n.error(w)}})}n.debug("Removing node",c),t.removeNode(c)})},W=(e,t)=>{let i=t.children(e),r=[...i];for(let s of i)V[s]=e,r=[...r,...W(s,t)];return r},p=(e,t)=>{n.trace("Searching",e);let i=t.children(e);if(n.trace("Searching children of id ",e,i),i.length<1)return n.trace("This is a valid node",e),e;for(let r of i){let s=p(r,t);if(s)return n.trace("Found replacement for",e," => ",s),s}},X=e=>!f[e]||!f[e].externalConnections?e:f[e]?f[e].id:e,it=(e,t)=>{if(!e||t>10){n.debug("Opting out, no graph ");return}else n.debug("Opting in, graph ");e.nodes().forEach(function(i){e.children(i).length>0&&(n.warn("Cluster identified",i," Replacement id in edges: ",p(i,e)),g[i]=W(i,e),f[i]={id:p(i,e),clusterData:e.node(i)})}),e.nodes().forEach(function(i){let r=e.children(i),s=e.edges();r.length>0?(n.debug("Cluster identified",i,g),s.forEach(c=>{if(c.v!==i&&c.w!==i){let d=S(c.v,i),l=S(c.w,i);d^l&&(n.warn("Edge: ",c," leaves cluster ",i),n.warn("Decendants of XXX ",i,": ",g[i]),f[i].externalConnections=!0)}})):n.debug("Not a cluster ",i,g)}),e.edges().forEach(function(i){let r=e.edge(i);n.warn("Edge "+i.v+" -> "+i.w+": "+JSON.stringify(i)),n.warn("Edge "+i.v+" -> "+i.w+": "+JSON.stringify(e.edge(i)));let s=i.v,c=i.w;if(n.warn("Fix XXX",f,"ids:",i.v,i.w,"Translating: ",f[i.v]," --- ",f[i.w]),f[i.v]&&f[i.w]&&f[i.v]===f[i.w]){n.warn("Fixing and trixing link to self - removing XXX",i.v,i.w,i.name),n.warn("Fixing and trixing - removing XXX",i.v,i.w,i.name),s=X(i.v),c=X(i.w),e.removeEdge(i.v,i.w,i.name);let d=i.w+"---"+i.v;e.setNode(d,{domId:d,id:d,labelStyle:"",labelText:r.label,padding:0,shape:"labelRect",style:""});let l=structuredClone(r),h=structuredClone(r);l.label="",l.arrowTypeEnd="none",h.label="",l.fromCluster=i.v,h.toCluster=i.v,e.setEdge(s,d,l,i.name+"-cyclic-special"),e.setEdge(d,c,h,i.name+"-cyclic-special")}else(f[i.v]||f[i.w])&&(n.warn("Fixing and trixing - removing XXX",i.v,i.w,i.name),s=X(i.v),c=X(i.w),e.removeEdge(i.v,i.w,i.name),s!==i.v&&(r.fromCluster=i.v),c!==i.w&&(r.toCluster=i.w),n.warn("Fix Replacing with XXX",s,c,i.name),e.setEdge(s,c,r,i.name))}),n.warn("Adjusted Graph",m(e)),q(e,0),n.trace(f)},q=(e,t)=>{if(n.warn("extractor - ",t,m(e),e.children("D")),t>10){n.error("Bailing out");return}let i=e.nodes(),r=!1;for(let s of i){let c=e.children(s);r=r||c.length>0}if(!r){n.debug("Done, no node has children",e.nodes());return}n.debug("Nodes = ",i,t);for(let s of i)if(n.debug("Extracting node",s,f,f[s]&&!f[s].externalConnections,!e.parent(s),e.node(s),e.children("D")," Depth ",t),!f[s])n.debug("Not a cluster",s,t);else if(!f[s].externalConnections&&e.children(s)&&e.children(s).length>0){n.warn("Cluster without external connections, without a parent and with children",s,t);let d=e.graph().rankdir==="TB"?"LR":"TB";f[s]&&f[s].clusterData&&f[s].clusterData.dir&&(d=f[s].clusterData.dir,n.warn("Fixing dir",f[s].clusterData.dir,d));let l=new J({multigraph:!0,compound:!0}).setGraph({rankdir:d,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});n.warn("Old graph before copy",m(e)),j(s,e,l,s),e.setNode(s,{clusterNode:!0,id:s,clusterData:f[s].clusterData,labelText:f[s].labelText,graph:l}),n.warn("New graph after copy node: (",s,")",m(l)),n.debug("Old graph after copy",m(e))}else n.warn("Cluster ** ",s," **not meeting the criteria !externalConnections:",!f[s].externalConnections," no parent: ",!e.parent(s)," children ",e.children(s)&&e.children(s).length>0,e.children("D"),t),n.debug(f);i=e.nodes(),n.warn("New list of nodes",i);for(let s of i){let c=e.node(s);n.warn(" Now next level",s,c),c.clusterNode&&q(c.graph,t+1)}},z=(e,t)=>{if(t.length===0)return[];let i=Object.assign(t);return t.forEach(r=>{let s=e.children(r),c=z(e,s);i=[...i,...c]}),i},nt=e=>z(e,e.children()),st=(e,t)=>{n.info("Creating subgraph rect for ",t.id,t);let i=e.insert("g").attr("class","cluster"+(t.class?" "+t.class:"")).attr("id",t.id),r=i.insert("rect",":first-child"),s=E(N().flowchart.htmlLabels),c=i.insert("g").attr("class","cluster-label"),d=t.labelType==="markdown"?R(c,t.labelText,{style:t.labelStyle,useHtmlLabels:s}):c.node().appendChild(O(t.labelText,t.labelStyle,void 0,!0)),l=d.getBBox();if(E(N().flowchart.htmlLabels)){let a=d.children[0],o=B(d);l=a.getBoundingClientRect(),o.attr("width",l.width),o.attr("height",l.height)}let h=0*t.padding,u=h/2,w=t.width<=l.width+h?l.width+h:t.width;t.width<=l.width+h?t.diff=(l.width-t.width)/2-t.padding/2:t.diff=-t.padding/2,n.trace("Data ",t,JSON.stringify(t)),r.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-w/2).attr("y",t.y-t.height/2-u).attr("width",w).attr("height",t.height+h),s?c.attr("transform","translate("+(t.x-l.width/2)+", "+(t.y-t.height/2)+")"):c.attr("transform","translate("+t.x+", "+(t.y-t.height/2)+")");let v=r.node().getBBox();return t.width=v.width,t.height=v.height,t.intersect=function(a){return y(t,a)},i},rt=(e,t)=>{let i=e.insert("g").attr("class","note-cluster").attr("id",t.id),r=i.insert("rect",":first-child"),s=0*t.padding,c=s/2;r.attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-t.width/2-c).attr("y",t.y-t.height/2-c).attr("width",t.width+s).attr("height",t.height+s).attr("fill","none");let d=r.node().getBBox();return t.width=d.width,t.height=d.height,t.intersect=function(l){return y(t,l)},i},at=(e,t)=>{let i=e.insert("g").attr("class",t.classes).attr("id",t.id),r=i.insert("rect",":first-child"),s=i.insert("g").attr("class","cluster-label"),c=i.append("rect"),d=s.node().appendChild(O(t.labelText,t.labelStyle,void 0,!0)),l=d.getBBox();if(E(N().flowchart.htmlLabels)){let a=d.children[0],o=B(d);l=a.getBoundingClientRect(),o.attr("width",l.width),o.attr("height",l.height)}l=d.getBBox();let h=0*t.padding,u=h/2,w=t.width<=l.width+t.padding?l.width+t.padding:t.width;t.width<=l.width+t.padding?t.diff=(l.width+t.padding*0-t.width)/2:t.diff=-t.padding/2,r.attr("class","outer").attr("x",t.x-w/2-u).attr("y",t.y-t.height/2-u).attr("width",w+h).attr("height",t.height+h),c.attr("class","inner").attr("x",t.x-w/2-u).attr("y",t.y-t.height/2-u+l.height-1).attr("width",w+h).attr("height",t.height+h-l.height-3),s.attr("transform","translate("+(t.x-l.width/2)+", "+(t.y-t.height/2-t.padding/3+(E(N().flowchart.htmlLabels)?5:3))+")");let v=r.node().getBBox();return t.height=v.height,t.intersect=function(a){return y(t,a)},i},ct=(e,t)=>{let i=e.insert("g").attr("class",t.classes).attr("id",t.id),r=i.insert("rect",":first-child"),s=0*t.padding,c=s/2;r.attr("class","divider").attr("x",t.x-t.width/2-c).attr("y",t.y-t.height/2).attr("width",t.width+s).attr("height",t.height+s);let d=r.node().getBBox();return t.width=d.width,t.height=d.height,t.diff=-t.padding/2,t.intersect=function(l){return y(t,l)},i},ot={rect:st,roundedWithTitle:at,noteGroup:rt,divider:ct},K={},lt=(e,t)=>{n.trace("Inserting cluster");let i=t.shape||"rect";K[t.id]=ot[i](e,t)},ft=()=>{K={}},Q=async(e,t,i,r,s)=>{n.info("Graph in recursive render: XXX",m(t),s);let c=t.graph().rankdir;n.trace("Dir in recursive render - dir:",c);let d=e.insert("g").attr("class","root");t.nodes()?n.info("Recursive render XXX",t.nodes()):n.info("No nodes found for",t),t.edges().length>0&&n.trace("Recursive edges",t.edge(t.edges()[0]));let l=d.insert("g").attr("class","clusters"),h=d.insert("g").attr("class","edgePaths"),u=d.insert("g").attr("class","edgeLabels"),w=d.insert("g").attr("class","nodes");await Promise.all(t.nodes().map(async function(a){let o=t.node(a);if(s!==void 0){let b=JSON.parse(JSON.stringify(s.clusterData));n.info("Setting data for cluster XXX (",a,") ",b,s),t.setNode(s.id,b),t.parent(a)||(n.trace("Setting parent",a,s.id),t.setParent(a,s.id,b))}if(n.info("(Insert) Node XXX"+a+": "+JSON.stringify(t.node(a))),o&&o.clusterNode){n.info("Cluster identified",a,o.width,t.node(a));let b=await Q(w,o.graph,i,r,t.node(a)),C=b.elem;k(o,C),o.diff=b.diff||0,n.info("Node bounds (abc123)",a,o,o.width,o.x,o.y),G(C,o),n.warn("Recursive render complete ",C,o)}else t.children(a).length>0?(n.info("Cluster - the non recursive path XXX",a,o.id,o,t),n.info(p(o.id,t)),f[o.id]={id:p(o.id,t),node:o}):(n.info("Node - the non recursive path",a,o.id,o),await F(w,t.node(a),c))})),t.edges().forEach(function(a){let o=t.edge(a.v,a.w,a.name);n.info("Edge "+a.v+" -> "+a.w+": "+JSON.stringify(a)),n.info("Edge "+a.v+" -> "+a.w+": ",a," ",JSON.stringify(t.edge(a))),n.info("Fix",f,"ids:",a.v,a.w,"Translateing: ",f[a.v],f[a.w]),$(u,o)}),t.edges().forEach(function(a){n.info("Edge "+a.v+" -> "+a.w+": "+JSON.stringify(a))}),n.info("#############################################"),n.info("### Layout ###"),n.info("#############################################"),n.info(t),P(t),n.info("Graph after layout:",m(t));let v=0;return nt(t).forEach(function(a){let o=t.node(a);n.info("Position "+a+": "+JSON.stringify(t.node(a))),n.info("Position "+a+": ("+o.x,","+o.y,") width: ",o.width," height: ",o.height),o&&o.clusterNode?T(o):t.children(a).length>0?(lt(l,o),f[o.id].node=o):T(o)}),t.edges().forEach(function(a){let o=t.edge(a);n.info("Edge "+a.v+" -> "+a.w+": "+JSON.stringify(o),o);let b=M(h,a,o,f,i,t,r);H(o,b)}),t.nodes().forEach(function(a){let o=t.node(a);n.info(a,o.type,o.diff),o.type==="group"&&(v=o.diff)}),{elem:d,diff:v}},yt=async(e,t,i,r,s)=>{_(e,i,r,s),U(),A(),ft(),tt(),n.warn("Graph at first:",JSON.stringify(m(t))),it(t),n.warn("Graph after:",JSON.stringify(m(t))),await Q(e,t,r,s)};export{yt as a}; +//# sourceMappingURL=chunk-VHIEHVUL.min.js.map diff --git a/docs/public/chunk-2DSXJIGN.min.js.map b/docs/public/chunk-VHIEHVUL.min.js.map similarity index 99% rename from docs/public/chunk-2DSXJIGN.min.js.map rename to docs/public/chunk-VHIEHVUL.min.js.map index d075c66e..4dc3f44d 100644 --- a/docs/public/chunk-2DSXJIGN.min.js.map +++ b/docs/public/chunk-VHIEHVUL.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/dagre-d3-es/src/graphlib/json.js", "../../node_modules/mermaid/dist/index-2c4b9a3b.js"], - "sourcesContent": ["import * as _ from 'lodash-es';\nimport { Graph } from './graph.js';\n\nexport { write, read };\n\nfunction write(g) {\n var json = {\n options: {\n directed: g.isDirected(),\n multigraph: g.isMultigraph(),\n compound: g.isCompound(),\n },\n nodes: writeNodes(g),\n edges: writeEdges(g),\n };\n if (!_.isUndefined(g.graph())) {\n json.value = _.clone(g.graph());\n }\n return json;\n}\n\nfunction writeNodes(g) {\n return _.map(g.nodes(), function (v) {\n var nodeValue = g.node(v);\n var parent = g.parent(v);\n var node = { v: v };\n if (!_.isUndefined(nodeValue)) {\n node.value = nodeValue;\n }\n if (!_.isUndefined(parent)) {\n node.parent = parent;\n }\n return node;\n });\n}\n\nfunction writeEdges(g) {\n return _.map(g.edges(), function (e) {\n var edgeValue = g.edge(e);\n var edge = { v: e.v, w: e.w };\n if (!_.isUndefined(e.name)) {\n edge.name = e.name;\n }\n if (!_.isUndefined(edgeValue)) {\n edge.value = edgeValue;\n }\n return edge;\n });\n}\n\nfunction read(json) {\n var g = new Graph(json.options).setGraph(json.value);\n _.each(json.nodes, function (entry) {\n g.setNode(entry.v, entry.value);\n if (entry.parent) {\n g.setParent(entry.v, entry.parent);\n }\n });\n _.each(json.edges, function (entry) {\n g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value);\n });\n return g;\n}\n", "import { layout } from \"dagre-d3-es/src/dagre/index.js\";\nimport * as graphlibJson from \"dagre-d3-es/src/graphlib/json.js\";\nimport { c as createLabel, i as intersectRect, a as insertMarkers, b as clear$2, d as clear$3, u as updateNodeBounds, s as setNodeElem, e as insertNode, f as insertEdgeLabel, p as positionNode, g as insertEdge, h as positionEdgeLabel } from \"./edges-f2ad444c.js\";\nimport { l as log, m as evaluate, c as getConfig } from \"./mermaid-8af3addd.js\";\nimport * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { a as createText } from \"./createText-62fc7601.js\";\nimport { select } from \"d3\";\nlet clusterDb = {};\nlet descendants = {};\nlet parents = {};\nconst clear$1 = () => {\n descendants = {};\n parents = {};\n clusterDb = {};\n};\nconst isDescendant = (id, ancenstorId) => {\n log.trace(\"In isDecendant\", ancenstorId, \" \", id, \" = \", descendants[ancenstorId].includes(id));\n if (descendants[ancenstorId].includes(id)) {\n return true;\n }\n return false;\n};\nconst edgeInCluster = (edge, clusterId) => {\n log.info(\"Decendants of \", clusterId, \" is \", descendants[clusterId]);\n log.info(\"Edge is \", edge);\n if (edge.v === clusterId) {\n return false;\n }\n if (edge.w === clusterId) {\n return false;\n }\n if (!descendants[clusterId]) {\n log.debug(\"Tilt, \", clusterId, \",not in decendants\");\n return false;\n }\n return descendants[clusterId].includes(edge.v) || isDescendant(edge.v, clusterId) || isDescendant(edge.w, clusterId) || descendants[clusterId].includes(edge.w);\n};\nconst copy = (clusterId, graph, newGraph, rootId) => {\n log.warn(\n \"Copying children of \",\n clusterId,\n \"root\",\n rootId,\n \"data\",\n graph.node(clusterId),\n rootId\n );\n const nodes = graph.children(clusterId) || [];\n if (clusterId !== rootId) {\n nodes.push(clusterId);\n }\n log.warn(\"Copying (nodes) clusterId\", clusterId, \"nodes\", nodes);\n nodes.forEach((node) => {\n if (graph.children(node).length > 0) {\n copy(node, graph, newGraph, rootId);\n } else {\n const data = graph.node(node);\n log.info(\"cp \", node, \" to \", rootId, \" with parent \", clusterId);\n newGraph.setNode(node, data);\n if (rootId !== graph.parent(node)) {\n log.warn(\"Setting parent\", node, graph.parent(node));\n newGraph.setParent(node, graph.parent(node));\n }\n if (clusterId !== rootId && node !== clusterId) {\n log.debug(\"Setting parent\", node, clusterId);\n newGraph.setParent(node, clusterId);\n } else {\n log.info(\"In copy \", clusterId, \"root\", rootId, \"data\", graph.node(clusterId), rootId);\n log.debug(\n \"Not Setting parent for node=\",\n node,\n \"cluster!==rootId\",\n clusterId !== rootId,\n \"node!==clusterId\",\n node !== clusterId\n );\n }\n const edges = graph.edges(node);\n log.debug(\"Copying Edges\", edges);\n edges.forEach((edge) => {\n log.info(\"Edge\", edge);\n const data2 = graph.edge(edge.v, edge.w, edge.name);\n log.info(\"Edge data\", data2, rootId);\n try {\n if (edgeInCluster(edge, rootId)) {\n log.info(\"Copying as \", edge.v, edge.w, data2, edge.name);\n newGraph.setEdge(edge.v, edge.w, data2, edge.name);\n log.info(\"newGraph edges \", newGraph.edges(), newGraph.edge(newGraph.edges()[0]));\n } else {\n log.info(\n \"Skipping copy of edge \",\n edge.v,\n \"-->\",\n edge.w,\n \" rootId: \",\n rootId,\n \" clusterId:\",\n clusterId\n );\n }\n } catch (e) {\n log.error(e);\n }\n });\n }\n log.debug(\"Removing node\", node);\n graph.removeNode(node);\n });\n};\nconst extractDescendants = (id, graph) => {\n const children = graph.children(id);\n let res = [...children];\n for (const child of children) {\n parents[child] = id;\n res = [...res, ...extractDescendants(child, graph)];\n }\n return res;\n};\nconst findNonClusterChild = (id, graph) => {\n log.trace(\"Searching\", id);\n const children = graph.children(id);\n log.trace(\"Searching children of id \", id, children);\n if (children.length < 1) {\n log.trace(\"This is a valid node\", id);\n return id;\n }\n for (const child of children) {\n const _id = findNonClusterChild(child, graph);\n if (_id) {\n log.trace(\"Found replacement for\", id, \" => \", _id);\n return _id;\n }\n }\n};\nconst getAnchorId = (id) => {\n if (!clusterDb[id]) {\n return id;\n }\n if (!clusterDb[id].externalConnections) {\n return id;\n }\n if (clusterDb[id]) {\n return clusterDb[id].id;\n }\n return id;\n};\nconst adjustClustersAndEdges = (graph, depth) => {\n if (!graph || depth > 10) {\n log.debug(\"Opting out, no graph \");\n return;\n } else {\n log.debug(\"Opting in, graph \");\n }\n graph.nodes().forEach(function(id) {\n const children = graph.children(id);\n if (children.length > 0) {\n log.warn(\n \"Cluster identified\",\n id,\n \" Replacement id in edges: \",\n findNonClusterChild(id, graph)\n );\n descendants[id] = extractDescendants(id, graph);\n clusterDb[id] = { id: findNonClusterChild(id, graph), clusterData: graph.node(id) };\n }\n });\n graph.nodes().forEach(function(id) {\n const children = graph.children(id);\n const edges = graph.edges();\n if (children.length > 0) {\n log.debug(\"Cluster identified\", id, descendants);\n edges.forEach((edge) => {\n if (edge.v !== id && edge.w !== id) {\n const d1 = isDescendant(edge.v, id);\n const d2 = isDescendant(edge.w, id);\n if (d1 ^ d2) {\n log.warn(\"Edge: \", edge, \" leaves cluster \", id);\n log.warn(\"Decendants of XXX \", id, \": \", descendants[id]);\n clusterDb[id].externalConnections = true;\n }\n }\n });\n } else {\n log.debug(\"Not a cluster \", id, descendants);\n }\n });\n graph.edges().forEach(function(e) {\n const edge = graph.edge(e);\n log.warn(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(e));\n log.warn(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(graph.edge(e)));\n let v = e.v;\n let w = e.w;\n log.warn(\n \"Fix XXX\",\n clusterDb,\n \"ids:\",\n e.v,\n e.w,\n \"Translating: \",\n clusterDb[e.v],\n \" --- \",\n clusterDb[e.w]\n );\n if (clusterDb[e.v] && clusterDb[e.w] && clusterDb[e.v] === clusterDb[e.w]) {\n log.warn(\"Fixing and trixing link to self - removing XXX\", e.v, e.w, e.name);\n log.warn(\"Fixing and trixing - removing XXX\", e.v, e.w, e.name);\n v = getAnchorId(e.v);\n w = getAnchorId(e.w);\n graph.removeEdge(e.v, e.w, e.name);\n const specialId = e.w + \"---\" + e.v;\n graph.setNode(specialId, {\n domId: specialId,\n id: specialId,\n labelStyle: \"\",\n labelText: edge.label,\n padding: 0,\n shape: \"labelRect\",\n style: \"\"\n });\n const edge1 = structuredClone(edge);\n const edge2 = structuredClone(edge);\n edge1.label = \"\";\n edge1.arrowTypeEnd = \"none\";\n edge2.label = \"\";\n edge1.fromCluster = e.v;\n edge2.toCluster = e.v;\n graph.setEdge(v, specialId, edge1, e.name + \"-cyclic-special\");\n graph.setEdge(specialId, w, edge2, e.name + \"-cyclic-special\");\n } else if (clusterDb[e.v] || clusterDb[e.w]) {\n log.warn(\"Fixing and trixing - removing XXX\", e.v, e.w, e.name);\n v = getAnchorId(e.v);\n w = getAnchorId(e.w);\n graph.removeEdge(e.v, e.w, e.name);\n if (v !== e.v) {\n edge.fromCluster = e.v;\n }\n if (w !== e.w) {\n edge.toCluster = e.w;\n }\n log.warn(\"Fix Replacing with XXX\", v, w, e.name);\n graph.setEdge(v, w, edge, e.name);\n }\n });\n log.warn(\"Adjusted Graph\", graphlibJson.write(graph));\n extractor(graph, 0);\n log.trace(clusterDb);\n};\nconst extractor = (graph, depth) => {\n log.warn(\"extractor - \", depth, graphlibJson.write(graph), graph.children(\"D\"));\n if (depth > 10) {\n log.error(\"Bailing out\");\n return;\n }\n let nodes = graph.nodes();\n let hasChildren = false;\n for (const node of nodes) {\n const children = graph.children(node);\n hasChildren = hasChildren || children.length > 0;\n }\n if (!hasChildren) {\n log.debug(\"Done, no node has children\", graph.nodes());\n return;\n }\n log.debug(\"Nodes = \", nodes, depth);\n for (const node of nodes) {\n log.debug(\n \"Extracting node\",\n node,\n clusterDb,\n clusterDb[node] && !clusterDb[node].externalConnections,\n !graph.parent(node),\n graph.node(node),\n graph.children(\"D\"),\n \" Depth \",\n depth\n );\n if (!clusterDb[node]) {\n log.debug(\"Not a cluster\", node, depth);\n } else if (!clusterDb[node].externalConnections && // !graph.parent(node) &&\n graph.children(node) && graph.children(node).length > 0) {\n log.warn(\n \"Cluster without external connections, without a parent and with children\",\n node,\n depth\n );\n const graphSettings = graph.graph();\n let dir = graphSettings.rankdir === \"TB\" ? \"LR\" : \"TB\";\n if (clusterDb[node] && clusterDb[node].clusterData && clusterDb[node].clusterData.dir) {\n dir = clusterDb[node].clusterData.dir;\n log.warn(\"Fixing dir\", clusterDb[node].clusterData.dir, dir);\n }\n const clusterGraph = new graphlib.Graph({\n multigraph: true,\n compound: true\n }).setGraph({\n rankdir: dir,\n // Todo: set proper spacing\n nodesep: 50,\n ranksep: 50,\n marginx: 8,\n marginy: 8\n }).setDefaultEdgeLabel(function() {\n return {};\n });\n log.warn(\"Old graph before copy\", graphlibJson.write(graph));\n copy(node, graph, clusterGraph, node);\n graph.setNode(node, {\n clusterNode: true,\n id: node,\n clusterData: clusterDb[node].clusterData,\n labelText: clusterDb[node].labelText,\n graph: clusterGraph\n });\n log.warn(\"New graph after copy node: (\", node, \")\", graphlibJson.write(clusterGraph));\n log.debug(\"Old graph after copy\", graphlibJson.write(graph));\n } else {\n log.warn(\n \"Cluster ** \",\n node,\n \" **not meeting the criteria !externalConnections:\",\n !clusterDb[node].externalConnections,\n \" no parent: \",\n !graph.parent(node),\n \" children \",\n graph.children(node) && graph.children(node).length > 0,\n graph.children(\"D\"),\n depth\n );\n log.debug(clusterDb);\n }\n }\n nodes = graph.nodes();\n log.warn(\"New list of nodes\", nodes);\n for (const node of nodes) {\n const data = graph.node(node);\n log.warn(\" Now next level\", node, data);\n if (data.clusterNode) {\n extractor(data.graph, depth + 1);\n }\n }\n};\nconst sorter = (graph, nodes) => {\n if (nodes.length === 0) {\n return [];\n }\n let result = Object.assign(nodes);\n nodes.forEach((node) => {\n const children = graph.children(node);\n const sorted = sorter(graph, children);\n result = [...result, ...sorted];\n });\n return result;\n};\nconst sortNodesByHierarchy = (graph) => sorter(graph, graph.children());\nconst rect = (parent, node) => {\n log.info(\"Creating subgraph rect for \", node.id, node);\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"cluster\" + (node.class ? \" \" + node.class : \"\")).attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const useHtmlLabels = evaluate(getConfig().flowchart.htmlLabels);\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"cluster-label\");\n const text = node.labelType === \"markdown\" ? createText(label, node.labelText, { style: node.labelStyle, useHtmlLabels }) : label.node().appendChild(createLabel(node.labelText, node.labelStyle, void 0, true));\n let bbox = text.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n const width = node.width <= bbox.width + padding ? bbox.width + padding : node.width;\n if (node.width <= bbox.width + padding) {\n node.diff = (bbox.width - node.width) / 2 - node.padding / 2;\n } else {\n node.diff = -node.padding / 2;\n }\n log.trace(\"Data \", node, JSON.stringify(node));\n rect2.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", node.x - width / 2).attr(\"y\", node.y - node.height / 2 - halfPadding).attr(\"width\", width).attr(\"height\", node.height + padding);\n if (useHtmlLabels) {\n label.attr(\n \"transform\",\n // This puts the labal on top of the box instead of inside it\n \"translate(\" + (node.x - bbox.width / 2) + \", \" + (node.y - node.height / 2) + \")\"\n );\n } else {\n label.attr(\n \"transform\",\n // This puts the labal on top of the box instead of inside it\n \"translate(\" + node.x + \", \" + (node.y - node.height / 2) + \")\"\n );\n }\n const rectBox = rect2.node().getBBox();\n node.width = rectBox.width;\n node.height = rectBox.height;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst noteGroup = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"note-cluster\").attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n rect2.attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", node.x - node.width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2 - halfPadding).attr(\"width\", node.width + padding).attr(\"height\", node.height + padding).attr(\"fill\", \"none\");\n const rectBox = rect2.node().getBBox();\n node.width = rectBox.width;\n node.height = rectBox.height;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst roundedWithTitle = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", node.classes).attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"cluster-label\");\n const innerRect = shapeSvg.append(\"rect\");\n const text = label.node().appendChild(createLabel(node.labelText, node.labelStyle, void 0, true));\n let bbox = text.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n bbox = text.getBBox();\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n const width = node.width <= bbox.width + node.padding ? bbox.width + node.padding : node.width;\n if (node.width <= bbox.width + node.padding) {\n node.diff = (bbox.width + node.padding * 0 - node.width) / 2;\n } else {\n node.diff = -node.padding / 2;\n }\n rect2.attr(\"class\", \"outer\").attr(\"x\", node.x - width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2 - halfPadding).attr(\"width\", width + padding).attr(\"height\", node.height + padding);\n innerRect.attr(\"class\", \"inner\").attr(\"x\", node.x - width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2 - halfPadding + bbox.height - 1).attr(\"width\", width + padding).attr(\"height\", node.height + padding - bbox.height - 3);\n label.attr(\n \"transform\",\n \"translate(\" + (node.x - bbox.width / 2) + \", \" + (node.y - node.height / 2 - node.padding / 3 + (evaluate(getConfig().flowchart.htmlLabels) ? 5 : 3)) + \")\"\n );\n const rectBox = rect2.node().getBBox();\n node.height = rectBox.height;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst divider = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", node.classes).attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n rect2.attr(\"class\", \"divider\").attr(\"x\", node.x - node.width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2).attr(\"width\", node.width + padding).attr(\"height\", node.height + padding);\n const rectBox = rect2.node().getBBox();\n node.width = rectBox.width;\n node.height = rectBox.height;\n node.diff = -node.padding / 2;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst shapes = { rect, roundedWithTitle, noteGroup, divider };\nlet clusterElems = {};\nconst insertCluster = (elem, node) => {\n log.trace(\"Inserting cluster\");\n const shape = node.shape || \"rect\";\n clusterElems[node.id] = shapes[shape](elem, node);\n};\nconst clear = () => {\n clusterElems = {};\n};\nconst recursiveRender = async (_elem, graph, diagramtype, id, parentCluster) => {\n log.info(\"Graph in recursive render: XXX\", graphlibJson.write(graph), parentCluster);\n const dir = graph.graph().rankdir;\n log.trace(\"Dir in recursive render - dir:\", dir);\n const elem = _elem.insert(\"g\").attr(\"class\", \"root\");\n if (!graph.nodes()) {\n log.info(\"No nodes found for\", graph);\n } else {\n log.info(\"Recursive render XXX\", graph.nodes());\n }\n if (graph.edges().length > 0) {\n log.trace(\"Recursive edges\", graph.edge(graph.edges()[0]));\n }\n const clusters = elem.insert(\"g\").attr(\"class\", \"clusters\");\n const edgePaths = elem.insert(\"g\").attr(\"class\", \"edgePaths\");\n const edgeLabels = elem.insert(\"g\").attr(\"class\", \"edgeLabels\");\n const nodes = elem.insert(\"g\").attr(\"class\", \"nodes\");\n await Promise.all(\n graph.nodes().map(async function(v) {\n const node = graph.node(v);\n if (parentCluster !== void 0) {\n const data = JSON.parse(JSON.stringify(parentCluster.clusterData));\n log.info(\"Setting data for cluster XXX (\", v, \") \", data, parentCluster);\n graph.setNode(parentCluster.id, data);\n if (!graph.parent(v)) {\n log.trace(\"Setting parent\", v, parentCluster.id);\n graph.setParent(v, parentCluster.id, data);\n }\n }\n log.info(\"(Insert) Node XXX\" + v + \": \" + JSON.stringify(graph.node(v)));\n if (node && node.clusterNode) {\n log.info(\"Cluster identified\", v, node.width, graph.node(v));\n const o = await recursiveRender(nodes, node.graph, diagramtype, id, graph.node(v));\n const newEl = o.elem;\n updateNodeBounds(node, newEl);\n node.diff = o.diff || 0;\n log.info(\"Node bounds (abc123)\", v, node, node.width, node.x, node.y);\n setNodeElem(newEl, node);\n log.warn(\"Recursive render complete \", newEl, node);\n } else {\n if (graph.children(v).length > 0) {\n log.info(\"Cluster - the non recursive path XXX\", v, node.id, node, graph);\n log.info(findNonClusterChild(node.id, graph));\n clusterDb[node.id] = { id: findNonClusterChild(node.id, graph), node };\n } else {\n log.info(\"Node - the non recursive path\", v, node.id, node);\n await insertNode(nodes, graph.node(v), dir);\n }\n }\n })\n );\n graph.edges().forEach(function(e) {\n const edge = graph.edge(e.v, e.w, e.name);\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(e));\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \", e, \" \", JSON.stringify(graph.edge(e)));\n log.info(\"Fix\", clusterDb, \"ids:\", e.v, e.w, \"Translateing: \", clusterDb[e.v], clusterDb[e.w]);\n insertEdgeLabel(edgeLabels, edge);\n });\n graph.edges().forEach(function(e) {\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(e));\n });\n log.info(\"#############################################\");\n log.info(\"### Layout ###\");\n log.info(\"#############################################\");\n log.info(graph);\n layout(graph);\n log.info(\"Graph after layout:\", graphlibJson.write(graph));\n let diff = 0;\n sortNodesByHierarchy(graph).forEach(function(v) {\n const node = graph.node(v);\n log.info(\"Position \" + v + \": \" + JSON.stringify(graph.node(v)));\n log.info(\n \"Position \" + v + \": (\" + node.x,\n \",\" + node.y,\n \") width: \",\n node.width,\n \" height: \",\n node.height\n );\n if (node && node.clusterNode) {\n positionNode(node);\n } else {\n if (graph.children(v).length > 0) {\n insertCluster(clusters, node);\n clusterDb[node.id].node = node;\n } else {\n positionNode(node);\n }\n }\n });\n graph.edges().forEach(function(e) {\n const edge = graph.edge(e);\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(edge), edge);\n const paths = insertEdge(edgePaths, e, edge, clusterDb, diagramtype, graph, id);\n positionEdgeLabel(edge, paths);\n });\n graph.nodes().forEach(function(v) {\n const n = graph.node(v);\n log.info(v, n.type, n.diff);\n if (n.type === \"group\") {\n diff = n.diff;\n }\n });\n return { elem, diff };\n};\nconst render = async (elem, graph, markers, diagramtype, id) => {\n insertMarkers(elem, markers, diagramtype, id);\n clear$2();\n clear$3();\n clear();\n clear$1();\n log.warn(\"Graph at first:\", JSON.stringify(graphlibJson.write(graph)));\n adjustClustersAndEdges(graph);\n log.warn(\"Graph after:\", JSON.stringify(graphlibJson.write(graph)));\n await recursiveRender(elem, graph, diagramtype, id);\n};\nexport {\n render as r\n};\n"], + "sources": ["../../node_modules/dagre-d3-es/src/graphlib/json.js", "../../node_modules/mermaid/dist/index-67a42d7d.js"], + "sourcesContent": ["import * as _ from 'lodash-es';\nimport { Graph } from './graph.js';\n\nexport { write, read };\n\nfunction write(g) {\n var json = {\n options: {\n directed: g.isDirected(),\n multigraph: g.isMultigraph(),\n compound: g.isCompound(),\n },\n nodes: writeNodes(g),\n edges: writeEdges(g),\n };\n if (!_.isUndefined(g.graph())) {\n json.value = _.clone(g.graph());\n }\n return json;\n}\n\nfunction writeNodes(g) {\n return _.map(g.nodes(), function (v) {\n var nodeValue = g.node(v);\n var parent = g.parent(v);\n var node = { v: v };\n if (!_.isUndefined(nodeValue)) {\n node.value = nodeValue;\n }\n if (!_.isUndefined(parent)) {\n node.parent = parent;\n }\n return node;\n });\n}\n\nfunction writeEdges(g) {\n return _.map(g.edges(), function (e) {\n var edgeValue = g.edge(e);\n var edge = { v: e.v, w: e.w };\n if (!_.isUndefined(e.name)) {\n edge.name = e.name;\n }\n if (!_.isUndefined(edgeValue)) {\n edge.value = edgeValue;\n }\n return edge;\n });\n}\n\nfunction read(json) {\n var g = new Graph(json.options).setGraph(json.value);\n _.each(json.nodes, function (entry) {\n g.setNode(entry.v, entry.value);\n if (entry.parent) {\n g.setParent(entry.v, entry.parent);\n }\n });\n _.each(json.edges, function (entry) {\n g.setEdge({ v: entry.v, w: entry.w, name: entry.name }, entry.value);\n });\n return g;\n}\n", "import { layout } from \"dagre-d3-es/src/dagre/index.js\";\nimport * as graphlibJson from \"dagre-d3-es/src/graphlib/json.js\";\nimport { c as createLabel, i as intersectRect, a as insertMarkers, b as clear$2, d as clear$3, u as updateNodeBounds, s as setNodeElem, e as insertNode, f as insertEdgeLabel, p as positionNode, g as insertEdge, h as positionEdgeLabel } from \"./edges-80f1ebb6.js\";\nimport { l as log, m as evaluate, c as getConfig } from \"./mermaid-934d9bea.js\";\nimport * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { a as createText } from \"./createText-aebacdfe.js\";\nimport { select } from \"d3\";\nlet clusterDb = {};\nlet descendants = {};\nlet parents = {};\nconst clear$1 = () => {\n descendants = {};\n parents = {};\n clusterDb = {};\n};\nconst isDescendant = (id, ancenstorId) => {\n log.trace(\"In isDecendant\", ancenstorId, \" \", id, \" = \", descendants[ancenstorId].includes(id));\n if (descendants[ancenstorId].includes(id)) {\n return true;\n }\n return false;\n};\nconst edgeInCluster = (edge, clusterId) => {\n log.info(\"Decendants of \", clusterId, \" is \", descendants[clusterId]);\n log.info(\"Edge is \", edge);\n if (edge.v === clusterId) {\n return false;\n }\n if (edge.w === clusterId) {\n return false;\n }\n if (!descendants[clusterId]) {\n log.debug(\"Tilt, \", clusterId, \",not in decendants\");\n return false;\n }\n return descendants[clusterId].includes(edge.v) || isDescendant(edge.v, clusterId) || isDescendant(edge.w, clusterId) || descendants[clusterId].includes(edge.w);\n};\nconst copy = (clusterId, graph, newGraph, rootId) => {\n log.warn(\n \"Copying children of \",\n clusterId,\n \"root\",\n rootId,\n \"data\",\n graph.node(clusterId),\n rootId\n );\n const nodes = graph.children(clusterId) || [];\n if (clusterId !== rootId) {\n nodes.push(clusterId);\n }\n log.warn(\"Copying (nodes) clusterId\", clusterId, \"nodes\", nodes);\n nodes.forEach((node) => {\n if (graph.children(node).length > 0) {\n copy(node, graph, newGraph, rootId);\n } else {\n const data = graph.node(node);\n log.info(\"cp \", node, \" to \", rootId, \" with parent \", clusterId);\n newGraph.setNode(node, data);\n if (rootId !== graph.parent(node)) {\n log.warn(\"Setting parent\", node, graph.parent(node));\n newGraph.setParent(node, graph.parent(node));\n }\n if (clusterId !== rootId && node !== clusterId) {\n log.debug(\"Setting parent\", node, clusterId);\n newGraph.setParent(node, clusterId);\n } else {\n log.info(\"In copy \", clusterId, \"root\", rootId, \"data\", graph.node(clusterId), rootId);\n log.debug(\n \"Not Setting parent for node=\",\n node,\n \"cluster!==rootId\",\n clusterId !== rootId,\n \"node!==clusterId\",\n node !== clusterId\n );\n }\n const edges = graph.edges(node);\n log.debug(\"Copying Edges\", edges);\n edges.forEach((edge) => {\n log.info(\"Edge\", edge);\n const data2 = graph.edge(edge.v, edge.w, edge.name);\n log.info(\"Edge data\", data2, rootId);\n try {\n if (edgeInCluster(edge, rootId)) {\n log.info(\"Copying as \", edge.v, edge.w, data2, edge.name);\n newGraph.setEdge(edge.v, edge.w, data2, edge.name);\n log.info(\"newGraph edges \", newGraph.edges(), newGraph.edge(newGraph.edges()[0]));\n } else {\n log.info(\n \"Skipping copy of edge \",\n edge.v,\n \"-->\",\n edge.w,\n \" rootId: \",\n rootId,\n \" clusterId:\",\n clusterId\n );\n }\n } catch (e) {\n log.error(e);\n }\n });\n }\n log.debug(\"Removing node\", node);\n graph.removeNode(node);\n });\n};\nconst extractDescendants = (id, graph) => {\n const children = graph.children(id);\n let res = [...children];\n for (const child of children) {\n parents[child] = id;\n res = [...res, ...extractDescendants(child, graph)];\n }\n return res;\n};\nconst findNonClusterChild = (id, graph) => {\n log.trace(\"Searching\", id);\n const children = graph.children(id);\n log.trace(\"Searching children of id \", id, children);\n if (children.length < 1) {\n log.trace(\"This is a valid node\", id);\n return id;\n }\n for (const child of children) {\n const _id = findNonClusterChild(child, graph);\n if (_id) {\n log.trace(\"Found replacement for\", id, \" => \", _id);\n return _id;\n }\n }\n};\nconst getAnchorId = (id) => {\n if (!clusterDb[id]) {\n return id;\n }\n if (!clusterDb[id].externalConnections) {\n return id;\n }\n if (clusterDb[id]) {\n return clusterDb[id].id;\n }\n return id;\n};\nconst adjustClustersAndEdges = (graph, depth) => {\n if (!graph || depth > 10) {\n log.debug(\"Opting out, no graph \");\n return;\n } else {\n log.debug(\"Opting in, graph \");\n }\n graph.nodes().forEach(function(id) {\n const children = graph.children(id);\n if (children.length > 0) {\n log.warn(\n \"Cluster identified\",\n id,\n \" Replacement id in edges: \",\n findNonClusterChild(id, graph)\n );\n descendants[id] = extractDescendants(id, graph);\n clusterDb[id] = { id: findNonClusterChild(id, graph), clusterData: graph.node(id) };\n }\n });\n graph.nodes().forEach(function(id) {\n const children = graph.children(id);\n const edges = graph.edges();\n if (children.length > 0) {\n log.debug(\"Cluster identified\", id, descendants);\n edges.forEach((edge) => {\n if (edge.v !== id && edge.w !== id) {\n const d1 = isDescendant(edge.v, id);\n const d2 = isDescendant(edge.w, id);\n if (d1 ^ d2) {\n log.warn(\"Edge: \", edge, \" leaves cluster \", id);\n log.warn(\"Decendants of XXX \", id, \": \", descendants[id]);\n clusterDb[id].externalConnections = true;\n }\n }\n });\n } else {\n log.debug(\"Not a cluster \", id, descendants);\n }\n });\n graph.edges().forEach(function(e) {\n const edge = graph.edge(e);\n log.warn(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(e));\n log.warn(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(graph.edge(e)));\n let v = e.v;\n let w = e.w;\n log.warn(\n \"Fix XXX\",\n clusterDb,\n \"ids:\",\n e.v,\n e.w,\n \"Translating: \",\n clusterDb[e.v],\n \" --- \",\n clusterDb[e.w]\n );\n if (clusterDb[e.v] && clusterDb[e.w] && clusterDb[e.v] === clusterDb[e.w]) {\n log.warn(\"Fixing and trixing link to self - removing XXX\", e.v, e.w, e.name);\n log.warn(\"Fixing and trixing - removing XXX\", e.v, e.w, e.name);\n v = getAnchorId(e.v);\n w = getAnchorId(e.w);\n graph.removeEdge(e.v, e.w, e.name);\n const specialId = e.w + \"---\" + e.v;\n graph.setNode(specialId, {\n domId: specialId,\n id: specialId,\n labelStyle: \"\",\n labelText: edge.label,\n padding: 0,\n shape: \"labelRect\",\n style: \"\"\n });\n const edge1 = structuredClone(edge);\n const edge2 = structuredClone(edge);\n edge1.label = \"\";\n edge1.arrowTypeEnd = \"none\";\n edge2.label = \"\";\n edge1.fromCluster = e.v;\n edge2.toCluster = e.v;\n graph.setEdge(v, specialId, edge1, e.name + \"-cyclic-special\");\n graph.setEdge(specialId, w, edge2, e.name + \"-cyclic-special\");\n } else if (clusterDb[e.v] || clusterDb[e.w]) {\n log.warn(\"Fixing and trixing - removing XXX\", e.v, e.w, e.name);\n v = getAnchorId(e.v);\n w = getAnchorId(e.w);\n graph.removeEdge(e.v, e.w, e.name);\n if (v !== e.v) {\n edge.fromCluster = e.v;\n }\n if (w !== e.w) {\n edge.toCluster = e.w;\n }\n log.warn(\"Fix Replacing with XXX\", v, w, e.name);\n graph.setEdge(v, w, edge, e.name);\n }\n });\n log.warn(\"Adjusted Graph\", graphlibJson.write(graph));\n extractor(graph, 0);\n log.trace(clusterDb);\n};\nconst extractor = (graph, depth) => {\n log.warn(\"extractor - \", depth, graphlibJson.write(graph), graph.children(\"D\"));\n if (depth > 10) {\n log.error(\"Bailing out\");\n return;\n }\n let nodes = graph.nodes();\n let hasChildren = false;\n for (const node of nodes) {\n const children = graph.children(node);\n hasChildren = hasChildren || children.length > 0;\n }\n if (!hasChildren) {\n log.debug(\"Done, no node has children\", graph.nodes());\n return;\n }\n log.debug(\"Nodes = \", nodes, depth);\n for (const node of nodes) {\n log.debug(\n \"Extracting node\",\n node,\n clusterDb,\n clusterDb[node] && !clusterDb[node].externalConnections,\n !graph.parent(node),\n graph.node(node),\n graph.children(\"D\"),\n \" Depth \",\n depth\n );\n if (!clusterDb[node]) {\n log.debug(\"Not a cluster\", node, depth);\n } else if (!clusterDb[node].externalConnections && // !graph.parent(node) &&\n graph.children(node) && graph.children(node).length > 0) {\n log.warn(\n \"Cluster without external connections, without a parent and with children\",\n node,\n depth\n );\n const graphSettings = graph.graph();\n let dir = graphSettings.rankdir === \"TB\" ? \"LR\" : \"TB\";\n if (clusterDb[node] && clusterDb[node].clusterData && clusterDb[node].clusterData.dir) {\n dir = clusterDb[node].clusterData.dir;\n log.warn(\"Fixing dir\", clusterDb[node].clusterData.dir, dir);\n }\n const clusterGraph = new graphlib.Graph({\n multigraph: true,\n compound: true\n }).setGraph({\n rankdir: dir,\n // Todo: set proper spacing\n nodesep: 50,\n ranksep: 50,\n marginx: 8,\n marginy: 8\n }).setDefaultEdgeLabel(function() {\n return {};\n });\n log.warn(\"Old graph before copy\", graphlibJson.write(graph));\n copy(node, graph, clusterGraph, node);\n graph.setNode(node, {\n clusterNode: true,\n id: node,\n clusterData: clusterDb[node].clusterData,\n labelText: clusterDb[node].labelText,\n graph: clusterGraph\n });\n log.warn(\"New graph after copy node: (\", node, \")\", graphlibJson.write(clusterGraph));\n log.debug(\"Old graph after copy\", graphlibJson.write(graph));\n } else {\n log.warn(\n \"Cluster ** \",\n node,\n \" **not meeting the criteria !externalConnections:\",\n !clusterDb[node].externalConnections,\n \" no parent: \",\n !graph.parent(node),\n \" children \",\n graph.children(node) && graph.children(node).length > 0,\n graph.children(\"D\"),\n depth\n );\n log.debug(clusterDb);\n }\n }\n nodes = graph.nodes();\n log.warn(\"New list of nodes\", nodes);\n for (const node of nodes) {\n const data = graph.node(node);\n log.warn(\" Now next level\", node, data);\n if (data.clusterNode) {\n extractor(data.graph, depth + 1);\n }\n }\n};\nconst sorter = (graph, nodes) => {\n if (nodes.length === 0) {\n return [];\n }\n let result = Object.assign(nodes);\n nodes.forEach((node) => {\n const children = graph.children(node);\n const sorted = sorter(graph, children);\n result = [...result, ...sorted];\n });\n return result;\n};\nconst sortNodesByHierarchy = (graph) => sorter(graph, graph.children());\nconst rect = (parent, node) => {\n log.info(\"Creating subgraph rect for \", node.id, node);\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"cluster\" + (node.class ? \" \" + node.class : \"\")).attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const useHtmlLabels = evaluate(getConfig().flowchart.htmlLabels);\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"cluster-label\");\n const text = node.labelType === \"markdown\" ? createText(label, node.labelText, { style: node.labelStyle, useHtmlLabels }) : label.node().appendChild(createLabel(node.labelText, node.labelStyle, void 0, true));\n let bbox = text.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n const width = node.width <= bbox.width + padding ? bbox.width + padding : node.width;\n if (node.width <= bbox.width + padding) {\n node.diff = (bbox.width - node.width) / 2 - node.padding / 2;\n } else {\n node.diff = -node.padding / 2;\n }\n log.trace(\"Data \", node, JSON.stringify(node));\n rect2.attr(\"style\", node.style).attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", node.x - width / 2).attr(\"y\", node.y - node.height / 2 - halfPadding).attr(\"width\", width).attr(\"height\", node.height + padding);\n if (useHtmlLabels) {\n label.attr(\n \"transform\",\n // This puts the labal on top of the box instead of inside it\n \"translate(\" + (node.x - bbox.width / 2) + \", \" + (node.y - node.height / 2) + \")\"\n );\n } else {\n label.attr(\n \"transform\",\n // This puts the labal on top of the box instead of inside it\n \"translate(\" + node.x + \", \" + (node.y - node.height / 2) + \")\"\n );\n }\n const rectBox = rect2.node().getBBox();\n node.width = rectBox.width;\n node.height = rectBox.height;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst noteGroup = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", \"note-cluster\").attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n rect2.attr(\"rx\", node.rx).attr(\"ry\", node.ry).attr(\"x\", node.x - node.width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2 - halfPadding).attr(\"width\", node.width + padding).attr(\"height\", node.height + padding).attr(\"fill\", \"none\");\n const rectBox = rect2.node().getBBox();\n node.width = rectBox.width;\n node.height = rectBox.height;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst roundedWithTitle = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", node.classes).attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const label = shapeSvg.insert(\"g\").attr(\"class\", \"cluster-label\");\n const innerRect = shapeSvg.append(\"rect\");\n const text = label.node().appendChild(createLabel(node.labelText, node.labelStyle, void 0, true));\n let bbox = text.getBBox();\n if (evaluate(getConfig().flowchart.htmlLabels)) {\n const div = text.children[0];\n const dv = select(text);\n bbox = div.getBoundingClientRect();\n dv.attr(\"width\", bbox.width);\n dv.attr(\"height\", bbox.height);\n }\n bbox = text.getBBox();\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n const width = node.width <= bbox.width + node.padding ? bbox.width + node.padding : node.width;\n if (node.width <= bbox.width + node.padding) {\n node.diff = (bbox.width + node.padding * 0 - node.width) / 2;\n } else {\n node.diff = -node.padding / 2;\n }\n rect2.attr(\"class\", \"outer\").attr(\"x\", node.x - width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2 - halfPadding).attr(\"width\", width + padding).attr(\"height\", node.height + padding);\n innerRect.attr(\"class\", \"inner\").attr(\"x\", node.x - width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2 - halfPadding + bbox.height - 1).attr(\"width\", width + padding).attr(\"height\", node.height + padding - bbox.height - 3);\n label.attr(\n \"transform\",\n \"translate(\" + (node.x - bbox.width / 2) + \", \" + (node.y - node.height / 2 - node.padding / 3 + (evaluate(getConfig().flowchart.htmlLabels) ? 5 : 3)) + \")\"\n );\n const rectBox = rect2.node().getBBox();\n node.height = rectBox.height;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst divider = (parent, node) => {\n const shapeSvg = parent.insert(\"g\").attr(\"class\", node.classes).attr(\"id\", node.id);\n const rect2 = shapeSvg.insert(\"rect\", \":first-child\");\n const padding = 0 * node.padding;\n const halfPadding = padding / 2;\n rect2.attr(\"class\", \"divider\").attr(\"x\", node.x - node.width / 2 - halfPadding).attr(\"y\", node.y - node.height / 2).attr(\"width\", node.width + padding).attr(\"height\", node.height + padding);\n const rectBox = rect2.node().getBBox();\n node.width = rectBox.width;\n node.height = rectBox.height;\n node.diff = -node.padding / 2;\n node.intersect = function(point) {\n return intersectRect(node, point);\n };\n return shapeSvg;\n};\nconst shapes = { rect, roundedWithTitle, noteGroup, divider };\nlet clusterElems = {};\nconst insertCluster = (elem, node) => {\n log.trace(\"Inserting cluster\");\n const shape = node.shape || \"rect\";\n clusterElems[node.id] = shapes[shape](elem, node);\n};\nconst clear = () => {\n clusterElems = {};\n};\nconst recursiveRender = async (_elem, graph, diagramtype, id, parentCluster) => {\n log.info(\"Graph in recursive render: XXX\", graphlibJson.write(graph), parentCluster);\n const dir = graph.graph().rankdir;\n log.trace(\"Dir in recursive render - dir:\", dir);\n const elem = _elem.insert(\"g\").attr(\"class\", \"root\");\n if (!graph.nodes()) {\n log.info(\"No nodes found for\", graph);\n } else {\n log.info(\"Recursive render XXX\", graph.nodes());\n }\n if (graph.edges().length > 0) {\n log.trace(\"Recursive edges\", graph.edge(graph.edges()[0]));\n }\n const clusters = elem.insert(\"g\").attr(\"class\", \"clusters\");\n const edgePaths = elem.insert(\"g\").attr(\"class\", \"edgePaths\");\n const edgeLabels = elem.insert(\"g\").attr(\"class\", \"edgeLabels\");\n const nodes = elem.insert(\"g\").attr(\"class\", \"nodes\");\n await Promise.all(\n graph.nodes().map(async function(v) {\n const node = graph.node(v);\n if (parentCluster !== void 0) {\n const data = JSON.parse(JSON.stringify(parentCluster.clusterData));\n log.info(\"Setting data for cluster XXX (\", v, \") \", data, parentCluster);\n graph.setNode(parentCluster.id, data);\n if (!graph.parent(v)) {\n log.trace(\"Setting parent\", v, parentCluster.id);\n graph.setParent(v, parentCluster.id, data);\n }\n }\n log.info(\"(Insert) Node XXX\" + v + \": \" + JSON.stringify(graph.node(v)));\n if (node && node.clusterNode) {\n log.info(\"Cluster identified\", v, node.width, graph.node(v));\n const o = await recursiveRender(nodes, node.graph, diagramtype, id, graph.node(v));\n const newEl = o.elem;\n updateNodeBounds(node, newEl);\n node.diff = o.diff || 0;\n log.info(\"Node bounds (abc123)\", v, node, node.width, node.x, node.y);\n setNodeElem(newEl, node);\n log.warn(\"Recursive render complete \", newEl, node);\n } else {\n if (graph.children(v).length > 0) {\n log.info(\"Cluster - the non recursive path XXX\", v, node.id, node, graph);\n log.info(findNonClusterChild(node.id, graph));\n clusterDb[node.id] = { id: findNonClusterChild(node.id, graph), node };\n } else {\n log.info(\"Node - the non recursive path\", v, node.id, node);\n await insertNode(nodes, graph.node(v), dir);\n }\n }\n })\n );\n graph.edges().forEach(function(e) {\n const edge = graph.edge(e.v, e.w, e.name);\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(e));\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \", e, \" \", JSON.stringify(graph.edge(e)));\n log.info(\"Fix\", clusterDb, \"ids:\", e.v, e.w, \"Translateing: \", clusterDb[e.v], clusterDb[e.w]);\n insertEdgeLabel(edgeLabels, edge);\n });\n graph.edges().forEach(function(e) {\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(e));\n });\n log.info(\"#############################################\");\n log.info(\"### Layout ###\");\n log.info(\"#############################################\");\n log.info(graph);\n layout(graph);\n log.info(\"Graph after layout:\", graphlibJson.write(graph));\n let diff = 0;\n sortNodesByHierarchy(graph).forEach(function(v) {\n const node = graph.node(v);\n log.info(\"Position \" + v + \": \" + JSON.stringify(graph.node(v)));\n log.info(\n \"Position \" + v + \": (\" + node.x,\n \",\" + node.y,\n \") width: \",\n node.width,\n \" height: \",\n node.height\n );\n if (node && node.clusterNode) {\n positionNode(node);\n } else {\n if (graph.children(v).length > 0) {\n insertCluster(clusters, node);\n clusterDb[node.id].node = node;\n } else {\n positionNode(node);\n }\n }\n });\n graph.edges().forEach(function(e) {\n const edge = graph.edge(e);\n log.info(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(edge), edge);\n const paths = insertEdge(edgePaths, e, edge, clusterDb, diagramtype, graph, id);\n positionEdgeLabel(edge, paths);\n });\n graph.nodes().forEach(function(v) {\n const n = graph.node(v);\n log.info(v, n.type, n.diff);\n if (n.type === \"group\") {\n diff = n.diff;\n }\n });\n return { elem, diff };\n};\nconst render = async (elem, graph, markers, diagramtype, id) => {\n insertMarkers(elem, markers, diagramtype, id);\n clear$2();\n clear$3();\n clear();\n clear$1();\n log.warn(\"Graph at first:\", JSON.stringify(graphlibJson.write(graph)));\n adjustClustersAndEdges(graph);\n log.warn(\"Graph after:\", JSON.stringify(graphlibJson.write(graph)));\n await recursiveRender(elem, graph, diagramtype, id);\n};\nexport {\n render as r\n};\n"], "mappings": "iTAKA,SAASA,EAAMC,EAAG,CAChB,IAAIC,EAAO,CACT,QAAS,CACP,SAAUD,EAAE,WAAW,EACvB,WAAYA,EAAE,aAAa,EAC3B,SAAUA,EAAE,WAAW,CACzB,EACA,MAAOE,EAAWF,CAAC,EACnB,MAAOG,EAAWH,CAAC,CACrB,EACA,OAAOI,EAAYJ,EAAE,MAAM,CAAC,IAC1BC,EAAK,MAAUI,EAAML,EAAE,MAAM,CAAC,GAEzBC,CACT,CAEA,SAASC,EAAWF,EAAG,CACrB,OAASM,EAAIN,EAAE,MAAM,EAAG,SAAUO,EAAG,CACnC,IAAIC,EAAYR,EAAE,KAAKO,CAAC,EACpBE,EAAST,EAAE,OAAOO,CAAC,EACnBG,EAAO,CAAE,EAAGH,CAAE,EAClB,OAAOH,EAAYI,CAAS,IAC1BE,EAAK,MAAQF,GAERJ,EAAYK,CAAM,IACvBC,EAAK,OAASD,GAETC,CACT,CAAC,CACH,CAEA,SAASP,EAAWH,EAAG,CACrB,OAASM,EAAIN,EAAE,MAAM,EAAG,SAAUW,EAAG,CACnC,IAAIC,EAAYZ,EAAE,KAAKW,CAAC,EACpBE,EAAO,CAAE,EAAGF,EAAE,EAAG,EAAGA,EAAE,CAAE,EAC5B,OAAOP,EAAYO,EAAE,IAAI,IACvBE,EAAK,KAAOF,EAAE,MAETP,EAAYQ,CAAS,IAC1BC,EAAK,MAAQD,GAERC,CACT,CAAC,CACH,CCzCA,IAAIC,EAAY,CAAC,EACb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"v", "nodeValue", "parent", "node", "e", "edgeValue", "edge", "clusterDb", "descendants", "parents", "clear$1", "isDescendant", "id", "ancenstorId", "log$1", "edgeInCluster", "edge", "clusterId", "copy", "graph", "newGraph", "rootId", "nodes", "node", "data", "edges", "data2", "e", "extractDescendants", "children", "res", "child", "findNonClusterChild", "_id", "getAnchorId", "adjustClustersAndEdges", "depth", "d1", "d2", "v", "w", "specialId", "edge1", "edge2", "write", "extractor", "hasChildren", "dir", "clusterGraph", "Graph", "sorter", "result", "sorted", "sortNodesByHierarchy", "rect", "parent", "shapeSvg", "rect2", "useHtmlLabels", "evaluate", "getConfig", "label", "text", "createText", "createLabel$1", "bbox", "div", "dv", "select_default", "padding", "halfPadding", "width", "rectBox", "point", "intersectRect$1", "noteGroup", "roundedWithTitle", "innerRect", "divider", "shapes", "clusterElems", "insertCluster", "elem", "shape", "clear", "recursiveRender", "_elem", "diagramtype", "parentCluster", "clusters", "edgePaths", "edgeLabels", "o", "newEl", "updateNodeBounds", "setNodeElem", "insertNode", "insertEdgeLabel", "layout", "diff", "positionNode", "paths", "insertEdge", "positionEdgeLabel", "n", "render", "markers", "insertMarkers$1"] } diff --git a/docs/public/chunk-TYUXPGKI.min.js b/docs/public/chunk-ZMRDHQ6H.min.js similarity index 99% rename from docs/public/chunk-TYUXPGKI.min.js rename to docs/public/chunk-ZMRDHQ6H.min.js index e8d5a1f0..3083634f 100644 --- a/docs/public/chunk-TYUXPGKI.min.js +++ b/docs/public/chunk-ZMRDHQ6H.min.js @@ -1,8 +1,8 @@ -import{Ga as gt,a as xt,pb as dt}from"./chunk-65WDIALL.min.js";import{c as ue}from"./chunk-P42HNYSU.min.js";var ae={};function Un(n,r){let t=r||ae,e=typeof t.includeImageAlt=="boolean"?t.includeImageAlt:!0,u=typeof t.includeHtml=="boolean"?t.includeHtml:!0;return yt(n,e,u)}function yt(n,r,t){if(oe(n)){if("value"in n)return n.type==="html"&&!t?"":n.value;if(r&&"alt"in n&&n.alt)return n.alt;if("children"in n)return kt(n.children,r,t)}return Array.isArray(n)?kt(n,r,t):""}function kt(n,r,t){let e=[],u=-1;for(;++uu?0:u+r:r=r>u?u:r,t=t>0?t:0,e.length<1e4)i=Array.from(e),i.unshift(r,t),[].splice.apply(n,i);else for(t&&[].splice.apply(n,[r,t]);a0?(Z(n,n.length,0,r),n):r}var bt={}.hasOwnProperty;function St(n){let r={},t=-1;for(;++ti))return;let j=r.events.length,H=j,M,Q;for(;H--;)if(r.events[H][0]==="exit"&&r.events[H][1].type==="chunkFlow"){if(M){Q=r.events[H][1].end;break}M=!0}for(b(e),d=j;dw;){let _=t[P];r.containerState=_[1],_[0].exit.call(r,n)}t.length=w}function R(){u.write([null]),a=void 0,u=void 0,r.containerState._closeFlow=void 0}}function me(n,r,t){return C(n,n.attempt(this.parser.constructs.document,r,t),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Zn(n){if(n===null||V(n)||Ct(n))return 1;if(At(n))return 2}function yn(n,r,t){let e=[],u=-1;for(;++u1&&n[t][1].end.offset-n[t][1].start.offset>1?2:1;let y=Object.assign({},n[e][1].end),h=Object.assign({},n[t][1].start);Lt(y,-p),Lt(h,p),i={type:p>1?"strongSequence":"emphasisSequence",start:y,end:Object.assign({},n[e][1].end)},o={type:p>1?"strongSequence":"emphasisSequence",start:Object.assign({},n[t][1].start),end:h},a={type:p>1?"strongText":"emphasisText",start:Object.assign({},n[e][1].end),end:Object.assign({},n[t][1].start)},u={type:p>1?"strong":"emphasis",start:Object.assign({},i.start),end:Object.assign({},o.end)},n[e][1].end=Object.assign({},i.start),n[t][1].start=Object.assign({},o.end),m=[],n[e][1].end.offset-n[e][1].start.offset&&(m=J(m,[["enter",n[e][1],r],["exit",n[e][1],r]])),m=J(m,[["enter",u,r],["enter",i,r],["exit",i,r],["enter",a,r]]),m=J(m,yn(r.parser.constructs.insideSpan.null,n.slice(e+1,t),r)),m=J(m,[["exit",a,r],["enter",o,r],["exit",o,r],["exit",u,r]]),n[t][1].end.offset-n[t][1].start.offset?(c=2,m=J(m,[["enter",n[t][1],r],["exit",n[t][1],r]])):c=0,Z(n,e-1,t-e+3,m),t=e+m.length-c-2;break}}for(t=-1;++t=4?i(m):t(m)}function i(m){return m===null?p(m):S(m)?n.attempt(we,i,p)(m):(n.enter("codeFlowValue"),o(m))}function o(m){return m===null||S(m)?(n.exit("codeFlowValue"),i(m)):(n.consume(m),o)}function p(m){return n.exit("codeIndented"),r(m)}}function Ce(n,r,t){let e=this;return u;function u(i){return e.parser.lazy[e.now().line]?t(i):S(i)?(n.enter("lineEnding"),n.consume(i),n.exit("lineEnding"),u):C(n,a,"linePrefix",4+1)(i)}function a(i){let o=e.events[e.events.length-1];return o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?r(i):S(i)?u(i):t(i)}}var Gn={name:"codeText",tokenize:Ie,resolve:Ae,previous:ze};function Ae(n){let r=n.length-4,t=3,e,u;if((n[t][1].type==="lineEnding"||n[t][1].type==="space")&&(n[r][1].type==="lineEnding"||n[r][1].type==="space")){for(e=t;++e=4?r(i):n.interrupt(e.parser.constructs.flow,t,r)(i)}}function Rn(n,r,t,e,u,a,i,o,p){let m=p||Number.POSITIVE_INFINITY,c=0;return y;function y(b){return b===60?(n.enter(e),n.enter(u),n.enter(a),n.consume(b),n.exit(a),h):b===null||b===41||In(b)?t(b):(n.enter(e),n.enter(i),n.enter(o),n.enter("chunkString",{contentType:"string"}),L(b))}function h(b){return b===62?(n.enter(a),n.consume(b),n.exit(a),n.exit(u),n.exit(e),r):(n.enter(o),n.enter("chunkString",{contentType:"string"}),x(b))}function x(b){return b===62?(n.exit("chunkString"),n.exit(o),h(b)):b===null||b===60||S(b)?t(b):(n.consume(b),b===92?g:x)}function g(b){return b===60||b===62||b===92?(n.consume(b),x):x(b)}function L(b){return b===40?++c>m?t(b):(n.consume(b),L):b===41?c--?(n.consume(b),L):(n.exit("chunkString"),n.exit(o),n.exit(i),n.exit(e),r(b)):b===null||V(b)?c?t(b):(n.exit("chunkString"),n.exit(o),n.exit(i),n.exit(e),r(b)):In(b)?t(b):(n.consume(b),b===92?O:L)}function O(b){return b===40||b===41||b===92?(n.consume(b),L):L(b)}}function jn(n,r,t,e,u,a){let i=this,o=0,p;return m;function m(x){return n.enter(e),n.enter(u),n.consume(x),n.exit(u),n.enter(a),c}function c(x){return x===null||x===91||x===93&&!p||x===94&&!o&&"_hiddenFootnoteSupport"in i.parser.constructs||o>999?t(x):x===93?(n.exit(a),n.enter(u),n.consume(x),n.exit(u),n.exit(e),r):S(x)?(n.enter("lineEnding"),n.consume(x),n.exit("lineEnding"),c):(n.enter("chunkString",{contentType:"string"}),y(x))}function y(x){return x===null||x===91||x===93||S(x)||o++>999?(n.exit("chunkString"),c(x)):(n.consume(x),p=p||!I(x),x===92?h:y)}function h(x){return x===91||x===92||x===93?(n.consume(x),o++,y):y(x)}}function qn(n,r,t,e,u,a){let i;return o;function o(h){return n.enter(e),n.enter(u),n.consume(h),n.exit(u),i=h===40?41:h,p}function p(h){return h===i?(n.enter(u),n.consume(h),n.exit(u),n.exit(e),r):(n.enter(a),m(h))}function m(h){return h===i?(n.exit(a),p(i)):h===null?t(h):S(h)?(n.enter("lineEnding"),n.consume(h),n.exit("lineEnding"),C(n,m,"linePrefix")):(n.enter("chunkString",{contentType:"string"}),c(h))}function c(h){return h===i||h===null||S(h)?(n.exit("chunkString"),m(h)):(n.consume(h),h===92?y:c)}function y(h){return h===i||h===92?(n.consume(h),c):c(h)}}function fn(n,r){let t;return e;function e(u){return S(u)?(n.enter("lineEnding"),n.consume(u),n.exit("lineEnding"),t=!0,e):I(u)?C(n,e,t?"linePrefix":"lineSuffix")(u):r(u)}}function on(n){return n.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}var Kn={name:"definition",tokenize:_e},Pe={tokenize:Me,partial:!0};function _e(n,r,t){let e=this,u;return a;function a(p){return n.enter("definition"),jn.call(e,n,i,t,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function i(p){return u=on(e.sliceSerialize(e.events[e.events.length-1][1]).slice(1,-1)),p===58?(n.enter("definitionMarker"),n.consume(p),n.exit("definitionMarker"),fn(n,Rn(n,n.attempt(Pe,C(n,o,"whitespace"),C(n,o,"whitespace")),t,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString"))):t(p)}function o(p){return p===null||S(p)?(n.exit("definition"),e.parser.defined.includes(u)||e.parser.defined.push(u),r(p)):t(p)}}function Me(n,r,t){return e;function e(i){return V(i)?fn(n,u)(i):t(i)}function u(i){return i===34||i===39||i===40?qn(n,C(n,a,"whitespace"),t,"definitionTitle","definitionTitleMarker","definitionTitleString")(i):t(i)}function a(i){return i===null||S(i)?r(i):t(i)}}var Xn={name:"hardBreakEscape",tokenize:Re};function Re(n,r,t){return e;function e(a){return n.enter("hardBreakEscape"),n.enter("escapeMarker"),n.consume(a),u}function u(a){return S(a)?(n.exit("escapeMarker"),n.exit("hardBreakEscape"),r(a)):t(a)}}var vn={name:"headingAtx",tokenize:qe,resolve:je};function je(n,r){let t=n.length-2,e=3,u,a;return n[e][1].type==="whitespace"&&(e+=2),t-2>e&&n[t][1].type==="whitespace"&&(t-=2),n[t][1].type==="atxHeadingSequence"&&(e===t-1||t-4>e&&n[t-2][1].type==="whitespace")&&(t-=e+1===t?2:4),t>e&&(u={type:"atxHeadingText",start:n[e][1].start,end:n[t][1].end},a={type:"chunkText",start:n[e][1].start,end:n[t][1].end,contentType:"text"},Z(n,e,t-e+1,[["enter",u,r],["enter",a,r],["exit",a,r],["exit",u,r]])),n}function qe(n,r,t){let e=this,u=0;return a;function a(c){return n.enter("atxHeading"),n.enter("atxHeadingSequence"),i(c)}function i(c){return c===35&&u++<6?(n.consume(c),i):c===null||V(c)?(n.exit("atxHeadingSequence"),e.interrupt?r(c):o(c)):t(c)}function o(c){return c===35?(n.enter("atxHeadingSequence"),p(c)):c===null||S(c)?(n.exit("atxHeading"),r(c)):I(c)?C(n,o,"whitespace")(c):(n.enter("atxHeadingText"),m(c))}function p(c){return c===35?(n.consume(c),p):(n.exit("atxHeadingSequence"),o(c))}function m(c){return c===null||c===35||V(c)?(n.exit("atxHeadingText"),o(c)):(n.consume(c),m)}}var Ot=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],nt=["pre","script","style","textarea"];var tt={name:"htmlFlow",tokenize:Ve,resolveTo:Ne,concrete:!0},He={tokenize:We,partial:!0};function Ne(n){let r=n.length;for(;r--&&!(n[r][0]==="enter"&&n[r][1].type==="htmlFlow"););return r>1&&n[r-2][1].type==="linePrefix"&&(n[r][1].start=n[r-2][1].start,n[r+1][1].start=n[r-2][1].start,n.splice(r-2,2)),n}function Ve(n,r,t){let e=this,u,a,i,o,p;return m;function m(l){return n.enter("htmlFlow"),n.enter("htmlFlowData"),n.consume(l),c}function c(l){return l===33?(n.consume(l),y):l===47?(n.consume(l),g):l===63?(n.consume(l),u=3,e.interrupt?r:G):v(l)?(n.consume(l),i=String.fromCharCode(l),a=!0,L):t(l)}function y(l){return l===45?(n.consume(l),u=2,h):l===91?(n.consume(l),u=5,i="CDATA[",o=0,x):v(l)?(n.consume(l),u=4,e.interrupt?r:G):t(l)}function h(l){return l===45?(n.consume(l),e.interrupt?r:G):t(l)}function x(l){return l===i.charCodeAt(o++)?(n.consume(l),o===i.length?e.interrupt?r:A:x):t(l)}function g(l){return v(l)?(n.consume(l),i=String.fromCharCode(l),L):t(l)}function L(l){return l===null||l===47||l===62||V(l)?l!==47&&a&&nt.includes(i.toLowerCase())?(u=1,e.interrupt?r(l):A(l)):Ot.includes(i.toLowerCase())?(u=6,l===47?(n.consume(l),O):e.interrupt?r(l):A(l)):(u=7,e.interrupt&&!e.parser.lazy[e.now().line]?t(l):a?R(l):b(l)):l===45||K(l)?(n.consume(l),i+=String.fromCharCode(l),L):t(l)}function O(l){return l===62?(n.consume(l),e.interrupt?r:A):t(l)}function b(l){return I(l)?(n.consume(l),b):M(l)}function R(l){return l===47?(n.consume(l),M):l===58||l===95||v(l)?(n.consume(l),w):I(l)?(n.consume(l),R):M(l)}function w(l){return l===45||l===46||l===58||l===95||K(l)?(n.consume(l),w):P(l)}function P(l){return l===61?(n.consume(l),_):I(l)?(n.consume(l),P):R(l)}function _(l){return l===null||l===60||l===61||l===62||l===96?t(l):l===34||l===39?(n.consume(l),p=l,d):I(l)?(n.consume(l),_):(p=null,j(l))}function d(l){return l===null||S(l)?t(l):l===p?(n.consume(l),H):(n.consume(l),d)}function j(l){return l===null||l===34||l===39||l===60||l===61||l===62||l===96||V(l)?P(l):(n.consume(l),j)}function H(l){return l===47||l===62||I(l)?R(l):t(l)}function M(l){return l===62?(n.consume(l),Q):t(l)}function Q(l){return I(l)?(n.consume(l),Q):l===null||S(l)?A(l):t(l)}function A(l){return l===45&&u===2?(n.consume(l),U):l===60&&u===1?(n.consume(l),X):l===62&&u===4?(n.consume(l),N):l===63&&u===3?(n.consume(l),G):l===93&&u===5?(n.consume(l),W):S(l)&&(u===6||u===7)?n.check(He,N,D)(l):l===null||S(l)?D(l):(n.consume(l),A)}function D(l){return n.exit("htmlFlowData"),E(l)}function E(l){return l===null?s(l):S(l)?n.attempt({tokenize:z,partial:!0},E,s)(l):(n.enter("htmlFlowData"),A(l))}function z(l,En,mn){return dn;function dn(en){return l.enter("lineEnding"),l.consume(en),l.exit("lineEnding"),wn}function wn(en){return e.parser.lazy[e.now().line]?mn(en):En(en)}}function U(l){return l===45?(n.consume(l),G):A(l)}function X(l){return l===47?(n.consume(l),i="",nn):A(l)}function nn(l){return l===62&&nt.includes(i.toLowerCase())?(n.consume(l),N):v(l)&&i.length<8?(n.consume(l),i+=String.fromCharCode(l),nn):A(l)}function W(l){return l===93?(n.consume(l),G):A(l)}function G(l){return l===62?(n.consume(l),N):l===45&&u===2?(n.consume(l),G):A(l)}function N(l){return l===null||S(l)?(n.exit("htmlFlowData"),s(l)):(n.consume(l),N)}function s(l){return n.exit("htmlFlow"),r(l)}}function We(n,r,t){return e;function e(u){return n.exit("htmlFlowData"),n.enter("lineEndingBlank"),n.consume(u),n.exit("lineEndingBlank"),n.attempt(cn,r,t)}}var et={name:"htmlText",tokenize:Qe};function Qe(n,r,t){let e=this,u,a,i,o;return p;function p(s){return n.enter("htmlText"),n.enter("htmlTextData"),n.consume(s),m}function m(s){return s===33?(n.consume(s),c):s===47?(n.consume(s),j):s===63?(n.consume(s),_):v(s)?(n.consume(s),Q):t(s)}function c(s){return s===45?(n.consume(s),y):s===91?(n.consume(s),a="CDATA[",i=0,O):v(s)?(n.consume(s),P):t(s)}function y(s){return s===45?(n.consume(s),h):t(s)}function h(s){return s===null||s===62?t(s):s===45?(n.consume(s),x):g(s)}function x(s){return s===null||s===62?t(s):g(s)}function g(s){return s===null?t(s):s===45?(n.consume(s),L):S(s)?(o=g,W(s)):(n.consume(s),g)}function L(s){return s===45?(n.consume(s),N):g(s)}function O(s){return s===a.charCodeAt(i++)?(n.consume(s),i===a.length?b:O):t(s)}function b(s){return s===null?t(s):s===93?(n.consume(s),R):S(s)?(o=b,W(s)):(n.consume(s),b)}function R(s){return s===93?(n.consume(s),w):b(s)}function w(s){return s===62?N(s):s===93?(n.consume(s),w):b(s)}function P(s){return s===null||s===62?N(s):S(s)?(o=P,W(s)):(n.consume(s),P)}function _(s){return s===null?t(s):s===63?(n.consume(s),d):S(s)?(o=_,W(s)):(n.consume(s),_)}function d(s){return s===62?N(s):_(s)}function j(s){return v(s)?(n.consume(s),H):t(s)}function H(s){return s===45||K(s)?(n.consume(s),H):M(s)}function M(s){return S(s)?(o=M,W(s)):I(s)?(n.consume(s),M):N(s)}function Q(s){return s===45||K(s)?(n.consume(s),Q):s===47||s===62||V(s)?A(s):t(s)}function A(s){return s===47?(n.consume(s),N):s===58||s===95||v(s)?(n.consume(s),D):S(s)?(o=A,W(s)):I(s)?(n.consume(s),A):N(s)}function D(s){return s===45||s===46||s===58||s===95||K(s)?(n.consume(s),D):E(s)}function E(s){return s===61?(n.consume(s),z):S(s)?(o=E,W(s)):I(s)?(n.consume(s),E):A(s)}function z(s){return s===null||s===60||s===61||s===62||s===96?t(s):s===34||s===39?(n.consume(s),u=s,U):S(s)?(o=z,W(s)):I(s)?(n.consume(s),z):(n.consume(s),u=void 0,nn)}function U(s){return s===u?(n.consume(s),X):s===null?t(s):S(s)?(o=U,W(s)):(n.consume(s),U)}function X(s){return s===62||s===47||V(s)?A(s):t(s)}function nn(s){return s===null||s===34||s===39||s===60||s===61||s===96?t(s):s===62||V(s)?A(s):(n.consume(s),nn)}function W(s){return n.exit("htmlTextData"),n.enter("lineEnding"),n.consume(s),n.exit("lineEnding"),C(n,G,"linePrefix",e.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function G(s){return n.enter("htmlTextData"),o(s)}function N(s){return s===62?(n.consume(s),n.exit("htmlTextData"),n.exit("htmlText"),r):t(s)}}var xn={name:"labelEnd",tokenize:Je,resolveTo:Ge,resolveAll:Ye},Ue={tokenize:Ke},$e={tokenize:Xe},Ze={tokenize:ve};function Ye(n){let r=-1,t;for(;++r-1&&(i[0]=i[0].slice(e)),a>0&&i.push(n[u].slice(0,a))),i}function gr(n,r){let t=-1,e=[],u;for(;++tu?0:u+r:r=r>u?u:r,t=t>0?t:0,e.length<1e4)i=Array.from(e),i.unshift(r,t),[].splice.apply(n,i);else for(t&&[].splice.apply(n,[r,t]);a0?(Z(n,n.length,0,r),n):r}var bt={}.hasOwnProperty;function St(n){let r={},t=-1;for(;++ti))return;let j=r.events.length,H=j,M,Q;for(;H--;)if(r.events[H][0]==="exit"&&r.events[H][1].type==="chunkFlow"){if(M){Q=r.events[H][1].end;break}M=!0}for(b(e),d=j;dw;){let _=t[P];r.containerState=_[1],_[0].exit.call(r,n)}t.length=w}function R(){u.write([null]),a=void 0,u=void 0,r.containerState._closeFlow=void 0}}function me(n,r,t){return C(n,n.attempt(this.parser.constructs.document,r,t),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Zn(n){if(n===null||V(n)||Ct(n))return 1;if(At(n))return 2}function yn(n,r,t){let e=[],u=-1;for(;++u1&&n[t][1].end.offset-n[t][1].start.offset>1?2:1;let y=Object.assign({},n[e][1].end),h=Object.assign({},n[t][1].start);Lt(y,-p),Lt(h,p),i={type:p>1?"strongSequence":"emphasisSequence",start:y,end:Object.assign({},n[e][1].end)},o={type:p>1?"strongSequence":"emphasisSequence",start:Object.assign({},n[t][1].start),end:h},a={type:p>1?"strongText":"emphasisText",start:Object.assign({},n[e][1].end),end:Object.assign({},n[t][1].start)},u={type:p>1?"strong":"emphasis",start:Object.assign({},i.start),end:Object.assign({},o.end)},n[e][1].end=Object.assign({},i.start),n[t][1].start=Object.assign({},o.end),m=[],n[e][1].end.offset-n[e][1].start.offset&&(m=J(m,[["enter",n[e][1],r],["exit",n[e][1],r]])),m=J(m,[["enter",u,r],["enter",i,r],["exit",i,r],["enter",a,r]]),m=J(m,yn(r.parser.constructs.insideSpan.null,n.slice(e+1,t),r)),m=J(m,[["exit",a,r],["enter",o,r],["exit",o,r],["exit",u,r]]),n[t][1].end.offset-n[t][1].start.offset?(c=2,m=J(m,[["enter",n[t][1],r],["exit",n[t][1],r]])):c=0,Z(n,e-1,t-e+3,m),t=e+m.length-c-2;break}}for(t=-1;++t=4?i(m):t(m)}function i(m){return m===null?p(m):S(m)?n.attempt(we,i,p)(m):(n.enter("codeFlowValue"),o(m))}function o(m){return m===null||S(m)?(n.exit("codeFlowValue"),i(m)):(n.consume(m),o)}function p(m){return n.exit("codeIndented"),r(m)}}function Ce(n,r,t){let e=this;return u;function u(i){return e.parser.lazy[e.now().line]?t(i):S(i)?(n.enter("lineEnding"),n.consume(i),n.exit("lineEnding"),u):C(n,a,"linePrefix",4+1)(i)}function a(i){let o=e.events[e.events.length-1];return o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?r(i):S(i)?u(i):t(i)}}var Gn={name:"codeText",tokenize:Ie,resolve:Ae,previous:ze};function Ae(n){let r=n.length-4,t=3,e,u;if((n[t][1].type==="lineEnding"||n[t][1].type==="space")&&(n[r][1].type==="lineEnding"||n[r][1].type==="space")){for(e=t;++e=4?r(i):n.interrupt(e.parser.constructs.flow,t,r)(i)}}function Rn(n,r,t,e,u,a,i,o,p){let m=p||Number.POSITIVE_INFINITY,c=0;return y;function y(b){return b===60?(n.enter(e),n.enter(u),n.enter(a),n.consume(b),n.exit(a),h):b===null||b===41||In(b)?t(b):(n.enter(e),n.enter(i),n.enter(o),n.enter("chunkString",{contentType:"string"}),L(b))}function h(b){return b===62?(n.enter(a),n.consume(b),n.exit(a),n.exit(u),n.exit(e),r):(n.enter(o),n.enter("chunkString",{contentType:"string"}),x(b))}function x(b){return b===62?(n.exit("chunkString"),n.exit(o),h(b)):b===null||b===60||S(b)?t(b):(n.consume(b),b===92?g:x)}function g(b){return b===60||b===62||b===92?(n.consume(b),x):x(b)}function L(b){return b===40?++c>m?t(b):(n.consume(b),L):b===41?c--?(n.consume(b),L):(n.exit("chunkString"),n.exit(o),n.exit(i),n.exit(e),r(b)):b===null||V(b)?c?t(b):(n.exit("chunkString"),n.exit(o),n.exit(i),n.exit(e),r(b)):In(b)?t(b):(n.consume(b),b===92?O:L)}function O(b){return b===40||b===41||b===92?(n.consume(b),L):L(b)}}function jn(n,r,t,e,u,a){let i=this,o=0,p;return m;function m(x){return n.enter(e),n.enter(u),n.consume(x),n.exit(u),n.enter(a),c}function c(x){return x===null||x===91||x===93&&!p||x===94&&!o&&"_hiddenFootnoteSupport"in i.parser.constructs||o>999?t(x):x===93?(n.exit(a),n.enter(u),n.consume(x),n.exit(u),n.exit(e),r):S(x)?(n.enter("lineEnding"),n.consume(x),n.exit("lineEnding"),c):(n.enter("chunkString",{contentType:"string"}),y(x))}function y(x){return x===null||x===91||x===93||S(x)||o++>999?(n.exit("chunkString"),c(x)):(n.consume(x),p=p||!I(x),x===92?h:y)}function h(x){return x===91||x===92||x===93?(n.consume(x),o++,y):y(x)}}function qn(n,r,t,e,u,a){let i;return o;function o(h){return n.enter(e),n.enter(u),n.consume(h),n.exit(u),i=h===40?41:h,p}function p(h){return h===i?(n.enter(u),n.consume(h),n.exit(u),n.exit(e),r):(n.enter(a),m(h))}function m(h){return h===i?(n.exit(a),p(i)):h===null?t(h):S(h)?(n.enter("lineEnding"),n.consume(h),n.exit("lineEnding"),C(n,m,"linePrefix")):(n.enter("chunkString",{contentType:"string"}),c(h))}function c(h){return h===i||h===null||S(h)?(n.exit("chunkString"),m(h)):(n.consume(h),h===92?y:c)}function y(h){return h===i||h===92?(n.consume(h),c):c(h)}}function fn(n,r){let t;return e;function e(u){return S(u)?(n.enter("lineEnding"),n.consume(u),n.exit("lineEnding"),t=!0,e):I(u)?C(n,e,t?"linePrefix":"lineSuffix")(u):r(u)}}function on(n){return n.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}var Kn={name:"definition",tokenize:_e},Pe={tokenize:Me,partial:!0};function _e(n,r,t){let e=this,u;return a;function a(p){return n.enter("definition"),jn.call(e,n,i,t,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function i(p){return u=on(e.sliceSerialize(e.events[e.events.length-1][1]).slice(1,-1)),p===58?(n.enter("definitionMarker"),n.consume(p),n.exit("definitionMarker"),fn(n,Rn(n,n.attempt(Pe,C(n,o,"whitespace"),C(n,o,"whitespace")),t,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString"))):t(p)}function o(p){return p===null||S(p)?(n.exit("definition"),e.parser.defined.includes(u)||e.parser.defined.push(u),r(p)):t(p)}}function Me(n,r,t){return e;function e(i){return V(i)?fn(n,u)(i):t(i)}function u(i){return i===34||i===39||i===40?qn(n,C(n,a,"whitespace"),t,"definitionTitle","definitionTitleMarker","definitionTitleString")(i):t(i)}function a(i){return i===null||S(i)?r(i):t(i)}}var Xn={name:"hardBreakEscape",tokenize:Re};function Re(n,r,t){return e;function e(a){return n.enter("hardBreakEscape"),n.enter("escapeMarker"),n.consume(a),u}function u(a){return S(a)?(n.exit("escapeMarker"),n.exit("hardBreakEscape"),r(a)):t(a)}}var vn={name:"headingAtx",tokenize:qe,resolve:je};function je(n,r){let t=n.length-2,e=3,u,a;return n[e][1].type==="whitespace"&&(e+=2),t-2>e&&n[t][1].type==="whitespace"&&(t-=2),n[t][1].type==="atxHeadingSequence"&&(e===t-1||t-4>e&&n[t-2][1].type==="whitespace")&&(t-=e+1===t?2:4),t>e&&(u={type:"atxHeadingText",start:n[e][1].start,end:n[t][1].end},a={type:"chunkText",start:n[e][1].start,end:n[t][1].end,contentType:"text"},Z(n,e,t-e+1,[["enter",u,r],["enter",a,r],["exit",a,r],["exit",u,r]])),n}function qe(n,r,t){let e=this,u=0;return a;function a(c){return n.enter("atxHeading"),n.enter("atxHeadingSequence"),i(c)}function i(c){return c===35&&u++<6?(n.consume(c),i):c===null||V(c)?(n.exit("atxHeadingSequence"),e.interrupt?r(c):o(c)):t(c)}function o(c){return c===35?(n.enter("atxHeadingSequence"),p(c)):c===null||S(c)?(n.exit("atxHeading"),r(c)):I(c)?C(n,o,"whitespace")(c):(n.enter("atxHeadingText"),m(c))}function p(c){return c===35?(n.consume(c),p):(n.exit("atxHeadingSequence"),o(c))}function m(c){return c===null||c===35||V(c)?(n.exit("atxHeadingText"),o(c)):(n.consume(c),m)}}var Ot=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],nt=["pre","script","style","textarea"];var tt={name:"htmlFlow",tokenize:Ve,resolveTo:Ne,concrete:!0},He={tokenize:We,partial:!0};function Ne(n){let r=n.length;for(;r--&&!(n[r][0]==="enter"&&n[r][1].type==="htmlFlow"););return r>1&&n[r-2][1].type==="linePrefix"&&(n[r][1].start=n[r-2][1].start,n[r+1][1].start=n[r-2][1].start,n.splice(r-2,2)),n}function Ve(n,r,t){let e=this,u,a,i,o,p;return m;function m(l){return n.enter("htmlFlow"),n.enter("htmlFlowData"),n.consume(l),c}function c(l){return l===33?(n.consume(l),y):l===47?(n.consume(l),g):l===63?(n.consume(l),u=3,e.interrupt?r:G):v(l)?(n.consume(l),i=String.fromCharCode(l),a=!0,L):t(l)}function y(l){return l===45?(n.consume(l),u=2,h):l===91?(n.consume(l),u=5,i="CDATA[",o=0,x):v(l)?(n.consume(l),u=4,e.interrupt?r:G):t(l)}function h(l){return l===45?(n.consume(l),e.interrupt?r:G):t(l)}function x(l){return l===i.charCodeAt(o++)?(n.consume(l),o===i.length?e.interrupt?r:A:x):t(l)}function g(l){return v(l)?(n.consume(l),i=String.fromCharCode(l),L):t(l)}function L(l){return l===null||l===47||l===62||V(l)?l!==47&&a&&nt.includes(i.toLowerCase())?(u=1,e.interrupt?r(l):A(l)):Ot.includes(i.toLowerCase())?(u=6,l===47?(n.consume(l),O):e.interrupt?r(l):A(l)):(u=7,e.interrupt&&!e.parser.lazy[e.now().line]?t(l):a?R(l):b(l)):l===45||K(l)?(n.consume(l),i+=String.fromCharCode(l),L):t(l)}function O(l){return l===62?(n.consume(l),e.interrupt?r:A):t(l)}function b(l){return I(l)?(n.consume(l),b):M(l)}function R(l){return l===47?(n.consume(l),M):l===58||l===95||v(l)?(n.consume(l),w):I(l)?(n.consume(l),R):M(l)}function w(l){return l===45||l===46||l===58||l===95||K(l)?(n.consume(l),w):P(l)}function P(l){return l===61?(n.consume(l),_):I(l)?(n.consume(l),P):R(l)}function _(l){return l===null||l===60||l===61||l===62||l===96?t(l):l===34||l===39?(n.consume(l),p=l,d):I(l)?(n.consume(l),_):(p=null,j(l))}function d(l){return l===null||S(l)?t(l):l===p?(n.consume(l),H):(n.consume(l),d)}function j(l){return l===null||l===34||l===39||l===60||l===61||l===62||l===96||V(l)?P(l):(n.consume(l),j)}function H(l){return l===47||l===62||I(l)?R(l):t(l)}function M(l){return l===62?(n.consume(l),Q):t(l)}function Q(l){return I(l)?(n.consume(l),Q):l===null||S(l)?A(l):t(l)}function A(l){return l===45&&u===2?(n.consume(l),U):l===60&&u===1?(n.consume(l),X):l===62&&u===4?(n.consume(l),N):l===63&&u===3?(n.consume(l),G):l===93&&u===5?(n.consume(l),W):S(l)&&(u===6||u===7)?n.check(He,N,D)(l):l===null||S(l)?D(l):(n.consume(l),A)}function D(l){return n.exit("htmlFlowData"),E(l)}function E(l){return l===null?s(l):S(l)?n.attempt({tokenize:z,partial:!0},E,s)(l):(n.enter("htmlFlowData"),A(l))}function z(l,En,mn){return dn;function dn(en){return l.enter("lineEnding"),l.consume(en),l.exit("lineEnding"),wn}function wn(en){return e.parser.lazy[e.now().line]?mn(en):En(en)}}function U(l){return l===45?(n.consume(l),G):A(l)}function X(l){return l===47?(n.consume(l),i="",nn):A(l)}function nn(l){return l===62&&nt.includes(i.toLowerCase())?(n.consume(l),N):v(l)&&i.length<8?(n.consume(l),i+=String.fromCharCode(l),nn):A(l)}function W(l){return l===93?(n.consume(l),G):A(l)}function G(l){return l===62?(n.consume(l),N):l===45&&u===2?(n.consume(l),G):A(l)}function N(l){return l===null||S(l)?(n.exit("htmlFlowData"),s(l)):(n.consume(l),N)}function s(l){return n.exit("htmlFlow"),r(l)}}function We(n,r,t){return e;function e(u){return n.exit("htmlFlowData"),n.enter("lineEndingBlank"),n.consume(u),n.exit("lineEndingBlank"),n.attempt(cn,r,t)}}var et={name:"htmlText",tokenize:Qe};function Qe(n,r,t){let e=this,u,a,i,o;return p;function p(s){return n.enter("htmlText"),n.enter("htmlTextData"),n.consume(s),m}function m(s){return s===33?(n.consume(s),c):s===47?(n.consume(s),j):s===63?(n.consume(s),_):v(s)?(n.consume(s),Q):t(s)}function c(s){return s===45?(n.consume(s),y):s===91?(n.consume(s),a="CDATA[",i=0,O):v(s)?(n.consume(s),P):t(s)}function y(s){return s===45?(n.consume(s),h):t(s)}function h(s){return s===null||s===62?t(s):s===45?(n.consume(s),x):g(s)}function x(s){return s===null||s===62?t(s):g(s)}function g(s){return s===null?t(s):s===45?(n.consume(s),L):S(s)?(o=g,W(s)):(n.consume(s),g)}function L(s){return s===45?(n.consume(s),N):g(s)}function O(s){return s===a.charCodeAt(i++)?(n.consume(s),i===a.length?b:O):t(s)}function b(s){return s===null?t(s):s===93?(n.consume(s),R):S(s)?(o=b,W(s)):(n.consume(s),b)}function R(s){return s===93?(n.consume(s),w):b(s)}function w(s){return s===62?N(s):s===93?(n.consume(s),w):b(s)}function P(s){return s===null||s===62?N(s):S(s)?(o=P,W(s)):(n.consume(s),P)}function _(s){return s===null?t(s):s===63?(n.consume(s),d):S(s)?(o=_,W(s)):(n.consume(s),_)}function d(s){return s===62?N(s):_(s)}function j(s){return v(s)?(n.consume(s),H):t(s)}function H(s){return s===45||K(s)?(n.consume(s),H):M(s)}function M(s){return S(s)?(o=M,W(s)):I(s)?(n.consume(s),M):N(s)}function Q(s){return s===45||K(s)?(n.consume(s),Q):s===47||s===62||V(s)?A(s):t(s)}function A(s){return s===47?(n.consume(s),N):s===58||s===95||v(s)?(n.consume(s),D):S(s)?(o=A,W(s)):I(s)?(n.consume(s),A):N(s)}function D(s){return s===45||s===46||s===58||s===95||K(s)?(n.consume(s),D):E(s)}function E(s){return s===61?(n.consume(s),z):S(s)?(o=E,W(s)):I(s)?(n.consume(s),E):A(s)}function z(s){return s===null||s===60||s===61||s===62||s===96?t(s):s===34||s===39?(n.consume(s),u=s,U):S(s)?(o=z,W(s)):I(s)?(n.consume(s),z):(n.consume(s),u=void 0,nn)}function U(s){return s===u?(n.consume(s),X):s===null?t(s):S(s)?(o=U,W(s)):(n.consume(s),U)}function X(s){return s===62||s===47||V(s)?A(s):t(s)}function nn(s){return s===null||s===34||s===39||s===60||s===61||s===96?t(s):s===62||V(s)?A(s):(n.consume(s),nn)}function W(s){return n.exit("htmlTextData"),n.enter("lineEnding"),n.consume(s),n.exit("lineEnding"),C(n,G,"linePrefix",e.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function G(s){return n.enter("htmlTextData"),o(s)}function N(s){return s===62?(n.consume(s),n.exit("htmlTextData"),n.exit("htmlText"),r):t(s)}}var xn={name:"labelEnd",tokenize:Je,resolveTo:Ge,resolveAll:Ye},Ue={tokenize:Ke},$e={tokenize:Xe},Ze={tokenize:ve};function Ye(n){let r=-1,t;for(;++r-1&&(i[0]=i[0].slice(e)),a>0&&i.push(n[u].slice(0,a))),i}function gr(n,r){let t=-1,e=[],u;for(;++tFr,contentInitial:()=>kr,disable:()=>Cr,document:()=>dr,flow:()=>br,flowInitial:()=>yr,insideSpan:()=>wr,string:()=>Sr,text:()=>Er});var dr={42:Y,43:Y,45:Y,48:Y,49:Y,50:Y,51:Y,52:Y,53:Y,54:Y,55:Y,56:Y,57:Y,62:On},kr={91:Kn},yr={[-2]:Ln,[-1]:Ln,32:Ln},br={35:vn,42:gn,45:[Hn,gn],60:tt,61:Hn,95:gn,96:_n,126:_n},Sr={38:Pn,92:Dn},Er={[-5]:Bn,[-4]:Bn,[-3]:Bn,33:rt,38:Pn,42:Tn,60:[Yn,et],91:it,92:[Xn,Dn],93:xn,95:Tn,96:Gn},wr={null:[Tn,Pt]},Fr={null:[42,95]},Cr={null:[]};function Ht(n={}){let r=St([ut].concat(n.extensions||[])),t={defined:[],lazy:{},constructs:r,content:e(zt),document:e(Tt),flow:e(Dt),string:e(_t),text:e(Mt)};return t;function e(u){return a;function a(i){return qt(t,u,i)}}}var Nt=/[\0\t\n\r]/g;function Vt(){let n=1,r="",t=!0,e;return u;function u(a,i,o){let p=[],m,c,y,h,x;for(a=r+a.toString(i),y=0,r="",t&&(a.charCodeAt(0)===65279&&y++,t=void 0);y13&&t<32||t>126&&t<160||t>55295&&t<57344||t>64975&&t<65008||(t&65535)===65535||(t&65535)===65534||t>1114111?"\uFFFD":String.fromCharCode(t)}var Ar=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Qt(n){return n.replace(Ar,zr)}function zr(n,r,t){if(r)return r;if(t.charCodeAt(0)===35){let u=t.charCodeAt(1),a=u===120||u===88;return Nn(t.slice(a?2:1),a?16:10)}return bn(t)||n}function Sn(n){return!n||typeof n!="object"?"":"position"in n||"type"in n?Ut(n.position):"start"in n||"end"in n?Ut(n):"line"in n||"column"in n?at(n):""}function at(n){return $t(n&&n.line)+":"+$t(n&&n.column)}function Ut(n){return at(n&&n.start)+"-"+at(n&&n.end)}function $t(n){return n&&typeof n=="number"?n:1}var Yt={}.hasOwnProperty,Vn=function(n,r,t){return typeof r!="string"&&(t=r,r=void 0),Ir(t)(Wt(Ht(t).document().write(Vt()(n,r,!0))))};function Ir(n){let r={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:o(ht),autolinkProtocol:A,autolinkEmail:A,atxHeading:o(ct),blockQuote:o(kn),characterEscape:A,characterReference:A,codeFenced:o(hn),codeFencedFenceInfo:p,codeFencedFenceMeta:p,codeIndented:o(hn,p),codeText:o(Wn,p),codeTextData:A,data:A,codeFlowValue:A,definition:o(Kt),definitionDestinationString:p,definitionLabelString:p,definitionTitleString:p,emphasis:o(Xt),hardBreakEscape:o(pt),hardBreakTrailing:o(pt),htmlFlow:o(mt,p),htmlFlowData:A,htmlText:o(mt,p),htmlTextData:A,image:o(vt),label:p,link:o(ht),listItem:o(ne),listItemValue:g,listOrdered:o(ft,x),listUnordered:o(ft),paragraph:o(te),reference:dn,referenceString:p,resourceDestinationString:p,resourceTitleString:p,setextHeading:o(ct),strong:o(ee),thematicBreak:o(ie)},exit:{atxHeading:c(),atxHeadingSequence:j,autolink:c(),autolinkEmail:rn,autolinkProtocol:Fn,blockQuote:c(),characterEscapeValue:D,characterReferenceMarkerHexadecimal:en,characterReferenceMarkerNumeric:en,characterReferenceValue:$,codeFenced:c(R),codeFencedFence:b,codeFencedFenceInfo:L,codeFencedFenceMeta:O,codeFlowValue:D,codeIndented:c(w),codeText:c(nn),codeTextData:D,data:D,definition:c(),definitionDestinationString:d,definitionLabelString:P,definitionTitleString:_,emphasis:c(),hardBreakEscape:c(z),hardBreakTrailing:c(z),htmlFlow:c(U),htmlFlowData:D,htmlText:c(X),htmlTextData:D,image:c(G),label:s,labelText:N,lineEnding:E,link:c(W),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:wn,resourceDestinationString:l,resourceTitleString:En,resource:mn,setextHeading:c(Q),setextHeadingLineSequence:M,setextHeadingText:H,strong:c(),thematicBreak:c()}};Gt(r,(n||{}).mdastExtensions||[]);let t={};return e;function e(f){let k={type:"root",children:[]},F={stack:[k],tokenStack:[],config:r,enter:m,exit:y,buffer:p,resume:h,setData:a,getData:i},T=[],B=-1;for(;++B0){let tn=F.tokenStack[F.tokenStack.length-1];(tn[1]||Zt).call(F,void 0,tn[0])}for(k.position={start:pn(f.length>0?f[0][1].start:{line:1,column:1,offset:0}),end:pn(f.length>0?f[f.length-2][1].end:{line:1,column:1,offset:0})},B=-1;++B{c!==0&&(u++,e.push([])),m.split(" ").forEach(y=>{y&&e[u].push({content:y,type:o})})}):(i.type==="strong"||i.type==="emphasis")&&i.children.forEach(p=>{a(p,i.type)})}return t.forEach(i=>{i.type==="paragraph"&&i.children.forEach(o=>{a(o)})}),e}function Or(n){let{children:r}=Vn(n);function t(e){return e.type==="text"?e.value.replace(/\n/g,"
      "):e.type==="strong"?`${e.children.map(t).join("")}`:e.type==="emphasis"?`${e.children.map(t).join("")}`:e.type==="paragraph"?`

      ${e.children.map(t).join("")}

      `:`Unsupported markdown: ${e.type}`}return r.map(t).join("")}function Dr(n){return Intl.Segmenter?[...new Intl.Segmenter().segment(n)].map(r=>r.segment):[...n]}function Pr(n,r){let t=Dr(r.content);return Jt(n,[],t,r.type)}function Jt(n,r,t,e){if(t.length===0)return[{content:r.join(""),type:e},{content:"",type:e}];let[u,...a]=t,i=[...r,u];return n([{content:i.join(""),type:e}])?Jt(n,i,a,e):(r.length===0&&u&&(r.push(u),t.shift()),[{content:r.join(""),type:e},{content:t.join(""),type:e}])}function _r(n,r){if(n.some(({content:t})=>t.includes(` `)))throw new Error("splitLineToFitWidth does not support newlines in the line");return ot(n,r)}function ot(n,r,t=[],e=[]){if(n.length===0)return e.length>0&&t.push(e),t.length>0?t:[];let u="";n[0].content===" "&&(u=" ",n.shift());let a=n.shift()??{content:" ",type:"normal"},i=[...e];if(u!==""&&i.push({content:u,type:"normal"}),i.push(a),r(i))return ot(n,r,t,i);if(e.length>0)t.push(e),n.unshift(a);else if(a.content){let[o,p]=Pr(r,a);t.push([o]),p.content&&n.unshift(p)}return ot(n,r,t)}function Mr(n,r){r&&n.attr("style",r)}function Rr(n,r,t,e,u=!1){let a=n.append("foreignObject"),i=a.append("xhtml:div"),o=r.label,p=r.isNode?"nodeLabel":"edgeLabel";i.html(` "+o+""),Mr(i,r.labelStyle),i.style("display","table-cell"),i.style("white-space","nowrap"),i.style("max-width",t+"px"),i.attr("xmlns","http://www.w3.org/1999/xhtml"),u&&i.attr("class","labelBkg");let m=i.node().getBoundingClientRect();return m.width===t&&(i.style("display","table"),i.style("white-space","break-spaces"),i.style("width",t+"px"),m=i.node().getBoundingClientRect()),a.style("width",m.width),a.style("height",m.height),a.node()}function lt(n,r,t){return n.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",r*t-.1+"em").attr("dy",t+"em")}function jr(n,r,t){let e=n.append("text"),u=lt(e,1,r);st(u,t);let a=u.node().getComputedTextLength();return e.remove(),a}function to(n,r,t){var e;let u=n.append("text"),a=lt(u,1,r);st(a,[{content:t,type:"normal"}]);let i=(e=a.node())==null?void 0:e.getBoundingClientRect();return i&&u.remove(),i}function qr(n,r,t,e=!1){let a=r.append("g"),i=a.insert("rect").attr("class","background"),o=a.append("text").attr("y","-10.1"),p=0;for(let m of t){let c=h=>jr(a,1.1,h)<=n,y=c(m)?[m]:_r(m,c);for(let h of y){let x=lt(o,p,1.1);st(x,h),p++}}if(e){let m=o.node().getBBox(),c=2;return i.attr("x",-c).attr("y",-c).attr("width",m.width+2*c).attr("height",m.height+2*c),a.node()}else return o.node()}function st(n,r){n.text(""),r.forEach((t,e)=>{let u=n.append("tspan").attr("font-style",t.type==="emphasis"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",t.type==="strong"?"bold":"normal");e===0?u.text(t.content):u.text(" "+t.content)})}var eo=(n,r="",{style:t="",isTitle:e=!1,classes:u="",useHtmlLabels:a=!0,isNode:i=!0,width:o=200,addSvgBackground:p=!1}={})=>{if(gt.info("createText",r,t,e,u,a,i,p),a){let m=Or(r),c={isNode:i,label:dt(m).replace(/fa[blrs]?:fa-[\w-]+/g,h=>``),labelStyle:t.replace("fill:","color:")};return Rr(n,c,o,u,p)}else{let m=Br(r);return qr(o,n,m,p)}};export{to as a,eo as b}; -//# sourceMappingURL=chunk-TYUXPGKI.min.js.map +//# sourceMappingURL=chunk-ZMRDHQ6H.min.js.map diff --git a/docs/public/chunk-TYUXPGKI.min.js.map b/docs/public/chunk-ZMRDHQ6H.min.js.map similarity index 99% rename from docs/public/chunk-TYUXPGKI.min.js.map rename to docs/public/chunk-ZMRDHQ6H.min.js.map index 13e07583..8dd99769 100644 --- a/docs/public/chunk-TYUXPGKI.min.js.map +++ b/docs/public/chunk-ZMRDHQ6H.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mdast-util-to-string/lib/index.js", "../../node_modules/micromark-util-chunked/index.js", "../../node_modules/micromark-util-combine-extensions/index.js", "../../node_modules/micromark-util-character/lib/unicode-punctuation-regex.js", "../../node_modules/micromark-util-character/index.js", "../../node_modules/micromark-factory-space/index.js", "../../node_modules/micromark/lib/initialize/content.js", "../../node_modules/micromark/lib/initialize/document.js", "../../node_modules/micromark-util-classify-character/index.js", "../../node_modules/micromark-util-resolve-all/index.js", "../../node_modules/micromark-core-commonmark/lib/attention.js", "../../node_modules/micromark-core-commonmark/lib/autolink.js", "../../node_modules/micromark-core-commonmark/lib/blank-line.js", "../../node_modules/micromark-core-commonmark/lib/block-quote.js", "../../node_modules/micromark-core-commonmark/lib/character-escape.js", "../../node_modules/decode-named-character-reference/index.dom.js", "../../node_modules/micromark-core-commonmark/lib/character-reference.js", "../../node_modules/micromark-core-commonmark/lib/code-fenced.js", "../../node_modules/micromark-core-commonmark/lib/code-indented.js", "../../node_modules/micromark-core-commonmark/lib/code-text.js", "../../node_modules/micromark-util-subtokenize/index.js", "../../node_modules/micromark-core-commonmark/lib/content.js", "../../node_modules/micromark-factory-destination/index.js", "../../node_modules/micromark-factory-label/index.js", "../../node_modules/micromark-factory-title/index.js", "../../node_modules/micromark-factory-whitespace/index.js", "../../node_modules/micromark-util-normalize-identifier/index.js", "../../node_modules/micromark-core-commonmark/lib/definition.js", "../../node_modules/micromark-core-commonmark/lib/hard-break-escape.js", "../../node_modules/micromark-core-commonmark/lib/heading-atx.js", "../../node_modules/micromark-util-html-tag-name/index.js", "../../node_modules/micromark-core-commonmark/lib/html-flow.js", "../../node_modules/micromark-core-commonmark/lib/html-text.js", "../../node_modules/micromark-core-commonmark/lib/label-end.js", "../../node_modules/micromark-core-commonmark/lib/label-start-image.js", "../../node_modules/micromark-core-commonmark/lib/label-start-link.js", "../../node_modules/micromark-core-commonmark/lib/line-ending.js", "../../node_modules/micromark-core-commonmark/lib/thematic-break.js", "../../node_modules/micromark-core-commonmark/lib/list.js", "../../node_modules/micromark-core-commonmark/lib/setext-underline.js", "../../node_modules/micromark/lib/initialize/flow.js", "../../node_modules/micromark/lib/initialize/text.js", "../../node_modules/micromark/lib/create-tokenizer.js", "../../node_modules/micromark/lib/constructs.js", "../../node_modules/micromark/lib/parse.js", "../../node_modules/micromark/lib/preprocess.js", "../../node_modules/micromark/lib/postprocess.js", "../../node_modules/micromark-util-decode-numeric-character-reference/index.js", "../../node_modules/micromark-util-decode-string/index.js", "../../node_modules/unist-util-stringify-position/lib/index.js", "../../node_modules/mdast-util-from-markdown/lib/index.js", "../../node_modules/mermaid/dist/createText-62fc7601.js"], - "sourcesContent": ["/**\n * @typedef {import('mdast').Root|import('mdast').Content} Node\n *\n * @typedef Options\n * Configuration (optional).\n * @property {boolean | null | undefined} [includeImageAlt=true]\n * Whether to use `alt` for `image`s.\n * @property {boolean | null | undefined} [includeHtml=true]\n * Whether to use `value` of HTML.\n */\n\n/** @type {Options} */\nconst emptyOptions = {}\n\n/**\n * Get the text content of a node or list of nodes.\n *\n * Prefers the node\u2019s plain-text fields, otherwise serializes its children,\n * and if the given value is an array, serialize the nodes in it.\n *\n * @param {unknown} value\n * Thing to serialize, typically `Node`.\n * @param {Options | null | undefined} [options]\n * Configuration (optional).\n * @returns {string}\n * Serialized `value`.\n */\nexport function toString(value, options) {\n const settings = options || emptyOptions\n const includeImageAlt =\n typeof settings.includeImageAlt === 'boolean'\n ? settings.includeImageAlt\n : true\n const includeHtml =\n typeof settings.includeHtml === 'boolean' ? settings.includeHtml : true\n\n return one(value, includeImageAlt, includeHtml)\n}\n\n/**\n * One node or several nodes.\n *\n * @param {unknown} value\n * Thing to serialize.\n * @param {boolean} includeImageAlt\n * Include image `alt`s.\n * @param {boolean} includeHtml\n * Include HTML.\n * @returns {string}\n * Serialized node.\n */\nfunction one(value, includeImageAlt, includeHtml) {\n if (node(value)) {\n if ('value' in value) {\n return value.type === 'html' && !includeHtml ? '' : value.value\n }\n\n if (includeImageAlt && 'alt' in value && value.alt) {\n return value.alt\n }\n\n if ('children' in value) {\n return all(value.children, includeImageAlt, includeHtml)\n }\n }\n\n if (Array.isArray(value)) {\n return all(value, includeImageAlt, includeHtml)\n }\n\n return ''\n}\n\n/**\n * Serialize a list of nodes.\n *\n * @param {Array} values\n * Thing to serialize.\n * @param {boolean} includeImageAlt\n * Include image `alt`s.\n * @param {boolean} includeHtml\n * Include HTML.\n * @returns {string}\n * Serialized nodes.\n */\nfunction all(values, includeImageAlt, includeHtml) {\n /** @type {Array} */\n const result = []\n let index = -1\n\n while (++index < values.length) {\n result[index] = one(values[index], includeImageAlt, includeHtml)\n }\n\n return result.join('')\n}\n\n/**\n * Check if `value` looks like a node.\n *\n * @param {unknown} value\n * Thing.\n * @returns {value is Node}\n * Whether `value` is a node.\n */\nfunction node(value) {\n return Boolean(value && typeof value === 'object')\n}\n", "/**\n * Like `Array#splice`, but smarter for giant arrays.\n *\n * `Array#splice` takes all items to be inserted as individual argument which\n * causes a stack overflow in V8 when trying to insert 100k items for instance.\n *\n * Otherwise, this does not return the removed items, and takes `items` as an\n * array instead of rest parameters.\n *\n * @template {unknown} T\n * @param {T[]} list\n * @param {number} start\n * @param {number} remove\n * @param {T[]} items\n * @returns {void}\n */\nexport function splice(list, start, remove, items) {\n const end = list.length\n let chunkStart = 0\n /** @type {unknown[]} */\n\n let parameters // Make start between zero and `end` (included).\n\n if (start < 0) {\n start = -start > end ? 0 : end + start\n } else {\n start = start > end ? end : start\n }\n\n remove = remove > 0 ? remove : 0 // No need to chunk the items if there\u2019s only a couple (10k) items.\n\n if (items.length < 10000) {\n parameters = Array.from(items)\n parameters.unshift(start, remove) // @ts-expect-error Hush, it\u2019s fine.\n ;[].splice.apply(list, parameters)\n } else {\n // Delete `remove` items starting from `start`\n if (remove) [].splice.apply(list, [start, remove]) // Insert the items in chunks to not cause stack overflows.\n\n while (chunkStart < items.length) {\n parameters = items.slice(chunkStart, chunkStart + 10000)\n parameters.unshift(start, 0) // @ts-expect-error Hush, it\u2019s fine.\n ;[].splice.apply(list, parameters)\n chunkStart += 10000\n start += 10000\n }\n }\n}\n/**\n * Append `items` (an array) at the end of `list` (another array).\n * When `list` was empty, returns `items` instead.\n *\n * This prevents a potentially expensive operation when `list` is empty,\n * and adds items in batches to prevent V8 from hanging.\n *\n * @template {unknown} T\n * @param {T[]} list\n * @param {T[]} items\n * @returns {T[]}\n */\n\nexport function push(list, items) {\n if (list.length > 0) {\n splice(list, list.length, 0, items)\n return list\n }\n\n return items\n}\n", "/**\n * @typedef {import('micromark-util-types').NormalizedExtension} NormalizedExtension\n * @typedef {import('micromark-util-types').Extension} Extension\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').HtmlExtension} HtmlExtension\n */\n\nimport {splice} from 'micromark-util-chunked'\n\nconst hasOwnProperty = {}.hasOwnProperty\n\n/**\n * Combine several syntax extensions into one.\n *\n * @param {Extension[]} extensions List of syntax extensions.\n * @returns {NormalizedExtension} A single combined extension.\n */\nexport function combineExtensions(extensions) {\n /** @type {NormalizedExtension} */\n const all = {}\n let index = -1\n\n while (++index < extensions.length) {\n syntaxExtension(all, extensions[index])\n }\n\n return all\n}\n\n/**\n * Merge `extension` into `all`.\n *\n * @param {NormalizedExtension} all Extension to merge into.\n * @param {Extension} extension Extension to merge.\n * @returns {void}\n */\nfunction syntaxExtension(all, extension) {\n /** @type {string} */\n let hook\n\n for (hook in extension) {\n const maybe = hasOwnProperty.call(all, hook) ? all[hook] : undefined\n const left = maybe || (all[hook] = {})\n const right = extension[hook]\n /** @type {string} */\n let code\n\n for (code in right) {\n if (!hasOwnProperty.call(left, code)) left[code] = []\n const value = right[code]\n constructs(\n // @ts-expect-error Looks like a list.\n left[code],\n Array.isArray(value) ? value : value ? [value] : []\n )\n }\n }\n}\n\n/**\n * Merge `list` into `existing` (both lists of constructs).\n * Mutates `existing`.\n *\n * @param {unknown[]} existing\n * @param {unknown[]} list\n * @returns {void}\n */\nfunction constructs(existing, list) {\n let index = -1\n /** @type {unknown[]} */\n const before = []\n\n while (++index < list.length) {\n // @ts-expect-error Looks like an object.\n ;(list[index].add === 'after' ? existing : before).push(list[index])\n }\n\n splice(existing, 0, 0, before)\n}\n\n/**\n * Combine several HTML extensions into one.\n *\n * @param {HtmlExtension[]} htmlExtensions List of HTML extensions.\n * @returns {HtmlExtension} A single combined extension.\n */\nexport function combineHtmlExtensions(htmlExtensions) {\n /** @type {HtmlExtension} */\n const handlers = {}\n let index = -1\n\n while (++index < htmlExtensions.length) {\n htmlExtension(handlers, htmlExtensions[index])\n }\n\n return handlers\n}\n\n/**\n * Merge `extension` into `all`.\n *\n * @param {HtmlExtension} all Extension to merge into.\n * @param {HtmlExtension} extension Extension to merge.\n * @returns {void}\n */\nfunction htmlExtension(all, extension) {\n /** @type {string} */\n let hook\n\n for (hook in extension) {\n const maybe = hasOwnProperty.call(all, hook) ? all[hook] : undefined\n const left = maybe || (all[hook] = {})\n const right = extension[hook]\n /** @type {string} */\n let type\n\n if (right) {\n for (type in right) {\n left[type] = right[type]\n }\n }\n }\n}\n", "// This module is generated by `script/`.\n//\n// CommonMark handles attention (emphasis, strong) markers based on what comes\n// before or after them.\n// One such difference is if those characters are Unicode punctuation.\n// This script is generated from the Unicode data.\nexport const unicodePunctuationRegex =\n /[!-/:-@[-`{-~\\u00A1\\u00A7\\u00AB\\u00B6\\u00B7\\u00BB\\u00BF\\u037E\\u0387\\u055A-\\u055F\\u0589\\u058A\\u05BE\\u05C0\\u05C3\\u05C6\\u05F3\\u05F4\\u0609\\u060A\\u060C\\u060D\\u061B\\u061E\\u061F\\u066A-\\u066D\\u06D4\\u0700-\\u070D\\u07F7-\\u07F9\\u0830-\\u083E\\u085E\\u0964\\u0965\\u0970\\u09FD\\u0A76\\u0AF0\\u0C77\\u0C84\\u0DF4\\u0E4F\\u0E5A\\u0E5B\\u0F04-\\u0F12\\u0F14\\u0F3A-\\u0F3D\\u0F85\\u0FD0-\\u0FD4\\u0FD9\\u0FDA\\u104A-\\u104F\\u10FB\\u1360-\\u1368\\u1400\\u166E\\u169B\\u169C\\u16EB-\\u16ED\\u1735\\u1736\\u17D4-\\u17D6\\u17D8-\\u17DA\\u1800-\\u180A\\u1944\\u1945\\u1A1E\\u1A1F\\u1AA0-\\u1AA6\\u1AA8-\\u1AAD\\u1B5A-\\u1B60\\u1BFC-\\u1BFF\\u1C3B-\\u1C3F\\u1C7E\\u1C7F\\u1CC0-\\u1CC7\\u1CD3\\u2010-\\u2027\\u2030-\\u2043\\u2045-\\u2051\\u2053-\\u205E\\u207D\\u207E\\u208D\\u208E\\u2308-\\u230B\\u2329\\u232A\\u2768-\\u2775\\u27C5\\u27C6\\u27E6-\\u27EF\\u2983-\\u2998\\u29D8-\\u29DB\\u29FC\\u29FD\\u2CF9-\\u2CFC\\u2CFE\\u2CFF\\u2D70\\u2E00-\\u2E2E\\u2E30-\\u2E4F\\u2E52\\u3001-\\u3003\\u3008-\\u3011\\u3014-\\u301F\\u3030\\u303D\\u30A0\\u30FB\\uA4FE\\uA4FF\\uA60D-\\uA60F\\uA673\\uA67E\\uA6F2-\\uA6F7\\uA874-\\uA877\\uA8CE\\uA8CF\\uA8F8-\\uA8FA\\uA8FC\\uA92E\\uA92F\\uA95F\\uA9C1-\\uA9CD\\uA9DE\\uA9DF\\uAA5C-\\uAA5F\\uAADE\\uAADF\\uAAF0\\uAAF1\\uABEB\\uFD3E\\uFD3F\\uFE10-\\uFE19\\uFE30-\\uFE52\\uFE54-\\uFE61\\uFE63\\uFE68\\uFE6A\\uFE6B\\uFF01-\\uFF03\\uFF05-\\uFF0A\\uFF0C-\\uFF0F\\uFF1A\\uFF1B\\uFF1F\\uFF20\\uFF3B-\\uFF3D\\uFF3F\\uFF5B\\uFF5D\\uFF5F-\\uFF65]/\n", "/**\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {unicodePunctuationRegex} from './lib/unicode-punctuation-regex.js'\n/**\n * Check whether the character code represents an ASCII alpha (`a` through `z`,\n * case insensitive).\n *\n * An **ASCII alpha** is an ASCII upper alpha or ASCII lower alpha.\n *\n * An **ASCII upper alpha** is a character in the inclusive range U+0041 (`A`)\n * to U+005A (`Z`).\n *\n * An **ASCII lower alpha** is a character in the inclusive range U+0061 (`a`)\n * to U+007A (`z`).\n */\n\nexport const asciiAlpha = regexCheck(/[A-Za-z]/)\n/**\n * Check whether the character code represents an ASCII digit (`0` through `9`).\n *\n * An **ASCII digit** is a character in the inclusive range U+0030 (`0`) to\n * U+0039 (`9`).\n */\n\nexport const asciiDigit = regexCheck(/\\d/)\n/**\n * Check whether the character code represents an ASCII hex digit (`a` through\n * `f`, case insensitive, or `0` through `9`).\n *\n * An **ASCII hex digit** is an ASCII digit (see `asciiDigit`), ASCII upper hex\n * digit, or an ASCII lower hex digit.\n *\n * An **ASCII upper hex digit** is a character in the inclusive range U+0041\n * (`A`) to U+0046 (`F`).\n *\n * An **ASCII lower hex digit** is a character in the inclusive range U+0061\n * (`a`) to U+0066 (`f`).\n */\n\nexport const asciiHexDigit = regexCheck(/[\\dA-Fa-f]/)\n/**\n * Check whether the character code represents an ASCII alphanumeric (`a`\n * through `z`, case insensitive, or `0` through `9`).\n *\n * An **ASCII alphanumeric** is an ASCII digit (see `asciiDigit`) or ASCII alpha\n * (see `asciiAlpha`).\n */\n\nexport const asciiAlphanumeric = regexCheck(/[\\dA-Za-z]/)\n/**\n * Check whether the character code represents ASCII punctuation.\n *\n * An **ASCII punctuation** is a character in the inclusive ranges U+0021\n * EXCLAMATION MARK (`!`) to U+002F SLASH (`/`), U+003A COLON (`:`) to U+0040 AT\n * SIGN (`@`), U+005B LEFT SQUARE BRACKET (`[`) to U+0060 GRAVE ACCENT\n * (`` ` ``), or U+007B LEFT CURLY BRACE (`{`) to U+007E TILDE (`~`).\n */\n\nexport const asciiPunctuation = regexCheck(/[!-/:-@[-`{-~]/)\n/**\n * Check whether the character code represents an ASCII atext.\n *\n * atext is an ASCII alphanumeric (see `asciiAlphanumeric`), or a character in\n * the inclusive ranges U+0023 NUMBER SIGN (`#`) to U+0027 APOSTROPHE (`'`),\n * U+002A ASTERISK (`*`), U+002B PLUS SIGN (`+`), U+002D DASH (`-`), U+002F\n * SLASH (`/`), U+003D EQUALS TO (`=`), U+003F QUESTION MARK (`?`), U+005E\n * CARET (`^`) to U+0060 GRAVE ACCENT (`` ` ``), or U+007B LEFT CURLY BRACE\n * (`{`) to U+007E TILDE (`~`).\n *\n * See:\n * **\\[RFC5322]**:\n * [Internet Message Format](https://tools.ietf.org/html/rfc5322).\n * P. Resnick.\n * IETF.\n */\n\nexport const asciiAtext = regexCheck(/[#-'*+\\--9=?A-Z^-~]/)\n/**\n * Check whether a character code is an ASCII control character.\n *\n * An **ASCII control** is a character in the inclusive range U+0000 NULL (NUL)\n * to U+001F (US), or U+007F (DEL).\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function asciiControl(code) {\n return (\n // Special whitespace codes (which have negative values), C0 and Control\n // character DEL\n code !== null && (code < 32 || code === 127)\n )\n}\n/**\n * Check whether a character code is a markdown line ending (see\n * `markdownLineEnding`) or markdown space (see `markdownSpace`).\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function markdownLineEndingOrSpace(code) {\n return code !== null && (code < 0 || code === 32)\n}\n/**\n * Check whether a character code is a markdown line ending.\n *\n * A **markdown line ending** is the virtual characters M-0003 CARRIAGE RETURN\n * LINE FEED (CRLF), M-0004 LINE FEED (LF) and M-0005 CARRIAGE RETURN (CR).\n *\n * In micromark, the actual character U+000A LINE FEED (LF) and U+000D CARRIAGE\n * RETURN (CR) are replaced by these virtual characters depending on whether\n * they occurred together.\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function markdownLineEnding(code) {\n return code !== null && code < -2\n}\n/**\n * Check whether a character code is a markdown space.\n *\n * A **markdown space** is the concrete character U+0020 SPACE (SP) and the\n * virtual characters M-0001 VIRTUAL SPACE (VS) and M-0002 HORIZONTAL TAB (HT).\n *\n * In micromark, the actual character U+0009 CHARACTER TABULATION (HT) is\n * replaced by one M-0002 HORIZONTAL TAB (HT) and between 0 and 3 M-0001 VIRTUAL\n * SPACE (VS) characters, depending on the column at which the tab occurred.\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function markdownSpace(code) {\n return code === -2 || code === -1 || code === 32\n}\n/**\n * Check whether the character code represents Unicode whitespace.\n *\n * Note that this does handle micromark specific markdown whitespace characters.\n * See `markdownLineEndingOrSpace` to check that.\n *\n * A **Unicode whitespace** is a character in the Unicode `Zs` (Separator,\n * Space) category, or U+0009 CHARACTER TABULATION (HT), U+000A LINE FEED (LF),\n * U+000C (FF), or U+000D CARRIAGE RETURN (CR) (**\\[UNICODE]**).\n *\n * See:\n * **\\[UNICODE]**:\n * [The Unicode Standard](https://www.unicode.org/versions/).\n * Unicode Consortium.\n */\n\nexport const unicodeWhitespace = regexCheck(/\\s/)\n/**\n * Check whether the character code represents Unicode punctuation.\n *\n * A **Unicode punctuation** is a character in the Unicode `Pc` (Punctuation,\n * Connector), `Pd` (Punctuation, Dash), `Pe` (Punctuation, Close), `Pf`\n * (Punctuation, Final quote), `Pi` (Punctuation, Initial quote), `Po`\n * (Punctuation, Other), or `Ps` (Punctuation, Open) categories, or an ASCII\n * punctuation (see `asciiPunctuation`).\n *\n * See:\n * **\\[UNICODE]**:\n * [The Unicode Standard](https://www.unicode.org/versions/).\n * Unicode Consortium.\n */\n// Size note: removing ASCII from the regex and using `asciiPunctuation` here\n// In fact adds to the bundle size.\n\nexport const unicodePunctuation = regexCheck(unicodePunctuationRegex)\n/**\n * Create a code check from a regex.\n *\n * @param {RegExp} regex\n * @returns {(code: Code) => code is number}\n */\n\nfunction regexCheck(regex) {\n return check\n /**\n * Check whether a code matches the bound regex.\n *\n * @param {Code} code Character code\n * @returns {code is number} Whether the character code matches the bound regex\n */\n\n function check(code) {\n return code !== null && regex.test(String.fromCharCode(code))\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownSpace} from 'micromark-util-character'\n/**\n * @param {Effects} effects\n * @param {State} ok\n * @param {string} type\n * @param {number} [max=Infinity]\n * @returns {State}\n */\n\nexport function factorySpace(effects, ok, type, max) {\n const limit = max ? max - 1 : Number.POSITIVE_INFINITY\n let size = 0\n return start\n /** @type {State} */\n\n function start(code) {\n if (markdownSpace(code)) {\n effects.enter(type)\n return prefix(code)\n }\n\n return ok(code)\n }\n /** @type {State} */\n\n function prefix(code) {\n if (markdownSpace(code) && size++ < limit) {\n effects.consume(code)\n return prefix\n }\n\n effects.exit(type)\n return ok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {InitialConstruct} */\nexport const content = {\n tokenize: initializeContent\n}\n/** @type {Initializer} */\n\nfunction initializeContent(effects) {\n const contentStart = effects.attempt(\n this.parser.constructs.contentInitial,\n afterContentStartConstruct,\n paragraphInitial\n )\n /** @type {Token} */\n\n let previous\n return contentStart\n /** @type {State} */\n\n function afterContentStartConstruct(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, contentStart, 'linePrefix')\n }\n /** @type {State} */\n\n function paragraphInitial(code) {\n effects.enter('paragraph')\n return lineStart(code)\n }\n /** @type {State} */\n\n function lineStart(code) {\n const token = effects.enter('chunkText', {\n contentType: 'text',\n previous\n })\n\n if (previous) {\n previous.next = token\n }\n\n previous = token\n return data(code)\n }\n /** @type {State} */\n\n function data(code) {\n if (code === null) {\n effects.exit('chunkText')\n effects.exit('paragraph')\n effects.consume(code)\n return\n }\n\n if (markdownLineEnding(code)) {\n effects.consume(code)\n effects.exit('chunkText')\n return lineStart\n } // Data.\n\n effects.consume(code)\n return data\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Point} Point\n */\n\n/**\n * @typedef {Record} StackState\n * @typedef {[Construct, StackState]} StackItem\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\nimport {splice} from 'micromark-util-chunked'\n/** @type {InitialConstruct} */\n\nexport const document = {\n tokenize: initializeDocument\n}\n/** @type {Construct} */\n\nconst containerConstruct = {\n tokenize: tokenizeContainer\n}\n/** @type {Initializer} */\n\nfunction initializeDocument(effects) {\n const self = this\n /** @type {Array} */\n\n const stack = []\n let continued = 0\n /** @type {TokenizeContext|undefined} */\n\n let childFlow\n /** @type {Token|undefined} */\n\n let childToken\n /** @type {number} */\n\n let lineStartOffset\n return start\n /** @type {State} */\n\n function start(code) {\n // First we iterate through the open blocks, starting with the root\n // document, and descending through last children down to the last open\n // block.\n // Each block imposes a condition that the line must satisfy if the block is\n // to remain open.\n // For example, a block quote requires a `>` character.\n // A paragraph requires a non-blank line.\n // In this phase we may match all or just some of the open blocks.\n // But we cannot close unmatched blocks yet, because we may have a lazy\n // continuation line.\n if (continued < stack.length) {\n const item = stack[continued]\n self.containerState = item[1]\n return effects.attempt(\n item[0].continuation,\n documentContinue,\n checkNewContainers\n )(code)\n } // Done.\n\n return checkNewContainers(code)\n }\n /** @type {State} */\n\n function documentContinue(code) {\n continued++ // Note: this field is called `_closeFlow` but it also closes containers.\n // Perhaps a good idea to rename it but it\u2019s already used in the wild by\n // extensions.\n\n if (self.containerState._closeFlow) {\n self.containerState._closeFlow = undefined\n\n if (childFlow) {\n closeFlow()\n } // Note: this algorithm for moving events around is similar to the\n // algorithm when dealing with lazy lines in `writeToChild`.\n\n const indexBeforeExits = self.events.length\n let indexBeforeFlow = indexBeforeExits\n /** @type {Point|undefined} */\n\n let point // Find the flow chunk.\n\n while (indexBeforeFlow--) {\n if (\n self.events[indexBeforeFlow][0] === 'exit' &&\n self.events[indexBeforeFlow][1].type === 'chunkFlow'\n ) {\n point = self.events[indexBeforeFlow][1].end\n break\n }\n }\n\n exitContainers(continued) // Fix positions.\n\n let index = indexBeforeExits\n\n while (index < self.events.length) {\n self.events[index][1].end = Object.assign({}, point)\n index++\n } // Inject the exits earlier (they\u2019re still also at the end).\n\n splice(\n self.events,\n indexBeforeFlow + 1,\n 0,\n self.events.slice(indexBeforeExits)\n ) // Discard the duplicate exits.\n\n self.events.length = index\n return checkNewContainers(code)\n }\n\n return start(code)\n }\n /** @type {State} */\n\n function checkNewContainers(code) {\n // Next, after consuming the continuation markers for existing blocks, we\n // look for new block starts (e.g. `>` for a block quote).\n // If we encounter a new block start, we close any blocks unmatched in\n // step 1 before creating the new block as a child of the last matched\n // block.\n if (continued === stack.length) {\n // No need to `check` whether there\u2019s a container, of `exitContainers`\n // would be moot.\n // We can instead immediately `attempt` to parse one.\n if (!childFlow) {\n return documentContinued(code)\n } // If we have concrete content, such as block HTML or fenced code,\n // we can\u2019t have containers \u201Cpierce\u201D into them, so we can immediately\n // start.\n\n if (childFlow.currentConstruct && childFlow.currentConstruct.concrete) {\n return flowStart(code)\n } // If we do have flow, it could still be a blank line,\n // but we\u2019d be interrupting it w/ a new container if there\u2019s a current\n // construct.\n\n self.interrupt = Boolean(\n childFlow.currentConstruct && !childFlow._gfmTableDynamicInterruptHack\n )\n } // Check if there is a new container.\n\n self.containerState = {}\n return effects.check(\n containerConstruct,\n thereIsANewContainer,\n thereIsNoNewContainer\n )(code)\n }\n /** @type {State} */\n\n function thereIsANewContainer(code) {\n if (childFlow) closeFlow()\n exitContainers(continued)\n return documentContinued(code)\n }\n /** @type {State} */\n\n function thereIsNoNewContainer(code) {\n self.parser.lazy[self.now().line] = continued !== stack.length\n lineStartOffset = self.now().offset\n return flowStart(code)\n }\n /** @type {State} */\n\n function documentContinued(code) {\n // Try new containers.\n self.containerState = {}\n return effects.attempt(\n containerConstruct,\n containerContinue,\n flowStart\n )(code)\n }\n /** @type {State} */\n\n function containerContinue(code) {\n continued++\n stack.push([self.currentConstruct, self.containerState]) // Try another.\n\n return documentContinued(code)\n }\n /** @type {State} */\n\n function flowStart(code) {\n if (code === null) {\n if (childFlow) closeFlow()\n exitContainers(0)\n effects.consume(code)\n return\n }\n\n childFlow = childFlow || self.parser.flow(self.now())\n effects.enter('chunkFlow', {\n contentType: 'flow',\n previous: childToken,\n _tokenizer: childFlow\n })\n return flowContinue(code)\n }\n /** @type {State} */\n\n function flowContinue(code) {\n if (code === null) {\n writeToChild(effects.exit('chunkFlow'), true)\n exitContainers(0)\n effects.consume(code)\n return\n }\n\n if (markdownLineEnding(code)) {\n effects.consume(code)\n writeToChild(effects.exit('chunkFlow')) // Get ready for the next line.\n\n continued = 0\n self.interrupt = undefined\n return start\n }\n\n effects.consume(code)\n return flowContinue\n }\n /**\n * @param {Token} token\n * @param {boolean} [eof]\n * @returns {void}\n */\n\n function writeToChild(token, eof) {\n const stream = self.sliceStream(token)\n if (eof) stream.push(null)\n token.previous = childToken\n if (childToken) childToken.next = token\n childToken = token\n childFlow.defineSkip(token.start)\n childFlow.write(stream) // Alright, so we just added a lazy line:\n //\n // ```markdown\n // > a\n // b.\n //\n // Or:\n //\n // > ~~~c\n // d\n //\n // Or:\n //\n // > | e |\n // f\n // ```\n //\n // The construct in the second example (fenced code) does not accept lazy\n // lines, so it marked itself as done at the end of its first line, and\n // then the content construct parses `d`.\n // Most constructs in markdown match on the first line: if the first line\n // forms a construct, a non-lazy line can\u2019t \u201Cunmake\u201D it.\n //\n // The construct in the third example is potentially a GFM table, and\n // those are *weird*.\n // It *could* be a table, from the first line, if the following line\n // matches a condition.\n // In this case, that second line is lazy, which \u201Cunmakes\u201D the first line\n // and turns the whole into one content block.\n //\n // We\u2019ve now parsed the non-lazy and the lazy line, and can figure out\n // whether the lazy line started a new flow block.\n // If it did, we exit the current containers between the two flow blocks.\n\n if (self.parser.lazy[token.start.line]) {\n let index = childFlow.events.length\n\n while (index--) {\n if (\n // The token starts before the line ending\u2026\n childFlow.events[index][1].start.offset < lineStartOffset && // \u2026and either is not ended yet\u2026\n (!childFlow.events[index][1].end || // \u2026or ends after it.\n childFlow.events[index][1].end.offset > lineStartOffset)\n ) {\n // Exit: there\u2019s still something open, which means it\u2019s a lazy line\n // part of something.\n return\n }\n } // Note: this algorithm for moving events around is similar to the\n // algorithm when closing flow in `documentContinue`.\n\n const indexBeforeExits = self.events.length\n let indexBeforeFlow = indexBeforeExits\n /** @type {boolean|undefined} */\n\n let seen\n /** @type {Point|undefined} */\n\n let point // Find the previous chunk (the one before the lazy line).\n\n while (indexBeforeFlow--) {\n if (\n self.events[indexBeforeFlow][0] === 'exit' &&\n self.events[indexBeforeFlow][1].type === 'chunkFlow'\n ) {\n if (seen) {\n point = self.events[indexBeforeFlow][1].end\n break\n }\n\n seen = true\n }\n }\n\n exitContainers(continued) // Fix positions.\n\n index = indexBeforeExits\n\n while (index < self.events.length) {\n self.events[index][1].end = Object.assign({}, point)\n index++\n } // Inject the exits earlier (they\u2019re still also at the end).\n\n splice(\n self.events,\n indexBeforeFlow + 1,\n 0,\n self.events.slice(indexBeforeExits)\n ) // Discard the duplicate exits.\n\n self.events.length = index\n }\n }\n /**\n * @param {number} size\n * @returns {void}\n */\n\n function exitContainers(size) {\n let index = stack.length // Exit open containers.\n\n while (index-- > size) {\n const entry = stack[index]\n self.containerState = entry[1]\n entry[0].exit.call(self, effects)\n }\n\n stack.length = size\n }\n\n function closeFlow() {\n childFlow.write([null])\n childToken = undefined\n childFlow = undefined\n self.containerState._closeFlow = undefined\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeContainer(effects, ok, nok) {\n return factorySpace(\n effects,\n effects.attempt(this.parser.constructs.document, ok, nok),\n 'linePrefix',\n this.parser.constructs.disable.null.includes('codeIndented') ? undefined : 4\n )\n}\n", "/**\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {\n markdownLineEndingOrSpace,\n unicodePunctuation,\n unicodeWhitespace\n} from 'micromark-util-character'\n\n/**\n * Classify whether a character code represents whitespace, punctuation, or\n * something else.\n *\n * Used for attention (emphasis, strong), whose sequences can open or close\n * based on the class of surrounding characters.\n *\n * Note that eof (`null`) is seen as whitespace.\n *\n * @param {Code} code\n * @returns {number|undefined}\n */\nexport function classifyCharacter(code) {\n if (\n code === null ||\n markdownLineEndingOrSpace(code) ||\n unicodeWhitespace(code)\n ) {\n return 1\n }\n\n if (unicodePunctuation(code)) {\n return 2\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').Resolver} Resolver\n */\n\n/**\n * Call all `resolveAll`s.\n *\n * @param {{resolveAll?: Resolver}[]} constructs\n * @param {Event[]} events\n * @param {TokenizeContext} context\n * @returns {Event[]}\n */\nexport function resolveAll(constructs, events, context) {\n /** @type {Resolver[]} */\n const called = []\n let index = -1\n\n while (++index < constructs.length) {\n const resolve = constructs[index].resolveAll\n\n if (resolve && !called.includes(resolve)) {\n events = resolve(events, context)\n called.push(resolve)\n }\n }\n\n return events\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').Code} Code\n * @typedef {import('micromark-util-types').Point} Point\n */\nimport {push, splice} from 'micromark-util-chunked'\nimport {classifyCharacter} from 'micromark-util-classify-character'\nimport {resolveAll} from 'micromark-util-resolve-all'\n\n/** @type {Construct} */\nexport const attention = {\n name: 'attention',\n tokenize: tokenizeAttention,\n resolveAll: resolveAllAttention\n}\n/**\n * Take all events and resolve attention to emphasis or strong.\n *\n * @type {Resolver}\n */\n\nfunction resolveAllAttention(events, context) {\n let index = -1\n /** @type {number} */\n\n let open\n /** @type {Token} */\n\n let group\n /** @type {Token} */\n\n let text\n /** @type {Token} */\n\n let openingSequence\n /** @type {Token} */\n\n let closingSequence\n /** @type {number} */\n\n let use\n /** @type {Event[]} */\n\n let nextEvents\n /** @type {number} */\n\n let offset // Walk through all events.\n //\n // Note: performance of this is fine on an mb of normal markdown, but it\u2019s\n // a bottleneck for malicious stuff.\n\n while (++index < events.length) {\n // Find a token that can close.\n if (\n events[index][0] === 'enter' &&\n events[index][1].type === 'attentionSequence' &&\n events[index][1]._close\n ) {\n open = index // Now walk back to find an opener.\n\n while (open--) {\n // Find a token that can open the closer.\n if (\n events[open][0] === 'exit' &&\n events[open][1].type === 'attentionSequence' &&\n events[open][1]._open && // If the markers are the same:\n context.sliceSerialize(events[open][1]).charCodeAt(0) ===\n context.sliceSerialize(events[index][1]).charCodeAt(0)\n ) {\n // If the opening can close or the closing can open,\n // and the close size *is not* a multiple of three,\n // but the sum of the opening and closing size *is* multiple of three,\n // then don\u2019t match.\n if (\n (events[open][1]._close || events[index][1]._open) &&\n (events[index][1].end.offset - events[index][1].start.offset) % 3 &&\n !(\n (events[open][1].end.offset -\n events[open][1].start.offset +\n events[index][1].end.offset -\n events[index][1].start.offset) %\n 3\n )\n ) {\n continue\n } // Number of markers to use from the sequence.\n\n use =\n events[open][1].end.offset - events[open][1].start.offset > 1 &&\n events[index][1].end.offset - events[index][1].start.offset > 1\n ? 2\n : 1\n const start = Object.assign({}, events[open][1].end)\n const end = Object.assign({}, events[index][1].start)\n movePoint(start, -use)\n movePoint(end, use)\n openingSequence = {\n type: use > 1 ? 'strongSequence' : 'emphasisSequence',\n start,\n end: Object.assign({}, events[open][1].end)\n }\n closingSequence = {\n type: use > 1 ? 'strongSequence' : 'emphasisSequence',\n start: Object.assign({}, events[index][1].start),\n end\n }\n text = {\n type: use > 1 ? 'strongText' : 'emphasisText',\n start: Object.assign({}, events[open][1].end),\n end: Object.assign({}, events[index][1].start)\n }\n group = {\n type: use > 1 ? 'strong' : 'emphasis',\n start: Object.assign({}, openingSequence.start),\n end: Object.assign({}, closingSequence.end)\n }\n events[open][1].end = Object.assign({}, openingSequence.start)\n events[index][1].start = Object.assign({}, closingSequence.end)\n nextEvents = [] // If there are more markers in the opening, add them before.\n\n if (events[open][1].end.offset - events[open][1].start.offset) {\n nextEvents = push(nextEvents, [\n ['enter', events[open][1], context],\n ['exit', events[open][1], context]\n ])\n } // Opening.\n\n nextEvents = push(nextEvents, [\n ['enter', group, context],\n ['enter', openingSequence, context],\n ['exit', openingSequence, context],\n ['enter', text, context]\n ]) // Between.\n\n nextEvents = push(\n nextEvents,\n resolveAll(\n context.parser.constructs.insideSpan.null,\n events.slice(open + 1, index),\n context\n )\n ) // Closing.\n\n nextEvents = push(nextEvents, [\n ['exit', text, context],\n ['enter', closingSequence, context],\n ['exit', closingSequence, context],\n ['exit', group, context]\n ]) // If there are more markers in the closing, add them after.\n\n if (events[index][1].end.offset - events[index][1].start.offset) {\n offset = 2\n nextEvents = push(nextEvents, [\n ['enter', events[index][1], context],\n ['exit', events[index][1], context]\n ])\n } else {\n offset = 0\n }\n\n splice(events, open - 1, index - open + 3, nextEvents)\n index = open + nextEvents.length - offset - 2\n break\n }\n }\n }\n } // Remove remaining sequences.\n\n index = -1\n\n while (++index < events.length) {\n if (events[index][1].type === 'attentionSequence') {\n events[index][1].type = 'data'\n }\n }\n\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeAttention(effects, ok) {\n const attentionMarkers = this.parser.constructs.attentionMarkers.null\n const previous = this.previous\n const before = classifyCharacter(previous)\n /** @type {NonNullable} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('attentionSequence')\n marker = code\n return sequence(code)\n }\n /** @type {State} */\n\n function sequence(code) {\n if (code === marker) {\n effects.consume(code)\n return sequence\n }\n\n const token = effects.exit('attentionSequence')\n const after = classifyCharacter(code)\n const open =\n !after || (after === 2 && before) || attentionMarkers.includes(code)\n const close =\n !before || (before === 2 && after) || attentionMarkers.includes(previous)\n token._open = Boolean(marker === 42 ? open : open && (before || !close))\n token._close = Boolean(marker === 42 ? close : close && (after || !open))\n return ok(code)\n }\n}\n/**\n * Move a point a bit.\n *\n * Note: `move` only works inside lines! It\u2019s not possible to move past other\n * chunks (replacement characters, tabs, or line endings).\n *\n * @param {Point} point\n * @param {number} offset\n * @returns {void}\n */\n\nfunction movePoint(point, offset) {\n point.column += offset\n point.offset += offset\n point._bufferIndex += offset\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {\n asciiAlpha,\n asciiAlphanumeric,\n asciiAtext,\n asciiControl\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const autolink = {\n name: 'autolink',\n tokenize: tokenizeAutolink\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeAutolink(effects, ok, nok) {\n let size = 1\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('autolink')\n effects.enter('autolinkMarker')\n effects.consume(code)\n effects.exit('autolinkMarker')\n effects.enter('autolinkProtocol')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (asciiAlpha(code)) {\n effects.consume(code)\n return schemeOrEmailAtext\n }\n\n return asciiAtext(code) ? emailAtext(code) : nok(code)\n }\n /** @type {State} */\n\n function schemeOrEmailAtext(code) {\n return code === 43 || code === 45 || code === 46 || asciiAlphanumeric(code)\n ? schemeInsideOrEmailAtext(code)\n : emailAtext(code)\n }\n /** @type {State} */\n\n function schemeInsideOrEmailAtext(code) {\n if (code === 58) {\n effects.consume(code)\n return urlInside\n }\n\n if (\n (code === 43 || code === 45 || code === 46 || asciiAlphanumeric(code)) &&\n size++ < 32\n ) {\n effects.consume(code)\n return schemeInsideOrEmailAtext\n }\n\n return emailAtext(code)\n }\n /** @type {State} */\n\n function urlInside(code) {\n if (code === 62) {\n effects.exit('autolinkProtocol')\n return end(code)\n }\n\n if (code === null || code === 32 || code === 60 || asciiControl(code)) {\n return nok(code)\n }\n\n effects.consume(code)\n return urlInside\n }\n /** @type {State} */\n\n function emailAtext(code) {\n if (code === 64) {\n effects.consume(code)\n size = 0\n return emailAtSignOrDot\n }\n\n if (asciiAtext(code)) {\n effects.consume(code)\n return emailAtext\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function emailAtSignOrDot(code) {\n return asciiAlphanumeric(code) ? emailLabel(code) : nok(code)\n }\n /** @type {State} */\n\n function emailLabel(code) {\n if (code === 46) {\n effects.consume(code)\n size = 0\n return emailAtSignOrDot\n }\n\n if (code === 62) {\n // Exit, then change the type.\n effects.exit('autolinkProtocol').type = 'autolinkEmail'\n return end(code)\n }\n\n return emailValue(code)\n }\n /** @type {State} */\n\n function emailValue(code) {\n if ((code === 45 || asciiAlphanumeric(code)) && size++ < 63) {\n effects.consume(code)\n return code === 45 ? emailValue : emailLabel\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function end(code) {\n effects.enter('autolinkMarker')\n effects.consume(code)\n effects.exit('autolinkMarker')\n effects.exit('autolink')\n return ok\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const blankLine = {\n tokenize: tokenizeBlankLine,\n partial: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeBlankLine(effects, ok, nok) {\n return factorySpace(effects, afterWhitespace, 'linePrefix')\n /** @type {State} */\n\n function afterWhitespace(code) {\n return code === null || markdownLineEnding(code) ? ok(code) : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Exiter} Exiter\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownSpace} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const blockQuote = {\n name: 'blockQuote',\n tokenize: tokenizeBlockQuoteStart,\n continuation: {\n tokenize: tokenizeBlockQuoteContinuation\n },\n exit\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeBlockQuoteStart(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n if (code === 62) {\n const state = self.containerState\n\n if (!state.open) {\n effects.enter('blockQuote', {\n _container: true\n })\n state.open = true\n }\n\n effects.enter('blockQuotePrefix')\n effects.enter('blockQuoteMarker')\n effects.consume(code)\n effects.exit('blockQuoteMarker')\n return after\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n if (markdownSpace(code)) {\n effects.enter('blockQuotePrefixWhitespace')\n effects.consume(code)\n effects.exit('blockQuotePrefixWhitespace')\n effects.exit('blockQuotePrefix')\n return ok\n }\n\n effects.exit('blockQuotePrefix')\n return ok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeBlockQuoteContinuation(effects, ok, nok) {\n return factorySpace(\n effects,\n effects.attempt(blockQuote, ok, nok),\n 'linePrefix',\n this.parser.constructs.disable.null.includes('codeIndented') ? undefined : 4\n )\n}\n/** @type {Exiter} */\n\nfunction exit(effects) {\n effects.exit('blockQuote')\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {asciiPunctuation} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const characterEscape = {\n name: 'characterEscape',\n tokenize: tokenizeCharacterEscape\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCharacterEscape(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('characterEscape')\n effects.enter('escapeMarker')\n effects.consume(code)\n effects.exit('escapeMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (asciiPunctuation(code)) {\n effects.enter('characterEscapeValue')\n effects.consume(code)\n effects.exit('characterEscapeValue')\n effects.exit('characterEscape')\n return ok\n }\n\n return nok(code)\n }\n}\n", "/// \n\n/* eslint-env browser */\n\nconst element = document.createElement('i')\n\n/**\n * @param {string} value\n * @returns {string|false}\n */\nexport function decodeNamedCharacterReference(value) {\n const characterReference = '&' + value + ';'\n element.innerHTML = characterReference\n const char = element.textContent\n\n // Some named character references do not require the closing semicolon\n // (`¬`, for instance), which leads to situations where parsing the assumed\n // named reference of `¬it;` will result in the string `\u00ACit;`.\n // When we encounter a trailing semicolon after parsing, and the character\n // reference to decode was not a semicolon (`;`), we can assume that the\n // matching was not complete.\n // @ts-expect-error: TypeScript is wrong that `textContent` on elements can\n // yield `null`.\n if (char.charCodeAt(char.length - 1) === 59 /* `;` */ && value !== 'semi') {\n return false\n }\n\n // If the decoded string is equal to the input, the character reference was\n // not valid.\n // @ts-expect-error: TypeScript is wrong that `textContent` on elements can\n // yield `null`.\n return char === characterReference ? false : char\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {decodeNamedCharacterReference} from 'decode-named-character-reference'\nimport {\n asciiAlphanumeric,\n asciiDigit,\n asciiHexDigit\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const characterReference = {\n name: 'characterReference',\n tokenize: tokenizeCharacterReference\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCharacterReference(effects, ok, nok) {\n const self = this\n let size = 0\n /** @type {number} */\n\n let max\n /** @type {(code: Code) => code is number} */\n\n let test\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('characterReference')\n effects.enter('characterReferenceMarker')\n effects.consume(code)\n effects.exit('characterReferenceMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 35) {\n effects.enter('characterReferenceMarkerNumeric')\n effects.consume(code)\n effects.exit('characterReferenceMarkerNumeric')\n return numeric\n }\n\n effects.enter('characterReferenceValue')\n max = 31\n test = asciiAlphanumeric\n return value(code)\n }\n /** @type {State} */\n\n function numeric(code) {\n if (code === 88 || code === 120) {\n effects.enter('characterReferenceMarkerHexadecimal')\n effects.consume(code)\n effects.exit('characterReferenceMarkerHexadecimal')\n effects.enter('characterReferenceValue')\n max = 6\n test = asciiHexDigit\n return value\n }\n\n effects.enter('characterReferenceValue')\n max = 7\n test = asciiDigit\n return value(code)\n }\n /** @type {State} */\n\n function value(code) {\n /** @type {Token} */\n let token\n\n if (code === 59 && size) {\n token = effects.exit('characterReferenceValue')\n\n if (\n test === asciiAlphanumeric &&\n !decodeNamedCharacterReference(self.sliceSerialize(token))\n ) {\n return nok(code)\n }\n\n effects.enter('characterReferenceMarker')\n effects.consume(code)\n effects.exit('characterReferenceMarker')\n effects.exit('characterReference')\n return ok\n }\n\n if (test(code) && size++ < max) {\n effects.consume(code)\n return value\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {\n markdownLineEnding,\n markdownLineEndingOrSpace\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const codeFenced = {\n name: 'codeFenced',\n tokenize: tokenizeCodeFenced,\n concrete: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCodeFenced(effects, ok, nok) {\n const self = this\n /** @type {Construct} */\n\n const closingFenceConstruct = {\n tokenize: tokenizeClosingFence,\n partial: true\n }\n /** @type {Construct} */\n\n const nonLazyLine = {\n tokenize: tokenizeNonLazyLine,\n partial: true\n }\n const tail = this.events[this.events.length - 1]\n const initialPrefix =\n tail && tail[1].type === 'linePrefix'\n ? tail[2].sliceSerialize(tail[1], true).length\n : 0\n let sizeOpen = 0\n /** @type {NonNullable} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('codeFenced')\n effects.enter('codeFencedFence')\n effects.enter('codeFencedFenceSequence')\n marker = code\n return sequenceOpen(code)\n }\n /** @type {State} */\n\n function sequenceOpen(code) {\n if (code === marker) {\n effects.consume(code)\n sizeOpen++\n return sequenceOpen\n }\n\n effects.exit('codeFencedFenceSequence')\n return sizeOpen < 3\n ? nok(code)\n : factorySpace(effects, infoOpen, 'whitespace')(code)\n }\n /** @type {State} */\n\n function infoOpen(code) {\n if (code === null || markdownLineEnding(code)) {\n return openAfter(code)\n }\n\n effects.enter('codeFencedFenceInfo')\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return info(code)\n }\n /** @type {State} */\n\n function info(code) {\n if (code === null || markdownLineEndingOrSpace(code)) {\n effects.exit('chunkString')\n effects.exit('codeFencedFenceInfo')\n return factorySpace(effects, infoAfter, 'whitespace')(code)\n }\n\n if (code === 96 && code === marker) return nok(code)\n effects.consume(code)\n return info\n }\n /** @type {State} */\n\n function infoAfter(code) {\n if (code === null || markdownLineEnding(code)) {\n return openAfter(code)\n }\n\n effects.enter('codeFencedFenceMeta')\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return meta(code)\n }\n /** @type {State} */\n\n function meta(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('chunkString')\n effects.exit('codeFencedFenceMeta')\n return openAfter(code)\n }\n\n if (code === 96 && code === marker) return nok(code)\n effects.consume(code)\n return meta\n }\n /** @type {State} */\n\n function openAfter(code) {\n effects.exit('codeFencedFence')\n return self.interrupt ? ok(code) : contentStart(code)\n }\n /** @type {State} */\n\n function contentStart(code) {\n if (code === null) {\n return after(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.attempt(\n nonLazyLine,\n effects.attempt(\n closingFenceConstruct,\n after,\n initialPrefix\n ? factorySpace(\n effects,\n contentStart,\n 'linePrefix',\n initialPrefix + 1\n )\n : contentStart\n ),\n after\n )(code)\n }\n\n effects.enter('codeFlowValue')\n return contentContinue(code)\n }\n /** @type {State} */\n\n function contentContinue(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('codeFlowValue')\n return contentStart(code)\n }\n\n effects.consume(code)\n return contentContinue\n }\n /** @type {State} */\n\n function after(code) {\n effects.exit('codeFenced')\n return ok(code)\n }\n /** @type {Tokenizer} */\n\n function tokenizeNonLazyLine(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return lineStart\n }\n /** @type {State} */\n\n function lineStart(code) {\n return self.parser.lazy[self.now().line] ? nok(code) : ok(code)\n }\n }\n /** @type {Tokenizer} */\n\n function tokenizeClosingFence(effects, ok, nok) {\n let size = 0\n return factorySpace(\n effects,\n closingSequenceStart,\n 'linePrefix',\n this.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4\n )\n /** @type {State} */\n\n function closingSequenceStart(code) {\n effects.enter('codeFencedFence')\n effects.enter('codeFencedFenceSequence')\n return closingSequence(code)\n }\n /** @type {State} */\n\n function closingSequence(code) {\n if (code === marker) {\n effects.consume(code)\n size++\n return closingSequence\n }\n\n if (size < sizeOpen) return nok(code)\n effects.exit('codeFencedFenceSequence')\n return factorySpace(effects, closingSequenceEnd, 'whitespace')(code)\n }\n /** @type {State} */\n\n function closingSequenceEnd(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('codeFencedFence')\n return ok(code)\n }\n\n return nok(code)\n }\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const codeIndented = {\n name: 'codeIndented',\n tokenize: tokenizeCodeIndented\n}\n/** @type {Construct} */\n\nconst indentedContent = {\n tokenize: tokenizeIndentedContent,\n partial: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCodeIndented(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('codeIndented')\n return factorySpace(effects, afterStartPrefix, 'linePrefix', 4 + 1)(code)\n }\n /** @type {State} */\n\n function afterStartPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return tail &&\n tail[1].type === 'linePrefix' &&\n tail[2].sliceSerialize(tail[1], true).length >= 4\n ? afterPrefix(code)\n : nok(code)\n }\n /** @type {State} */\n\n function afterPrefix(code) {\n if (code === null) {\n return after(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.attempt(indentedContent, afterPrefix, after)(code)\n }\n\n effects.enter('codeFlowValue')\n return content(code)\n }\n /** @type {State} */\n\n function content(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('codeFlowValue')\n return afterPrefix(code)\n }\n\n effects.consume(code)\n return content\n }\n /** @type {State} */\n\n function after(code) {\n effects.exit('codeIndented')\n return ok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeIndentedContent(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n // If this is a lazy line, it can\u2019t be code.\n if (self.parser.lazy[self.now().line]) {\n return nok(code)\n }\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return start\n }\n\n return factorySpace(effects, afterPrefix, 'linePrefix', 4 + 1)(code)\n }\n /** @type {State} */\n\n function afterPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return tail &&\n tail[1].type === 'linePrefix' &&\n tail[2].sliceSerialize(tail[1], true).length >= 4\n ? ok(code)\n : markdownLineEnding(code)\n ? start(code)\n : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Previous} Previous\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const codeText = {\n name: 'codeText',\n tokenize: tokenizeCodeText,\n resolve: resolveCodeText,\n previous\n}\n/** @type {Resolver} */\n\nfunction resolveCodeText(events) {\n let tailExitIndex = events.length - 4\n let headEnterIndex = 3\n /** @type {number} */\n\n let index\n /** @type {number|undefined} */\n\n let enter // If we start and end with an EOL or a space.\n\n if (\n (events[headEnterIndex][1].type === 'lineEnding' ||\n events[headEnterIndex][1].type === 'space') &&\n (events[tailExitIndex][1].type === 'lineEnding' ||\n events[tailExitIndex][1].type === 'space')\n ) {\n index = headEnterIndex // And we have data.\n\n while (++index < tailExitIndex) {\n if (events[index][1].type === 'codeTextData') {\n // Then we have padding.\n events[headEnterIndex][1].type = 'codeTextPadding'\n events[tailExitIndex][1].type = 'codeTextPadding'\n headEnterIndex += 2\n tailExitIndex -= 2\n break\n }\n }\n } // Merge adjacent spaces and data.\n\n index = headEnterIndex - 1\n tailExitIndex++\n\n while (++index <= tailExitIndex) {\n if (enter === undefined) {\n if (index !== tailExitIndex && events[index][1].type !== 'lineEnding') {\n enter = index\n }\n } else if (\n index === tailExitIndex ||\n events[index][1].type === 'lineEnding'\n ) {\n events[enter][1].type = 'codeTextData'\n\n if (index !== enter + 2) {\n events[enter][1].end = events[index - 1][1].end\n events.splice(enter + 2, index - enter - 2)\n tailExitIndex -= index - enter - 2\n index = enter + 2\n }\n\n enter = undefined\n }\n }\n\n return events\n}\n/** @type {Previous} */\n\nfunction previous(code) {\n // If there is a previous code, there will always be a tail.\n return (\n code !== 96 ||\n this.events[this.events.length - 1][1].type === 'characterEscape'\n )\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCodeText(effects, ok, nok) {\n const self = this\n let sizeOpen = 0\n /** @type {number} */\n\n let size\n /** @type {Token} */\n\n let token\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('codeText')\n effects.enter('codeTextSequence')\n return openingSequence(code)\n }\n /** @type {State} */\n\n function openingSequence(code) {\n if (code === 96) {\n effects.consume(code)\n sizeOpen++\n return openingSequence\n }\n\n effects.exit('codeTextSequence')\n return gap(code)\n }\n /** @type {State} */\n\n function gap(code) {\n // EOF.\n if (code === null) {\n return nok(code)\n } // Closing fence?\n // Could also be data.\n\n if (code === 96) {\n token = effects.enter('codeTextSequence')\n size = 0\n return closingSequence(code)\n } // Tabs don\u2019t work, and virtual spaces don\u2019t make sense.\n\n if (code === 32) {\n effects.enter('space')\n effects.consume(code)\n effects.exit('space')\n return gap\n }\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return gap\n } // Data.\n\n effects.enter('codeTextData')\n return data(code)\n } // In code.\n\n /** @type {State} */\n\n function data(code) {\n if (\n code === null ||\n code === 32 ||\n code === 96 ||\n markdownLineEnding(code)\n ) {\n effects.exit('codeTextData')\n return gap(code)\n }\n\n effects.consume(code)\n return data\n } // Closing fence.\n\n /** @type {State} */\n\n function closingSequence(code) {\n // More.\n if (code === 96) {\n effects.consume(code)\n size++\n return closingSequence\n } // Done!\n\n if (size === sizeOpen) {\n effects.exit('codeTextSequence')\n effects.exit('codeText')\n return ok(code)\n } // More or less accents: mark as data.\n\n token.type = 'codeTextData'\n return data(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').Chunk} Chunk\n * @typedef {import('micromark-util-types').Event} Event\n */\nimport {splice} from 'micromark-util-chunked'\n\n/**\n * Tokenize subcontent.\n *\n * @param {Event[]} events\n * @returns {boolean}\n */\nexport function subtokenize(events) {\n /** @type {Record} */\n const jumps = {}\n let index = -1\n /** @type {Event} */\n\n let event\n /** @type {number|undefined} */\n\n let lineIndex\n /** @type {number} */\n\n let otherIndex\n /** @type {Event} */\n\n let otherEvent\n /** @type {Event[]} */\n\n let parameters\n /** @type {Event[]} */\n\n let subevents\n /** @type {boolean|undefined} */\n\n let more\n\n while (++index < events.length) {\n while (index in jumps) {\n index = jumps[index]\n }\n\n event = events[index] // Add a hook for the GFM tasklist extension, which needs to know if text\n // is in the first content of a list item.\n\n if (\n index &&\n event[1].type === 'chunkFlow' &&\n events[index - 1][1].type === 'listItemPrefix'\n ) {\n subevents = event[1]._tokenizer.events\n otherIndex = 0\n\n if (\n otherIndex < subevents.length &&\n subevents[otherIndex][1].type === 'lineEndingBlank'\n ) {\n otherIndex += 2\n }\n\n if (\n otherIndex < subevents.length &&\n subevents[otherIndex][1].type === 'content'\n ) {\n while (++otherIndex < subevents.length) {\n if (subevents[otherIndex][1].type === 'content') {\n break\n }\n\n if (subevents[otherIndex][1].type === 'chunkText') {\n subevents[otherIndex][1]._isInFirstContentOfListItem = true\n otherIndex++\n }\n }\n }\n } // Enter.\n\n if (event[0] === 'enter') {\n if (event[1].contentType) {\n Object.assign(jumps, subcontent(events, index))\n index = jumps[index]\n more = true\n }\n } // Exit.\n else if (event[1]._container) {\n otherIndex = index\n lineIndex = undefined\n\n while (otherIndex--) {\n otherEvent = events[otherIndex]\n\n if (\n otherEvent[1].type === 'lineEnding' ||\n otherEvent[1].type === 'lineEndingBlank'\n ) {\n if (otherEvent[0] === 'enter') {\n if (lineIndex) {\n events[lineIndex][1].type = 'lineEndingBlank'\n }\n\n otherEvent[1].type = 'lineEnding'\n lineIndex = otherIndex\n }\n } else {\n break\n }\n }\n\n if (lineIndex) {\n // Fix position.\n event[1].end = Object.assign({}, events[lineIndex][1].start) // Switch container exit w/ line endings.\n\n parameters = events.slice(lineIndex, index)\n parameters.unshift(event)\n splice(events, lineIndex, index - lineIndex + 1, parameters)\n }\n }\n }\n\n return !more\n}\n/**\n * Tokenize embedded tokens.\n *\n * @param {Event[]} events\n * @param {number} eventIndex\n * @returns {Record}\n */\n\nfunction subcontent(events, eventIndex) {\n const token = events[eventIndex][1]\n const context = events[eventIndex][2]\n let startPosition = eventIndex - 1\n /** @type {number[]} */\n\n const startPositions = []\n const tokenizer =\n token._tokenizer || context.parser[token.contentType](token.start)\n const childEvents = tokenizer.events\n /** @type {[number, number][]} */\n\n const jumps = []\n /** @type {Record} */\n\n const gaps = {}\n /** @type {Chunk[]} */\n\n let stream\n /** @type {Token|undefined} */\n\n let previous\n let index = -1\n /** @type {Token|undefined} */\n\n let current = token\n let adjust = 0\n let start = 0\n const breaks = [start] // Loop forward through the linked tokens to pass them in order to the\n // subtokenizer.\n\n while (current) {\n // Find the position of the event for this token.\n while (events[++startPosition][1] !== current) {\n // Empty.\n }\n\n startPositions.push(startPosition)\n\n if (!current._tokenizer) {\n stream = context.sliceStream(current)\n\n if (!current.next) {\n stream.push(null)\n }\n\n if (previous) {\n tokenizer.defineSkip(current.start)\n }\n\n if (current._isInFirstContentOfListItem) {\n tokenizer._gfmTasklistFirstContentOfListItem = true\n }\n\n tokenizer.write(stream)\n\n if (current._isInFirstContentOfListItem) {\n tokenizer._gfmTasklistFirstContentOfListItem = undefined\n }\n } // Unravel the next token.\n\n previous = current\n current = current.next\n } // Now, loop back through all events (and linked tokens), to figure out which\n // parts belong where.\n\n current = token\n\n while (++index < childEvents.length) {\n if (\n // Find a void token that includes a break.\n childEvents[index][0] === 'exit' &&\n childEvents[index - 1][0] === 'enter' &&\n childEvents[index][1].type === childEvents[index - 1][1].type &&\n childEvents[index][1].start.line !== childEvents[index][1].end.line\n ) {\n start = index + 1\n breaks.push(start) // Help GC.\n\n current._tokenizer = undefined\n current.previous = undefined\n current = current.next\n }\n } // Help GC.\n\n tokenizer.events = [] // If there\u2019s one more token (which is the cases for lines that end in an\n // EOF), that\u2019s perfect: the last point we found starts it.\n // If there isn\u2019t then make sure any remaining content is added to it.\n\n if (current) {\n // Help GC.\n current._tokenizer = undefined\n current.previous = undefined\n } else {\n breaks.pop()\n } // Now splice the events from the subtokenizer into the current events,\n // moving back to front so that splice indices aren\u2019t affected.\n\n index = breaks.length\n\n while (index--) {\n const slice = childEvents.slice(breaks[index], breaks[index + 1])\n const start = startPositions.pop()\n jumps.unshift([start, start + slice.length - 1])\n splice(events, start, 2, slice)\n }\n\n index = -1\n\n while (++index < jumps.length) {\n gaps[adjust + jumps[index][0]] = adjust + jumps[index][1]\n adjust += jumps[index][1] - jumps[index][0] - 1\n }\n\n return gaps\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\nimport {subtokenize} from 'micromark-util-subtokenize'\n\n/**\n * No name because it must not be turned off.\n * @type {Construct}\n */\nexport const content = {\n tokenize: tokenizeContent,\n resolve: resolveContent\n}\n/** @type {Construct} */\n\nconst continuationConstruct = {\n tokenize: tokenizeContinuation,\n partial: true\n}\n/**\n * Content is transparent: it\u2019s parsed right now. That way, definitions are also\n * parsed right now: before text in paragraphs (specifically, media) are parsed.\n *\n * @type {Resolver}\n */\n\nfunction resolveContent(events) {\n subtokenize(events)\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeContent(effects, ok) {\n /** @type {Token} */\n let previous\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('content')\n previous = effects.enter('chunkContent', {\n contentType: 'content'\n })\n return data(code)\n }\n /** @type {State} */\n\n function data(code) {\n if (code === null) {\n return contentEnd(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.check(\n continuationConstruct,\n contentContinue,\n contentEnd\n )(code)\n } // Data.\n\n effects.consume(code)\n return data\n }\n /** @type {State} */\n\n function contentEnd(code) {\n effects.exit('chunkContent')\n effects.exit('content')\n return ok(code)\n }\n /** @type {State} */\n\n function contentContinue(code) {\n effects.consume(code)\n effects.exit('chunkContent')\n previous.next = effects.enter('chunkContent', {\n contentType: 'content',\n previous\n })\n previous = previous.next\n return data\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeContinuation(effects, ok, nok) {\n const self = this\n return startLookahead\n /** @type {State} */\n\n function startLookahead(code) {\n effects.exit('chunkContent')\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, prefixed, 'linePrefix')\n }\n /** @type {State} */\n\n function prefixed(code) {\n if (code === null || markdownLineEnding(code)) {\n return nok(code)\n }\n\n const tail = self.events[self.events.length - 1]\n\n if (\n !self.parser.constructs.disable.null.includes('codeIndented') &&\n tail &&\n tail[1].type === 'linePrefix' &&\n tail[2].sliceSerialize(tail[1], true).length >= 4\n ) {\n return ok(code)\n }\n\n return effects.interrupt(self.parser.constructs.flow, nok, ok)(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n */\nimport {\n asciiControl,\n markdownLineEndingOrSpace,\n markdownLineEnding\n} from 'micromark-util-character'\n\n/**\n * @param {Effects} effects\n * @param {State} ok\n * @param {State} nok\n * @param {string} type\n * @param {string} literalType\n * @param {string} literalMarkerType\n * @param {string} rawType\n * @param {string} stringType\n * @param {number} [max=Infinity]\n * @returns {State}\n */\n// eslint-disable-next-line max-params\nexport function factoryDestination(\n effects,\n ok,\n nok,\n type,\n literalType,\n literalMarkerType,\n rawType,\n stringType,\n max\n) {\n const limit = max || Number.POSITIVE_INFINITY\n let balance = 0\n return start\n /** @type {State} */\n\n function start(code) {\n if (code === 60) {\n effects.enter(type)\n effects.enter(literalType)\n effects.enter(literalMarkerType)\n effects.consume(code)\n effects.exit(literalMarkerType)\n return destinationEnclosedBefore\n }\n\n if (code === null || code === 41 || asciiControl(code)) {\n return nok(code)\n }\n\n effects.enter(type)\n effects.enter(rawType)\n effects.enter(stringType)\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return destinationRaw(code)\n }\n /** @type {State} */\n\n function destinationEnclosedBefore(code) {\n if (code === 62) {\n effects.enter(literalMarkerType)\n effects.consume(code)\n effects.exit(literalMarkerType)\n effects.exit(literalType)\n effects.exit(type)\n return ok\n }\n\n effects.enter(stringType)\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return destinationEnclosed(code)\n }\n /** @type {State} */\n\n function destinationEnclosed(code) {\n if (code === 62) {\n effects.exit('chunkString')\n effects.exit(stringType)\n return destinationEnclosedBefore(code)\n }\n\n if (code === null || code === 60 || markdownLineEnding(code)) {\n return nok(code)\n }\n\n effects.consume(code)\n return code === 92 ? destinationEnclosedEscape : destinationEnclosed\n }\n /** @type {State} */\n\n function destinationEnclosedEscape(code) {\n if (code === 60 || code === 62 || code === 92) {\n effects.consume(code)\n return destinationEnclosed\n }\n\n return destinationEnclosed(code)\n }\n /** @type {State} */\n\n function destinationRaw(code) {\n if (code === 40) {\n if (++balance > limit) return nok(code)\n effects.consume(code)\n return destinationRaw\n }\n\n if (code === 41) {\n if (!balance--) {\n effects.exit('chunkString')\n effects.exit(stringType)\n effects.exit(rawType)\n effects.exit(type)\n return ok(code)\n }\n\n effects.consume(code)\n return destinationRaw\n }\n\n if (code === null || markdownLineEndingOrSpace(code)) {\n if (balance) return nok(code)\n effects.exit('chunkString')\n effects.exit(stringType)\n effects.exit(rawType)\n effects.exit(type)\n return ok(code)\n }\n\n if (asciiControl(code)) return nok(code)\n effects.consume(code)\n return code === 92 ? destinationRawEscape : destinationRaw\n }\n /** @type {State} */\n\n function destinationRawEscape(code) {\n if (code === 40 || code === 41 || code === 92) {\n effects.consume(code)\n return destinationRaw\n }\n\n return destinationRaw(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownLineEnding, markdownSpace} from 'micromark-util-character'\n\n/**\n * @this {TokenizeContext}\n * @param {Effects} effects\n * @param {State} ok\n * @param {State} nok\n * @param {string} type\n * @param {string} markerType\n * @param {string} stringType\n * @returns {State}\n */\n// eslint-disable-next-line max-params\nexport function factoryLabel(effects, ok, nok, type, markerType, stringType) {\n const self = this\n let size = 0\n /** @type {boolean} */\n\n let data\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter(type)\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n effects.enter(stringType)\n return atBreak\n }\n /** @type {State} */\n\n function atBreak(code) {\n if (\n code === null ||\n code === 91 ||\n (code === 93 && !data) ||\n /* To do: remove in the future once we\u2019ve switched from\n * `micromark-extension-footnote` to `micromark-extension-gfm-footnote`,\n * which doesn\u2019t need this */\n\n /* Hidden footnotes hook */\n\n /* c8 ignore next 3 */\n (code === 94 &&\n !size &&\n '_hiddenFootnoteSupport' in self.parser.constructs) ||\n size > 999\n ) {\n return nok(code)\n }\n\n if (code === 93) {\n effects.exit(stringType)\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n effects.exit(type)\n return ok\n }\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return atBreak\n }\n\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return label(code)\n }\n /** @type {State} */\n\n function label(code) {\n if (\n code === null ||\n code === 91 ||\n code === 93 ||\n markdownLineEnding(code) ||\n size++ > 999\n ) {\n effects.exit('chunkString')\n return atBreak(code)\n }\n\n effects.consume(code)\n data = data || !markdownSpace(code)\n return code === 92 ? labelEscape : label\n }\n /** @type {State} */\n\n function labelEscape(code) {\n if (code === 91 || code === 92 || code === 93) {\n effects.consume(code)\n size++\n return label\n }\n\n return label(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/**\n * @param {Effects} effects\n * @param {State} ok\n * @param {State} nok\n * @param {string} type\n * @param {string} markerType\n * @param {string} stringType\n * @returns {State}\n */\n// eslint-disable-next-line max-params\nexport function factoryTitle(effects, ok, nok, type, markerType, stringType) {\n /** @type {NonNullable} */\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter(type)\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n marker = code === 40 ? 41 : code\n return atFirstTitleBreak\n }\n /** @type {State} */\n\n function atFirstTitleBreak(code) {\n if (code === marker) {\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n effects.exit(type)\n return ok\n }\n\n effects.enter(stringType)\n return atTitleBreak(code)\n }\n /** @type {State} */\n\n function atTitleBreak(code) {\n if (code === marker) {\n effects.exit(stringType)\n return atFirstTitleBreak(marker)\n }\n\n if (code === null) {\n return nok(code)\n } // Note: blank lines can\u2019t exist in content.\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, atTitleBreak, 'linePrefix')\n }\n\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return title(code)\n }\n /** @type {State} */\n\n function title(code) {\n if (code === marker || code === null || markdownLineEnding(code)) {\n effects.exit('chunkString')\n return atTitleBreak(code)\n }\n\n effects.consume(code)\n return code === 92 ? titleEscape : title\n }\n /** @type {State} */\n\n function titleEscape(code) {\n if (code === marker || code === 92) {\n effects.consume(code)\n return title\n }\n\n return title(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding, markdownSpace} from 'micromark-util-character'\n\n/**\n * @param {Effects} effects\n * @param {State} ok\n */\nexport function factoryWhitespace(effects, ok) {\n /** @type {boolean} */\n let seen\n return start\n /** @type {State} */\n\n function start(code) {\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n seen = true\n return start\n }\n\n if (markdownSpace(code)) {\n return factorySpace(\n effects,\n start,\n seen ? 'linePrefix' : 'lineSuffix'\n )(code)\n }\n\n return ok(code)\n }\n}\n", "/**\n * Normalize an identifier (such as used in definitions).\n *\n * @param {string} value\n * @returns {string}\n */\nexport function normalizeIdentifier(value) {\n return (\n value // Collapse Markdown whitespace.\n .replace(/[\\t\\n\\r ]+/g, ' ') // Trim.\n .replace(/^ | $/g, '') // Some characters are considered \u201Cuppercase\u201D, but if their lowercase\n // counterpart is uppercased will result in a different uppercase\n // character.\n // Hence, to get that form, we perform both lower- and uppercase.\n // Upper case makes sure keys will not interact with default prototypal\n // methods: no method is uppercase.\n .toLowerCase()\n .toUpperCase()\n )\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factoryDestination} from 'micromark-factory-destination'\nimport {factoryLabel} from 'micromark-factory-label'\nimport {factorySpace} from 'micromark-factory-space'\nimport {factoryTitle} from 'micromark-factory-title'\nimport {factoryWhitespace} from 'micromark-factory-whitespace'\nimport {normalizeIdentifier} from 'micromark-util-normalize-identifier'\nimport {\n markdownLineEnding,\n markdownLineEndingOrSpace\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const definition = {\n name: 'definition',\n tokenize: tokenizeDefinition\n}\n/** @type {Construct} */\n\nconst titleConstruct = {\n tokenize: tokenizeTitle,\n partial: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeDefinition(effects, ok, nok) {\n const self = this\n /** @type {string} */\n\n let identifier\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('definition')\n return factoryLabel.call(\n self,\n effects,\n labelAfter,\n nok,\n 'definitionLabel',\n 'definitionLabelMarker',\n 'definitionLabelString'\n )(code)\n }\n /** @type {State} */\n\n function labelAfter(code) {\n identifier = normalizeIdentifier(\n self.sliceSerialize(self.events[self.events.length - 1][1]).slice(1, -1)\n )\n\n if (code === 58) {\n effects.enter('definitionMarker')\n effects.consume(code)\n effects.exit('definitionMarker') // Note: blank lines can\u2019t exist in content.\n\n return factoryWhitespace(\n effects,\n factoryDestination(\n effects,\n effects.attempt(\n titleConstruct,\n factorySpace(effects, after, 'whitespace'),\n factorySpace(effects, after, 'whitespace')\n ),\n nok,\n 'definitionDestination',\n 'definitionDestinationLiteral',\n 'definitionDestinationLiteralMarker',\n 'definitionDestinationRaw',\n 'definitionDestinationString'\n )\n )\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('definition')\n\n if (!self.parser.defined.includes(identifier)) {\n self.parser.defined.push(identifier)\n }\n\n return ok(code)\n }\n\n return nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeTitle(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n return markdownLineEndingOrSpace(code)\n ? factoryWhitespace(effects, before)(code)\n : nok(code)\n }\n /** @type {State} */\n\n function before(code) {\n if (code === 34 || code === 39 || code === 40) {\n return factoryTitle(\n effects,\n factorySpace(effects, after, 'whitespace'),\n nok,\n 'definitionTitle',\n 'definitionTitleMarker',\n 'definitionTitleString'\n )(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n return code === null || markdownLineEnding(code) ? ok(code) : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const hardBreakEscape = {\n name: 'hardBreakEscape',\n tokenize: tokenizeHardBreakEscape\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHardBreakEscape(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('hardBreakEscape')\n effects.enter('escapeMarker')\n effects.consume(code)\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (markdownLineEnding(code)) {\n effects.exit('escapeMarker')\n effects.exit('hardBreakEscape')\n return ok(code)\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {\n markdownLineEnding,\n markdownLineEndingOrSpace,\n markdownSpace\n} from 'micromark-util-character'\nimport {splice} from 'micromark-util-chunked'\n\n/** @type {Construct} */\nexport const headingAtx = {\n name: 'headingAtx',\n tokenize: tokenizeHeadingAtx,\n resolve: resolveHeadingAtx\n}\n/** @type {Resolver} */\n\nfunction resolveHeadingAtx(events, context) {\n let contentEnd = events.length - 2\n let contentStart = 3\n /** @type {Token} */\n\n let content\n /** @type {Token} */\n\n let text // Prefix whitespace, part of the opening.\n\n if (events[contentStart][1].type === 'whitespace') {\n contentStart += 2\n } // Suffix whitespace, part of the closing.\n\n if (\n contentEnd - 2 > contentStart &&\n events[contentEnd][1].type === 'whitespace'\n ) {\n contentEnd -= 2\n }\n\n if (\n events[contentEnd][1].type === 'atxHeadingSequence' &&\n (contentStart === contentEnd - 1 ||\n (contentEnd - 4 > contentStart &&\n events[contentEnd - 2][1].type === 'whitespace'))\n ) {\n contentEnd -= contentStart + 1 === contentEnd ? 2 : 4\n }\n\n if (contentEnd > contentStart) {\n content = {\n type: 'atxHeadingText',\n start: events[contentStart][1].start,\n end: events[contentEnd][1].end\n }\n text = {\n type: 'chunkText',\n start: events[contentStart][1].start,\n end: events[contentEnd][1].end,\n // @ts-expect-error Constants are fine to assign.\n contentType: 'text'\n }\n splice(events, contentStart, contentEnd - contentStart + 1, [\n ['enter', content, context],\n ['enter', text, context],\n ['exit', text, context],\n ['exit', content, context]\n ])\n }\n\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHeadingAtx(effects, ok, nok) {\n const self = this\n let size = 0\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('atxHeading')\n effects.enter('atxHeadingSequence')\n return fenceOpenInside(code)\n }\n /** @type {State} */\n\n function fenceOpenInside(code) {\n if (code === 35 && size++ < 6) {\n effects.consume(code)\n return fenceOpenInside\n }\n\n if (code === null || markdownLineEndingOrSpace(code)) {\n effects.exit('atxHeadingSequence')\n return self.interrupt ? ok(code) : headingBreak(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function headingBreak(code) {\n if (code === 35) {\n effects.enter('atxHeadingSequence')\n return sequence(code)\n }\n\n if (code === null || markdownLineEnding(code)) {\n effects.exit('atxHeading')\n return ok(code)\n }\n\n if (markdownSpace(code)) {\n return factorySpace(effects, headingBreak, 'whitespace')(code)\n }\n\n effects.enter('atxHeadingText')\n return data(code)\n }\n /** @type {State} */\n\n function sequence(code) {\n if (code === 35) {\n effects.consume(code)\n return sequence\n }\n\n effects.exit('atxHeadingSequence')\n return headingBreak(code)\n }\n /** @type {State} */\n\n function data(code) {\n if (code === null || code === 35 || markdownLineEndingOrSpace(code)) {\n effects.exit('atxHeadingText')\n return headingBreak(code)\n }\n\n effects.consume(code)\n return data\n }\n}\n", "/**\n * List of lowercase HTML tag names which when parsing HTML (flow), result\n * in more relaxed rules (condition 6): because they are known blocks, the\n * HTML-like syntax doesn\u2019t have to be strictly parsed.\n * For tag names not in this list, a more strict algorithm (condition 7) is used\n * to detect whether the HTML-like syntax is seen as HTML (flow) or not.\n *\n * This is copied from:\n * .\n */\nexport const htmlBlockNames = [\n 'address',\n 'article',\n 'aside',\n 'base',\n 'basefont',\n 'blockquote',\n 'body',\n 'caption',\n 'center',\n 'col',\n 'colgroup',\n 'dd',\n 'details',\n 'dialog',\n 'dir',\n 'div',\n 'dl',\n 'dt',\n 'fieldset',\n 'figcaption',\n 'figure',\n 'footer',\n 'form',\n 'frame',\n 'frameset',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'head',\n 'header',\n 'hr',\n 'html',\n 'iframe',\n 'legend',\n 'li',\n 'link',\n 'main',\n 'menu',\n 'menuitem',\n 'nav',\n 'noframes',\n 'ol',\n 'optgroup',\n 'option',\n 'p',\n 'param',\n 'section',\n 'summary',\n 'table',\n 'tbody',\n 'td',\n 'tfoot',\n 'th',\n 'thead',\n 'title',\n 'tr',\n 'track',\n 'ul'\n]\n\n/**\n * List of lowercase HTML tag names which when parsing HTML (flow), result in\n * HTML that can include lines w/o exiting, until a closing tag also in this\n * list is found (condition 1).\n *\n * This module is copied from:\n * .\n *\n * Note that `textarea` was added in `CommonMark@0.30`.\n */\nexport const htmlRawNames = ['pre', 'script', 'style', 'textarea']\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {\n asciiAlpha,\n asciiAlphanumeric,\n markdownLineEnding,\n markdownLineEndingOrSpace,\n markdownSpace\n} from 'micromark-util-character'\nimport {htmlBlockNames, htmlRawNames} from 'micromark-util-html-tag-name'\nimport {blankLine} from './blank-line.js'\n/** @type {Construct} */\n\nexport const htmlFlow = {\n name: 'htmlFlow',\n tokenize: tokenizeHtmlFlow,\n resolveTo: resolveToHtmlFlow,\n concrete: true\n}\n/** @type {Construct} */\n\nconst nextBlankConstruct = {\n tokenize: tokenizeNextBlank,\n partial: true\n}\n/** @type {Resolver} */\n\nfunction resolveToHtmlFlow(events) {\n let index = events.length\n\n while (index--) {\n if (events[index][0] === 'enter' && events[index][1].type === 'htmlFlow') {\n break\n }\n }\n\n if (index > 1 && events[index - 2][1].type === 'linePrefix') {\n // Add the prefix start to the HTML token.\n events[index][1].start = events[index - 2][1].start // Add the prefix start to the HTML line token.\n\n events[index + 1][1].start = events[index - 2][1].start // Remove the line prefix.\n\n events.splice(index - 2, 2)\n }\n\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHtmlFlow(effects, ok, nok) {\n const self = this\n /** @type {number} */\n\n let kind\n /** @type {boolean} */\n\n let startTag\n /** @type {string} */\n\n let buffer\n /** @type {number} */\n\n let index\n /** @type {Code} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('htmlFlow')\n effects.enter('htmlFlowData')\n effects.consume(code)\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 33) {\n effects.consume(code)\n return declarationStart\n }\n\n if (code === 47) {\n effects.consume(code)\n return tagCloseStart\n }\n\n if (code === 63) {\n effects.consume(code)\n kind = 3 // While we\u2019re in an instruction instead of a declaration, we\u2019re on a `?`\n // right now, so we do need to search for `>`, similar to declarations.\n\n return self.interrupt ? ok : continuationDeclarationInside\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n buffer = String.fromCharCode(code)\n startTag = true\n return tagName\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function declarationStart(code) {\n if (code === 45) {\n effects.consume(code)\n kind = 2\n return commentOpenInside\n }\n\n if (code === 91) {\n effects.consume(code)\n kind = 5\n buffer = 'CDATA['\n index = 0\n return cdataOpenInside\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n kind = 4\n return self.interrupt ? ok : continuationDeclarationInside\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function commentOpenInside(code) {\n if (code === 45) {\n effects.consume(code)\n return self.interrupt ? ok : continuationDeclarationInside\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function cdataOpenInside(code) {\n if (code === buffer.charCodeAt(index++)) {\n effects.consume(code)\n return index === buffer.length\n ? self.interrupt\n ? ok\n : continuation\n : cdataOpenInside\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagCloseStart(code) {\n if (asciiAlpha(code)) {\n effects.consume(code)\n buffer = String.fromCharCode(code)\n return tagName\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagName(code) {\n if (\n code === null ||\n code === 47 ||\n code === 62 ||\n markdownLineEndingOrSpace(code)\n ) {\n if (\n code !== 47 &&\n startTag &&\n htmlRawNames.includes(buffer.toLowerCase())\n ) {\n kind = 1\n return self.interrupt ? ok(code) : continuation(code)\n }\n\n if (htmlBlockNames.includes(buffer.toLowerCase())) {\n kind = 6\n\n if (code === 47) {\n effects.consume(code)\n return basicSelfClosing\n }\n\n return self.interrupt ? ok(code) : continuation(code)\n }\n\n kind = 7 // Do not support complete HTML when interrupting\n\n return self.interrupt && !self.parser.lazy[self.now().line]\n ? nok(code)\n : startTag\n ? completeAttributeNameBefore(code)\n : completeClosingTagAfter(code)\n }\n\n if (code === 45 || asciiAlphanumeric(code)) {\n effects.consume(code)\n buffer += String.fromCharCode(code)\n return tagName\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function basicSelfClosing(code) {\n if (code === 62) {\n effects.consume(code)\n return self.interrupt ? ok : continuation\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function completeClosingTagAfter(code) {\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeClosingTagAfter\n }\n\n return completeEnd(code)\n }\n /** @type {State} */\n\n function completeAttributeNameBefore(code) {\n if (code === 47) {\n effects.consume(code)\n return completeEnd\n }\n\n if (code === 58 || code === 95 || asciiAlpha(code)) {\n effects.consume(code)\n return completeAttributeName\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAttributeNameBefore\n }\n\n return completeEnd(code)\n }\n /** @type {State} */\n\n function completeAttributeName(code) {\n if (\n code === 45 ||\n code === 46 ||\n code === 58 ||\n code === 95 ||\n asciiAlphanumeric(code)\n ) {\n effects.consume(code)\n return completeAttributeName\n }\n\n return completeAttributeNameAfter(code)\n }\n /** @type {State} */\n\n function completeAttributeNameAfter(code) {\n if (code === 61) {\n effects.consume(code)\n return completeAttributeValueBefore\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAttributeNameAfter\n }\n\n return completeAttributeNameBefore(code)\n }\n /** @type {State} */\n\n function completeAttributeValueBefore(code) {\n if (\n code === null ||\n code === 60 ||\n code === 61 ||\n code === 62 ||\n code === 96\n ) {\n return nok(code)\n }\n\n if (code === 34 || code === 39) {\n effects.consume(code)\n marker = code\n return completeAttributeValueQuoted\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAttributeValueBefore\n }\n\n marker = null\n return completeAttributeValueUnquoted(code)\n }\n /** @type {State} */\n\n function completeAttributeValueQuoted(code) {\n if (code === null || markdownLineEnding(code)) {\n return nok(code)\n }\n\n if (code === marker) {\n effects.consume(code)\n return completeAttributeValueQuotedAfter\n }\n\n effects.consume(code)\n return completeAttributeValueQuoted\n }\n /** @type {State} */\n\n function completeAttributeValueUnquoted(code) {\n if (\n code === null ||\n code === 34 ||\n code === 39 ||\n code === 60 ||\n code === 61 ||\n code === 62 ||\n code === 96 ||\n markdownLineEndingOrSpace(code)\n ) {\n return completeAttributeNameAfter(code)\n }\n\n effects.consume(code)\n return completeAttributeValueUnquoted\n }\n /** @type {State} */\n\n function completeAttributeValueQuotedAfter(code) {\n if (code === 47 || code === 62 || markdownSpace(code)) {\n return completeAttributeNameBefore(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function completeEnd(code) {\n if (code === 62) {\n effects.consume(code)\n return completeAfter\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function completeAfter(code) {\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAfter\n }\n\n return code === null || markdownLineEnding(code)\n ? continuation(code)\n : nok(code)\n }\n /** @type {State} */\n\n function continuation(code) {\n if (code === 45 && kind === 2) {\n effects.consume(code)\n return continuationCommentInside\n }\n\n if (code === 60 && kind === 1) {\n effects.consume(code)\n return continuationRawTagOpen\n }\n\n if (code === 62 && kind === 4) {\n effects.consume(code)\n return continuationClose\n }\n\n if (code === 63 && kind === 3) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n if (code === 93 && kind === 5) {\n effects.consume(code)\n return continuationCharacterDataInside\n }\n\n if (markdownLineEnding(code) && (kind === 6 || kind === 7)) {\n return effects.check(\n nextBlankConstruct,\n continuationClose,\n continuationAtLineEnding\n )(code)\n }\n\n if (code === null || markdownLineEnding(code)) {\n return continuationAtLineEnding(code)\n }\n\n effects.consume(code)\n return continuation\n }\n /** @type {State} */\n\n function continuationAtLineEnding(code) {\n effects.exit('htmlFlowData')\n return htmlContinueStart(code)\n }\n /** @type {State} */\n\n function htmlContinueStart(code) {\n if (code === null) {\n return done(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.attempt(\n {\n tokenize: htmlLineEnd,\n partial: true\n },\n htmlContinueStart,\n done\n )(code)\n }\n\n effects.enter('htmlFlowData')\n return continuation(code)\n }\n /** @type {Tokenizer} */\n\n function htmlLineEnd(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return lineStart\n }\n /** @type {State} */\n\n function lineStart(code) {\n return self.parser.lazy[self.now().line] ? nok(code) : ok(code)\n }\n }\n /** @type {State} */\n\n function continuationCommentInside(code) {\n if (code === 45) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationRawTagOpen(code) {\n if (code === 47) {\n effects.consume(code)\n buffer = ''\n return continuationRawEndTag\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationRawEndTag(code) {\n if (code === 62 && htmlRawNames.includes(buffer.toLowerCase())) {\n effects.consume(code)\n return continuationClose\n }\n\n if (asciiAlpha(code) && buffer.length < 8) {\n effects.consume(code)\n buffer += String.fromCharCode(code)\n return continuationRawEndTag\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationCharacterDataInside(code) {\n if (code === 93) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationDeclarationInside(code) {\n if (code === 62) {\n effects.consume(code)\n return continuationClose\n } // More dashes.\n\n if (code === 45 && kind === 2) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationClose(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('htmlFlowData')\n return done(code)\n }\n\n effects.consume(code)\n return continuationClose\n }\n /** @type {State} */\n\n function done(code) {\n effects.exit('htmlFlow')\n return ok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeNextBlank(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.exit('htmlFlowData')\n effects.enter('lineEndingBlank')\n effects.consume(code)\n effects.exit('lineEndingBlank')\n return effects.attempt(blankLine, ok, nok)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {\n asciiAlpha,\n asciiAlphanumeric,\n markdownLineEnding,\n markdownLineEndingOrSpace,\n markdownSpace\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const htmlText = {\n name: 'htmlText',\n tokenize: tokenizeHtmlText\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHtmlText(effects, ok, nok) {\n const self = this\n /** @type {NonNullable|undefined} */\n\n let marker\n /** @type {string} */\n\n let buffer\n /** @type {number} */\n\n let index\n /** @type {State} */\n\n let returnState\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('htmlText')\n effects.enter('htmlTextData')\n effects.consume(code)\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 33) {\n effects.consume(code)\n return declarationOpen\n }\n\n if (code === 47) {\n effects.consume(code)\n return tagCloseStart\n }\n\n if (code === 63) {\n effects.consume(code)\n return instruction\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n return tagOpen\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function declarationOpen(code) {\n if (code === 45) {\n effects.consume(code)\n return commentOpen\n }\n\n if (code === 91) {\n effects.consume(code)\n buffer = 'CDATA['\n index = 0\n return cdataOpen\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n return declaration\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function commentOpen(code) {\n if (code === 45) {\n effects.consume(code)\n return commentStart\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function commentStart(code) {\n if (code === null || code === 62) {\n return nok(code)\n }\n\n if (code === 45) {\n effects.consume(code)\n return commentStartDash\n }\n\n return comment(code)\n }\n /** @type {State} */\n\n function commentStartDash(code) {\n if (code === null || code === 62) {\n return nok(code)\n }\n\n return comment(code)\n }\n /** @type {State} */\n\n function comment(code) {\n if (code === null) {\n return nok(code)\n }\n\n if (code === 45) {\n effects.consume(code)\n return commentClose\n }\n\n if (markdownLineEnding(code)) {\n returnState = comment\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return comment\n }\n /** @type {State} */\n\n function commentClose(code) {\n if (code === 45) {\n effects.consume(code)\n return end\n }\n\n return comment(code)\n }\n /** @type {State} */\n\n function cdataOpen(code) {\n if (code === buffer.charCodeAt(index++)) {\n effects.consume(code)\n return index === buffer.length ? cdata : cdataOpen\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function cdata(code) {\n if (code === null) {\n return nok(code)\n }\n\n if (code === 93) {\n effects.consume(code)\n return cdataClose\n }\n\n if (markdownLineEnding(code)) {\n returnState = cdata\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return cdata\n }\n /** @type {State} */\n\n function cdataClose(code) {\n if (code === 93) {\n effects.consume(code)\n return cdataEnd\n }\n\n return cdata(code)\n }\n /** @type {State} */\n\n function cdataEnd(code) {\n if (code === 62) {\n return end(code)\n }\n\n if (code === 93) {\n effects.consume(code)\n return cdataEnd\n }\n\n return cdata(code)\n }\n /** @type {State} */\n\n function declaration(code) {\n if (code === null || code === 62) {\n return end(code)\n }\n\n if (markdownLineEnding(code)) {\n returnState = declaration\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return declaration\n }\n /** @type {State} */\n\n function instruction(code) {\n if (code === null) {\n return nok(code)\n }\n\n if (code === 63) {\n effects.consume(code)\n return instructionClose\n }\n\n if (markdownLineEnding(code)) {\n returnState = instruction\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return instruction\n }\n /** @type {State} */\n\n function instructionClose(code) {\n return code === 62 ? end(code) : instruction(code)\n }\n /** @type {State} */\n\n function tagCloseStart(code) {\n if (asciiAlpha(code)) {\n effects.consume(code)\n return tagClose\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagClose(code) {\n if (code === 45 || asciiAlphanumeric(code)) {\n effects.consume(code)\n return tagClose\n }\n\n return tagCloseBetween(code)\n }\n /** @type {State} */\n\n function tagCloseBetween(code) {\n if (markdownLineEnding(code)) {\n returnState = tagCloseBetween\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagCloseBetween\n }\n\n return end(code)\n }\n /** @type {State} */\n\n function tagOpen(code) {\n if (code === 45 || asciiAlphanumeric(code)) {\n effects.consume(code)\n return tagOpen\n }\n\n if (code === 47 || code === 62 || markdownLineEndingOrSpace(code)) {\n return tagOpenBetween(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagOpenBetween(code) {\n if (code === 47) {\n effects.consume(code)\n return end\n }\n\n if (code === 58 || code === 95 || asciiAlpha(code)) {\n effects.consume(code)\n return tagOpenAttributeName\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenBetween\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagOpenBetween\n }\n\n return end(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeName(code) {\n if (\n code === 45 ||\n code === 46 ||\n code === 58 ||\n code === 95 ||\n asciiAlphanumeric(code)\n ) {\n effects.consume(code)\n return tagOpenAttributeName\n }\n\n return tagOpenAttributeNameAfter(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeNameAfter(code) {\n if (code === 61) {\n effects.consume(code)\n return tagOpenAttributeValueBefore\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenAttributeNameAfter\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagOpenAttributeNameAfter\n }\n\n return tagOpenBetween(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeValueBefore(code) {\n if (\n code === null ||\n code === 60 ||\n code === 61 ||\n code === 62 ||\n code === 96\n ) {\n return nok(code)\n }\n\n if (code === 34 || code === 39) {\n effects.consume(code)\n marker = code\n return tagOpenAttributeValueQuoted\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenAttributeValueBefore\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagOpenAttributeValueBefore\n }\n\n effects.consume(code)\n marker = undefined\n return tagOpenAttributeValueUnquoted\n }\n /** @type {State} */\n\n function tagOpenAttributeValueQuoted(code) {\n if (code === marker) {\n effects.consume(code)\n return tagOpenAttributeValueQuotedAfter\n }\n\n if (code === null) {\n return nok(code)\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenAttributeValueQuoted\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return tagOpenAttributeValueQuoted\n }\n /** @type {State} */\n\n function tagOpenAttributeValueQuotedAfter(code) {\n if (code === 62 || code === 47 || markdownLineEndingOrSpace(code)) {\n return tagOpenBetween(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeValueUnquoted(code) {\n if (\n code === null ||\n code === 34 ||\n code === 39 ||\n code === 60 ||\n code === 61 ||\n code === 96\n ) {\n return nok(code)\n }\n\n if (code === 62 || markdownLineEndingOrSpace(code)) {\n return tagOpenBetween(code)\n }\n\n effects.consume(code)\n return tagOpenAttributeValueUnquoted\n } // We can\u2019t have blank lines in content, so no need to worry about empty\n // tokens.\n\n /** @type {State} */\n\n function atLineEnding(code) {\n effects.exit('htmlTextData')\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(\n effects,\n afterPrefix,\n 'linePrefix',\n self.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4\n )\n }\n /** @type {State} */\n\n function afterPrefix(code) {\n effects.enter('htmlTextData')\n return returnState(code)\n }\n /** @type {State} */\n\n function end(code) {\n if (code === 62) {\n effects.consume(code)\n effects.exit('htmlTextData')\n effects.exit('htmlText')\n return ok\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factoryDestination} from 'micromark-factory-destination'\nimport {factoryLabel} from 'micromark-factory-label'\nimport {factoryTitle} from 'micromark-factory-title'\nimport {factoryWhitespace} from 'micromark-factory-whitespace'\nimport {markdownLineEndingOrSpace} from 'micromark-util-character'\nimport {push, splice} from 'micromark-util-chunked'\nimport {normalizeIdentifier} from 'micromark-util-normalize-identifier'\nimport {resolveAll} from 'micromark-util-resolve-all'\n\n/** @type {Construct} */\nexport const labelEnd = {\n name: 'labelEnd',\n tokenize: tokenizeLabelEnd,\n resolveTo: resolveToLabelEnd,\n resolveAll: resolveAllLabelEnd\n}\n/** @type {Construct} */\n\nconst resourceConstruct = {\n tokenize: tokenizeResource\n}\n/** @type {Construct} */\n\nconst fullReferenceConstruct = {\n tokenize: tokenizeFullReference\n}\n/** @type {Construct} */\n\nconst collapsedReferenceConstruct = {\n tokenize: tokenizeCollapsedReference\n}\n/** @type {Resolver} */\n\nfunction resolveAllLabelEnd(events) {\n let index = -1\n /** @type {Token} */\n\n let token\n\n while (++index < events.length) {\n token = events[index][1]\n\n if (\n token.type === 'labelImage' ||\n token.type === 'labelLink' ||\n token.type === 'labelEnd'\n ) {\n // Remove the marker.\n events.splice(index + 1, token.type === 'labelImage' ? 4 : 2)\n token.type = 'data'\n index++\n }\n }\n\n return events\n}\n/** @type {Resolver} */\n\nfunction resolveToLabelEnd(events, context) {\n let index = events.length\n let offset = 0\n /** @type {Token} */\n\n let token\n /** @type {number|undefined} */\n\n let open\n /** @type {number|undefined} */\n\n let close\n /** @type {Event[]} */\n\n let media // Find an opening.\n\n while (index--) {\n token = events[index][1]\n\n if (open) {\n // If we see another link, or inactive link label, we\u2019ve been here before.\n if (\n token.type === 'link' ||\n (token.type === 'labelLink' && token._inactive)\n ) {\n break\n } // Mark other link openings as inactive, as we can\u2019t have links in\n // links.\n\n if (events[index][0] === 'enter' && token.type === 'labelLink') {\n token._inactive = true\n }\n } else if (close) {\n if (\n events[index][0] === 'enter' &&\n (token.type === 'labelImage' || token.type === 'labelLink') &&\n !token._balanced\n ) {\n open = index\n\n if (token.type !== 'labelLink') {\n offset = 2\n break\n }\n }\n } else if (token.type === 'labelEnd') {\n close = index\n }\n }\n\n const group = {\n type: events[open][1].type === 'labelLink' ? 'link' : 'image',\n start: Object.assign({}, events[open][1].start),\n end: Object.assign({}, events[events.length - 1][1].end)\n }\n const label = {\n type: 'label',\n start: Object.assign({}, events[open][1].start),\n end: Object.assign({}, events[close][1].end)\n }\n const text = {\n type: 'labelText',\n start: Object.assign({}, events[open + offset + 2][1].end),\n end: Object.assign({}, events[close - 2][1].start)\n }\n media = [\n ['enter', group, context],\n ['enter', label, context]\n ] // Opening marker.\n\n media = push(media, events.slice(open + 1, open + offset + 3)) // Text open.\n\n media = push(media, [['enter', text, context]]) // Between.\n\n media = push(\n media,\n resolveAll(\n context.parser.constructs.insideSpan.null,\n events.slice(open + offset + 4, close - 3),\n context\n )\n ) // Text close, marker close, label close.\n\n media = push(media, [\n ['exit', text, context],\n events[close - 2],\n events[close - 1],\n ['exit', label, context]\n ]) // Reference, resource, or so.\n\n media = push(media, events.slice(close + 1)) // Media close.\n\n media = push(media, [['exit', group, context]])\n splice(events, open, events.length, media)\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLabelEnd(effects, ok, nok) {\n const self = this\n let index = self.events.length\n /** @type {Token} */\n\n let labelStart\n /** @type {boolean} */\n\n let defined // Find an opening.\n\n while (index--) {\n if (\n (self.events[index][1].type === 'labelImage' ||\n self.events[index][1].type === 'labelLink') &&\n !self.events[index][1]._balanced\n ) {\n labelStart = self.events[index][1]\n break\n }\n }\n\n return start\n /** @type {State} */\n\n function start(code) {\n if (!labelStart) {\n return nok(code)\n } // It\u2019s a balanced bracket, but contains a link.\n\n if (labelStart._inactive) return balanced(code)\n defined = self.parser.defined.includes(\n normalizeIdentifier(\n self.sliceSerialize({\n start: labelStart.end,\n end: self.now()\n })\n )\n )\n effects.enter('labelEnd')\n effects.enter('labelMarker')\n effects.consume(code)\n effects.exit('labelMarker')\n effects.exit('labelEnd')\n return afterLabelEnd\n }\n /** @type {State} */\n\n function afterLabelEnd(code) {\n // Resource: `[asd](fgh)`.\n if (code === 40) {\n return effects.attempt(\n resourceConstruct,\n ok,\n defined ? ok : balanced\n )(code)\n } // Collapsed (`[asd][]`) or full (`[asd][fgh]`) reference?\n\n if (code === 91) {\n return effects.attempt(\n fullReferenceConstruct,\n ok,\n defined\n ? effects.attempt(collapsedReferenceConstruct, ok, balanced)\n : balanced\n )(code)\n } // Shortcut reference: `[asd]`?\n\n return defined ? ok(code) : balanced(code)\n }\n /** @type {State} */\n\n function balanced(code) {\n labelStart._balanced = true\n return nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeResource(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('resource')\n effects.enter('resourceMarker')\n effects.consume(code)\n effects.exit('resourceMarker')\n return factoryWhitespace(effects, open)\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 41) {\n return end(code)\n }\n\n return factoryDestination(\n effects,\n destinationAfter,\n nok,\n 'resourceDestination',\n 'resourceDestinationLiteral',\n 'resourceDestinationLiteralMarker',\n 'resourceDestinationRaw',\n 'resourceDestinationString',\n 32\n )(code)\n }\n /** @type {State} */\n\n function destinationAfter(code) {\n return markdownLineEndingOrSpace(code)\n ? factoryWhitespace(effects, between)(code)\n : end(code)\n }\n /** @type {State} */\n\n function between(code) {\n if (code === 34 || code === 39 || code === 40) {\n return factoryTitle(\n effects,\n factoryWhitespace(effects, end),\n nok,\n 'resourceTitle',\n 'resourceTitleMarker',\n 'resourceTitleString'\n )(code)\n }\n\n return end(code)\n }\n /** @type {State} */\n\n function end(code) {\n if (code === 41) {\n effects.enter('resourceMarker')\n effects.consume(code)\n effects.exit('resourceMarker')\n effects.exit('resource')\n return ok\n }\n\n return nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeFullReference(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n return factoryLabel.call(\n self,\n effects,\n afterLabel,\n nok,\n 'reference',\n 'referenceMarker',\n 'referenceString'\n )(code)\n }\n /** @type {State} */\n\n function afterLabel(code) {\n return self.parser.defined.includes(\n normalizeIdentifier(\n self.sliceSerialize(self.events[self.events.length - 1][1]).slice(1, -1)\n )\n )\n ? ok(code)\n : nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCollapsedReference(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('reference')\n effects.enter('referenceMarker')\n effects.consume(code)\n effects.exit('referenceMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 93) {\n effects.enter('referenceMarker')\n effects.consume(code)\n effects.exit('referenceMarker')\n effects.exit('reference')\n return ok\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {labelEnd} from './label-end.js'\n/** @type {Construct} */\n\nexport const labelStartImage = {\n name: 'labelStartImage',\n tokenize: tokenizeLabelStartImage,\n resolveAll: labelEnd.resolveAll\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLabelStartImage(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('labelImage')\n effects.enter('labelImageMarker')\n effects.consume(code)\n effects.exit('labelImageMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 91) {\n effects.enter('labelMarker')\n effects.consume(code)\n effects.exit('labelMarker')\n effects.exit('labelImage')\n return after\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n /* To do: remove in the future once we\u2019ve switched from\n * `micromark-extension-footnote` to `micromark-extension-gfm-footnote`,\n * which doesn\u2019t need this */\n\n /* Hidden footnotes hook */\n\n /* c8 ignore next 3 */\n return code === 94 && '_hiddenFootnoteSupport' in self.parser.constructs\n ? nok(code)\n : ok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {labelEnd} from './label-end.js'\n/** @type {Construct} */\n\nexport const labelStartLink = {\n name: 'labelStartLink',\n tokenize: tokenizeLabelStartLink,\n resolveAll: labelEnd.resolveAll\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLabelStartLink(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('labelLink')\n effects.enter('labelMarker')\n effects.consume(code)\n effects.exit('labelMarker')\n effects.exit('labelLink')\n return after\n }\n /** @type {State} */\n\n function after(code) {\n /* To do: remove in the future once we\u2019ve switched from\n * `micromark-extension-footnote` to `micromark-extension-gfm-footnote`,\n * which doesn\u2019t need this */\n\n /* Hidden footnotes hook. */\n\n /* c8 ignore next 3 */\n return code === 94 && '_hiddenFootnoteSupport' in self.parser.constructs\n ? nok(code)\n : ok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const lineEnding = {\n name: 'lineEnding',\n tokenize: tokenizeLineEnding\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLineEnding(effects, ok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, ok, 'linePrefix')\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding, markdownSpace} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const thematicBreak = {\n name: 'thematicBreak',\n tokenize: tokenizeThematicBreak\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeThematicBreak(effects, ok, nok) {\n let size = 0\n /** @type {NonNullable} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('thematicBreak')\n marker = code\n return atBreak(code)\n }\n /** @type {State} */\n\n function atBreak(code) {\n if (code === marker) {\n effects.enter('thematicBreakSequence')\n return sequence(code)\n }\n\n if (markdownSpace(code)) {\n return factorySpace(effects, atBreak, 'whitespace')(code)\n }\n\n if (size < 3 || (code !== null && !markdownLineEnding(code))) {\n return nok(code)\n }\n\n effects.exit('thematicBreak')\n return ok(code)\n }\n /** @type {State} */\n\n function sequence(code) {\n if (code === marker) {\n effects.consume(code)\n size++\n return sequence\n }\n\n effects.exit('thematicBreakSequence')\n return atBreak(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Exiter} Exiter\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\n\n/**\n * @typedef {Record & {marker: Code, type: string, size: number}} ListContainerState\n * @typedef {TokenizeContext & {containerState: ListContainerState}} TokenizeContextWithState\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {asciiDigit, markdownSpace} from 'micromark-util-character'\nimport {blankLine} from './blank-line.js'\nimport {thematicBreak} from './thematic-break.js'\n/** @type {Construct} */\n\nexport const list = {\n name: 'list',\n tokenize: tokenizeListStart,\n continuation: {\n tokenize: tokenizeListContinuation\n },\n exit: tokenizeListEnd\n}\n/** @type {Construct} */\n\nconst listItemPrefixWhitespaceConstruct = {\n tokenize: tokenizeListItemPrefixWhitespace,\n partial: true\n}\n/** @type {Construct} */\n\nconst indentConstruct = {\n tokenize: tokenizeIndent,\n partial: true\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListStart(effects, ok, nok) {\n const self = this\n const tail = self.events[self.events.length - 1]\n let initialSize =\n tail && tail[1].type === 'linePrefix'\n ? tail[2].sliceSerialize(tail[1], true).length\n : 0\n let size = 0\n return start\n /** @type {State} */\n\n function start(code) {\n const kind =\n self.containerState.type ||\n (code === 42 || code === 43 || code === 45\n ? 'listUnordered'\n : 'listOrdered')\n\n if (\n kind === 'listUnordered'\n ? !self.containerState.marker || code === self.containerState.marker\n : asciiDigit(code)\n ) {\n if (!self.containerState.type) {\n self.containerState.type = kind\n effects.enter(kind, {\n _container: true\n })\n }\n\n if (kind === 'listUnordered') {\n effects.enter('listItemPrefix')\n return code === 42 || code === 45\n ? effects.check(thematicBreak, nok, atMarker)(code)\n : atMarker(code)\n }\n\n if (!self.interrupt || code === 49) {\n effects.enter('listItemPrefix')\n effects.enter('listItemValue')\n return inside(code)\n }\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function inside(code) {\n if (asciiDigit(code) && ++size < 10) {\n effects.consume(code)\n return inside\n }\n\n if (\n (!self.interrupt || size < 2) &&\n (self.containerState.marker\n ? code === self.containerState.marker\n : code === 41 || code === 46)\n ) {\n effects.exit('listItemValue')\n return atMarker(code)\n }\n\n return nok(code)\n }\n /**\n * @type {State}\n **/\n\n function atMarker(code) {\n effects.enter('listItemMarker')\n effects.consume(code)\n effects.exit('listItemMarker')\n self.containerState.marker = self.containerState.marker || code\n return effects.check(\n blankLine, // Can\u2019t be empty when interrupting.\n self.interrupt ? nok : onBlank,\n effects.attempt(\n listItemPrefixWhitespaceConstruct,\n endOfPrefix,\n otherPrefix\n )\n )\n }\n /** @type {State} */\n\n function onBlank(code) {\n self.containerState.initialBlankLine = true\n initialSize++\n return endOfPrefix(code)\n }\n /** @type {State} */\n\n function otherPrefix(code) {\n if (markdownSpace(code)) {\n effects.enter('listItemPrefixWhitespace')\n effects.consume(code)\n effects.exit('listItemPrefixWhitespace')\n return endOfPrefix\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function endOfPrefix(code) {\n self.containerState.size =\n initialSize +\n self.sliceSerialize(effects.exit('listItemPrefix'), true).length\n return ok(code)\n }\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListContinuation(effects, ok, nok) {\n const self = this\n self.containerState._closeFlow = undefined\n return effects.check(blankLine, onBlank, notBlank)\n /** @type {State} */\n\n function onBlank(code) {\n self.containerState.furtherBlankLines =\n self.containerState.furtherBlankLines ||\n self.containerState.initialBlankLine // We have a blank line.\n // Still, try to consume at most the items size.\n\n return factorySpace(\n effects,\n ok,\n 'listItemIndent',\n self.containerState.size + 1\n )(code)\n }\n /** @type {State} */\n\n function notBlank(code) {\n if (self.containerState.furtherBlankLines || !markdownSpace(code)) {\n self.containerState.furtherBlankLines = undefined\n self.containerState.initialBlankLine = undefined\n return notInCurrentItem(code)\n }\n\n self.containerState.furtherBlankLines = undefined\n self.containerState.initialBlankLine = undefined\n return effects.attempt(indentConstruct, ok, notInCurrentItem)(code)\n }\n /** @type {State} */\n\n function notInCurrentItem(code) {\n // While we do continue, we signal that the flow should be closed.\n self.containerState._closeFlow = true // As we\u2019re closing flow, we\u2019re no longer interrupting.\n\n self.interrupt = undefined\n return factorySpace(\n effects,\n effects.attempt(list, ok, nok),\n 'linePrefix',\n self.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4\n )(code)\n }\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeIndent(effects, ok, nok) {\n const self = this\n return factorySpace(\n effects,\n afterPrefix,\n 'listItemIndent',\n self.containerState.size + 1\n )\n /** @type {State} */\n\n function afterPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return tail &&\n tail[1].type === 'listItemIndent' &&\n tail[2].sliceSerialize(tail[1], true).length === self.containerState.size\n ? ok(code)\n : nok(code)\n }\n}\n/**\n * @type {Exiter}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListEnd(effects) {\n effects.exit(this.containerState.type)\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListItemPrefixWhitespace(effects, ok, nok) {\n const self = this\n return factorySpace(\n effects,\n afterPrefix,\n 'listItemPrefixWhitespace',\n self.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4 + 1\n )\n /** @type {State} */\n\n function afterPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return !markdownSpace(code) &&\n tail &&\n tail[1].type === 'listItemPrefixWhitespace'\n ? ok(code)\n : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const setextUnderline = {\n name: 'setextUnderline',\n tokenize: tokenizeSetextUnderline,\n resolveTo: resolveToSetextUnderline\n}\n/** @type {Resolver} */\n\nfunction resolveToSetextUnderline(events, context) {\n let index = events.length\n /** @type {number|undefined} */\n\n let content\n /** @type {number|undefined} */\n\n let text\n /** @type {number|undefined} */\n\n let definition // Find the opening of the content.\n // It\u2019ll always exist: we don\u2019t tokenize if it isn\u2019t there.\n\n while (index--) {\n if (events[index][0] === 'enter') {\n if (events[index][1].type === 'content') {\n content = index\n break\n }\n\n if (events[index][1].type === 'paragraph') {\n text = index\n }\n } // Exit\n else {\n if (events[index][1].type === 'content') {\n // Remove the content end (if needed we\u2019ll add it later)\n events.splice(index, 1)\n }\n\n if (!definition && events[index][1].type === 'definition') {\n definition = index\n }\n }\n }\n\n const heading = {\n type: 'setextHeading',\n start: Object.assign({}, events[text][1].start),\n end: Object.assign({}, events[events.length - 1][1].end)\n } // Change the paragraph to setext heading text.\n\n events[text][1].type = 'setextHeadingText' // If we have definitions in the content, we\u2019ll keep on having content,\n // but we need move it.\n\n if (definition) {\n events.splice(text, 0, ['enter', heading, context])\n events.splice(definition + 1, 0, ['exit', events[content][1], context])\n events[content][1].end = Object.assign({}, events[definition][1].end)\n } else {\n events[content][1] = heading\n } // Add the heading exit at the end.\n\n events.push(['exit', heading, context])\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeSetextUnderline(effects, ok, nok) {\n const self = this\n let index = self.events.length\n /** @type {NonNullable} */\n\n let marker\n /** @type {boolean} */\n\n let paragraph // Find an opening.\n\n while (index--) {\n // Skip enter/exit of line ending, line prefix, and content.\n // We can now either have a definition or a paragraph.\n if (\n self.events[index][1].type !== 'lineEnding' &&\n self.events[index][1].type !== 'linePrefix' &&\n self.events[index][1].type !== 'content'\n ) {\n paragraph = self.events[index][1].type === 'paragraph'\n break\n }\n }\n\n return start\n /** @type {State} */\n\n function start(code) {\n if (!self.parser.lazy[self.now().line] && (self.interrupt || paragraph)) {\n effects.enter('setextHeadingLine')\n effects.enter('setextHeadingLineSequence')\n marker = code\n return closingSequence(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function closingSequence(code) {\n if (code === marker) {\n effects.consume(code)\n return closingSequence\n }\n\n effects.exit('setextHeadingLineSequence')\n return factorySpace(effects, closingSequenceEnd, 'lineSuffix')(code)\n }\n /** @type {State} */\n\n function closingSequenceEnd(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('setextHeadingLine')\n return ok(code)\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {blankLine, content} from 'micromark-core-commonmark'\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {InitialConstruct} */\nexport const flow = {\n tokenize: initializeFlow\n}\n/** @type {Initializer} */\n\nfunction initializeFlow(effects) {\n const self = this\n const initial = effects.attempt(\n // Try to parse a blank line.\n blankLine,\n atBlankEnding, // Try to parse initial flow (essentially, only code).\n effects.attempt(\n this.parser.constructs.flowInitial,\n afterConstruct,\n factorySpace(\n effects,\n effects.attempt(\n this.parser.constructs.flow,\n afterConstruct,\n effects.attempt(content, afterConstruct)\n ),\n 'linePrefix'\n )\n )\n )\n return initial\n /** @type {State} */\n\n function atBlankEnding(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('lineEndingBlank')\n effects.consume(code)\n effects.exit('lineEndingBlank')\n self.currentConstruct = undefined\n return initial\n }\n /** @type {State} */\n\n function afterConstruct(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n self.currentConstruct = undefined\n return initial\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nexport const resolver = {\n resolveAll: createResolver()\n}\nexport const string = initializeFactory('string')\nexport const text = initializeFactory('text')\n/**\n * @param {'string'|'text'} field\n * @returns {InitialConstruct}\n */\n\nfunction initializeFactory(field) {\n return {\n tokenize: initializeText,\n resolveAll: createResolver(\n field === 'text' ? resolveAllLineSuffixes : undefined\n )\n }\n /** @type {Initializer} */\n\n function initializeText(effects) {\n const self = this\n const constructs = this.parser.constructs[field]\n const text = effects.attempt(constructs, start, notText)\n return start\n /** @type {State} */\n\n function start(code) {\n return atBreak(code) ? text(code) : notText(code)\n }\n /** @type {State} */\n\n function notText(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('data')\n effects.consume(code)\n return data\n }\n /** @type {State} */\n\n function data(code) {\n if (atBreak(code)) {\n effects.exit('data')\n return text(code)\n } // Data.\n\n effects.consume(code)\n return data\n }\n /**\n * @param {Code} code\n * @returns {boolean}\n */\n\n function atBreak(code) {\n if (code === null) {\n return true\n }\n\n const list = constructs[code]\n let index = -1\n\n if (list) {\n while (++index < list.length) {\n const item = list[index]\n\n if (!item.previous || item.previous.call(self, self.previous)) {\n return true\n }\n }\n }\n\n return false\n }\n }\n}\n/**\n * @param {Resolver} [extraResolver]\n * @returns {Resolver}\n */\n\nfunction createResolver(extraResolver) {\n return resolveAllText\n /** @type {Resolver} */\n\n function resolveAllText(events, context) {\n let index = -1\n /** @type {number|undefined} */\n\n let enter // A rather boring computation (to merge adjacent `data` events) which\n // improves mm performance by 29%.\n\n while (++index <= events.length) {\n if (enter === undefined) {\n if (events[index] && events[index][1].type === 'data') {\n enter = index\n index++\n }\n } else if (!events[index] || events[index][1].type !== 'data') {\n // Don\u2019t do anything if there is one data token.\n if (index !== enter + 2) {\n events[enter][1].end = events[index - 1][1].end\n events.splice(enter + 2, index - enter - 2)\n index = enter + 2\n }\n\n enter = undefined\n }\n }\n\n return extraResolver ? extraResolver(events, context) : events\n }\n}\n/**\n * A rather ugly set of instructions which again looks at chunks in the input\n * stream.\n * The reason to do this here is that it is *much* faster to parse in reverse.\n * And that we can\u2019t hook into `null` to split the line suffix before an EOF.\n * To do: figure out if we can make this into a clean utility, or even in core.\n * As it will be useful for GFMs literal autolink extension (and maybe even\n * tables?)\n *\n * @type {Resolver}\n */\n\nfunction resolveAllLineSuffixes(events, context) {\n let eventIndex = 0 // Skip first.\n\n while (++eventIndex <= events.length) {\n if (\n (eventIndex === events.length ||\n events[eventIndex][1].type === 'lineEnding') &&\n events[eventIndex - 1][1].type === 'data'\n ) {\n const data = events[eventIndex - 1][1]\n const chunks = context.sliceStream(data)\n let index = chunks.length\n let bufferIndex = -1\n let size = 0\n /** @type {boolean|undefined} */\n\n let tabs\n\n while (index--) {\n const chunk = chunks[index]\n\n if (typeof chunk === 'string') {\n bufferIndex = chunk.length\n\n while (chunk.charCodeAt(bufferIndex - 1) === 32) {\n size++\n bufferIndex--\n }\n\n if (bufferIndex) break\n bufferIndex = -1\n } // Number\n else if (chunk === -2) {\n tabs = true\n size++\n } else if (chunk === -1) {\n // Empty\n } else {\n // Replacement character, exit.\n index++\n break\n }\n }\n\n if (size) {\n const token = {\n type:\n eventIndex === events.length || tabs || size < 2\n ? 'lineSuffix'\n : 'hardBreakTrailing',\n start: {\n line: data.end.line,\n column: data.end.column - size,\n offset: data.end.offset - size,\n _index: data.start._index + index,\n _bufferIndex: index\n ? bufferIndex\n : data.start._bufferIndex + bufferIndex\n },\n end: Object.assign({}, data.end)\n }\n data.end = Object.assign({}, token.start)\n\n if (data.start.offset === data.end.offset) {\n Object.assign(data, token)\n } else {\n events.splice(\n eventIndex,\n 0,\n ['enter', token, context],\n ['exit', token, context]\n )\n eventIndex += 2\n }\n }\n\n eventIndex++\n }\n }\n\n return events\n}\n", "/**\n * @typedef {import('micromark-util-types').Code} Code\n * @typedef {import('micromark-util-types').Chunk} Chunk\n * @typedef {import('micromark-util-types').Point} Point\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').ConstructRecord} ConstructRecord\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').ParseContext} ParseContext\n */\n\n/**\n * @typedef Info\n * @property {() => void} restore\n * @property {number} from\n *\n * @callback ReturnHandle\n * Handle a successful run.\n * @param {Construct} construct\n * @param {Info} info\n * @returns {void}\n */\nimport {markdownLineEnding} from 'micromark-util-character'\nimport {push, splice} from 'micromark-util-chunked'\nimport {resolveAll} from 'micromark-util-resolve-all'\n\n/**\n * Create a tokenizer.\n * Tokenizers deal with one type of data (e.g., containers, flow, text).\n * The parser is the object dealing with it all.\n * `initialize` works like other constructs, except that only its `tokenize`\n * function is used, in which case it doesn\u2019t receive an `ok` or `nok`.\n * `from` can be given to set the point before the first character, although\n * when further lines are indented, they must be set with `defineSkip`.\n *\n * @param {ParseContext} parser\n * @param {InitialConstruct} initialize\n * @param {Omit} [from]\n * @returns {TokenizeContext}\n */\nexport function createTokenizer(parser, initialize, from) {\n /** @type {Point} */\n let point = Object.assign(\n from\n ? Object.assign({}, from)\n : {\n line: 1,\n column: 1,\n offset: 0\n },\n {\n _index: 0,\n _bufferIndex: -1\n }\n )\n /** @type {Record} */\n\n const columnStart = {}\n /** @type {Array} */\n\n const resolveAllConstructs = []\n /** @type {Array} */\n\n let chunks = []\n /** @type {Array} */\n\n let stack = []\n /** @type {boolean|undefined} */\n\n let consumed = true\n /**\n * Tools used for tokenizing.\n *\n * @type {Effects}\n */\n\n const effects = {\n consume,\n enter,\n exit,\n attempt: constructFactory(onsuccessfulconstruct),\n check: constructFactory(onsuccessfulcheck),\n interrupt: constructFactory(onsuccessfulcheck, {\n interrupt: true\n })\n }\n /**\n * State and tools for resolving and serializing.\n *\n * @type {TokenizeContext}\n */\n\n const context = {\n previous: null,\n code: null,\n containerState: {},\n events: [],\n parser,\n sliceStream,\n sliceSerialize,\n now,\n defineSkip,\n write\n }\n /**\n * The state function.\n *\n * @type {State|void}\n */\n\n let state = initialize.tokenize.call(context, effects)\n /**\n * Track which character we expect to be consumed, to catch bugs.\n *\n * @type {Code}\n */\n\n let expectedCode\n\n if (initialize.resolveAll) {\n resolveAllConstructs.push(initialize)\n }\n\n return context\n /** @type {TokenizeContext['write']} */\n\n function write(slice) {\n chunks = push(chunks, slice)\n main() // Exit if we\u2019re not done, resolve might change stuff.\n\n if (chunks[chunks.length - 1] !== null) {\n return []\n }\n\n addResult(initialize, 0) // Otherwise, resolve, and exit.\n\n context.events = resolveAll(resolveAllConstructs, context.events, context)\n return context.events\n } //\n // Tools.\n //\n\n /** @type {TokenizeContext['sliceSerialize']} */\n\n function sliceSerialize(token, expandTabs) {\n return serializeChunks(sliceStream(token), expandTabs)\n }\n /** @type {TokenizeContext['sliceStream']} */\n\n function sliceStream(token) {\n return sliceChunks(chunks, token)\n }\n /** @type {TokenizeContext['now']} */\n\n function now() {\n return Object.assign({}, point)\n }\n /** @type {TokenizeContext['defineSkip']} */\n\n function defineSkip(value) {\n columnStart[value.line] = value.column\n accountForPotentialSkip()\n } //\n // State management.\n //\n\n /**\n * Main loop (note that `_index` and `_bufferIndex` in `point` are modified by\n * `consume`).\n * Here is where we walk through the chunks, which either include strings of\n * several characters, or numerical character codes.\n * The reason to do this in a loop instead of a call is so the stack can\n * drain.\n *\n * @returns {void}\n */\n\n function main() {\n /** @type {number} */\n let chunkIndex\n\n while (point._index < chunks.length) {\n const chunk = chunks[point._index] // If we\u2019re in a buffer chunk, loop through it.\n\n if (typeof chunk === 'string') {\n chunkIndex = point._index\n\n if (point._bufferIndex < 0) {\n point._bufferIndex = 0\n }\n\n while (\n point._index === chunkIndex &&\n point._bufferIndex < chunk.length\n ) {\n go(chunk.charCodeAt(point._bufferIndex))\n }\n } else {\n go(chunk)\n }\n }\n }\n /**\n * Deal with one code.\n *\n * @param {Code} code\n * @returns {void}\n */\n\n function go(code) {\n consumed = undefined\n expectedCode = code\n state = state(code)\n }\n /** @type {Effects['consume']} */\n\n function consume(code) {\n if (markdownLineEnding(code)) {\n point.line++\n point.column = 1\n point.offset += code === -3 ? 2 : 1\n accountForPotentialSkip()\n } else if (code !== -1) {\n point.column++\n point.offset++\n } // Not in a string chunk.\n\n if (point._bufferIndex < 0) {\n point._index++\n } else {\n point._bufferIndex++ // At end of string chunk.\n // @ts-expect-error Points w/ non-negative `_bufferIndex` reference\n // strings.\n\n if (point._bufferIndex === chunks[point._index].length) {\n point._bufferIndex = -1\n point._index++\n }\n } // Expose the previous character.\n\n context.previous = code // Mark as consumed.\n\n consumed = true\n }\n /** @type {Effects['enter']} */\n\n function enter(type, fields) {\n /** @type {Token} */\n // @ts-expect-error Patch instead of assign required fields to help GC.\n const token = fields || {}\n token.type = type\n token.start = now()\n context.events.push(['enter', token, context])\n stack.push(token)\n return token\n }\n /** @type {Effects['exit']} */\n\n function exit(type) {\n const token = stack.pop()\n token.end = now()\n context.events.push(['exit', token, context])\n return token\n }\n /**\n * Use results.\n *\n * @type {ReturnHandle}\n */\n\n function onsuccessfulconstruct(construct, info) {\n addResult(construct, info.from)\n }\n /**\n * Discard results.\n *\n * @type {ReturnHandle}\n */\n\n function onsuccessfulcheck(_, info) {\n info.restore()\n }\n /**\n * Factory to attempt/check/interrupt.\n *\n * @param {ReturnHandle} onreturn\n * @param {Record} [fields]\n */\n\n function constructFactory(onreturn, fields) {\n return hook\n /**\n * Handle either an object mapping codes to constructs, a list of\n * constructs, or a single construct.\n *\n * @param {Construct|Array|ConstructRecord} constructs\n * @param {State} returnState\n * @param {State} [bogusState]\n * @returns {State}\n */\n\n function hook(constructs, returnState, bogusState) {\n /** @type {Array} */\n let listOfConstructs\n /** @type {number} */\n\n let constructIndex\n /** @type {Construct} */\n\n let currentConstruct\n /** @type {Info} */\n\n let info\n return Array.isArray(constructs)\n ? /* c8 ignore next 1 */\n handleListOfConstructs(constructs)\n : 'tokenize' in constructs // @ts-expect-error Looks like a construct.\n ? handleListOfConstructs([constructs])\n : handleMapOfConstructs(constructs)\n /**\n * Handle a list of construct.\n *\n * @param {ConstructRecord} map\n * @returns {State}\n */\n\n function handleMapOfConstructs(map) {\n return start\n /** @type {State} */\n\n function start(code) {\n const def = code !== null && map[code]\n const all = code !== null && map.null\n const list = [\n // To do: add more extension tests.\n\n /* c8 ignore next 2 */\n ...(Array.isArray(def) ? def : def ? [def] : []),\n ...(Array.isArray(all) ? all : all ? [all] : [])\n ]\n return handleListOfConstructs(list)(code)\n }\n }\n /**\n * Handle a list of construct.\n *\n * @param {Array} list\n * @returns {State}\n */\n\n function handleListOfConstructs(list) {\n listOfConstructs = list\n constructIndex = 0\n\n if (list.length === 0) {\n return bogusState\n }\n\n return handleConstruct(list[constructIndex])\n }\n /**\n * Handle a single construct.\n *\n * @param {Construct} construct\n * @returns {State}\n */\n\n function handleConstruct(construct) {\n return start\n /** @type {State} */\n\n function start(code) {\n // To do: not needed to store if there is no bogus state, probably?\n // Currently doesn\u2019t work because `inspect` in document does a check\n // w/o a bogus, which doesn\u2019t make sense. But it does seem to help perf\n // by not storing.\n info = store()\n currentConstruct = construct\n\n if (!construct.partial) {\n context.currentConstruct = construct\n }\n\n if (\n construct.name &&\n context.parser.constructs.disable.null.includes(construct.name)\n ) {\n return nok(code)\n }\n\n return construct.tokenize.call(\n // If we do have fields, create an object w/ `context` as its\n // prototype.\n // This allows a \u201Clive binding\u201D, which is needed for `interrupt`.\n fields ? Object.assign(Object.create(context), fields) : context,\n effects,\n ok,\n nok\n )(code)\n }\n }\n /** @type {State} */\n\n function ok(code) {\n consumed = true\n onreturn(currentConstruct, info)\n return returnState\n }\n /** @type {State} */\n\n function nok(code) {\n consumed = true\n info.restore()\n\n if (++constructIndex < listOfConstructs.length) {\n return handleConstruct(listOfConstructs[constructIndex])\n }\n\n return bogusState\n }\n }\n }\n /**\n * @param {Construct} construct\n * @param {number} from\n * @returns {void}\n */\n\n function addResult(construct, from) {\n if (construct.resolveAll && !resolveAllConstructs.includes(construct)) {\n resolveAllConstructs.push(construct)\n }\n\n if (construct.resolve) {\n splice(\n context.events,\n from,\n context.events.length - from,\n construct.resolve(context.events.slice(from), context)\n )\n }\n\n if (construct.resolveTo) {\n context.events = construct.resolveTo(context.events, context)\n }\n }\n /**\n * Store state.\n *\n * @returns {Info}\n */\n\n function store() {\n const startPoint = now()\n const startPrevious = context.previous\n const startCurrentConstruct = context.currentConstruct\n const startEventsIndex = context.events.length\n const startStack = Array.from(stack)\n return {\n restore,\n from: startEventsIndex\n }\n /**\n * Restore state.\n *\n * @returns {void}\n */\n\n function restore() {\n point = startPoint\n context.previous = startPrevious\n context.currentConstruct = startCurrentConstruct\n context.events.length = startEventsIndex\n stack = startStack\n accountForPotentialSkip()\n }\n }\n /**\n * Move the current point a bit forward in the line when it\u2019s on a column\n * skip.\n *\n * @returns {void}\n */\n\n function accountForPotentialSkip() {\n if (point.line in columnStart && point.column < 2) {\n point.column = columnStart[point.line]\n point.offset += columnStart[point.line] - 1\n }\n }\n}\n/**\n * Get the chunks from a slice of chunks in the range of a token.\n *\n * @param {Array} chunks\n * @param {Pick} token\n * @returns {Array}\n */\n\nfunction sliceChunks(chunks, token) {\n const startIndex = token.start._index\n const startBufferIndex = token.start._bufferIndex\n const endIndex = token.end._index\n const endBufferIndex = token.end._bufferIndex\n /** @type {Array} */\n\n let view\n\n if (startIndex === endIndex) {\n // @ts-expect-error `_bufferIndex` is used on string chunks.\n view = [chunks[startIndex].slice(startBufferIndex, endBufferIndex)]\n } else {\n view = chunks.slice(startIndex, endIndex)\n\n if (startBufferIndex > -1) {\n // @ts-expect-error `_bufferIndex` is used on string chunks.\n view[0] = view[0].slice(startBufferIndex)\n }\n\n if (endBufferIndex > 0) {\n // @ts-expect-error `_bufferIndex` is used on string chunks.\n view.push(chunks[endIndex].slice(0, endBufferIndex))\n }\n }\n\n return view\n}\n/**\n * Get the string value of a slice of chunks.\n *\n * @param {Array} chunks\n * @param {boolean} [expandTabs=false]\n * @returns {string}\n */\n\nfunction serializeChunks(chunks, expandTabs) {\n let index = -1\n /** @type {Array} */\n\n const result = []\n /** @type {boolean|undefined} */\n\n let atTab\n\n while (++index < chunks.length) {\n const chunk = chunks[index]\n /** @type {string} */\n\n let value\n\n if (typeof chunk === 'string') {\n value = chunk\n } else\n switch (chunk) {\n case -5: {\n value = '\\r'\n break\n }\n\n case -4: {\n value = '\\n'\n break\n }\n\n case -3: {\n value = '\\r' + '\\n'\n break\n }\n\n case -2: {\n value = expandTabs ? ' ' : '\\t'\n break\n }\n\n case -1: {\n if (!expandTabs && atTab) continue\n value = ' '\n break\n }\n\n default: {\n // Currently only replacement character.\n value = String.fromCharCode(chunk)\n }\n }\n\n atTab = chunk === -2\n result.push(value)\n }\n\n return result.join('')\n}\n", "/**\n * @typedef {import('micromark-util-types').Extension} Extension\n */\nimport {\n attention,\n autolink,\n blockQuote,\n characterEscape,\n characterReference,\n codeFenced,\n codeIndented,\n codeText,\n definition,\n hardBreakEscape,\n headingAtx,\n htmlFlow,\n htmlText,\n labelEnd,\n labelStartImage,\n labelStartLink,\n lineEnding,\n list,\n setextUnderline,\n thematicBreak\n} from 'micromark-core-commonmark'\nimport {resolver as resolveText} from './initialize/text.js'\n/** @type {Extension['document']} */\n\nexport const document = {\n [42]: list,\n [43]: list,\n [45]: list,\n [48]: list,\n [49]: list,\n [50]: list,\n [51]: list,\n [52]: list,\n [53]: list,\n [54]: list,\n [55]: list,\n [56]: list,\n [57]: list,\n [62]: blockQuote\n}\n/** @type {Extension['contentInitial']} */\n\nexport const contentInitial = {\n [91]: definition\n}\n/** @type {Extension['flowInitial']} */\n\nexport const flowInitial = {\n [-2]: codeIndented,\n [-1]: codeIndented,\n [32]: codeIndented\n}\n/** @type {Extension['flow']} */\n\nexport const flow = {\n [35]: headingAtx,\n [42]: thematicBreak,\n [45]: [setextUnderline, thematicBreak],\n [60]: htmlFlow,\n [61]: setextUnderline,\n [95]: thematicBreak,\n [96]: codeFenced,\n [126]: codeFenced\n}\n/** @type {Extension['string']} */\n\nexport const string = {\n [38]: characterReference,\n [92]: characterEscape\n}\n/** @type {Extension['text']} */\n\nexport const text = {\n [-5]: lineEnding,\n [-4]: lineEnding,\n [-3]: lineEnding,\n [33]: labelStartImage,\n [38]: characterReference,\n [42]: attention,\n [60]: [autolink, htmlText],\n [91]: labelStartLink,\n [92]: [hardBreakEscape, characterEscape],\n [93]: labelEnd,\n [95]: attention,\n [96]: codeText\n}\n/** @type {Extension['insideSpan']} */\n\nexport const insideSpan = {\n null: [attention, resolveText]\n}\n/** @type {Extension['attentionMarkers']} */\n\nexport const attentionMarkers = {\n null: [42, 95]\n}\n/** @type {Extension['disable']} */\n\nexport const disable = {\n null: []\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').FullNormalizedExtension} FullNormalizedExtension\n * @typedef {import('micromark-util-types').ParseOptions} ParseOptions\n * @typedef {import('micromark-util-types').ParseContext} ParseContext\n * @typedef {import('micromark-util-types').Create} Create\n */\nimport {combineExtensions} from 'micromark-util-combine-extensions'\nimport {content} from './initialize/content.js'\nimport {document} from './initialize/document.js'\nimport {flow} from './initialize/flow.js'\nimport {text, string} from './initialize/text.js'\nimport {createTokenizer} from './create-tokenizer.js'\nimport * as defaultConstructs from './constructs.js'\n/**\n * @param {ParseOptions} [options]\n * @returns {ParseContext}\n */\n\nexport function parse(options = {}) {\n /** @type {FullNormalizedExtension} */\n // @ts-expect-error `defaultConstructs` is full, so the result will be too.\n const constructs = combineExtensions(\n // @ts-expect-error Same as above.\n [defaultConstructs].concat(options.extensions || [])\n )\n /** @type {ParseContext} */\n\n const parser = {\n defined: [],\n lazy: {},\n constructs,\n content: create(content),\n document: create(document),\n flow: create(flow),\n string: create(string),\n text: create(text)\n }\n return parser\n /**\n * @param {InitialConstruct} initial\n */\n\n function create(initial) {\n return creator\n /** @type {Create} */\n\n function creator(from) {\n return createTokenizer(parser, initial, from)\n }\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Encoding} Encoding\n * @typedef {import('micromark-util-types').Value} Value\n * @typedef {import('micromark-util-types').Chunk} Chunk\n * @typedef {import('micromark-util-types').Code} Code\n */\n\n/**\n * @callback Preprocessor\n * @param {Value} value\n * @param {Encoding} [encoding]\n * @param {boolean} [end=false]\n * @returns {Array}\n */\nconst search = /[\\0\\t\\n\\r]/g\n/**\n * @returns {Preprocessor}\n */\n\nexport function preprocess() {\n let column = 1\n let buffer = ''\n /** @type {boolean|undefined} */\n\n let start = true\n /** @type {boolean|undefined} */\n\n let atCarriageReturn\n return preprocessor\n /** @type {Preprocessor} */\n\n function preprocessor(value, encoding, end) {\n /** @type {Array} */\n const chunks = []\n /** @type {RegExpMatchArray|null} */\n\n let match\n /** @type {number} */\n\n let next\n /** @type {number} */\n\n let startPosition\n /** @type {number} */\n\n let endPosition\n /** @type {Code} */\n\n let code // @ts-expect-error `Buffer` does allow an encoding.\n\n value = buffer + value.toString(encoding)\n startPosition = 0\n buffer = ''\n\n if (start) {\n if (value.charCodeAt(0) === 65279) {\n startPosition++\n }\n\n start = undefined\n }\n\n while (startPosition < value.length) {\n search.lastIndex = startPosition\n match = search.exec(value)\n endPosition =\n match && match.index !== undefined ? match.index : value.length\n code = value.charCodeAt(endPosition)\n\n if (!match) {\n buffer = value.slice(startPosition)\n break\n }\n\n if (code === 10 && startPosition === endPosition && atCarriageReturn) {\n chunks.push(-3)\n atCarriageReturn = undefined\n } else {\n if (atCarriageReturn) {\n chunks.push(-5)\n atCarriageReturn = undefined\n }\n\n if (startPosition < endPosition) {\n chunks.push(value.slice(startPosition, endPosition))\n column += endPosition - startPosition\n }\n\n switch (code) {\n case 0: {\n chunks.push(65533)\n column++\n break\n }\n\n case 9: {\n next = Math.ceil(column / 4) * 4\n chunks.push(-2)\n\n while (column++ < next) chunks.push(-1)\n\n break\n }\n\n case 10: {\n chunks.push(-4)\n column = 1\n break\n }\n\n default: {\n atCarriageReturn = true\n column = 1\n }\n }\n }\n\n startPosition = endPosition + 1\n }\n\n if (end) {\n if (atCarriageReturn) chunks.push(-5)\n if (buffer) chunks.push(buffer)\n chunks.push(null)\n }\n\n return chunks\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Event} Event\n */\nimport {subtokenize} from 'micromark-util-subtokenize'\n/**\n * @param {Array} events\n * @returns {Array}\n */\n\nexport function postprocess(events) {\n while (!subtokenize(events)) {\n // Empty\n }\n\n return events\n}\n", "/**\n * Turn the number (in string form as either hexa- or plain decimal) coming from\n * a numeric character reference into a character.\n *\n * @param {string} value\n * Value to decode.\n * @param {number} base\n * Numeric base.\n * @returns {string}\n */\nexport function decodeNumericCharacterReference(value, base) {\n const code = Number.parseInt(value, base)\n\n if (\n // C0 except for HT, LF, FF, CR, space\n code < 9 ||\n code === 11 ||\n (code > 13 && code < 32) || // Control character (DEL) of the basic block and C1 controls.\n (code > 126 && code < 160) || // Lone high surrogates and low surrogates.\n (code > 55295 && code < 57344) || // Noncharacters.\n (code > 64975 && code < 65008) ||\n (code & 65535) === 65535 ||\n (code & 65535) === 65534 || // Out of range\n code > 1114111\n ) {\n return '\\uFFFD'\n }\n\n return String.fromCharCode(code)\n}\n", "import {decodeNamedCharacterReference} from 'decode-named-character-reference'\nimport {decodeNumericCharacterReference} from 'micromark-util-decode-numeric-character-reference'\nconst characterEscapeOrReference =\n /\\\\([!-/:-@[-`{-~])|&(#(?:\\d{1,7}|x[\\da-f]{1,6})|[\\da-z]{1,31});/gi\n/**\n * Utility to decode markdown strings (which occur in places such as fenced\n * code info strings, destinations, labels, and titles).\n * The \u201Cstring\u201D content type allows character escapes and -references.\n * This decodes those.\n *\n * @param {string} value\n * @returns {string}\n */\n\nexport function decodeString(value) {\n return value.replace(characterEscapeOrReference, decode)\n}\n/**\n * @param {string} $0\n * @param {string} $1\n * @param {string} $2\n * @returns {string}\n */\n\nfunction decode($0, $1, $2) {\n if ($1) {\n // Escape.\n return $1\n } // Reference.\n\n const head = $2.charCodeAt(0)\n\n if (head === 35) {\n const head = $2.charCodeAt(1)\n const hex = head === 120 || head === 88\n return decodeNumericCharacterReference($2.slice(hex ? 2 : 1), hex ? 16 : 10)\n }\n\n return decodeNamedCharacterReference($2) || $0\n}\n", "/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Point} Point\n * @typedef {import('unist').Position} Position\n */\n\n/**\n * @typedef NodeLike\n * @property {string} type\n * @property {PositionLike | null | undefined} [position]\n *\n * @typedef PositionLike\n * @property {PointLike | null | undefined} [start]\n * @property {PointLike | null | undefined} [end]\n *\n * @typedef PointLike\n * @property {number | null | undefined} [line]\n * @property {number | null | undefined} [column]\n * @property {number | null | undefined} [offset]\n */\n\n/**\n * Serialize the positional info of a point, position (start and end points),\n * or node.\n *\n * @param {Node | NodeLike | Position | PositionLike | Point | PointLike | null | undefined} [value]\n * Node, position, or point.\n * @returns {string}\n * Pretty printed positional info of a node (`string`).\n *\n * In the format of a range `ls:cs-le:ce` (when given `node` or `position`)\n * or a point `l:c` (when given `point`), where `l` stands for line, `c` for\n * column, `s` for `start`, and `e` for end.\n * An empty string (`''`) is returned if the given value is neither `node`,\n * `position`, nor `point`.\n */\nexport function stringifyPosition(value) {\n // Nothing.\n if (!value || typeof value !== 'object') {\n return ''\n }\n\n // Node.\n if ('position' in value || 'type' in value) {\n return position(value.position)\n }\n\n // Position.\n if ('start' in value || 'end' in value) {\n return position(value)\n }\n\n // Point.\n if ('line' in value || 'column' in value) {\n return point(value)\n }\n\n // ?\n return ''\n}\n\n/**\n * @param {Point | PointLike | null | undefined} point\n * @returns {string}\n */\nfunction point(point) {\n return index(point && point.line) + ':' + index(point && point.column)\n}\n\n/**\n * @param {Position | PositionLike | null | undefined} pos\n * @returns {string}\n */\nfunction position(pos) {\n return point(pos && pos.start) + '-' + point(pos && pos.end)\n}\n\n/**\n * @param {number | null | undefined} value\n * @returns {number}\n */\nfunction index(value) {\n return value && typeof value === 'number' ? value : 1\n}\n", "/**\n * @typedef {import('micromark-util-types').Encoding} Encoding\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').ParseOptions} ParseOptions\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Value} Value\n *\n * @typedef {import('unist').Parent} UnistParent\n * @typedef {import('unist').Point} Point\n *\n * @typedef {import('mdast').PhrasingContent} PhrasingContent\n * @typedef {import('mdast').StaticPhrasingContent} StaticPhrasingContent\n * @typedef {import('mdast').Content} Content\n * @typedef {import('mdast').Break} Break\n * @typedef {import('mdast').Blockquote} Blockquote\n * @typedef {import('mdast').Code} Code\n * @typedef {import('mdast').Definition} Definition\n * @typedef {import('mdast').Emphasis} Emphasis\n * @typedef {import('mdast').Heading} Heading\n * @typedef {import('mdast').HTML} HTML\n * @typedef {import('mdast').Image} Image\n * @typedef {import('mdast').ImageReference} ImageReference\n * @typedef {import('mdast').InlineCode} InlineCode\n * @typedef {import('mdast').Link} Link\n * @typedef {import('mdast').LinkReference} LinkReference\n * @typedef {import('mdast').List} List\n * @typedef {import('mdast').ListItem} ListItem\n * @typedef {import('mdast').Paragraph} Paragraph\n * @typedef {import('mdast').Root} Root\n * @typedef {import('mdast').Strong} Strong\n * @typedef {import('mdast').Text} Text\n * @typedef {import('mdast').ThematicBreak} ThematicBreak\n * @typedef {import('mdast').ReferenceType} ReferenceType\n * @typedef {import('../index.js').CompileData} CompileData\n */\n\n/**\n * @typedef {Root | Content} Node\n * @typedef {Extract} Parent\n *\n * @typedef {Omit & {type: 'fragment', children: Array}} Fragment\n */\n\n/**\n * @callback Transform\n * Extra transform, to change the AST afterwards.\n * @param {Root} tree\n * Tree to transform.\n * @returns {Root | undefined | null | void}\n * New tree or nothing (in which case the current tree is used).\n *\n * @callback Handle\n * Handle a token.\n * @param {CompileContext} this\n * Context.\n * @param {Token} token\n * Current token.\n * @returns {void}\n * Nothing.\n *\n * @typedef {Record} Handles\n * Token types mapping to handles\n *\n * @callback OnEnterError\n * Handle the case where the `right` token is open, but it is closed (by the\n * `left` token) or because we reached the end of the document.\n * @param {Omit} this\n * Context.\n * @param {Token | undefined} left\n * Left token.\n * @param {Token} right\n * Right token.\n * @returns {void}\n * Nothing.\n *\n * @callback OnExitError\n * Handle the case where the `right` token is open but it is closed by\n * exiting the `left` token.\n * @param {Omit} this\n * Context.\n * @param {Token} left\n * Left token.\n * @param {Token} right\n * Right token.\n * @returns {void}\n * Nothing.\n *\n * @typedef {[Token, OnEnterError | undefined]} TokenTuple\n * Open token on the stack, with an optional error handler for when\n * that token isn\u2019t closed properly.\n */\n\n/**\n * @typedef Config\n * Configuration.\n *\n * We have our defaults, but extensions will add more.\n * @property {Array} canContainEols\n * Token types where line endings are used.\n * @property {Handles} enter\n * Opening handles.\n * @property {Handles} exit\n * Closing handles.\n * @property {Array} transforms\n * Tree transforms.\n *\n * @typedef {Partial} Extension\n * Change how markdown tokens from micromark are turned into mdast.\n *\n * @typedef CompileContext\n * mdast compiler context.\n * @property {Array} stack\n * Stack of nodes.\n * @property {Array} tokenStack\n * Stack of tokens.\n * @property {(key: Key) => CompileData[Key]} getData\n * Get data from the key/value store.\n * @property {(key: Key, value?: CompileData[Key]) => void} setData\n * Set data into the key/value store.\n * @property {(this: CompileContext) => void} buffer\n * Capture some of the output data.\n * @property {(this: CompileContext) => string} resume\n * Stop capturing and access the output data.\n * @property {(this: CompileContext, node: Kind, token: Token, onError?: OnEnterError) => Kind} enter\n * Enter a token.\n * @property {(this: CompileContext, token: Token, onError?: OnExitError) => Node} exit\n * Exit a token.\n * @property {TokenizeContext['sliceSerialize']} sliceSerialize\n * Get the string value of a token.\n * @property {Config} config\n * Configuration.\n *\n * @typedef FromMarkdownOptions\n * Configuration for how to build mdast.\n * @property {Array> | null | undefined} [mdastExtensions]\n * Extensions for this utility to change how tokens are turned into a tree.\n *\n * @typedef {ParseOptions & FromMarkdownOptions} Options\n * Configuration.\n */\n\n// To do: micromark: create a registry of tokens?\n// To do: next major: don\u2019t return given `Node` from `enter`.\n// To do: next major: remove setter/getter.\n\nimport {toString} from 'mdast-util-to-string'\nimport {parse} from 'micromark/lib/parse.js'\nimport {preprocess} from 'micromark/lib/preprocess.js'\nimport {postprocess} from 'micromark/lib/postprocess.js'\nimport {decodeNumericCharacterReference} from 'micromark-util-decode-numeric-character-reference'\nimport {decodeString} from 'micromark-util-decode-string'\nimport {normalizeIdentifier} from 'micromark-util-normalize-identifier'\nimport {decodeNamedCharacterReference} from 'decode-named-character-reference'\nimport {stringifyPosition} from 'unist-util-stringify-position'\nconst own = {}.hasOwnProperty\n\n/**\n * @param value\n * Markdown to parse.\n * @param encoding\n * Character encoding for when `value` is `Buffer`.\n * @param options\n * Configuration.\n * @returns\n * mdast tree.\n */\nexport const fromMarkdown =\n /**\n * @type {(\n * ((value: Value, encoding: Encoding, options?: Options | null | undefined) => Root) &\n * ((value: Value, options?: Options | null | undefined) => Root)\n * )}\n */\n\n /**\n * @param {Value} value\n * @param {Encoding | Options | null | undefined} [encoding]\n * @param {Options | null | undefined} [options]\n * @returns {Root}\n */\n function (value, encoding, options) {\n if (typeof encoding !== 'string') {\n options = encoding\n encoding = undefined\n }\n return compiler(options)(\n postprocess(\n // @ts-expect-error: micromark types need to accept `null`.\n parse(options).document().write(preprocess()(value, encoding, true))\n )\n )\n }\n\n/**\n * Note this compiler only understand complete buffering, not streaming.\n *\n * @param {Options | null | undefined} [options]\n */\nfunction compiler(options) {\n /** @type {Config} */\n const config = {\n transforms: [],\n canContainEols: ['emphasis', 'fragment', 'heading', 'paragraph', 'strong'],\n enter: {\n autolink: opener(link),\n autolinkProtocol: onenterdata,\n autolinkEmail: onenterdata,\n atxHeading: opener(heading),\n blockQuote: opener(blockQuote),\n characterEscape: onenterdata,\n characterReference: onenterdata,\n codeFenced: opener(codeFlow),\n codeFencedFenceInfo: buffer,\n codeFencedFenceMeta: buffer,\n codeIndented: opener(codeFlow, buffer),\n codeText: opener(codeText, buffer),\n codeTextData: onenterdata,\n data: onenterdata,\n codeFlowValue: onenterdata,\n definition: opener(definition),\n definitionDestinationString: buffer,\n definitionLabelString: buffer,\n definitionTitleString: buffer,\n emphasis: opener(emphasis),\n hardBreakEscape: opener(hardBreak),\n hardBreakTrailing: opener(hardBreak),\n htmlFlow: opener(html, buffer),\n htmlFlowData: onenterdata,\n htmlText: opener(html, buffer),\n htmlTextData: onenterdata,\n image: opener(image),\n label: buffer,\n link: opener(link),\n listItem: opener(listItem),\n listItemValue: onenterlistitemvalue,\n listOrdered: opener(list, onenterlistordered),\n listUnordered: opener(list),\n paragraph: opener(paragraph),\n reference: onenterreference,\n referenceString: buffer,\n resourceDestinationString: buffer,\n resourceTitleString: buffer,\n setextHeading: opener(heading),\n strong: opener(strong),\n thematicBreak: opener(thematicBreak)\n },\n exit: {\n atxHeading: closer(),\n atxHeadingSequence: onexitatxheadingsequence,\n autolink: closer(),\n autolinkEmail: onexitautolinkemail,\n autolinkProtocol: onexitautolinkprotocol,\n blockQuote: closer(),\n characterEscapeValue: onexitdata,\n characterReferenceMarkerHexadecimal: onexitcharacterreferencemarker,\n characterReferenceMarkerNumeric: onexitcharacterreferencemarker,\n characterReferenceValue: onexitcharacterreferencevalue,\n codeFenced: closer(onexitcodefenced),\n codeFencedFence: onexitcodefencedfence,\n codeFencedFenceInfo: onexitcodefencedfenceinfo,\n codeFencedFenceMeta: onexitcodefencedfencemeta,\n codeFlowValue: onexitdata,\n codeIndented: closer(onexitcodeindented),\n codeText: closer(onexitcodetext),\n codeTextData: onexitdata,\n data: onexitdata,\n definition: closer(),\n definitionDestinationString: onexitdefinitiondestinationstring,\n definitionLabelString: onexitdefinitionlabelstring,\n definitionTitleString: onexitdefinitiontitlestring,\n emphasis: closer(),\n hardBreakEscape: closer(onexithardbreak),\n hardBreakTrailing: closer(onexithardbreak),\n htmlFlow: closer(onexithtmlflow),\n htmlFlowData: onexitdata,\n htmlText: closer(onexithtmltext),\n htmlTextData: onexitdata,\n image: closer(onexitimage),\n label: onexitlabel,\n labelText: onexitlabeltext,\n lineEnding: onexitlineending,\n link: closer(onexitlink),\n listItem: closer(),\n listOrdered: closer(),\n listUnordered: closer(),\n paragraph: closer(),\n referenceString: onexitreferencestring,\n resourceDestinationString: onexitresourcedestinationstring,\n resourceTitleString: onexitresourcetitlestring,\n resource: onexitresource,\n setextHeading: closer(onexitsetextheading),\n setextHeadingLineSequence: onexitsetextheadinglinesequence,\n setextHeadingText: onexitsetextheadingtext,\n strong: closer(),\n thematicBreak: closer()\n }\n }\n configure(config, (options || {}).mdastExtensions || [])\n\n /** @type {CompileData} */\n const data = {}\n return compile\n\n /**\n * Turn micromark events into an mdast tree.\n *\n * @param {Array} events\n * Events.\n * @returns {Root}\n * mdast tree.\n */\n function compile(events) {\n /** @type {Root} */\n let tree = {\n type: 'root',\n children: []\n }\n /** @type {Omit} */\n const context = {\n stack: [tree],\n tokenStack: [],\n config,\n enter,\n exit,\n buffer,\n resume,\n setData,\n getData\n }\n /** @type {Array} */\n const listStack = []\n let index = -1\n while (++index < events.length) {\n // We preprocess lists to add `listItem` tokens, and to infer whether\n // items the list itself are spread out.\n if (\n events[index][1].type === 'listOrdered' ||\n events[index][1].type === 'listUnordered'\n ) {\n if (events[index][0] === 'enter') {\n listStack.push(index)\n } else {\n const tail = listStack.pop()\n index = prepareList(events, tail, index)\n }\n }\n }\n index = -1\n while (++index < events.length) {\n const handler = config[events[index][0]]\n if (own.call(handler, events[index][1].type)) {\n handler[events[index][1].type].call(\n Object.assign(\n {\n sliceSerialize: events[index][2].sliceSerialize\n },\n context\n ),\n events[index][1]\n )\n }\n }\n\n // Handle tokens still being open.\n if (context.tokenStack.length > 0) {\n const tail = context.tokenStack[context.tokenStack.length - 1]\n const handler = tail[1] || defaultOnError\n handler.call(context, undefined, tail[0])\n }\n\n // Figure out `root` position.\n tree.position = {\n start: point(\n events.length > 0\n ? events[0][1].start\n : {\n line: 1,\n column: 1,\n offset: 0\n }\n ),\n end: point(\n events.length > 0\n ? events[events.length - 2][1].end\n : {\n line: 1,\n column: 1,\n offset: 0\n }\n )\n }\n\n // Call transforms.\n index = -1\n while (++index < config.transforms.length) {\n tree = config.transforms[index](tree) || tree\n }\n return tree\n }\n\n /**\n * @param {Array} events\n * @param {number} start\n * @param {number} length\n * @returns {number}\n */\n function prepareList(events, start, length) {\n let index = start - 1\n let containerBalance = -1\n let listSpread = false\n /** @type {Token | undefined} */\n let listItem\n /** @type {number | undefined} */\n let lineIndex\n /** @type {number | undefined} */\n let firstBlankLineIndex\n /** @type {boolean | undefined} */\n let atMarker\n while (++index <= length) {\n const event = events[index]\n if (\n event[1].type === 'listUnordered' ||\n event[1].type === 'listOrdered' ||\n event[1].type === 'blockQuote'\n ) {\n if (event[0] === 'enter') {\n containerBalance++\n } else {\n containerBalance--\n }\n atMarker = undefined\n } else if (event[1].type === 'lineEndingBlank') {\n if (event[0] === 'enter') {\n if (\n listItem &&\n !atMarker &&\n !containerBalance &&\n !firstBlankLineIndex\n ) {\n firstBlankLineIndex = index\n }\n atMarker = undefined\n }\n } else if (\n event[1].type === 'linePrefix' ||\n event[1].type === 'listItemValue' ||\n event[1].type === 'listItemMarker' ||\n event[1].type === 'listItemPrefix' ||\n event[1].type === 'listItemPrefixWhitespace'\n ) {\n // Empty.\n } else {\n atMarker = undefined\n }\n if (\n (!containerBalance &&\n event[0] === 'enter' &&\n event[1].type === 'listItemPrefix') ||\n (containerBalance === -1 &&\n event[0] === 'exit' &&\n (event[1].type === 'listUnordered' ||\n event[1].type === 'listOrdered'))\n ) {\n if (listItem) {\n let tailIndex = index\n lineIndex = undefined\n while (tailIndex--) {\n const tailEvent = events[tailIndex]\n if (\n tailEvent[1].type === 'lineEnding' ||\n tailEvent[1].type === 'lineEndingBlank'\n ) {\n if (tailEvent[0] === 'exit') continue\n if (lineIndex) {\n events[lineIndex][1].type = 'lineEndingBlank'\n listSpread = true\n }\n tailEvent[1].type = 'lineEnding'\n lineIndex = tailIndex\n } else if (\n tailEvent[1].type === 'linePrefix' ||\n tailEvent[1].type === 'blockQuotePrefix' ||\n tailEvent[1].type === 'blockQuotePrefixWhitespace' ||\n tailEvent[1].type === 'blockQuoteMarker' ||\n tailEvent[1].type === 'listItemIndent'\n ) {\n // Empty\n } else {\n break\n }\n }\n if (\n firstBlankLineIndex &&\n (!lineIndex || firstBlankLineIndex < lineIndex)\n ) {\n // @ts-expect-error Patched.\n listItem._spread = true\n }\n\n // Fix position.\n listItem.end = Object.assign(\n {},\n lineIndex ? events[lineIndex][1].start : event[1].end\n )\n events.splice(lineIndex || index, 0, ['exit', listItem, event[2]])\n index++\n length++\n }\n\n // Create a new list item.\n if (event[1].type === 'listItemPrefix') {\n listItem = {\n type: 'listItem',\n // @ts-expect-error Patched\n _spread: false,\n start: Object.assign({}, event[1].start)\n }\n // @ts-expect-error: `listItem` is most definitely defined, TS...\n events.splice(index, 0, ['enter', listItem, event[2]])\n index++\n length++\n firstBlankLineIndex = undefined\n atMarker = true\n }\n }\n }\n\n // @ts-expect-error Patched.\n events[start][1]._spread = listSpread\n return length\n }\n\n /**\n * Set data.\n *\n * @template {keyof CompileData} Key\n * Field type.\n * @param {Key} key\n * Key of field.\n * @param {CompileData[Key]} [value]\n * New value.\n * @returns {void}\n * Nothing.\n */\n function setData(key, value) {\n data[key] = value\n }\n\n /**\n * Get data.\n *\n * @template {keyof CompileData} Key\n * Field type.\n * @param {Key} key\n * Key of field.\n * @returns {CompileData[Key]}\n * Value.\n */\n function getData(key) {\n return data[key]\n }\n\n /**\n * Create an opener handle.\n *\n * @param {(token: Token) => Node} create\n * Create a node.\n * @param {Handle} [and]\n * Optional function to also run.\n * @returns {Handle}\n * Handle.\n */\n function opener(create, and) {\n return open\n\n /**\n * @this {CompileContext}\n * @param {Token} token\n * @returns {void}\n */\n function open(token) {\n enter.call(this, create(token), token)\n if (and) and.call(this, token)\n }\n }\n\n /**\n * @this {CompileContext}\n * @returns {void}\n */\n function buffer() {\n this.stack.push({\n type: 'fragment',\n children: []\n })\n }\n\n /**\n * @template {Node} Kind\n * Node type.\n * @this {CompileContext}\n * Context.\n * @param {Kind} node\n * Node to enter.\n * @param {Token} token\n * Corresponding token.\n * @param {OnEnterError | undefined} [errorHandler]\n * Handle the case where this token is open, but it is closed by something else.\n * @returns {Kind}\n * The given node.\n */\n function enter(node, token, errorHandler) {\n const parent = this.stack[this.stack.length - 1]\n // @ts-expect-error: Assume `Node` can exist as a child of `parent`.\n parent.children.push(node)\n this.stack.push(node)\n this.tokenStack.push([token, errorHandler])\n // @ts-expect-error: `end` will be patched later.\n node.position = {\n start: point(token.start)\n }\n return node\n }\n\n /**\n * Create a closer handle.\n *\n * @param {Handle} [and]\n * Optional function to also run.\n * @returns {Handle}\n * Handle.\n */\n function closer(and) {\n return close\n\n /**\n * @this {CompileContext}\n * @param {Token} token\n * @returns {void}\n */\n function close(token) {\n if (and) and.call(this, token)\n exit.call(this, token)\n }\n }\n\n /**\n * @this {CompileContext}\n * Context.\n * @param {Token} token\n * Corresponding token.\n * @param {OnExitError | undefined} [onExitError]\n * Handle the case where another token is open.\n * @returns {Node}\n * The closed node.\n */\n function exit(token, onExitError) {\n const node = this.stack.pop()\n const open = this.tokenStack.pop()\n if (!open) {\n throw new Error(\n 'Cannot close `' +\n token.type +\n '` (' +\n stringifyPosition({\n start: token.start,\n end: token.end\n }) +\n '): it\u2019s not open'\n )\n } else if (open[0].type !== token.type) {\n if (onExitError) {\n onExitError.call(this, token, open[0])\n } else {\n const handler = open[1] || defaultOnError\n handler.call(this, token, open[0])\n }\n }\n node.position.end = point(token.end)\n return node\n }\n\n /**\n * @this {CompileContext}\n * @returns {string}\n */\n function resume() {\n return toString(this.stack.pop())\n }\n\n //\n // Handlers.\n //\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onenterlistordered() {\n setData('expectingFirstListItemValue', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onenterlistitemvalue(token) {\n if (getData('expectingFirstListItemValue')) {\n const ancestor = this.stack[this.stack.length - 2]\n ancestor.start = Number.parseInt(this.sliceSerialize(token), 10)\n setData('expectingFirstListItemValue')\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefencedfenceinfo() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.lang = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefencedfencemeta() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.meta = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefencedfence() {\n // Exit if this is the closing fence.\n if (getData('flowCodeInside')) return\n this.buffer()\n setData('flowCodeInside', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefenced() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data.replace(/^(\\r?\\n|\\r)|(\\r?\\n|\\r)$/g, '')\n setData('flowCodeInside')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodeindented() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data.replace(/(\\r?\\n|\\r)$/g, '')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitdefinitionlabelstring(token) {\n const label = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.label = label\n node.identifier = normalizeIdentifier(\n this.sliceSerialize(token)\n ).toLowerCase()\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitdefinitiontitlestring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.title = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitdefinitiondestinationstring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.url = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitatxheadingsequence(token) {\n const node = this.stack[this.stack.length - 1]\n if (!node.depth) {\n const depth = this.sliceSerialize(token).length\n node.depth = depth\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitsetextheadingtext() {\n setData('setextHeadingSlurpLineEnding', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitsetextheadinglinesequence(token) {\n const node = this.stack[this.stack.length - 1]\n node.depth = this.sliceSerialize(token).charCodeAt(0) === 61 ? 1 : 2\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitsetextheading() {\n setData('setextHeadingSlurpLineEnding')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onenterdata(token) {\n const node = this.stack[this.stack.length - 1]\n let tail = node.children[node.children.length - 1]\n if (!tail || tail.type !== 'text') {\n // Add a new text node.\n tail = text()\n // @ts-expect-error: we\u2019ll add `end` later.\n tail.position = {\n start: point(token.start)\n }\n // @ts-expect-error: Assume `parent` accepts `text`.\n node.children.push(tail)\n }\n this.stack.push(tail)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitdata(token) {\n const tail = this.stack.pop()\n tail.value += this.sliceSerialize(token)\n tail.position.end = point(token.end)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlineending(token) {\n const context = this.stack[this.stack.length - 1]\n // If we\u2019re at a hard break, include the line ending in there.\n if (getData('atHardBreak')) {\n const tail = context.children[context.children.length - 1]\n tail.position.end = point(token.end)\n setData('atHardBreak')\n return\n }\n if (\n !getData('setextHeadingSlurpLineEnding') &&\n config.canContainEols.includes(context.type)\n ) {\n onenterdata.call(this, token)\n onexitdata.call(this, token)\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexithardbreak() {\n setData('atHardBreak', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexithtmlflow() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexithtmltext() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitcodetext() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlink() {\n const node = this.stack[this.stack.length - 1]\n // Note: there are also `identifier` and `label` fields on this link node!\n // These are used / cleaned here.\n\n // To do: clean.\n if (getData('inReference')) {\n /** @type {ReferenceType} */\n const referenceType = getData('referenceType') || 'shortcut'\n node.type += 'Reference'\n // @ts-expect-error: mutate.\n node.referenceType = referenceType\n // @ts-expect-error: mutate.\n delete node.url\n delete node.title\n } else {\n // @ts-expect-error: mutate.\n delete node.identifier\n // @ts-expect-error: mutate.\n delete node.label\n }\n setData('referenceType')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitimage() {\n const node = this.stack[this.stack.length - 1]\n // Note: there are also `identifier` and `label` fields on this link node!\n // These are used / cleaned here.\n\n // To do: clean.\n if (getData('inReference')) {\n /** @type {ReferenceType} */\n const referenceType = getData('referenceType') || 'shortcut'\n node.type += 'Reference'\n // @ts-expect-error: mutate.\n node.referenceType = referenceType\n // @ts-expect-error: mutate.\n delete node.url\n delete node.title\n } else {\n // @ts-expect-error: mutate.\n delete node.identifier\n // @ts-expect-error: mutate.\n delete node.label\n }\n setData('referenceType')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlabeltext(token) {\n const string = this.sliceSerialize(token)\n const ancestor = this.stack[this.stack.length - 2]\n // @ts-expect-error: stash this on the node, as it might become a reference\n // later.\n ancestor.label = decodeString(string)\n // @ts-expect-error: same as above.\n ancestor.identifier = normalizeIdentifier(string).toLowerCase()\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlabel() {\n const fragment = this.stack[this.stack.length - 1]\n const value = this.resume()\n const node = this.stack[this.stack.length - 1]\n // Assume a reference.\n setData('inReference', true)\n if (node.type === 'link') {\n /** @type {Array} */\n // @ts-expect-error: Assume static phrasing content.\n const children = fragment.children\n node.children = children\n } else {\n node.alt = value\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitresourcedestinationstring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.url = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitresourcetitlestring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.title = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitresource() {\n setData('inReference')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onenterreference() {\n setData('referenceType', 'collapsed')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitreferencestring(token) {\n const label = this.resume()\n const node = this.stack[this.stack.length - 1]\n // @ts-expect-error: stash this on the node, as it might become a reference\n // later.\n node.label = label\n // @ts-expect-error: same as above.\n node.identifier = normalizeIdentifier(\n this.sliceSerialize(token)\n ).toLowerCase()\n setData('referenceType', 'full')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitcharacterreferencemarker(token) {\n setData('characterReferenceType', token.type)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcharacterreferencevalue(token) {\n const data = this.sliceSerialize(token)\n const type = getData('characterReferenceType')\n /** @type {string} */\n let value\n if (type) {\n value = decodeNumericCharacterReference(\n data,\n type === 'characterReferenceMarkerNumeric' ? 10 : 16\n )\n setData('characterReferenceType')\n } else {\n const result = decodeNamedCharacterReference(data)\n value = result\n }\n const tail = this.stack.pop()\n tail.value += value\n tail.position.end = point(token.end)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitautolinkprotocol(token) {\n onexitdata.call(this, token)\n const node = this.stack[this.stack.length - 1]\n node.url = this.sliceSerialize(token)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitautolinkemail(token) {\n onexitdata.call(this, token)\n const node = this.stack[this.stack.length - 1]\n node.url = 'mailto:' + this.sliceSerialize(token)\n }\n\n //\n // Creaters.\n //\n\n /** @returns {Blockquote} */\n function blockQuote() {\n return {\n type: 'blockquote',\n children: []\n }\n }\n\n /** @returns {Code} */\n function codeFlow() {\n return {\n type: 'code',\n lang: null,\n meta: null,\n value: ''\n }\n }\n\n /** @returns {InlineCode} */\n function codeText() {\n return {\n type: 'inlineCode',\n value: ''\n }\n }\n\n /** @returns {Definition} */\n function definition() {\n return {\n type: 'definition',\n identifier: '',\n label: null,\n title: null,\n url: ''\n }\n }\n\n /** @returns {Emphasis} */\n function emphasis() {\n return {\n type: 'emphasis',\n children: []\n }\n }\n\n /** @returns {Heading} */\n function heading() {\n // @ts-expect-error `depth` will be set later.\n return {\n type: 'heading',\n depth: undefined,\n children: []\n }\n }\n\n /** @returns {Break} */\n function hardBreak() {\n return {\n type: 'break'\n }\n }\n\n /** @returns {HTML} */\n function html() {\n return {\n type: 'html',\n value: ''\n }\n }\n\n /** @returns {Image} */\n function image() {\n return {\n type: 'image',\n title: null,\n url: '',\n alt: null\n }\n }\n\n /** @returns {Link} */\n function link() {\n return {\n type: 'link',\n title: null,\n url: '',\n children: []\n }\n }\n\n /**\n * @param {Token} token\n * @returns {List}\n */\n function list(token) {\n return {\n type: 'list',\n ordered: token.type === 'listOrdered',\n start: null,\n // @ts-expect-error Patched.\n spread: token._spread,\n children: []\n }\n }\n\n /**\n * @param {Token} token\n * @returns {ListItem}\n */\n function listItem(token) {\n return {\n type: 'listItem',\n // @ts-expect-error Patched.\n spread: token._spread,\n checked: null,\n children: []\n }\n }\n\n /** @returns {Paragraph} */\n function paragraph() {\n return {\n type: 'paragraph',\n children: []\n }\n }\n\n /** @returns {Strong} */\n function strong() {\n return {\n type: 'strong',\n children: []\n }\n }\n\n /** @returns {Text} */\n function text() {\n return {\n type: 'text',\n value: ''\n }\n }\n\n /** @returns {ThematicBreak} */\n function thematicBreak() {\n return {\n type: 'thematicBreak'\n }\n }\n}\n\n/**\n * Copy a point-like value.\n *\n * @param {Point} d\n * Point-like value.\n * @returns {Point}\n * unist point.\n */\nfunction point(d) {\n return {\n line: d.line,\n column: d.column,\n offset: d.offset\n }\n}\n\n/**\n * @param {Config} combined\n * @param {Array>} extensions\n * @returns {void}\n */\nfunction configure(combined, extensions) {\n let index = -1\n while (++index < extensions.length) {\n const value = extensions[index]\n if (Array.isArray(value)) {\n configure(combined, value)\n } else {\n extension(combined, value)\n }\n }\n}\n\n/**\n * @param {Config} combined\n * @param {Extension} extension\n * @returns {void}\n */\nfunction extension(combined, extension) {\n /** @type {keyof Extension} */\n let key\n for (key in extension) {\n if (own.call(extension, key)) {\n if (key === 'canContainEols') {\n const right = extension[key]\n if (right) {\n combined[key].push(...right)\n }\n } else if (key === 'transforms') {\n const right = extension[key]\n if (right) {\n combined[key].push(...right)\n }\n } else if (key === 'enter' || key === 'exit') {\n const right = extension[key]\n if (right) {\n Object.assign(combined[key], right)\n }\n }\n }\n }\n}\n\n/** @type {OnEnterError} */\nfunction defaultOnError(left, right) {\n if (left) {\n throw new Error(\n 'Cannot close `' +\n left.type +\n '` (' +\n stringifyPosition({\n start: left.start,\n end: left.end\n }) +\n '): a different token (`' +\n right.type +\n '`, ' +\n stringifyPosition({\n start: right.start,\n end: right.end\n }) +\n ') is open'\n )\n } else {\n throw new Error(\n 'Cannot close document, a token (`' +\n right.type +\n '`, ' +\n stringifyPosition({\n start: right.start,\n end: right.end\n }) +\n ') is still open'\n )\n }\n}\n", "import { l as log, J as decodeEntities } from \"./mermaid-8af3addd.js\";\nimport { fromMarkdown } from \"mdast-util-from-markdown\";\nimport { dedent } from \"ts-dedent\";\nfunction preprocessMarkdown(markdown) {\n const withoutMultipleNewlines = markdown.replace(/\\n{2,}/g, \"\\n\");\n const withoutExtraSpaces = dedent(withoutMultipleNewlines);\n return withoutExtraSpaces;\n}\nfunction markdownToLines(markdown) {\n const preprocessedMarkdown = preprocessMarkdown(markdown);\n const { children } = fromMarkdown(preprocessedMarkdown);\n const lines = [[]];\n let currentLine = 0;\n function processNode(node, parentType = \"normal\") {\n if (node.type === \"text\") {\n const textLines = node.value.split(\"\\n\");\n textLines.forEach((textLine, index) => {\n if (index !== 0) {\n currentLine++;\n lines.push([]);\n }\n textLine.split(\" \").forEach((word) => {\n if (word) {\n lines[currentLine].push({ content: word, type: parentType });\n }\n });\n });\n } else if (node.type === \"strong\" || node.type === \"emphasis\") {\n node.children.forEach((contentNode) => {\n processNode(contentNode, node.type);\n });\n }\n }\n children.forEach((treeNode) => {\n if (treeNode.type === \"paragraph\") {\n treeNode.children.forEach((contentNode) => {\n processNode(contentNode);\n });\n }\n });\n return lines;\n}\nfunction markdownToHTML(markdown) {\n const { children } = fromMarkdown(markdown);\n function output(node) {\n if (node.type === \"text\") {\n return node.value.replace(/\\n/g, \"
      \");\n } else if (node.type === \"strong\") {\n return `${node.children.map(output).join(\"\")}`;\n } else if (node.type === \"emphasis\") {\n return `${node.children.map(output).join(\"\")}`;\n } else if (node.type === \"paragraph\") {\n return `

      ${node.children.map(output).join(\"\")}

      `;\n }\n return `Unsupported markdown: ${node.type}`;\n }\n return children.map(output).join(\"\");\n}\nfunction splitTextToChars(text) {\n if (Intl.Segmenter) {\n return [...new Intl.Segmenter().segment(text)].map((s) => s.segment);\n }\n return [...text];\n}\nfunction splitWordToFitWidth(checkFit, word) {\n const characters = splitTextToChars(word.content);\n return splitWordToFitWidthRecursion(checkFit, [], characters, word.type);\n}\nfunction splitWordToFitWidthRecursion(checkFit, usedChars, remainingChars, type) {\n if (remainingChars.length === 0) {\n return [\n { content: usedChars.join(\"\"), type },\n { content: \"\", type }\n ];\n }\n const [nextChar, ...rest] = remainingChars;\n const newWord = [...usedChars, nextChar];\n if (checkFit([{ content: newWord.join(\"\"), type }])) {\n return splitWordToFitWidthRecursion(checkFit, newWord, rest, type);\n }\n if (usedChars.length === 0 && nextChar) {\n usedChars.push(nextChar);\n remainingChars.shift();\n }\n return [\n { content: usedChars.join(\"\"), type },\n { content: remainingChars.join(\"\"), type }\n ];\n}\nfunction splitLineToFitWidth(line, checkFit) {\n if (line.some(({ content }) => content.includes(\"\\n\"))) {\n throw new Error(\"splitLineToFitWidth does not support newlines in the line\");\n }\n return splitLineToFitWidthRecursion(line, checkFit);\n}\nfunction splitLineToFitWidthRecursion(words, checkFit, lines = [], newLine = []) {\n if (words.length === 0) {\n if (newLine.length > 0) {\n lines.push(newLine);\n }\n return lines.length > 0 ? lines : [];\n }\n let joiner = \"\";\n if (words[0].content === \" \") {\n joiner = \" \";\n words.shift();\n }\n const nextWord = words.shift() ?? { content: \" \", type: \"normal\" };\n const lineWithNextWord = [...newLine];\n if (joiner !== \"\") {\n lineWithNextWord.push({ content: joiner, type: \"normal\" });\n }\n lineWithNextWord.push(nextWord);\n if (checkFit(lineWithNextWord)) {\n return splitLineToFitWidthRecursion(words, checkFit, lines, lineWithNextWord);\n }\n if (newLine.length > 0) {\n lines.push(newLine);\n words.unshift(nextWord);\n } else if (nextWord.content) {\n const [line, rest] = splitWordToFitWidth(checkFit, nextWord);\n lines.push([line]);\n if (rest.content) {\n words.unshift(rest);\n }\n }\n return splitLineToFitWidthRecursion(words, checkFit, lines);\n}\nfunction applyStyle(dom, styleFn) {\n if (styleFn) {\n dom.attr(\"style\", styleFn);\n }\n}\nfunction addHtmlSpan(element, node, width, classes, addBackground = false) {\n const fo = element.append(\"foreignObject\");\n const div = fo.append(\"xhtml:div\");\n const label = node.label;\n const labelClass = node.isNode ? \"nodeLabel\" : \"edgeLabel\";\n div.html(\n `\n \" + label + \"\"\n );\n applyStyle(div, node.labelStyle);\n div.style(\"display\", \"table-cell\");\n div.style(\"white-space\", \"nowrap\");\n div.style(\"max-width\", width + \"px\");\n div.attr(\"xmlns\", \"http://www.w3.org/1999/xhtml\");\n if (addBackground) {\n div.attr(\"class\", \"labelBkg\");\n }\n let bbox = div.node().getBoundingClientRect();\n if (bbox.width === width) {\n div.style(\"display\", \"table\");\n div.style(\"white-space\", \"break-spaces\");\n div.style(\"width\", width + \"px\");\n bbox = div.node().getBoundingClientRect();\n }\n fo.style(\"width\", bbox.width);\n fo.style(\"height\", bbox.height);\n return fo.node();\n}\nfunction createTspan(textElement, lineIndex, lineHeight) {\n return textElement.append(\"tspan\").attr(\"class\", \"text-outer-tspan\").attr(\"x\", 0).attr(\"y\", lineIndex * lineHeight - 0.1 + \"em\").attr(\"dy\", lineHeight + \"em\");\n}\nfunction computeWidthOfText(parentNode, lineHeight, line) {\n const testElement = parentNode.append(\"text\");\n const testSpan = createTspan(testElement, 1, lineHeight);\n updateTextContentAndStyles(testSpan, line);\n const textLength = testSpan.node().getComputedTextLength();\n testElement.remove();\n return textLength;\n}\nfunction computeDimensionOfText(parentNode, lineHeight, text) {\n var _a;\n const testElement = parentNode.append(\"text\");\n const testSpan = createTspan(testElement, 1, lineHeight);\n updateTextContentAndStyles(testSpan, [{ content: text, type: \"normal\" }]);\n const textDimension = (_a = testSpan.node()) == null ? void 0 : _a.getBoundingClientRect();\n if (textDimension) {\n testElement.remove();\n }\n return textDimension;\n}\nfunction createFormattedText(width, g, structuredText, addBackground = false) {\n const lineHeight = 1.1;\n const labelGroup = g.append(\"g\");\n const bkg = labelGroup.insert(\"rect\").attr(\"class\", \"background\");\n const textElement = labelGroup.append(\"text\").attr(\"y\", \"-10.1\");\n let lineIndex = 0;\n for (const line of structuredText) {\n const checkWidth = (line2) => computeWidthOfText(labelGroup, lineHeight, line2) <= width;\n const linesUnderWidth = checkWidth(line) ? [line] : splitLineToFitWidth(line, checkWidth);\n for (const preparedLine of linesUnderWidth) {\n const tspan = createTspan(textElement, lineIndex, lineHeight);\n updateTextContentAndStyles(tspan, preparedLine);\n lineIndex++;\n }\n }\n if (addBackground) {\n const bbox = textElement.node().getBBox();\n const padding = 2;\n bkg.attr(\"x\", -padding).attr(\"y\", -padding).attr(\"width\", bbox.width + 2 * padding).attr(\"height\", bbox.height + 2 * padding);\n return labelGroup.node();\n } else {\n return textElement.node();\n }\n}\nfunction updateTextContentAndStyles(tspan, wrappedLine) {\n tspan.text(\"\");\n wrappedLine.forEach((word, index) => {\n const innerTspan = tspan.append(\"tspan\").attr(\"font-style\", word.type === \"emphasis\" ? \"italic\" : \"normal\").attr(\"class\", \"text-inner-tspan\").attr(\"font-weight\", word.type === \"strong\" ? \"bold\" : \"normal\");\n if (index === 0) {\n innerTspan.text(word.content);\n } else {\n innerTspan.text(\" \" + word.content);\n }\n });\n}\nconst createText = (el, text = \"\", {\n style = \"\",\n isTitle = false,\n classes = \"\",\n useHtmlLabels = true,\n isNode = true,\n width = 200,\n addSvgBackground = false\n} = {}) => {\n log.info(\"createText\", text, style, isTitle, classes, useHtmlLabels, isNode, addSvgBackground);\n if (useHtmlLabels) {\n const htmlText = markdownToHTML(text);\n const node = {\n isNode,\n label: decodeEntities(htmlText).replace(\n /fa[blrs]?:fa-[\\w-]+/g,\n (s) => ``\n ),\n labelStyle: style.replace(\"fill:\", \"color:\")\n };\n const vertexNode = addHtmlSpan(el, node, width, classes, addSvgBackground);\n return vertexNode;\n } else {\n const structuredText = markdownToLines(text);\n const svgLabel = createFormattedText(width, el, structuredText, addSvgBackground);\n return svgLabel;\n }\n};\nexport {\n createText as a,\n computeDimensionOfText as c\n};\n"], + "sources": ["../../node_modules/mdast-util-to-string/lib/index.js", "../../node_modules/micromark-util-chunked/index.js", "../../node_modules/micromark-util-combine-extensions/index.js", "../../node_modules/micromark-util-character/lib/unicode-punctuation-regex.js", "../../node_modules/micromark-util-character/index.js", "../../node_modules/micromark-factory-space/index.js", "../../node_modules/micromark/lib/initialize/content.js", "../../node_modules/micromark/lib/initialize/document.js", "../../node_modules/micromark-util-classify-character/index.js", "../../node_modules/micromark-util-resolve-all/index.js", "../../node_modules/micromark-core-commonmark/lib/attention.js", "../../node_modules/micromark-core-commonmark/lib/autolink.js", "../../node_modules/micromark-core-commonmark/lib/blank-line.js", "../../node_modules/micromark-core-commonmark/lib/block-quote.js", "../../node_modules/micromark-core-commonmark/lib/character-escape.js", "../../node_modules/decode-named-character-reference/index.dom.js", "../../node_modules/micromark-core-commonmark/lib/character-reference.js", "../../node_modules/micromark-core-commonmark/lib/code-fenced.js", "../../node_modules/micromark-core-commonmark/lib/code-indented.js", "../../node_modules/micromark-core-commonmark/lib/code-text.js", "../../node_modules/micromark-util-subtokenize/index.js", "../../node_modules/micromark-core-commonmark/lib/content.js", "../../node_modules/micromark-factory-destination/index.js", "../../node_modules/micromark-factory-label/index.js", "../../node_modules/micromark-factory-title/index.js", "../../node_modules/micromark-factory-whitespace/index.js", "../../node_modules/micromark-util-normalize-identifier/index.js", "../../node_modules/micromark-core-commonmark/lib/definition.js", "../../node_modules/micromark-core-commonmark/lib/hard-break-escape.js", "../../node_modules/micromark-core-commonmark/lib/heading-atx.js", "../../node_modules/micromark-util-html-tag-name/index.js", "../../node_modules/micromark-core-commonmark/lib/html-flow.js", "../../node_modules/micromark-core-commonmark/lib/html-text.js", "../../node_modules/micromark-core-commonmark/lib/label-end.js", "../../node_modules/micromark-core-commonmark/lib/label-start-image.js", "../../node_modules/micromark-core-commonmark/lib/label-start-link.js", "../../node_modules/micromark-core-commonmark/lib/line-ending.js", "../../node_modules/micromark-core-commonmark/lib/thematic-break.js", "../../node_modules/micromark-core-commonmark/lib/list.js", "../../node_modules/micromark-core-commonmark/lib/setext-underline.js", "../../node_modules/micromark/lib/initialize/flow.js", "../../node_modules/micromark/lib/initialize/text.js", "../../node_modules/micromark/lib/create-tokenizer.js", "../../node_modules/micromark/lib/constructs.js", "../../node_modules/micromark/lib/parse.js", "../../node_modules/micromark/lib/preprocess.js", "../../node_modules/micromark/lib/postprocess.js", "../../node_modules/micromark-util-decode-numeric-character-reference/index.js", "../../node_modules/micromark-util-decode-string/index.js", "../../node_modules/unist-util-stringify-position/lib/index.js", "../../node_modules/mdast-util-from-markdown/lib/index.js", "../../node_modules/mermaid/dist/createText-aebacdfe.js"], + "sourcesContent": ["/**\n * @typedef {import('mdast').Root|import('mdast').Content} Node\n *\n * @typedef Options\n * Configuration (optional).\n * @property {boolean | null | undefined} [includeImageAlt=true]\n * Whether to use `alt` for `image`s.\n * @property {boolean | null | undefined} [includeHtml=true]\n * Whether to use `value` of HTML.\n */\n\n/** @type {Options} */\nconst emptyOptions = {}\n\n/**\n * Get the text content of a node or list of nodes.\n *\n * Prefers the node\u2019s plain-text fields, otherwise serializes its children,\n * and if the given value is an array, serialize the nodes in it.\n *\n * @param {unknown} value\n * Thing to serialize, typically `Node`.\n * @param {Options | null | undefined} [options]\n * Configuration (optional).\n * @returns {string}\n * Serialized `value`.\n */\nexport function toString(value, options) {\n const settings = options || emptyOptions\n const includeImageAlt =\n typeof settings.includeImageAlt === 'boolean'\n ? settings.includeImageAlt\n : true\n const includeHtml =\n typeof settings.includeHtml === 'boolean' ? settings.includeHtml : true\n\n return one(value, includeImageAlt, includeHtml)\n}\n\n/**\n * One node or several nodes.\n *\n * @param {unknown} value\n * Thing to serialize.\n * @param {boolean} includeImageAlt\n * Include image `alt`s.\n * @param {boolean} includeHtml\n * Include HTML.\n * @returns {string}\n * Serialized node.\n */\nfunction one(value, includeImageAlt, includeHtml) {\n if (node(value)) {\n if ('value' in value) {\n return value.type === 'html' && !includeHtml ? '' : value.value\n }\n\n if (includeImageAlt && 'alt' in value && value.alt) {\n return value.alt\n }\n\n if ('children' in value) {\n return all(value.children, includeImageAlt, includeHtml)\n }\n }\n\n if (Array.isArray(value)) {\n return all(value, includeImageAlt, includeHtml)\n }\n\n return ''\n}\n\n/**\n * Serialize a list of nodes.\n *\n * @param {Array} values\n * Thing to serialize.\n * @param {boolean} includeImageAlt\n * Include image `alt`s.\n * @param {boolean} includeHtml\n * Include HTML.\n * @returns {string}\n * Serialized nodes.\n */\nfunction all(values, includeImageAlt, includeHtml) {\n /** @type {Array} */\n const result = []\n let index = -1\n\n while (++index < values.length) {\n result[index] = one(values[index], includeImageAlt, includeHtml)\n }\n\n return result.join('')\n}\n\n/**\n * Check if `value` looks like a node.\n *\n * @param {unknown} value\n * Thing.\n * @returns {value is Node}\n * Whether `value` is a node.\n */\nfunction node(value) {\n return Boolean(value && typeof value === 'object')\n}\n", "/**\n * Like `Array#splice`, but smarter for giant arrays.\n *\n * `Array#splice` takes all items to be inserted as individual argument which\n * causes a stack overflow in V8 when trying to insert 100k items for instance.\n *\n * Otherwise, this does not return the removed items, and takes `items` as an\n * array instead of rest parameters.\n *\n * @template {unknown} T\n * @param {T[]} list\n * @param {number} start\n * @param {number} remove\n * @param {T[]} items\n * @returns {void}\n */\nexport function splice(list, start, remove, items) {\n const end = list.length\n let chunkStart = 0\n /** @type {unknown[]} */\n\n let parameters // Make start between zero and `end` (included).\n\n if (start < 0) {\n start = -start > end ? 0 : end + start\n } else {\n start = start > end ? end : start\n }\n\n remove = remove > 0 ? remove : 0 // No need to chunk the items if there\u2019s only a couple (10k) items.\n\n if (items.length < 10000) {\n parameters = Array.from(items)\n parameters.unshift(start, remove) // @ts-expect-error Hush, it\u2019s fine.\n ;[].splice.apply(list, parameters)\n } else {\n // Delete `remove` items starting from `start`\n if (remove) [].splice.apply(list, [start, remove]) // Insert the items in chunks to not cause stack overflows.\n\n while (chunkStart < items.length) {\n parameters = items.slice(chunkStart, chunkStart + 10000)\n parameters.unshift(start, 0) // @ts-expect-error Hush, it\u2019s fine.\n ;[].splice.apply(list, parameters)\n chunkStart += 10000\n start += 10000\n }\n }\n}\n/**\n * Append `items` (an array) at the end of `list` (another array).\n * When `list` was empty, returns `items` instead.\n *\n * This prevents a potentially expensive operation when `list` is empty,\n * and adds items in batches to prevent V8 from hanging.\n *\n * @template {unknown} T\n * @param {T[]} list\n * @param {T[]} items\n * @returns {T[]}\n */\n\nexport function push(list, items) {\n if (list.length > 0) {\n splice(list, list.length, 0, items)\n return list\n }\n\n return items\n}\n", "/**\n * @typedef {import('micromark-util-types').NormalizedExtension} NormalizedExtension\n * @typedef {import('micromark-util-types').Extension} Extension\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').HtmlExtension} HtmlExtension\n */\n\nimport {splice} from 'micromark-util-chunked'\n\nconst hasOwnProperty = {}.hasOwnProperty\n\n/**\n * Combine several syntax extensions into one.\n *\n * @param {Extension[]} extensions List of syntax extensions.\n * @returns {NormalizedExtension} A single combined extension.\n */\nexport function combineExtensions(extensions) {\n /** @type {NormalizedExtension} */\n const all = {}\n let index = -1\n\n while (++index < extensions.length) {\n syntaxExtension(all, extensions[index])\n }\n\n return all\n}\n\n/**\n * Merge `extension` into `all`.\n *\n * @param {NormalizedExtension} all Extension to merge into.\n * @param {Extension} extension Extension to merge.\n * @returns {void}\n */\nfunction syntaxExtension(all, extension) {\n /** @type {string} */\n let hook\n\n for (hook in extension) {\n const maybe = hasOwnProperty.call(all, hook) ? all[hook] : undefined\n const left = maybe || (all[hook] = {})\n const right = extension[hook]\n /** @type {string} */\n let code\n\n for (code in right) {\n if (!hasOwnProperty.call(left, code)) left[code] = []\n const value = right[code]\n constructs(\n // @ts-expect-error Looks like a list.\n left[code],\n Array.isArray(value) ? value : value ? [value] : []\n )\n }\n }\n}\n\n/**\n * Merge `list` into `existing` (both lists of constructs).\n * Mutates `existing`.\n *\n * @param {unknown[]} existing\n * @param {unknown[]} list\n * @returns {void}\n */\nfunction constructs(existing, list) {\n let index = -1\n /** @type {unknown[]} */\n const before = []\n\n while (++index < list.length) {\n // @ts-expect-error Looks like an object.\n ;(list[index].add === 'after' ? existing : before).push(list[index])\n }\n\n splice(existing, 0, 0, before)\n}\n\n/**\n * Combine several HTML extensions into one.\n *\n * @param {HtmlExtension[]} htmlExtensions List of HTML extensions.\n * @returns {HtmlExtension} A single combined extension.\n */\nexport function combineHtmlExtensions(htmlExtensions) {\n /** @type {HtmlExtension} */\n const handlers = {}\n let index = -1\n\n while (++index < htmlExtensions.length) {\n htmlExtension(handlers, htmlExtensions[index])\n }\n\n return handlers\n}\n\n/**\n * Merge `extension` into `all`.\n *\n * @param {HtmlExtension} all Extension to merge into.\n * @param {HtmlExtension} extension Extension to merge.\n * @returns {void}\n */\nfunction htmlExtension(all, extension) {\n /** @type {string} */\n let hook\n\n for (hook in extension) {\n const maybe = hasOwnProperty.call(all, hook) ? all[hook] : undefined\n const left = maybe || (all[hook] = {})\n const right = extension[hook]\n /** @type {string} */\n let type\n\n if (right) {\n for (type in right) {\n left[type] = right[type]\n }\n }\n }\n}\n", "// This module is generated by `script/`.\n//\n// CommonMark handles attention (emphasis, strong) markers based on what comes\n// before or after them.\n// One such difference is if those characters are Unicode punctuation.\n// This script is generated from the Unicode data.\nexport const unicodePunctuationRegex =\n /[!-/:-@[-`{-~\\u00A1\\u00A7\\u00AB\\u00B6\\u00B7\\u00BB\\u00BF\\u037E\\u0387\\u055A-\\u055F\\u0589\\u058A\\u05BE\\u05C0\\u05C3\\u05C6\\u05F3\\u05F4\\u0609\\u060A\\u060C\\u060D\\u061B\\u061E\\u061F\\u066A-\\u066D\\u06D4\\u0700-\\u070D\\u07F7-\\u07F9\\u0830-\\u083E\\u085E\\u0964\\u0965\\u0970\\u09FD\\u0A76\\u0AF0\\u0C77\\u0C84\\u0DF4\\u0E4F\\u0E5A\\u0E5B\\u0F04-\\u0F12\\u0F14\\u0F3A-\\u0F3D\\u0F85\\u0FD0-\\u0FD4\\u0FD9\\u0FDA\\u104A-\\u104F\\u10FB\\u1360-\\u1368\\u1400\\u166E\\u169B\\u169C\\u16EB-\\u16ED\\u1735\\u1736\\u17D4-\\u17D6\\u17D8-\\u17DA\\u1800-\\u180A\\u1944\\u1945\\u1A1E\\u1A1F\\u1AA0-\\u1AA6\\u1AA8-\\u1AAD\\u1B5A-\\u1B60\\u1BFC-\\u1BFF\\u1C3B-\\u1C3F\\u1C7E\\u1C7F\\u1CC0-\\u1CC7\\u1CD3\\u2010-\\u2027\\u2030-\\u2043\\u2045-\\u2051\\u2053-\\u205E\\u207D\\u207E\\u208D\\u208E\\u2308-\\u230B\\u2329\\u232A\\u2768-\\u2775\\u27C5\\u27C6\\u27E6-\\u27EF\\u2983-\\u2998\\u29D8-\\u29DB\\u29FC\\u29FD\\u2CF9-\\u2CFC\\u2CFE\\u2CFF\\u2D70\\u2E00-\\u2E2E\\u2E30-\\u2E4F\\u2E52\\u3001-\\u3003\\u3008-\\u3011\\u3014-\\u301F\\u3030\\u303D\\u30A0\\u30FB\\uA4FE\\uA4FF\\uA60D-\\uA60F\\uA673\\uA67E\\uA6F2-\\uA6F7\\uA874-\\uA877\\uA8CE\\uA8CF\\uA8F8-\\uA8FA\\uA8FC\\uA92E\\uA92F\\uA95F\\uA9C1-\\uA9CD\\uA9DE\\uA9DF\\uAA5C-\\uAA5F\\uAADE\\uAADF\\uAAF0\\uAAF1\\uABEB\\uFD3E\\uFD3F\\uFE10-\\uFE19\\uFE30-\\uFE52\\uFE54-\\uFE61\\uFE63\\uFE68\\uFE6A\\uFE6B\\uFF01-\\uFF03\\uFF05-\\uFF0A\\uFF0C-\\uFF0F\\uFF1A\\uFF1B\\uFF1F\\uFF20\\uFF3B-\\uFF3D\\uFF3F\\uFF5B\\uFF5D\\uFF5F-\\uFF65]/\n", "/**\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {unicodePunctuationRegex} from './lib/unicode-punctuation-regex.js'\n/**\n * Check whether the character code represents an ASCII alpha (`a` through `z`,\n * case insensitive).\n *\n * An **ASCII alpha** is an ASCII upper alpha or ASCII lower alpha.\n *\n * An **ASCII upper alpha** is a character in the inclusive range U+0041 (`A`)\n * to U+005A (`Z`).\n *\n * An **ASCII lower alpha** is a character in the inclusive range U+0061 (`a`)\n * to U+007A (`z`).\n */\n\nexport const asciiAlpha = regexCheck(/[A-Za-z]/)\n/**\n * Check whether the character code represents an ASCII digit (`0` through `9`).\n *\n * An **ASCII digit** is a character in the inclusive range U+0030 (`0`) to\n * U+0039 (`9`).\n */\n\nexport const asciiDigit = regexCheck(/\\d/)\n/**\n * Check whether the character code represents an ASCII hex digit (`a` through\n * `f`, case insensitive, or `0` through `9`).\n *\n * An **ASCII hex digit** is an ASCII digit (see `asciiDigit`), ASCII upper hex\n * digit, or an ASCII lower hex digit.\n *\n * An **ASCII upper hex digit** is a character in the inclusive range U+0041\n * (`A`) to U+0046 (`F`).\n *\n * An **ASCII lower hex digit** is a character in the inclusive range U+0061\n * (`a`) to U+0066 (`f`).\n */\n\nexport const asciiHexDigit = regexCheck(/[\\dA-Fa-f]/)\n/**\n * Check whether the character code represents an ASCII alphanumeric (`a`\n * through `z`, case insensitive, or `0` through `9`).\n *\n * An **ASCII alphanumeric** is an ASCII digit (see `asciiDigit`) or ASCII alpha\n * (see `asciiAlpha`).\n */\n\nexport const asciiAlphanumeric = regexCheck(/[\\dA-Za-z]/)\n/**\n * Check whether the character code represents ASCII punctuation.\n *\n * An **ASCII punctuation** is a character in the inclusive ranges U+0021\n * EXCLAMATION MARK (`!`) to U+002F SLASH (`/`), U+003A COLON (`:`) to U+0040 AT\n * SIGN (`@`), U+005B LEFT SQUARE BRACKET (`[`) to U+0060 GRAVE ACCENT\n * (`` ` ``), or U+007B LEFT CURLY BRACE (`{`) to U+007E TILDE (`~`).\n */\n\nexport const asciiPunctuation = regexCheck(/[!-/:-@[-`{-~]/)\n/**\n * Check whether the character code represents an ASCII atext.\n *\n * atext is an ASCII alphanumeric (see `asciiAlphanumeric`), or a character in\n * the inclusive ranges U+0023 NUMBER SIGN (`#`) to U+0027 APOSTROPHE (`'`),\n * U+002A ASTERISK (`*`), U+002B PLUS SIGN (`+`), U+002D DASH (`-`), U+002F\n * SLASH (`/`), U+003D EQUALS TO (`=`), U+003F QUESTION MARK (`?`), U+005E\n * CARET (`^`) to U+0060 GRAVE ACCENT (`` ` ``), or U+007B LEFT CURLY BRACE\n * (`{`) to U+007E TILDE (`~`).\n *\n * See:\n * **\\[RFC5322]**:\n * [Internet Message Format](https://tools.ietf.org/html/rfc5322).\n * P. Resnick.\n * IETF.\n */\n\nexport const asciiAtext = regexCheck(/[#-'*+\\--9=?A-Z^-~]/)\n/**\n * Check whether a character code is an ASCII control character.\n *\n * An **ASCII control** is a character in the inclusive range U+0000 NULL (NUL)\n * to U+001F (US), or U+007F (DEL).\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function asciiControl(code) {\n return (\n // Special whitespace codes (which have negative values), C0 and Control\n // character DEL\n code !== null && (code < 32 || code === 127)\n )\n}\n/**\n * Check whether a character code is a markdown line ending (see\n * `markdownLineEnding`) or markdown space (see `markdownSpace`).\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function markdownLineEndingOrSpace(code) {\n return code !== null && (code < 0 || code === 32)\n}\n/**\n * Check whether a character code is a markdown line ending.\n *\n * A **markdown line ending** is the virtual characters M-0003 CARRIAGE RETURN\n * LINE FEED (CRLF), M-0004 LINE FEED (LF) and M-0005 CARRIAGE RETURN (CR).\n *\n * In micromark, the actual character U+000A LINE FEED (LF) and U+000D CARRIAGE\n * RETURN (CR) are replaced by these virtual characters depending on whether\n * they occurred together.\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function markdownLineEnding(code) {\n return code !== null && code < -2\n}\n/**\n * Check whether a character code is a markdown space.\n *\n * A **markdown space** is the concrete character U+0020 SPACE (SP) and the\n * virtual characters M-0001 VIRTUAL SPACE (VS) and M-0002 HORIZONTAL TAB (HT).\n *\n * In micromark, the actual character U+0009 CHARACTER TABULATION (HT) is\n * replaced by one M-0002 HORIZONTAL TAB (HT) and between 0 and 3 M-0001 VIRTUAL\n * SPACE (VS) characters, depending on the column at which the tab occurred.\n *\n * @param {Code} code\n * @returns {code is number}\n */\n\nexport function markdownSpace(code) {\n return code === -2 || code === -1 || code === 32\n}\n/**\n * Check whether the character code represents Unicode whitespace.\n *\n * Note that this does handle micromark specific markdown whitespace characters.\n * See `markdownLineEndingOrSpace` to check that.\n *\n * A **Unicode whitespace** is a character in the Unicode `Zs` (Separator,\n * Space) category, or U+0009 CHARACTER TABULATION (HT), U+000A LINE FEED (LF),\n * U+000C (FF), or U+000D CARRIAGE RETURN (CR) (**\\[UNICODE]**).\n *\n * See:\n * **\\[UNICODE]**:\n * [The Unicode Standard](https://www.unicode.org/versions/).\n * Unicode Consortium.\n */\n\nexport const unicodeWhitespace = regexCheck(/\\s/)\n/**\n * Check whether the character code represents Unicode punctuation.\n *\n * A **Unicode punctuation** is a character in the Unicode `Pc` (Punctuation,\n * Connector), `Pd` (Punctuation, Dash), `Pe` (Punctuation, Close), `Pf`\n * (Punctuation, Final quote), `Pi` (Punctuation, Initial quote), `Po`\n * (Punctuation, Other), or `Ps` (Punctuation, Open) categories, or an ASCII\n * punctuation (see `asciiPunctuation`).\n *\n * See:\n * **\\[UNICODE]**:\n * [The Unicode Standard](https://www.unicode.org/versions/).\n * Unicode Consortium.\n */\n// Size note: removing ASCII from the regex and using `asciiPunctuation` here\n// In fact adds to the bundle size.\n\nexport const unicodePunctuation = regexCheck(unicodePunctuationRegex)\n/**\n * Create a code check from a regex.\n *\n * @param {RegExp} regex\n * @returns {(code: Code) => code is number}\n */\n\nfunction regexCheck(regex) {\n return check\n /**\n * Check whether a code matches the bound regex.\n *\n * @param {Code} code Character code\n * @returns {code is number} Whether the character code matches the bound regex\n */\n\n function check(code) {\n return code !== null && regex.test(String.fromCharCode(code))\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownSpace} from 'micromark-util-character'\n/**\n * @param {Effects} effects\n * @param {State} ok\n * @param {string} type\n * @param {number} [max=Infinity]\n * @returns {State}\n */\n\nexport function factorySpace(effects, ok, type, max) {\n const limit = max ? max - 1 : Number.POSITIVE_INFINITY\n let size = 0\n return start\n /** @type {State} */\n\n function start(code) {\n if (markdownSpace(code)) {\n effects.enter(type)\n return prefix(code)\n }\n\n return ok(code)\n }\n /** @type {State} */\n\n function prefix(code) {\n if (markdownSpace(code) && size++ < limit) {\n effects.consume(code)\n return prefix\n }\n\n effects.exit(type)\n return ok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {InitialConstruct} */\nexport const content = {\n tokenize: initializeContent\n}\n/** @type {Initializer} */\n\nfunction initializeContent(effects) {\n const contentStart = effects.attempt(\n this.parser.constructs.contentInitial,\n afterContentStartConstruct,\n paragraphInitial\n )\n /** @type {Token} */\n\n let previous\n return contentStart\n /** @type {State} */\n\n function afterContentStartConstruct(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, contentStart, 'linePrefix')\n }\n /** @type {State} */\n\n function paragraphInitial(code) {\n effects.enter('paragraph')\n return lineStart(code)\n }\n /** @type {State} */\n\n function lineStart(code) {\n const token = effects.enter('chunkText', {\n contentType: 'text',\n previous\n })\n\n if (previous) {\n previous.next = token\n }\n\n previous = token\n return data(code)\n }\n /** @type {State} */\n\n function data(code) {\n if (code === null) {\n effects.exit('chunkText')\n effects.exit('paragraph')\n effects.consume(code)\n return\n }\n\n if (markdownLineEnding(code)) {\n effects.consume(code)\n effects.exit('chunkText')\n return lineStart\n } // Data.\n\n effects.consume(code)\n return data\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Point} Point\n */\n\n/**\n * @typedef {Record} StackState\n * @typedef {[Construct, StackState]} StackItem\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\nimport {splice} from 'micromark-util-chunked'\n/** @type {InitialConstruct} */\n\nexport const document = {\n tokenize: initializeDocument\n}\n/** @type {Construct} */\n\nconst containerConstruct = {\n tokenize: tokenizeContainer\n}\n/** @type {Initializer} */\n\nfunction initializeDocument(effects) {\n const self = this\n /** @type {Array} */\n\n const stack = []\n let continued = 0\n /** @type {TokenizeContext|undefined} */\n\n let childFlow\n /** @type {Token|undefined} */\n\n let childToken\n /** @type {number} */\n\n let lineStartOffset\n return start\n /** @type {State} */\n\n function start(code) {\n // First we iterate through the open blocks, starting with the root\n // document, and descending through last children down to the last open\n // block.\n // Each block imposes a condition that the line must satisfy if the block is\n // to remain open.\n // For example, a block quote requires a `>` character.\n // A paragraph requires a non-blank line.\n // In this phase we may match all or just some of the open blocks.\n // But we cannot close unmatched blocks yet, because we may have a lazy\n // continuation line.\n if (continued < stack.length) {\n const item = stack[continued]\n self.containerState = item[1]\n return effects.attempt(\n item[0].continuation,\n documentContinue,\n checkNewContainers\n )(code)\n } // Done.\n\n return checkNewContainers(code)\n }\n /** @type {State} */\n\n function documentContinue(code) {\n continued++ // Note: this field is called `_closeFlow` but it also closes containers.\n // Perhaps a good idea to rename it but it\u2019s already used in the wild by\n // extensions.\n\n if (self.containerState._closeFlow) {\n self.containerState._closeFlow = undefined\n\n if (childFlow) {\n closeFlow()\n } // Note: this algorithm for moving events around is similar to the\n // algorithm when dealing with lazy lines in `writeToChild`.\n\n const indexBeforeExits = self.events.length\n let indexBeforeFlow = indexBeforeExits\n /** @type {Point|undefined} */\n\n let point // Find the flow chunk.\n\n while (indexBeforeFlow--) {\n if (\n self.events[indexBeforeFlow][0] === 'exit' &&\n self.events[indexBeforeFlow][1].type === 'chunkFlow'\n ) {\n point = self.events[indexBeforeFlow][1].end\n break\n }\n }\n\n exitContainers(continued) // Fix positions.\n\n let index = indexBeforeExits\n\n while (index < self.events.length) {\n self.events[index][1].end = Object.assign({}, point)\n index++\n } // Inject the exits earlier (they\u2019re still also at the end).\n\n splice(\n self.events,\n indexBeforeFlow + 1,\n 0,\n self.events.slice(indexBeforeExits)\n ) // Discard the duplicate exits.\n\n self.events.length = index\n return checkNewContainers(code)\n }\n\n return start(code)\n }\n /** @type {State} */\n\n function checkNewContainers(code) {\n // Next, after consuming the continuation markers for existing blocks, we\n // look for new block starts (e.g. `>` for a block quote).\n // If we encounter a new block start, we close any blocks unmatched in\n // step 1 before creating the new block as a child of the last matched\n // block.\n if (continued === stack.length) {\n // No need to `check` whether there\u2019s a container, of `exitContainers`\n // would be moot.\n // We can instead immediately `attempt` to parse one.\n if (!childFlow) {\n return documentContinued(code)\n } // If we have concrete content, such as block HTML or fenced code,\n // we can\u2019t have containers \u201Cpierce\u201D into them, so we can immediately\n // start.\n\n if (childFlow.currentConstruct && childFlow.currentConstruct.concrete) {\n return flowStart(code)\n } // If we do have flow, it could still be a blank line,\n // but we\u2019d be interrupting it w/ a new container if there\u2019s a current\n // construct.\n\n self.interrupt = Boolean(\n childFlow.currentConstruct && !childFlow._gfmTableDynamicInterruptHack\n )\n } // Check if there is a new container.\n\n self.containerState = {}\n return effects.check(\n containerConstruct,\n thereIsANewContainer,\n thereIsNoNewContainer\n )(code)\n }\n /** @type {State} */\n\n function thereIsANewContainer(code) {\n if (childFlow) closeFlow()\n exitContainers(continued)\n return documentContinued(code)\n }\n /** @type {State} */\n\n function thereIsNoNewContainer(code) {\n self.parser.lazy[self.now().line] = continued !== stack.length\n lineStartOffset = self.now().offset\n return flowStart(code)\n }\n /** @type {State} */\n\n function documentContinued(code) {\n // Try new containers.\n self.containerState = {}\n return effects.attempt(\n containerConstruct,\n containerContinue,\n flowStart\n )(code)\n }\n /** @type {State} */\n\n function containerContinue(code) {\n continued++\n stack.push([self.currentConstruct, self.containerState]) // Try another.\n\n return documentContinued(code)\n }\n /** @type {State} */\n\n function flowStart(code) {\n if (code === null) {\n if (childFlow) closeFlow()\n exitContainers(0)\n effects.consume(code)\n return\n }\n\n childFlow = childFlow || self.parser.flow(self.now())\n effects.enter('chunkFlow', {\n contentType: 'flow',\n previous: childToken,\n _tokenizer: childFlow\n })\n return flowContinue(code)\n }\n /** @type {State} */\n\n function flowContinue(code) {\n if (code === null) {\n writeToChild(effects.exit('chunkFlow'), true)\n exitContainers(0)\n effects.consume(code)\n return\n }\n\n if (markdownLineEnding(code)) {\n effects.consume(code)\n writeToChild(effects.exit('chunkFlow')) // Get ready for the next line.\n\n continued = 0\n self.interrupt = undefined\n return start\n }\n\n effects.consume(code)\n return flowContinue\n }\n /**\n * @param {Token} token\n * @param {boolean} [eof]\n * @returns {void}\n */\n\n function writeToChild(token, eof) {\n const stream = self.sliceStream(token)\n if (eof) stream.push(null)\n token.previous = childToken\n if (childToken) childToken.next = token\n childToken = token\n childFlow.defineSkip(token.start)\n childFlow.write(stream) // Alright, so we just added a lazy line:\n //\n // ```markdown\n // > a\n // b.\n //\n // Or:\n //\n // > ~~~c\n // d\n //\n // Or:\n //\n // > | e |\n // f\n // ```\n //\n // The construct in the second example (fenced code) does not accept lazy\n // lines, so it marked itself as done at the end of its first line, and\n // then the content construct parses `d`.\n // Most constructs in markdown match on the first line: if the first line\n // forms a construct, a non-lazy line can\u2019t \u201Cunmake\u201D it.\n //\n // The construct in the third example is potentially a GFM table, and\n // those are *weird*.\n // It *could* be a table, from the first line, if the following line\n // matches a condition.\n // In this case, that second line is lazy, which \u201Cunmakes\u201D the first line\n // and turns the whole into one content block.\n //\n // We\u2019ve now parsed the non-lazy and the lazy line, and can figure out\n // whether the lazy line started a new flow block.\n // If it did, we exit the current containers between the two flow blocks.\n\n if (self.parser.lazy[token.start.line]) {\n let index = childFlow.events.length\n\n while (index--) {\n if (\n // The token starts before the line ending\u2026\n childFlow.events[index][1].start.offset < lineStartOffset && // \u2026and either is not ended yet\u2026\n (!childFlow.events[index][1].end || // \u2026or ends after it.\n childFlow.events[index][1].end.offset > lineStartOffset)\n ) {\n // Exit: there\u2019s still something open, which means it\u2019s a lazy line\n // part of something.\n return\n }\n } // Note: this algorithm for moving events around is similar to the\n // algorithm when closing flow in `documentContinue`.\n\n const indexBeforeExits = self.events.length\n let indexBeforeFlow = indexBeforeExits\n /** @type {boolean|undefined} */\n\n let seen\n /** @type {Point|undefined} */\n\n let point // Find the previous chunk (the one before the lazy line).\n\n while (indexBeforeFlow--) {\n if (\n self.events[indexBeforeFlow][0] === 'exit' &&\n self.events[indexBeforeFlow][1].type === 'chunkFlow'\n ) {\n if (seen) {\n point = self.events[indexBeforeFlow][1].end\n break\n }\n\n seen = true\n }\n }\n\n exitContainers(continued) // Fix positions.\n\n index = indexBeforeExits\n\n while (index < self.events.length) {\n self.events[index][1].end = Object.assign({}, point)\n index++\n } // Inject the exits earlier (they\u2019re still also at the end).\n\n splice(\n self.events,\n indexBeforeFlow + 1,\n 0,\n self.events.slice(indexBeforeExits)\n ) // Discard the duplicate exits.\n\n self.events.length = index\n }\n }\n /**\n * @param {number} size\n * @returns {void}\n */\n\n function exitContainers(size) {\n let index = stack.length // Exit open containers.\n\n while (index-- > size) {\n const entry = stack[index]\n self.containerState = entry[1]\n entry[0].exit.call(self, effects)\n }\n\n stack.length = size\n }\n\n function closeFlow() {\n childFlow.write([null])\n childToken = undefined\n childFlow = undefined\n self.containerState._closeFlow = undefined\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeContainer(effects, ok, nok) {\n return factorySpace(\n effects,\n effects.attempt(this.parser.constructs.document, ok, nok),\n 'linePrefix',\n this.parser.constructs.disable.null.includes('codeIndented') ? undefined : 4\n )\n}\n", "/**\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {\n markdownLineEndingOrSpace,\n unicodePunctuation,\n unicodeWhitespace\n} from 'micromark-util-character'\n\n/**\n * Classify whether a character code represents whitespace, punctuation, or\n * something else.\n *\n * Used for attention (emphasis, strong), whose sequences can open or close\n * based on the class of surrounding characters.\n *\n * Note that eof (`null`) is seen as whitespace.\n *\n * @param {Code} code\n * @returns {number|undefined}\n */\nexport function classifyCharacter(code) {\n if (\n code === null ||\n markdownLineEndingOrSpace(code) ||\n unicodeWhitespace(code)\n ) {\n return 1\n }\n\n if (unicodePunctuation(code)) {\n return 2\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').Resolver} Resolver\n */\n\n/**\n * Call all `resolveAll`s.\n *\n * @param {{resolveAll?: Resolver}[]} constructs\n * @param {Event[]} events\n * @param {TokenizeContext} context\n * @returns {Event[]}\n */\nexport function resolveAll(constructs, events, context) {\n /** @type {Resolver[]} */\n const called = []\n let index = -1\n\n while (++index < constructs.length) {\n const resolve = constructs[index].resolveAll\n\n if (resolve && !called.includes(resolve)) {\n events = resolve(events, context)\n called.push(resolve)\n }\n }\n\n return events\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').Code} Code\n * @typedef {import('micromark-util-types').Point} Point\n */\nimport {push, splice} from 'micromark-util-chunked'\nimport {classifyCharacter} from 'micromark-util-classify-character'\nimport {resolveAll} from 'micromark-util-resolve-all'\n\n/** @type {Construct} */\nexport const attention = {\n name: 'attention',\n tokenize: tokenizeAttention,\n resolveAll: resolveAllAttention\n}\n/**\n * Take all events and resolve attention to emphasis or strong.\n *\n * @type {Resolver}\n */\n\nfunction resolveAllAttention(events, context) {\n let index = -1\n /** @type {number} */\n\n let open\n /** @type {Token} */\n\n let group\n /** @type {Token} */\n\n let text\n /** @type {Token} */\n\n let openingSequence\n /** @type {Token} */\n\n let closingSequence\n /** @type {number} */\n\n let use\n /** @type {Event[]} */\n\n let nextEvents\n /** @type {number} */\n\n let offset // Walk through all events.\n //\n // Note: performance of this is fine on an mb of normal markdown, but it\u2019s\n // a bottleneck for malicious stuff.\n\n while (++index < events.length) {\n // Find a token that can close.\n if (\n events[index][0] === 'enter' &&\n events[index][1].type === 'attentionSequence' &&\n events[index][1]._close\n ) {\n open = index // Now walk back to find an opener.\n\n while (open--) {\n // Find a token that can open the closer.\n if (\n events[open][0] === 'exit' &&\n events[open][1].type === 'attentionSequence' &&\n events[open][1]._open && // If the markers are the same:\n context.sliceSerialize(events[open][1]).charCodeAt(0) ===\n context.sliceSerialize(events[index][1]).charCodeAt(0)\n ) {\n // If the opening can close or the closing can open,\n // and the close size *is not* a multiple of three,\n // but the sum of the opening and closing size *is* multiple of three,\n // then don\u2019t match.\n if (\n (events[open][1]._close || events[index][1]._open) &&\n (events[index][1].end.offset - events[index][1].start.offset) % 3 &&\n !(\n (events[open][1].end.offset -\n events[open][1].start.offset +\n events[index][1].end.offset -\n events[index][1].start.offset) %\n 3\n )\n ) {\n continue\n } // Number of markers to use from the sequence.\n\n use =\n events[open][1].end.offset - events[open][1].start.offset > 1 &&\n events[index][1].end.offset - events[index][1].start.offset > 1\n ? 2\n : 1\n const start = Object.assign({}, events[open][1].end)\n const end = Object.assign({}, events[index][1].start)\n movePoint(start, -use)\n movePoint(end, use)\n openingSequence = {\n type: use > 1 ? 'strongSequence' : 'emphasisSequence',\n start,\n end: Object.assign({}, events[open][1].end)\n }\n closingSequence = {\n type: use > 1 ? 'strongSequence' : 'emphasisSequence',\n start: Object.assign({}, events[index][1].start),\n end\n }\n text = {\n type: use > 1 ? 'strongText' : 'emphasisText',\n start: Object.assign({}, events[open][1].end),\n end: Object.assign({}, events[index][1].start)\n }\n group = {\n type: use > 1 ? 'strong' : 'emphasis',\n start: Object.assign({}, openingSequence.start),\n end: Object.assign({}, closingSequence.end)\n }\n events[open][1].end = Object.assign({}, openingSequence.start)\n events[index][1].start = Object.assign({}, closingSequence.end)\n nextEvents = [] // If there are more markers in the opening, add them before.\n\n if (events[open][1].end.offset - events[open][1].start.offset) {\n nextEvents = push(nextEvents, [\n ['enter', events[open][1], context],\n ['exit', events[open][1], context]\n ])\n } // Opening.\n\n nextEvents = push(nextEvents, [\n ['enter', group, context],\n ['enter', openingSequence, context],\n ['exit', openingSequence, context],\n ['enter', text, context]\n ]) // Between.\n\n nextEvents = push(\n nextEvents,\n resolveAll(\n context.parser.constructs.insideSpan.null,\n events.slice(open + 1, index),\n context\n )\n ) // Closing.\n\n nextEvents = push(nextEvents, [\n ['exit', text, context],\n ['enter', closingSequence, context],\n ['exit', closingSequence, context],\n ['exit', group, context]\n ]) // If there are more markers in the closing, add them after.\n\n if (events[index][1].end.offset - events[index][1].start.offset) {\n offset = 2\n nextEvents = push(nextEvents, [\n ['enter', events[index][1], context],\n ['exit', events[index][1], context]\n ])\n } else {\n offset = 0\n }\n\n splice(events, open - 1, index - open + 3, nextEvents)\n index = open + nextEvents.length - offset - 2\n break\n }\n }\n }\n } // Remove remaining sequences.\n\n index = -1\n\n while (++index < events.length) {\n if (events[index][1].type === 'attentionSequence') {\n events[index][1].type = 'data'\n }\n }\n\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeAttention(effects, ok) {\n const attentionMarkers = this.parser.constructs.attentionMarkers.null\n const previous = this.previous\n const before = classifyCharacter(previous)\n /** @type {NonNullable} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('attentionSequence')\n marker = code\n return sequence(code)\n }\n /** @type {State} */\n\n function sequence(code) {\n if (code === marker) {\n effects.consume(code)\n return sequence\n }\n\n const token = effects.exit('attentionSequence')\n const after = classifyCharacter(code)\n const open =\n !after || (after === 2 && before) || attentionMarkers.includes(code)\n const close =\n !before || (before === 2 && after) || attentionMarkers.includes(previous)\n token._open = Boolean(marker === 42 ? open : open && (before || !close))\n token._close = Boolean(marker === 42 ? close : close && (after || !open))\n return ok(code)\n }\n}\n/**\n * Move a point a bit.\n *\n * Note: `move` only works inside lines! It\u2019s not possible to move past other\n * chunks (replacement characters, tabs, or line endings).\n *\n * @param {Point} point\n * @param {number} offset\n * @returns {void}\n */\n\nfunction movePoint(point, offset) {\n point.column += offset\n point.offset += offset\n point._bufferIndex += offset\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {\n asciiAlpha,\n asciiAlphanumeric,\n asciiAtext,\n asciiControl\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const autolink = {\n name: 'autolink',\n tokenize: tokenizeAutolink\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeAutolink(effects, ok, nok) {\n let size = 1\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('autolink')\n effects.enter('autolinkMarker')\n effects.consume(code)\n effects.exit('autolinkMarker')\n effects.enter('autolinkProtocol')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (asciiAlpha(code)) {\n effects.consume(code)\n return schemeOrEmailAtext\n }\n\n return asciiAtext(code) ? emailAtext(code) : nok(code)\n }\n /** @type {State} */\n\n function schemeOrEmailAtext(code) {\n return code === 43 || code === 45 || code === 46 || asciiAlphanumeric(code)\n ? schemeInsideOrEmailAtext(code)\n : emailAtext(code)\n }\n /** @type {State} */\n\n function schemeInsideOrEmailAtext(code) {\n if (code === 58) {\n effects.consume(code)\n return urlInside\n }\n\n if (\n (code === 43 || code === 45 || code === 46 || asciiAlphanumeric(code)) &&\n size++ < 32\n ) {\n effects.consume(code)\n return schemeInsideOrEmailAtext\n }\n\n return emailAtext(code)\n }\n /** @type {State} */\n\n function urlInside(code) {\n if (code === 62) {\n effects.exit('autolinkProtocol')\n return end(code)\n }\n\n if (code === null || code === 32 || code === 60 || asciiControl(code)) {\n return nok(code)\n }\n\n effects.consume(code)\n return urlInside\n }\n /** @type {State} */\n\n function emailAtext(code) {\n if (code === 64) {\n effects.consume(code)\n size = 0\n return emailAtSignOrDot\n }\n\n if (asciiAtext(code)) {\n effects.consume(code)\n return emailAtext\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function emailAtSignOrDot(code) {\n return asciiAlphanumeric(code) ? emailLabel(code) : nok(code)\n }\n /** @type {State} */\n\n function emailLabel(code) {\n if (code === 46) {\n effects.consume(code)\n size = 0\n return emailAtSignOrDot\n }\n\n if (code === 62) {\n // Exit, then change the type.\n effects.exit('autolinkProtocol').type = 'autolinkEmail'\n return end(code)\n }\n\n return emailValue(code)\n }\n /** @type {State} */\n\n function emailValue(code) {\n if ((code === 45 || asciiAlphanumeric(code)) && size++ < 63) {\n effects.consume(code)\n return code === 45 ? emailValue : emailLabel\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function end(code) {\n effects.enter('autolinkMarker')\n effects.consume(code)\n effects.exit('autolinkMarker')\n effects.exit('autolink')\n return ok\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const blankLine = {\n tokenize: tokenizeBlankLine,\n partial: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeBlankLine(effects, ok, nok) {\n return factorySpace(effects, afterWhitespace, 'linePrefix')\n /** @type {State} */\n\n function afterWhitespace(code) {\n return code === null || markdownLineEnding(code) ? ok(code) : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Exiter} Exiter\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownSpace} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const blockQuote = {\n name: 'blockQuote',\n tokenize: tokenizeBlockQuoteStart,\n continuation: {\n tokenize: tokenizeBlockQuoteContinuation\n },\n exit\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeBlockQuoteStart(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n if (code === 62) {\n const state = self.containerState\n\n if (!state.open) {\n effects.enter('blockQuote', {\n _container: true\n })\n state.open = true\n }\n\n effects.enter('blockQuotePrefix')\n effects.enter('blockQuoteMarker')\n effects.consume(code)\n effects.exit('blockQuoteMarker')\n return after\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n if (markdownSpace(code)) {\n effects.enter('blockQuotePrefixWhitespace')\n effects.consume(code)\n effects.exit('blockQuotePrefixWhitespace')\n effects.exit('blockQuotePrefix')\n return ok\n }\n\n effects.exit('blockQuotePrefix')\n return ok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeBlockQuoteContinuation(effects, ok, nok) {\n return factorySpace(\n effects,\n effects.attempt(blockQuote, ok, nok),\n 'linePrefix',\n this.parser.constructs.disable.null.includes('codeIndented') ? undefined : 4\n )\n}\n/** @type {Exiter} */\n\nfunction exit(effects) {\n effects.exit('blockQuote')\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {asciiPunctuation} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const characterEscape = {\n name: 'characterEscape',\n tokenize: tokenizeCharacterEscape\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCharacterEscape(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('characterEscape')\n effects.enter('escapeMarker')\n effects.consume(code)\n effects.exit('escapeMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (asciiPunctuation(code)) {\n effects.enter('characterEscapeValue')\n effects.consume(code)\n effects.exit('characterEscapeValue')\n effects.exit('characterEscape')\n return ok\n }\n\n return nok(code)\n }\n}\n", "/// \n\n/* eslint-env browser */\n\nconst element = document.createElement('i')\n\n/**\n * @param {string} value\n * @returns {string|false}\n */\nexport function decodeNamedCharacterReference(value) {\n const characterReference = '&' + value + ';'\n element.innerHTML = characterReference\n const char = element.textContent\n\n // Some named character references do not require the closing semicolon\n // (`¬`, for instance), which leads to situations where parsing the assumed\n // named reference of `¬it;` will result in the string `\u00ACit;`.\n // When we encounter a trailing semicolon after parsing, and the character\n // reference to decode was not a semicolon (`;`), we can assume that the\n // matching was not complete.\n // @ts-expect-error: TypeScript is wrong that `textContent` on elements can\n // yield `null`.\n if (char.charCodeAt(char.length - 1) === 59 /* `;` */ && value !== 'semi') {\n return false\n }\n\n // If the decoded string is equal to the input, the character reference was\n // not valid.\n // @ts-expect-error: TypeScript is wrong that `textContent` on elements can\n // yield `null`.\n return char === characterReference ? false : char\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {decodeNamedCharacterReference} from 'decode-named-character-reference'\nimport {\n asciiAlphanumeric,\n asciiDigit,\n asciiHexDigit\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const characterReference = {\n name: 'characterReference',\n tokenize: tokenizeCharacterReference\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCharacterReference(effects, ok, nok) {\n const self = this\n let size = 0\n /** @type {number} */\n\n let max\n /** @type {(code: Code) => code is number} */\n\n let test\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('characterReference')\n effects.enter('characterReferenceMarker')\n effects.consume(code)\n effects.exit('characterReferenceMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 35) {\n effects.enter('characterReferenceMarkerNumeric')\n effects.consume(code)\n effects.exit('characterReferenceMarkerNumeric')\n return numeric\n }\n\n effects.enter('characterReferenceValue')\n max = 31\n test = asciiAlphanumeric\n return value(code)\n }\n /** @type {State} */\n\n function numeric(code) {\n if (code === 88 || code === 120) {\n effects.enter('characterReferenceMarkerHexadecimal')\n effects.consume(code)\n effects.exit('characterReferenceMarkerHexadecimal')\n effects.enter('characterReferenceValue')\n max = 6\n test = asciiHexDigit\n return value\n }\n\n effects.enter('characterReferenceValue')\n max = 7\n test = asciiDigit\n return value(code)\n }\n /** @type {State} */\n\n function value(code) {\n /** @type {Token} */\n let token\n\n if (code === 59 && size) {\n token = effects.exit('characterReferenceValue')\n\n if (\n test === asciiAlphanumeric &&\n !decodeNamedCharacterReference(self.sliceSerialize(token))\n ) {\n return nok(code)\n }\n\n effects.enter('characterReferenceMarker')\n effects.consume(code)\n effects.exit('characterReferenceMarker')\n effects.exit('characterReference')\n return ok\n }\n\n if (test(code) && size++ < max) {\n effects.consume(code)\n return value\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {\n markdownLineEnding,\n markdownLineEndingOrSpace\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const codeFenced = {\n name: 'codeFenced',\n tokenize: tokenizeCodeFenced,\n concrete: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCodeFenced(effects, ok, nok) {\n const self = this\n /** @type {Construct} */\n\n const closingFenceConstruct = {\n tokenize: tokenizeClosingFence,\n partial: true\n }\n /** @type {Construct} */\n\n const nonLazyLine = {\n tokenize: tokenizeNonLazyLine,\n partial: true\n }\n const tail = this.events[this.events.length - 1]\n const initialPrefix =\n tail && tail[1].type === 'linePrefix'\n ? tail[2].sliceSerialize(tail[1], true).length\n : 0\n let sizeOpen = 0\n /** @type {NonNullable} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('codeFenced')\n effects.enter('codeFencedFence')\n effects.enter('codeFencedFenceSequence')\n marker = code\n return sequenceOpen(code)\n }\n /** @type {State} */\n\n function sequenceOpen(code) {\n if (code === marker) {\n effects.consume(code)\n sizeOpen++\n return sequenceOpen\n }\n\n effects.exit('codeFencedFenceSequence')\n return sizeOpen < 3\n ? nok(code)\n : factorySpace(effects, infoOpen, 'whitespace')(code)\n }\n /** @type {State} */\n\n function infoOpen(code) {\n if (code === null || markdownLineEnding(code)) {\n return openAfter(code)\n }\n\n effects.enter('codeFencedFenceInfo')\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return info(code)\n }\n /** @type {State} */\n\n function info(code) {\n if (code === null || markdownLineEndingOrSpace(code)) {\n effects.exit('chunkString')\n effects.exit('codeFencedFenceInfo')\n return factorySpace(effects, infoAfter, 'whitespace')(code)\n }\n\n if (code === 96 && code === marker) return nok(code)\n effects.consume(code)\n return info\n }\n /** @type {State} */\n\n function infoAfter(code) {\n if (code === null || markdownLineEnding(code)) {\n return openAfter(code)\n }\n\n effects.enter('codeFencedFenceMeta')\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return meta(code)\n }\n /** @type {State} */\n\n function meta(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('chunkString')\n effects.exit('codeFencedFenceMeta')\n return openAfter(code)\n }\n\n if (code === 96 && code === marker) return nok(code)\n effects.consume(code)\n return meta\n }\n /** @type {State} */\n\n function openAfter(code) {\n effects.exit('codeFencedFence')\n return self.interrupt ? ok(code) : contentStart(code)\n }\n /** @type {State} */\n\n function contentStart(code) {\n if (code === null) {\n return after(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.attempt(\n nonLazyLine,\n effects.attempt(\n closingFenceConstruct,\n after,\n initialPrefix\n ? factorySpace(\n effects,\n contentStart,\n 'linePrefix',\n initialPrefix + 1\n )\n : contentStart\n ),\n after\n )(code)\n }\n\n effects.enter('codeFlowValue')\n return contentContinue(code)\n }\n /** @type {State} */\n\n function contentContinue(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('codeFlowValue')\n return contentStart(code)\n }\n\n effects.consume(code)\n return contentContinue\n }\n /** @type {State} */\n\n function after(code) {\n effects.exit('codeFenced')\n return ok(code)\n }\n /** @type {Tokenizer} */\n\n function tokenizeNonLazyLine(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return lineStart\n }\n /** @type {State} */\n\n function lineStart(code) {\n return self.parser.lazy[self.now().line] ? nok(code) : ok(code)\n }\n }\n /** @type {Tokenizer} */\n\n function tokenizeClosingFence(effects, ok, nok) {\n let size = 0\n return factorySpace(\n effects,\n closingSequenceStart,\n 'linePrefix',\n this.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4\n )\n /** @type {State} */\n\n function closingSequenceStart(code) {\n effects.enter('codeFencedFence')\n effects.enter('codeFencedFenceSequence')\n return closingSequence(code)\n }\n /** @type {State} */\n\n function closingSequence(code) {\n if (code === marker) {\n effects.consume(code)\n size++\n return closingSequence\n }\n\n if (size < sizeOpen) return nok(code)\n effects.exit('codeFencedFenceSequence')\n return factorySpace(effects, closingSequenceEnd, 'whitespace')(code)\n }\n /** @type {State} */\n\n function closingSequenceEnd(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('codeFencedFence')\n return ok(code)\n }\n\n return nok(code)\n }\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const codeIndented = {\n name: 'codeIndented',\n tokenize: tokenizeCodeIndented\n}\n/** @type {Construct} */\n\nconst indentedContent = {\n tokenize: tokenizeIndentedContent,\n partial: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCodeIndented(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('codeIndented')\n return factorySpace(effects, afterStartPrefix, 'linePrefix', 4 + 1)(code)\n }\n /** @type {State} */\n\n function afterStartPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return tail &&\n tail[1].type === 'linePrefix' &&\n tail[2].sliceSerialize(tail[1], true).length >= 4\n ? afterPrefix(code)\n : nok(code)\n }\n /** @type {State} */\n\n function afterPrefix(code) {\n if (code === null) {\n return after(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.attempt(indentedContent, afterPrefix, after)(code)\n }\n\n effects.enter('codeFlowValue')\n return content(code)\n }\n /** @type {State} */\n\n function content(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('codeFlowValue')\n return afterPrefix(code)\n }\n\n effects.consume(code)\n return content\n }\n /** @type {State} */\n\n function after(code) {\n effects.exit('codeIndented')\n return ok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeIndentedContent(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n // If this is a lazy line, it can\u2019t be code.\n if (self.parser.lazy[self.now().line]) {\n return nok(code)\n }\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return start\n }\n\n return factorySpace(effects, afterPrefix, 'linePrefix', 4 + 1)(code)\n }\n /** @type {State} */\n\n function afterPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return tail &&\n tail[1].type === 'linePrefix' &&\n tail[2].sliceSerialize(tail[1], true).length >= 4\n ? ok(code)\n : markdownLineEnding(code)\n ? start(code)\n : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Previous} Previous\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const codeText = {\n name: 'codeText',\n tokenize: tokenizeCodeText,\n resolve: resolveCodeText,\n previous\n}\n/** @type {Resolver} */\n\nfunction resolveCodeText(events) {\n let tailExitIndex = events.length - 4\n let headEnterIndex = 3\n /** @type {number} */\n\n let index\n /** @type {number|undefined} */\n\n let enter // If we start and end with an EOL or a space.\n\n if (\n (events[headEnterIndex][1].type === 'lineEnding' ||\n events[headEnterIndex][1].type === 'space') &&\n (events[tailExitIndex][1].type === 'lineEnding' ||\n events[tailExitIndex][1].type === 'space')\n ) {\n index = headEnterIndex // And we have data.\n\n while (++index < tailExitIndex) {\n if (events[index][1].type === 'codeTextData') {\n // Then we have padding.\n events[headEnterIndex][1].type = 'codeTextPadding'\n events[tailExitIndex][1].type = 'codeTextPadding'\n headEnterIndex += 2\n tailExitIndex -= 2\n break\n }\n }\n } // Merge adjacent spaces and data.\n\n index = headEnterIndex - 1\n tailExitIndex++\n\n while (++index <= tailExitIndex) {\n if (enter === undefined) {\n if (index !== tailExitIndex && events[index][1].type !== 'lineEnding') {\n enter = index\n }\n } else if (\n index === tailExitIndex ||\n events[index][1].type === 'lineEnding'\n ) {\n events[enter][1].type = 'codeTextData'\n\n if (index !== enter + 2) {\n events[enter][1].end = events[index - 1][1].end\n events.splice(enter + 2, index - enter - 2)\n tailExitIndex -= index - enter - 2\n index = enter + 2\n }\n\n enter = undefined\n }\n }\n\n return events\n}\n/** @type {Previous} */\n\nfunction previous(code) {\n // If there is a previous code, there will always be a tail.\n return (\n code !== 96 ||\n this.events[this.events.length - 1][1].type === 'characterEscape'\n )\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCodeText(effects, ok, nok) {\n const self = this\n let sizeOpen = 0\n /** @type {number} */\n\n let size\n /** @type {Token} */\n\n let token\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('codeText')\n effects.enter('codeTextSequence')\n return openingSequence(code)\n }\n /** @type {State} */\n\n function openingSequence(code) {\n if (code === 96) {\n effects.consume(code)\n sizeOpen++\n return openingSequence\n }\n\n effects.exit('codeTextSequence')\n return gap(code)\n }\n /** @type {State} */\n\n function gap(code) {\n // EOF.\n if (code === null) {\n return nok(code)\n } // Closing fence?\n // Could also be data.\n\n if (code === 96) {\n token = effects.enter('codeTextSequence')\n size = 0\n return closingSequence(code)\n } // Tabs don\u2019t work, and virtual spaces don\u2019t make sense.\n\n if (code === 32) {\n effects.enter('space')\n effects.consume(code)\n effects.exit('space')\n return gap\n }\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return gap\n } // Data.\n\n effects.enter('codeTextData')\n return data(code)\n } // In code.\n\n /** @type {State} */\n\n function data(code) {\n if (\n code === null ||\n code === 32 ||\n code === 96 ||\n markdownLineEnding(code)\n ) {\n effects.exit('codeTextData')\n return gap(code)\n }\n\n effects.consume(code)\n return data\n } // Closing fence.\n\n /** @type {State} */\n\n function closingSequence(code) {\n // More.\n if (code === 96) {\n effects.consume(code)\n size++\n return closingSequence\n } // Done!\n\n if (size === sizeOpen) {\n effects.exit('codeTextSequence')\n effects.exit('codeText')\n return ok(code)\n } // More or less accents: mark as data.\n\n token.type = 'codeTextData'\n return data(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').Chunk} Chunk\n * @typedef {import('micromark-util-types').Event} Event\n */\nimport {splice} from 'micromark-util-chunked'\n\n/**\n * Tokenize subcontent.\n *\n * @param {Event[]} events\n * @returns {boolean}\n */\nexport function subtokenize(events) {\n /** @type {Record} */\n const jumps = {}\n let index = -1\n /** @type {Event} */\n\n let event\n /** @type {number|undefined} */\n\n let lineIndex\n /** @type {number} */\n\n let otherIndex\n /** @type {Event} */\n\n let otherEvent\n /** @type {Event[]} */\n\n let parameters\n /** @type {Event[]} */\n\n let subevents\n /** @type {boolean|undefined} */\n\n let more\n\n while (++index < events.length) {\n while (index in jumps) {\n index = jumps[index]\n }\n\n event = events[index] // Add a hook for the GFM tasklist extension, which needs to know if text\n // is in the first content of a list item.\n\n if (\n index &&\n event[1].type === 'chunkFlow' &&\n events[index - 1][1].type === 'listItemPrefix'\n ) {\n subevents = event[1]._tokenizer.events\n otherIndex = 0\n\n if (\n otherIndex < subevents.length &&\n subevents[otherIndex][1].type === 'lineEndingBlank'\n ) {\n otherIndex += 2\n }\n\n if (\n otherIndex < subevents.length &&\n subevents[otherIndex][1].type === 'content'\n ) {\n while (++otherIndex < subevents.length) {\n if (subevents[otherIndex][1].type === 'content') {\n break\n }\n\n if (subevents[otherIndex][1].type === 'chunkText') {\n subevents[otherIndex][1]._isInFirstContentOfListItem = true\n otherIndex++\n }\n }\n }\n } // Enter.\n\n if (event[0] === 'enter') {\n if (event[1].contentType) {\n Object.assign(jumps, subcontent(events, index))\n index = jumps[index]\n more = true\n }\n } // Exit.\n else if (event[1]._container) {\n otherIndex = index\n lineIndex = undefined\n\n while (otherIndex--) {\n otherEvent = events[otherIndex]\n\n if (\n otherEvent[1].type === 'lineEnding' ||\n otherEvent[1].type === 'lineEndingBlank'\n ) {\n if (otherEvent[0] === 'enter') {\n if (lineIndex) {\n events[lineIndex][1].type = 'lineEndingBlank'\n }\n\n otherEvent[1].type = 'lineEnding'\n lineIndex = otherIndex\n }\n } else {\n break\n }\n }\n\n if (lineIndex) {\n // Fix position.\n event[1].end = Object.assign({}, events[lineIndex][1].start) // Switch container exit w/ line endings.\n\n parameters = events.slice(lineIndex, index)\n parameters.unshift(event)\n splice(events, lineIndex, index - lineIndex + 1, parameters)\n }\n }\n }\n\n return !more\n}\n/**\n * Tokenize embedded tokens.\n *\n * @param {Event[]} events\n * @param {number} eventIndex\n * @returns {Record}\n */\n\nfunction subcontent(events, eventIndex) {\n const token = events[eventIndex][1]\n const context = events[eventIndex][2]\n let startPosition = eventIndex - 1\n /** @type {number[]} */\n\n const startPositions = []\n const tokenizer =\n token._tokenizer || context.parser[token.contentType](token.start)\n const childEvents = tokenizer.events\n /** @type {[number, number][]} */\n\n const jumps = []\n /** @type {Record} */\n\n const gaps = {}\n /** @type {Chunk[]} */\n\n let stream\n /** @type {Token|undefined} */\n\n let previous\n let index = -1\n /** @type {Token|undefined} */\n\n let current = token\n let adjust = 0\n let start = 0\n const breaks = [start] // Loop forward through the linked tokens to pass them in order to the\n // subtokenizer.\n\n while (current) {\n // Find the position of the event for this token.\n while (events[++startPosition][1] !== current) {\n // Empty.\n }\n\n startPositions.push(startPosition)\n\n if (!current._tokenizer) {\n stream = context.sliceStream(current)\n\n if (!current.next) {\n stream.push(null)\n }\n\n if (previous) {\n tokenizer.defineSkip(current.start)\n }\n\n if (current._isInFirstContentOfListItem) {\n tokenizer._gfmTasklistFirstContentOfListItem = true\n }\n\n tokenizer.write(stream)\n\n if (current._isInFirstContentOfListItem) {\n tokenizer._gfmTasklistFirstContentOfListItem = undefined\n }\n } // Unravel the next token.\n\n previous = current\n current = current.next\n } // Now, loop back through all events (and linked tokens), to figure out which\n // parts belong where.\n\n current = token\n\n while (++index < childEvents.length) {\n if (\n // Find a void token that includes a break.\n childEvents[index][0] === 'exit' &&\n childEvents[index - 1][0] === 'enter' &&\n childEvents[index][1].type === childEvents[index - 1][1].type &&\n childEvents[index][1].start.line !== childEvents[index][1].end.line\n ) {\n start = index + 1\n breaks.push(start) // Help GC.\n\n current._tokenizer = undefined\n current.previous = undefined\n current = current.next\n }\n } // Help GC.\n\n tokenizer.events = [] // If there\u2019s one more token (which is the cases for lines that end in an\n // EOF), that\u2019s perfect: the last point we found starts it.\n // If there isn\u2019t then make sure any remaining content is added to it.\n\n if (current) {\n // Help GC.\n current._tokenizer = undefined\n current.previous = undefined\n } else {\n breaks.pop()\n } // Now splice the events from the subtokenizer into the current events,\n // moving back to front so that splice indices aren\u2019t affected.\n\n index = breaks.length\n\n while (index--) {\n const slice = childEvents.slice(breaks[index], breaks[index + 1])\n const start = startPositions.pop()\n jumps.unshift([start, start + slice.length - 1])\n splice(events, start, 2, slice)\n }\n\n index = -1\n\n while (++index < jumps.length) {\n gaps[adjust + jumps[index][0]] = adjust + jumps[index][1]\n adjust += jumps[index][1] - jumps[index][0] - 1\n }\n\n return gaps\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\nimport {subtokenize} from 'micromark-util-subtokenize'\n\n/**\n * No name because it must not be turned off.\n * @type {Construct}\n */\nexport const content = {\n tokenize: tokenizeContent,\n resolve: resolveContent\n}\n/** @type {Construct} */\n\nconst continuationConstruct = {\n tokenize: tokenizeContinuation,\n partial: true\n}\n/**\n * Content is transparent: it\u2019s parsed right now. That way, definitions are also\n * parsed right now: before text in paragraphs (specifically, media) are parsed.\n *\n * @type {Resolver}\n */\n\nfunction resolveContent(events) {\n subtokenize(events)\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeContent(effects, ok) {\n /** @type {Token} */\n let previous\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('content')\n previous = effects.enter('chunkContent', {\n contentType: 'content'\n })\n return data(code)\n }\n /** @type {State} */\n\n function data(code) {\n if (code === null) {\n return contentEnd(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.check(\n continuationConstruct,\n contentContinue,\n contentEnd\n )(code)\n } // Data.\n\n effects.consume(code)\n return data\n }\n /** @type {State} */\n\n function contentEnd(code) {\n effects.exit('chunkContent')\n effects.exit('content')\n return ok(code)\n }\n /** @type {State} */\n\n function contentContinue(code) {\n effects.consume(code)\n effects.exit('chunkContent')\n previous.next = effects.enter('chunkContent', {\n contentType: 'content',\n previous\n })\n previous = previous.next\n return data\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeContinuation(effects, ok, nok) {\n const self = this\n return startLookahead\n /** @type {State} */\n\n function startLookahead(code) {\n effects.exit('chunkContent')\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, prefixed, 'linePrefix')\n }\n /** @type {State} */\n\n function prefixed(code) {\n if (code === null || markdownLineEnding(code)) {\n return nok(code)\n }\n\n const tail = self.events[self.events.length - 1]\n\n if (\n !self.parser.constructs.disable.null.includes('codeIndented') &&\n tail &&\n tail[1].type === 'linePrefix' &&\n tail[2].sliceSerialize(tail[1], true).length >= 4\n ) {\n return ok(code)\n }\n\n return effects.interrupt(self.parser.constructs.flow, nok, ok)(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n */\nimport {\n asciiControl,\n markdownLineEndingOrSpace,\n markdownLineEnding\n} from 'micromark-util-character'\n\n/**\n * @param {Effects} effects\n * @param {State} ok\n * @param {State} nok\n * @param {string} type\n * @param {string} literalType\n * @param {string} literalMarkerType\n * @param {string} rawType\n * @param {string} stringType\n * @param {number} [max=Infinity]\n * @returns {State}\n */\n// eslint-disable-next-line max-params\nexport function factoryDestination(\n effects,\n ok,\n nok,\n type,\n literalType,\n literalMarkerType,\n rawType,\n stringType,\n max\n) {\n const limit = max || Number.POSITIVE_INFINITY\n let balance = 0\n return start\n /** @type {State} */\n\n function start(code) {\n if (code === 60) {\n effects.enter(type)\n effects.enter(literalType)\n effects.enter(literalMarkerType)\n effects.consume(code)\n effects.exit(literalMarkerType)\n return destinationEnclosedBefore\n }\n\n if (code === null || code === 41 || asciiControl(code)) {\n return nok(code)\n }\n\n effects.enter(type)\n effects.enter(rawType)\n effects.enter(stringType)\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return destinationRaw(code)\n }\n /** @type {State} */\n\n function destinationEnclosedBefore(code) {\n if (code === 62) {\n effects.enter(literalMarkerType)\n effects.consume(code)\n effects.exit(literalMarkerType)\n effects.exit(literalType)\n effects.exit(type)\n return ok\n }\n\n effects.enter(stringType)\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return destinationEnclosed(code)\n }\n /** @type {State} */\n\n function destinationEnclosed(code) {\n if (code === 62) {\n effects.exit('chunkString')\n effects.exit(stringType)\n return destinationEnclosedBefore(code)\n }\n\n if (code === null || code === 60 || markdownLineEnding(code)) {\n return nok(code)\n }\n\n effects.consume(code)\n return code === 92 ? destinationEnclosedEscape : destinationEnclosed\n }\n /** @type {State} */\n\n function destinationEnclosedEscape(code) {\n if (code === 60 || code === 62 || code === 92) {\n effects.consume(code)\n return destinationEnclosed\n }\n\n return destinationEnclosed(code)\n }\n /** @type {State} */\n\n function destinationRaw(code) {\n if (code === 40) {\n if (++balance > limit) return nok(code)\n effects.consume(code)\n return destinationRaw\n }\n\n if (code === 41) {\n if (!balance--) {\n effects.exit('chunkString')\n effects.exit(stringType)\n effects.exit(rawType)\n effects.exit(type)\n return ok(code)\n }\n\n effects.consume(code)\n return destinationRaw\n }\n\n if (code === null || markdownLineEndingOrSpace(code)) {\n if (balance) return nok(code)\n effects.exit('chunkString')\n effects.exit(stringType)\n effects.exit(rawType)\n effects.exit(type)\n return ok(code)\n }\n\n if (asciiControl(code)) return nok(code)\n effects.consume(code)\n return code === 92 ? destinationRawEscape : destinationRaw\n }\n /** @type {State} */\n\n function destinationRawEscape(code) {\n if (code === 40 || code === 41 || code === 92) {\n effects.consume(code)\n return destinationRaw\n }\n\n return destinationRaw(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownLineEnding, markdownSpace} from 'micromark-util-character'\n\n/**\n * @this {TokenizeContext}\n * @param {Effects} effects\n * @param {State} ok\n * @param {State} nok\n * @param {string} type\n * @param {string} markerType\n * @param {string} stringType\n * @returns {State}\n */\n// eslint-disable-next-line max-params\nexport function factoryLabel(effects, ok, nok, type, markerType, stringType) {\n const self = this\n let size = 0\n /** @type {boolean} */\n\n let data\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter(type)\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n effects.enter(stringType)\n return atBreak\n }\n /** @type {State} */\n\n function atBreak(code) {\n if (\n code === null ||\n code === 91 ||\n (code === 93 && !data) ||\n /* To do: remove in the future once we\u2019ve switched from\n * `micromark-extension-footnote` to `micromark-extension-gfm-footnote`,\n * which doesn\u2019t need this */\n\n /* Hidden footnotes hook */\n\n /* c8 ignore next 3 */\n (code === 94 &&\n !size &&\n '_hiddenFootnoteSupport' in self.parser.constructs) ||\n size > 999\n ) {\n return nok(code)\n }\n\n if (code === 93) {\n effects.exit(stringType)\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n effects.exit(type)\n return ok\n }\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return atBreak\n }\n\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return label(code)\n }\n /** @type {State} */\n\n function label(code) {\n if (\n code === null ||\n code === 91 ||\n code === 93 ||\n markdownLineEnding(code) ||\n size++ > 999\n ) {\n effects.exit('chunkString')\n return atBreak(code)\n }\n\n effects.consume(code)\n data = data || !markdownSpace(code)\n return code === 92 ? labelEscape : label\n }\n /** @type {State} */\n\n function labelEscape(code) {\n if (code === 91 || code === 92 || code === 93) {\n effects.consume(code)\n size++\n return label\n }\n\n return label(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/**\n * @param {Effects} effects\n * @param {State} ok\n * @param {State} nok\n * @param {string} type\n * @param {string} markerType\n * @param {string} stringType\n * @returns {State}\n */\n// eslint-disable-next-line max-params\nexport function factoryTitle(effects, ok, nok, type, markerType, stringType) {\n /** @type {NonNullable} */\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter(type)\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n marker = code === 40 ? 41 : code\n return atFirstTitleBreak\n }\n /** @type {State} */\n\n function atFirstTitleBreak(code) {\n if (code === marker) {\n effects.enter(markerType)\n effects.consume(code)\n effects.exit(markerType)\n effects.exit(type)\n return ok\n }\n\n effects.enter(stringType)\n return atTitleBreak(code)\n }\n /** @type {State} */\n\n function atTitleBreak(code) {\n if (code === marker) {\n effects.exit(stringType)\n return atFirstTitleBreak(marker)\n }\n\n if (code === null) {\n return nok(code)\n } // Note: blank lines can\u2019t exist in content.\n\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, atTitleBreak, 'linePrefix')\n }\n\n effects.enter('chunkString', {\n contentType: 'string'\n })\n return title(code)\n }\n /** @type {State} */\n\n function title(code) {\n if (code === marker || code === null || markdownLineEnding(code)) {\n effects.exit('chunkString')\n return atTitleBreak(code)\n }\n\n effects.consume(code)\n return code === 92 ? titleEscape : title\n }\n /** @type {State} */\n\n function titleEscape(code) {\n if (code === marker || code === 92) {\n effects.consume(code)\n return title\n }\n\n return title(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding, markdownSpace} from 'micromark-util-character'\n\n/**\n * @param {Effects} effects\n * @param {State} ok\n */\nexport function factoryWhitespace(effects, ok) {\n /** @type {boolean} */\n let seen\n return start\n /** @type {State} */\n\n function start(code) {\n if (markdownLineEnding(code)) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n seen = true\n return start\n }\n\n if (markdownSpace(code)) {\n return factorySpace(\n effects,\n start,\n seen ? 'linePrefix' : 'lineSuffix'\n )(code)\n }\n\n return ok(code)\n }\n}\n", "/**\n * Normalize an identifier (such as used in definitions).\n *\n * @param {string} value\n * @returns {string}\n */\nexport function normalizeIdentifier(value) {\n return (\n value // Collapse Markdown whitespace.\n .replace(/[\\t\\n\\r ]+/g, ' ') // Trim.\n .replace(/^ | $/g, '') // Some characters are considered \u201Cuppercase\u201D, but if their lowercase\n // counterpart is uppercased will result in a different uppercase\n // character.\n // Hence, to get that form, we perform both lower- and uppercase.\n // Upper case makes sure keys will not interact with default prototypal\n // methods: no method is uppercase.\n .toLowerCase()\n .toUpperCase()\n )\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factoryDestination} from 'micromark-factory-destination'\nimport {factoryLabel} from 'micromark-factory-label'\nimport {factorySpace} from 'micromark-factory-space'\nimport {factoryTitle} from 'micromark-factory-title'\nimport {factoryWhitespace} from 'micromark-factory-whitespace'\nimport {normalizeIdentifier} from 'micromark-util-normalize-identifier'\nimport {\n markdownLineEnding,\n markdownLineEndingOrSpace\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const definition = {\n name: 'definition',\n tokenize: tokenizeDefinition\n}\n/** @type {Construct} */\n\nconst titleConstruct = {\n tokenize: tokenizeTitle,\n partial: true\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeDefinition(effects, ok, nok) {\n const self = this\n /** @type {string} */\n\n let identifier\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('definition')\n return factoryLabel.call(\n self,\n effects,\n labelAfter,\n nok,\n 'definitionLabel',\n 'definitionLabelMarker',\n 'definitionLabelString'\n )(code)\n }\n /** @type {State} */\n\n function labelAfter(code) {\n identifier = normalizeIdentifier(\n self.sliceSerialize(self.events[self.events.length - 1][1]).slice(1, -1)\n )\n\n if (code === 58) {\n effects.enter('definitionMarker')\n effects.consume(code)\n effects.exit('definitionMarker') // Note: blank lines can\u2019t exist in content.\n\n return factoryWhitespace(\n effects,\n factoryDestination(\n effects,\n effects.attempt(\n titleConstruct,\n factorySpace(effects, after, 'whitespace'),\n factorySpace(effects, after, 'whitespace')\n ),\n nok,\n 'definitionDestination',\n 'definitionDestinationLiteral',\n 'definitionDestinationLiteralMarker',\n 'definitionDestinationRaw',\n 'definitionDestinationString'\n )\n )\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('definition')\n\n if (!self.parser.defined.includes(identifier)) {\n self.parser.defined.push(identifier)\n }\n\n return ok(code)\n }\n\n return nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeTitle(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n return markdownLineEndingOrSpace(code)\n ? factoryWhitespace(effects, before)(code)\n : nok(code)\n }\n /** @type {State} */\n\n function before(code) {\n if (code === 34 || code === 39 || code === 40) {\n return factoryTitle(\n effects,\n factorySpace(effects, after, 'whitespace'),\n nok,\n 'definitionTitle',\n 'definitionTitleMarker',\n 'definitionTitleString'\n )(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n return code === null || markdownLineEnding(code) ? ok(code) : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const hardBreakEscape = {\n name: 'hardBreakEscape',\n tokenize: tokenizeHardBreakEscape\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHardBreakEscape(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('hardBreakEscape')\n effects.enter('escapeMarker')\n effects.consume(code)\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (markdownLineEnding(code)) {\n effects.exit('escapeMarker')\n effects.exit('hardBreakEscape')\n return ok(code)\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {\n markdownLineEnding,\n markdownLineEndingOrSpace,\n markdownSpace\n} from 'micromark-util-character'\nimport {splice} from 'micromark-util-chunked'\n\n/** @type {Construct} */\nexport const headingAtx = {\n name: 'headingAtx',\n tokenize: tokenizeHeadingAtx,\n resolve: resolveHeadingAtx\n}\n/** @type {Resolver} */\n\nfunction resolveHeadingAtx(events, context) {\n let contentEnd = events.length - 2\n let contentStart = 3\n /** @type {Token} */\n\n let content\n /** @type {Token} */\n\n let text // Prefix whitespace, part of the opening.\n\n if (events[contentStart][1].type === 'whitespace') {\n contentStart += 2\n } // Suffix whitespace, part of the closing.\n\n if (\n contentEnd - 2 > contentStart &&\n events[contentEnd][1].type === 'whitespace'\n ) {\n contentEnd -= 2\n }\n\n if (\n events[contentEnd][1].type === 'atxHeadingSequence' &&\n (contentStart === contentEnd - 1 ||\n (contentEnd - 4 > contentStart &&\n events[contentEnd - 2][1].type === 'whitespace'))\n ) {\n contentEnd -= contentStart + 1 === contentEnd ? 2 : 4\n }\n\n if (contentEnd > contentStart) {\n content = {\n type: 'atxHeadingText',\n start: events[contentStart][1].start,\n end: events[contentEnd][1].end\n }\n text = {\n type: 'chunkText',\n start: events[contentStart][1].start,\n end: events[contentEnd][1].end,\n // @ts-expect-error Constants are fine to assign.\n contentType: 'text'\n }\n splice(events, contentStart, contentEnd - contentStart + 1, [\n ['enter', content, context],\n ['enter', text, context],\n ['exit', text, context],\n ['exit', content, context]\n ])\n }\n\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHeadingAtx(effects, ok, nok) {\n const self = this\n let size = 0\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('atxHeading')\n effects.enter('atxHeadingSequence')\n return fenceOpenInside(code)\n }\n /** @type {State} */\n\n function fenceOpenInside(code) {\n if (code === 35 && size++ < 6) {\n effects.consume(code)\n return fenceOpenInside\n }\n\n if (code === null || markdownLineEndingOrSpace(code)) {\n effects.exit('atxHeadingSequence')\n return self.interrupt ? ok(code) : headingBreak(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function headingBreak(code) {\n if (code === 35) {\n effects.enter('atxHeadingSequence')\n return sequence(code)\n }\n\n if (code === null || markdownLineEnding(code)) {\n effects.exit('atxHeading')\n return ok(code)\n }\n\n if (markdownSpace(code)) {\n return factorySpace(effects, headingBreak, 'whitespace')(code)\n }\n\n effects.enter('atxHeadingText')\n return data(code)\n }\n /** @type {State} */\n\n function sequence(code) {\n if (code === 35) {\n effects.consume(code)\n return sequence\n }\n\n effects.exit('atxHeadingSequence')\n return headingBreak(code)\n }\n /** @type {State} */\n\n function data(code) {\n if (code === null || code === 35 || markdownLineEndingOrSpace(code)) {\n effects.exit('atxHeadingText')\n return headingBreak(code)\n }\n\n effects.consume(code)\n return data\n }\n}\n", "/**\n * List of lowercase HTML tag names which when parsing HTML (flow), result\n * in more relaxed rules (condition 6): because they are known blocks, the\n * HTML-like syntax doesn\u2019t have to be strictly parsed.\n * For tag names not in this list, a more strict algorithm (condition 7) is used\n * to detect whether the HTML-like syntax is seen as HTML (flow) or not.\n *\n * This is copied from:\n * .\n */\nexport const htmlBlockNames = [\n 'address',\n 'article',\n 'aside',\n 'base',\n 'basefont',\n 'blockquote',\n 'body',\n 'caption',\n 'center',\n 'col',\n 'colgroup',\n 'dd',\n 'details',\n 'dialog',\n 'dir',\n 'div',\n 'dl',\n 'dt',\n 'fieldset',\n 'figcaption',\n 'figure',\n 'footer',\n 'form',\n 'frame',\n 'frameset',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'head',\n 'header',\n 'hr',\n 'html',\n 'iframe',\n 'legend',\n 'li',\n 'link',\n 'main',\n 'menu',\n 'menuitem',\n 'nav',\n 'noframes',\n 'ol',\n 'optgroup',\n 'option',\n 'p',\n 'param',\n 'section',\n 'summary',\n 'table',\n 'tbody',\n 'td',\n 'tfoot',\n 'th',\n 'thead',\n 'title',\n 'tr',\n 'track',\n 'ul'\n]\n\n/**\n * List of lowercase HTML tag names which when parsing HTML (flow), result in\n * HTML that can include lines w/o exiting, until a closing tag also in this\n * list is found (condition 1).\n *\n * This module is copied from:\n * .\n *\n * Note that `textarea` was added in `CommonMark@0.30`.\n */\nexport const htmlRawNames = ['pre', 'script', 'style', 'textarea']\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {\n asciiAlpha,\n asciiAlphanumeric,\n markdownLineEnding,\n markdownLineEndingOrSpace,\n markdownSpace\n} from 'micromark-util-character'\nimport {htmlBlockNames, htmlRawNames} from 'micromark-util-html-tag-name'\nimport {blankLine} from './blank-line.js'\n/** @type {Construct} */\n\nexport const htmlFlow = {\n name: 'htmlFlow',\n tokenize: tokenizeHtmlFlow,\n resolveTo: resolveToHtmlFlow,\n concrete: true\n}\n/** @type {Construct} */\n\nconst nextBlankConstruct = {\n tokenize: tokenizeNextBlank,\n partial: true\n}\n/** @type {Resolver} */\n\nfunction resolveToHtmlFlow(events) {\n let index = events.length\n\n while (index--) {\n if (events[index][0] === 'enter' && events[index][1].type === 'htmlFlow') {\n break\n }\n }\n\n if (index > 1 && events[index - 2][1].type === 'linePrefix') {\n // Add the prefix start to the HTML token.\n events[index][1].start = events[index - 2][1].start // Add the prefix start to the HTML line token.\n\n events[index + 1][1].start = events[index - 2][1].start // Remove the line prefix.\n\n events.splice(index - 2, 2)\n }\n\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHtmlFlow(effects, ok, nok) {\n const self = this\n /** @type {number} */\n\n let kind\n /** @type {boolean} */\n\n let startTag\n /** @type {string} */\n\n let buffer\n /** @type {number} */\n\n let index\n /** @type {Code} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('htmlFlow')\n effects.enter('htmlFlowData')\n effects.consume(code)\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 33) {\n effects.consume(code)\n return declarationStart\n }\n\n if (code === 47) {\n effects.consume(code)\n return tagCloseStart\n }\n\n if (code === 63) {\n effects.consume(code)\n kind = 3 // While we\u2019re in an instruction instead of a declaration, we\u2019re on a `?`\n // right now, so we do need to search for `>`, similar to declarations.\n\n return self.interrupt ? ok : continuationDeclarationInside\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n buffer = String.fromCharCode(code)\n startTag = true\n return tagName\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function declarationStart(code) {\n if (code === 45) {\n effects.consume(code)\n kind = 2\n return commentOpenInside\n }\n\n if (code === 91) {\n effects.consume(code)\n kind = 5\n buffer = 'CDATA['\n index = 0\n return cdataOpenInside\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n kind = 4\n return self.interrupt ? ok : continuationDeclarationInside\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function commentOpenInside(code) {\n if (code === 45) {\n effects.consume(code)\n return self.interrupt ? ok : continuationDeclarationInside\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function cdataOpenInside(code) {\n if (code === buffer.charCodeAt(index++)) {\n effects.consume(code)\n return index === buffer.length\n ? self.interrupt\n ? ok\n : continuation\n : cdataOpenInside\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagCloseStart(code) {\n if (asciiAlpha(code)) {\n effects.consume(code)\n buffer = String.fromCharCode(code)\n return tagName\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagName(code) {\n if (\n code === null ||\n code === 47 ||\n code === 62 ||\n markdownLineEndingOrSpace(code)\n ) {\n if (\n code !== 47 &&\n startTag &&\n htmlRawNames.includes(buffer.toLowerCase())\n ) {\n kind = 1\n return self.interrupt ? ok(code) : continuation(code)\n }\n\n if (htmlBlockNames.includes(buffer.toLowerCase())) {\n kind = 6\n\n if (code === 47) {\n effects.consume(code)\n return basicSelfClosing\n }\n\n return self.interrupt ? ok(code) : continuation(code)\n }\n\n kind = 7 // Do not support complete HTML when interrupting\n\n return self.interrupt && !self.parser.lazy[self.now().line]\n ? nok(code)\n : startTag\n ? completeAttributeNameBefore(code)\n : completeClosingTagAfter(code)\n }\n\n if (code === 45 || asciiAlphanumeric(code)) {\n effects.consume(code)\n buffer += String.fromCharCode(code)\n return tagName\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function basicSelfClosing(code) {\n if (code === 62) {\n effects.consume(code)\n return self.interrupt ? ok : continuation\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function completeClosingTagAfter(code) {\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeClosingTagAfter\n }\n\n return completeEnd(code)\n }\n /** @type {State} */\n\n function completeAttributeNameBefore(code) {\n if (code === 47) {\n effects.consume(code)\n return completeEnd\n }\n\n if (code === 58 || code === 95 || asciiAlpha(code)) {\n effects.consume(code)\n return completeAttributeName\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAttributeNameBefore\n }\n\n return completeEnd(code)\n }\n /** @type {State} */\n\n function completeAttributeName(code) {\n if (\n code === 45 ||\n code === 46 ||\n code === 58 ||\n code === 95 ||\n asciiAlphanumeric(code)\n ) {\n effects.consume(code)\n return completeAttributeName\n }\n\n return completeAttributeNameAfter(code)\n }\n /** @type {State} */\n\n function completeAttributeNameAfter(code) {\n if (code === 61) {\n effects.consume(code)\n return completeAttributeValueBefore\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAttributeNameAfter\n }\n\n return completeAttributeNameBefore(code)\n }\n /** @type {State} */\n\n function completeAttributeValueBefore(code) {\n if (\n code === null ||\n code === 60 ||\n code === 61 ||\n code === 62 ||\n code === 96\n ) {\n return nok(code)\n }\n\n if (code === 34 || code === 39) {\n effects.consume(code)\n marker = code\n return completeAttributeValueQuoted\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAttributeValueBefore\n }\n\n marker = null\n return completeAttributeValueUnquoted(code)\n }\n /** @type {State} */\n\n function completeAttributeValueQuoted(code) {\n if (code === null || markdownLineEnding(code)) {\n return nok(code)\n }\n\n if (code === marker) {\n effects.consume(code)\n return completeAttributeValueQuotedAfter\n }\n\n effects.consume(code)\n return completeAttributeValueQuoted\n }\n /** @type {State} */\n\n function completeAttributeValueUnquoted(code) {\n if (\n code === null ||\n code === 34 ||\n code === 39 ||\n code === 60 ||\n code === 61 ||\n code === 62 ||\n code === 96 ||\n markdownLineEndingOrSpace(code)\n ) {\n return completeAttributeNameAfter(code)\n }\n\n effects.consume(code)\n return completeAttributeValueUnquoted\n }\n /** @type {State} */\n\n function completeAttributeValueQuotedAfter(code) {\n if (code === 47 || code === 62 || markdownSpace(code)) {\n return completeAttributeNameBefore(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function completeEnd(code) {\n if (code === 62) {\n effects.consume(code)\n return completeAfter\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function completeAfter(code) {\n if (markdownSpace(code)) {\n effects.consume(code)\n return completeAfter\n }\n\n return code === null || markdownLineEnding(code)\n ? continuation(code)\n : nok(code)\n }\n /** @type {State} */\n\n function continuation(code) {\n if (code === 45 && kind === 2) {\n effects.consume(code)\n return continuationCommentInside\n }\n\n if (code === 60 && kind === 1) {\n effects.consume(code)\n return continuationRawTagOpen\n }\n\n if (code === 62 && kind === 4) {\n effects.consume(code)\n return continuationClose\n }\n\n if (code === 63 && kind === 3) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n if (code === 93 && kind === 5) {\n effects.consume(code)\n return continuationCharacterDataInside\n }\n\n if (markdownLineEnding(code) && (kind === 6 || kind === 7)) {\n return effects.check(\n nextBlankConstruct,\n continuationClose,\n continuationAtLineEnding\n )(code)\n }\n\n if (code === null || markdownLineEnding(code)) {\n return continuationAtLineEnding(code)\n }\n\n effects.consume(code)\n return continuation\n }\n /** @type {State} */\n\n function continuationAtLineEnding(code) {\n effects.exit('htmlFlowData')\n return htmlContinueStart(code)\n }\n /** @type {State} */\n\n function htmlContinueStart(code) {\n if (code === null) {\n return done(code)\n }\n\n if (markdownLineEnding(code)) {\n return effects.attempt(\n {\n tokenize: htmlLineEnd,\n partial: true\n },\n htmlContinueStart,\n done\n )(code)\n }\n\n effects.enter('htmlFlowData')\n return continuation(code)\n }\n /** @type {Tokenizer} */\n\n function htmlLineEnd(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return lineStart\n }\n /** @type {State} */\n\n function lineStart(code) {\n return self.parser.lazy[self.now().line] ? nok(code) : ok(code)\n }\n }\n /** @type {State} */\n\n function continuationCommentInside(code) {\n if (code === 45) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationRawTagOpen(code) {\n if (code === 47) {\n effects.consume(code)\n buffer = ''\n return continuationRawEndTag\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationRawEndTag(code) {\n if (code === 62 && htmlRawNames.includes(buffer.toLowerCase())) {\n effects.consume(code)\n return continuationClose\n }\n\n if (asciiAlpha(code) && buffer.length < 8) {\n effects.consume(code)\n buffer += String.fromCharCode(code)\n return continuationRawEndTag\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationCharacterDataInside(code) {\n if (code === 93) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationDeclarationInside(code) {\n if (code === 62) {\n effects.consume(code)\n return continuationClose\n } // More dashes.\n\n if (code === 45 && kind === 2) {\n effects.consume(code)\n return continuationDeclarationInside\n }\n\n return continuation(code)\n }\n /** @type {State} */\n\n function continuationClose(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('htmlFlowData')\n return done(code)\n }\n\n effects.consume(code)\n return continuationClose\n }\n /** @type {State} */\n\n function done(code) {\n effects.exit('htmlFlow')\n return ok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeNextBlank(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.exit('htmlFlowData')\n effects.enter('lineEndingBlank')\n effects.consume(code)\n effects.exit('lineEndingBlank')\n return effects.attempt(blankLine, ok, nok)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {\n asciiAlpha,\n asciiAlphanumeric,\n markdownLineEnding,\n markdownLineEndingOrSpace,\n markdownSpace\n} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const htmlText = {\n name: 'htmlText',\n tokenize: tokenizeHtmlText\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeHtmlText(effects, ok, nok) {\n const self = this\n /** @type {NonNullable|undefined} */\n\n let marker\n /** @type {string} */\n\n let buffer\n /** @type {number} */\n\n let index\n /** @type {State} */\n\n let returnState\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('htmlText')\n effects.enter('htmlTextData')\n effects.consume(code)\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 33) {\n effects.consume(code)\n return declarationOpen\n }\n\n if (code === 47) {\n effects.consume(code)\n return tagCloseStart\n }\n\n if (code === 63) {\n effects.consume(code)\n return instruction\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n return tagOpen\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function declarationOpen(code) {\n if (code === 45) {\n effects.consume(code)\n return commentOpen\n }\n\n if (code === 91) {\n effects.consume(code)\n buffer = 'CDATA['\n index = 0\n return cdataOpen\n }\n\n if (asciiAlpha(code)) {\n effects.consume(code)\n return declaration\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function commentOpen(code) {\n if (code === 45) {\n effects.consume(code)\n return commentStart\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function commentStart(code) {\n if (code === null || code === 62) {\n return nok(code)\n }\n\n if (code === 45) {\n effects.consume(code)\n return commentStartDash\n }\n\n return comment(code)\n }\n /** @type {State} */\n\n function commentStartDash(code) {\n if (code === null || code === 62) {\n return nok(code)\n }\n\n return comment(code)\n }\n /** @type {State} */\n\n function comment(code) {\n if (code === null) {\n return nok(code)\n }\n\n if (code === 45) {\n effects.consume(code)\n return commentClose\n }\n\n if (markdownLineEnding(code)) {\n returnState = comment\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return comment\n }\n /** @type {State} */\n\n function commentClose(code) {\n if (code === 45) {\n effects.consume(code)\n return end\n }\n\n return comment(code)\n }\n /** @type {State} */\n\n function cdataOpen(code) {\n if (code === buffer.charCodeAt(index++)) {\n effects.consume(code)\n return index === buffer.length ? cdata : cdataOpen\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function cdata(code) {\n if (code === null) {\n return nok(code)\n }\n\n if (code === 93) {\n effects.consume(code)\n return cdataClose\n }\n\n if (markdownLineEnding(code)) {\n returnState = cdata\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return cdata\n }\n /** @type {State} */\n\n function cdataClose(code) {\n if (code === 93) {\n effects.consume(code)\n return cdataEnd\n }\n\n return cdata(code)\n }\n /** @type {State} */\n\n function cdataEnd(code) {\n if (code === 62) {\n return end(code)\n }\n\n if (code === 93) {\n effects.consume(code)\n return cdataEnd\n }\n\n return cdata(code)\n }\n /** @type {State} */\n\n function declaration(code) {\n if (code === null || code === 62) {\n return end(code)\n }\n\n if (markdownLineEnding(code)) {\n returnState = declaration\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return declaration\n }\n /** @type {State} */\n\n function instruction(code) {\n if (code === null) {\n return nok(code)\n }\n\n if (code === 63) {\n effects.consume(code)\n return instructionClose\n }\n\n if (markdownLineEnding(code)) {\n returnState = instruction\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return instruction\n }\n /** @type {State} */\n\n function instructionClose(code) {\n return code === 62 ? end(code) : instruction(code)\n }\n /** @type {State} */\n\n function tagCloseStart(code) {\n if (asciiAlpha(code)) {\n effects.consume(code)\n return tagClose\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagClose(code) {\n if (code === 45 || asciiAlphanumeric(code)) {\n effects.consume(code)\n return tagClose\n }\n\n return tagCloseBetween(code)\n }\n /** @type {State} */\n\n function tagCloseBetween(code) {\n if (markdownLineEnding(code)) {\n returnState = tagCloseBetween\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagCloseBetween\n }\n\n return end(code)\n }\n /** @type {State} */\n\n function tagOpen(code) {\n if (code === 45 || asciiAlphanumeric(code)) {\n effects.consume(code)\n return tagOpen\n }\n\n if (code === 47 || code === 62 || markdownLineEndingOrSpace(code)) {\n return tagOpenBetween(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagOpenBetween(code) {\n if (code === 47) {\n effects.consume(code)\n return end\n }\n\n if (code === 58 || code === 95 || asciiAlpha(code)) {\n effects.consume(code)\n return tagOpenAttributeName\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenBetween\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagOpenBetween\n }\n\n return end(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeName(code) {\n if (\n code === 45 ||\n code === 46 ||\n code === 58 ||\n code === 95 ||\n asciiAlphanumeric(code)\n ) {\n effects.consume(code)\n return tagOpenAttributeName\n }\n\n return tagOpenAttributeNameAfter(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeNameAfter(code) {\n if (code === 61) {\n effects.consume(code)\n return tagOpenAttributeValueBefore\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenAttributeNameAfter\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagOpenAttributeNameAfter\n }\n\n return tagOpenBetween(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeValueBefore(code) {\n if (\n code === null ||\n code === 60 ||\n code === 61 ||\n code === 62 ||\n code === 96\n ) {\n return nok(code)\n }\n\n if (code === 34 || code === 39) {\n effects.consume(code)\n marker = code\n return tagOpenAttributeValueQuoted\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenAttributeValueBefore\n return atLineEnding(code)\n }\n\n if (markdownSpace(code)) {\n effects.consume(code)\n return tagOpenAttributeValueBefore\n }\n\n effects.consume(code)\n marker = undefined\n return tagOpenAttributeValueUnquoted\n }\n /** @type {State} */\n\n function tagOpenAttributeValueQuoted(code) {\n if (code === marker) {\n effects.consume(code)\n return tagOpenAttributeValueQuotedAfter\n }\n\n if (code === null) {\n return nok(code)\n }\n\n if (markdownLineEnding(code)) {\n returnState = tagOpenAttributeValueQuoted\n return atLineEnding(code)\n }\n\n effects.consume(code)\n return tagOpenAttributeValueQuoted\n }\n /** @type {State} */\n\n function tagOpenAttributeValueQuotedAfter(code) {\n if (code === 62 || code === 47 || markdownLineEndingOrSpace(code)) {\n return tagOpenBetween(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function tagOpenAttributeValueUnquoted(code) {\n if (\n code === null ||\n code === 34 ||\n code === 39 ||\n code === 60 ||\n code === 61 ||\n code === 96\n ) {\n return nok(code)\n }\n\n if (code === 62 || markdownLineEndingOrSpace(code)) {\n return tagOpenBetween(code)\n }\n\n effects.consume(code)\n return tagOpenAttributeValueUnquoted\n } // We can\u2019t have blank lines in content, so no need to worry about empty\n // tokens.\n\n /** @type {State} */\n\n function atLineEnding(code) {\n effects.exit('htmlTextData')\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(\n effects,\n afterPrefix,\n 'linePrefix',\n self.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4\n )\n }\n /** @type {State} */\n\n function afterPrefix(code) {\n effects.enter('htmlTextData')\n return returnState(code)\n }\n /** @type {State} */\n\n function end(code) {\n if (code === 62) {\n effects.consume(code)\n effects.exit('htmlTextData')\n effects.exit('htmlText')\n return ok\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factoryDestination} from 'micromark-factory-destination'\nimport {factoryLabel} from 'micromark-factory-label'\nimport {factoryTitle} from 'micromark-factory-title'\nimport {factoryWhitespace} from 'micromark-factory-whitespace'\nimport {markdownLineEndingOrSpace} from 'micromark-util-character'\nimport {push, splice} from 'micromark-util-chunked'\nimport {normalizeIdentifier} from 'micromark-util-normalize-identifier'\nimport {resolveAll} from 'micromark-util-resolve-all'\n\n/** @type {Construct} */\nexport const labelEnd = {\n name: 'labelEnd',\n tokenize: tokenizeLabelEnd,\n resolveTo: resolveToLabelEnd,\n resolveAll: resolveAllLabelEnd\n}\n/** @type {Construct} */\n\nconst resourceConstruct = {\n tokenize: tokenizeResource\n}\n/** @type {Construct} */\n\nconst fullReferenceConstruct = {\n tokenize: tokenizeFullReference\n}\n/** @type {Construct} */\n\nconst collapsedReferenceConstruct = {\n tokenize: tokenizeCollapsedReference\n}\n/** @type {Resolver} */\n\nfunction resolveAllLabelEnd(events) {\n let index = -1\n /** @type {Token} */\n\n let token\n\n while (++index < events.length) {\n token = events[index][1]\n\n if (\n token.type === 'labelImage' ||\n token.type === 'labelLink' ||\n token.type === 'labelEnd'\n ) {\n // Remove the marker.\n events.splice(index + 1, token.type === 'labelImage' ? 4 : 2)\n token.type = 'data'\n index++\n }\n }\n\n return events\n}\n/** @type {Resolver} */\n\nfunction resolveToLabelEnd(events, context) {\n let index = events.length\n let offset = 0\n /** @type {Token} */\n\n let token\n /** @type {number|undefined} */\n\n let open\n /** @type {number|undefined} */\n\n let close\n /** @type {Event[]} */\n\n let media // Find an opening.\n\n while (index--) {\n token = events[index][1]\n\n if (open) {\n // If we see another link, or inactive link label, we\u2019ve been here before.\n if (\n token.type === 'link' ||\n (token.type === 'labelLink' && token._inactive)\n ) {\n break\n } // Mark other link openings as inactive, as we can\u2019t have links in\n // links.\n\n if (events[index][0] === 'enter' && token.type === 'labelLink') {\n token._inactive = true\n }\n } else if (close) {\n if (\n events[index][0] === 'enter' &&\n (token.type === 'labelImage' || token.type === 'labelLink') &&\n !token._balanced\n ) {\n open = index\n\n if (token.type !== 'labelLink') {\n offset = 2\n break\n }\n }\n } else if (token.type === 'labelEnd') {\n close = index\n }\n }\n\n const group = {\n type: events[open][1].type === 'labelLink' ? 'link' : 'image',\n start: Object.assign({}, events[open][1].start),\n end: Object.assign({}, events[events.length - 1][1].end)\n }\n const label = {\n type: 'label',\n start: Object.assign({}, events[open][1].start),\n end: Object.assign({}, events[close][1].end)\n }\n const text = {\n type: 'labelText',\n start: Object.assign({}, events[open + offset + 2][1].end),\n end: Object.assign({}, events[close - 2][1].start)\n }\n media = [\n ['enter', group, context],\n ['enter', label, context]\n ] // Opening marker.\n\n media = push(media, events.slice(open + 1, open + offset + 3)) // Text open.\n\n media = push(media, [['enter', text, context]]) // Between.\n\n media = push(\n media,\n resolveAll(\n context.parser.constructs.insideSpan.null,\n events.slice(open + offset + 4, close - 3),\n context\n )\n ) // Text close, marker close, label close.\n\n media = push(media, [\n ['exit', text, context],\n events[close - 2],\n events[close - 1],\n ['exit', label, context]\n ]) // Reference, resource, or so.\n\n media = push(media, events.slice(close + 1)) // Media close.\n\n media = push(media, [['exit', group, context]])\n splice(events, open, events.length, media)\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLabelEnd(effects, ok, nok) {\n const self = this\n let index = self.events.length\n /** @type {Token} */\n\n let labelStart\n /** @type {boolean} */\n\n let defined // Find an opening.\n\n while (index--) {\n if (\n (self.events[index][1].type === 'labelImage' ||\n self.events[index][1].type === 'labelLink') &&\n !self.events[index][1]._balanced\n ) {\n labelStart = self.events[index][1]\n break\n }\n }\n\n return start\n /** @type {State} */\n\n function start(code) {\n if (!labelStart) {\n return nok(code)\n } // It\u2019s a balanced bracket, but contains a link.\n\n if (labelStart._inactive) return balanced(code)\n defined = self.parser.defined.includes(\n normalizeIdentifier(\n self.sliceSerialize({\n start: labelStart.end,\n end: self.now()\n })\n )\n )\n effects.enter('labelEnd')\n effects.enter('labelMarker')\n effects.consume(code)\n effects.exit('labelMarker')\n effects.exit('labelEnd')\n return afterLabelEnd\n }\n /** @type {State} */\n\n function afterLabelEnd(code) {\n // Resource: `[asd](fgh)`.\n if (code === 40) {\n return effects.attempt(\n resourceConstruct,\n ok,\n defined ? ok : balanced\n )(code)\n } // Collapsed (`[asd][]`) or full (`[asd][fgh]`) reference?\n\n if (code === 91) {\n return effects.attempt(\n fullReferenceConstruct,\n ok,\n defined\n ? effects.attempt(collapsedReferenceConstruct, ok, balanced)\n : balanced\n )(code)\n } // Shortcut reference: `[asd]`?\n\n return defined ? ok(code) : balanced(code)\n }\n /** @type {State} */\n\n function balanced(code) {\n labelStart._balanced = true\n return nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeResource(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('resource')\n effects.enter('resourceMarker')\n effects.consume(code)\n effects.exit('resourceMarker')\n return factoryWhitespace(effects, open)\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 41) {\n return end(code)\n }\n\n return factoryDestination(\n effects,\n destinationAfter,\n nok,\n 'resourceDestination',\n 'resourceDestinationLiteral',\n 'resourceDestinationLiteralMarker',\n 'resourceDestinationRaw',\n 'resourceDestinationString',\n 32\n )(code)\n }\n /** @type {State} */\n\n function destinationAfter(code) {\n return markdownLineEndingOrSpace(code)\n ? factoryWhitespace(effects, between)(code)\n : end(code)\n }\n /** @type {State} */\n\n function between(code) {\n if (code === 34 || code === 39 || code === 40) {\n return factoryTitle(\n effects,\n factoryWhitespace(effects, end),\n nok,\n 'resourceTitle',\n 'resourceTitleMarker',\n 'resourceTitleString'\n )(code)\n }\n\n return end(code)\n }\n /** @type {State} */\n\n function end(code) {\n if (code === 41) {\n effects.enter('resourceMarker')\n effects.consume(code)\n effects.exit('resourceMarker')\n effects.exit('resource')\n return ok\n }\n\n return nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeFullReference(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n return factoryLabel.call(\n self,\n effects,\n afterLabel,\n nok,\n 'reference',\n 'referenceMarker',\n 'referenceString'\n )(code)\n }\n /** @type {State} */\n\n function afterLabel(code) {\n return self.parser.defined.includes(\n normalizeIdentifier(\n self.sliceSerialize(self.events[self.events.length - 1][1]).slice(1, -1)\n )\n )\n ? ok(code)\n : nok(code)\n }\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeCollapsedReference(effects, ok, nok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('reference')\n effects.enter('referenceMarker')\n effects.consume(code)\n effects.exit('referenceMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 93) {\n effects.enter('referenceMarker')\n effects.consume(code)\n effects.exit('referenceMarker')\n effects.exit('reference')\n return ok\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {labelEnd} from './label-end.js'\n/** @type {Construct} */\n\nexport const labelStartImage = {\n name: 'labelStartImage',\n tokenize: tokenizeLabelStartImage,\n resolveAll: labelEnd.resolveAll\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLabelStartImage(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('labelImage')\n effects.enter('labelImageMarker')\n effects.consume(code)\n effects.exit('labelImageMarker')\n return open\n }\n /** @type {State} */\n\n function open(code) {\n if (code === 91) {\n effects.enter('labelMarker')\n effects.consume(code)\n effects.exit('labelMarker')\n effects.exit('labelImage')\n return after\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function after(code) {\n /* To do: remove in the future once we\u2019ve switched from\n * `micromark-extension-footnote` to `micromark-extension-gfm-footnote`,\n * which doesn\u2019t need this */\n\n /* Hidden footnotes hook */\n\n /* c8 ignore next 3 */\n return code === 94 && '_hiddenFootnoteSupport' in self.parser.constructs\n ? nok(code)\n : ok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {labelEnd} from './label-end.js'\n/** @type {Construct} */\n\nexport const labelStartLink = {\n name: 'labelStartLink',\n tokenize: tokenizeLabelStartLink,\n resolveAll: labelEnd.resolveAll\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLabelStartLink(effects, ok, nok) {\n const self = this\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('labelLink')\n effects.enter('labelMarker')\n effects.consume(code)\n effects.exit('labelMarker')\n effects.exit('labelLink')\n return after\n }\n /** @type {State} */\n\n function after(code) {\n /* To do: remove in the future once we\u2019ve switched from\n * `micromark-extension-footnote` to `micromark-extension-gfm-footnote`,\n * which doesn\u2019t need this */\n\n /* Hidden footnotes hook. */\n\n /* c8 ignore next 3 */\n return code === 94 && '_hiddenFootnoteSupport' in self.parser.constructs\n ? nok(code)\n : ok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const lineEnding = {\n name: 'lineEnding',\n tokenize: tokenizeLineEnding\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeLineEnding(effects, ok) {\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n return factorySpace(effects, ok, 'linePrefix')\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding, markdownSpace} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const thematicBreak = {\n name: 'thematicBreak',\n tokenize: tokenizeThematicBreak\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeThematicBreak(effects, ok, nok) {\n let size = 0\n /** @type {NonNullable} */\n\n let marker\n return start\n /** @type {State} */\n\n function start(code) {\n effects.enter('thematicBreak')\n marker = code\n return atBreak(code)\n }\n /** @type {State} */\n\n function atBreak(code) {\n if (code === marker) {\n effects.enter('thematicBreakSequence')\n return sequence(code)\n }\n\n if (markdownSpace(code)) {\n return factorySpace(effects, atBreak, 'whitespace')(code)\n }\n\n if (size < 3 || (code !== null && !markdownLineEnding(code))) {\n return nok(code)\n }\n\n effects.exit('thematicBreak')\n return ok(code)\n }\n /** @type {State} */\n\n function sequence(code) {\n if (code === marker) {\n effects.consume(code)\n size++\n return sequence\n }\n\n effects.exit('thematicBreakSequence')\n return atBreak(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Exiter} Exiter\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\n\n/**\n * @typedef {Record & {marker: Code, type: string, size: number}} ListContainerState\n * @typedef {TokenizeContext & {containerState: ListContainerState}} TokenizeContextWithState\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {asciiDigit, markdownSpace} from 'micromark-util-character'\nimport {blankLine} from './blank-line.js'\nimport {thematicBreak} from './thematic-break.js'\n/** @type {Construct} */\n\nexport const list = {\n name: 'list',\n tokenize: tokenizeListStart,\n continuation: {\n tokenize: tokenizeListContinuation\n },\n exit: tokenizeListEnd\n}\n/** @type {Construct} */\n\nconst listItemPrefixWhitespaceConstruct = {\n tokenize: tokenizeListItemPrefixWhitespace,\n partial: true\n}\n/** @type {Construct} */\n\nconst indentConstruct = {\n tokenize: tokenizeIndent,\n partial: true\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListStart(effects, ok, nok) {\n const self = this\n const tail = self.events[self.events.length - 1]\n let initialSize =\n tail && tail[1].type === 'linePrefix'\n ? tail[2].sliceSerialize(tail[1], true).length\n : 0\n let size = 0\n return start\n /** @type {State} */\n\n function start(code) {\n const kind =\n self.containerState.type ||\n (code === 42 || code === 43 || code === 45\n ? 'listUnordered'\n : 'listOrdered')\n\n if (\n kind === 'listUnordered'\n ? !self.containerState.marker || code === self.containerState.marker\n : asciiDigit(code)\n ) {\n if (!self.containerState.type) {\n self.containerState.type = kind\n effects.enter(kind, {\n _container: true\n })\n }\n\n if (kind === 'listUnordered') {\n effects.enter('listItemPrefix')\n return code === 42 || code === 45\n ? effects.check(thematicBreak, nok, atMarker)(code)\n : atMarker(code)\n }\n\n if (!self.interrupt || code === 49) {\n effects.enter('listItemPrefix')\n effects.enter('listItemValue')\n return inside(code)\n }\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function inside(code) {\n if (asciiDigit(code) && ++size < 10) {\n effects.consume(code)\n return inside\n }\n\n if (\n (!self.interrupt || size < 2) &&\n (self.containerState.marker\n ? code === self.containerState.marker\n : code === 41 || code === 46)\n ) {\n effects.exit('listItemValue')\n return atMarker(code)\n }\n\n return nok(code)\n }\n /**\n * @type {State}\n **/\n\n function atMarker(code) {\n effects.enter('listItemMarker')\n effects.consume(code)\n effects.exit('listItemMarker')\n self.containerState.marker = self.containerState.marker || code\n return effects.check(\n blankLine, // Can\u2019t be empty when interrupting.\n self.interrupt ? nok : onBlank,\n effects.attempt(\n listItemPrefixWhitespaceConstruct,\n endOfPrefix,\n otherPrefix\n )\n )\n }\n /** @type {State} */\n\n function onBlank(code) {\n self.containerState.initialBlankLine = true\n initialSize++\n return endOfPrefix(code)\n }\n /** @type {State} */\n\n function otherPrefix(code) {\n if (markdownSpace(code)) {\n effects.enter('listItemPrefixWhitespace')\n effects.consume(code)\n effects.exit('listItemPrefixWhitespace')\n return endOfPrefix\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function endOfPrefix(code) {\n self.containerState.size =\n initialSize +\n self.sliceSerialize(effects.exit('listItemPrefix'), true).length\n return ok(code)\n }\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListContinuation(effects, ok, nok) {\n const self = this\n self.containerState._closeFlow = undefined\n return effects.check(blankLine, onBlank, notBlank)\n /** @type {State} */\n\n function onBlank(code) {\n self.containerState.furtherBlankLines =\n self.containerState.furtherBlankLines ||\n self.containerState.initialBlankLine // We have a blank line.\n // Still, try to consume at most the items size.\n\n return factorySpace(\n effects,\n ok,\n 'listItemIndent',\n self.containerState.size + 1\n )(code)\n }\n /** @type {State} */\n\n function notBlank(code) {\n if (self.containerState.furtherBlankLines || !markdownSpace(code)) {\n self.containerState.furtherBlankLines = undefined\n self.containerState.initialBlankLine = undefined\n return notInCurrentItem(code)\n }\n\n self.containerState.furtherBlankLines = undefined\n self.containerState.initialBlankLine = undefined\n return effects.attempt(indentConstruct, ok, notInCurrentItem)(code)\n }\n /** @type {State} */\n\n function notInCurrentItem(code) {\n // While we do continue, we signal that the flow should be closed.\n self.containerState._closeFlow = true // As we\u2019re closing flow, we\u2019re no longer interrupting.\n\n self.interrupt = undefined\n return factorySpace(\n effects,\n effects.attempt(list, ok, nok),\n 'linePrefix',\n self.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4\n )(code)\n }\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeIndent(effects, ok, nok) {\n const self = this\n return factorySpace(\n effects,\n afterPrefix,\n 'listItemIndent',\n self.containerState.size + 1\n )\n /** @type {State} */\n\n function afterPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return tail &&\n tail[1].type === 'listItemIndent' &&\n tail[2].sliceSerialize(tail[1], true).length === self.containerState.size\n ? ok(code)\n : nok(code)\n }\n}\n/**\n * @type {Exiter}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListEnd(effects) {\n effects.exit(this.containerState.type)\n}\n/**\n * @type {Tokenizer}\n * @this {TokenizeContextWithState}\n */\n\nfunction tokenizeListItemPrefixWhitespace(effects, ok, nok) {\n const self = this\n return factorySpace(\n effects,\n afterPrefix,\n 'listItemPrefixWhitespace',\n self.parser.constructs.disable.null.includes('codeIndented')\n ? undefined\n : 4 + 1\n )\n /** @type {State} */\n\n function afterPrefix(code) {\n const tail = self.events[self.events.length - 1]\n return !markdownSpace(code) &&\n tail &&\n tail[1].type === 'listItemPrefixWhitespace'\n ? ok(code)\n : nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Tokenizer} Tokenizer\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {Construct} */\nexport const setextUnderline = {\n name: 'setextUnderline',\n tokenize: tokenizeSetextUnderline,\n resolveTo: resolveToSetextUnderline\n}\n/** @type {Resolver} */\n\nfunction resolveToSetextUnderline(events, context) {\n let index = events.length\n /** @type {number|undefined} */\n\n let content\n /** @type {number|undefined} */\n\n let text\n /** @type {number|undefined} */\n\n let definition // Find the opening of the content.\n // It\u2019ll always exist: we don\u2019t tokenize if it isn\u2019t there.\n\n while (index--) {\n if (events[index][0] === 'enter') {\n if (events[index][1].type === 'content') {\n content = index\n break\n }\n\n if (events[index][1].type === 'paragraph') {\n text = index\n }\n } // Exit\n else {\n if (events[index][1].type === 'content') {\n // Remove the content end (if needed we\u2019ll add it later)\n events.splice(index, 1)\n }\n\n if (!definition && events[index][1].type === 'definition') {\n definition = index\n }\n }\n }\n\n const heading = {\n type: 'setextHeading',\n start: Object.assign({}, events[text][1].start),\n end: Object.assign({}, events[events.length - 1][1].end)\n } // Change the paragraph to setext heading text.\n\n events[text][1].type = 'setextHeadingText' // If we have definitions in the content, we\u2019ll keep on having content,\n // but we need move it.\n\n if (definition) {\n events.splice(text, 0, ['enter', heading, context])\n events.splice(definition + 1, 0, ['exit', events[content][1], context])\n events[content][1].end = Object.assign({}, events[definition][1].end)\n } else {\n events[content][1] = heading\n } // Add the heading exit at the end.\n\n events.push(['exit', heading, context])\n return events\n}\n/** @type {Tokenizer} */\n\nfunction tokenizeSetextUnderline(effects, ok, nok) {\n const self = this\n let index = self.events.length\n /** @type {NonNullable} */\n\n let marker\n /** @type {boolean} */\n\n let paragraph // Find an opening.\n\n while (index--) {\n // Skip enter/exit of line ending, line prefix, and content.\n // We can now either have a definition or a paragraph.\n if (\n self.events[index][1].type !== 'lineEnding' &&\n self.events[index][1].type !== 'linePrefix' &&\n self.events[index][1].type !== 'content'\n ) {\n paragraph = self.events[index][1].type === 'paragraph'\n break\n }\n }\n\n return start\n /** @type {State} */\n\n function start(code) {\n if (!self.parser.lazy[self.now().line] && (self.interrupt || paragraph)) {\n effects.enter('setextHeadingLine')\n effects.enter('setextHeadingLineSequence')\n marker = code\n return closingSequence(code)\n }\n\n return nok(code)\n }\n /** @type {State} */\n\n function closingSequence(code) {\n if (code === marker) {\n effects.consume(code)\n return closingSequence\n }\n\n effects.exit('setextHeadingLineSequence')\n return factorySpace(effects, closingSequenceEnd, 'lineSuffix')(code)\n }\n /** @type {State} */\n\n function closingSequenceEnd(code) {\n if (code === null || markdownLineEnding(code)) {\n effects.exit('setextHeadingLine')\n return ok(code)\n }\n\n return nok(code)\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').State} State\n */\nimport {blankLine, content} from 'micromark-core-commonmark'\nimport {factorySpace} from 'micromark-factory-space'\nimport {markdownLineEnding} from 'micromark-util-character'\n\n/** @type {InitialConstruct} */\nexport const flow = {\n tokenize: initializeFlow\n}\n/** @type {Initializer} */\n\nfunction initializeFlow(effects) {\n const self = this\n const initial = effects.attempt(\n // Try to parse a blank line.\n blankLine,\n atBlankEnding, // Try to parse initial flow (essentially, only code).\n effects.attempt(\n this.parser.constructs.flowInitial,\n afterConstruct,\n factorySpace(\n effects,\n effects.attempt(\n this.parser.constructs.flow,\n afterConstruct,\n effects.attempt(content, afterConstruct)\n ),\n 'linePrefix'\n )\n )\n )\n return initial\n /** @type {State} */\n\n function atBlankEnding(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('lineEndingBlank')\n effects.consume(code)\n effects.exit('lineEndingBlank')\n self.currentConstruct = undefined\n return initial\n }\n /** @type {State} */\n\n function afterConstruct(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('lineEnding')\n effects.consume(code)\n effects.exit('lineEnding')\n self.currentConstruct = undefined\n return initial\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Resolver} Resolver\n * @typedef {import('micromark-util-types').Initializer} Initializer\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Code} Code\n */\nexport const resolver = {\n resolveAll: createResolver()\n}\nexport const string = initializeFactory('string')\nexport const text = initializeFactory('text')\n/**\n * @param {'string'|'text'} field\n * @returns {InitialConstruct}\n */\n\nfunction initializeFactory(field) {\n return {\n tokenize: initializeText,\n resolveAll: createResolver(\n field === 'text' ? resolveAllLineSuffixes : undefined\n )\n }\n /** @type {Initializer} */\n\n function initializeText(effects) {\n const self = this\n const constructs = this.parser.constructs[field]\n const text = effects.attempt(constructs, start, notText)\n return start\n /** @type {State} */\n\n function start(code) {\n return atBreak(code) ? text(code) : notText(code)\n }\n /** @type {State} */\n\n function notText(code) {\n if (code === null) {\n effects.consume(code)\n return\n }\n\n effects.enter('data')\n effects.consume(code)\n return data\n }\n /** @type {State} */\n\n function data(code) {\n if (atBreak(code)) {\n effects.exit('data')\n return text(code)\n } // Data.\n\n effects.consume(code)\n return data\n }\n /**\n * @param {Code} code\n * @returns {boolean}\n */\n\n function atBreak(code) {\n if (code === null) {\n return true\n }\n\n const list = constructs[code]\n let index = -1\n\n if (list) {\n while (++index < list.length) {\n const item = list[index]\n\n if (!item.previous || item.previous.call(self, self.previous)) {\n return true\n }\n }\n }\n\n return false\n }\n }\n}\n/**\n * @param {Resolver} [extraResolver]\n * @returns {Resolver}\n */\n\nfunction createResolver(extraResolver) {\n return resolveAllText\n /** @type {Resolver} */\n\n function resolveAllText(events, context) {\n let index = -1\n /** @type {number|undefined} */\n\n let enter // A rather boring computation (to merge adjacent `data` events) which\n // improves mm performance by 29%.\n\n while (++index <= events.length) {\n if (enter === undefined) {\n if (events[index] && events[index][1].type === 'data') {\n enter = index\n index++\n }\n } else if (!events[index] || events[index][1].type !== 'data') {\n // Don\u2019t do anything if there is one data token.\n if (index !== enter + 2) {\n events[enter][1].end = events[index - 1][1].end\n events.splice(enter + 2, index - enter - 2)\n index = enter + 2\n }\n\n enter = undefined\n }\n }\n\n return extraResolver ? extraResolver(events, context) : events\n }\n}\n/**\n * A rather ugly set of instructions which again looks at chunks in the input\n * stream.\n * The reason to do this here is that it is *much* faster to parse in reverse.\n * And that we can\u2019t hook into `null` to split the line suffix before an EOF.\n * To do: figure out if we can make this into a clean utility, or even in core.\n * As it will be useful for GFMs literal autolink extension (and maybe even\n * tables?)\n *\n * @type {Resolver}\n */\n\nfunction resolveAllLineSuffixes(events, context) {\n let eventIndex = 0 // Skip first.\n\n while (++eventIndex <= events.length) {\n if (\n (eventIndex === events.length ||\n events[eventIndex][1].type === 'lineEnding') &&\n events[eventIndex - 1][1].type === 'data'\n ) {\n const data = events[eventIndex - 1][1]\n const chunks = context.sliceStream(data)\n let index = chunks.length\n let bufferIndex = -1\n let size = 0\n /** @type {boolean|undefined} */\n\n let tabs\n\n while (index--) {\n const chunk = chunks[index]\n\n if (typeof chunk === 'string') {\n bufferIndex = chunk.length\n\n while (chunk.charCodeAt(bufferIndex - 1) === 32) {\n size++\n bufferIndex--\n }\n\n if (bufferIndex) break\n bufferIndex = -1\n } // Number\n else if (chunk === -2) {\n tabs = true\n size++\n } else if (chunk === -1) {\n // Empty\n } else {\n // Replacement character, exit.\n index++\n break\n }\n }\n\n if (size) {\n const token = {\n type:\n eventIndex === events.length || tabs || size < 2\n ? 'lineSuffix'\n : 'hardBreakTrailing',\n start: {\n line: data.end.line,\n column: data.end.column - size,\n offset: data.end.offset - size,\n _index: data.start._index + index,\n _bufferIndex: index\n ? bufferIndex\n : data.start._bufferIndex + bufferIndex\n },\n end: Object.assign({}, data.end)\n }\n data.end = Object.assign({}, token.start)\n\n if (data.start.offset === data.end.offset) {\n Object.assign(data, token)\n } else {\n events.splice(\n eventIndex,\n 0,\n ['enter', token, context],\n ['exit', token, context]\n )\n eventIndex += 2\n }\n }\n\n eventIndex++\n }\n }\n\n return events\n}\n", "/**\n * @typedef {import('micromark-util-types').Code} Code\n * @typedef {import('micromark-util-types').Chunk} Chunk\n * @typedef {import('micromark-util-types').Point} Point\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').Effects} Effects\n * @typedef {import('micromark-util-types').State} State\n * @typedef {import('micromark-util-types').Construct} Construct\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').ConstructRecord} ConstructRecord\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').ParseContext} ParseContext\n */\n\n/**\n * @typedef Info\n * @property {() => void} restore\n * @property {number} from\n *\n * @callback ReturnHandle\n * Handle a successful run.\n * @param {Construct} construct\n * @param {Info} info\n * @returns {void}\n */\nimport {markdownLineEnding} from 'micromark-util-character'\nimport {push, splice} from 'micromark-util-chunked'\nimport {resolveAll} from 'micromark-util-resolve-all'\n\n/**\n * Create a tokenizer.\n * Tokenizers deal with one type of data (e.g., containers, flow, text).\n * The parser is the object dealing with it all.\n * `initialize` works like other constructs, except that only its `tokenize`\n * function is used, in which case it doesn\u2019t receive an `ok` or `nok`.\n * `from` can be given to set the point before the first character, although\n * when further lines are indented, they must be set with `defineSkip`.\n *\n * @param {ParseContext} parser\n * @param {InitialConstruct} initialize\n * @param {Omit} [from]\n * @returns {TokenizeContext}\n */\nexport function createTokenizer(parser, initialize, from) {\n /** @type {Point} */\n let point = Object.assign(\n from\n ? Object.assign({}, from)\n : {\n line: 1,\n column: 1,\n offset: 0\n },\n {\n _index: 0,\n _bufferIndex: -1\n }\n )\n /** @type {Record} */\n\n const columnStart = {}\n /** @type {Array} */\n\n const resolveAllConstructs = []\n /** @type {Array} */\n\n let chunks = []\n /** @type {Array} */\n\n let stack = []\n /** @type {boolean|undefined} */\n\n let consumed = true\n /**\n * Tools used for tokenizing.\n *\n * @type {Effects}\n */\n\n const effects = {\n consume,\n enter,\n exit,\n attempt: constructFactory(onsuccessfulconstruct),\n check: constructFactory(onsuccessfulcheck),\n interrupt: constructFactory(onsuccessfulcheck, {\n interrupt: true\n })\n }\n /**\n * State and tools for resolving and serializing.\n *\n * @type {TokenizeContext}\n */\n\n const context = {\n previous: null,\n code: null,\n containerState: {},\n events: [],\n parser,\n sliceStream,\n sliceSerialize,\n now,\n defineSkip,\n write\n }\n /**\n * The state function.\n *\n * @type {State|void}\n */\n\n let state = initialize.tokenize.call(context, effects)\n /**\n * Track which character we expect to be consumed, to catch bugs.\n *\n * @type {Code}\n */\n\n let expectedCode\n\n if (initialize.resolveAll) {\n resolveAllConstructs.push(initialize)\n }\n\n return context\n /** @type {TokenizeContext['write']} */\n\n function write(slice) {\n chunks = push(chunks, slice)\n main() // Exit if we\u2019re not done, resolve might change stuff.\n\n if (chunks[chunks.length - 1] !== null) {\n return []\n }\n\n addResult(initialize, 0) // Otherwise, resolve, and exit.\n\n context.events = resolveAll(resolveAllConstructs, context.events, context)\n return context.events\n } //\n // Tools.\n //\n\n /** @type {TokenizeContext['sliceSerialize']} */\n\n function sliceSerialize(token, expandTabs) {\n return serializeChunks(sliceStream(token), expandTabs)\n }\n /** @type {TokenizeContext['sliceStream']} */\n\n function sliceStream(token) {\n return sliceChunks(chunks, token)\n }\n /** @type {TokenizeContext['now']} */\n\n function now() {\n return Object.assign({}, point)\n }\n /** @type {TokenizeContext['defineSkip']} */\n\n function defineSkip(value) {\n columnStart[value.line] = value.column\n accountForPotentialSkip()\n } //\n // State management.\n //\n\n /**\n * Main loop (note that `_index` and `_bufferIndex` in `point` are modified by\n * `consume`).\n * Here is where we walk through the chunks, which either include strings of\n * several characters, or numerical character codes.\n * The reason to do this in a loop instead of a call is so the stack can\n * drain.\n *\n * @returns {void}\n */\n\n function main() {\n /** @type {number} */\n let chunkIndex\n\n while (point._index < chunks.length) {\n const chunk = chunks[point._index] // If we\u2019re in a buffer chunk, loop through it.\n\n if (typeof chunk === 'string') {\n chunkIndex = point._index\n\n if (point._bufferIndex < 0) {\n point._bufferIndex = 0\n }\n\n while (\n point._index === chunkIndex &&\n point._bufferIndex < chunk.length\n ) {\n go(chunk.charCodeAt(point._bufferIndex))\n }\n } else {\n go(chunk)\n }\n }\n }\n /**\n * Deal with one code.\n *\n * @param {Code} code\n * @returns {void}\n */\n\n function go(code) {\n consumed = undefined\n expectedCode = code\n state = state(code)\n }\n /** @type {Effects['consume']} */\n\n function consume(code) {\n if (markdownLineEnding(code)) {\n point.line++\n point.column = 1\n point.offset += code === -3 ? 2 : 1\n accountForPotentialSkip()\n } else if (code !== -1) {\n point.column++\n point.offset++\n } // Not in a string chunk.\n\n if (point._bufferIndex < 0) {\n point._index++\n } else {\n point._bufferIndex++ // At end of string chunk.\n // @ts-expect-error Points w/ non-negative `_bufferIndex` reference\n // strings.\n\n if (point._bufferIndex === chunks[point._index].length) {\n point._bufferIndex = -1\n point._index++\n }\n } // Expose the previous character.\n\n context.previous = code // Mark as consumed.\n\n consumed = true\n }\n /** @type {Effects['enter']} */\n\n function enter(type, fields) {\n /** @type {Token} */\n // @ts-expect-error Patch instead of assign required fields to help GC.\n const token = fields || {}\n token.type = type\n token.start = now()\n context.events.push(['enter', token, context])\n stack.push(token)\n return token\n }\n /** @type {Effects['exit']} */\n\n function exit(type) {\n const token = stack.pop()\n token.end = now()\n context.events.push(['exit', token, context])\n return token\n }\n /**\n * Use results.\n *\n * @type {ReturnHandle}\n */\n\n function onsuccessfulconstruct(construct, info) {\n addResult(construct, info.from)\n }\n /**\n * Discard results.\n *\n * @type {ReturnHandle}\n */\n\n function onsuccessfulcheck(_, info) {\n info.restore()\n }\n /**\n * Factory to attempt/check/interrupt.\n *\n * @param {ReturnHandle} onreturn\n * @param {Record} [fields]\n */\n\n function constructFactory(onreturn, fields) {\n return hook\n /**\n * Handle either an object mapping codes to constructs, a list of\n * constructs, or a single construct.\n *\n * @param {Construct|Array|ConstructRecord} constructs\n * @param {State} returnState\n * @param {State} [bogusState]\n * @returns {State}\n */\n\n function hook(constructs, returnState, bogusState) {\n /** @type {Array} */\n let listOfConstructs\n /** @type {number} */\n\n let constructIndex\n /** @type {Construct} */\n\n let currentConstruct\n /** @type {Info} */\n\n let info\n return Array.isArray(constructs)\n ? /* c8 ignore next 1 */\n handleListOfConstructs(constructs)\n : 'tokenize' in constructs // @ts-expect-error Looks like a construct.\n ? handleListOfConstructs([constructs])\n : handleMapOfConstructs(constructs)\n /**\n * Handle a list of construct.\n *\n * @param {ConstructRecord} map\n * @returns {State}\n */\n\n function handleMapOfConstructs(map) {\n return start\n /** @type {State} */\n\n function start(code) {\n const def = code !== null && map[code]\n const all = code !== null && map.null\n const list = [\n // To do: add more extension tests.\n\n /* c8 ignore next 2 */\n ...(Array.isArray(def) ? def : def ? [def] : []),\n ...(Array.isArray(all) ? all : all ? [all] : [])\n ]\n return handleListOfConstructs(list)(code)\n }\n }\n /**\n * Handle a list of construct.\n *\n * @param {Array} list\n * @returns {State}\n */\n\n function handleListOfConstructs(list) {\n listOfConstructs = list\n constructIndex = 0\n\n if (list.length === 0) {\n return bogusState\n }\n\n return handleConstruct(list[constructIndex])\n }\n /**\n * Handle a single construct.\n *\n * @param {Construct} construct\n * @returns {State}\n */\n\n function handleConstruct(construct) {\n return start\n /** @type {State} */\n\n function start(code) {\n // To do: not needed to store if there is no bogus state, probably?\n // Currently doesn\u2019t work because `inspect` in document does a check\n // w/o a bogus, which doesn\u2019t make sense. But it does seem to help perf\n // by not storing.\n info = store()\n currentConstruct = construct\n\n if (!construct.partial) {\n context.currentConstruct = construct\n }\n\n if (\n construct.name &&\n context.parser.constructs.disable.null.includes(construct.name)\n ) {\n return nok(code)\n }\n\n return construct.tokenize.call(\n // If we do have fields, create an object w/ `context` as its\n // prototype.\n // This allows a \u201Clive binding\u201D, which is needed for `interrupt`.\n fields ? Object.assign(Object.create(context), fields) : context,\n effects,\n ok,\n nok\n )(code)\n }\n }\n /** @type {State} */\n\n function ok(code) {\n consumed = true\n onreturn(currentConstruct, info)\n return returnState\n }\n /** @type {State} */\n\n function nok(code) {\n consumed = true\n info.restore()\n\n if (++constructIndex < listOfConstructs.length) {\n return handleConstruct(listOfConstructs[constructIndex])\n }\n\n return bogusState\n }\n }\n }\n /**\n * @param {Construct} construct\n * @param {number} from\n * @returns {void}\n */\n\n function addResult(construct, from) {\n if (construct.resolveAll && !resolveAllConstructs.includes(construct)) {\n resolveAllConstructs.push(construct)\n }\n\n if (construct.resolve) {\n splice(\n context.events,\n from,\n context.events.length - from,\n construct.resolve(context.events.slice(from), context)\n )\n }\n\n if (construct.resolveTo) {\n context.events = construct.resolveTo(context.events, context)\n }\n }\n /**\n * Store state.\n *\n * @returns {Info}\n */\n\n function store() {\n const startPoint = now()\n const startPrevious = context.previous\n const startCurrentConstruct = context.currentConstruct\n const startEventsIndex = context.events.length\n const startStack = Array.from(stack)\n return {\n restore,\n from: startEventsIndex\n }\n /**\n * Restore state.\n *\n * @returns {void}\n */\n\n function restore() {\n point = startPoint\n context.previous = startPrevious\n context.currentConstruct = startCurrentConstruct\n context.events.length = startEventsIndex\n stack = startStack\n accountForPotentialSkip()\n }\n }\n /**\n * Move the current point a bit forward in the line when it\u2019s on a column\n * skip.\n *\n * @returns {void}\n */\n\n function accountForPotentialSkip() {\n if (point.line in columnStart && point.column < 2) {\n point.column = columnStart[point.line]\n point.offset += columnStart[point.line] - 1\n }\n }\n}\n/**\n * Get the chunks from a slice of chunks in the range of a token.\n *\n * @param {Array} chunks\n * @param {Pick} token\n * @returns {Array}\n */\n\nfunction sliceChunks(chunks, token) {\n const startIndex = token.start._index\n const startBufferIndex = token.start._bufferIndex\n const endIndex = token.end._index\n const endBufferIndex = token.end._bufferIndex\n /** @type {Array} */\n\n let view\n\n if (startIndex === endIndex) {\n // @ts-expect-error `_bufferIndex` is used on string chunks.\n view = [chunks[startIndex].slice(startBufferIndex, endBufferIndex)]\n } else {\n view = chunks.slice(startIndex, endIndex)\n\n if (startBufferIndex > -1) {\n // @ts-expect-error `_bufferIndex` is used on string chunks.\n view[0] = view[0].slice(startBufferIndex)\n }\n\n if (endBufferIndex > 0) {\n // @ts-expect-error `_bufferIndex` is used on string chunks.\n view.push(chunks[endIndex].slice(0, endBufferIndex))\n }\n }\n\n return view\n}\n/**\n * Get the string value of a slice of chunks.\n *\n * @param {Array} chunks\n * @param {boolean} [expandTabs=false]\n * @returns {string}\n */\n\nfunction serializeChunks(chunks, expandTabs) {\n let index = -1\n /** @type {Array} */\n\n const result = []\n /** @type {boolean|undefined} */\n\n let atTab\n\n while (++index < chunks.length) {\n const chunk = chunks[index]\n /** @type {string} */\n\n let value\n\n if (typeof chunk === 'string') {\n value = chunk\n } else\n switch (chunk) {\n case -5: {\n value = '\\r'\n break\n }\n\n case -4: {\n value = '\\n'\n break\n }\n\n case -3: {\n value = '\\r' + '\\n'\n break\n }\n\n case -2: {\n value = expandTabs ? ' ' : '\\t'\n break\n }\n\n case -1: {\n if (!expandTabs && atTab) continue\n value = ' '\n break\n }\n\n default: {\n // Currently only replacement character.\n value = String.fromCharCode(chunk)\n }\n }\n\n atTab = chunk === -2\n result.push(value)\n }\n\n return result.join('')\n}\n", "/**\n * @typedef {import('micromark-util-types').Extension} Extension\n */\nimport {\n attention,\n autolink,\n blockQuote,\n characterEscape,\n characterReference,\n codeFenced,\n codeIndented,\n codeText,\n definition,\n hardBreakEscape,\n headingAtx,\n htmlFlow,\n htmlText,\n labelEnd,\n labelStartImage,\n labelStartLink,\n lineEnding,\n list,\n setextUnderline,\n thematicBreak\n} from 'micromark-core-commonmark'\nimport {resolver as resolveText} from './initialize/text.js'\n/** @type {Extension['document']} */\n\nexport const document = {\n [42]: list,\n [43]: list,\n [45]: list,\n [48]: list,\n [49]: list,\n [50]: list,\n [51]: list,\n [52]: list,\n [53]: list,\n [54]: list,\n [55]: list,\n [56]: list,\n [57]: list,\n [62]: blockQuote\n}\n/** @type {Extension['contentInitial']} */\n\nexport const contentInitial = {\n [91]: definition\n}\n/** @type {Extension['flowInitial']} */\n\nexport const flowInitial = {\n [-2]: codeIndented,\n [-1]: codeIndented,\n [32]: codeIndented\n}\n/** @type {Extension['flow']} */\n\nexport const flow = {\n [35]: headingAtx,\n [42]: thematicBreak,\n [45]: [setextUnderline, thematicBreak],\n [60]: htmlFlow,\n [61]: setextUnderline,\n [95]: thematicBreak,\n [96]: codeFenced,\n [126]: codeFenced\n}\n/** @type {Extension['string']} */\n\nexport const string = {\n [38]: characterReference,\n [92]: characterEscape\n}\n/** @type {Extension['text']} */\n\nexport const text = {\n [-5]: lineEnding,\n [-4]: lineEnding,\n [-3]: lineEnding,\n [33]: labelStartImage,\n [38]: characterReference,\n [42]: attention,\n [60]: [autolink, htmlText],\n [91]: labelStartLink,\n [92]: [hardBreakEscape, characterEscape],\n [93]: labelEnd,\n [95]: attention,\n [96]: codeText\n}\n/** @type {Extension['insideSpan']} */\n\nexport const insideSpan = {\n null: [attention, resolveText]\n}\n/** @type {Extension['attentionMarkers']} */\n\nexport const attentionMarkers = {\n null: [42, 95]\n}\n/** @type {Extension['disable']} */\n\nexport const disable = {\n null: []\n}\n", "/**\n * @typedef {import('micromark-util-types').InitialConstruct} InitialConstruct\n * @typedef {import('micromark-util-types').FullNormalizedExtension} FullNormalizedExtension\n * @typedef {import('micromark-util-types').ParseOptions} ParseOptions\n * @typedef {import('micromark-util-types').ParseContext} ParseContext\n * @typedef {import('micromark-util-types').Create} Create\n */\nimport {combineExtensions} from 'micromark-util-combine-extensions'\nimport {content} from './initialize/content.js'\nimport {document} from './initialize/document.js'\nimport {flow} from './initialize/flow.js'\nimport {text, string} from './initialize/text.js'\nimport {createTokenizer} from './create-tokenizer.js'\nimport * as defaultConstructs from './constructs.js'\n/**\n * @param {ParseOptions} [options]\n * @returns {ParseContext}\n */\n\nexport function parse(options = {}) {\n /** @type {FullNormalizedExtension} */\n // @ts-expect-error `defaultConstructs` is full, so the result will be too.\n const constructs = combineExtensions(\n // @ts-expect-error Same as above.\n [defaultConstructs].concat(options.extensions || [])\n )\n /** @type {ParseContext} */\n\n const parser = {\n defined: [],\n lazy: {},\n constructs,\n content: create(content),\n document: create(document),\n flow: create(flow),\n string: create(string),\n text: create(text)\n }\n return parser\n /**\n * @param {InitialConstruct} initial\n */\n\n function create(initial) {\n return creator\n /** @type {Create} */\n\n function creator(from) {\n return createTokenizer(parser, initial, from)\n }\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Encoding} Encoding\n * @typedef {import('micromark-util-types').Value} Value\n * @typedef {import('micromark-util-types').Chunk} Chunk\n * @typedef {import('micromark-util-types').Code} Code\n */\n\n/**\n * @callback Preprocessor\n * @param {Value} value\n * @param {Encoding} [encoding]\n * @param {boolean} [end=false]\n * @returns {Array}\n */\nconst search = /[\\0\\t\\n\\r]/g\n/**\n * @returns {Preprocessor}\n */\n\nexport function preprocess() {\n let column = 1\n let buffer = ''\n /** @type {boolean|undefined} */\n\n let start = true\n /** @type {boolean|undefined} */\n\n let atCarriageReturn\n return preprocessor\n /** @type {Preprocessor} */\n\n function preprocessor(value, encoding, end) {\n /** @type {Array} */\n const chunks = []\n /** @type {RegExpMatchArray|null} */\n\n let match\n /** @type {number} */\n\n let next\n /** @type {number} */\n\n let startPosition\n /** @type {number} */\n\n let endPosition\n /** @type {Code} */\n\n let code // @ts-expect-error `Buffer` does allow an encoding.\n\n value = buffer + value.toString(encoding)\n startPosition = 0\n buffer = ''\n\n if (start) {\n if (value.charCodeAt(0) === 65279) {\n startPosition++\n }\n\n start = undefined\n }\n\n while (startPosition < value.length) {\n search.lastIndex = startPosition\n match = search.exec(value)\n endPosition =\n match && match.index !== undefined ? match.index : value.length\n code = value.charCodeAt(endPosition)\n\n if (!match) {\n buffer = value.slice(startPosition)\n break\n }\n\n if (code === 10 && startPosition === endPosition && atCarriageReturn) {\n chunks.push(-3)\n atCarriageReturn = undefined\n } else {\n if (atCarriageReturn) {\n chunks.push(-5)\n atCarriageReturn = undefined\n }\n\n if (startPosition < endPosition) {\n chunks.push(value.slice(startPosition, endPosition))\n column += endPosition - startPosition\n }\n\n switch (code) {\n case 0: {\n chunks.push(65533)\n column++\n break\n }\n\n case 9: {\n next = Math.ceil(column / 4) * 4\n chunks.push(-2)\n\n while (column++ < next) chunks.push(-1)\n\n break\n }\n\n case 10: {\n chunks.push(-4)\n column = 1\n break\n }\n\n default: {\n atCarriageReturn = true\n column = 1\n }\n }\n }\n\n startPosition = endPosition + 1\n }\n\n if (end) {\n if (atCarriageReturn) chunks.push(-5)\n if (buffer) chunks.push(buffer)\n chunks.push(null)\n }\n\n return chunks\n }\n}\n", "/**\n * @typedef {import('micromark-util-types').Event} Event\n */\nimport {subtokenize} from 'micromark-util-subtokenize'\n/**\n * @param {Array} events\n * @returns {Array}\n */\n\nexport function postprocess(events) {\n while (!subtokenize(events)) {\n // Empty\n }\n\n return events\n}\n", "/**\n * Turn the number (in string form as either hexa- or plain decimal) coming from\n * a numeric character reference into a character.\n *\n * @param {string} value\n * Value to decode.\n * @param {number} base\n * Numeric base.\n * @returns {string}\n */\nexport function decodeNumericCharacterReference(value, base) {\n const code = Number.parseInt(value, base)\n\n if (\n // C0 except for HT, LF, FF, CR, space\n code < 9 ||\n code === 11 ||\n (code > 13 && code < 32) || // Control character (DEL) of the basic block and C1 controls.\n (code > 126 && code < 160) || // Lone high surrogates and low surrogates.\n (code > 55295 && code < 57344) || // Noncharacters.\n (code > 64975 && code < 65008) ||\n (code & 65535) === 65535 ||\n (code & 65535) === 65534 || // Out of range\n code > 1114111\n ) {\n return '\\uFFFD'\n }\n\n return String.fromCharCode(code)\n}\n", "import {decodeNamedCharacterReference} from 'decode-named-character-reference'\nimport {decodeNumericCharacterReference} from 'micromark-util-decode-numeric-character-reference'\nconst characterEscapeOrReference =\n /\\\\([!-/:-@[-`{-~])|&(#(?:\\d{1,7}|x[\\da-f]{1,6})|[\\da-z]{1,31});/gi\n/**\n * Utility to decode markdown strings (which occur in places such as fenced\n * code info strings, destinations, labels, and titles).\n * The \u201Cstring\u201D content type allows character escapes and -references.\n * This decodes those.\n *\n * @param {string} value\n * @returns {string}\n */\n\nexport function decodeString(value) {\n return value.replace(characterEscapeOrReference, decode)\n}\n/**\n * @param {string} $0\n * @param {string} $1\n * @param {string} $2\n * @returns {string}\n */\n\nfunction decode($0, $1, $2) {\n if ($1) {\n // Escape.\n return $1\n } // Reference.\n\n const head = $2.charCodeAt(0)\n\n if (head === 35) {\n const head = $2.charCodeAt(1)\n const hex = head === 120 || head === 88\n return decodeNumericCharacterReference($2.slice(hex ? 2 : 1), hex ? 16 : 10)\n }\n\n return decodeNamedCharacterReference($2) || $0\n}\n", "/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Point} Point\n * @typedef {import('unist').Position} Position\n */\n\n/**\n * @typedef NodeLike\n * @property {string} type\n * @property {PositionLike | null | undefined} [position]\n *\n * @typedef PositionLike\n * @property {PointLike | null | undefined} [start]\n * @property {PointLike | null | undefined} [end]\n *\n * @typedef PointLike\n * @property {number | null | undefined} [line]\n * @property {number | null | undefined} [column]\n * @property {number | null | undefined} [offset]\n */\n\n/**\n * Serialize the positional info of a point, position (start and end points),\n * or node.\n *\n * @param {Node | NodeLike | Position | PositionLike | Point | PointLike | null | undefined} [value]\n * Node, position, or point.\n * @returns {string}\n * Pretty printed positional info of a node (`string`).\n *\n * In the format of a range `ls:cs-le:ce` (when given `node` or `position`)\n * or a point `l:c` (when given `point`), where `l` stands for line, `c` for\n * column, `s` for `start`, and `e` for end.\n * An empty string (`''`) is returned if the given value is neither `node`,\n * `position`, nor `point`.\n */\nexport function stringifyPosition(value) {\n // Nothing.\n if (!value || typeof value !== 'object') {\n return ''\n }\n\n // Node.\n if ('position' in value || 'type' in value) {\n return position(value.position)\n }\n\n // Position.\n if ('start' in value || 'end' in value) {\n return position(value)\n }\n\n // Point.\n if ('line' in value || 'column' in value) {\n return point(value)\n }\n\n // ?\n return ''\n}\n\n/**\n * @param {Point | PointLike | null | undefined} point\n * @returns {string}\n */\nfunction point(point) {\n return index(point && point.line) + ':' + index(point && point.column)\n}\n\n/**\n * @param {Position | PositionLike | null | undefined} pos\n * @returns {string}\n */\nfunction position(pos) {\n return point(pos && pos.start) + '-' + point(pos && pos.end)\n}\n\n/**\n * @param {number | null | undefined} value\n * @returns {number}\n */\nfunction index(value) {\n return value && typeof value === 'number' ? value : 1\n}\n", "/**\n * @typedef {import('micromark-util-types').Encoding} Encoding\n * @typedef {import('micromark-util-types').Event} Event\n * @typedef {import('micromark-util-types').ParseOptions} ParseOptions\n * @typedef {import('micromark-util-types').Token} Token\n * @typedef {import('micromark-util-types').TokenizeContext} TokenizeContext\n * @typedef {import('micromark-util-types').Value} Value\n *\n * @typedef {import('unist').Parent} UnistParent\n * @typedef {import('unist').Point} Point\n *\n * @typedef {import('mdast').PhrasingContent} PhrasingContent\n * @typedef {import('mdast').StaticPhrasingContent} StaticPhrasingContent\n * @typedef {import('mdast').Content} Content\n * @typedef {import('mdast').Break} Break\n * @typedef {import('mdast').Blockquote} Blockquote\n * @typedef {import('mdast').Code} Code\n * @typedef {import('mdast').Definition} Definition\n * @typedef {import('mdast').Emphasis} Emphasis\n * @typedef {import('mdast').Heading} Heading\n * @typedef {import('mdast').HTML} HTML\n * @typedef {import('mdast').Image} Image\n * @typedef {import('mdast').ImageReference} ImageReference\n * @typedef {import('mdast').InlineCode} InlineCode\n * @typedef {import('mdast').Link} Link\n * @typedef {import('mdast').LinkReference} LinkReference\n * @typedef {import('mdast').List} List\n * @typedef {import('mdast').ListItem} ListItem\n * @typedef {import('mdast').Paragraph} Paragraph\n * @typedef {import('mdast').Root} Root\n * @typedef {import('mdast').Strong} Strong\n * @typedef {import('mdast').Text} Text\n * @typedef {import('mdast').ThematicBreak} ThematicBreak\n * @typedef {import('mdast').ReferenceType} ReferenceType\n * @typedef {import('../index.js').CompileData} CompileData\n */\n\n/**\n * @typedef {Root | Content} Node\n * @typedef {Extract} Parent\n *\n * @typedef {Omit & {type: 'fragment', children: Array}} Fragment\n */\n\n/**\n * @callback Transform\n * Extra transform, to change the AST afterwards.\n * @param {Root} tree\n * Tree to transform.\n * @returns {Root | undefined | null | void}\n * New tree or nothing (in which case the current tree is used).\n *\n * @callback Handle\n * Handle a token.\n * @param {CompileContext} this\n * Context.\n * @param {Token} token\n * Current token.\n * @returns {void}\n * Nothing.\n *\n * @typedef {Record} Handles\n * Token types mapping to handles\n *\n * @callback OnEnterError\n * Handle the case where the `right` token is open, but it is closed (by the\n * `left` token) or because we reached the end of the document.\n * @param {Omit} this\n * Context.\n * @param {Token | undefined} left\n * Left token.\n * @param {Token} right\n * Right token.\n * @returns {void}\n * Nothing.\n *\n * @callback OnExitError\n * Handle the case where the `right` token is open but it is closed by\n * exiting the `left` token.\n * @param {Omit} this\n * Context.\n * @param {Token} left\n * Left token.\n * @param {Token} right\n * Right token.\n * @returns {void}\n * Nothing.\n *\n * @typedef {[Token, OnEnterError | undefined]} TokenTuple\n * Open token on the stack, with an optional error handler for when\n * that token isn\u2019t closed properly.\n */\n\n/**\n * @typedef Config\n * Configuration.\n *\n * We have our defaults, but extensions will add more.\n * @property {Array} canContainEols\n * Token types where line endings are used.\n * @property {Handles} enter\n * Opening handles.\n * @property {Handles} exit\n * Closing handles.\n * @property {Array} transforms\n * Tree transforms.\n *\n * @typedef {Partial} Extension\n * Change how markdown tokens from micromark are turned into mdast.\n *\n * @typedef CompileContext\n * mdast compiler context.\n * @property {Array} stack\n * Stack of nodes.\n * @property {Array} tokenStack\n * Stack of tokens.\n * @property {(key: Key) => CompileData[Key]} getData\n * Get data from the key/value store.\n * @property {(key: Key, value?: CompileData[Key]) => void} setData\n * Set data into the key/value store.\n * @property {(this: CompileContext) => void} buffer\n * Capture some of the output data.\n * @property {(this: CompileContext) => string} resume\n * Stop capturing and access the output data.\n * @property {(this: CompileContext, node: Kind, token: Token, onError?: OnEnterError) => Kind} enter\n * Enter a token.\n * @property {(this: CompileContext, token: Token, onError?: OnExitError) => Node} exit\n * Exit a token.\n * @property {TokenizeContext['sliceSerialize']} sliceSerialize\n * Get the string value of a token.\n * @property {Config} config\n * Configuration.\n *\n * @typedef FromMarkdownOptions\n * Configuration for how to build mdast.\n * @property {Array> | null | undefined} [mdastExtensions]\n * Extensions for this utility to change how tokens are turned into a tree.\n *\n * @typedef {ParseOptions & FromMarkdownOptions} Options\n * Configuration.\n */\n\n// To do: micromark: create a registry of tokens?\n// To do: next major: don\u2019t return given `Node` from `enter`.\n// To do: next major: remove setter/getter.\n\nimport {toString} from 'mdast-util-to-string'\nimport {parse} from 'micromark/lib/parse.js'\nimport {preprocess} from 'micromark/lib/preprocess.js'\nimport {postprocess} from 'micromark/lib/postprocess.js'\nimport {decodeNumericCharacterReference} from 'micromark-util-decode-numeric-character-reference'\nimport {decodeString} from 'micromark-util-decode-string'\nimport {normalizeIdentifier} from 'micromark-util-normalize-identifier'\nimport {decodeNamedCharacterReference} from 'decode-named-character-reference'\nimport {stringifyPosition} from 'unist-util-stringify-position'\nconst own = {}.hasOwnProperty\n\n/**\n * @param value\n * Markdown to parse.\n * @param encoding\n * Character encoding for when `value` is `Buffer`.\n * @param options\n * Configuration.\n * @returns\n * mdast tree.\n */\nexport const fromMarkdown =\n /**\n * @type {(\n * ((value: Value, encoding: Encoding, options?: Options | null | undefined) => Root) &\n * ((value: Value, options?: Options | null | undefined) => Root)\n * )}\n */\n\n /**\n * @param {Value} value\n * @param {Encoding | Options | null | undefined} [encoding]\n * @param {Options | null | undefined} [options]\n * @returns {Root}\n */\n function (value, encoding, options) {\n if (typeof encoding !== 'string') {\n options = encoding\n encoding = undefined\n }\n return compiler(options)(\n postprocess(\n // @ts-expect-error: micromark types need to accept `null`.\n parse(options).document().write(preprocess()(value, encoding, true))\n )\n )\n }\n\n/**\n * Note this compiler only understand complete buffering, not streaming.\n *\n * @param {Options | null | undefined} [options]\n */\nfunction compiler(options) {\n /** @type {Config} */\n const config = {\n transforms: [],\n canContainEols: ['emphasis', 'fragment', 'heading', 'paragraph', 'strong'],\n enter: {\n autolink: opener(link),\n autolinkProtocol: onenterdata,\n autolinkEmail: onenterdata,\n atxHeading: opener(heading),\n blockQuote: opener(blockQuote),\n characterEscape: onenterdata,\n characterReference: onenterdata,\n codeFenced: opener(codeFlow),\n codeFencedFenceInfo: buffer,\n codeFencedFenceMeta: buffer,\n codeIndented: opener(codeFlow, buffer),\n codeText: opener(codeText, buffer),\n codeTextData: onenterdata,\n data: onenterdata,\n codeFlowValue: onenterdata,\n definition: opener(definition),\n definitionDestinationString: buffer,\n definitionLabelString: buffer,\n definitionTitleString: buffer,\n emphasis: opener(emphasis),\n hardBreakEscape: opener(hardBreak),\n hardBreakTrailing: opener(hardBreak),\n htmlFlow: opener(html, buffer),\n htmlFlowData: onenterdata,\n htmlText: opener(html, buffer),\n htmlTextData: onenterdata,\n image: opener(image),\n label: buffer,\n link: opener(link),\n listItem: opener(listItem),\n listItemValue: onenterlistitemvalue,\n listOrdered: opener(list, onenterlistordered),\n listUnordered: opener(list),\n paragraph: opener(paragraph),\n reference: onenterreference,\n referenceString: buffer,\n resourceDestinationString: buffer,\n resourceTitleString: buffer,\n setextHeading: opener(heading),\n strong: opener(strong),\n thematicBreak: opener(thematicBreak)\n },\n exit: {\n atxHeading: closer(),\n atxHeadingSequence: onexitatxheadingsequence,\n autolink: closer(),\n autolinkEmail: onexitautolinkemail,\n autolinkProtocol: onexitautolinkprotocol,\n blockQuote: closer(),\n characterEscapeValue: onexitdata,\n characterReferenceMarkerHexadecimal: onexitcharacterreferencemarker,\n characterReferenceMarkerNumeric: onexitcharacterreferencemarker,\n characterReferenceValue: onexitcharacterreferencevalue,\n codeFenced: closer(onexitcodefenced),\n codeFencedFence: onexitcodefencedfence,\n codeFencedFenceInfo: onexitcodefencedfenceinfo,\n codeFencedFenceMeta: onexitcodefencedfencemeta,\n codeFlowValue: onexitdata,\n codeIndented: closer(onexitcodeindented),\n codeText: closer(onexitcodetext),\n codeTextData: onexitdata,\n data: onexitdata,\n definition: closer(),\n definitionDestinationString: onexitdefinitiondestinationstring,\n definitionLabelString: onexitdefinitionlabelstring,\n definitionTitleString: onexitdefinitiontitlestring,\n emphasis: closer(),\n hardBreakEscape: closer(onexithardbreak),\n hardBreakTrailing: closer(onexithardbreak),\n htmlFlow: closer(onexithtmlflow),\n htmlFlowData: onexitdata,\n htmlText: closer(onexithtmltext),\n htmlTextData: onexitdata,\n image: closer(onexitimage),\n label: onexitlabel,\n labelText: onexitlabeltext,\n lineEnding: onexitlineending,\n link: closer(onexitlink),\n listItem: closer(),\n listOrdered: closer(),\n listUnordered: closer(),\n paragraph: closer(),\n referenceString: onexitreferencestring,\n resourceDestinationString: onexitresourcedestinationstring,\n resourceTitleString: onexitresourcetitlestring,\n resource: onexitresource,\n setextHeading: closer(onexitsetextheading),\n setextHeadingLineSequence: onexitsetextheadinglinesequence,\n setextHeadingText: onexitsetextheadingtext,\n strong: closer(),\n thematicBreak: closer()\n }\n }\n configure(config, (options || {}).mdastExtensions || [])\n\n /** @type {CompileData} */\n const data = {}\n return compile\n\n /**\n * Turn micromark events into an mdast tree.\n *\n * @param {Array} events\n * Events.\n * @returns {Root}\n * mdast tree.\n */\n function compile(events) {\n /** @type {Root} */\n let tree = {\n type: 'root',\n children: []\n }\n /** @type {Omit} */\n const context = {\n stack: [tree],\n tokenStack: [],\n config,\n enter,\n exit,\n buffer,\n resume,\n setData,\n getData\n }\n /** @type {Array} */\n const listStack = []\n let index = -1\n while (++index < events.length) {\n // We preprocess lists to add `listItem` tokens, and to infer whether\n // items the list itself are spread out.\n if (\n events[index][1].type === 'listOrdered' ||\n events[index][1].type === 'listUnordered'\n ) {\n if (events[index][0] === 'enter') {\n listStack.push(index)\n } else {\n const tail = listStack.pop()\n index = prepareList(events, tail, index)\n }\n }\n }\n index = -1\n while (++index < events.length) {\n const handler = config[events[index][0]]\n if (own.call(handler, events[index][1].type)) {\n handler[events[index][1].type].call(\n Object.assign(\n {\n sliceSerialize: events[index][2].sliceSerialize\n },\n context\n ),\n events[index][1]\n )\n }\n }\n\n // Handle tokens still being open.\n if (context.tokenStack.length > 0) {\n const tail = context.tokenStack[context.tokenStack.length - 1]\n const handler = tail[1] || defaultOnError\n handler.call(context, undefined, tail[0])\n }\n\n // Figure out `root` position.\n tree.position = {\n start: point(\n events.length > 0\n ? events[0][1].start\n : {\n line: 1,\n column: 1,\n offset: 0\n }\n ),\n end: point(\n events.length > 0\n ? events[events.length - 2][1].end\n : {\n line: 1,\n column: 1,\n offset: 0\n }\n )\n }\n\n // Call transforms.\n index = -1\n while (++index < config.transforms.length) {\n tree = config.transforms[index](tree) || tree\n }\n return tree\n }\n\n /**\n * @param {Array} events\n * @param {number} start\n * @param {number} length\n * @returns {number}\n */\n function prepareList(events, start, length) {\n let index = start - 1\n let containerBalance = -1\n let listSpread = false\n /** @type {Token | undefined} */\n let listItem\n /** @type {number | undefined} */\n let lineIndex\n /** @type {number | undefined} */\n let firstBlankLineIndex\n /** @type {boolean | undefined} */\n let atMarker\n while (++index <= length) {\n const event = events[index]\n if (\n event[1].type === 'listUnordered' ||\n event[1].type === 'listOrdered' ||\n event[1].type === 'blockQuote'\n ) {\n if (event[0] === 'enter') {\n containerBalance++\n } else {\n containerBalance--\n }\n atMarker = undefined\n } else if (event[1].type === 'lineEndingBlank') {\n if (event[0] === 'enter') {\n if (\n listItem &&\n !atMarker &&\n !containerBalance &&\n !firstBlankLineIndex\n ) {\n firstBlankLineIndex = index\n }\n atMarker = undefined\n }\n } else if (\n event[1].type === 'linePrefix' ||\n event[1].type === 'listItemValue' ||\n event[1].type === 'listItemMarker' ||\n event[1].type === 'listItemPrefix' ||\n event[1].type === 'listItemPrefixWhitespace'\n ) {\n // Empty.\n } else {\n atMarker = undefined\n }\n if (\n (!containerBalance &&\n event[0] === 'enter' &&\n event[1].type === 'listItemPrefix') ||\n (containerBalance === -1 &&\n event[0] === 'exit' &&\n (event[1].type === 'listUnordered' ||\n event[1].type === 'listOrdered'))\n ) {\n if (listItem) {\n let tailIndex = index\n lineIndex = undefined\n while (tailIndex--) {\n const tailEvent = events[tailIndex]\n if (\n tailEvent[1].type === 'lineEnding' ||\n tailEvent[1].type === 'lineEndingBlank'\n ) {\n if (tailEvent[0] === 'exit') continue\n if (lineIndex) {\n events[lineIndex][1].type = 'lineEndingBlank'\n listSpread = true\n }\n tailEvent[1].type = 'lineEnding'\n lineIndex = tailIndex\n } else if (\n tailEvent[1].type === 'linePrefix' ||\n tailEvent[1].type === 'blockQuotePrefix' ||\n tailEvent[1].type === 'blockQuotePrefixWhitespace' ||\n tailEvent[1].type === 'blockQuoteMarker' ||\n tailEvent[1].type === 'listItemIndent'\n ) {\n // Empty\n } else {\n break\n }\n }\n if (\n firstBlankLineIndex &&\n (!lineIndex || firstBlankLineIndex < lineIndex)\n ) {\n // @ts-expect-error Patched.\n listItem._spread = true\n }\n\n // Fix position.\n listItem.end = Object.assign(\n {},\n lineIndex ? events[lineIndex][1].start : event[1].end\n )\n events.splice(lineIndex || index, 0, ['exit', listItem, event[2]])\n index++\n length++\n }\n\n // Create a new list item.\n if (event[1].type === 'listItemPrefix') {\n listItem = {\n type: 'listItem',\n // @ts-expect-error Patched\n _spread: false,\n start: Object.assign({}, event[1].start)\n }\n // @ts-expect-error: `listItem` is most definitely defined, TS...\n events.splice(index, 0, ['enter', listItem, event[2]])\n index++\n length++\n firstBlankLineIndex = undefined\n atMarker = true\n }\n }\n }\n\n // @ts-expect-error Patched.\n events[start][1]._spread = listSpread\n return length\n }\n\n /**\n * Set data.\n *\n * @template {keyof CompileData} Key\n * Field type.\n * @param {Key} key\n * Key of field.\n * @param {CompileData[Key]} [value]\n * New value.\n * @returns {void}\n * Nothing.\n */\n function setData(key, value) {\n data[key] = value\n }\n\n /**\n * Get data.\n *\n * @template {keyof CompileData} Key\n * Field type.\n * @param {Key} key\n * Key of field.\n * @returns {CompileData[Key]}\n * Value.\n */\n function getData(key) {\n return data[key]\n }\n\n /**\n * Create an opener handle.\n *\n * @param {(token: Token) => Node} create\n * Create a node.\n * @param {Handle} [and]\n * Optional function to also run.\n * @returns {Handle}\n * Handle.\n */\n function opener(create, and) {\n return open\n\n /**\n * @this {CompileContext}\n * @param {Token} token\n * @returns {void}\n */\n function open(token) {\n enter.call(this, create(token), token)\n if (and) and.call(this, token)\n }\n }\n\n /**\n * @this {CompileContext}\n * @returns {void}\n */\n function buffer() {\n this.stack.push({\n type: 'fragment',\n children: []\n })\n }\n\n /**\n * @template {Node} Kind\n * Node type.\n * @this {CompileContext}\n * Context.\n * @param {Kind} node\n * Node to enter.\n * @param {Token} token\n * Corresponding token.\n * @param {OnEnterError | undefined} [errorHandler]\n * Handle the case where this token is open, but it is closed by something else.\n * @returns {Kind}\n * The given node.\n */\n function enter(node, token, errorHandler) {\n const parent = this.stack[this.stack.length - 1]\n // @ts-expect-error: Assume `Node` can exist as a child of `parent`.\n parent.children.push(node)\n this.stack.push(node)\n this.tokenStack.push([token, errorHandler])\n // @ts-expect-error: `end` will be patched later.\n node.position = {\n start: point(token.start)\n }\n return node\n }\n\n /**\n * Create a closer handle.\n *\n * @param {Handle} [and]\n * Optional function to also run.\n * @returns {Handle}\n * Handle.\n */\n function closer(and) {\n return close\n\n /**\n * @this {CompileContext}\n * @param {Token} token\n * @returns {void}\n */\n function close(token) {\n if (and) and.call(this, token)\n exit.call(this, token)\n }\n }\n\n /**\n * @this {CompileContext}\n * Context.\n * @param {Token} token\n * Corresponding token.\n * @param {OnExitError | undefined} [onExitError]\n * Handle the case where another token is open.\n * @returns {Node}\n * The closed node.\n */\n function exit(token, onExitError) {\n const node = this.stack.pop()\n const open = this.tokenStack.pop()\n if (!open) {\n throw new Error(\n 'Cannot close `' +\n token.type +\n '` (' +\n stringifyPosition({\n start: token.start,\n end: token.end\n }) +\n '): it\u2019s not open'\n )\n } else if (open[0].type !== token.type) {\n if (onExitError) {\n onExitError.call(this, token, open[0])\n } else {\n const handler = open[1] || defaultOnError\n handler.call(this, token, open[0])\n }\n }\n node.position.end = point(token.end)\n return node\n }\n\n /**\n * @this {CompileContext}\n * @returns {string}\n */\n function resume() {\n return toString(this.stack.pop())\n }\n\n //\n // Handlers.\n //\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onenterlistordered() {\n setData('expectingFirstListItemValue', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onenterlistitemvalue(token) {\n if (getData('expectingFirstListItemValue')) {\n const ancestor = this.stack[this.stack.length - 2]\n ancestor.start = Number.parseInt(this.sliceSerialize(token), 10)\n setData('expectingFirstListItemValue')\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefencedfenceinfo() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.lang = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefencedfencemeta() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.meta = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefencedfence() {\n // Exit if this is the closing fence.\n if (getData('flowCodeInside')) return\n this.buffer()\n setData('flowCodeInside', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodefenced() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data.replace(/^(\\r?\\n|\\r)|(\\r?\\n|\\r)$/g, '')\n setData('flowCodeInside')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcodeindented() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data.replace(/(\\r?\\n|\\r)$/g, '')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitdefinitionlabelstring(token) {\n const label = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.label = label\n node.identifier = normalizeIdentifier(\n this.sliceSerialize(token)\n ).toLowerCase()\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitdefinitiontitlestring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.title = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitdefinitiondestinationstring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.url = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitatxheadingsequence(token) {\n const node = this.stack[this.stack.length - 1]\n if (!node.depth) {\n const depth = this.sliceSerialize(token).length\n node.depth = depth\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitsetextheadingtext() {\n setData('setextHeadingSlurpLineEnding', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitsetextheadinglinesequence(token) {\n const node = this.stack[this.stack.length - 1]\n node.depth = this.sliceSerialize(token).charCodeAt(0) === 61 ? 1 : 2\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitsetextheading() {\n setData('setextHeadingSlurpLineEnding')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onenterdata(token) {\n const node = this.stack[this.stack.length - 1]\n let tail = node.children[node.children.length - 1]\n if (!tail || tail.type !== 'text') {\n // Add a new text node.\n tail = text()\n // @ts-expect-error: we\u2019ll add `end` later.\n tail.position = {\n start: point(token.start)\n }\n // @ts-expect-error: Assume `parent` accepts `text`.\n node.children.push(tail)\n }\n this.stack.push(tail)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitdata(token) {\n const tail = this.stack.pop()\n tail.value += this.sliceSerialize(token)\n tail.position.end = point(token.end)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlineending(token) {\n const context = this.stack[this.stack.length - 1]\n // If we\u2019re at a hard break, include the line ending in there.\n if (getData('atHardBreak')) {\n const tail = context.children[context.children.length - 1]\n tail.position.end = point(token.end)\n setData('atHardBreak')\n return\n }\n if (\n !getData('setextHeadingSlurpLineEnding') &&\n config.canContainEols.includes(context.type)\n ) {\n onenterdata.call(this, token)\n onexitdata.call(this, token)\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexithardbreak() {\n setData('atHardBreak', true)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexithtmlflow() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexithtmltext() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitcodetext() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.value = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlink() {\n const node = this.stack[this.stack.length - 1]\n // Note: there are also `identifier` and `label` fields on this link node!\n // These are used / cleaned here.\n\n // To do: clean.\n if (getData('inReference')) {\n /** @type {ReferenceType} */\n const referenceType = getData('referenceType') || 'shortcut'\n node.type += 'Reference'\n // @ts-expect-error: mutate.\n node.referenceType = referenceType\n // @ts-expect-error: mutate.\n delete node.url\n delete node.title\n } else {\n // @ts-expect-error: mutate.\n delete node.identifier\n // @ts-expect-error: mutate.\n delete node.label\n }\n setData('referenceType')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitimage() {\n const node = this.stack[this.stack.length - 1]\n // Note: there are also `identifier` and `label` fields on this link node!\n // These are used / cleaned here.\n\n // To do: clean.\n if (getData('inReference')) {\n /** @type {ReferenceType} */\n const referenceType = getData('referenceType') || 'shortcut'\n node.type += 'Reference'\n // @ts-expect-error: mutate.\n node.referenceType = referenceType\n // @ts-expect-error: mutate.\n delete node.url\n delete node.title\n } else {\n // @ts-expect-error: mutate.\n delete node.identifier\n // @ts-expect-error: mutate.\n delete node.label\n }\n setData('referenceType')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlabeltext(token) {\n const string = this.sliceSerialize(token)\n const ancestor = this.stack[this.stack.length - 2]\n // @ts-expect-error: stash this on the node, as it might become a reference\n // later.\n ancestor.label = decodeString(string)\n // @ts-expect-error: same as above.\n ancestor.identifier = normalizeIdentifier(string).toLowerCase()\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitlabel() {\n const fragment = this.stack[this.stack.length - 1]\n const value = this.resume()\n const node = this.stack[this.stack.length - 1]\n // Assume a reference.\n setData('inReference', true)\n if (node.type === 'link') {\n /** @type {Array} */\n // @ts-expect-error: Assume static phrasing content.\n const children = fragment.children\n node.children = children\n } else {\n node.alt = value\n }\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitresourcedestinationstring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.url = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitresourcetitlestring() {\n const data = this.resume()\n const node = this.stack[this.stack.length - 1]\n node.title = data\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitresource() {\n setData('inReference')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onenterreference() {\n setData('referenceType', 'collapsed')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitreferencestring(token) {\n const label = this.resume()\n const node = this.stack[this.stack.length - 1]\n // @ts-expect-error: stash this on the node, as it might become a reference\n // later.\n node.label = label\n // @ts-expect-error: same as above.\n node.identifier = normalizeIdentifier(\n this.sliceSerialize(token)\n ).toLowerCase()\n setData('referenceType', 'full')\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n\n function onexitcharacterreferencemarker(token) {\n setData('characterReferenceType', token.type)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitcharacterreferencevalue(token) {\n const data = this.sliceSerialize(token)\n const type = getData('characterReferenceType')\n /** @type {string} */\n let value\n if (type) {\n value = decodeNumericCharacterReference(\n data,\n type === 'characterReferenceMarkerNumeric' ? 10 : 16\n )\n setData('characterReferenceType')\n } else {\n const result = decodeNamedCharacterReference(data)\n value = result\n }\n const tail = this.stack.pop()\n tail.value += value\n tail.position.end = point(token.end)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitautolinkprotocol(token) {\n onexitdata.call(this, token)\n const node = this.stack[this.stack.length - 1]\n node.url = this.sliceSerialize(token)\n }\n\n /**\n * @this {CompileContext}\n * @type {Handle}\n */\n function onexitautolinkemail(token) {\n onexitdata.call(this, token)\n const node = this.stack[this.stack.length - 1]\n node.url = 'mailto:' + this.sliceSerialize(token)\n }\n\n //\n // Creaters.\n //\n\n /** @returns {Blockquote} */\n function blockQuote() {\n return {\n type: 'blockquote',\n children: []\n }\n }\n\n /** @returns {Code} */\n function codeFlow() {\n return {\n type: 'code',\n lang: null,\n meta: null,\n value: ''\n }\n }\n\n /** @returns {InlineCode} */\n function codeText() {\n return {\n type: 'inlineCode',\n value: ''\n }\n }\n\n /** @returns {Definition} */\n function definition() {\n return {\n type: 'definition',\n identifier: '',\n label: null,\n title: null,\n url: ''\n }\n }\n\n /** @returns {Emphasis} */\n function emphasis() {\n return {\n type: 'emphasis',\n children: []\n }\n }\n\n /** @returns {Heading} */\n function heading() {\n // @ts-expect-error `depth` will be set later.\n return {\n type: 'heading',\n depth: undefined,\n children: []\n }\n }\n\n /** @returns {Break} */\n function hardBreak() {\n return {\n type: 'break'\n }\n }\n\n /** @returns {HTML} */\n function html() {\n return {\n type: 'html',\n value: ''\n }\n }\n\n /** @returns {Image} */\n function image() {\n return {\n type: 'image',\n title: null,\n url: '',\n alt: null\n }\n }\n\n /** @returns {Link} */\n function link() {\n return {\n type: 'link',\n title: null,\n url: '',\n children: []\n }\n }\n\n /**\n * @param {Token} token\n * @returns {List}\n */\n function list(token) {\n return {\n type: 'list',\n ordered: token.type === 'listOrdered',\n start: null,\n // @ts-expect-error Patched.\n spread: token._spread,\n children: []\n }\n }\n\n /**\n * @param {Token} token\n * @returns {ListItem}\n */\n function listItem(token) {\n return {\n type: 'listItem',\n // @ts-expect-error Patched.\n spread: token._spread,\n checked: null,\n children: []\n }\n }\n\n /** @returns {Paragraph} */\n function paragraph() {\n return {\n type: 'paragraph',\n children: []\n }\n }\n\n /** @returns {Strong} */\n function strong() {\n return {\n type: 'strong',\n children: []\n }\n }\n\n /** @returns {Text} */\n function text() {\n return {\n type: 'text',\n value: ''\n }\n }\n\n /** @returns {ThematicBreak} */\n function thematicBreak() {\n return {\n type: 'thematicBreak'\n }\n }\n}\n\n/**\n * Copy a point-like value.\n *\n * @param {Point} d\n * Point-like value.\n * @returns {Point}\n * unist point.\n */\nfunction point(d) {\n return {\n line: d.line,\n column: d.column,\n offset: d.offset\n }\n}\n\n/**\n * @param {Config} combined\n * @param {Array>} extensions\n * @returns {void}\n */\nfunction configure(combined, extensions) {\n let index = -1\n while (++index < extensions.length) {\n const value = extensions[index]\n if (Array.isArray(value)) {\n configure(combined, value)\n } else {\n extension(combined, value)\n }\n }\n}\n\n/**\n * @param {Config} combined\n * @param {Extension} extension\n * @returns {void}\n */\nfunction extension(combined, extension) {\n /** @type {keyof Extension} */\n let key\n for (key in extension) {\n if (own.call(extension, key)) {\n if (key === 'canContainEols') {\n const right = extension[key]\n if (right) {\n combined[key].push(...right)\n }\n } else if (key === 'transforms') {\n const right = extension[key]\n if (right) {\n combined[key].push(...right)\n }\n } else if (key === 'enter' || key === 'exit') {\n const right = extension[key]\n if (right) {\n Object.assign(combined[key], right)\n }\n }\n }\n }\n}\n\n/** @type {OnEnterError} */\nfunction defaultOnError(left, right) {\n if (left) {\n throw new Error(\n 'Cannot close `' +\n left.type +\n '` (' +\n stringifyPosition({\n start: left.start,\n end: left.end\n }) +\n '): a different token (`' +\n right.type +\n '`, ' +\n stringifyPosition({\n start: right.start,\n end: right.end\n }) +\n ') is open'\n )\n } else {\n throw new Error(\n 'Cannot close document, a token (`' +\n right.type +\n '`, ' +\n stringifyPosition({\n start: right.start,\n end: right.end\n }) +\n ') is still open'\n )\n }\n}\n", "import { l as log, J as decodeEntities } from \"./mermaid-934d9bea.js\";\nimport { fromMarkdown } from \"mdast-util-from-markdown\";\nimport { dedent } from \"ts-dedent\";\nfunction preprocessMarkdown(markdown) {\n const withoutMultipleNewlines = markdown.replace(/\\n{2,}/g, \"\\n\");\n const withoutExtraSpaces = dedent(withoutMultipleNewlines);\n return withoutExtraSpaces;\n}\nfunction markdownToLines(markdown) {\n const preprocessedMarkdown = preprocessMarkdown(markdown);\n const { children } = fromMarkdown(preprocessedMarkdown);\n const lines = [[]];\n let currentLine = 0;\n function processNode(node, parentType = \"normal\") {\n if (node.type === \"text\") {\n const textLines = node.value.split(\"\\n\");\n textLines.forEach((textLine, index) => {\n if (index !== 0) {\n currentLine++;\n lines.push([]);\n }\n textLine.split(\" \").forEach((word) => {\n if (word) {\n lines[currentLine].push({ content: word, type: parentType });\n }\n });\n });\n } else if (node.type === \"strong\" || node.type === \"emphasis\") {\n node.children.forEach((contentNode) => {\n processNode(contentNode, node.type);\n });\n }\n }\n children.forEach((treeNode) => {\n if (treeNode.type === \"paragraph\") {\n treeNode.children.forEach((contentNode) => {\n processNode(contentNode);\n });\n }\n });\n return lines;\n}\nfunction markdownToHTML(markdown) {\n const { children } = fromMarkdown(markdown);\n function output(node) {\n if (node.type === \"text\") {\n return node.value.replace(/\\n/g, \"
      \");\n } else if (node.type === \"strong\") {\n return `${node.children.map(output).join(\"\")}`;\n } else if (node.type === \"emphasis\") {\n return `${node.children.map(output).join(\"\")}`;\n } else if (node.type === \"paragraph\") {\n return `

      ${node.children.map(output).join(\"\")}

      `;\n }\n return `Unsupported markdown: ${node.type}`;\n }\n return children.map(output).join(\"\");\n}\nfunction splitTextToChars(text) {\n if (Intl.Segmenter) {\n return [...new Intl.Segmenter().segment(text)].map((s) => s.segment);\n }\n return [...text];\n}\nfunction splitWordToFitWidth(checkFit, word) {\n const characters = splitTextToChars(word.content);\n return splitWordToFitWidthRecursion(checkFit, [], characters, word.type);\n}\nfunction splitWordToFitWidthRecursion(checkFit, usedChars, remainingChars, type) {\n if (remainingChars.length === 0) {\n return [\n { content: usedChars.join(\"\"), type },\n { content: \"\", type }\n ];\n }\n const [nextChar, ...rest] = remainingChars;\n const newWord = [...usedChars, nextChar];\n if (checkFit([{ content: newWord.join(\"\"), type }])) {\n return splitWordToFitWidthRecursion(checkFit, newWord, rest, type);\n }\n if (usedChars.length === 0 && nextChar) {\n usedChars.push(nextChar);\n remainingChars.shift();\n }\n return [\n { content: usedChars.join(\"\"), type },\n { content: remainingChars.join(\"\"), type }\n ];\n}\nfunction splitLineToFitWidth(line, checkFit) {\n if (line.some(({ content }) => content.includes(\"\\n\"))) {\n throw new Error(\"splitLineToFitWidth does not support newlines in the line\");\n }\n return splitLineToFitWidthRecursion(line, checkFit);\n}\nfunction splitLineToFitWidthRecursion(words, checkFit, lines = [], newLine = []) {\n if (words.length === 0) {\n if (newLine.length > 0) {\n lines.push(newLine);\n }\n return lines.length > 0 ? lines : [];\n }\n let joiner = \"\";\n if (words[0].content === \" \") {\n joiner = \" \";\n words.shift();\n }\n const nextWord = words.shift() ?? { content: \" \", type: \"normal\" };\n const lineWithNextWord = [...newLine];\n if (joiner !== \"\") {\n lineWithNextWord.push({ content: joiner, type: \"normal\" });\n }\n lineWithNextWord.push(nextWord);\n if (checkFit(lineWithNextWord)) {\n return splitLineToFitWidthRecursion(words, checkFit, lines, lineWithNextWord);\n }\n if (newLine.length > 0) {\n lines.push(newLine);\n words.unshift(nextWord);\n } else if (nextWord.content) {\n const [line, rest] = splitWordToFitWidth(checkFit, nextWord);\n lines.push([line]);\n if (rest.content) {\n words.unshift(rest);\n }\n }\n return splitLineToFitWidthRecursion(words, checkFit, lines);\n}\nfunction applyStyle(dom, styleFn) {\n if (styleFn) {\n dom.attr(\"style\", styleFn);\n }\n}\nfunction addHtmlSpan(element, node, width, classes, addBackground = false) {\n const fo = element.append(\"foreignObject\");\n const div = fo.append(\"xhtml:div\");\n const label = node.label;\n const labelClass = node.isNode ? \"nodeLabel\" : \"edgeLabel\";\n div.html(\n `\n \" + label + \"\"\n );\n applyStyle(div, node.labelStyle);\n div.style(\"display\", \"table-cell\");\n div.style(\"white-space\", \"nowrap\");\n div.style(\"max-width\", width + \"px\");\n div.attr(\"xmlns\", \"http://www.w3.org/1999/xhtml\");\n if (addBackground) {\n div.attr(\"class\", \"labelBkg\");\n }\n let bbox = div.node().getBoundingClientRect();\n if (bbox.width === width) {\n div.style(\"display\", \"table\");\n div.style(\"white-space\", \"break-spaces\");\n div.style(\"width\", width + \"px\");\n bbox = div.node().getBoundingClientRect();\n }\n fo.style(\"width\", bbox.width);\n fo.style(\"height\", bbox.height);\n return fo.node();\n}\nfunction createTspan(textElement, lineIndex, lineHeight) {\n return textElement.append(\"tspan\").attr(\"class\", \"text-outer-tspan\").attr(\"x\", 0).attr(\"y\", lineIndex * lineHeight - 0.1 + \"em\").attr(\"dy\", lineHeight + \"em\");\n}\nfunction computeWidthOfText(parentNode, lineHeight, line) {\n const testElement = parentNode.append(\"text\");\n const testSpan = createTspan(testElement, 1, lineHeight);\n updateTextContentAndStyles(testSpan, line);\n const textLength = testSpan.node().getComputedTextLength();\n testElement.remove();\n return textLength;\n}\nfunction computeDimensionOfText(parentNode, lineHeight, text) {\n var _a;\n const testElement = parentNode.append(\"text\");\n const testSpan = createTspan(testElement, 1, lineHeight);\n updateTextContentAndStyles(testSpan, [{ content: text, type: \"normal\" }]);\n const textDimension = (_a = testSpan.node()) == null ? void 0 : _a.getBoundingClientRect();\n if (textDimension) {\n testElement.remove();\n }\n return textDimension;\n}\nfunction createFormattedText(width, g, structuredText, addBackground = false) {\n const lineHeight = 1.1;\n const labelGroup = g.append(\"g\");\n const bkg = labelGroup.insert(\"rect\").attr(\"class\", \"background\");\n const textElement = labelGroup.append(\"text\").attr(\"y\", \"-10.1\");\n let lineIndex = 0;\n for (const line of structuredText) {\n const checkWidth = (line2) => computeWidthOfText(labelGroup, lineHeight, line2) <= width;\n const linesUnderWidth = checkWidth(line) ? [line] : splitLineToFitWidth(line, checkWidth);\n for (const preparedLine of linesUnderWidth) {\n const tspan = createTspan(textElement, lineIndex, lineHeight);\n updateTextContentAndStyles(tspan, preparedLine);\n lineIndex++;\n }\n }\n if (addBackground) {\n const bbox = textElement.node().getBBox();\n const padding = 2;\n bkg.attr(\"x\", -padding).attr(\"y\", -padding).attr(\"width\", bbox.width + 2 * padding).attr(\"height\", bbox.height + 2 * padding);\n return labelGroup.node();\n } else {\n return textElement.node();\n }\n}\nfunction updateTextContentAndStyles(tspan, wrappedLine) {\n tspan.text(\"\");\n wrappedLine.forEach((word, index) => {\n const innerTspan = tspan.append(\"tspan\").attr(\"font-style\", word.type === \"emphasis\" ? \"italic\" : \"normal\").attr(\"class\", \"text-inner-tspan\").attr(\"font-weight\", word.type === \"strong\" ? \"bold\" : \"normal\");\n if (index === 0) {\n innerTspan.text(word.content);\n } else {\n innerTspan.text(\" \" + word.content);\n }\n });\n}\nconst createText = (el, text = \"\", {\n style = \"\",\n isTitle = false,\n classes = \"\",\n useHtmlLabels = true,\n isNode = true,\n width = 200,\n addSvgBackground = false\n} = {}) => {\n log.info(\"createText\", text, style, isTitle, classes, useHtmlLabels, isNode, addSvgBackground);\n if (useHtmlLabels) {\n const htmlText = markdownToHTML(text);\n const node = {\n isNode,\n label: decodeEntities(htmlText).replace(\n /fa[blrs]?:fa-[\\w-]+/g,\n (s) => ``\n ),\n labelStyle: style.replace(\"fill:\", \"color:\")\n };\n const vertexNode = addHtmlSpan(el, node, width, classes, addSvgBackground);\n return vertexNode;\n } else {\n const structuredText = markdownToLines(text);\n const svgLabel = createFormattedText(width, el, structuredText, addSvgBackground);\n return svgLabel;\n }\n};\nexport {\n createText as a,\n computeDimensionOfText as c\n};\n"], "mappings": "4GAYA,IAAMA,GAAe,CAAC,EAef,SAASC,GAASC,EAAOC,EAAS,CACvC,IAAMC,EAAWD,GAAWH,GACtBK,EACJ,OAAOD,EAAS,iBAAoB,UAChCA,EAAS,gBACT,GACAE,EACJ,OAAOF,EAAS,aAAgB,UAAYA,EAAS,YAAc,GAErE,OAAOG,GAAIL,EAAOG,EAAiBC,CAAW,CAChD,CAcA,SAASC,GAAIL,EAAOG,EAAiBC,EAAa,CAChD,GAAIE,GAAKN,CAAK,EAAG,CACf,GAAI,UAAWA,EACb,OAAOA,EAAM,OAAS,QAAU,CAACI,EAAc,GAAKJ,EAAM,MAG5D,GAAIG,GAAmB,QAASH,GAASA,EAAM,IAC7C,OAAOA,EAAM,IAGf,GAAI,aAAcA,EAChB,OAAOO,GAAIP,EAAM,SAAUG,EAAiBC,CAAW,CAE3D,CAEA,OAAI,MAAM,QAAQJ,CAAK,EACdO,GAAIP,EAAOG,EAAiBC,CAAW,EAGzC,EACT,CAcA,SAASG,GAAIC,EAAQL,EAAiBC,EAAa,CAEjD,IAAMK,EAAS,CAAC,EACZC,EAAQ,GAEZ,KAAO,EAAEA,EAAQF,EAAO,QACtBC,EAAOC,CAAK,EAAIL,GAAIG,EAAOE,CAAK,EAAGP,EAAiBC,CAAW,EAGjE,OAAOK,EAAO,KAAK,EAAE,CACvB,CAUA,SAASH,GAAKN,EAAO,CACnB,MAAO,GAAQA,GAAS,OAAOA,GAAU,SAC3C,CC3FO,SAASW,EAAOC,EAAMC,EAAOC,EAAQC,EAAO,CACjD,IAAMC,EAAMJ,EAAK,OACbK,EAAa,EAGbC,EAUJ,GARIL,EAAQ,EACVA,EAAQ,CAACA,EAAQG,EAAM,EAAIA,EAAMH,EAEjCA,EAAQA,E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tDF,EAAM,KAAK,EAAE,EACbE,EAAY,QAAQ,CAAChE,EAAMD,IAAU,CACnC,IAAMkE,EAAaH,EAAM,OAAO,OAAO,EAAE,KAAK,aAAc9D,EAAK,OAAS,WAAa,SAAW,QAAQ,EAAE,KAAK,QAAS,kBAAkB,EAAE,KAAK,cAAeA,EAAK,OAAS,SAAW,OAAS,QAAQ,EACxMD,IAAU,EACZkE,EAAW,KAAKjE,EAAK,OAAO,EAE5BiE,EAAW,KAAK,IAAMjE,EAAK,OAAO,CAEtC,CAAC,CACH,CACA,IAAMkE,GAAa,CAACC,EAAI7D,EAAO,GAAI,CACjC,MAAA8D,EAAQ,GACR,QAAAC,EAAU,GACV,QAAApC,EAAU,GACV,cAAAqC,EAAgB,GAChB,OAAAC,EAAS,GACT,MAAAvC,EAAQ,IACR,iBAAAwC,EAAmB,EACrB,EAAI,CAAC,IAAM,CAET,GADAC,GAAI,KAAK,aAAcnE,EAAM8D,EAAOC,EAASpC,EAASqC,EAAeC,EAAQC,CAAgB,EACzFF,EAAe,CACjB,IAAMI,EAAWvE,GAAeG,CAAI,EAC9BV,EAAO,CACX,OAAA2E,EACA,MAAOI,GAAeD,CAAQ,EAAE,QAC9B,uBACCnE,GAAM,aAAaA,EAAE,QAAQ,IAAK,GAAG,CAAC,QACzC,EACA,WAAY6D,EAAM,QAAQ,QAAS,QAAQ,CAC7C,EAEA,OADmBtC,GAAYqC,EAAIvE,EAAMoC,EAAOC,EAASuC,CAAgB,CAE3E,KAAO,CACL,IAAMjB,EAAiBlE,GAAgBiB,CAAI,EAE3C,OADiB+C,GAAoBrB,EAAOmC,EAAIZ,EAAgBiB,CAAgB,CAElF,CACF", "names": ["emptyOptions", "toString", "value", "options", "settings", "includeImageAlt", "includeHtml", "one", "node", "all", "values", "result", "index", "splice", "list", "start", "remove", "items", "end", "chunkStart", "parameters", "push", "hasOwnProperty", "combineExtensions", "extensions", "all", "index", "syntaxExtension", "extension", "hook", "left", "right", "code", "value", "constructs", "existing", "list", "before", "splice", "unicodePunctuationRegex", "asciiAlpha", "regexCheck", "asciiDigit", "asciiHexDigit", "asciiAlphanumeric", "asciiPunctuation", "asciiAtext", "asciiControl", "code", "markdownLineEndingOrSpace", "markdownLineEnding", "markdownSpace", "unicodeWhitespace", "unicodePunctuation", "unicodePunctuationRegex", "regex", "check", "factorySpace", "effects", "ok", "type", "max", "limit", "size", "start", "code", "markdownSpace", "prefix", "content", "initializeContent", "effects", "contentStart", "afterContentStartConstruct", "paragraphInitial", "previous", "code", "factorySpace", "lineStart", "token", "data", "markdownLineEnding", "document", "initializeDocument", "containerConstruct", "tokenizeContainer", "effects", "self", "stack", "continued", "childFlow", "childToken", "lineStartOffset", "start", "code", "item", "documentContinue", "checkNewContainers", "closeFlow", "indexBeforeExits", "indexBeforeFlow", "point", "exitContainers", "index", "splice", "documentContinued", "flowStart", "thereIsANewContainer", "thereIsNoNewContainer", "containerContinue", "flowContinue", "writeToChild", "markdownLineEnding", "token", "eof", "stream", "seen", "size", "entry", "ok", "nok", "factorySpace", "classifyCharacter", "code", "markdownLineEndingOrSpace", "unicodeWhitespace", "unicodePunctuation", "resolveAll", "constructs", "events", "context", "called", "index", "resolve", "attention", "tokenizeAttention", "resolveAllAttention", "events", "context", "index", "open", "group", "text", "openingSequence", "closingSequence", "use", "nextEvents", "offset", "start", "end", "movePoint", "push", "resolveAll", "splice", "effects", "ok", "attentionMarkers", "previous", "before", "classifyCharacter", "marker", "code", "sequence", "token", "after", "close", "point", "autolink", "tokenizeAutolink", "effects", "ok", "nok", "size", "start", "code", "open", "asciiAlpha", "schemeOrEmailAtext", "asciiAtext", "emailAtext", "asciiAlphanumeric", "schemeInsideOrEmailAtext", "urlInside", "end", "asciiControl", "emailAtSignOrDot", "emailLabel", "emailValue", "blankLine", "tokenizeBlankLine", "effects", "ok", "nok", "factorySpace", "afterWhitespace", "code", "markdownLineEnding", "blockQuote", "tokenizeBlockQuoteStart", "tokenizeBlockQuoteContinuation", "exit", "effects", "ok", "nok", "self", "start", "code", "state", "after", "markdownSpace", "factorySpace", "characterEscape", "tokenizeCharacterEscape", "effects", "ok", "nok", "start", "code", "open", "asciiPunctuation", "element", "decodeNamedCharacterReference", "value", "characterReference", "char", "characterReference", "tokenizeCharacterReference", "effects", "ok", "nok", "self", "size", "max", "test", "start", "code", "open", "numeric", "asciiAlphanumeric", "value", "asciiHexDigit", "asciiDigit", "token", "decodeNamedCharacterReference", "codeFenced", "tokenizeCodeFenced", "effects", "ok", "nok", "self", "closingFenceConstruct", "tokenizeClosingFence", "nonLazyLine", "tokenizeNonLazyLine", "tail", "initialPrefix", "sizeOpen", "marker", "start", "code", "sequenceOpen", "factorySpace", "infoOpen", "markdownLineEnding", "openAfter", "info", "markdownLineEndingOrSpace", "infoAfter", "meta", "contentStart", "after", "contentContinue", "lineStart", "size", "closingSequenceStart", "closingSequence", "closingSequenceEnd", "codeIndented", "tokenizeCodeIndented", "indentedContent", "tokenizeIndentedContent", "effects", "ok", "nok", "self", "start", "code", "factorySpace", "afterStartPrefix", "tail", "afterPrefix", "after", "markdownLineEnding", "content", "codeText", "tokenizeCodeText", "resolveCodeText", "previous", "events", "tailExitIndex", "headEnterIndex", "index", "enter", "code", "effects", "ok", "nok", "self", "sizeOpen", "size", "token", "start", "openingSequence", "gap", "closingSequence", "markdownLineEnding", "data", "subtokenize", "events", "jumps", "index", "event", "lineIndex", "otherIndex", "otherEvent", "parameters", "subevents", "more", "subcontent", "splice", "eventIndex", "token", "context", "startPosition", "startPositions", "tokenizer", "childEvents", "gaps", "stream", "previous", "current", "adjust", "start", "breaks", "slice", "content", "tokenizeContent", "resolveContent", "continuationConstruct", "tokenizeContinuation", "events", "subtokenize", "effects", "ok", "previous", "start", "code", "data", "contentEnd", "markdownLineEnding", "contentContinue", "nok", "self", "startLookahead", "factorySpace", "prefixed", "tail", "factoryDestination", "effects", "ok", "nok", "type", "literalType", "literalMarkerType", "rawType", "stringType", "max", "limit", "balance", "start", "code", "destinationEnclosedBefore", "asciiControl", "destinationRaw", "destinationEnclosed", "markdownLineEnding", "destinationEnclosedEscape", "markdownLineEndingOrSpace", "destinationRawEscape", "factoryLabel", "effects", "ok", "nok", "type", "markerType", "stringType", "self", "size", "data", "start", "code", "atBreak", "markdownLineEnding", "label", "markdownSpace", "labelEscape", "factoryTitle", "effects", "ok", "nok", "type", "markerType", "stringType", "marker", "start", "code", "atFirstTitleBreak", "atTitleBreak", "markdownLineEnding", "factorySpace", "title", "titleEscape", "factoryWhitespace", "effects", "ok", "seen", "start", "code", "markdownLineEnding", "markdownSpace", "factorySpace", "normalizeIdentifier", "value", "definition", "tokenizeDefinition", "titleConstruct", "tokenizeTitle", "effects", "ok", "nok", "self", "identifier", "start", "code", "factoryLabel", "labelAfter", "normalizeIdentifier", "factoryWhitespace", "factoryDestination", "factorySpace", "after", "markdownLineEnding", "markdownLineEndingOrSpace", "before", "factoryTitle", "hardBreakEscape", "tokenizeHardBreakEscape", "effects", "ok", "nok", "start", "code", "open", "markdownLineEnding", "headingAtx", "tokenizeHeadingAtx", "resolveHeadingAtx", "events", "context", "contentEnd", "contentStart", "content", "text", "splice", "effects", "ok", "nok", "self", "size", "start", "code", "fenceOpenInside", "markdownLineEndingOrSpace", "headingBreak", "sequence", "markdownLineEnding", "markdownSpace", "factorySpace", "data", "htmlBlockNames", "htmlRawNames", "htmlFlow", "tokenizeHtmlFlow", "resolveToHtmlFlow", "nextBlankConstruct", "tokenizeNextBlank", "events", "index", "effects", "ok", "nok", "self", "kind", "startTag", "buffer", "marker", "start", "code", "open", "declarationStart", "tagCloseStart", "continuationDeclarationInside", "asciiAlpha", "tagName", "commentOpenInside", "cdataOpenInside", "continuation", "markdownLineEndingOrSpace", "htmlRawNames", "htmlBlockNames", "basicSelfClosing", "completeAttributeNameBefore", "completeClosingTagAfter", "asciiAlphanumeric", "markdownSpace", "completeEnd", "completeAttributeName", "completeAttributeNameAfter", "completeAttributeValueBefore", "completeAttributeValueQuoted", "completeAttributeValueUnquoted", "markdownLineEnding", "completeAttributeValueQuotedAfter", "completeAfter", "continuationCommentInside", "continuationRawTagOpen", "continuationClose", "continuationCharacterDataInside", "continuationAtLineEnding", "htmlContinueStart", "done", "htmlLineEnd", "lineStart", "continuationRawEndTag", "blankLine", "htmlText", "tokenizeHtmlText", "effects", "ok", "nok", "self", "marker", "buffer", "index", "returnState", "start", "code", "open", "declarationOpen", "tagCloseStart", "instruction", "asciiAlpha", "tagOpen", "commentOpen", "cdataOpen", "declaration", "commentStart", "commentStartDash", "comment", "commentClose", "markdownLineEnding", "atLineEnding", "end", "cdata", "cdataClose", "cdataEnd", "instructionClose", "tagClose", "asciiAlphanumeric", "tagCloseBetween", "markdownSpace", "markdownLineEndingOrSpace", "tagOpenBetween", "tagOpenAttributeName", "tagOpenAttributeNameAfter", "tagOpenAttributeValueBefore", "tagOpenAttributeValueQuoted", "tagOpenAttributeValueUnquoted", "tagOpenAttributeValueQuotedAfter", "factorySpace", "afterPrefix", "labelEnd", "tokenizeLabelEnd", "resolveToLabelEnd", "resolveAllLabelEnd", "resourceConstruct", "tokenizeResource", "fullReferenceConstruct", "tokenizeFullReference", "collapsedReferenceConstruct", "tokenizeCollapsedReference", "events", "index", "token", "context", "offset", "open", "close", "media", "group", "label", "text", "push", "resolveAll", "splice", "effects", "ok", "nok", "self", "labelStart", "defined", "start", "code", "balanced", "normalizeIdentifier", "afterLabelEnd", "factoryWhitespace", "end", "factoryDestination", "destinationAfter", "markdownLineEndingOrSpace", "between", "factoryTitle", "factoryLabel", "afterLabel", "labelStartImage", "tokenizeLabelStartImage", "labelEnd", "effects", "ok", "nok", "self", "start", "code", "open", "after", "labelStartLink", "tokenizeLabelStartLink", "labelEnd", "effects", "ok", "nok", "self", "start", "code", "after", "lineEnding", "tokenizeLineEnding", "effects", "ok", "start", "code", "factorySpace", "thematicBreak", "tokenizeThematicBreak", "effects", "ok", "nok", "size", "marker", "start", "code", "atBreak", "sequence", "markdownSpace", "factorySpace", "markdownLineEnding", "list", "tokenizeListStart", "tokenizeListContinuation", "tokenizeListEnd", "listItemPrefixWhitespaceConstruct", "tokenizeListItemPrefixWhitespace", "indentConstruct", "tokenizeIndent", "effects", "ok", "nok", "self", "tail", "initialSize", "size", "start", "code", "kind", "asciiDigit", "thematicBreak", "atMarker", "inside", "blankLine", "onBlank", "endOfPrefix", "otherPrefix", "markdownSpace", "notBlank", "factorySpace", "notInCurrentItem", "afterPrefix", "setextUnderline", "tokenizeSetextUnderline", "resolveToSetextUnderline", "events", "context", "index", "content", "text", "definition", "heading", "effects", "ok", "nok", "self", "marker", "paragraph", "start", "code", "closingSequence", "factorySpace", "closingSequenceEnd", "markdownLineEnding", "flow", "initializeFlow", "effects", "self", "initial", "blankLine", "atBlankEnding", "afterConstruct", "factorySpace", "content", "code", "resolver", "createResolver", "string", "initializeFactory", "text", "field", "initializeText", "resolveAllLineSuffixes", "effects", "self", "constructs", "start", "notText", "code", "atBreak", "data", "list", "index", "item", "extraResolver", "resolveAllText", "events", "context", "enter", "eventIndex", "chunks", "bufferIndex", "size", "tabs", "chunk", "token", "createTokenizer", "parser", "initialize", "from", "point", "columnStart", "resolveAllConstructs", "chunks", "stack", "consumed", "effects", "consume", "enter", "exit", "constructFactory", "onsuccessfulconstruct", "onsuccessfulcheck", "context", "sliceStream", "sliceSerialize", "now", "defineSkip", "write", "state", "expectedCode", "slice", "push", "main", "addResult", "resolveAll", "token", "expandTabs", "serializeChunks", "sliceChunks", "value", "accountForPotentialSkip", "chunkIndex", "chunk", "go", "code", "markdownLineEnding", "type", "fields", "construct", "info", "_", "onreturn", "hook", "constructs", "returnState", "bogusState", "listOfConstructs", "constructIndex", "currentConstruct", "handleListOfConstructs", "handleMapOfConstructs", "map", "start", "def", "all", "list", "handleConstruct", "store", "nok", "ok", "splice", "startPoint", "startPrevious", "startCurrentConstruct", "startEventsIndex", "startStack", "restore", "startIndex", "startBufferIndex", "endIndex", "endBufferIndex", "view", "index", "result", "atTab", "constructs_exports", "__export", "attentionMarkers", "contentInitial", "disable", "document", "flow", "flowInitial", "insideSpan", "string", "text", "document", "list", "blockQuote", "contentInitial", "definition", "flowInitial", "codeIndented", "flow", "headingAtx", "thematicBreak", "setextUnderline", "htmlFlow", "codeFenced", "string", "characterReference", "characterEscape", "text", "lineEnding", "labelStartImage", "attention", "autolink", "htmlText", "labelStartLink", "hardBreakEscape", "labelEnd", "codeText", "insideSpan", "resolver", "attentionMarkers", "disable", "parse", "options", "constructs", "combineExtensions", "constructs_exports", "parser", "create", "content", "document", "flow", "string", "text", "initial", "creator", "from", "createTokenizer", "search", "preprocess", "column", "buffer", "start", "atCarriageReturn", "preprocessor", "value", "encoding", "end", "chunks", "match", "next", "startPosition", "endPosition", "code", "postprocess", "events", "subtokenize", "decodeNumericCharacterReference", "value", "base", "code", "characterEscapeOrReference", "decodeString", "value", "decode", "$0", "$1", "$2", "head", "hex", "decodeNumericCharacterReference", "decodeNamedCharacterReference", "stringifyPosition", "value", "position", "point", "index", "pos", "own", "fromMarkdown", "value", "encoding", "options", "compiler", "postprocess", "parse", "preprocess", "config", "opener", "link", "onenterdata", "heading", "blockQuote", "codeFlow", "buffer", "codeText", "definition", "emphasis", "hardBreak", "html", "image", "listItem", "onenterlistitemvalue", "list", "onenterlistordered", "paragraph", "onenterreference", "strong", "thematicBreak", "closer", "onexitatxheadingsequence", "onexitautolinkemail", "onexitautolinkprotocol", "onexitdata", "onexitcharacterreferencemarker", "onexitcharacterreferencevalue", "onexitcodefenced", "onexitcodefencedfence", "onexitcodefencedfenceinfo", "onexitcodefencedfencemeta", "onexitcodeindented", "onexitcodetext", "onexitdefinitiondestinationstring", "onexitdefinitionlabelstring", "onexitdefinitiontitlestring", "onexithardbreak", "onexithtmlflow", "onexithtmltext", "onexitimage", "onexitlabel", "onexitlabeltext", "onexitlineending", "onexitlink", "onexitreferencestring", "onexitresourcedestinationstring", "onexitresourcetitlestring", "onexitresource", "onexitsetextheading", "onexitsetextheadinglinesequence", "onexitsetextheadingtext", "configure", "data", "compile", "events", "tree", "context", "enter", "exit", "resume", "setData", "getData", "listStack", "index", "tail", "prepareList", "handler", "defaultOnError", "point", "start", "length", "containerBalance", "listSpread", "lineIndex", "firstBlankLineIndex", "atMarker", "event", "tailIndex", "tailEvent", "key", "create", "and", "open", "token", "node", "errorHandler", "close", "onExitError", "stringifyPosition", "toString", "ancestor", "label", "normalizeIdentifier", "depth", "text", "referenceType", "string", "decodeString", "fragment", "children", "type", "decodeNumericCharacterReference", "decodeNamedCharacterReference", "d", "combined", "extensions", "extension", "right", "left", "preprocessMarkdown", "markdown", "withoutMultipleNewlines", "dedent", "markdownToLines", "preprocessedMarkdown", "children", "fromMarkdown", "lines", "currentLine", "processNode", "node", "parentType", "textLine", "index", "word", "contentNode", "treeNode", "markdownToHTML", "output", "splitTextToChars", "text", "s", "splitWordToFitWidth", "checkFit", "characters", "splitWordToFitWidthRecursion", "usedChars", "remainingChars", "type", "nextChar", "rest", "newWord", "splitLineToFitWidth", "line", "content", "splitLineToFitWidthRecursion", "words", "newLine", "joiner", "nextWord", "lineWithNextWord", "applyStyle", "dom", "styleFn", "addHtmlSpan", "element", "width", "classes", "addBackground", "fo", "div", "label", "labelClass", "bbox", "createTspan", "textElement", "lineIndex", "lineHeight", "computeWidthOfText", "parentNode", "testElement", "testSpan", "updateTextContentAndStyles", "textLength", "computeDimensionOfText", "_a", "textDimension", "createFormattedText", "g", "structuredText", "labelGroup", "bkg", "checkWidth", "line2", "linesUnderWidth", "preparedLine", "tspan", "padding", "wrappedLine", "innerTspan", "createText", "el", "style", "isTitle", "useHtmlLabels", "isNode", "addSvgBackground", "log$1", "htmlText", "decodeEntities"] } diff --git a/docs/public/classDiagram-936ed81e-YM34DHJU.min.js b/docs/public/classDiagram-48ab76fb-DDANGYBP.min.js similarity index 97% rename from docs/public/classDiagram-936ed81e-YM34DHJU.min.js rename to docs/public/classDiagram-48ab76fb-DDANGYBP.min.js index b52b571b..3b5ba870 100644 --- a/docs/public/classDiagram-936ed81e-YM34DHJU.min.js +++ b/docs/public/classDiagram-48ab76fb-DDANGYBP.min.js @@ -1,3 +1,3 @@ -import{a as G,b as v,c as I}from"./chunk-F3IAZVFZ.min.js";import{j as A,k as W}from"./chunk-3BJWU2V2.min.js";import{$a as P,G as _,Ga as y,I as C,J as R,Ka as O,Za as T,b as J,c as Z,h as E,jb as S}from"./chunk-65WDIALL.min.js";import{d as N}from"./chunk-P42HNYSU.min.js";var at=N(J(),1),it=N(Z(),1),nt=N(R(),1);var X=0,F=function(i,r,t,o,p){let g=function(e){switch(e){case p.db.relationType.AGGREGATION:return"aggregation";case p.db.relationType.EXTENSION:return"extension";case p.db.relationType.COMPOSITION:return"composition";case p.db.relationType.DEPENDENCY:return"dependency";case p.db.relationType.LOLLIPOP:return"lollipop"}};r.points=r.points.filter(e=>!Number.isNaN(e.y));let s=r.points,c=_().x(function(e){return e.x}).y(function(e){return e.y}).curve(C),n=i.append("path").attr("d",c(s)).attr("id","edge"+X).attr("class","relation"),a="";o.arrowMarkerAbsolute&&(a=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,a=a.replace(/\(/g,"\\("),a=a.replace(/\)/g,"\\)")),t.relation.lineType==1&&n.attr("class","relation dashed-line"),t.relation.lineType==10&&n.attr("class","relation dotted-line"),t.relation.type1!=="none"&&n.attr("marker-start","url("+a+"#"+g(t.relation.type1)+"Start)"),t.relation.type2!=="none"&&n.attr("marker-end","url("+a+"#"+g(t.relation.type2)+"End)");let f,h,x=r.points.length,b=T.calcLabelPosition(r.points);f=b.x,h=b.y;let u,m,w,k;if(x%2!==0&&x>1){let e=T.calcCardinalityPosition(t.relation.type1!=="none",r.points,r.points[0]),d=T.calcCardinalityPosition(t.relation.type2!=="none",r.points,r.points[x-1]);y.debug("cardinality_1_point "+JSON.stringify(e)),y.debug("cardinality_2_point "+JSON.stringify(d)),u=e.x,m=e.y,w=d.x,k=d.y}if(t.title!==void 0){let e=i.append("g").attr("class","classLabel"),d=e.append("text").attr("class","label").attr("x",f).attr("y",h).attr("fill","red").attr("text-anchor","middle").text(t.title);window.label=d;let l=d.node().getBBox();e.insert("rect",":first-child").attr("class","box").attr("x",l.x-o.padding/2).attr("y",l.y-o.padding/2).attr("width",l.width+o.padding).attr("height",l.height+o.padding)}y.info("Rendering relation "+JSON.stringify(t)),t.relationTitle1!==void 0&&t.relationTitle1!=="none"&&i.append("g").attr("class","cardinality").append("text").attr("class","type1").attr("x",u).attr("y",m).attr("fill","black").attr("font-size","6").text(t.relationTitle1),t.relationTitle2!==void 0&&t.relationTitle2!=="none"&&i.append("g").attr("class","cardinality").append("text").attr("class","type2").attr("x",w).attr("y",k).attr("fill","black").attr("font-size","6").text(t.relationTitle2),X++},U=function(i,r,t,o){y.debug("Rendering class ",r,t);let p=r.id,g={id:p,label:r.id,width:0,height:0},s=i.append("g").attr("id",o.db.lookUpDomId(p)).attr("class","classGroup"),c;r.link?c=s.append("svg:a").attr("xlink:href",r.link).attr("target",r.linkTarget).append("text").attr("y",t.textHeight+t.padding).attr("x",0):c=s.append("text").attr("y",t.textHeight+t.padding).attr("x",0);let n=!0;r.annotations.forEach(function(d){let l=c.append("tspan").text("\xAB"+d+"\xBB");n||l.attr("dy",t.textHeight),n=!1});let a=$(r),f=c.append("tspan").text(a).attr("class","title");n||f.attr("dy",t.textHeight);let h=c.node().getBBox().height,x,b,u;if(r.members.length>0){x=s.append("line").attr("x1",0).attr("y1",t.padding+h+t.dividerMargin/2).attr("y2",t.padding+h+t.dividerMargin/2);let d=s.append("text").attr("x",t.padding).attr("y",h+t.dividerMargin+t.textHeight).attr("fill","white").attr("class","classText");n=!0,r.members.forEach(function(l){Y(d,l,n,t),n=!1}),b=d.node().getBBox()}if(r.methods.length>0){u=s.append("line").attr("x1",0).attr("y1",t.padding+h+t.dividerMargin+b.height).attr("y2",t.padding+h+t.dividerMargin+b.height);let d=s.append("text").attr("x",t.padding).attr("y",h+2*t.dividerMargin+b.height+t.textHeight).attr("fill","white").attr("class","classText");n=!0,r.methods.forEach(function(l){Y(d,l,n,t),n=!1})}let m=s.node().getBBox();var w=" ";r.cssClasses.length>0&&(w=w+r.cssClasses.join(" "));let e=s.insert("rect",":first-child").attr("x",0).attr("y",0).attr("width",m.width+2*t.padding).attr("height",m.height+t.padding+.5*t.dividerMargin).attr("class",w).node().getBBox().width;return c.node().childNodes.forEach(function(d){d.setAttribute("x",(e-d.getBBox().width)/2)}),r.tooltip&&c.insert("title").text(r.tooltip),x&&x.attr("x2",e),u&&u.attr("x2",e),g.width=e,g.height=m.height+t.padding+.5*t.dividerMargin,g},$=function(i){let r=i.id;return i.type&&(r+="<"+O(i.type)+">"),r},z=function(i,r,t,o){y.debug("Rendering note ",r,t);let p=r.id,g={id:p,text:r.text,width:0,height:0},s=i.append("g").attr("id",p).attr("class","classGroup"),c=s.append("text").attr("y",t.textHeight+t.padding).attr("x",0),n=JSON.parse(`"${r.text}"`).split(` +import{a as G,b as v,c as I}from"./chunk-NRFNOXYN.min.js";import{j as A,k as W}from"./chunk-NAH225X5.min.js";import{$a as P,G as _,Ga as y,I as C,J as R,Ka as O,Za as T,b as J,c as Z,h as E,jb as S}from"./chunk-JUXSCBYR.min.js";import{d as N}from"./chunk-P42HNYSU.min.js";var at=N(J(),1),it=N(Z(),1),nt=N(R(),1);var X=0,F=function(i,r,t,o,p){let g=function(e){switch(e){case p.db.relationType.AGGREGATION:return"aggregation";case p.db.relationType.EXTENSION:return"extension";case p.db.relationType.COMPOSITION:return"composition";case p.db.relationType.DEPENDENCY:return"dependency";case p.db.relationType.LOLLIPOP:return"lollipop"}};r.points=r.points.filter(e=>!Number.isNaN(e.y));let s=r.points,c=_().x(function(e){return e.x}).y(function(e){return e.y}).curve(C),n=i.append("path").attr("d",c(s)).attr("id","edge"+X).attr("class","relation"),a="";o.arrowMarkerAbsolute&&(a=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,a=a.replace(/\(/g,"\\("),a=a.replace(/\)/g,"\\)")),t.relation.lineType==1&&n.attr("class","relation dashed-line"),t.relation.lineType==10&&n.attr("class","relation dotted-line"),t.relation.type1!=="none"&&n.attr("marker-start","url("+a+"#"+g(t.relation.type1)+"Start)"),t.relation.type2!=="none"&&n.attr("marker-end","url("+a+"#"+g(t.relation.type2)+"End)");let f,h,x=r.points.length,b=T.calcLabelPosition(r.points);f=b.x,h=b.y;let u,m,w,k;if(x%2!==0&&x>1){let e=T.calcCardinalityPosition(t.relation.type1!=="none",r.points,r.points[0]),d=T.calcCardinalityPosition(t.relation.type2!=="none",r.points,r.points[x-1]);y.debug("cardinality_1_point "+JSON.stringify(e)),y.debug("cardinality_2_point "+JSON.stringify(d)),u=e.x,m=e.y,w=d.x,k=d.y}if(t.title!==void 0){let e=i.append("g").attr("class","classLabel"),d=e.append("text").attr("class","label").attr("x",f).attr("y",h).attr("fill","red").attr("text-anchor","middle").text(t.title);window.label=d;let l=d.node().getBBox();e.insert("rect",":first-child").attr("class","box").attr("x",l.x-o.padding/2).attr("y",l.y-o.padding/2).attr("width",l.width+o.padding).attr("height",l.height+o.padding)}y.info("Rendering relation "+JSON.stringify(t)),t.relationTitle1!==void 0&&t.relationTitle1!=="none"&&i.append("g").attr("class","cardinality").append("text").attr("class","type1").attr("x",u).attr("y",m).attr("fill","black").attr("font-size","6").text(t.relationTitle1),t.relationTitle2!==void 0&&t.relationTitle2!=="none"&&i.append("g").attr("class","cardinality").append("text").attr("class","type2").attr("x",w).attr("y",k).attr("fill","black").attr("font-size","6").text(t.relationTitle2),X++},U=function(i,r,t,o){y.debug("Rendering class ",r,t);let p=r.id,g={id:p,label:r.id,width:0,height:0},s=i.append("g").attr("id",o.db.lookUpDomId(p)).attr("class","classGroup"),c;r.link?c=s.append("svg:a").attr("xlink:href",r.link).attr("target",r.linkTarget).append("text").attr("y",t.textHeight+t.padding).attr("x",0):c=s.append("text").attr("y",t.textHeight+t.padding).attr("x",0);let n=!0;r.annotations.forEach(function(d){let l=c.append("tspan").text("\xAB"+d+"\xBB");n||l.attr("dy",t.textHeight),n=!1});let a=$(r),f=c.append("tspan").text(a).attr("class","title");n||f.attr("dy",t.textHeight);let h=c.node().getBBox().height,x,b,u;if(r.members.length>0){x=s.append("line").attr("x1",0).attr("y1",t.padding+h+t.dividerMargin/2).attr("y2",t.padding+h+t.dividerMargin/2);let d=s.append("text").attr("x",t.padding).attr("y",h+t.dividerMargin+t.textHeight).attr("fill","white").attr("class","classText");n=!0,r.members.forEach(function(l){Y(d,l,n,t),n=!1}),b=d.node().getBBox()}if(r.methods.length>0){u=s.append("line").attr("x1",0).attr("y1",t.padding+h+t.dividerMargin+b.height).attr("y2",t.padding+h+t.dividerMargin+b.height);let d=s.append("text").attr("x",t.padding).attr("y",h+2*t.dividerMargin+b.height+t.textHeight).attr("fill","white").attr("class","classText");n=!0,r.methods.forEach(function(l){Y(d,l,n,t),n=!1})}let m=s.node().getBBox();var w=" ";r.cssClasses.length>0&&(w=w+r.cssClasses.join(" "));let e=s.insert("rect",":first-child").attr("x",0).attr("y",0).attr("width",m.width+2*t.padding).attr("height",m.height+t.padding+.5*t.dividerMargin).attr("class",w).node().getBBox().width;return c.node().childNodes.forEach(function(d){d.setAttribute("x",(e-d.getBBox().width)/2)}),r.tooltip&&c.insert("title").text(r.tooltip),x&&x.attr("x2",e),u&&u.attr("x2",e),g.width=e,g.height=m.height+t.padding+.5*t.dividerMargin,g},$=function(i){let r=i.id;return i.type&&(r+="<"+O(i.type)+">"),r},z=function(i,r,t,o){y.debug("Rendering note ",r,t);let p=r.id,g={id:p,text:r.text,width:0,height:0},s=i.append("g").attr("id",p).attr("class","classGroup"),c=s.append("text").attr("y",t.textHeight+t.padding).attr("x",0),n=JSON.parse(`"${r.text}"`).split(` `);n.forEach(function(x){y.debug(`Adding line: ${x}`),c.append("tspan").text(x).attr("class","title").attr("dy",t.textHeight)});let a=s.node().getBBox(),h=s.insert("rect",":first-child").attr("x",0).attr("y",0).attr("width",a.width+2*t.padding).attr("height",a.height+n.length*t.textHeight+t.padding+.5*t.dividerMargin).node().getBBox().width;return c.node().childNodes.forEach(function(x){x.setAttribute("x",(h-x.getBBox().width)/2)}),g.width=h,g.height=a.height+n.length*t.textHeight+t.padding+.5*t.dividerMargin,g},Y=function(i,r,t,o){let{displayText:p,cssStyle:g}=r.getDisplayDetails(),s=i.append("tspan").attr("x",o.padding).text(p);g!==""&&s.attr("style",r.cssStyle),t||s.attr("dy",o.textHeight)},H={getClassTitleString:$,drawClass:U,drawEdge:F,drawNote:z},M={},B=20,L=function(i){let r=Object.entries(M).find(t=>t[1].label===i);if(r)return r[0]},V=function(i){i.append("defs").append("marker").attr("id","extensionStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),i.append("defs").append("marker").attr("id","extensionEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z"),i.append("defs").append("marker").attr("id","compositionStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),i.append("defs").append("marker").attr("id","compositionEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),i.append("defs").append("marker").attr("id","aggregationStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),i.append("defs").append("marker").attr("id","aggregationEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),i.append("defs").append("marker").attr("id","dependencyStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),i.append("defs").append("marker").attr("id","dependencyEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},q=function(i,r,t,o){let p=S().class;M={},y.info("Rendering diagram "+i);let g=S().securityLevel,s;g==="sandbox"&&(s=E("#i"+r));let c=g==="sandbox"?E(s.nodes()[0].contentDocument.body):E("body"),n=c.select(`[id='${r}']`);V(n);let a=new A({multigraph:!0});a.setGraph({isMultiGraph:!0}),a.setDefaultEdgeLabel(function(){return{}});let f=o.db.getClasses(),h=Object.keys(f);for(let e of h){let d=f[e],l=H.drawClass(n,d,p,o);M[l.id]=l,a.setNode(l.id,l),y.info("Org height: "+l.height)}o.db.getRelations().forEach(function(e){y.info("tjoho"+L(e.id1)+L(e.id2)+JSON.stringify(e)),a.setEdge(L(e.id1),L(e.id2),{relation:e},e.title||"DEFAULT")}),o.db.getNotes().forEach(function(e){y.debug(`Adding note: ${JSON.stringify(e)}`);let d=H.drawNote(n,e,p,o);M[d.id]=d,a.setNode(d.id,d),e.class&&e.class in f&&a.setEdge(e.id,L(e.class),{relation:{id1:e.id,id2:e.class,relation:{type1:"none",type2:"none",lineType:10}}},"DEFAULT")}),W(a),a.nodes().forEach(function(e){e!==void 0&&a.node(e)!==void 0&&(y.debug("Node "+e+": "+JSON.stringify(a.node(e))),c.select("#"+(o.db.lookUpDomId(e)||e)).attr("transform","translate("+(a.node(e).x-a.node(e).width/2)+","+(a.node(e).y-a.node(e).height/2)+" )"))}),a.edges().forEach(function(e){e!==void 0&&a.edge(e)!==void 0&&(y.debug("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(a.edge(e))),H.drawEdge(n,a.edge(e),a.edge(e).relation,p,o))});let u=n.node().getBBox(),m=u.width+B*2,w=u.height+B*2;P(n,w,m,p.useMaxWidth);let k=`${u.x-B} ${u.y-B} ${m} ${w}`;y.debug(`viewBox ${k}`),n.attr("viewBox",k)},K={draw:q},dt={parser:G,db:v,renderer:K,styles:I,init:i=>{i.class||(i.class={}),i.class.arrowMarkerAbsolute=i.arrowMarkerAbsolute,v.clear()}};export{dt as diagram}; -//# sourceMappingURL=classDiagram-936ed81e-YM34DHJU.min.js.map +//# sourceMappingURL=classDiagram-48ab76fb-DDANGYBP.min.js.map diff --git a/docs/public/classDiagram-936ed81e-YM34DHJU.min.js.map b/docs/public/classDiagram-48ab76fb-DDANGYBP.min.js.map similarity index 99% rename from docs/public/classDiagram-936ed81e-YM34DHJU.min.js.map rename to docs/public/classDiagram-48ab76fb-DDANGYBP.min.js.map index 70ab157d..ff2600c4 100644 --- a/docs/public/classDiagram-936ed81e-YM34DHJU.min.js.map +++ b/docs/public/classDiagram-48ab76fb-DDANGYBP.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/classDiagram-936ed81e.js"], - "sourcesContent": ["import { p as parser, d as db, s as styles } from \"./styles-3dcbcfbf.js\";\nimport { line, curveBasis, select } from \"d3\";\nimport { layout } from \"dagre-d3-es/src/dagre/index.js\";\nimport * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { u as utils, l as log, v as parseGenericTypes, c as getConfig, i as configureSvgSize } from \"./mermaid-8af3addd.js\";\nimport \"ts-dedent\";\nimport \"dayjs\";\nimport \"@braintree/sanitize-url\";\nimport \"dompurify\";\nimport \"khroma\";\nimport \"lodash-es/memoize.js\";\nimport \"lodash-es/merge.js\";\nimport \"stylis\";\nimport \"lodash-es/isEmpty.js\";\nlet edgeCount = 0;\nconst drawEdge = function(elem, path, relation, conf, diagObj) {\n const getRelationType = function(type) {\n switch (type) {\n case diagObj.db.relationType.AGGREGATION:\n return \"aggregation\";\n case diagObj.db.relationType.EXTENSION:\n return \"extension\";\n case diagObj.db.relationType.COMPOSITION:\n return \"composition\";\n case diagObj.db.relationType.DEPENDENCY:\n return \"dependency\";\n case diagObj.db.relationType.LOLLIPOP:\n return \"lollipop\";\n }\n };\n path.points = path.points.filter((p) => !Number.isNaN(p.y));\n const lineData = path.points;\n const lineFunction = line().x(function(d) {\n return d.x;\n }).y(function(d) {\n return d.y;\n }).curve(curveBasis);\n const svgPath = elem.append(\"path\").attr(\"d\", lineFunction(lineData)).attr(\"id\", \"edge\" + edgeCount).attr(\"class\", \"relation\");\n let url = \"\";\n if (conf.arrowMarkerAbsolute) {\n url = window.location.protocol + \"//\" + window.location.host + window.location.pathname + window.location.search;\n url = url.replace(/\\(/g, \"\\\\(\");\n url = url.replace(/\\)/g, \"\\\\)\");\n }\n if (relation.relation.lineType == 1) {\n svgPath.attr(\"class\", \"relation dashed-line\");\n }\n if (relation.relation.lineType == 10) {\n svgPath.attr(\"class\", \"relation dotted-line\");\n }\n if (relation.relation.type1 !== \"none\") {\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + getRelationType(relation.relation.type1) + \"Start)\"\n );\n }\n if (relation.relation.type2 !== \"none\") {\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + getRelationType(relation.relation.type2) + \"End)\"\n );\n }\n let x, y;\n const l = path.points.length;\n let labelPosition = utils.calcLabelPosition(path.points);\n x = labelPosition.x;\n y = labelPosition.y;\n let p1_card_x, p1_card_y;\n let p2_card_x, p2_card_y;\n if (l % 2 !== 0 && l > 1) {\n let cardinality_1_point = utils.calcCardinalityPosition(\n relation.relation.type1 !== \"none\",\n path.points,\n path.points[0]\n );\n let cardinality_2_point = utils.calcCardinalityPosition(\n relation.relation.type2 !== \"none\",\n path.points,\n path.points[l - 1]\n );\n log.debug(\"cardinality_1_point \" + JSON.stringify(cardinality_1_point));\n log.debug(\"cardinality_2_point \" + JSON.stringify(cardinality_2_point));\n p1_card_x = cardinality_1_point.x;\n p1_card_y = cardinality_1_point.y;\n p2_card_x = cardinality_2_point.x;\n p2_card_y = cardinality_2_point.y;\n }\n if (relation.title !== void 0) {\n const g = elem.append(\"g\").attr(\"class\", \"classLabel\");\n const label = g.append(\"text\").attr(\"class\", \"label\").attr(\"x\", x).attr(\"y\", y).attr(\"fill\", \"red\").attr(\"text-anchor\", \"middle\").text(relation.title);\n window.label = label;\n const bounds = label.node().getBBox();\n g.insert(\"rect\", \":first-child\").attr(\"class\", \"box\").attr(\"x\", bounds.x - conf.padding / 2).attr(\"y\", bounds.y - conf.padding / 2).attr(\"width\", bounds.width + conf.padding).attr(\"height\", bounds.height + conf.padding);\n }\n log.info(\"Rendering relation \" + JSON.stringify(relation));\n if (relation.relationTitle1 !== void 0 && relation.relationTitle1 !== \"none\") {\n const g = elem.append(\"g\").attr(\"class\", \"cardinality\");\n g.append(\"text\").attr(\"class\", \"type1\").attr(\"x\", p1_card_x).attr(\"y\", p1_card_y).attr(\"fill\", \"black\").attr(\"font-size\", \"6\").text(relation.relationTitle1);\n }\n if (relation.relationTitle2 !== void 0 && relation.relationTitle2 !== \"none\") {\n const g = elem.append(\"g\").attr(\"class\", \"cardinality\");\n g.append(\"text\").attr(\"class\", \"type2\").attr(\"x\", p2_card_x).attr(\"y\", p2_card_y).attr(\"fill\", \"black\").attr(\"font-size\", \"6\").text(relation.relationTitle2);\n }\n edgeCount++;\n};\nconst drawClass = function(elem, classDef, conf, diagObj) {\n log.debug(\"Rendering class \", classDef, conf);\n const id = classDef.id;\n const classInfo = {\n id,\n label: classDef.id,\n width: 0,\n height: 0\n };\n const g = elem.append(\"g\").attr(\"id\", diagObj.db.lookUpDomId(id)).attr(\"class\", \"classGroup\");\n let title;\n if (classDef.link) {\n title = g.append(\"svg:a\").attr(\"xlink:href\", classDef.link).attr(\"target\", classDef.linkTarget).append(\"text\").attr(\"y\", conf.textHeight + conf.padding).attr(\"x\", 0);\n } else {\n title = g.append(\"text\").attr(\"y\", conf.textHeight + conf.padding).attr(\"x\", 0);\n }\n let isFirst = true;\n classDef.annotations.forEach(function(member) {\n const titleText2 = title.append(\"tspan\").text(\"\u00AB\" + member + \"\u00BB\");\n if (!isFirst) {\n titleText2.attr(\"dy\", conf.textHeight);\n }\n isFirst = false;\n });\n let classTitleString = getClassTitleString(classDef);\n const classTitle = title.append(\"tspan\").text(classTitleString).attr(\"class\", \"title\");\n if (!isFirst) {\n classTitle.attr(\"dy\", conf.textHeight);\n }\n const titleHeight = title.node().getBBox().height;\n let membersLine;\n let membersBox;\n let methodsLine;\n if (classDef.members.length > 0) {\n membersLine = g.append(\"line\").attr(\"x1\", 0).attr(\"y1\", conf.padding + titleHeight + conf.dividerMargin / 2).attr(\"y2\", conf.padding + titleHeight + conf.dividerMargin / 2);\n const members = g.append(\"text\").attr(\"x\", conf.padding).attr(\"y\", titleHeight + conf.dividerMargin + conf.textHeight).attr(\"fill\", \"white\").attr(\"class\", \"classText\");\n isFirst = true;\n classDef.members.forEach(function(member) {\n addTspan(members, member, isFirst, conf);\n isFirst = false;\n });\n membersBox = members.node().getBBox();\n }\n if (classDef.methods.length > 0) {\n methodsLine = g.append(\"line\").attr(\"x1\", 0).attr(\"y1\", conf.padding + titleHeight + conf.dividerMargin + membersBox.height).attr(\"y2\", conf.padding + titleHeight + conf.dividerMargin + membersBox.height);\n const methods = g.append(\"text\").attr(\"x\", conf.padding).attr(\"y\", titleHeight + 2 * conf.dividerMargin + membersBox.height + conf.textHeight).attr(\"fill\", \"white\").attr(\"class\", \"classText\");\n isFirst = true;\n classDef.methods.forEach(function(method) {\n addTspan(methods, method, isFirst, conf);\n isFirst = false;\n });\n }\n const classBox = g.node().getBBox();\n var cssClassStr = \" \";\n if (classDef.cssClasses.length > 0) {\n cssClassStr = cssClassStr + classDef.cssClasses.join(\" \");\n }\n const rect = g.insert(\"rect\", \":first-child\").attr(\"x\", 0).attr(\"y\", 0).attr(\"width\", classBox.width + 2 * conf.padding).attr(\"height\", classBox.height + conf.padding + 0.5 * conf.dividerMargin).attr(\"class\", cssClassStr);\n const rectWidth = rect.node().getBBox().width;\n title.node().childNodes.forEach(function(x) {\n x.setAttribute(\"x\", (rectWidth - x.getBBox().width) / 2);\n });\n if (classDef.tooltip) {\n title.insert(\"title\").text(classDef.tooltip);\n }\n if (membersLine) {\n membersLine.attr(\"x2\", rectWidth);\n }\n if (methodsLine) {\n methodsLine.attr(\"x2\", rectWidth);\n }\n classInfo.width = rectWidth;\n classInfo.height = classBox.height + conf.padding + 0.5 * conf.dividerMargin;\n return classInfo;\n};\nconst getClassTitleString = function(classDef) {\n let classTitleString = classDef.id;\n if (classDef.type) {\n classTitleString += \"<\" + parseGenericTypes(classDef.type) + \">\";\n }\n return classTitleString;\n};\nconst drawNote = function(elem, note, conf, diagObj) {\n log.debug(\"Rendering note \", note, conf);\n const id = note.id;\n const noteInfo = {\n id,\n text: note.text,\n width: 0,\n height: 0\n };\n const g = elem.append(\"g\").attr(\"id\", id).attr(\"class\", \"classGroup\");\n let text = g.append(\"text\").attr(\"y\", conf.textHeight + conf.padding).attr(\"x\", 0);\n const lines = JSON.parse(`\"${note.text}\"`).split(\"\\n\");\n lines.forEach(function(line2) {\n log.debug(`Adding line: ${line2}`);\n text.append(\"tspan\").text(line2).attr(\"class\", \"title\").attr(\"dy\", conf.textHeight);\n });\n const noteBox = g.node().getBBox();\n const rect = g.insert(\"rect\", \":first-child\").attr(\"x\", 0).attr(\"y\", 0).attr(\"width\", noteBox.width + 2 * conf.padding).attr(\n \"height\",\n noteBox.height + lines.length * conf.textHeight + conf.padding + 0.5 * conf.dividerMargin\n );\n const rectWidth = rect.node().getBBox().width;\n text.node().childNodes.forEach(function(x) {\n x.setAttribute(\"x\", (rectWidth - x.getBBox().width) / 2);\n });\n noteInfo.width = rectWidth;\n noteInfo.height = noteBox.height + lines.length * conf.textHeight + conf.padding + 0.5 * conf.dividerMargin;\n return noteInfo;\n};\nconst addTspan = function(textEl, member, isFirst, conf) {\n const { displayText, cssStyle } = member.getDisplayDetails();\n const tSpan = textEl.append(\"tspan\").attr(\"x\", conf.padding).text(displayText);\n if (cssStyle !== \"\") {\n tSpan.attr(\"style\", member.cssStyle);\n }\n if (!isFirst) {\n tSpan.attr(\"dy\", conf.textHeight);\n }\n};\nconst svgDraw = {\n getClassTitleString,\n drawClass,\n drawEdge,\n drawNote\n};\nlet idCache = {};\nconst padding = 20;\nconst getGraphId = function(label) {\n const foundEntry = Object.entries(idCache).find((entry) => entry[1].label === label);\n if (foundEntry) {\n return foundEntry[0];\n }\n};\nconst insertMarkers = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"extensionStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,7 L18,13 V 1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"extensionEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 V 13 L18,7 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"compositionStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"compositionEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"aggregationStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"aggregationEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"dependencyStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 5,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"dependencyEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L14,7 L9,1 Z\");\n};\nconst draw = function(text, id, _version, diagObj) {\n const conf = getConfig().class;\n idCache = {};\n log.info(\"Rendering diagram \" + text);\n const securityLevel = getConfig().securityLevel;\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n const diagram2 = root.select(`[id='${id}']`);\n insertMarkers(diagram2);\n const g = new graphlib.Graph({\n multigraph: true\n });\n g.setGraph({\n isMultiGraph: true\n });\n g.setDefaultEdgeLabel(function() {\n return {};\n });\n const classes = diagObj.db.getClasses();\n const keys = Object.keys(classes);\n for (const key of keys) {\n const classDef = classes[key];\n const node = svgDraw.drawClass(diagram2, classDef, conf, diagObj);\n idCache[node.id] = node;\n g.setNode(node.id, node);\n log.info(\"Org height: \" + node.height);\n }\n const relations = diagObj.db.getRelations();\n relations.forEach(function(relation) {\n log.info(\n \"tjoho\" + getGraphId(relation.id1) + getGraphId(relation.id2) + JSON.stringify(relation)\n );\n g.setEdge(\n getGraphId(relation.id1),\n getGraphId(relation.id2),\n {\n relation\n },\n relation.title || \"DEFAULT\"\n );\n });\n const notes = diagObj.db.getNotes();\n notes.forEach(function(note) {\n log.debug(`Adding note: ${JSON.stringify(note)}`);\n const node = svgDraw.drawNote(diagram2, note, conf, diagObj);\n idCache[node.id] = node;\n g.setNode(node.id, node);\n if (note.class && note.class in classes) {\n g.setEdge(\n note.id,\n getGraphId(note.class),\n {\n relation: {\n id1: note.id,\n id2: note.class,\n relation: {\n type1: \"none\",\n type2: \"none\",\n lineType: 10\n }\n }\n },\n \"DEFAULT\"\n );\n }\n });\n layout(g);\n g.nodes().forEach(function(v) {\n if (v !== void 0 && g.node(v) !== void 0) {\n log.debug(\"Node \" + v + \": \" + JSON.stringify(g.node(v)));\n root.select(\"#\" + (diagObj.db.lookUpDomId(v) || v)).attr(\n \"transform\",\n \"translate(\" + (g.node(v).x - g.node(v).width / 2) + \",\" + (g.node(v).y - g.node(v).height / 2) + \" )\"\n );\n }\n });\n g.edges().forEach(function(e) {\n if (e !== void 0 && g.edge(e) !== void 0) {\n log.debug(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(g.edge(e)));\n svgDraw.drawEdge(diagram2, g.edge(e), g.edge(e).relation, conf, diagObj);\n }\n });\n const svgBounds = diagram2.node().getBBox();\n const width = svgBounds.width + padding * 2;\n const height = svgBounds.height + padding * 2;\n configureSvgSize(diagram2, height, width, conf.useMaxWidth);\n const vBox = `${svgBounds.x - padding} ${svgBounds.y - padding} ${width} ${height}`;\n log.debug(`viewBox ${vBox}`);\n diagram2.attr(\"viewBox\", vBox);\n};\nconst renderer = {\n draw\n};\nconst diagram = {\n parser,\n db,\n renderer,\n styles,\n init: (cnf) => {\n if (!cnf.class) {\n cnf.class = {};\n }\n cnf.class.arrowMarkerAbsolute = cnf.arrowMarkerAbsolute;\n db.clear();\n }\n};\nexport {\n diagram\n};\n"], + "sources": ["../../node_modules/mermaid/dist/classDiagram-48ab76fb.js"], + "sourcesContent": ["import { p as parser, d as db, s as styles } from \"./styles-4ba6ed67.js\";\nimport { line, curveBasis, select } from \"d3\";\nimport { layout } from \"dagre-d3-es/src/dagre/index.js\";\nimport * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { u as utils, l as log, v as parseGenericTypes, c as getConfig, i as configureSvgSize } from \"./mermaid-934d9bea.js\";\nimport \"ts-dedent\";\nimport \"dayjs\";\nimport \"@braintree/sanitize-url\";\nimport \"dompurify\";\nimport \"khroma\";\nimport \"lodash-es/memoize.js\";\nimport \"lodash-es/merge.js\";\nimport \"stylis\";\nimport \"lodash-es/isEmpty.js\";\nlet edgeCount = 0;\nconst drawEdge = function(elem, path, relation, conf, diagObj) {\n const getRelationType = function(type) {\n switch (type) {\n case diagObj.db.relationType.AGGREGATION:\n return \"aggregation\";\n case diagObj.db.relationType.EXTENSION:\n return \"extension\";\n case diagObj.db.relationType.COMPOSITION:\n return \"composition\";\n case diagObj.db.relationType.DEPENDENCY:\n return \"dependency\";\n case diagObj.db.relationType.LOLLIPOP:\n return \"lollipop\";\n }\n };\n path.points = path.points.filter((p) => !Number.isNaN(p.y));\n const lineData = path.points;\n const lineFunction = line().x(function(d) {\n return d.x;\n }).y(function(d) {\n return d.y;\n }).curve(curveBasis);\n const svgPath = elem.append(\"path\").attr(\"d\", lineFunction(lineData)).attr(\"id\", \"edge\" + edgeCount).attr(\"class\", \"relation\");\n let url = \"\";\n if (conf.arrowMarkerAbsolute) {\n url = window.location.protocol + \"//\" + window.location.host + window.location.pathname + window.location.search;\n url = url.replace(/\\(/g, \"\\\\(\");\n url = url.replace(/\\)/g, \"\\\\)\");\n }\n if (relation.relation.lineType == 1) {\n svgPath.attr(\"class\", \"relation dashed-line\");\n }\n if (relation.relation.lineType == 10) {\n svgPath.attr(\"class\", \"relation dotted-line\");\n }\n if (relation.relation.type1 !== \"none\") {\n svgPath.attr(\n \"marker-start\",\n \"url(\" + url + \"#\" + getRelationType(relation.relation.type1) + \"Start)\"\n );\n }\n if (relation.relation.type2 !== \"none\") {\n svgPath.attr(\n \"marker-end\",\n \"url(\" + url + \"#\" + getRelationType(relation.relation.type2) + \"End)\"\n );\n }\n let x, y;\n const l = path.points.length;\n let labelPosition = utils.calcLabelPosition(path.points);\n x = labelPosition.x;\n y = labelPosition.y;\n let p1_card_x, p1_card_y;\n let p2_card_x, p2_card_y;\n if (l % 2 !== 0 && l > 1) {\n let cardinality_1_point = utils.calcCardinalityPosition(\n relation.relation.type1 !== \"none\",\n path.points,\n path.points[0]\n );\n let cardinality_2_point = utils.calcCardinalityPosition(\n relation.relation.type2 !== \"none\",\n path.points,\n path.points[l - 1]\n );\n log.debug(\"cardinality_1_point \" + JSON.stringify(cardinality_1_point));\n log.debug(\"cardinality_2_point \" + JSON.stringify(cardinality_2_point));\n p1_card_x = cardinality_1_point.x;\n p1_card_y = cardinality_1_point.y;\n p2_card_x = cardinality_2_point.x;\n p2_card_y = cardinality_2_point.y;\n }\n if (relation.title !== void 0) {\n const g = elem.append(\"g\").attr(\"class\", \"classLabel\");\n const label = g.append(\"text\").attr(\"class\", \"label\").attr(\"x\", x).attr(\"y\", y).attr(\"fill\", \"red\").attr(\"text-anchor\", \"middle\").text(relation.title);\n window.label = label;\n const bounds = label.node().getBBox();\n g.insert(\"rect\", \":first-child\").attr(\"class\", \"box\").attr(\"x\", bounds.x - conf.padding / 2).attr(\"y\", bounds.y - conf.padding / 2).attr(\"width\", bounds.width + conf.padding).attr(\"height\", bounds.height + conf.padding);\n }\n log.info(\"Rendering relation \" + JSON.stringify(relation));\n if (relation.relationTitle1 !== void 0 && relation.relationTitle1 !== \"none\") {\n const g = elem.append(\"g\").attr(\"class\", \"cardinality\");\n g.append(\"text\").attr(\"class\", \"type1\").attr(\"x\", p1_card_x).attr(\"y\", p1_card_y).attr(\"fill\", \"black\").attr(\"font-size\", \"6\").text(relation.relationTitle1);\n }\n if (relation.relationTitle2 !== void 0 && relation.relationTitle2 !== \"none\") {\n const g = elem.append(\"g\").attr(\"class\", \"cardinality\");\n g.append(\"text\").attr(\"class\", \"type2\").attr(\"x\", p2_card_x).attr(\"y\", p2_card_y).attr(\"fill\", \"black\").attr(\"font-size\", \"6\").text(relation.relationTitle2);\n }\n edgeCount++;\n};\nconst drawClass = function(elem, classDef, conf, diagObj) {\n log.debug(\"Rendering class \", classDef, conf);\n const id = classDef.id;\n const classInfo = {\n id,\n label: classDef.id,\n width: 0,\n height: 0\n };\n const g = elem.append(\"g\").attr(\"id\", diagObj.db.lookUpDomId(id)).attr(\"class\", \"classGroup\");\n let title;\n if (classDef.link) {\n title = g.append(\"svg:a\").attr(\"xlink:href\", classDef.link).attr(\"target\", classDef.linkTarget).append(\"text\").attr(\"y\", conf.textHeight + conf.padding).attr(\"x\", 0);\n } else {\n title = g.append(\"text\").attr(\"y\", conf.textHeight + conf.padding).attr(\"x\", 0);\n }\n let isFirst = true;\n classDef.annotations.forEach(function(member) {\n const titleText2 = title.append(\"tspan\").text(\"\u00AB\" + member + \"\u00BB\");\n if (!isFirst) {\n titleText2.attr(\"dy\", conf.textHeight);\n }\n isFirst = false;\n });\n let classTitleString = getClassTitleString(classDef);\n const classTitle = title.append(\"tspan\").text(classTitleString).attr(\"class\", \"title\");\n if (!isFirst) {\n classTitle.attr(\"dy\", conf.textHeight);\n }\n const titleHeight = title.node().getBBox().height;\n let membersLine;\n let membersBox;\n let methodsLine;\n if (classDef.members.length > 0) {\n membersLine = g.append(\"line\").attr(\"x1\", 0).attr(\"y1\", conf.padding + titleHeight + conf.dividerMargin / 2).attr(\"y2\", conf.padding + titleHeight + conf.dividerMargin / 2);\n const members = g.append(\"text\").attr(\"x\", conf.padding).attr(\"y\", titleHeight + conf.dividerMargin + conf.textHeight).attr(\"fill\", \"white\").attr(\"class\", \"classText\");\n isFirst = true;\n classDef.members.forEach(function(member) {\n addTspan(members, member, isFirst, conf);\n isFirst = false;\n });\n membersBox = members.node().getBBox();\n }\n if (classDef.methods.length > 0) {\n methodsLine = g.append(\"line\").attr(\"x1\", 0).attr(\"y1\", conf.padding + titleHeight + conf.dividerMargin + membersBox.height).attr(\"y2\", conf.padding + titleHeight + conf.dividerMargin + membersBox.height);\n const methods = g.append(\"text\").attr(\"x\", conf.padding).attr(\"y\", titleHeight + 2 * conf.dividerMargin + membersBox.height + conf.textHeight).attr(\"fill\", \"white\").attr(\"class\", \"classText\");\n isFirst = true;\n classDef.methods.forEach(function(method) {\n addTspan(methods, method, isFirst, conf);\n isFirst = false;\n });\n }\n const classBox = g.node().getBBox();\n var cssClassStr = \" \";\n if (classDef.cssClasses.length > 0) {\n cssClassStr = cssClassStr + classDef.cssClasses.join(\" \");\n }\n const rect = g.insert(\"rect\", \":first-child\").attr(\"x\", 0).attr(\"y\", 0).attr(\"width\", classBox.width + 2 * conf.padding).attr(\"height\", classBox.height + conf.padding + 0.5 * conf.dividerMargin).attr(\"class\", cssClassStr);\n const rectWidth = rect.node().getBBox().width;\n title.node().childNodes.forEach(function(x) {\n x.setAttribute(\"x\", (rectWidth - x.getBBox().width) / 2);\n });\n if (classDef.tooltip) {\n title.insert(\"title\").text(classDef.tooltip);\n }\n if (membersLine) {\n membersLine.attr(\"x2\", rectWidth);\n }\n if (methodsLine) {\n methodsLine.attr(\"x2\", rectWidth);\n }\n classInfo.width = rectWidth;\n classInfo.height = classBox.height + conf.padding + 0.5 * conf.dividerMargin;\n return classInfo;\n};\nconst getClassTitleString = function(classDef) {\n let classTitleString = classDef.id;\n if (classDef.type) {\n classTitleString += \"<\" + parseGenericTypes(classDef.type) + \">\";\n }\n return classTitleString;\n};\nconst drawNote = function(elem, note, conf, diagObj) {\n log.debug(\"Rendering note \", note, conf);\n const id = note.id;\n const noteInfo = {\n id,\n text: note.text,\n width: 0,\n height: 0\n };\n const g = elem.append(\"g\").attr(\"id\", id).attr(\"class\", \"classGroup\");\n let text = g.append(\"text\").attr(\"y\", conf.textHeight + conf.padding).attr(\"x\", 0);\n const lines = JSON.parse(`\"${note.text}\"`).split(\"\\n\");\n lines.forEach(function(line2) {\n log.debug(`Adding line: ${line2}`);\n text.append(\"tspan\").text(line2).attr(\"class\", \"title\").attr(\"dy\", conf.textHeight);\n });\n const noteBox = g.node().getBBox();\n const rect = g.insert(\"rect\", \":first-child\").attr(\"x\", 0).attr(\"y\", 0).attr(\"width\", noteBox.width + 2 * conf.padding).attr(\n \"height\",\n noteBox.height + lines.length * conf.textHeight + conf.padding + 0.5 * conf.dividerMargin\n );\n const rectWidth = rect.node().getBBox().width;\n text.node().childNodes.forEach(function(x) {\n x.setAttribute(\"x\", (rectWidth - x.getBBox().width) / 2);\n });\n noteInfo.width = rectWidth;\n noteInfo.height = noteBox.height + lines.length * conf.textHeight + conf.padding + 0.5 * conf.dividerMargin;\n return noteInfo;\n};\nconst addTspan = function(textEl, member, isFirst, conf) {\n const { displayText, cssStyle } = member.getDisplayDetails();\n const tSpan = textEl.append(\"tspan\").attr(\"x\", conf.padding).text(displayText);\n if (cssStyle !== \"\") {\n tSpan.attr(\"style\", member.cssStyle);\n }\n if (!isFirst) {\n tSpan.attr(\"dy\", conf.textHeight);\n }\n};\nconst svgDraw = {\n getClassTitleString,\n drawClass,\n drawEdge,\n drawNote\n};\nlet idCache = {};\nconst padding = 20;\nconst getGraphId = function(label) {\n const foundEntry = Object.entries(idCache).find((entry) => entry[1].label === label);\n if (foundEntry) {\n return foundEntry[0];\n }\n};\nconst insertMarkers = function(elem) {\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"extensionStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,7 L18,13 V 1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"extensionEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 1,1 V 13 L18,7 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"compositionStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"compositionEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"aggregationStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"aggregationEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"dependencyStart\").attr(\"class\", \"extension\").attr(\"refX\", 0).attr(\"refY\", 7).attr(\"markerWidth\", 190).attr(\"markerHeight\", 240).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 5,7 L9,13 L1,7 L9,1 Z\");\n elem.append(\"defs\").append(\"marker\").attr(\"id\", \"dependencyEnd\").attr(\"refX\", 19).attr(\"refY\", 7).attr(\"markerWidth\", 20).attr(\"markerHeight\", 28).attr(\"orient\", \"auto\").append(\"path\").attr(\"d\", \"M 18,7 L9,13 L14,7 L9,1 Z\");\n};\nconst draw = function(text, id, _version, diagObj) {\n const conf = getConfig().class;\n idCache = {};\n log.info(\"Rendering diagram \" + text);\n const securityLevel = getConfig().securityLevel;\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n const diagram2 = root.select(`[id='${id}']`);\n insertMarkers(diagram2);\n const g = new graphlib.Graph({\n multigraph: true\n });\n g.setGraph({\n isMultiGraph: true\n });\n g.setDefaultEdgeLabel(function() {\n return {};\n });\n const classes = diagObj.db.getClasses();\n const keys = Object.keys(classes);\n for (const key of keys) {\n const classDef = classes[key];\n const node = svgDraw.drawClass(diagram2, classDef, conf, diagObj);\n idCache[node.id] = node;\n g.setNode(node.id, node);\n log.info(\"Org height: \" + node.height);\n }\n const relations = diagObj.db.getRelations();\n relations.forEach(function(relation) {\n log.info(\n \"tjoho\" + getGraphId(relation.id1) + getGraphId(relation.id2) + JSON.stringify(relation)\n );\n g.setEdge(\n getGraphId(relation.id1),\n getGraphId(relation.id2),\n {\n relation\n },\n relation.title || \"DEFAULT\"\n );\n });\n const notes = diagObj.db.getNotes();\n notes.forEach(function(note) {\n log.debug(`Adding note: ${JSON.stringify(note)}`);\n const node = svgDraw.drawNote(diagram2, note, conf, diagObj);\n idCache[node.id] = node;\n g.setNode(node.id, node);\n if (note.class && note.class in classes) {\n g.setEdge(\n note.id,\n getGraphId(note.class),\n {\n relation: {\n id1: note.id,\n id2: note.class,\n relation: {\n type1: \"none\",\n type2: \"none\",\n lineType: 10\n }\n }\n },\n \"DEFAULT\"\n );\n }\n });\n layout(g);\n g.nodes().forEach(function(v) {\n if (v !== void 0 && g.node(v) !== void 0) {\n log.debug(\"Node \" + v + \": \" + JSON.stringify(g.node(v)));\n root.select(\"#\" + (diagObj.db.lookUpDomId(v) || v)).attr(\n \"transform\",\n \"translate(\" + (g.node(v).x - g.node(v).width / 2) + \",\" + (g.node(v).y - g.node(v).height / 2) + \" )\"\n );\n }\n });\n g.edges().forEach(function(e) {\n if (e !== void 0 && g.edge(e) !== void 0) {\n log.debug(\"Edge \" + e.v + \" -> \" + e.w + \": \" + JSON.stringify(g.edge(e)));\n svgDraw.drawEdge(diagram2, g.edge(e), g.edge(e).relation, conf, diagObj);\n }\n });\n const svgBounds = diagram2.node().getBBox();\n const width = svgBounds.width + padding * 2;\n const height = svgBounds.height + padding * 2;\n configureSvgSize(diagram2, height, width, conf.useMaxWidth);\n const vBox = `${svgBounds.x - padding} ${svgBounds.y - padding} ${width} ${height}`;\n log.debug(`viewBox ${vBox}`);\n diagram2.attr(\"viewBox\", vBox);\n};\nconst renderer = {\n draw\n};\nconst diagram = {\n parser,\n db,\n renderer,\n styles,\n init: (cnf) => {\n if (!cnf.class) {\n cnf.class = {};\n }\n cnf.class.arrowMarkerAbsolute = cnf.arrowMarkerAbsolute;\n db.clear();\n }\n};\nexport {\n diagram\n};\n"], "mappings": "gRAMA,IAAAA,GAAO,SACPC,GAAO,SACPC,GAAO,SAMP,IAAIC,EAAY,EACVC,EAAW,SAASC,EAAMC,EAAMC,EAAUC,EAAMC,EAAS,CAC7D,IAAMC,EAAkB,SAASC,EAAM,CACrC,OAAQA,EAAM,CACZ,KAAKF,EAAQ,GAAG,aAAa,YAC3B,MAAO,cACT,KAAKA,EAAQ,GAAG,aAAa,UAC3B,MAAO,YACT,KAAKA,EAAQ,GAAG,aAAa,YAC3B,MAAO,cACT,KAAKA,EAAQ,GAAG,aAAa,WAC3B,MAAO,aACT,KAAKA,EAAQ,GAAG,aAAa,SAC3B,MAAO,UACX,CACF,EACAH,EAAK,OAASA,EAAK,OAAO,OAAQM,GAAM,CAAC,OAAO,MAAMA,EAAE,CAAC,CAAC,EAC1D,IAAMC,EAAWP,EAAK,OAChBQ,EAAeC,EAAK,EAAE,EAAE,SAASC,EAAG,CACxC,OAAOA,EAAE,CACX,CAAC,EAAE,EAAE,SAASA,EAAG,CACf,OAAOA,EAAE,CACX,CAAC,EAAE,MAAMC,CAAU,EACbC,EAAUb,EAAK,OAAO,MAAM,EAAE,KAAK,IAAKS,EAAaD,CAAQ,CAAC,EAAE,KAAK,KAAM,OAASV,CAAS,EAAE,KAAK,QAAS,UAAU,EACzHgB,EAAM,GACNX,EAAK,sBACPW,EAAM,OAAO,SAAS,SAAW,KAAO,OAAO,SAAS,KAAO,OAAO,SAAS,SAAW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AO,KAAOzE,EAAQ,GAAG,YAAYiF,CAAC,GAAKA,EAAE,EAAE,KAClD,YACA,cAAgB1D,EAAE,KAAK0D,CAAC,EAAE,EAAI1D,EAAE,KAAK0D,CAAC,EAAE,MAAQ,GAAK,KAAO1D,EAAE,KAAK0D,CAAC,EAAE,EAAI1D,EAAE,KAAK0D,CAAC,EAAE,OAAS,GAAK,IACpG,EAEJ,CAAC,EACD1D,EAAE,MAAM,EAAE,QAAQ,SAAS,EAAG,CACxB,IAAM,QAAUA,EAAE,KAAK,CAAC,IAAM,SAChCD,EAAI,MAAM,QAAU,EAAE,EAAI,OAAS,EAAE,EAAI,KAAO,KAAK,UAAUC,EAAE,KAAK,CAAC,CAAC,CAAC,EACzEqC,EAAQ,SAASc,EAAUnD,EAAE,KAAK,CAAC,EAAGA,EAAE,KAAK,CAAC,EAAE,SAAUxB,EAAMC,CAAO,EAE3E,CAAC,EACD,IAAMkF,EAAYR,EAAS,KAAK,EAAE,QAAQ,EACpCS,EAAQD,EAAU,MAAQpB,EAAU,EACpCsB,EAASF,EAAU,OAASpB,EAAU,EAC5CuB,EAAiBX,EAAUU,EAAQD,EAAOpF,EAAK,WAAW,EAC1D,IAAMuF,EAAO,GAAGJ,EAAU,EAAIpB,CAAO,IAAIoB,EAAU,EAAIpB,CAAO,IAAIqB,CAAK,IAAIC,CAAM,GACjF9D,EAAI,MAAM,WAAWgE,CAAI,EAAE,EAC3BZ,EAAS,KAAK,UAAWY,CAAI,CAC/B,EACMC,EAAW,CACf,KAAApB,CACF,EACMqB,GAAU,CACd,OAAAC,EACA,GAAAC,EACA,SAAAH,EACA,OAAAI,EACA,KAAOC,GAAQ,CACRA,EAAI,QACPA,EAAI,MAAQ,CAAC,GAEfA,EAAI,MAAM,oBAAsBA,EAAI,oBACpCF,EAAG,MAAM,CACX,CACF", "names": ["import_dayjs", "import_sanitize_url", "import_dompurify", "edgeCount", "drawEdge", "elem", "path", "relation", "conf", "diagObj", "getRelationType", "type", "p", "lineData", "lineFunction", "line_default", "d", "basis_default", "svgPath", "url", "x", "y", "l", "labelPosition", "utils", "p1_card_x", "p1_card_y", "p2_card_x", "p2_card_y", "cardinality_1_point", "cardinality_2_point", "log$1", "g", "label", "bounds", "drawClass", "classDef", "id", "classInfo", "title", "isFirst", "member", "titleText2", "classTitleString", "getClassTitleString", "classTitle", "titleHeight", "membersLine", "membersBox", "methodsLine", "members", "addTspan", "methods", "method", "classBox", "cssClassStr", "rectWidth", "parseGenericTypes", "drawNote", "note", "noteInfo", "text", "lines", "line2", "noteBox", "textEl", "displayText", "cssStyle", "tSpan", "svgDraw", "idCache", "padding", "getGraphId", "foundEntry", "entry", "insertMarkers", "draw", "_version", "getConfig", "securityLevel", "sandboxElement", "select_default", "root", "diagram2", "Graph", "classes", "keys", "key", "node", "layout", "v", "svgBounds", "width", "height", "configureSvgSize", "vBox", "renderer", "diagram", "parser$1", "db", "styles", "cnf"] } diff --git a/docs/public/classDiagram-v2-c3cb15f1-KNJLQSSI.min.js b/docs/public/classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js similarity index 92% rename from docs/public/classDiagram-v2-c3cb15f1-KNJLQSSI.min.js rename to docs/public/classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js index 6383bb36..a6cd50b4 100644 --- a/docs/public/classDiagram-v2-c3cb15f1-KNJLQSSI.min.js +++ b/docs/public/classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js @@ -1,3 +1,3 @@ -import{a as M,b as T,c as R}from"./chunk-F3IAZVFZ.min.js";import{a as I}from"./chunk-2DSXJIGN.min.js";import"./chunk-ESYVBUIP.min.js";import"./chunk-TYUXPGKI.min.js";import{j as A}from"./chunk-3BJWU2V2.min.js";import{F as S,Ga as d,J as V,La as L,Qa as N,Ra as B,Za as G,ab as z,b as F,c as H,h as g,jb as i}from"./chunk-65WDIALL.min.js";import{d as k}from"./chunk-P42HNYSU.min.js";var ot=k(F(),1),lt=k(H(),1),nt=k(V(),1);var E=n=>L.sanitizeText(n,i()),D={dividerMargin:10,padding:5,textHeight:10,curve:void 0},W=function(n,e,y,s){let t=Object.keys(n);d.info("keys:",t),d.info(n),t.forEach(function(r){var o,c;let l=n[r],p={shape:"rect",id:l.id,domId:l.domId,labelText:E(l.id),labelStyle:"",style:"fill: none; stroke: black",padding:((o=i().flowchart)==null?void 0:o.padding)??((c=i().class)==null?void 0:c.padding)};e.setNode(l.id,p),$(l.classes,e,y,s,l.id),d.info("setNode",p)})},$=function(n,e,y,s,t){let r=Object.keys(n);d.info("keys:",r),d.info(n),r.filter(o=>n[o].parent==t).forEach(function(o){var c,l;let a=n[o],p=a.cssClasses.join(" "),f={labelStyle:"",style:""},h=a.label??a.id,b=0,m="class_box",u={labelStyle:f.labelStyle,shape:m,labelText:E(h),classData:a,rx:b,ry:b,class:p,style:f.style,id:a.id,domId:a.domId,tooltip:s.db.getTooltip(a.id,t)||"",haveCallback:a.haveCallback,link:a.link,width:a.type==="group"?500:void 0,type:a.type,padding:((c=i().flowchart)==null?void 0:c.padding)??((l=i().class)==null?void 0:l.padding)};e.setNode(a.id,u),t&&e.setParent(a.id,t),d.info("setNode",u)})},J=function(n,e,y,s){d.info(n),n.forEach(function(t,r){var o,c;let l=t,a="",p={labelStyle:"",style:""},f=l.text,h=0,b="note",m={labelStyle:p.labelStyle,shape:b,labelText:E(f),noteData:l,rx:h,ry:h,class:a,style:p.style,id:l.id,domId:l.id,tooltip:"",type:"note",padding:((o=i().flowchart)==null?void 0:o.padding)??((c=i().class)==null?void 0:c.padding)};if(e.setNode(l.id,m),d.info("setNode",m),!l.class||!(l.class in s))return;let u=y+r,x={id:`edgeNote${u}`,classes:"relation",pattern:"dotted",arrowhead:"none",startLabelRight:"",endLabelLeft:"",arrowTypeStart:"none",arrowTypeEnd:"none",style:"fill:none",labelStyle:"",curve:N(D.curve,S)};e.setEdge(l.id,l.class,x,u)})},K=function(n,e){let y=i().flowchart,s=0;n.forEach(function(t){var r;s++;let o={classes:"relation",pattern:t.relation.lineType==1?"dashed":"solid",id:"id"+s,arrowhead:t.type==="arrow_open"?"none":"normal",startLabelRight:t.relationTitle1==="none"?"":t.relationTitle1,endLabelLeft:t.relationTitle2==="none"?"":t.relationTitle2,arrowTypeStart:P(t.relation.type1),arrowTypeEnd:P(t.relation.type2),style:"fill:none",labelStyle:"",curve:N(y?.curve,S)};if(d.info(o,t),t.style!==void 0){let c=B(t.style);o.style=c.style,o.labelStyle=c.labelStyle}t.text=t.title,t.text===void 0?t.style!==void 0&&(o.arrowheadStyle="fill: #333"):(o.arrowheadStyle="fill: #333",o.labelpos="c",((r=i().flowchart)==null?void 0:r.htmlLabels)??i().htmlLabels?(o.labelType="html",o.label=''+t.text+""):(o.labelType="text",o.label=t.text.replace(L.lineBreakRegex,` +import{a as M,b as T,c as R}from"./chunk-NRFNOXYN.min.js";import{a as I}from"./chunk-VHIEHVUL.min.js";import"./chunk-NV7BXRXJ.min.js";import"./chunk-ZMRDHQ6H.min.js";import{j as A}from"./chunk-NAH225X5.min.js";import{F as S,Ga as d,J as V,La as L,Qa as N,Ra as B,Za as G,ab as z,b as F,c as H,h as g,jb as i}from"./chunk-JUXSCBYR.min.js";import{d as k}from"./chunk-P42HNYSU.min.js";var ot=k(F(),1),lt=k(H(),1),nt=k(V(),1);var E=n=>L.sanitizeText(n,i()),D={dividerMargin:10,padding:5,textHeight:10,curve:void 0},W=function(n,e,y,s){let t=Object.keys(n);d.info("keys:",t),d.info(n),t.forEach(function(r){var o,c;let l=n[r],p={shape:"rect",id:l.id,domId:l.domId,labelText:E(l.id),labelStyle:"",style:"fill: none; stroke: black",padding:((o=i().flowchart)==null?void 0:o.padding)??((c=i().class)==null?void 0:c.padding)};e.setNode(l.id,p),$(l.classes,e,y,s,l.id),d.info("setNode",p)})},$=function(n,e,y,s,t){let r=Object.keys(n);d.info("keys:",r),d.info(n),r.filter(o=>n[o].parent==t).forEach(function(o){var c,l;let a=n[o],p=a.cssClasses.join(" "),f={labelStyle:"",style:""},h=a.label??a.id,b=0,m="class_box",u={labelStyle:f.labelStyle,shape:m,labelText:E(h),classData:a,rx:b,ry:b,class:p,style:f.style,id:a.id,domId:a.domId,tooltip:s.db.getTooltip(a.id,t)||"",haveCallback:a.haveCallback,link:a.link,width:a.type==="group"?500:void 0,type:a.type,padding:((c=i().flowchart)==null?void 0:c.padding)??((l=i().class)==null?void 0:l.padding)};e.setNode(a.id,u),t&&e.setParent(a.id,t),d.info("setNode",u)})},J=function(n,e,y,s){d.info(n),n.forEach(function(t,r){var o,c;let l=t,a="",p={labelStyle:"",style:""},f=l.text,h=0,b="note",m={labelStyle:p.labelStyle,shape:b,labelText:E(f),noteData:l,rx:h,ry:h,class:a,style:p.style,id:l.id,domId:l.id,tooltip:"",type:"note",padding:((o=i().flowchart)==null?void 0:o.padding)??((c=i().class)==null?void 0:c.padding)};if(e.setNode(l.id,m),d.info("setNode",m),!l.class||!(l.class in s))return;let u=y+r,x={id:`edgeNote${u}`,classes:"relation",pattern:"dotted",arrowhead:"none",startLabelRight:"",endLabelLeft:"",arrowTypeStart:"none",arrowTypeEnd:"none",style:"fill:none",labelStyle:"",curve:N(D.curve,S)};e.setEdge(l.id,l.class,x,u)})},K=function(n,e){let y=i().flowchart,s=0;n.forEach(function(t){var r;s++;let o={classes:"relation",pattern:t.relation.lineType==1?"dashed":"solid",id:"id"+s,arrowhead:t.type==="arrow_open"?"none":"normal",startLabelRight:t.relationTitle1==="none"?"":t.relationTitle1,endLabelLeft:t.relationTitle2==="none"?"":t.relationTitle2,arrowTypeStart:P(t.relation.type1),arrowTypeEnd:P(t.relation.type2),style:"fill:none",labelStyle:"",curve:N(y?.curve,S)};if(d.info(o,t),t.style!==void 0){let c=B(t.style);o.style=c.style,o.labelStyle=c.labelStyle}t.text=t.title,t.text===void 0?t.style!==void 0&&(o.arrowheadStyle="fill: #333"):(o.arrowheadStyle="fill: #333",o.labelpos="c",((r=i().flowchart)==null?void 0:r.htmlLabels)??i().htmlLabels?(o.labelType="html",o.label=''+t.text+""):(o.labelType="text",o.label=t.text.replace(L.lineBreakRegex,` `),t.style===void 0&&(o.style=o.style||"stroke: #333; stroke-width: 1.5px;fill:none"),o.labelStyle=o.labelStyle.replace("color:","fill:"))),e.setEdge(t.id1,t.id2,o,s)})},Q=function(n){D={...D,...n}},U=async function(n,e,y,s){d.info("Drawing class - ",e);let t=i().flowchart??i().class,r=i().securityLevel;d.info("config:",t);let o=t?.nodeSpacing??50,c=t?.rankSpacing??50,l=new A({multigraph:!0,compound:!0}).setGraph({rankdir:s.db.getDirection(),nodesep:o,ranksep:c,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}}),a=s.db.getNamespaces(),p=s.db.getClasses(),f=s.db.getRelations(),h=s.db.getNotes();d.info(f),W(a,l,e,s),$(p,l,e,s),K(f,l),J(h,l,f.length+1,p);let b;r==="sandbox"&&(b=g("#i"+e));let m=r==="sandbox"?g(b.nodes()[0].contentDocument.body):g("body"),u=m.select(`[id="${e}"]`),x=m.select("#"+e+" g");if(await I(x,l,["aggregation","extension","composition","dependency","lollipop"],"classDiagram",e),G.insertTitle(u,"classTitleText",t?.titleTopMargin??5,s.db.getDiagramTitle()),z(l,u,t?.diagramPadding,t?.useMaxWidth),!t?.htmlLabels){let _=r==="sandbox"?b.nodes()[0].contentDocument:document,q=_.querySelectorAll('[id="'+e+'"] .edgeLabel .label');for(let w of q){let C=w.getBBox(),v=_.createElementNS("http://www.w3.org/2000/svg","rect");v.setAttribute("rx",0),v.setAttribute("ry",0),v.setAttribute("width",C.width),v.setAttribute("height",C.height),w.insertBefore(v,w.firstChild)}}};function P(n){let e;switch(n){case 0:e="aggregation";break;case 1:e="extension";break;case 2:e="composition";break;case 3:e="dependency";break;case 4:e="lollipop";break;default:e="none"}return e}var X={setConf:Q,draw:U},it={parser:M,db:T,renderer:X,styles:R,init:n=>{n.class||(n.class={}),n.class.arrowMarkerAbsolute=n.arrowMarkerAbsolute,T.clear()}};export{it as diagram}; -//# sourceMappingURL=classDiagram-v2-c3cb15f1-KNJLQSSI.min.js.map +//# sourceMappingURL=classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js.map diff --git a/docs/public/classDiagram-v2-c3cb15f1-KNJLQSSI.min.js.map b/docs/public/classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js.map similarity index 98% rename from docs/public/classDiagram-v2-c3cb15f1-KNJLQSSI.min.js.map rename to docs/public/classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js.map index 49ac12c5..f81411cc 100644 --- a/docs/public/classDiagram-v2-c3cb15f1-KNJLQSSI.min.js.map +++ b/docs/public/classDiagram-v2-8ecb0bfc-5GKH2VJ4.min.js.map @@ -1,7 +1,7 @@ { "version": 3, - "sources": ["../../node_modules/mermaid/dist/classDiagram-v2-c3cb15f1.js"], - "sourcesContent": ["import { p as parser, d as db, s as styles } from \"./styles-3dcbcfbf.js\";\nimport { select, curveLinear } from \"d3\";\nimport * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { l as log, c as getConfig, u as utils, o as setupGraphViewbox, n as interpolateToCurve, k as getStylesFromArray, e as common } from \"./mermaid-8af3addd.js\";\nimport { r as render } from \"./index-2c4b9a3b.js\";\nimport \"ts-dedent\";\nimport \"dayjs\";\nimport \"@braintree/sanitize-url\";\nimport \"dompurify\";\nimport \"khroma\";\nimport \"lodash-es/memoize.js\";\nimport \"lodash-es/merge.js\";\nimport \"stylis\";\nimport \"lodash-es/isEmpty.js\";\nimport \"dagre-d3-es/src/dagre/index.js\";\nimport \"dagre-d3-es/src/graphlib/json.js\";\nimport \"./edges-f2ad444c.js\";\nimport \"./createText-62fc7601.js\";\nimport \"mdast-util-from-markdown\";\nconst sanitizeText = (txt) => common.sanitizeText(txt, getConfig());\nlet conf = {\n dividerMargin: 10,\n padding: 5,\n textHeight: 10,\n curve: void 0\n};\nconst addNamespaces = function(namespaces, g, _id, diagObj) {\n const keys = Object.keys(namespaces);\n log.info(\"keys:\", keys);\n log.info(namespaces);\n keys.forEach(function(id) {\n var _a, _b;\n const vertex = namespaces[id];\n const shape = \"rect\";\n const node = {\n shape,\n id: vertex.id,\n domId: vertex.domId,\n labelText: sanitizeText(vertex.id),\n labelStyle: \"\",\n style: \"fill: none; stroke: black\",\n // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release\n padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)\n };\n g.setNode(vertex.id, node);\n addClasses(vertex.classes, g, _id, diagObj, vertex.id);\n log.info(\"setNode\", node);\n });\n};\nconst addClasses = function(classes, g, _id, diagObj, parent) {\n const keys = Object.keys(classes);\n log.info(\"keys:\", keys);\n log.info(classes);\n keys.filter((id) => classes[id].parent == parent).forEach(function(id) {\n var _a, _b;\n const vertex = classes[id];\n const cssClassStr = vertex.cssClasses.join(\" \");\n const styles2 = { labelStyle: \"\", style: \"\" };\n const vertexText = vertex.label ?? vertex.id;\n const radius = 0;\n const shape = \"class_box\";\n const node = {\n labelStyle: styles2.labelStyle,\n shape,\n labelText: sanitizeText(vertexText),\n classData: vertex,\n rx: radius,\n ry: radius,\n class: cssClassStr,\n style: styles2.style,\n id: vertex.id,\n domId: vertex.domId,\n tooltip: diagObj.db.getTooltip(vertex.id, parent) || \"\",\n haveCallback: vertex.haveCallback,\n link: vertex.link,\n width: vertex.type === \"group\" ? 500 : void 0,\n type: vertex.type,\n // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release\n padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)\n };\n g.setNode(vertex.id, node);\n if (parent) {\n g.setParent(vertex.id, parent);\n }\n log.info(\"setNode\", node);\n });\n};\nconst addNotes = function(notes, g, startEdgeId, classes) {\n log.info(notes);\n notes.forEach(function(note, i) {\n var _a, _b;\n const vertex = note;\n const cssNoteStr = \"\";\n const styles2 = { labelStyle: \"\", style: \"\" };\n const vertexText = vertex.text;\n const radius = 0;\n const shape = \"note\";\n const node = {\n labelStyle: styles2.labelStyle,\n shape,\n labelText: sanitizeText(vertexText),\n noteData: vertex,\n rx: radius,\n ry: radius,\n class: cssNoteStr,\n style: styles2.style,\n id: vertex.id,\n domId: vertex.id,\n tooltip: \"\",\n type: \"note\",\n // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release\n padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)\n };\n g.setNode(vertex.id, node);\n log.info(\"setNode\", node);\n if (!vertex.class || !(vertex.class in classes)) {\n return;\n }\n const edgeId = startEdgeId + i;\n const edgeData = {\n id: `edgeNote${edgeId}`,\n //Set relationship style and line type\n classes: \"relation\",\n pattern: \"dotted\",\n // Set link type for rendering\n arrowhead: \"none\",\n //Set edge extra labels\n startLabelRight: \"\",\n endLabelLeft: \"\",\n //Set relation arrow types\n arrowTypeStart: \"none\",\n arrowTypeEnd: \"none\",\n style: \"fill:none\",\n labelStyle: \"\",\n curve: interpolateToCurve(conf.curve, curveLinear)\n };\n g.setEdge(vertex.id, vertex.class, edgeData, edgeId);\n });\n};\nconst addRelations = function(relations, g) {\n const conf2 = getConfig().flowchart;\n let cnt = 0;\n relations.forEach(function(edge) {\n var _a;\n cnt++;\n const edgeData = {\n //Set relationship style and line type\n classes: \"relation\",\n pattern: edge.relation.lineType == 1 ? \"dashed\" : \"solid\",\n id: \"id\" + cnt,\n // Set link type for rendering\n arrowhead: edge.type === \"arrow_open\" ? \"none\" : \"normal\",\n //Set edge extra labels\n startLabelRight: edge.relationTitle1 === \"none\" ? \"\" : edge.relationTitle1,\n endLabelLeft: edge.relationTitle2 === \"none\" ? \"\" : edge.relationTitle2,\n //Set relation arrow types\n arrowTypeStart: getArrowMarker(edge.relation.type1),\n arrowTypeEnd: getArrowMarker(edge.relation.type2),\n style: \"fill:none\",\n labelStyle: \"\",\n curve: interpolateToCurve(conf2 == null ? void 0 : conf2.curve, curveLinear)\n };\n log.info(edgeData, edge);\n if (edge.style !== void 0) {\n const styles2 = getStylesFromArray(edge.style);\n edgeData.style = styles2.style;\n edgeData.labelStyle = styles2.labelStyle;\n }\n edge.text = edge.title;\n if (edge.text === void 0) {\n if (edge.style !== void 0) {\n edgeData.arrowheadStyle = \"fill: #333\";\n }\n } else {\n edgeData.arrowheadStyle = \"fill: #333\";\n edgeData.labelpos = \"c\";\n if (((_a = getConfig().flowchart) == null ? void 0 : _a.htmlLabels) ?? getConfig().htmlLabels) {\n edgeData.labelType = \"html\";\n edgeData.label = '' + edge.text + \"\";\n } else {\n edgeData.labelType = \"text\";\n edgeData.label = edge.text.replace(common.lineBreakRegex, \"\\n\");\n if (edge.style === void 0) {\n edgeData.style = edgeData.style || \"stroke: #333; stroke-width: 1.5px;fill:none\";\n }\n edgeData.labelStyle = edgeData.labelStyle.replace(\"color:\", \"fill:\");\n }\n }\n g.setEdge(edge.id1, edge.id2, edgeData, cnt);\n });\n};\nconst setConf = function(cnf) {\n conf = {\n ...conf,\n ...cnf\n };\n};\nconst draw = async function(text, id, _version, diagObj) {\n log.info(\"Drawing class - \", id);\n const conf2 = getConfig().flowchart ?? getConfig().class;\n const securityLevel = getConfig().securityLevel;\n log.info(\"config:\", conf2);\n const nodeSpacing = (conf2 == null ? void 0 : conf2.nodeSpacing) ?? 50;\n const rankSpacing = (conf2 == null ? void 0 : conf2.rankSpacing) ?? 50;\n const g = new graphlib.Graph({\n multigraph: true,\n compound: true\n }).setGraph({\n rankdir: diagObj.db.getDirection(),\n nodesep: nodeSpacing,\n ranksep: rankSpacing,\n marginx: 8,\n marginy: 8\n }).setDefaultEdgeLabel(function() {\n return {};\n });\n const namespaces = diagObj.db.getNamespaces();\n const classes = diagObj.db.getClasses();\n const relations = diagObj.db.getRelations();\n const notes = diagObj.db.getNotes();\n log.info(relations);\n addNamespaces(namespaces, g, id, diagObj);\n addClasses(classes, g, id, diagObj);\n addRelations(relations, g);\n addNotes(notes, g, relations.length + 1, classes);\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n const svg = root.select(`[id=\"${id}\"]`);\n const element = root.select(\"#\" + id + \" g\");\n await render(\n element,\n g,\n [\"aggregation\", \"extension\", \"composition\", \"dependency\", \"lollipop\"],\n \"classDiagram\",\n id\n );\n utils.insertTitle(svg, \"classTitleText\", (conf2 == null ? void 0 : conf2.titleTopMargin) ?? 5, diagObj.db.getDiagramTitle());\n setupGraphViewbox(g, svg, conf2 == null ? void 0 : conf2.diagramPadding, conf2 == null ? void 0 : conf2.useMaxWidth);\n if (!(conf2 == null ? void 0 : conf2.htmlLabels)) {\n const doc = securityLevel === \"sandbox\" ? sandboxElement.nodes()[0].contentDocument : document;\n const labels = doc.querySelectorAll('[id=\"' + id + '\"] .edgeLabel .label');\n for (const label of labels) {\n const dim = label.getBBox();\n const rect = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"rect\");\n rect.setAttribute(\"rx\", 0);\n rect.setAttribute(\"ry\", 0);\n rect.setAttribute(\"width\", dim.width);\n rect.setAttribute(\"height\", dim.height);\n label.insertBefore(rect, label.firstChild);\n }\n }\n};\nfunction getArrowMarker(type) {\n let marker;\n switch (type) {\n case 0:\n marker = \"aggregation\";\n break;\n case 1:\n marker = \"extension\";\n break;\n case 2:\n marker = \"composition\";\n break;\n case 3:\n marker = \"dependency\";\n break;\n case 4:\n marker = \"lollipop\";\n break;\n default:\n marker = \"none\";\n }\n return marker;\n}\nconst renderer = {\n setConf,\n draw\n};\nconst diagram = {\n parser,\n db,\n renderer,\n styles,\n init: (cnf) => {\n if (!cnf.class) {\n cnf.class = {};\n }\n cnf.class.arrowMarkerAbsolute = cnf.arrowMarkerAbsolute;\n db.clear();\n }\n};\nexport {\n diagram\n};\n"], + "sources": ["../../node_modules/mermaid/dist/classDiagram-v2-8ecb0bfc.js"], + "sourcesContent": ["import { p as parser, d as db, s as styles } from \"./styles-4ba6ed67.js\";\nimport { select, curveLinear } from \"d3\";\nimport * as graphlib from \"dagre-d3-es/src/graphlib/index.js\";\nimport { l as log, c as getConfig, u as utils, o as setupGraphViewbox, n as interpolateToCurve, k as getStylesFromArray, e as common } from \"./mermaid-934d9bea.js\";\nimport { r as render } from \"./index-67a42d7d.js\";\nimport \"ts-dedent\";\nimport \"dayjs\";\nimport \"@braintree/sanitize-url\";\nimport \"dompurify\";\nimport \"khroma\";\nimport \"lodash-es/memoize.js\";\nimport \"lodash-es/merge.js\";\nimport \"stylis\";\nimport \"lodash-es/isEmpty.js\";\nimport \"dagre-d3-es/src/dagre/index.js\";\nimport \"dagre-d3-es/src/graphlib/json.js\";\nimport \"./edges-80f1ebb6.js\";\nimport \"./createText-aebacdfe.js\";\nimport \"mdast-util-from-markdown\";\nconst sanitizeText = (txt) => common.sanitizeText(txt, getConfig());\nlet conf = {\n dividerMargin: 10,\n padding: 5,\n textHeight: 10,\n curve: void 0\n};\nconst addNamespaces = function(namespaces, g, _id, diagObj) {\n const keys = Object.keys(namespaces);\n log.info(\"keys:\", keys);\n log.info(namespaces);\n keys.forEach(function(id) {\n var _a, _b;\n const vertex = namespaces[id];\n const shape = \"rect\";\n const node = {\n shape,\n id: vertex.id,\n domId: vertex.domId,\n labelText: sanitizeText(vertex.id),\n labelStyle: \"\",\n style: \"fill: none; stroke: black\",\n // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release\n padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)\n };\n g.setNode(vertex.id, node);\n addClasses(vertex.classes, g, _id, diagObj, vertex.id);\n log.info(\"setNode\", node);\n });\n};\nconst addClasses = function(classes, g, _id, diagObj, parent) {\n const keys = Object.keys(classes);\n log.info(\"keys:\", keys);\n log.info(classes);\n keys.filter((id) => classes[id].parent == parent).forEach(function(id) {\n var _a, _b;\n const vertex = classes[id];\n const cssClassStr = vertex.cssClasses.join(\" \");\n const styles2 = { labelStyle: \"\", style: \"\" };\n const vertexText = vertex.label ?? vertex.id;\n const radius = 0;\n const shape = \"class_box\";\n const node = {\n labelStyle: styles2.labelStyle,\n shape,\n labelText: sanitizeText(vertexText),\n classData: vertex,\n rx: radius,\n ry: radius,\n class: cssClassStr,\n style: styles2.style,\n id: vertex.id,\n domId: vertex.domId,\n tooltip: diagObj.db.getTooltip(vertex.id, parent) || \"\",\n haveCallback: vertex.haveCallback,\n link: vertex.link,\n width: vertex.type === \"group\" ? 500 : void 0,\n type: vertex.type,\n // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release\n padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)\n };\n g.setNode(vertex.id, node);\n if (parent) {\n g.setParent(vertex.id, parent);\n }\n log.info(\"setNode\", node);\n });\n};\nconst addNotes = function(notes, g, startEdgeId, classes) {\n log.info(notes);\n notes.forEach(function(note, i) {\n var _a, _b;\n const vertex = note;\n const cssNoteStr = \"\";\n const styles2 = { labelStyle: \"\", style: \"\" };\n const vertexText = vertex.text;\n const radius = 0;\n const shape = \"note\";\n const node = {\n labelStyle: styles2.labelStyle,\n shape,\n labelText: sanitizeText(vertexText),\n noteData: vertex,\n rx: radius,\n ry: radius,\n class: cssNoteStr,\n style: styles2.style,\n id: vertex.id,\n domId: vertex.id,\n tooltip: \"\",\n type: \"note\",\n // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release\n padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)\n };\n g.setNode(vertex.id, node);\n log.info(\"setNode\", node);\n if (!vertex.class || !(vertex.class in classes)) {\n return;\n }\n const edgeId = startEdgeId + i;\n const edgeData = {\n id: `edgeNote${edgeId}`,\n //Set relationship style and line type\n classes: \"relation\",\n pattern: \"dotted\",\n // Set link type for rendering\n arrowhead: \"none\",\n //Set edge extra labels\n startLabelRight: \"\",\n endLabelLeft: \"\",\n //Set relation arrow types\n arrowTypeStart: \"none\",\n arrowTypeEnd: \"none\",\n style: \"fill:none\",\n labelStyle: \"\",\n curve: interpolateToCurve(conf.curve, curveLinear)\n };\n g.setEdge(vertex.id, vertex.class, edgeData, edgeId);\n });\n};\nconst addRelations = function(relations, g) {\n const conf2 = getConfig().flowchart;\n let cnt = 0;\n relations.forEach(function(edge) {\n var _a;\n cnt++;\n const edgeData = {\n //Set relationship style and line type\n classes: \"relation\",\n pattern: edge.relation.lineType == 1 ? \"dashed\" : \"solid\",\n id: \"id\" + cnt,\n // Set link type for rendering\n arrowhead: edge.type === \"arrow_open\" ? \"none\" : \"normal\",\n //Set edge extra labels\n startLabelRight: edge.relationTitle1 === \"none\" ? \"\" : edge.relationTitle1,\n endLabelLeft: edge.relationTitle2 === \"none\" ? \"\" : edge.relationTitle2,\n //Set relation arrow types\n arrowTypeStart: getArrowMarker(edge.relation.type1),\n arrowTypeEnd: getArrowMarker(edge.relation.type2),\n style: \"fill:none\",\n labelStyle: \"\",\n curve: interpolateToCurve(conf2 == null ? void 0 : conf2.curve, curveLinear)\n };\n log.info(edgeData, edge);\n if (edge.style !== void 0) {\n const styles2 = getStylesFromArray(edge.style);\n edgeData.style = styles2.style;\n edgeData.labelStyle = styles2.labelStyle;\n }\n edge.text = edge.title;\n if (edge.text === void 0) {\n if (edge.style !== void 0) {\n edgeData.arrowheadStyle = \"fill: #333\";\n }\n } else {\n edgeData.arrowheadStyle = \"fill: #333\";\n edgeData.labelpos = \"c\";\n if (((_a = getConfig().flowchart) == null ? void 0 : _a.htmlLabels) ?? getConfig().htmlLabels) {\n edgeData.labelType = \"html\";\n edgeData.label = '' + edge.text + \"\";\n } else {\n edgeData.labelType = \"text\";\n edgeData.label = edge.text.replace(common.lineBreakRegex, \"\\n\");\n if (edge.style === void 0) {\n edgeData.style = edgeData.style || \"stroke: #333; stroke-width: 1.5px;fill:none\";\n }\n edgeData.labelStyle = edgeData.labelStyle.replace(\"color:\", \"fill:\");\n }\n }\n g.setEdge(edge.id1, edge.id2, edgeData, cnt);\n });\n};\nconst setConf = function(cnf) {\n conf = {\n ...conf,\n ...cnf\n };\n};\nconst draw = async function(text, id, _version, diagObj) {\n log.info(\"Drawing class - \", id);\n const conf2 = getConfig().flowchart ?? getConfig().class;\n const securityLevel = getConfig().securityLevel;\n log.info(\"config:\", conf2);\n const nodeSpacing = (conf2 == null ? void 0 : conf2.nodeSpacing) ?? 50;\n const rankSpacing = (conf2 == null ? void 0 : conf2.rankSpacing) ?? 50;\n const g = new graphlib.Graph({\n multigraph: true,\n compound: true\n }).setGraph({\n rankdir: diagObj.db.getDirection(),\n nodesep: nodeSpacing,\n ranksep: rankSpacing,\n marginx: 8,\n marginy: 8\n }).setDefaultEdgeLabel(function() {\n return {};\n });\n const namespaces = diagObj.db.getNamespaces();\n const classes = diagObj.db.getClasses();\n const relations = diagObj.db.getRelations();\n const notes = diagObj.db.getNotes();\n log.info(relations);\n addNamespaces(namespaces, g, id, diagObj);\n addClasses(classes, g, id, diagObj);\n addRelations(relations, g);\n addNotes(notes, g, relations.length + 1, classes);\n let sandboxElement;\n if (securityLevel === \"sandbox\") {\n sandboxElement = select(\"#i\" + id);\n }\n const root = securityLevel === \"sandbox\" ? select(sandboxElement.nodes()[0].contentDocument.body) : select(\"body\");\n const svg = root.select(`[id=\"${id}\"]`);\n const element = root.select(\"#\" + id + \" g\");\n await render(\n element,\n g,\n [\"aggregation\", \"extension\", \"composition\", \"dependency\", \"lollipop\"],\n \"classDiagram\",\n id\n );\n utils.insertTitle(svg, \"classTitleText\", (conf2 == null ? void 0 : conf2.titleTopMargin) ?? 5, diagObj.db.getDiagramTitle());\n setupGraphViewbox(g, svg, conf2 == null ? void 0 : conf2.diagramPadding, conf2 == null ? void 0 : conf2.useMaxWidth);\n if (!(conf2 == null ? void 0 : conf2.htmlLabels)) {\n const doc = securityLevel === \"sandbox\" ? sandboxElement.nodes()[0].contentDocument : document;\n const labels = doc.querySelectorAll('[id=\"' + id + '\"] .edgeLabel .label');\n for (const label of labels) {\n const dim = label.getBBox();\n const rect = doc.createElementNS(\"http://www.w3.org/2000/svg\", \"rect\");\n rect.setAttribute(\"rx\", 0);\n rect.setAttribute(\"ry\", 0);\n rect.setAttribute(\"width\", dim.width);\n rect.setAttribute(\"height\", dim.height);\n label.insertBefore(rect, label.firstChild);\n }\n }\n};\nfunction getArrowMarker(type) {\n let marker;\n switch (type) {\n case 0:\n marker = \"aggregation\";\n break;\n case 1:\n marker = \"extension\";\n break;\n case 2:\n marker = \"composition\";\n break;\n case 3:\n marker = \"dependency\";\n break;\n case 4:\n marker = \"lollipop\";\n break;\n default:\n marker = \"none\";\n }\n return marker;\n}\nconst renderer = {\n setConf,\n draw\n};\nconst diagram = {\n parser,\n db,\n renderer,\n styles,\n init: (cnf) => {\n if (!cnf.class) {\n cnf.class = {};\n }\n cnf.class.arrowMarkerAbsolute = cnf.arrowMarkerAbsolute;\n db.clear();\n }\n};\nexport {\n diagram\n};\n"], "mappings": "8XAMA,IAAAA,GAAO,SACPC,GAAO,SACPC,GAAO,SAWP,IAAMC,EAAgBC,GAAQC,EAAO,aAAaD,EAAKE,EAAU,CAAC,EAC9DC,EAAO,CACT,cAAe,GACf,QAAS,EACT,WAAY,GACZ,MAAO,MACT,EACMC,EAAgB,SAASC,EAAYC,EAAGC,EAAKC,EAAS,CAC1D,IAAMC,EAAO,OAAO,KAAKJ,CAAU,EACnCK,EAAI,KAAK,QAASD,CAAI,EACtBC,EAAI,KAAKL,CAAU,EACnBI,EAAK,QAAQ,SAASE,EAAI,CACxB,IAAIC,EAAIC,EACR,IAAMC,EAAST,EAAWM,CAAE,EAEtBI,EAAO,CACX,MAFY,OAGZ,GAAID,EAAO,GACX,MAAOA,EAAO,MACd,UAAWf,EAAae,EAAO,EAAE,EACjC,WAAY,GACZ,MAAO,4BAEP,UAAWF,EAAKV,EAAU,EAAE,YAAc,KAAO,OAASU,EAAG,Y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AAM,EAAE,CAAC,EAAE,gBAAkB,SAChFS,EAASD,EAAI,iBAAiB,QAAU/C,EAAK,sBAAsB,EACzE,QAAWiD,KAASD,EAAQ,CAC1B,IAAME,EAAMD,EAAM,QAAQ,EACpBE,EAAOJ,EAAI,gBAAgB,6BAA8B,MAAM,EACrEI,EAAK,aAAa,KAAM,CAAC,EACzBA,EAAK,aAAa,KAAM,CAAC,EACzBA,EAAK,aAAa,QAASD,EAAI,KAAK,EACpCC,EAAK,aAAa,SAAUD,EAAI,MAAM,EACtCD,EAAM,aAAaE,EAAMF,EAAM,UAAU,CAC3C,CACF,CACF,EACA,SAASrB,EAAewB,EAAM,CAC5B,IAAIC,EACJ,OAAQD,EAAM,CACZ,IAAK,GACHC,EAAS,cACT,MACF,IAAK,GACHA,EAAS,YACT,MACF,IAAK,GACHA,EAAS,cACT,MACF,IAAK,GACHA,EAAS,aACT,MACF,IAAK,GACHA,EAAS,WACT,MACF,QACEA,EAAS,MACb,CACA,OAAOA,CACT,CACA,IAAMC,EAAW,CACf,QAAAxB,EACA,KAAAE,CACF,EACMuB,GAAU,CACd,OAAAC,EACA,GAAAC,EACA,SAAAH,EACA,OAAAI,EACA,KAAO3B,GAAQ,CACRA,EAAI,QACPA,EAAI,MAAQ,CAAC,GAEfA,EAAI,MAAM,oBAAsBA,EAAI,oBACpC0B,EAAG,MAAM,CACX,CACF", "names": ["import_dayjs", "import_sanitize_url", "import_dompurify", "sanitizeText", "txt", "common$1", "getConfig", "conf", "addNamespaces", "namespaces", "g", "_id", "diagObj", "keys", "log$1", "id", "_a", "_b", "vertex", "node", "addClasses", "classes", "parent", "cssClassStr", "styles2", "vertexText", "radius", "shape", "addNotes", "notes", "startEdgeId", "note", "i", "cssNoteStr", "edgeId", "edgeData", "interpolateToCurve", "linear_default", "addRelations", "relations", "conf2", "cnt", "edge", "getArrowMarker", "getStylesFromArray", "setConf", "cnf", "draw", "text", "_version", "securityLevel", "nodeSpacing", "rankSpacing", "Graph", "sandboxElement", "select_default", "root", "svg", "element", "render", "utils", "setupGraphViewbox$1", "doc", "labels", "label", "dim", "rect", "type", "marker", "renderer", "diagram", "parser$1", "db", "styles"] } diff --git a/docs/public/docfx.min.js b/docs/public/docfx.min.js index d37b8e8a..55264044 100644 --- a/docs/public/docfx.min.js +++ b/docs/public/docfx.min.js @@ -1,6 +1,6 @@ import{b as Jo,c as Lo,d as No}from"./chunk-P42HNYSU.min.js";var Qo=Jo((AF,xi)=>{(function(i,t){"use strict";typeof define=="function"&&define.amd?define([],t):typeof xi=="object"&&xi.exports?xi.exports=t():(i.AnchorJS=t(),i.anchors=new i.AnchorJS)})(globalThis,function(){"use strict";function i(t){this.options=t||{},this.elements=[];function c(o){o.icon=Object.prototype.hasOwnProperty.call(o,"icon")?o.icon:"\uE9CB",o.visible=Object.prototype.hasOwnProperty.call(o,"visible")?o.visible:"hover",o.placement=Object.prototype.hasOwnProperty.call(o,"placement")?o.placement:"right",o.ariaLabel=Object.prototype.hasOwnProperty.call(o,"ariaLabel")?o.ariaLabel:"Anchor",o.class=Object.prototype.hasOwnProperty.call(o,"class")?o.class:"",o.base=Object.prototype.hasOwnProperty.call(o,"base")?o.base:"",o.truncate=Object.prototype.hasOwnProperty.call(o,"truncate")?Math.floor(o.truncate):64,o.titleText=Object.prototype.hasOwnProperty.call(o,"titleText")?o.titleText:""}c(this.options),this.add=function(o){var l,a,I,d,n,s,C,g,F,r,X,Z=[];if(c(this.options),o||(o="h2, h3, h4, h5, h6"),l=e(o),l.length===0)return this;for(b(),a=document.querySelectorAll("[id]"),I=[].map.call(a,function(B){return B.id}),n=0;n\]./()*\\\n\t\b\v\u00A0]/g;return this.options.truncate||c(this.options),o.trim().replace(/'/gi,"").replace(a,"-").replace(/-{2,}/g,"-").substring(0,this.options.truncate).replace(/^-+|-+$/gm,"").toLowerCase()},this.hasAnchorJSLink=function(o){var l=o.firstChild&&(" "+o.firstChild.className+" ").indexOf(" anchorjs-link ")>-1,a=o.lastChild&&(" "+o.lastChild.className+" ").indexOf(" anchorjs-link ")>-1;return l||a||!1};function e(o){var l;if(typeof o=="string"||o instanceof String)l=[].slice.call(document.querySelectorAll(o));else if(Array.isArray(o)||o instanceof NodeList)l=[].slice.call(o);else throw new TypeError("The selector provided to AnchorJS was invalid.");return l}function b(){if(document.head.querySelector("style.anchorjs")===null){var o=document.createElement("style"),l=".anchorjs-link{opacity:0;text-decoration:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}",a=":hover>.anchorjs-link,.anchorjs-link:focus{opacity:1}",I='@font-face{font-family:anchorjs-icons;src:url(data:n/a;base64,AAEAAAALAIAAAwAwT1MvMg8yG2cAAAE4AAAAYGNtYXDp3gC3AAABpAAAAExnYXNwAAAAEAAAA9wAAAAIZ2x5ZlQCcfwAAAH4AAABCGhlYWQHFvHyAAAAvAAAADZoaGVhBnACFwAAAPQAAAAkaG10eASAADEAAAGYAAAADGxvY2EACACEAAAB8AAAAAhtYXhwAAYAVwAAARgAAAAgbmFtZQGOH9cAAAMAAAAAunBvc3QAAwAAAAADvAAAACAAAQAAAAEAAHzE2p9fDzz1AAkEAAAAAADRecUWAAAAANQA6R8AAAAAAoACwAAAAAgAAgAAAAAAAAABAAADwP/AAAACgAAA/9MCrQABAAAAAAAAAAAAAAAAAAAAAwABAAAAAwBVAAIAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAMCQAGQAAUAAAKZAswAAACPApkCzAAAAesAMwEJAAAAAAAAAAAAAAAAAAAAARAAAAAAAAAAAAAAAAAAAAAAQAAg//0DwP/AAEADwABAAAAAAQAAAAAAAAAAAAAAIAAAAAAAAAIAAAACgAAxAAAAAwAAAAMAAAAcAAEAAwAAABwAAwABAAAAHAAEADAAAAAIAAgAAgAAACDpy//9//8AAAAg6cv//f///+EWNwADAAEAAAAAAAAAAAAAAAAACACEAAEAAAAAAAAAAAAAAAAxAAACAAQARAKAAsAAKwBUAAABIiYnJjQ3NzY2MzIWFxYUBwcGIicmNDc3NjQnJiYjIgYHBwYUFxYUBwYGIwciJicmNDc3NjIXFhQHBwYUFxYWMzI2Nzc2NCcmNDc2MhcWFAcHBgYjARQGDAUtLXoWOR8fORYtLTgKGwoKCjgaGg0gEhIgDXoaGgkJBQwHdR85Fi0tOAobCgoKOBoaDSASEiANehoaCQkKGwotLXoWOR8BMwUFLYEuehYXFxYugC44CQkKGwo4GkoaDQ0NDXoaShoKGwoFBe8XFi6ALjgJCQobCjgaShoNDQ0NehpKGgobCgoKLYEuehYXAAAADACWAAEAAAAAAAEACAAAAAEAAAAAAAIAAwAIAAEAAAAAAAMACAAAAAEAAAAAAAQACAAAAAEAAAAAAAUAAQALAAEAAAAAAAYACAAAAAMAAQQJAAEAEAAMAAMAAQQJAAIABgAcAAMAAQQJAAMAEAAMAAMAAQQJAAQAEAAMAAMAAQQJAAUAAgAiAAMAAQQJAAYAEAAMYW5jaG9yanM0MDBAAGEAbgBjAGgAbwByAGoAcwA0ADAAMABAAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAH//wAP) format("truetype")}',d="[data-anchorjs-icon]::after{content:attr(data-anchorjs-icon)}",n;o.className="anchorjs",o.appendChild(document.createTextNode("")),n=document.head.querySelector('[rel="stylesheet"],style'),n===void 0?document.head.appendChild(o):document.head.insertBefore(o,n),o.sheet.insertRule(l,o.sheet.cssRules.length),o.sheet.insertRule(a,o.sheet.cssRules.length),o.sheet.insertRule(d,o.sheet.cssRules.length),o.sheet.insertRule(I,o.sheet.cssRules.length)}}}return i})});var ci={};Lo(ci,{afterMain:()=>ze,afterRead:()=>Ne,afterWrite:()=>He,applyStyles:()=>qt,arrow:()=>Dc,auto:()=>Gc,basePlacements:()=>dt,beforeMain:()=>we,beforeRead:()=>Je,beforeWrite:()=>je,bottom:()=>v,clippingParents:()=>Ai,computeStyles:()=>cc,createPopper:()=>Vc,createPopperBase:()=>qe,createPopperLite:()=>tb,detectOverflow:()=>H,end:()=>Xt,eventListeners:()=>ic,flip:()=>Pc,hide:()=>$c,left:()=>f,main:()=>ke,modifierPhases:()=>fi,offset:()=>qc,placements:()=>Wc,popper:()=>Yt,popperGenerator:()=>zt,popperOffsets:()=>oc,preventOverflow:()=>ti,read:()=>Le,reference:()=>Ui,right:()=>Y,start:()=>It,top:()=>A,variationPlacements:()=>Ec,viewport:()=>Bc,write:()=>Se});var A="top",v="bottom",Y="right",f="left",Gc="auto",dt=[A,v,Y,f],It="start",Xt="end",Ai="clippingParents",Bc="viewport",Yt="popper",Ui="reference",Ec=dt.reduce(function(i,t){return i.concat([t+"-"+It,t+"-"+Xt])},[]),Wc=[].concat(dt,[Gc]).reduce(function(i,t){return i.concat([t,t+"-"+It,t+"-"+Xt])},[]),Je="beforeRead",Le="read",Ne="afterRead",we="beforeMain",ke="main",ze="afterMain",je="beforeWrite",Se="write",He="afterWrite",fi=[Je,Le,Ne,we,ke,ze,je,Se,He];function N(i){return i?(i.nodeName||"").toLowerCase():null}function V(i){if(i==null)return window;if(i.toString()!=="[object Window]"){var t=i.ownerDocument;return t&&t.defaultView||window}return i}function _(i){var t=V(i).Element;return i instanceof t||i instanceof Element}function J(i){var t=V(i).HTMLElement;return i instanceof t||i instanceof HTMLElement}function $t(i){if(typeof ShadowRoot>"u")return!1;var t=V(i).ShadowRoot;return i instanceof t||i instanceof ShadowRoot}function wo(i){var t=i.state;Object.keys(t.elements).forEach(function(c){var e=t.styles[c]||{},b=t.attributes[c]||{},o=t.elements[c];!J(o)||!N(o)||(Object.assign(o.style,e),Object.keys(b).forEach(function(l){var a=b[l];a===!1?o.removeAttribute(l):o.setAttribute(l,a===!0?"":a)}))})}function ko(i){var t=i.state,c={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,c.popper),t.styles=c,t.elements.arrow&&Object.assign(t.elements.arrow.style,c.arrow),function(){Object.keys(t.elements).forEach(function(e){var b=t.elements[e],o=t.attributes[e]||{},l=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:c[e]),a=l.reduce(function(I,d){return I[d]="",I},{});!J(b)||!N(b)||(Object.assign(b.style,a),Object.keys(o).forEach(function(I){b.removeAttribute(I)}))})}}var qt={name:"applyStyles",enabled:!0,phase:"write",fn:wo,effect:ko,requires:["computeStyles"]};function w(i){return i.split("-")[0]}var bt=Math.max,vt=Math.min,gt=Math.round;function tc(){var i=navigator.userAgentData;return i!=null&&i.brands&&Array.isArray(i.brands)?i.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function uc(){return!/^((?!chrome|android).)*safari/i.test(tc())}function P(i,t,c){t===void 0&&(t=!1),c===void 0&&(c=!1);var e=i.getBoundingClientRect(),b=1,o=1;t&&J(i)&&(b=i.offsetWidth>0&>(e.width)/i.offsetWidth||1,o=i.offsetHeight>0&>(e.height)/i.offsetHeight||1);var l=_(i)?V(i):window,a=l.visualViewport,I=!uc()&&c,d=(e.left+(I&&a?a.offsetLeft:0))/b,n=(e.top+(I&&a?a.offsetTop:0))/o,s=e.width/b,C=e.height/o;return{width:s,height:C,top:n,right:d+s,bottom:n+C,left:d,x:d,y:n}}function Ot(i){var t=P(i),c=i.offsetWidth,e=i.offsetHeight;return Math.abs(t.width-c)<=1&&(c=t.width),Math.abs(t.height-e)<=1&&(e=t.height),{x:i.offsetLeft,y:i.offsetTop,width:c,height:e}}function Rc(i,t){var c=t.getRootNode&&t.getRootNode();if(i.contains(t))return!0;if(c&&$t(c)){var e=t;do{if(e&&i.isSameNode(e))return!0;e=e.parentNode||e.host}while(e)}return!1}function S(i){return V(i).getComputedStyle(i)}function yi(i){return["table","td","th"].indexOf(N(i))>=0}function j(i){return((_(i)?i.ownerDocument:i.document)||window.document).documentElement}function st(i){return N(i)==="html"?i:i.assignedSlot||i.parentNode||($t(i)?i.host:null)||j(i)}function Te(i){return!J(i)||S(i).position==="fixed"?null:i.offsetParent}function zo(i){var t=/firefox/i.test(tc()),c=/Trident/i.test(tc());if(c&&J(i)){var e=S(i);if(e.position==="fixed")return null}var b=st(i);for($t(b)&&(b=b.host);J(b)&&["html","body"].indexOf(N(b))<0;){var o=S(b);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return b;b=b.parentNode}return null}function ot(i){for(var t=V(i),c=Te(i);c&&yi(c)&&S(c).position==="static";)c=Te(c);return c&&(N(c)==="html"||N(c)==="body"&&S(c).position==="static")?t:c||zo(i)||t}function Jt(i){return["top","bottom"].indexOf(i)>=0?"x":"y"}function Lt(i,t,c){return bt(i,vt(t,c))}function Ee(i,t,c){var e=Lt(i,t,c);return e>c?c:e}function xc(){return{top:0,right:0,bottom:0,left:0}}function Qc(i){return Object.assign({},xc(),i)}function pc(i,t){return t.reduce(function(c,e){return c[e]=i,c},{})}var jo=function(t,c){return t=typeof t=="function"?t(Object.assign({},c.rects,{placement:c.placement})):t,Qc(typeof t!="number"?t:pc(t,dt))};function So(i){var t,c=i.state,e=i.name,b=i.options,o=c.elements.arrow,l=c.modifiersData.popperOffsets,a=w(c.placement),I=Jt(a),d=[f,Y].indexOf(a)>=0,n=d?"height":"width";if(!(!o||!l)){var s=jo(b.padding,c),C=Ot(o),g=I==="y"?A:f,F=I==="y"?v:Y,r=c.rects.reference[n]+c.rects.reference[I]-l[I]-c.rects.popper[n],X=l[I]-c.rects.reference[I],Z=ot(o),B=Z?I==="y"?Z.clientHeight||0:Z.clientWidth||0:0,G=r/2-X/2,u=s[g],R=B-C[n]-s[F],Q=B/2-C[n]/2+G,p=Lt(u,Q,R),h=I;c.modifiersData[e]=(t={},t[h]=p,t.centerOffset=p-Q,t)}}function Ho(i){var t=i.state,c=i.options,e=c.element,b=e===void 0?"[data-popper-arrow]":e;b!=null&&(typeof b=="string"&&(b=t.elements.popper.querySelector(b),!b)||Rc(t.elements.popper,b)&&(t.elements.arrow=b))}var Dc={name:"arrow",enabled:!0,phase:"main",fn:So,effect:Ho,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function $(i){return i.split("-")[1]}var To={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Eo(i,t){var c=i.x,e=i.y,b=t.devicePixelRatio||1;return{x:gt(c*b)/b||0,y:gt(e*b)/b||0}}function De(i){var t,c=i.popper,e=i.popperRect,b=i.placement,o=i.variation,l=i.offsets,a=i.position,I=i.gpuAcceleration,d=i.adaptive,n=i.roundOffsets,s=i.isFixed,C=l.x,g=C===void 0?0:C,F=l.y,r=F===void 0?0:F,X=typeof n=="function"?n({x:g,y:r}):{x:g,y:r};g=X.x,r=X.y;var Z=l.hasOwnProperty("x"),B=l.hasOwnProperty("y"),G=f,u=A,R=window;if(d){var Q=ot(c),p="clientHeight",h="clientWidth";if(Q===V(c)&&(Q=j(c),S(Q).position!=="static"&&a==="absolute"&&(p="scrollHeight",h="scrollWidth")),Q=Q,b===A||(b===f||b===Y)&&o===Xt){u=v;var U=s&&Q===R&&R.visualViewport?R.visualViewport.height:Q[p];r-=U-e.height,r*=I?1:-1}if(b===f||(b===A||b===v)&&o===Xt){G=Y;var y=s&&Q===R&&R.visualViewport?R.visualViewport.width:Q[h];g-=y-e.width,g*=I?1:-1}}var O=Object.assign({position:a},d&&To),T=n===!0?Eo({x:g,y:r},V(c)):{x:g,y:r};if(g=T.x,r=T.y,I){var z;return Object.assign({},O,(z={},z[u]=B?"0":"",z[G]=Z?"0":"",z.transform=(R.devicePixelRatio||1)<=1?"translate("+g+"px, "+r+"px)":"translate3d("+g+"px, "+r+"px, 0)",z))}return Object.assign({},O,(t={},t[u]=B?r+"px":"",t[G]=Z?g+"px":"",t.transform="",t))}function Do(i){var t=i.state,c=i.options,e=c.gpuAcceleration,b=e===void 0?!0:e,o=c.adaptive,l=o===void 0?!0:o,a=c.roundOffsets,I=a===void 0?!0:a,d={placement:w(t.placement),variation:$(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:b,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,De(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:l,roundOffsets:I})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,De(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:I})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var cc={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Do,data:{}};var Mc={passive:!0};function Mo(i){var t=i.state,c=i.instance,e=i.options,b=e.scroll,o=b===void 0?!0:b,l=e.resize,a=l===void 0?!0:l,I=V(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&d.forEach(function(n){n.addEventListener("scroll",c.update,Mc)}),a&&I.addEventListener("resize",c.update,Mc),function(){o&&d.forEach(function(n){n.removeEventListener("scroll",c.update,Mc)}),a&&I.removeEventListener("resize",c.update,Mc)}}var ic={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Mo,data:{}};var Ko={left:"right",right:"left",bottom:"top",top:"bottom"};function ec(i){return i.replace(/left|right|bottom|top/g,function(t){return Ko[t]})}var _o={start:"end",end:"start"};function Kc(i){return i.replace(/start|end/g,function(t){return _o[t]})}function Nt(i){var t=V(i),c=t.pageXOffset,e=t.pageYOffset;return{scrollLeft:c,scrollTop:e}}function wt(i){return P(j(i)).left+Nt(i).scrollLeft}function Yi(i,t){var c=V(i),e=j(i),b=c.visualViewport,o=e.clientWidth,l=e.clientHeight,a=0,I=0;if(b){o=b.width,l=b.height;var d=uc();(d||!d&&t==="fixed")&&(a=b.offsetLeft,I=b.offsetTop)}return{width:o,height:l,x:a+wt(i),y:I}}function vi(i){var t,c=j(i),e=Nt(i),b=(t=i.ownerDocument)==null?void 0:t.body,o=bt(c.scrollWidth,c.clientWidth,b?b.scrollWidth:0,b?b.clientWidth:0),l=bt(c.scrollHeight,c.clientHeight,b?b.scrollHeight:0,b?b.clientHeight:0),a=-e.scrollLeft+wt(i),I=-e.scrollTop;return S(b||c).direction==="rtl"&&(a+=bt(c.clientWidth,b?b.clientWidth:0)-o),{width:o,height:l,x:a,y:I}}function kt(i){var t=S(i),c=t.overflow,e=t.overflowX,b=t.overflowY;return/auto|scroll|overlay|hidden/.test(c+b+e)}function _c(i){return["html","body","#document"].indexOf(N(i))>=0?i.ownerDocument.body:J(i)&&kt(i)?i:_c(st(i))}function Ct(i,t){var c;t===void 0&&(t=[]);var e=_c(i),b=e===((c=i.ownerDocument)==null?void 0:c.body),o=V(e),l=b?[o].concat(o.visualViewport||[],kt(e)?e:[]):e,a=t.concat(l);return b?a:a.concat(Ct(st(l)))}function bc(i){return Object.assign({},i,{left:i.x,top:i.y,right:i.x+i.width,bottom:i.y+i.height})}function Po(i,t){var c=P(i,!1,t==="fixed");return c.top=c.top+i.clientTop,c.left=c.left+i.clientLeft,c.bottom=c.top+i.clientHeight,c.right=c.left+i.clientWidth,c.width=i.clientWidth,c.height=i.clientHeight,c.x=c.left,c.y=c.top,c}function Me(i,t,c){return t===Bc?bc(Yi(i,c)):_(t)?Po(t,c):bc(vi(j(i)))}function $o(i){var t=Ct(st(i)),c=["absolute","fixed"].indexOf(S(i).position)>=0,e=c&&J(i)?ot(i):i;return _(e)?t.filter(function(b){return _(b)&&Rc(b,e)&&N(b)!=="body"}):[]}function Oi(i,t,c,e){var b=t==="clippingParents"?$o(i):[].concat(t),o=[].concat(b,[c]),l=o[0],a=o.reduce(function(I,d){var n=Me(i,d,e);return I.top=bt(n.top,I.top),I.right=vt(n.right,I.right),I.bottom=vt(n.bottom,I.bottom),I.left=bt(n.left,I.left),I},Me(i,l,e));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function hc(i){var t=i.reference,c=i.element,e=i.placement,b=e?w(e):null,o=e?$(e):null,l=t.x+t.width/2-c.width/2,a=t.y+t.height/2-c.height/2,I;switch(b){case A:I={x:l,y:t.y-c.height};break;case v:I={x:l,y:t.y+t.height};break;case Y:I={x:t.x+t.width,y:a};break;case f:I={x:t.x-c.width,y:a};break;default:I={x:t.x,y:t.y}}var d=b?Jt(b):null;if(d!=null){var n=d==="y"?"height":"width";switch(o){case It:I[d]=I[d]-(t[n]/2-c[n]/2);break;case Xt:I[d]=I[d]+(t[n]/2-c[n]/2);break;default:}}return I}function H(i,t){t===void 0&&(t={});var c=t,e=c.placement,b=e===void 0?i.placement:e,o=c.strategy,l=o===void 0?i.strategy:o,a=c.boundary,I=a===void 0?Ai:a,d=c.rootBoundary,n=d===void 0?Bc:d,s=c.elementContext,C=s===void 0?Yt:s,g=c.altBoundary,F=g===void 0?!1:g,r=c.padding,X=r===void 0?0:r,Z=Qc(typeof X!="number"?X:pc(X,dt)),B=C===Yt?Ui:Yt,G=i.rects.popper,u=i.elements[F?B:C],R=Oi(_(u)?u:u.contextElement||j(i.elements.popper),I,n,l),Q=P(i.elements.reference),p=hc({reference:Q,element:G,strategy:"absolute",placement:b}),h=bc(Object.assign({},G,p)),U=C===Yt?h:Q,y={top:R.top-U.top+Z.top,bottom:U.bottom-R.bottom+Z.bottom,left:R.left-U.left+Z.left,right:U.right-R.right+Z.right},O=i.modifiersData.offset;if(C===Yt&&O){var T=O[b];Object.keys(y).forEach(function(z){var Vt=[Y,v].indexOf(z)>=0?1:-1,At=[A,v].indexOf(z)>=0?"y":"x";y[z]+=T[At]*Vt})}return y}function Ji(i,t){t===void 0&&(t={});var c=t,e=c.placement,b=c.boundary,o=c.rootBoundary,l=c.padding,a=c.flipVariations,I=c.allowedAutoPlacements,d=I===void 0?Wc:I,n=$(e),s=n?a?Ec:Ec.filter(function(F){return $(F)===n}):dt,C=s.filter(function(F){return d.indexOf(F)>=0});C.length===0&&(C=s);var g=C.reduce(function(F,r){return F[r]=H(i,{placement:r,boundary:b,rootBoundary:o,padding:l})[w(r)],F},{});return Object.keys(g).sort(function(F,r){return g[F]-g[r]})}function qo(i){if(w(i)===Gc)return[];var t=ec(i);return[Kc(i),t,Kc(t)]}function tl(i){var t=i.state,c=i.options,e=i.name;if(!t.modifiersData[e]._skip){for(var b=c.mainAxis,o=b===void 0?!0:b,l=c.altAxis,a=l===void 0?!0:l,I=c.fallbackPlacements,d=c.padding,n=c.boundary,s=c.rootBoundary,C=c.altBoundary,g=c.flipVariations,F=g===void 0?!0:g,r=c.allowedAutoPlacements,X=t.options.placement,Z=w(X),B=Z===X,G=I||(B||!F?[ec(X)]:qo(X)),u=[X].concat(G).reduce(function(Pt,Zt){return Pt.concat(w(Zt)===Gc?Ji(t,{placement:Zt,boundary:n,rootBoundary:s,padding:d,flipVariations:F,allowedAutoPlacements:r}):Zt)},[]),R=t.rects.reference,Q=t.rects.popper,p=new Map,h=!0,U=u[0],y=0;y=0,At=Vt?"width":"height",M=H(t,{placement:O,boundary:n,rootBoundary:s,altBoundary:C,padding:d}),et=Vt?z?Y:f:z?v:A;R[At]>Q[At]&&(et=ec(et));var zc=ec(et),Ut=[];if(o&&Ut.push(M[T]<=0),a&&Ut.push(M[et]<=0,M[zc]<=0),Ut.every(function(Pt){return Pt})){U=O,h=!1;break}p.set(O,Ut)}if(h)for(var jc=F?3:1,Qi=function(Zt){var Cc=u.find(function(Hc){var ft=p.get(Hc);if(ft)return ft.slice(0,Zt).every(function(pi){return pi})});if(Cc)return U=Cc,"break"},Xc=jc;Xc>0;Xc--){var Sc=Qi(Xc);if(Sc==="break")break}t.placement!==U&&(t.modifiersData[e]._skip=!0,t.placement=U,t.reset=!0)}}var Pc={name:"flip",enabled:!0,phase:"main",fn:tl,requiresIfExists:["offset"],data:{_skip:!1}};function Ke(i,t,c){return c===void 0&&(c={x:0,y:0}),{top:i.top-t.height-c.y,right:i.right-t.width+c.x,bottom:i.bottom-t.height+c.y,left:i.left-t.width-c.x}}function _e(i){return[A,Y,v,f].some(function(t){return i[t]>=0})}function cl(i){var t=i.state,c=i.name,e=t.rects.reference,b=t.rects.popper,o=t.modifiersData.preventOverflow,l=H(t,{elementContext:"reference"}),a=H(t,{altBoundary:!0}),I=Ke(l,e),d=Ke(a,b,o),n=_e(I),s=_e(d);t.modifiersData[c]={referenceClippingOffsets:I,popperEscapeOffsets:d,isReferenceHidden:n,hasPopperEscaped:s},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":n,"data-popper-escaped":s})}var $c={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:cl};function il(i,t,c){var e=w(i),b=[f,A].indexOf(e)>=0?-1:1,o=typeof c=="function"?c(Object.assign({},t,{placement:i})):c,l=o[0],a=o[1];return l=l||0,a=(a||0)*b,[f,Y].indexOf(e)>=0?{x:a,y:l}:{x:l,y:a}}function el(i){var t=i.state,c=i.options,e=i.name,b=c.offset,o=b===void 0?[0,0]:b,l=Wc.reduce(function(n,s){return n[s]=il(s,t.rects,o),n},{}),a=l[t.placement],I=a.x,d=a.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=I,t.modifiersData.popperOffsets.y+=d),t.modifiersData[e]=l}var qc={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:el};function bl(i){var t=i.state,c=i.name;t.modifiersData[c]=hc({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}var oc={name:"popperOffsets",enabled:!0,phase:"read",fn:bl,data:{}};function Li(i){return i==="x"?"y":"x"}function ol(i){var t=i.state,c=i.options,e=i.name,b=c.mainAxis,o=b===void 0?!0:b,l=c.altAxis,a=l===void 0?!1:l,I=c.boundary,d=c.rootBoundary,n=c.altBoundary,s=c.padding,C=c.tether,g=C===void 0?!0:C,F=c.tetherOffset,r=F===void 0?0:F,X=H(t,{boundary:I,rootBoundary:d,padding:s,altBoundary:n}),Z=w(t.placement),B=$(t.placement),G=!B,u=Jt(Z),R=Li(u),Q=t.modifiersData.popperOffsets,p=t.rects.reference,h=t.rects.popper,U=typeof r=="function"?r(Object.assign({},t.rects,{placement:t.placement})):r,y=typeof U=="number"?{mainAxis:U,altAxis:U}:Object.assign({mainAxis:0,altAxis:0},U),O=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,T={x:0,y:0};if(Q){if(o){var z,Vt=u==="y"?A:f,At=u==="y"?v:Y,M=u==="y"?"height":"width",et=Q[u],zc=et+X[Vt],Ut=et-X[At],jc=g?-h[M]/2:0,Qi=B===It?p[M]:h[M],Xc=B===It?-h[M]:-p[M],Sc=t.elements.arrow,Pt=g&&Sc?Ot(Sc):{width:0,height:0},Zt=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:xc(),Cc=Zt[Vt],Hc=Zt[At],ft=Lt(0,p[M],Pt[M]),pi=G?p[M]/2-jc-ft-Cc-y.mainAxis:Qi-ft-Cc-y.mainAxis,Uo=G?-p[M]/2+jc+ft+Hc+y.mainAxis:Xc+ft+Hc+y.mainAxis,hi=t.elements.arrow&&ot(t.elements.arrow),fo=hi?u==="y"?hi.clientTop||0:hi.clientLeft||0:0,he=(z=O?.[u])!=null?z:0,yo=et+pi-he-fo,Yo=et+Uo-he,Ve=Lt(g?vt(zc,yo):zc,et,g?bt(Ut,Yo):Ut);Q[u]=Ve,T[u]=Ve-et}if(a){var Ae,vo=u==="x"?A:f,Oo=u==="x"?v:Y,yt=Q[R],Tc=R==="y"?"height":"width",Ue=yt+X[vo],fe=yt-X[Oo],Vi=[A,f].indexOf(Z)!==-1,ye=(Ae=O?.[R])!=null?Ae:0,Ye=Vi?Ue:yt-p[Tc]-h[Tc]-ye+y.altAxis,ve=Vi?yt+p[Tc]+h[Tc]-ye-y.altAxis:fe,Oe=g&&Vi?Ee(Ye,yt,ve):Lt(g?Ye:Ue,yt,g?ve:fe);Q[R]=Oe,T[R]=Oe-yt}t.modifiersData[e]=T}}var ti={name:"preventOverflow",enabled:!0,phase:"main",fn:ol,requiresIfExists:["offset"]};function Ni(i){return{scrollLeft:i.scrollLeft,scrollTop:i.scrollTop}}function wi(i){return i===V(i)||!J(i)?Nt(i):Ni(i)}function ll(i){var t=i.getBoundingClientRect(),c=gt(t.width)/i.offsetWidth||1,e=gt(t.height)/i.offsetHeight||1;return c!==1||e!==1}function ki(i,t,c){c===void 0&&(c=!1);var e=J(t),b=J(t)&&ll(t),o=j(t),l=P(i,b,c),a={scrollLeft:0,scrollTop:0},I={x:0,y:0};return(e||!e&&!c)&&((N(t)!=="body"||kt(o))&&(a=wi(t)),J(t)?(I=P(t,!0),I.x+=t.clientLeft,I.y+=t.clientTop):o&&(I.x=wt(o))),{x:l.left+a.scrollLeft-I.x,y:l.top+a.scrollTop-I.y,width:l.width,height:l.height}}function Il(i){var t=new Map,c=new Set,e=[];i.forEach(function(o){t.set(o.name,o)});function b(o){c.add(o.name);var l=[].concat(o.requires||[],o.requiresIfExists||[]);l.forEach(function(a){if(!c.has(a)){var I=t.get(a);I&&b(I)}}),e.push(o)}return i.forEach(function(o){c.has(o.name)||b(o)}),e}function zi(i){var t=Il(i);return fi.reduce(function(c,e){return c.concat(t.filter(function(b){return b.phase===e}))},[])}function ji(i){var t;return function(){return t||(t=new Promise(function(c){Promise.resolve().then(function(){t=void 0,c(i())})})),t}}function Si(i){var t=i.reduce(function(c,e){var b=c[e.name];return c[e.name]=b?Object.assign({},b,e,{options:Object.assign({},b.options,e.options),data:Object.assign({},b.data,e.data)}):e,c},{});return Object.keys(t).map(function(c){return t[c]})}var Pe={placement:"bottom",modifiers:[],strategy:"absolute"};function $e(){for(var i=arguments.length,t=new Array(i),c=0;c(i&&window.CSS&&window.CSS.escape&&(i=i.replace(/#([^\s"#']+)/g,(t,c)=>`#${CSS.escape(c)}`)),i),sl=i=>i==null?`${i}`:Object.prototype.toString.call(i).match(/\s([a-z]+)/i)[1].toLowerCase(),rl=i=>{do i+=Math.floor(Math.random()*dl);while(document.getElementById(i));return i},ml=i=>{if(!i)return 0;let{transitionDuration:t,transitionDelay:c}=window.getComputedStyle(i),e=Number.parseFloat(t),b=Number.parseFloat(c);return!e&&!b?0:(t=t.split(",")[0],c=c.split(",")[0],(Number.parseFloat(t)+Number.parseFloat(c))*gl)},Ub=i=>{i.dispatchEvent(new Event(oe))},rt=i=>!i||typeof i!="object"?!1:(typeof i.jquery<"u"&&(i=i[0]),typeof i.nodeType<"u"),Bt=i=>rt(i)?i.jquery?i[0]:i:typeof i=="string"&&i.length>0?document.querySelector(Ab(i)):null,rc=i=>{if(!rt(i)||i.getClientRects().length===0)return!1;let t=getComputedStyle(i).getPropertyValue("visibility")==="visible",c=i.closest("details:not([open])");if(!c)return t;if(c!==i){let e=i.closest("summary");if(e&&e.parentNode!==c||e===null)return!1}return t},Wt=i=>!i||i.nodeType!==Node.ELEMENT_NODE||i.classList.contains("disabled")?!0:typeof i.disabled<"u"?i.disabled:i.hasAttribute("disabled")&&i.getAttribute("disabled")!=="false",fb=i=>{if(!document.documentElement.attachShadow)return null;if(typeof i.getRootNode=="function"){let t=i.getRootNode();return t instanceof ShadowRoot?t:null}return i instanceof ShadowRoot?i:i.parentNode?fb(i.parentNode):null},di=()=>{},vc=i=>{i.offsetHeight},yb=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,Ti=[],Fl=i=>{document.readyState==="loading"?(Ti.length||document.addEventListener("DOMContentLoaded",()=>{for(let t of Ti)t()}),Ti.push(i)):i()},q=()=>document.documentElement.dir==="rtl",ct=i=>{Fl(()=>{let t=yb();if(t){let c=i.NAME,e=t.fn[c];t.fn[c]=i.jQueryInterface,t.fn[c].Constructor=i,t.fn[c].noConflict=()=>(t.fn[c]=e,i.jQueryInterface)}})},E=(i,t=[],c=i)=>typeof i=="function"?i(...t):c,Yb=(i,t,c=!0)=>{if(!c){E(i);return}let e=5,b=ml(t)+e,o=!1,l=({target:a})=>{a===t&&(o=!0,t.removeEventListener(oe,l),E(i))};t.addEventListener(oe,l),setTimeout(()=>{o||Ub(t)},b)},de=(i,t,c,e)=>{let b=i.length,o=i.indexOf(t);return o===-1?!c&&e?i[b-1]:i[0]:(o+=c?1:-1,e&&(o=(o+b)%b),i[Math.max(0,Math.min(o,b-1))])},Zl=/[^.]*(?=\..*)\.|.*/,Xl=/\..*/,Cl=/::\d+$/,Ei={},cb=1,vb={mouseenter:"mouseover",mouseleave:"mouseout"},Gl=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function Ob(i,t){return t&&`${t}::${cb++}`||i.uidEvent||cb++}function Jb(i){let t=Ob(i);return i.uidEvent=t,Ei[t]=Ei[t]||{},Ei[t]}function Bl(i,t){return function c(e){return ge(e,{delegateTarget:i}),c.oneOff&&m.off(i,e.type,t),t.apply(i,[e])}}function Wl(i,t,c){return function e(b){let o=i.querySelectorAll(t);for(let{target:l}=b;l&&l!==this;l=l.parentNode)for(let a of o)if(a===l)return ge(b,{delegateTarget:l}),e.oneOff&&m.off(i,b.type,t,c),c.apply(l,[b])}}function Lb(i,t,c=null){return Object.values(i).find(e=>e.callable===t&&e.delegationSelector===c)}function Nb(i,t,c){let e=typeof t=="string",b=e?c:t||c,o=wb(i);return Gl.has(o)||(o=i),[e,b,o]}function ib(i,t,c,e,b){if(typeof t!="string"||!i)return;let[o,l,a]=Nb(t,c,e);t in vb&&(l=(F=>function(r){if(!r.relatedTarget||r.relatedTarget!==r.delegateTarget&&!r.delegateTarget.contains(r.relatedTarget))return F.call(this,r)})(l));let I=Jb(i),d=I[a]||(I[a]={}),n=Lb(d,l,o?c:null);if(n){n.oneOff=n.oneOff&&b;return}let s=Ob(l,t.replace(Zl,"")),C=o?Wl(i,c,l):Bl(i,l);C.delegationSelector=o?c:null,C.callable=l,C.oneOff=b,C.uidEvent=s,d[s]=C,i.addEventListener(a,C,o)}function le(i,t,c,e,b){let o=Lb(t[c],e,b);o&&(i.removeEventListener(c,o,!!b),delete t[c][o.uidEvent])}function ul(i,t,c,e){let b=t[c]||{};for(let[o,l]of Object.entries(b))o.includes(e)&&le(i,t,c,l.callable,l.delegationSelector)}function wb(i){return i=i.replace(Xl,""),vb[i]||i}var m={on(i,t,c,e){ib(i,t,c,e,!1)},one(i,t,c,e){ib(i,t,c,e,!0)},off(i,t,c,e){if(typeof t!="string"||!i)return;let[b,o,l]=Nb(t,c,e),a=l!==t,I=Jb(i),d=I[l]||{},n=t.startsWith(".");if(typeof o<"u"){if(!Object.keys(d).length)return;le(i,I,l,o,b?c:null);return}if(n)for(let s of Object.keys(I))ul(i,I,s,t.slice(1));for(let[s,C]of Object.entries(d)){let g=s.replace(Cl,"");(!a||t.includes(g))&&le(i,I,l,C.callable,C.delegationSelector)}},trigger(i,t,c){if(typeof t!="string"||!i)return null;let e=yb(),b=wb(t),o=t!==b,l=null,a=!0,I=!0,d=!1;o&&e&&(l=e.Event(t,c),e(i).trigger(l),a=!l.isPropagationStopped(),I=!l.isImmediatePropagationStopped(),d=l.isDefaultPrevented());let n=ge(new Event(t,{bubbles:a,cancelable:!0}),c);return d&&n.preventDefault(),I&&i.dispatchEvent(n),n.defaultPrevented&&l&&l.preventDefault(),n}};function ge(i,t={}){for(let[c,e]of Object.entries(t))try{i[c]=e}catch{Object.defineProperty(i,c,{configurable:!0,get(){return e}})}return i}function eb(i){if(i==="true")return!0;if(i==="false")return!1;if(i===Number(i).toString())return Number(i);if(i===""||i==="null")return null;if(typeof i!="string")return i;try{return JSON.parse(decodeURIComponent(i))}catch{return i}}function Di(i){return i.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`)}var mt={setDataAttribute(i,t,c){i.setAttribute(`data-bs-${Di(t)}`,c)},removeDataAttribute(i,t){i.removeAttribute(`data-bs-${Di(t)}`)},getDataAttributes(i){if(!i)return{};let t={},c=Object.keys(i.dataset).filter(e=>e.startsWith("bs")&&!e.startsWith("bsConfig"));for(let e of c){let b=e.replace(/^bs/,"");b=b.charAt(0).toLowerCase()+b.slice(1,b.length),t[b]=eb(i.dataset[e])}return t},getDataAttribute(i,t){return eb(i.getAttribute(`data-bs-${Di(t)}`))}},Ht=class{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(t){return t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t}_mergeConfigObj(t,c){let e=rt(c)?mt.getDataAttribute(c,"config"):{};return{...this.constructor.Default,...typeof e=="object"?e:{},...rt(c)?mt.getDataAttributes(c):{},...typeof t=="object"?t:{}}}_typeCheckConfig(t,c=this.constructor.DefaultType){for(let[e,b]of Object.entries(c)){let o=t[e],l=rt(o)?"element":sl(o);if(!new RegExp(b).test(l))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${e}" provided type "${l}" but expected type "${b}".`)}}},Rl="5.3.2",K=class extends Ht{constructor(t,c){super(),t=Bt(t),t&&(this._element=t,this._config=this._getConfig(c),Hi.set(this._element,this.constructor.DATA_KEY,this))}dispose(){Hi.remove(this._element,this.constructor.DATA_KEY),m.off(this._element,this.constructor.EVENT_KEY);for(let t of Object.getOwnPropertyNames(this))this[t]=null}_queueCallback(t,c,e=!0){Yb(t,c,e)}_getConfig(t){return t=this._mergeConfigObj(t,this._element),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}static getInstance(t){return Hi.get(Bt(t),this.DATA_KEY)}static getOrCreateInstance(t,c={}){return this.getInstance(t)||new this(t,typeof c=="object"?c:null)}static get VERSION(){return Rl}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(t){return`${t}${this.EVENT_KEY}`}},Mi=i=>{let t=i.getAttribute("data-bs-target");if(!t||t==="#"){let c=i.getAttribute("href");if(!c||!c.includes("#")&&!c.startsWith("."))return null;c.includes("#")&&!c.startsWith("#")&&(c=`#${c.split("#")[1]}`),t=c&&c!=="#"?Ab(c.trim()):null}return t},W={find(i,t=document.documentElement){return[].concat(...Element.prototype.querySelectorAll.call(t,i))},findOne(i,t=document.documentElement){return Element.prototype.querySelector.call(t,i)},children(i,t){return[].concat(...i.children).filter(c=>c.matches(t))},parents(i,t){let c=[],e=i.parentNode.closest(t);for(;e;)c.push(e),e=e.parentNode.closest(t);return c},prev(i,t){let c=i.previousElementSibling;for(;c;){if(c.matches(t))return[c];c=c.previousElementSibling}return[]},next(i,t){let c=i.nextElementSibling;for(;c;){if(c.matches(t))return[c];c=c.nextElementSibling}return[]},focusableChildren(i){let t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map(c=>`${c}:not([tabindex^="-"])`).join(",");return this.find(t,i).filter(c=>!Wt(c)&&rc(c))},getSelectorFromElement(i){let t=Mi(i);return t&&W.findOne(t)?t:null},getElementFromSelector(i){let t=Mi(i);return t?W.findOne(t):null},getMultipleElementsFromSelector(i){let t=Mi(i);return t?W.find(t):[]}},Bi=(i,t="hide")=>{let c=`click.dismiss${i.EVENT_KEY}`,e=i.NAME;m.on(document,c,`[data-bs-dismiss="${e}"]`,function(b){if(["A","AREA"].includes(this.tagName)&&b.preventDefault(),Wt(this))return;let o=W.getElementFromSelector(this)||this.closest(`.${e}`);i.getOrCreateInstance(o)[t]()})},xl="alert",Ql="bs.alert",kb=`.${Ql}`,pl=`close${kb}`,hl=`closed${kb}`,Vl="fade",Al="show",gi=class i extends K{static get NAME(){return xl}close(){if(m.trigger(this._element,pl).defaultPrevented)return;this._element.classList.remove(Al);let c=this._element.classList.contains(Vl);this._queueCallback(()=>this._destroyElement(),this._element,c)}_destroyElement(){this._element.remove(),m.trigger(this._element,hl),this.dispose()}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this);if(typeof t=="string"){if(c[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);c[t](this)}})}};Bi(gi,"close");ct(gi);var Ul="button",fl="bs.button",yl=`.${fl}`,Yl=".data-api",vl="active",bb='[data-bs-toggle="button"]',Ol=`click${yl}${Yl}`,si=class i extends K{static get NAME(){return Ul}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle(vl))}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this);t==="toggle"&&c[t]()})}};m.on(document,Ol,bb,i=>{i.preventDefault();let t=i.target.closest(bb);si.getOrCreateInstance(t).toggle()});ct(si);var Jl="swipe",mc=".bs.swipe",Ll=`touchstart${mc}`,Nl=`touchmove${mc}`,wl=`touchend${mc}`,kl=`pointerdown${mc}`,zl=`pointerup${mc}`,jl="touch",Sl="pen",Hl="pointer-event",Tl=40,El={endCallback:null,leftCallback:null,rightCallback:null},Dl={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"},ri=class i extends Ht{constructor(t,c){super(),this._element=t,!(!t||!i.isSupported())&&(this._config=this._getConfig(c),this._deltaX=0,this._supportPointerEvents=!!window.PointerEvent,this._initEvents())}static get Default(){return El}static get DefaultType(){return Dl}static get NAME(){return Jl}dispose(){m.off(this._element,mc)}_start(t){if(!this._supportPointerEvents){this._deltaX=t.touches[0].clientX;return}this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX)}_end(t){this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX-this._deltaX),this._handleSwipe(),E(this._config.endCallback)}_move(t){this._deltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this._deltaX}_handleSwipe(){let t=Math.abs(this._deltaX);if(t<=Tl)return;let c=t/this._deltaX;this._deltaX=0,c&&E(c>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(m.on(this._element,kl,t=>this._start(t)),m.on(this._element,zl,t=>this._end(t)),this._element.classList.add(Hl)):(m.on(this._element,Ll,t=>this._start(t)),m.on(this._element,Nl,t=>this._move(t)),m.on(this._element,wl,t=>this._end(t)))}_eventIsPointerPenTouch(t){return this._supportPointerEvents&&(t.pointerType===Sl||t.pointerType===jl)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}},Ml="carousel",Kl="bs.carousel",xt=`.${Kl}`,zb=".data-api",_l="ArrowLeft",Pl="ArrowRight",$l=500,Ac="next",lc="prev",ac="left",ai="right",ql=`slide${xt}`,Ki=`slid${xt}`,tI=`keydown${xt}`,cI=`mouseenter${xt}`,iI=`mouseleave${xt}`,eI=`dragstart${xt}`,bI=`load${xt}${zb}`,oI=`click${xt}${zb}`,jb="carousel",ii="active",lI="slide",II="carousel-item-end",aI="carousel-item-start",nI="carousel-item-next",dI="carousel-item-prev",Sb=".active",Hb=".carousel-item",gI=Sb+Hb,sI=".carousel-item img",rI=".carousel-indicators",mI="[data-bs-slide], [data-bs-slide-to]",FI='[data-bs-ride="carousel"]',ZI={[_l]:ai,[Pl]:ac},XI={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},CI={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"},fc=class i extends K{constructor(t,c){super(t,c),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=W.findOne(rI,this._element),this._addEventListeners(),this._config.ride===jb&&this.cycle()}static get Default(){return XI}static get DefaultType(){return CI}static get NAME(){return Ml}next(){this._slide(Ac)}nextWhenVisible(){!document.hidden&&rc(this._element)&&this.next()}prev(){this._slide(lc)}pause(){this._isSliding&&Ub(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval(()=>this.nextWhenVisible(),this._config.interval)}_maybeEnableCycle(){if(this._config.ride){if(this._isSliding){m.one(this._element,Ki,()=>this.cycle());return}this.cycle()}}to(t){let c=this._getItems();if(t>c.length-1||t<0)return;if(this._isSliding){m.one(this._element,Ki,()=>this.to(t));return}let e=this._getItemIndex(this._getActive());if(e===t)return;let b=t>e?Ac:lc;this._slide(b,c[t])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(t){return t.defaultInterval=t.interval,t}_addEventListeners(){this._config.keyboard&&m.on(this._element,tI,t=>this._keydown(t)),this._config.pause==="hover"&&(m.on(this._element,cI,()=>this.pause()),m.on(this._element,iI,()=>this._maybeEnableCycle())),this._config.touch&&ri.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(let e of W.find(sI,this._element))m.on(e,eI,b=>b.preventDefault());let c={leftCallback:()=>this._slide(this._directionToOrder(ac)),rightCallback:()=>this._slide(this._directionToOrder(ai)),endCallback:()=>{this._config.pause==="hover"&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout(()=>this._maybeEnableCycle(),$l+this._config.interval))}};this._swipeHelper=new ri(this._element,c)}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;let c=ZI[t.key];c&&(t.preventDefault(),this._slide(this._directionToOrder(c)))}_getItemIndex(t){return this._getItems().indexOf(t)}_setActiveIndicatorElement(t){if(!this._indicatorsElement)return;let c=W.findOne(Sb,this._indicatorsElement);c.classList.remove(ii),c.removeAttribute("aria-current");let e=W.findOne(`[data-bs-slide-to="${t}"]`,this._indicatorsElement);e&&(e.classList.add(ii),e.setAttribute("aria-current","true"))}_updateInterval(){let t=this._activeElement||this._getActive();if(!t)return;let c=Number.parseInt(t.getAttribute("data-bs-interval"),10);this._config.interval=c||this._config.defaultInterval}_slide(t,c=null){if(this._isSliding)return;let e=this._getActive(),b=t===Ac,o=c||de(this._getItems(),e,b,this._config.wrap);if(o===e)return;let l=this._getItemIndex(o),a=g=>m.trigger(this._element,g,{relatedTarget:o,direction:this._orderToDirection(t),from:this._getItemIndex(e),to:l});if(a(ql).defaultPrevented||!e||!o)return;let d=!!this._interval;this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(l),this._activeElement=o;let n=b?aI:II,s=b?nI:dI;o.classList.add(s),vc(o),e.classList.add(n),o.classList.add(n);let C=()=>{o.classList.remove(n,s),o.classList.add(ii),e.classList.remove(ii,s,n),this._isSliding=!1,a(Ki)};this._queueCallback(C,e,this._isAnimated()),d&&this.cycle()}_isAnimated(){return this._element.classList.contains(lI)}_getActive(){return W.findOne(gI,this._element)}_getItems(){return W.find(Hb,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(t){return q()?t===ac?lc:Ac:t===ac?Ac:lc}_orderToDirection(t){return q()?t===lc?ac:ai:t===lc?ai:ac}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this,t);if(typeof t=="number"){c.to(t);return}if(typeof t=="string"){if(c[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);c[t]()}})}};m.on(document,oI,mI,function(i){let t=W.getElementFromSelector(this);if(!t||!t.classList.contains(jb))return;i.preventDefault();let c=fc.getOrCreateInstance(t),e=this.getAttribute("data-bs-slide-to");if(e){c.to(e),c._maybeEnableCycle();return}if(mt.getDataAttribute(this,"slide")==="next"){c.next(),c._maybeEnableCycle();return}c.prev(),c._maybeEnableCycle()});m.on(window,bI,()=>{let i=W.find(FI);for(let t of i)fc.getOrCreateInstance(t)});ct(fc);var GI="collapse",BI="bs.collapse",Oc=`.${BI}`,WI=".data-api",uI=`show${Oc}`,RI=`shown${Oc}`,xI=`hide${Oc}`,QI=`hidden${Oc}`,pI=`click${Oc}${WI}`,_i="show",dc="collapse",ei="collapsing",hI="collapsed",VI=`:scope .${dc} .${dc}`,AI="collapse-horizontal",UI="width",fI="height",yI=".collapse.show, .collapse.collapsing",Ie='[data-bs-toggle="collapse"]',YI={parent:null,toggle:!0},vI={parent:"(null|element)",toggle:"boolean"},mi=class i extends K{constructor(t,c){super(t,c),this._isTransitioning=!1,this._triggerArray=[];let e=W.find(Ie);for(let b of e){let o=W.getSelectorFromElement(b),l=W.find(o).filter(a=>a===this._element);o!==null&&l.length&&this._triggerArray.push(b)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return YI}static get DefaultType(){return vI}static get NAME(){return GI}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t=[];if(this._config.parent&&(t=this._getFirstLevelChildren(yI).filter(a=>a!==this._element).map(a=>i.getOrCreateInstance(a,{toggle:!1}))),t.length&&t[0]._isTransitioning||m.trigger(this._element,uI).defaultPrevented)return;for(let a of t)a.hide();let e=this._getDimension();this._element.classList.remove(dc),this._element.classList.add(ei),this._element.style[e]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;let b=()=>{this._isTransitioning=!1,this._element.classList.remove(ei),this._element.classList.add(dc,_i),this._element.style[e]="",m.trigger(this._element,RI)},l=`scroll${e[0].toUpperCase()+e.slice(1)}`;this._queueCallback(b,this._element,!0),this._element.style[e]=`${this._element[l]}px`}hide(){if(this._isTransitioning||!this._isShown()||m.trigger(this._element,xI).defaultPrevented)return;let c=this._getDimension();this._element.style[c]=`${this._element.getBoundingClientRect()[c]}px`,vc(this._element),this._element.classList.add(ei),this._element.classList.remove(dc,_i);for(let b of this._triggerArray){let o=W.getElementFromSelector(b);o&&!this._isShown(o)&&this._addAriaAndCollapsedClass([b],!1)}this._isTransitioning=!0;let e=()=>{this._isTransitioning=!1,this._element.classList.remove(ei),this._element.classList.add(dc),m.trigger(this._element,QI)};this._element.style[c]="",this._queueCallback(e,this._element,!0)}_isShown(t=this._element){return t.classList.contains(_i)}_configAfterMerge(t){return t.toggle=!!t.toggle,t.parent=Bt(t.parent),t}_getDimension(){return this._element.classList.contains(AI)?UI:fI}_initializeChildren(){if(!this._config.parent)return;let t=this._getFirstLevelChildren(Ie);for(let c of t){let e=W.getElementFromSelector(c);e&&this._addAriaAndCollapsedClass([c],this._isShown(e))}}_getFirstLevelChildren(t){let c=W.find(VI,this._config.parent);return W.find(t,this._config.parent).filter(e=>!c.includes(e))}_addAriaAndCollapsedClass(t,c){if(t.length)for(let e of t)e.classList.toggle(hI,!c),e.setAttribute("aria-expanded",c)}static jQueryInterface(t){let c={};return typeof t=="string"&&/show|hide/.test(t)&&(c.toggle=!1),this.each(function(){let e=i.getOrCreateInstance(this,c);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t]()}})}};m.on(document,pI,Ie,function(i){(i.target.tagName==="A"||i.delegateTarget&&i.delegateTarget.tagName==="A")&&i.preventDefault();for(let t of W.getMultipleElementsFromSelector(this))mi.getOrCreateInstance(t,{toggle:!1}).toggle()});ct(mi);var ob="dropdown",OI="bs.dropdown",Tt=`.${OI}`,se=".data-api",JI="Escape",lb="Tab",LI="ArrowUp",Ib="ArrowDown",NI=2,wI=`hide${Tt}`,kI=`hidden${Tt}`,zI=`show${Tt}`,jI=`shown${Tt}`,Tb=`click${Tt}${se}`,Eb=`keydown${Tt}${se}`,SI=`keyup${Tt}${se}`,nc="show",HI="dropup",TI="dropend",EI="dropstart",DI="dropup-center",MI="dropdown-center",jt='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',KI=`${jt}.${nc}`,ni=".dropdown-menu",_I=".navbar",PI=".navbar-nav",$I=".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",qI=q()?"top-end":"top-start",ta=q()?"top-start":"top-end",ca=q()?"bottom-end":"bottom-start",ia=q()?"bottom-start":"bottom-end",ea=q()?"left-start":"right-start",ba=q()?"right-start":"left-start",oa="top",la="bottom",Ia={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},aa={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"},ut=class i extends K{constructor(t,c){super(t,c),this._popper=null,this._parent=this._element.parentNode,this._menu=W.next(this._element,ni)[0]||W.prev(this._element,ni)[0]||W.findOne(ni,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return Ia}static get DefaultType(){return aa}static get NAME(){return ob}toggle(){return this._isShown()?this.hide():this.show()}show(){if(Wt(this._element)||this._isShown())return;let t={relatedTarget:this._element};if(!m.trigger(this._element,zI,t).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(PI))for(let e of[].concat(...document.body.children))m.on(e,"mouseover",di);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(nc),this._element.classList.add(nc),m.trigger(this._element,jI,t)}}hide(){if(Wt(this._element)||!this._isShown())return;let t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){if(!m.trigger(this._element,wI,t).defaultPrevented){if("ontouchstart"in document.documentElement)for(let e of[].concat(...document.body.children))m.off(e,"mouseover",di);this._popper&&this._popper.destroy(),this._menu.classList.remove(nc),this._element.classList.remove(nc),this._element.setAttribute("aria-expanded","false"),mt.removeDataAttribute(this._menu,"popper"),m.trigger(this._element,kI,t)}}_getConfig(t){if(t=super._getConfig(t),typeof t.reference=="object"&&!rt(t.reference)&&typeof t.reference.getBoundingClientRect!="function")throw new TypeError(`${ob.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return t}_createPopper(){if(typeof ci>"u")throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let t=this._element;this._config.reference==="parent"?t=this._parent:rt(this._config.reference)?t=Bt(this._config.reference):typeof this._config.reference=="object"&&(t=this._config.reference);let c=this._getPopperConfig();this._popper=Vc(t,this._menu,c)}_isShown(){return this._menu.classList.contains(nc)}_getPlacement(){let t=this._parent;if(t.classList.contains(TI))return ea;if(t.classList.contains(EI))return ba;if(t.classList.contains(DI))return oa;if(t.classList.contains(MI))return la;let c=getComputedStyle(this._menu).getPropertyValue("--bs-position").trim()==="end";return t.classList.contains(HI)?c?ta:qI:c?ia:ca}_detectNavbar(){return this._element.closest(_I)!==null}_getOffset(){let{offset:t}=this._config;return typeof t=="string"?t.split(",").map(c=>Number.parseInt(c,10)):typeof t=="function"?c=>t(c,this._element):t}_getPopperConfig(){let t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||this._config.display==="static")&&(mt.setDataAttribute(this._menu,"popper","static"),t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,...E(this._config.popperConfig,[t])}}_selectMenuItem({key:t,target:c}){let e=W.find($I,this._menu).filter(b=>rc(b));e.length&&de(e,c,t===Ib,!e.includes(c)).focus()}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof c[t]>"u")throw new TypeError(`No method named "${t}"`);c[t]()}})}static clearMenus(t){if(t.button===NI||t.type==="keyup"&&t.key!==lb)return;let c=W.find(KI);for(let e of c){let b=i.getInstance(e);if(!b||b._config.autoClose===!1)continue;let o=t.composedPath(),l=o.includes(b._menu);if(o.includes(b._element)||b._config.autoClose==="inside"&&!l||b._config.autoClose==="outside"&&l||b._menu.contains(t.target)&&(t.type==="keyup"&&t.key===lb||/input|select|option|textarea|form/i.test(t.target.tagName)))continue;let a={relatedTarget:b._element};t.type==="click"&&(a.clickEvent=t),b._completeHide(a)}}static dataApiKeydownHandler(t){let c=/input|textarea/i.test(t.target.tagName),e=t.key===JI,b=[LI,Ib].includes(t.key);if(!b&&!e||c&&!e)return;t.preventDefault();let o=this.matches(jt)?this:W.prev(this,jt)[0]||W.next(this,jt)[0]||W.findOne(jt,t.delegateTarget.parentNode),l=i.getOrCreateInstance(o);if(b){t.stopPropagation(),l.show(),l._selectMenuItem(t);return}l._isShown()&&(t.stopPropagation(),l.hide(),o.focus())}};m.on(document,Eb,jt,ut.dataApiKeydownHandler);m.on(document,Eb,ni,ut.dataApiKeydownHandler);m.on(document,Tb,ut.clearMenus);m.on(document,SI,ut.clearMenus);m.on(document,Tb,jt,function(i){i.preventDefault(),ut.getOrCreateInstance(this).toggle()});ct(ut);var Db="backdrop",na="fade",ab="show",nb=`mousedown.bs.${Db}`,da={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},ga={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"},Fi=class extends Ht{constructor(t){super(),this._config=this._getConfig(t),this._isAppended=!1,this._element=null}static get Default(){return da}static get DefaultType(){return ga}static get NAME(){return Db}show(t){if(!this._config.isVisible){E(t);return}this._append();let c=this._getElement();this._config.isAnimated&&vc(c),c.classList.add(ab),this._emulateAnimation(()=>{E(t)})}hide(t){if(!this._config.isVisible){E(t);return}this._getElement().classList.remove(ab),this._emulateAnimation(()=>{this.dispose(),E(t)})}dispose(){this._isAppended&&(m.off(this._element,nb),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){let t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add(na),this._element=t}return this._element}_configAfterMerge(t){return t.rootElement=Bt(t.rootElement),t}_append(){if(this._isAppended)return;let t=this._getElement();this._config.rootElement.append(t),m.on(t,nb,()=>{E(this._config.clickCallback)}),this._isAppended=!0}_emulateAnimation(t){Yb(t,this._getElement(),this._config.isAnimated)}},sa="focustrap",ra="bs.focustrap",Zi=`.${ra}`,ma=`focusin${Zi}`,Fa=`keydown.tab${Zi}`,Za="Tab",Xa="forward",db="backward",Ca={autofocus:!0,trapElement:null},Ga={autofocus:"boolean",trapElement:"element"},Xi=class extends Ht{constructor(t){super(),this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return Ca}static get DefaultType(){return Ga}static get NAME(){return sa}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),m.off(document,Zi),m.on(document,ma,t=>this._handleFocusin(t)),m.on(document,Fa,t=>this._handleKeydown(t)),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,m.off(document,Zi))}_handleFocusin(t){let{trapElement:c}=this._config;if(t.target===document||t.target===c||c.contains(t.target))return;let e=W.focusableChildren(c);e.length===0?c.focus():this._lastTabNavDirection===db?e[e.length-1].focus():e[0].focus()}_handleKeydown(t){t.key===Za&&(this._lastTabNavDirection=t.shiftKey?db:Xa)}},gb=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",sb=".sticky-top",bi="padding-right",rb="margin-right",yc=class{constructor(){this._element=document.body}getWidth(){let t=document.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}hide(){let t=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,bi,c=>c+t),this._setElementAttributes(gb,bi,c=>c+t),this._setElementAttributes(sb,rb,c=>c-t)}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,bi),this._resetElementAttributes(gb,bi),this._resetElementAttributes(sb,rb)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,c,e){let b=this.getWidth(),o=l=>{if(l!==this._element&&window.innerWidth>l.clientWidth+b)return;this._saveInitialAttribute(l,c);let a=window.getComputedStyle(l).getPropertyValue(c);l.style.setProperty(c,`${e(Number.parseFloat(a))}px`)};this._applyManipulationCallback(t,o)}_saveInitialAttribute(t,c){let e=t.style.getPropertyValue(c);e&&mt.setDataAttribute(t,c,e)}_resetElementAttributes(t,c){let e=b=>{let o=mt.getDataAttribute(b,c);if(o===null){b.style.removeProperty(c);return}mt.removeDataAttribute(b,c),b.style.setProperty(c,o)};this._applyManipulationCallback(t,e)}_applyManipulationCallback(t,c){if(rt(t)){c(t);return}for(let e of W.find(t,this._element))c(e)}},Ba="modal",Wa="bs.modal",tt=`.${Wa}`,ua=".data-api",Ra="Escape",xa=`hide${tt}`,Qa=`hidePrevented${tt}`,Mb=`hidden${tt}`,Kb=`show${tt}`,pa=`shown${tt}`,ha=`resize${tt}`,Va=`click.dismiss${tt}`,Aa=`mousedown.dismiss${tt}`,Ua=`keydown.dismiss${tt}`,fa=`click${tt}${ua}`,mb="modal-open",ya="fade",Fb="show",Pi="modal-static",Ya=".modal.show",va=".modal-dialog",Oa=".modal-body",Ja='[data-bs-toggle="modal"]',La={backdrop:!0,focus:!0,keyboard:!0},Na={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"},gc=class i extends K{constructor(t,c){super(t,c),this._dialog=W.findOne(va,this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new yc,this._addEventListeners()}static get Default(){return La}static get DefaultType(){return Na}static get NAME(){return Ba}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||m.trigger(this._element,Kb,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(mb),this._adjustDialog(),this._backdrop.show(()=>this._showElement(t)))}hide(){!this._isShown||this._isTransitioning||m.trigger(this._element,xa).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(Fb),this._queueCallback(()=>this._hideModal(),this._element,this._isAnimated()))}dispose(){m.off(window,tt),m.off(this._dialog,tt),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Fi({isVisible:!!this._config.backdrop,isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new Xi({trapElement:this._element})}_showElement(t){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;let c=W.findOne(Oa,this._dialog);c&&(c.scrollTop=0),vc(this._element),this._element.classList.add(Fb);let e=()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,m.trigger(this._element,pa,{relatedTarget:t})};this._queueCallback(e,this._dialog,this._isAnimated())}_addEventListeners(){m.on(this._element,Ua,t=>{if(t.key===Ra){if(this._config.keyboard){this.hide();return}this._triggerBackdropTransition()}}),m.on(window,ha,()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()}),m.on(this._element,Aa,t=>{m.one(this._element,Va,c=>{if(!(this._element!==t.target||this._element!==c.target)){if(this._config.backdrop==="static"){this._triggerBackdropTransition();return}this._config.backdrop&&this.hide()}})})}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide(()=>{document.body.classList.remove(mb),this._resetAdjustments(),this._scrollBar.reset(),m.trigger(this._element,Mb)})}_isAnimated(){return this._element.classList.contains(ya)}_triggerBackdropTransition(){if(m.trigger(this._element,Qa).defaultPrevented)return;let c=this._element.scrollHeight>document.documentElement.clientHeight,e=this._element.style.overflowY;e==="hidden"||this._element.classList.contains(Pi)||(c||(this._element.style.overflowY="hidden"),this._element.classList.add(Pi),this._queueCallback(()=>{this._element.classList.remove(Pi),this._queueCallback(()=>{this._element.style.overflowY=e},this._dialog)},this._dialog),this._element.focus())}_adjustDialog(){let t=this._element.scrollHeight>document.documentElement.clientHeight,c=this._scrollBar.getWidth(),e=c>0;if(e&&!t){let b=q()?"paddingLeft":"paddingRight";this._element.style[b]=`${c}px`}if(!e&&t){let b=q()?"paddingRight":"paddingLeft";this._element.style[b]=`${c}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,c){return this.each(function(){let e=i.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t](c)}})}};m.on(document,fa,Ja,function(i){let t=W.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&i.preventDefault(),m.one(t,Kb,b=>{b.defaultPrevented||m.one(t,Mb,()=>{rc(this)&&this.focus()})});let c=W.findOne(Ya);c&&gc.getInstance(c).hide(),gc.getOrCreateInstance(t).toggle(this)});Bi(gc);ct(gc);var wa="offcanvas",ka="bs.offcanvas",Ft=`.${ka}`,_b=".data-api",za=`load${Ft}${_b}`,ja="Escape",Zb="show",Xb="showing",Cb="hiding",Sa="offcanvas-backdrop",Pb=".offcanvas.show",Ha=`show${Ft}`,Ta=`shown${Ft}`,Ea=`hide${Ft}`,Gb=`hidePrevented${Ft}`,$b=`hidden${Ft}`,Da=`resize${Ft}`,Ma=`click${Ft}${_b}`,Ka=`keydown.dismiss${Ft}`,_a='[data-bs-toggle="offcanvas"]',Pa={backdrop:!0,keyboard:!0,scroll:!1},$a={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"},Rt=class i extends K{constructor(t,c){super(t,c),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return Pa}static get DefaultType(){return $a}static get NAME(){return wa}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){if(this._isShown||m.trigger(this._element,Ha,{relatedTarget:t}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||new yc().hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(Xb);let e=()=>{(!this._config.scroll||this._config.backdrop)&&this._focustrap.activate(),this._element.classList.add(Zb),this._element.classList.remove(Xb),m.trigger(this._element,Ta,{relatedTarget:t})};this._queueCallback(e,this._element,!0)}hide(){if(!this._isShown||m.trigger(this._element,Ea).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(Cb),this._backdrop.hide();let c=()=>{this._element.classList.remove(Zb,Cb),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||new yc().reset(),m.trigger(this._element,$b)};this._queueCallback(c,this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){let t=()=>{if(this._config.backdrop==="static"){m.trigger(this._element,Gb);return}this.hide()},c=!!this._config.backdrop;return new Fi({className:Sa,isVisible:c,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:c?t:null})}_initializeFocusTrap(){return new Xi({trapElement:this._element})}_addEventListeners(){m.on(this._element,Ka,t=>{if(t.key===ja){if(this._config.keyboard){this.hide();return}m.trigger(this._element,Gb)}})}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this,t);if(typeof t=="string"){if(c[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);c[t](this)}})}};m.on(document,Ma,_a,function(i){let t=W.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),Wt(this))return;m.one(t,$b,()=>{rc(this)&&this.focus()});let c=W.findOne(Pb);c&&c!==t&&Rt.getInstance(c).hide(),Rt.getOrCreateInstance(t).toggle(this)});m.on(window,za,()=>{for(let i of W.find(Pb))Rt.getOrCreateInstance(i).show()});m.on(window,Da,()=>{for(let i of W.find("[aria-modal][class*=show][class*=offcanvas-]"))getComputedStyle(i).position!=="fixed"&&Rt.getOrCreateInstance(i).hide()});Bi(Rt);ct(Rt);var qa=/^aria-[\w-]*$/i,qb={"*":["class","dir","id","lang","role",qa],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},tn=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),cn=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,en=(i,t)=>{let c=i.nodeName.toLowerCase();return t.includes(c)?tn.has(c)?!!cn.test(i.nodeValue):!0:t.filter(e=>e instanceof RegExp).some(e=>e.test(c))};function bn(i,t,c){if(!i.length)return i;if(c&&typeof c=="function")return c(i);let b=new window.DOMParser().parseFromString(i,"text/html"),o=[].concat(...b.body.querySelectorAll("*"));for(let l of o){let a=l.nodeName.toLowerCase();if(!Object.keys(t).includes(a)){l.remove();continue}let I=[].concat(...l.attributes),d=[].concat(t["*"]||[],t[a]||[]);for(let n of I)en(n,d)||l.removeAttribute(n.nodeName)}return b.body.innerHTML}var on="TemplateFactory",ln={allowList:qb,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"
      "},In={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},an={entry:"(string|element|function|null)",selector:"(string|element)"},ae=class extends Ht{constructor(t){super(),this._config=this._getConfig(t)}static get Default(){return ln}static get DefaultType(){return In}static get NAME(){return on}getContent(){return Object.values(this._config.content).map(t=>this._resolvePossibleFunction(t)).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(t){return this._checkContent(t),this._config.content={...this._config.content,...t},this}toHtml(){let t=document.createElement("div");t.innerHTML=this._maybeSanitize(this._config.template);for(let[b,o]of Object.entries(this._config.content))this._setContent(t,o,b);let c=t.children[0],e=this._resolvePossibleFunction(this._config.extraClass);return e&&c.classList.add(...e.split(" ")),c}_typeCheckConfig(t){super._typeCheckConfig(t),this._checkContent(t.content)}_checkContent(t){for(let[c,e]of Object.entries(t))super._typeCheckConfig({selector:c,entry:e},an)}_setContent(t,c,e){let b=W.findOne(e,t);if(b){if(c=this._resolvePossibleFunction(c),!c){b.remove();return}if(rt(c)){this._putElementInTemplate(Bt(c),b);return}if(this._config.html){b.innerHTML=this._maybeSanitize(c);return}b.textContent=c}}_maybeSanitize(t){return this._config.sanitize?bn(t,this._config.allowList,this._config.sanitizeFn):t}_resolvePossibleFunction(t){return E(t,[this])}_putElementInTemplate(t,c){if(this._config.html){c.innerHTML="",c.append(t);return}c.textContent=t.textContent}},nn="tooltip",dn=new Set(["sanitize","allowList","sanitizeFn"]),$i="fade",gn="modal",oi="show",sn=".tooltip-inner",Bb=`.${gn}`,Wb="hide.bs.modal",Uc="hover",qi="focus",rn="click",mn="manual",Fn="hide",Zn="hidden",Xn="show",Cn="shown",Gn="inserted",Bn="click",Wn="focusin",un="focusout",Rn="mouseenter",xn="mouseleave",Qn={AUTO:"auto",TOP:"top",RIGHT:q()?"left":"right",BOTTOM:"bottom",LEFT:q()?"right":"left"},pn={allowList:qb,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,6],placement:"top",popperConfig:null,sanitize:!0,sanitizeFn:null,selector:!1,template:'',title:"",trigger:"hover focus"},hn={allowList:"object",animation:"boolean",boundary:"(string|element)",container:"(string|element|boolean)",customClass:"(string|function)",delay:"(number|object)",fallbackPlacements:"array",html:"boolean",offset:"(array|string|function)",placement:"(string|function)",popperConfig:"(null|object|function)",sanitize:"boolean",sanitizeFn:"(null|function)",selector:"(string|boolean)",template:"string",title:"(string|element|function)",trigger:"string"},sc=class i extends K{constructor(t,c){if(typeof ci>"u")throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(t,c),this._isEnabled=!0,this._timeout=0,this._isHovered=null,this._activeTrigger={},this._popper=null,this._templateFactory=null,this._newContent=null,this.tip=null,this._setListeners(),this._config.selector||this._fixTitle()}static get Default(){return pn}static get DefaultType(){return hn}static get NAME(){return nn}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){if(this._isEnabled){if(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()){this._leave();return}this._enter()}}dispose(){clearTimeout(this._timeout),m.off(this._element.closest(Bb),Wb,this._hideModalHandler),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if(this._element.style.display==="none")throw new Error("Please use show on visible elements");if(!(this._isWithContent()&&this._isEnabled))return;let t=m.trigger(this._element,this.constructor.eventName(Xn)),e=(fb(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(t.defaultPrevented||!e)return;this._disposePopper();let b=this._getTipElement();this._element.setAttribute("aria-describedby",b.getAttribute("id"));let{container:o}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(o.append(b),m.trigger(this._element,this.constructor.eventName(Gn))),this._popper=this._createPopper(b),b.classList.add(oi),"ontouchstart"in document.documentElement)for(let a of[].concat(...document.body.children))m.on(a,"mouseover",di);let l=()=>{m.trigger(this._element,this.constructor.eventName(Cn)),this._isHovered===!1&&this._leave(),this._isHovered=!1};this._queueCallback(l,this.tip,this._isAnimated())}hide(){if(!this._isShown()||m.trigger(this._element,this.constructor.eventName(Fn)).defaultPrevented)return;if(this._getTipElement().classList.remove(oi),"ontouchstart"in document.documentElement)for(let b of[].concat(...document.body.children))m.off(b,"mouseover",di);this._activeTrigger[rn]=!1,this._activeTrigger[qi]=!1,this._activeTrigger[Uc]=!1,this._isHovered=null;let e=()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),m.trigger(this._element,this.constructor.eventName(Zn)))};this._queueCallback(e,this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return!!this._getTitle()}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(t){let c=this._getTemplateFactory(t).toHtml();if(!c)return null;c.classList.remove($i,oi),c.classList.add(`bs-${this.constructor.NAME}-auto`);let e=rl(this.constructor.NAME).toString();return c.setAttribute("id",e),this._isAnimated()&&c.classList.add($i),c}setContent(t){this._newContent=t,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(t){return this._templateFactory?this._templateFactory.changeContent(t):this._templateFactory=new ae({...this._config,content:t,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{[sn]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(t){return this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains($i)}_isShown(){return this.tip&&this.tip.classList.contains(oi)}_createPopper(t){let c=E(this._config.placement,[this,t,this._element]),e=Qn[c.toUpperCase()];return Vc(this._element,t,this._getPopperConfig(e))}_getOffset(){let{offset:t}=this._config;return typeof t=="string"?t.split(",").map(c=>Number.parseInt(c,10)):typeof t=="function"?c=>t(c,this._element):t}_resolvePossibleFunction(t){return E(t,[this._element])}_getPopperConfig(t){let c={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:e=>{this._getTipElement().setAttribute("data-popper-placement",e.state.placement)}}]};return{...c,...E(this._config.popperConfig,[c])}}_setListeners(){let t=this._config.trigger.split(" ");for(let c of t)if(c==="click")m.on(this._element,this.constructor.eventName(Bn),this._config.selector,e=>{this._initializeOnDelegatedTarget(e).toggle()});else if(c!==mn){let e=c===Uc?this.constructor.eventName(Rn):this.constructor.eventName(Wn),b=c===Uc?this.constructor.eventName(xn):this.constructor.eventName(un);m.on(this._element,e,this._config.selector,o=>{let l=this._initializeOnDelegatedTarget(o);l._activeTrigger[o.type==="focusin"?qi:Uc]=!0,l._enter()}),m.on(this._element,b,this._config.selector,o=>{let l=this._initializeOnDelegatedTarget(o);l._activeTrigger[o.type==="focusout"?qi:Uc]=l._element.contains(o.relatedTarget),l._leave()})}this._hideModalHandler=()=>{this._element&&this.hide()},m.on(this._element.closest(Bb),Wb,this._hideModalHandler)}_fixTitle(){let t=this._element.getAttribute("title");t&&(!this._element.getAttribute("aria-label")&&!this._element.textContent.trim()&&this._element.setAttribute("aria-label",t),this._element.setAttribute("data-bs-original-title",t),this._element.removeAttribute("title"))}_enter(){if(this._isShown()||this._isHovered){this._isHovered=!0;return}this._isHovered=!0,this._setTimeout(()=>{this._isHovered&&this.show()},this._config.delay.show)}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout(()=>{this._isHovered||this.hide()},this._config.delay.hide))}_setTimeout(t,c){clearTimeout(this._timeout),this._timeout=setTimeout(t,c)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(t){let c=mt.getDataAttributes(this._element);for(let e of Object.keys(c))dn.has(e)&&delete c[e];return t={...c,...typeof t=="object"&&t?t:{}},t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t.container=t.container===!1?document.body:Bt(t.container),typeof t.delay=="number"&&(t.delay={show:t.delay,hide:t.delay}),typeof t.title=="number"&&(t.title=t.title.toString()),typeof t.content=="number"&&(t.content=t.content.toString()),t}_getDelegateConfig(){let t={};for(let[c,e]of Object.entries(this._config))this.constructor.Default[c]!==e&&(t[c]=e);return t.selector=!1,t.trigger="manual",t}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof c[t]>"u")throw new TypeError(`No method named "${t}"`);c[t]()}})}};ct(sc);var Vn="popover",An=".popover-header",Un=".popover-body",fn={...sc.Default,content:"",offset:[0,8],placement:"right",template:'',trigger:"click"},yn={...sc.DefaultType,content:"(null|string|element|function)"},ne=class i extends sc{static get Default(){return fn}static get DefaultType(){return yn}static get NAME(){return Vn}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[An]:this._getTitle(),[Un]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof c[t]>"u")throw new TypeError(`No method named "${t}"`);c[t]()}})}};ct(ne);var Yn="scrollspy",vn="bs.scrollspy",re=`.${vn}`,On=".data-api",Jn=`activate${re}`,ub=`click${re}`,Ln=`load${re}${On}`,Nn="dropdown-item",Ic="active",wn='[data-bs-spy="scroll"]',te="[href]",kn=".nav, .list-group",Rb=".nav-link",zn=".nav-item",jn=".list-group-item",Sn=`${Rb}, ${zn} > ${Rb}, ${jn}`,Hn=".dropdown",Tn=".dropdown-toggle",En={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},Dn={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"},Ci=class i extends K{constructor(t,c){super(t,c),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement=getComputedStyle(this._element).overflowY==="visible"?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return En}static get DefaultType(){return Dn}static get NAME(){return Yn}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(let t of this._observableSections.values())this._observer.observe(t)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(t){return t.target=Bt(t.target)||document.body,t.rootMargin=t.offset?`${t.offset}px 0px -30%`:t.rootMargin,typeof t.threshold=="string"&&(t.threshold=t.threshold.split(",").map(c=>Number.parseFloat(c))),t}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(m.off(this._config.target,ub),m.on(this._config.target,ub,te,t=>{let c=this._observableSections.get(t.target.hash);if(c){t.preventDefault();let e=this._rootElement||window,b=c.offsetTop-this._element.offsetTop;if(e.scrollTo){e.scrollTo({top:b,behavior:"smooth"});return}e.scrollTop=b}}))}_getNewObserver(){let t={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver(c=>this._observerCallback(c),t)}_observerCallback(t){let c=l=>this._targetLinks.get(`#${l.target.id}`),e=l=>{this._previousScrollData.visibleEntryTop=l.target.offsetTop,this._process(c(l))},b=(this._rootElement||document.documentElement).scrollTop,o=b>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=b;for(let l of t){if(!l.isIntersecting){this._activeTarget=null,this._clearActiveClass(c(l));continue}let a=l.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(o&&a){if(e(l),!b)return;continue}!o&&!a&&e(l)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;let t=W.find(te,this._config.target);for(let c of t){if(!c.hash||Wt(c))continue;let e=W.findOne(decodeURI(c.hash),this._element);rc(e)&&(this._targetLinks.set(decodeURI(c.hash),c),this._observableSections.set(c.hash,e))}}_process(t){this._activeTarget!==t&&(this._clearActiveClass(this._config.target),this._activeTarget=t,t.classList.add(Ic),this._activateParents(t),m.trigger(this._element,Jn,{relatedTarget:t}))}_activateParents(t){if(t.classList.contains(Nn)){W.findOne(Tn,t.closest(Hn)).classList.add(Ic);return}for(let c of W.parents(t,kn))for(let e of W.prev(c,Sn))e.classList.add(Ic)}_clearActiveClass(t){t.classList.remove(Ic);let c=W.find(`${te}.${Ic}`,t);for(let e of c)e.classList.remove(Ic)}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this,t);if(typeof t=="string"){if(c[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);c[t]()}})}};m.on(window,Ln,()=>{for(let i of W.find(wn))Ci.getOrCreateInstance(i)});ct(Ci);var Mn="tab",Kn="bs.tab",Et=`.${Kn}`,_n=`hide${Et}`,Pn=`hidden${Et}`,$n=`show${Et}`,qn=`shown${Et}`,td=`click${Et}`,cd=`keydown${Et}`,id=`load${Et}`,ed="ArrowLeft",xb="ArrowRight",bd="ArrowUp",Qb="ArrowDown",ce="Home",pb="End",St="active",hb="fade",ie="show",od="dropdown",to=".dropdown-toggle",ld=".dropdown-menu",ee=`:not(${to})`,Id='.list-group, .nav, [role="tablist"]',ad=".nav-item, .list-group-item",nd=`.nav-link${ee}, .list-group-item${ee}, [role="tab"]${ee}`,co='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',be=`${nd}, ${co}`,dd=`.${St}[data-bs-toggle="tab"], .${St}[data-bs-toggle="pill"], .${St}[data-bs-toggle="list"]`,Yc=class i extends K{constructor(t){super(t),this._parent=this._element.closest(Id),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),m.on(this._element,cd,c=>this._keydown(c)))}static get NAME(){return Mn}show(){let t=this._element;if(this._elemIsActive(t))return;let c=this._getActiveElem(),e=c?m.trigger(c,_n,{relatedTarget:t}):null;m.trigger(t,$n,{relatedTarget:c}).defaultPrevented||e&&e.defaultPrevented||(this._deactivate(c,t),this._activate(t,c))}_activate(t,c){if(!t)return;t.classList.add(St),this._activate(W.getElementFromSelector(t));let e=()=>{if(t.getAttribute("role")!=="tab"){t.classList.add(ie);return}t.removeAttribute("tabindex"),t.setAttribute("aria-selected",!0),this._toggleDropDown(t,!0),m.trigger(t,qn,{relatedTarget:c})};this._queueCallback(e,t,t.classList.contains(hb))}_deactivate(t,c){if(!t)return;t.classList.remove(St),t.blur(),this._deactivate(W.getElementFromSelector(t));let e=()=>{if(t.getAttribute("role")!=="tab"){t.classList.remove(ie);return}t.setAttribute("aria-selected",!1),t.setAttribute("tabindex","-1"),this._toggleDropDown(t,!1),m.trigger(t,Pn,{relatedTarget:c})};this._queueCallback(e,t,t.classList.contains(hb))}_keydown(t){if(![ed,xb,bd,Qb,ce,pb].includes(t.key))return;t.stopPropagation(),t.preventDefault();let c=this._getChildren().filter(b=>!Wt(b)),e;if([ce,pb].includes(t.key))e=c[t.key===ce?0:c.length-1];else{let b=[xb,Qb].includes(t.key);e=de(c,t.target,b,!0)}e&&(e.focus({preventScroll:!0}),i.getOrCreateInstance(e).show())}_getChildren(){return W.find(be,this._parent)}_getActiveElem(){return this._getChildren().find(t=>this._elemIsActive(t))||null}_setInitialAttributes(t,c){this._setAttributeIfNotExists(t,"role","tablist");for(let e of c)this._setInitialAttributesOnChild(e)}_setInitialAttributesOnChild(t){t=this._getInnerElement(t);let c=this._elemIsActive(t),e=this._getOuterElement(t);t.setAttribute("aria-selected",c),e!==t&&this._setAttributeIfNotExists(e,"role","presentation"),c||t.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(t,"role","tab"),this._setInitialAttributesOnTargetPanel(t)}_setInitialAttributesOnTargetPanel(t){let c=W.getElementFromSelector(t);c&&(this._setAttributeIfNotExists(c,"role","tabpanel"),t.id&&this._setAttributeIfNotExists(c,"aria-labelledby",`${t.id}`))}_toggleDropDown(t,c){let e=this._getOuterElement(t);if(!e.classList.contains(od))return;let b=(o,l)=>{let a=W.findOne(o,e);a&&a.classList.toggle(l,c)};b(to,St),b(ld,ie),e.setAttribute("aria-expanded",c)}_setAttributeIfNotExists(t,c,e){t.hasAttribute(c)||t.setAttribute(c,e)}_elemIsActive(t){return t.classList.contains(St)}_getInnerElement(t){return t.matches(be)?t:W.findOne(be,t)}_getOuterElement(t){return t.closest(ad)||t}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this);if(typeof t=="string"){if(c[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);c[t]()}})}};m.on(document,td,co,function(i){["A","AREA"].includes(this.tagName)&&i.preventDefault(),!Wt(this)&&Yc.getOrCreateInstance(this).show()});m.on(window,id,()=>{for(let i of W.find(dd))Yc.getOrCreateInstance(i)});ct(Yc);var gd="toast",sd="bs.toast",Qt=`.${sd}`,rd=`mouseover${Qt}`,md=`mouseout${Qt}`,Fd=`focusin${Qt}`,Zd=`focusout${Qt}`,Xd=`hide${Qt}`,Cd=`hidden${Qt}`,Gd=`show${Qt}`,Bd=`shown${Qt}`,Wd="fade",Vb="hide",li="show",Ii="showing",ud={animation:"boolean",autohide:"boolean",delay:"number"},Rd={animation:!0,autohide:!0,delay:5e3},Gi=class i extends K{constructor(t,c){super(t,c),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return Rd}static get DefaultType(){return ud}static get NAME(){return gd}show(){if(m.trigger(this._element,Gd).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add(Wd);let c=()=>{this._element.classList.remove(Ii),m.trigger(this._element,Bd),this._maybeScheduleHide()};this._element.classList.remove(Vb),vc(this._element),this._element.classList.add(li,Ii),this._queueCallback(c,this._element,this._config.animation)}hide(){if(!this.isShown()||m.trigger(this._element,Xd).defaultPrevented)return;let c=()=>{this._element.classList.add(Vb),this._element.classList.remove(Ii,li),m.trigger(this._element,Cd)};this._element.classList.add(Ii),this._queueCallback(c,this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(li),super.dispose()}isShown(){return this._element.classList.contains(li)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout(()=>{this.hide()},this._config.delay)))}_onInteraction(t,c){switch(t.type){case"mouseover":case"mouseout":{this._hasMouseInteraction=c;break}case"focusin":case"focusout":{this._hasKeyboardInteraction=c;break}}if(c){this._clearTimeout();return}let e=t.relatedTarget;this._element===e||this._element.contains(e)||this._maybeScheduleHide()}_setListeners(){m.on(this._element,rd,t=>this._onInteraction(t,!0)),m.on(this._element,md,t=>this._onInteraction(t,!1)),m.on(this._element,Fd,t=>this._onInteraction(t,!0)),m.on(this._element,Zd,t=>this._onInteraction(t,!1))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each(function(){let c=i.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof c[t]>"u")throw new TypeError(`No method named "${t}"`);c[t](this)}})}};Bi(Gi);ct(Gi);var Be=globalThis,Wi=Be.trustedTypes,io=Wi?Wi.createPolicy("lit-html",{createHTML:i=>i}):void 0,ao="$lit$",pt=`lit$${(Math.random()+"").slice(9)}$`,no="?"+pt,xd=`<${no}>`,Kt=document,Lc=()=>Kt.createComment(""),Nc=i=>i===null||typeof i!="object"&&typeof i!="function",go=Array.isArray,Qd=i=>go(i)||typeof i?.[Symbol.iterator]=="function",me=`[ \f\r]`,Jc=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,eo=/-->/g,bo=/>/g,Dt=RegExp(`>|${me}(?:([^\\s"'>=/]+)(${me}*=${me}*(?:[^ -\f\r"'\`<>=]|("|')|))|$)`,"g"),oo=/'/g,lo=/"/g,so=/^(?:script|style|textarea|title)$/i,ro=i=>(t,...c)=>({_$litType$:i,strings:t,values:c}),x=ro(1),tF=ro(2),_t=Symbol.for("lit-noChange"),k=Symbol.for("lit-nothing"),Io=new WeakMap,Mt=Kt.createTreeWalker(Kt,129);function mo(i,t){if(!Array.isArray(i)||!i.hasOwnProperty("raw"))throw Error("invalid template strings array");return io!==void 0?io.createHTML(t):t}var pd=(i,t)=>{let c=i.length-1,e=[],b,o=t===2?"":"",l=Jc;for(let a=0;a"?(l=b??Jc,s=-1):n[1]===void 0?s=-2:(s=l.lastIndex-n[2].length,d=n[1],l=n[3]===void 0?Dt:n[3]==='"'?lo:oo):l===lo||l===oo?l=Dt:l===eo||l===bo?l=Jc:(l=Dt,b=void 0);let g=l===Dt&&i[a+1].startsWith("/>")?" ":"";o+=l===Jc?I+xd:s>=0?(e.push(d),I.slice(0,s)+ao+I.slice(s)+pt+g):I+pt+(s===-2?a:g)}return[mo(i,o+(i[c]||"")+(t===2?"":"")),e]},wc=class i{constructor({strings:t,_$litType$:c},e){let b;this.parts=[];let o=0,l=0,a=t.length-1,I=this.parts,[d,n]=pd(t,c);if(this.el=i.createElement(d,e),Mt.currentNode=this.el.content,c===2){let s=this.el.content.firstChild;s.replaceWith(...s.childNodes)}for(;(b=Mt.nextNode())!==null&&I.length0){b.textContent=Wi?Wi.emptyScript:"";for(let g=0;g2||e[0]!==""||e[1]!==""?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=k}_$AI(t,c=this,e,b){let o=this.strings,l=!1;if(o===void 0)t=Fc(this,t,c,0),l=!Nc(t)||t!==this._$AH&&t!==_t,l&&(this._$AH=t);else{let a=t,I,d;for(t=o[0],I=0;I{let e=c?.renderBefore??t,b=e._$litPart$;if(b===void 0){let o=c?.renderBefore??null;e._$litPart$=b=new kc(t.insertBefore(Lc(),o),o,void 0,c??{})}return b._$AI(i),b};async function D(){return await import("./main.js").then(i=>i.default)}function at(i){return document.querySelector(`meta[name="${i}"]`)?.content}function L(i,t){let c=at(`loc:${i}`)||i;if(t)for(let e in t)c=c.replace(`{${e}}`,t[e]);return c}function We(i){let t=/([a-z0-9])([A-Z]+[a-z])|([a-zA-Z0-9][.,/<>_])/g,c=[],e=0;for(;;){let b=t.exec(i);if(!b)break;let o=b.index+(b[1]||b[3]).length;c.push(i.slice(e,o)),e=o}return e{t.length>0&&t.push(x``),t.push(x`${c}`)}),x`${t}`}function ui(i){return i.hostname!==window.location.hostname||i.protocol!==window.location.protocol}function Fo(i,t){return c(i)===c(t);function c(e){return e.pathname.replace(/\/index\.html$/gi,"/").replace(/\.html$/gi,"").replace(/\/$/gi,"")}}async function ue(){if(document.querySelectorAll("pre code").length<=0)return;let{default:t}=await import("./es-BVOT75G5.min.js"),{configureHljs:c}=await D();c?.(t),document.querySelectorAll("pre code").forEach(e=>{t.highlightElement(e)}),document.querySelectorAll("pre code[highlight-lines]").forEach(e=>{if(e.innerHTML==="")return;let b=e.getAttribute("highlight-lines");if(!b)return;let o=e.innerHTML.split(` +\f\r"'\`<>=]|("|')|))|$)`,"g"),oo=/'/g,lo=/"/g,so=/^(?:script|style|textarea|title)$/i,ro=i=>(t,...c)=>({_$litType$:i,strings:t,values:c}),x=ro(1),tF=ro(2),_t=Symbol.for("lit-noChange"),k=Symbol.for("lit-nothing"),Io=new WeakMap,Mt=Kt.createTreeWalker(Kt,129);function mo(i,t){if(!Array.isArray(i)||!i.hasOwnProperty("raw"))throw Error("invalid template strings array");return io!==void 0?io.createHTML(t):t}var pd=(i,t)=>{let c=i.length-1,e=[],b,o=t===2?"":"",l=Jc;for(let a=0;a"?(l=b??Jc,s=-1):n[1]===void 0?s=-2:(s=l.lastIndex-n[2].length,d=n[1],l=n[3]===void 0?Dt:n[3]==='"'?lo:oo):l===lo||l===oo?l=Dt:l===eo||l===bo?l=Jc:(l=Dt,b=void 0);let g=l===Dt&&i[a+1].startsWith("/>")?" ":"";o+=l===Jc?I+xd:s>=0?(e.push(d),I.slice(0,s)+ao+I.slice(s)+pt+g):I+pt+(s===-2?a:g)}return[mo(i,o+(i[c]||"")+(t===2?"":"")),e]},wc=class i{constructor({strings:t,_$litType$:c},e){let b;this.parts=[];let o=0,l=0,a=t.length-1,I=this.parts,[d,n]=pd(t,c);if(this.el=i.createElement(d,e),Mt.currentNode=this.el.content,c===2){let s=this.el.content.firstChild;s.replaceWith(...s.childNodes)}for(;(b=Mt.nextNode())!==null&&I.length0){b.textContent=Wi?Wi.emptyScript:"";for(let g=0;g2||e[0]!==""||e[1]!==""?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=k}_$AI(t,c=this,e,b){let o=this.strings,l=!1;if(o===void 0)t=Fc(this,t,c,0),l=!Nc(t)||t!==this._$AH&&t!==_t,l&&(this._$AH=t);else{let a=t,I,d;for(t=o[0],I=0;I{let e=c?.renderBefore??t,b=e._$litPart$;if(b===void 0){let o=c?.renderBefore??null;e._$litPart$=b=new kc(t.insertBefore(Lc(),o),o,void 0,c??{})}return b._$AI(i),b};async function D(){return await import("./main.js").then(i=>i.default)}function at(i){return document.querySelector(`meta[name="${i}"]`)?.content}function L(i,t){let c=at(`loc:${i}`)||i;if(t)for(let e in t)c=c.replace(`{${e}}`,t[e]);return c}function We(i){let t=/([a-z0-9])([A-Z]+[a-z])|([a-zA-Z0-9][.,/<>_])/g,c=[],e=0;for(;;){let b=t.exec(i);if(!b)break;let o=b.index+(b[1]||b[3]).length;c.push(i.slice(e,o)),e=o}return e{t.length>0&&t.push(x``),t.push(x`${c}`)}),x`${t}`}function ui(i){return i.hostname!==window.location.hostname||i.protocol!==window.location.protocol}function Fo(i,t){return c(i)===c(t);function c(e){return e.pathname.replace(/\/index\.html$/gi,"/").replace(/\.html$/gi,"").replace(/\/$/gi,"")}}async function ue(){if(document.querySelectorAll("pre code").length<=0)return;let{default:t}=await import("./es-BVOT75G5.min.js"),{configureHljs:c}=await D();c?.(t),document.querySelectorAll("pre code").forEach(e=>{t.highlightElement(e)}),document.querySelectorAll("pre code[highlight-lines]").forEach(e=>{if(e.innerHTML==="")return;let b=e.getAttribute("highlight-lines");if(!b)return;let o=e.innerHTML.split(` `),l=b.split(",");for(let a of l){let I=0,d=0,n=a.match(/^(\d+)-(\d+)?$/);if(n)I=+n[1],d=+n[2],(isNaN(d)||d>o.length)&&(d=o.length);else{if(isNaN(Number(a)))continue;I=+a,d=I}I<=0||d<=0||I>d||I>o.length||(o[I-1]=''+o[I-1],o[d-1]=o[d-1]+"")}e.innerHTML=o.join(` `)})}function Zo(i){localStorage.setItem("theme",i),i==="auto"?document.documentElement.setAttribute("data-bs-theme",window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"):document.documentElement.setAttribute("data-bs-theme",i)}async function Xo(){return localStorage.getItem("theme")||(await D()).defaultTheme||"auto"}async function Co(){Zo(await Xo())}function Go(i){return new MutationObserver(()=>i(Re())).observe(document.documentElement,{attributes:!0,attributeFilter:["data-bs-theme"]})}function Re(){return document.documentElement.getAttribute("data-bs-theme")}async function Bo(i){let t=await Xo(),c=t==="light"?"sun":t==="dark"?"moon":"circle-half";return x`
    -
    `;function e(b,o){b.preventDefault(),Zo(o),i()}}async function Qe(){Ad(),fd(),yd(),Yd(),Od(),vd(),await Promise.all([Ud(),Vd(),xe()]),Go(xe)}async function Vd(){document.querySelectorAll(".math").length>0&&await import("./tex-svg-full-NDFOGKDH.min.js")}async function xe(){let i=document.querySelectorAll("pre code.lang-mermaid"),t=document.querySelectorAll("pre.mermaid[data-mermaid]");if(i.length<=0&&t.length<=0)return;let{default:c}=await import("./mermaid.core-WDQUIAJO.min.js"),e=Re()==="dark"?"dark":"default",{mermaid:b}=await D();c.initialize(Object.assign({startOnLoad:!1,theme:e},b));let o=[];i.forEach(l=>{if(l.offsetParent){o.push(l.parentElement);let a=l.innerHTML;l.parentElement.classList.add("mermaid"),l.parentElement.setAttribute("data-mermaid",a),l.parentElement.innerHTML=a}}),t.forEach(l=>{l.offsetParent&&(l.removeAttribute("data-processed"),l.innerHTML=l.getAttribute("data-mermaid"),o.push(l))}),await c.run({nodes:o})}function Ad(){document.querySelectorAll("article h1,h2,h3,h4,h5,h6,.xref,.text-break").forEach(i=>{if(i.innerHTML?.trim()===i.innerText?.trim()){let t=[];for(let c of We(i.innerText))t.length>0&&t.push(document.createElement("wbr")),t.push(c);i.replaceChildren(...t)}})}async function Ud(){let{showLightbox:i}=await D(),t=200,c=Array.from(document.querySelectorAll("article a img[src]"));document.querySelectorAll("article img[src]").forEach(e=>{o()?b():e.addEventListener("load",()=>{o()&&b()});function b(){let l=document.createElement("a");l.target="_blank",l.rel="noopener noreferrer nofollow",l.href=e.src,e.replaceWith(l),l.appendChild(e)}function o(){return i?i(e):e.naturalWidth>t&&e.naturalHeight>t&&!c.includes(e)}})}function fd(){document.querySelectorAll("table").forEach(i=>{i.classList.add("table","table-bordered","table-condensed");let t=document.createElement("div");t.className="table-responsive",i.parentElement.insertBefore(t,i),t.appendChild(i)})}function yd(){document.querySelectorAll(".NOTE, .TIP").forEach(i=>i.classList.add("alert","alert-info")),document.querySelectorAll(".WARNING").forEach(i=>i.classList.add("alert","alert-warning")),document.querySelectorAll(".IMPORTANT, .CAUTION").forEach(i=>i.classList.add("alert","alert-danger"))}function Yd(){at("docfx:disablenewtab")!=="true"&&document.querySelectorAll("article a[href]").forEach(i=>{i.hostname!==window.location.hostname&&i.innerText.trim()!==""&&(i.target="_blank",i.rel="noopener noreferrer nofollow",i.classList.add("external"))})}function vd(){document.querySelectorAll("pre>code").forEach(i=>{if(i.innerText.trim().length===0)return;let t=!1;c();function c(){let e=t?x``:x``;lt(e,i.parentElement);async function b(o){o.preventDefault(),await navigator.clipboard.writeText(i.innerText),t=!0,c(),setTimeout(()=>{t=!1,c()},1e3)}}})}function Od(){s();let i={id:"data-bi-id",name:"data-bi-name",type:"data-bi-type"},t=function(){function g(F,r,X){this.li=F,this.a=r,this.section=X}return Object.defineProperty(g.prototype,"tabIds",{get:function(){return this.a.getAttribute("data-tab").split(" ")},enumerable:!0,configurable:!0}),Object.defineProperty(g.prototype,"condition",{get:function(){return this.a.getAttribute("data-condition")},enumerable:!0,configurable:!0}),Object.defineProperty(g.prototype,"visible",{get:function(){return!this.li.hasAttribute("hidden")},set:function(F){F?(this.li.removeAttribute("hidden"),this.li.removeAttribute("aria-hidden")):(this.li.setAttribute("hidden","hidden"),this.li.setAttribute("aria-hidden","true"))},enumerable:!0,configurable:!0}),Object.defineProperty(g.prototype,"selected",{get:function(){return!this.section.hasAttribute("hidden")},set:function(F){F?(this.a.setAttribute("aria-selected","true"),this.a.classList.add("active"),this.a.tabIndex=0,this.section.removeAttribute("hidden"),this.section.removeAttribute("aria-hidden")):(this.a.setAttribute("aria-selected","false"),this.a.classList.remove("active"),this.a.tabIndex=-1,this.section.setAttribute("hidden","hidden"),this.section.setAttribute("aria-hidden","true"))},enumerable:!0,configurable:!0}),g.prototype.focus=function(){this.a.focus()},g}();c(document.body);function c(g){let F=I(),r=g.querySelectorAll(".tabGroup"),X={groups:[],selectedTabs:[]};for(let Z=0;Z ul > li > a[data-tab="'+X+'"]:not([hidden])');if(Z===null)return;Z.dispatchEvent(new CustomEvent("click",{bubbles:!0}))}}function I(){let F=new URLSearchParams(window.location.search).get("tabs");return F?F.split(","):[]}function d(g){let F=new URLSearchParams(window.location.search);F.set("tabs",g.selectedTabs.join());let r=location.protocol+"//"+location.host+location.pathname+"?"+F.toString()+location.hash;location.href!==r&&history.replaceState({},document.title,r)}function n(g,F){for(let r=0,X=g;rul").forEach(g=>g.classList.add("nav","nav-tabs")),document.querySelectorAll("div.tabGroup>ul>li").forEach(g=>g.classList.add("nav-item")),document.querySelectorAll("div.tabGroup>ul>li>a").forEach(g=>g.classList.add("nav-link")),document.querySelectorAll("div.tabGroup>section").forEach(g=>g.classList.add("card"))}function C(){xe()}}var Wo={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},uo=i=>(...t)=>({_$litDirective$:i,values:t}),Ri=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,c,e){this._$Ct=t,this._$AM=c,this._$Ci=e}_$AS(t,c){return this.update(t,c)}update(t,c){return this.render(...c)}};var ht=uo(class extends Ri{constructor(i){if(super(i),i.type!==Wo.ATTRIBUTE||i.name!=="class"||i.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(i){return" "+Object.keys(i).filter(t=>i[t]).join(" ")+" "}update(i,[t]){if(this.it===void 0){this.it=new Set,i.strings!==void 0&&(this.st=new Set(i.strings.join(" ").split(/\s/).filter(e=>e!=="")));for(let e in t)t[e]&&!this.st?.has(e)&&this.it.add(e);return this.render(t)}let c=i.element.classList;for(let e of this.it)e in t||(c.remove(e),this.it.delete(e));for(let e in t){let b=!!t[e];b===this.it.has(e)||this.st?.has(e)||(b?(c.add(e),this.it.add(e)):(c.remove(e),this.it.delete(e)))}return _t}});var nt;async function Ro(){let i=document.getElementById("search-query");if(!i||!window.Worker)return;let t=at("docfx:rel")||"",c=new Worker(t+"public/search-worker.min.js",{type:"module"});c.onerror=I=>{console.error("Error occurred at search-worker. message: "+I.message)},c.onmessage=function(I){switch(I.data.e){case"index-ready":i.disabled=!1,i.addEventListener("input",b),window.docfx.searchReady=!0;break;case"query-ready":document.body.setAttribute("data-search","true"),a(I.data.d,0),window.docfx.searchResultReady=!0,i.value===""&&document.body.removeAttribute("data-search");break}};let{lunrLanguages:e}=await D();c.postMessage({init:{lunrLanguages:e}});function b(){nt=i.value,nt===""?document.body.removeAttribute("data-search"):c.postMessage({q:nt})}function o(I,d){let n=I.split(/\/+/),s=d.split(/\/+/),C=n.length-1,g=[];for(let F=0;F512)return"..."+I.slice(s-512,s+512)+"...";if(s<=512)return I.slice(0,s+512)+"..."}function a(I,d){let s=Math.ceil(I.length/10);lt(C(d),document.getElementById("search-results"));function C(F){if(I.length===0)return x`
    ${L("searchNoResults",{query:nt})}
    `;let r=F*10,X=I.slice(r,r+10),Z=x` +
    `;function e(b,o){b.preventDefault(),Zo(o),i()}}async function Qe(){Ad(),fd(),yd(),Yd(),Od(),vd(),await Promise.all([Ud(),Vd(),xe()]),Go(xe)}async function Vd(){document.querySelectorAll(".math").length>0&&await import("./tex-svg-full-NDFOGKDH.min.js")}async function xe(){let i=document.querySelectorAll("pre code.lang-mermaid"),t=document.querySelectorAll("pre.mermaid[data-mermaid]");if(i.length<=0&&t.length<=0)return;let{default:c}=await import("./mermaid.core-OQEF2Y4J.min.js"),e=Re()==="dark"?"dark":"default",{mermaid:b}=await D();c.initialize(Object.assign({startOnLoad:!1,theme:e},b));let o=[];i.forEach(l=>{if(l.offsetParent){o.push(l.parentElement);let a=l.innerHTML;l.parentElement.classList.add("mermaid"),l.parentElement.setAttribute("data-mermaid",a),l.parentElement.innerHTML=a}}),t.forEach(l=>{l.offsetParent&&(l.removeAttribute("data-processed"),l.innerHTML=l.getAttribute("data-mermaid"),o.push(l))}),await c.run({nodes:o})}function Ad(){document.querySelectorAll("article h1,h2,h3,h4,h5,h6,.xref,.text-break").forEach(i=>{if(i.innerHTML?.trim()===i.innerText?.trim()){let t=[];for(let c of We(i.innerText))t.length>0&&t.push(document.createElement("wbr")),t.push(c);i.replaceChildren(...t)}})}async function Ud(){let{showLightbox:i}=await D(),t=200,c=Array.from(document.querySelectorAll("article a img[src]"));document.querySelectorAll("article img[src]").forEach(e=>{o()?b():e.addEventListener("load",()=>{o()&&b()});function b(){let l=document.createElement("a");l.target="_blank",l.rel="noopener noreferrer nofollow",l.href=e.src,e.replaceWith(l),l.appendChild(e)}function o(){return i?i(e):e.naturalWidth>t&&e.naturalHeight>t&&!c.includes(e)}})}function fd(){document.querySelectorAll("table").forEach(i=>{i.classList.add("table","table-bordered","table-condensed");let t=document.createElement("div");t.className="table-responsive",i.parentElement.insertBefore(t,i),t.appendChild(i)})}function yd(){document.querySelectorAll(".NOTE, .TIP").forEach(i=>i.classList.add("alert","alert-info")),document.querySelectorAll(".WARNING").forEach(i=>i.classList.add("alert","alert-warning")),document.querySelectorAll(".IMPORTANT, .CAUTION").forEach(i=>i.classList.add("alert","alert-danger"))}function Yd(){at("docfx:disablenewtab")!=="true"&&document.querySelectorAll("article a[href]").forEach(i=>{i.hostname!==window.location.hostname&&i.innerText.trim()!==""&&(i.target="_blank",i.rel="noopener noreferrer nofollow",i.classList.add("external"))})}function vd(){document.querySelectorAll("pre>code").forEach(i=>{if(i.innerText.trim().length===0)return;let t=!1;c();function c(){let e=t?x``:x``;lt(e,i.parentElement);async function b(o){o.preventDefault(),await navigator.clipboard.writeText(i.innerText),t=!0,c(),setTimeout(()=>{t=!1,c()},1e3)}}})}function Od(){s();let i={id:"data-bi-id",name:"data-bi-name",type:"data-bi-type"},t=function(){function g(F,r,X){this.li=F,this.a=r,this.section=X}return Object.defineProperty(g.prototype,"tabIds",{get:function(){return this.a.getAttribute("data-tab").split(" ")},enumerable:!0,configurable:!0}),Object.defineProperty(g.prototype,"condition",{get:function(){return this.a.getAttribute("data-condition")},enumerable:!0,configurable:!0}),Object.defineProperty(g.prototype,"visible",{get:function(){return!this.li.hasAttribute("hidden")},set:function(F){F?(this.li.removeAttribute("hidden"),this.li.removeAttribute("aria-hidden")):(this.li.setAttribute("hidden","hidden"),this.li.setAttribute("aria-hidden","true"))},enumerable:!0,configurable:!0}),Object.defineProperty(g.prototype,"selected",{get:function(){return!this.section.hasAttribute("hidden")},set:function(F){F?(this.a.setAttribute("aria-selected","true"),this.a.classList.add("active"),this.a.tabIndex=0,this.section.removeAttribute("hidden"),this.section.removeAttribute("aria-hidden")):(this.a.setAttribute("aria-selected","false"),this.a.classList.remove("active"),this.a.tabIndex=-1,this.section.setAttribute("hidden","hidden"),this.section.setAttribute("aria-hidden","true"))},enumerable:!0,configurable:!0}),g.prototype.focus=function(){this.a.focus()},g}();c(document.body);function c(g){let F=I(),r=g.querySelectorAll(".tabGroup"),X={groups:[],selectedTabs:[]};for(let Z=0;Z ul > li > a[data-tab="'+X+'"]:not([hidden])');if(Z===null)return;Z.dispatchEvent(new CustomEvent("click",{bubbles:!0}))}}function I(){let F=new URLSearchParams(window.location.search).get("tabs");return F?F.split(","):[]}function d(g){let F=new URLSearchParams(window.location.search);F.set("tabs",g.selectedTabs.join());let r=location.protocol+"//"+location.host+location.pathname+"?"+F.toString()+location.hash;location.href!==r&&history.replaceState({},document.title,r)}function n(g,F){for(let r=0,X=g;rul").forEach(g=>g.classList.add("nav","nav-tabs")),document.querySelectorAll("div.tabGroup>ul>li").forEach(g=>g.classList.add("nav-item")),document.querySelectorAll("div.tabGroup>ul>li>a").forEach(g=>g.classList.add("nav-link")),document.querySelectorAll("div.tabGroup>section").forEach(g=>g.classList.add("card"))}function C(){xe()}}var Wo={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},uo=i=>(...t)=>({_$litDirective$:i,values:t}),Ri=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,c,e){this._$Ct=t,this._$AM=c,this._$Ci=e}_$AS(t,c){return this.update(t,c)}update(t,c){return this.render(...c)}};var ht=uo(class extends Ri{constructor(i){if(super(i),i.type!==Wo.ATTRIBUTE||i.name!=="class"||i.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(i){return" "+Object.keys(i).filter(t=>i[t]).join(" ")+" "}update(i,[t]){if(this.it===void 0){this.it=new Set,i.strings!==void 0&&(this.st=new Set(i.strings.join(" ").split(/\s/).filter(e=>e!=="")));for(let e in t)t[e]&&!this.st?.has(e)&&this.it.add(e);return this.render(t)}let c=i.element.classList;for(let e of this.it)e in t||(c.remove(e),this.it.delete(e));for(let e in t){let b=!!t[e];b===this.it.has(e)||this.st?.has(e)||(b?(c.add(e),this.it.add(e)):(c.remove(e),this.it.delete(e)))}return _t}});var nt;async function Ro(){let i=document.getElementById("search-query");if(!i||!window.Worker)return;let t=at("docfx:rel")||"",c=new Worker(t+"public/search-worker.min.js",{type:"module"});c.onerror=I=>{console.error("Error occurred at search-worker. message: "+I.message)},c.onmessage=function(I){switch(I.data.e){case"index-ready":i.disabled=!1,i.addEventListener("input",b),window.docfx.searchReady=!0;break;case"query-ready":document.body.setAttribute("data-search","true"),a(I.data.d,0),window.docfx.searchResultReady=!0,i.value===""&&document.body.removeAttribute("data-search");break}};let{lunrLanguages:e}=await D();c.postMessage({init:{lunrLanguages:e}});function b(){nt=i.value,nt===""?document.body.removeAttribute("data-search"):c.postMessage({q:nt})}function o(I,d){let n=I.split(/\/+/),s=d.split(/\/+/),C=n.length-1,g=[];for(let F=0;F512)return"..."+I.slice(s-512,s+512)+"...";if(s<=512)return I.slice(0,s+512)+"..."}function a(I,d){let s=Math.ceil(I.length/10);lt(C(d),document.getElementById("search-results"));function C(F){if(I.length===0)return x`
    ${L("searchNoResults",{query:nt})}
    `;let r=F*10,X=I.slice(r,r+10),Z=x`
    ${L("searchResultsCount",{count:I.length.toString(),query:nt})}
    ${X.map(B=>{let G=window.location.href,u=o(G,t+B.href),R=t+B.href+"?q="+nt,Q=l(B.keywords);return x`
    diff --git a/docs/public/docfx.min.js.map b/docs/public/docfx.min.js.map index c29ac20b..c495ba98 100644 --- a/docs/public/docfx.min.js.map +++ b/docs/public/docfx.min.js.map @@ -1,7 +1,7 @@ { "version": 3, "sources": ["../../node_modules/anchor-js/anchor.js", "../../node_modules/@popperjs/core/lib/index.js", "../../node_modules/@popperjs/core/lib/enums.js", "../../node_modules/@popperjs/core/lib/dom-utils/getNodeName.js", "../../node_modules/@popperjs/core/lib/dom-utils/getWindow.js", "../../node_modules/@popperjs/core/lib/dom-utils/instanceOf.js", "../../node_modules/@popperjs/core/lib/modifiers/applyStyles.js", "../../node_modules/@popperjs/core/lib/utils/getBasePlacement.js", "../../node_modules/@popperjs/core/lib/utils/math.js", "../../node_modules/@popperjs/core/lib/utils/userAgent.js", "../../node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.js", "../../node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.js", "../../node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.js", "../../node_modules/@popperjs/core/lib/dom-utils/contains.js", "../../node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.js", "../../node_modules/@popperjs/core/lib/dom-utils/isTableElement.js", "../../node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.js", "../../node_modules/@popperjs/core/lib/dom-utils/getParentNode.js", "../../node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.js", "../../node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.js", "../../node_modules/@popperjs/core/lib/utils/within.js", "../../node_modules/@popperjs/core/lib/utils/getFreshSideObject.js", "../../node_modules/@popperjs/core/lib/utils/mergePaddingObject.js", "../../node_modules/@popperjs/core/lib/utils/expandToHashMap.js", "../../node_modules/@popperjs/core/lib/modifiers/arrow.js", "../../node_modules/@popperjs/core/lib/utils/getVariation.js", "../../node_modules/@popperjs/core/lib/modifiers/computeStyles.js", "../../node_modules/@popperjs/core/lib/modifiers/eventListeners.js", "../../node_modules/@popperjs/core/lib/utils/getOppositePlacement.js", "../../node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.js", "../../node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.js", "../../node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.js", "../../node_modules/@popperjs/core/lib/dom-utils/getViewportRect.js", "../../node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.js", "../../node_modules/@popperjs/core/lib/dom-utils/isScrollParent.js", "../../node_modules/@popperjs/core/lib/dom-utils/getScrollParent.js", "../../node_modules/@popperjs/core/lib/dom-utils/listScrollParents.js", "../../node_modules/@popperjs/core/lib/utils/rectToClientRect.js", "../../node_modules/@popperjs/core/lib/dom-utils/getClippingRect.js", "../../node_modules/@popperjs/core/lib/utils/computeOffsets.js", "../../node_modules/@popperjs/core/lib/utils/detectOverflow.js", "../../node_modules/@popperjs/core/lib/utils/computeAutoPlacement.js", "../../node_modules/@popperjs/core/lib/modifiers/flip.js", "../../node_modules/@popperjs/core/lib/modifiers/hide.js", "../../node_modules/@popperjs/core/lib/modifiers/offset.js", "../../node_modules/@popperjs/core/lib/modifiers/popperOffsets.js", "../../node_modules/@popperjs/core/lib/utils/getAltAxis.js", "../../node_modules/@popperjs/core/lib/modifiers/preventOverflow.js", "../../node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.js", "../../node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.js", "../../node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.js", "../../node_modules/@popperjs/core/lib/utils/orderModifiers.js", "../../node_modules/@popperjs/core/lib/utils/debounce.js", "../../node_modules/@popperjs/core/lib/utils/mergeByName.js", "../../node_modules/@popperjs/core/lib/createPopper.js", "../../node_modules/@popperjs/core/lib/popper-lite.js", "../../node_modules/@popperjs/core/lib/popper.js", "../../node_modules/bootstrap/js/src/dom/data.js", "../../node_modules/bootstrap/js/src/util/index.js", "../../node_modules/bootstrap/js/src/dom/event-handler.js", "../../node_modules/bootstrap/js/src/dom/manipulator.js", "../../node_modules/bootstrap/js/src/util/config.js", "../../node_modules/bootstrap/js/src/base-component.js", "../../node_modules/bootstrap/js/src/dom/selector-engine.js", "../../node_modules/bootstrap/js/src/util/component-functions.js", "../../node_modules/bootstrap/js/src/alert.js", "../../node_modules/bootstrap/js/src/button.js", "../../node_modules/bootstrap/js/src/util/swipe.js", "../../node_modules/bootstrap/js/src/carousel.js", "../../node_modules/bootstrap/js/src/collapse.js", "../../node_modules/bootstrap/js/src/dropdown.js", "../../node_modules/bootstrap/js/src/util/backdrop.js", "../../node_modules/bootstrap/js/src/util/focustrap.js", "../../node_modules/bootstrap/js/src/util/scrollbar.js", "../../node_modules/bootstrap/js/src/modal.js", "../../node_modules/bootstrap/js/src/offcanvas.js", "../../node_modules/bootstrap/js/src/util/sanitizer.js", "../../node_modules/bootstrap/js/src/util/template-factory.js", "../../node_modules/bootstrap/js/src/tooltip.js", "../../node_modules/bootstrap/js/src/popover.js", "../../node_modules/bootstrap/js/src/scrollspy.js", "../../node_modules/bootstrap/js/src/tab.js", "../../node_modules/bootstrap/js/src/toast.js", "../../node_modules/lit-html/src/lit-html.ts", "../src/helper.ts", "../src/highlight.ts", "../src/theme.ts", "../src/markdown.ts", "../../node_modules/lit-html/src/directive.ts", "../../node_modules/lit-html/src/directives/class-map.ts", "../src/search.ts", "../src/toc.ts", "../src/nav.ts", "../src/docfx.ts"], - "sourcesContent": ["/* eslint-env amd */\n/* globals module:false */\n\n// https://github.com/umdjs/umd/blob/master/templates/returnExports.js\n(function(root, factory) {\n 'use strict';\n\n if (typeof define === 'function' && define.amd) {\n // AMD. Register as an anonymous module.\n define([], factory);\n } else if (typeof module === 'object' && module.exports) {\n // Node. Does not work with strict CommonJS, but\n // only CommonJS-like environments that support module.exports,\n // like Node.\n module.exports = factory();\n } else {\n // Browser globals (root is window)\n root.AnchorJS = factory();\n root.anchors = new root.AnchorJS();\n }\n}(globalThis, function() {\n 'use strict';\n\n function AnchorJS(options) {\n this.options = options || {};\n this.elements = [];\n\n /**\n * Assigns options to the internal options object, and provides defaults.\n * @param {Object} opts - Options object\n */\n function _applyRemainingDefaultOptions(opts) {\n opts.icon = Object.prototype.hasOwnProperty.call(opts, 'icon') ? opts.icon : '\\uE9CB'; // Accepts characters (and also URLs?), like '#', '\u00B6', '\u2761', or '\u00A7'.\n opts.visible = Object.prototype.hasOwnProperty.call(opts, 'visible') ? opts.visible : 'hover'; // Also accepts 'always'\n opts.placement = Object.prototype.hasOwnProperty.call(opts, 'placement') ? opts.placement : 'right'; // Also accepts 'left'\n opts.ariaLabel = Object.prototype.hasOwnProperty.call(opts, 'ariaLabel') ? opts.ariaLabel : 'Anchor'; // Accepts any text.\n opts.class = Object.prototype.hasOwnProperty.call(opts, 'class') ? opts.class : ''; // Accepts any class name.\n opts.base = Object.prototype.hasOwnProperty.call(opts, 'base') ? opts.base : ''; // Accepts any base URI.\n // Using Math.floor here will ensure the value is Number-cast and an integer.\n opts.truncate = Object.prototype.hasOwnProperty.call(opts, 'truncate') ? Math.floor(opts.truncate) : 64; // Accepts any value that can be typecast to a number.\n opts.titleText = Object.prototype.hasOwnProperty.call(opts, 'titleText') ? opts.titleText : ''; // Accepts any text.\n }\n\n _applyRemainingDefaultOptions(this.options);\n\n /**\n * Add anchor links to page elements.\n * @param {String|Array|Nodelist} selector - A CSS selector for targeting the elements you wish to add anchor links\n * to. Also accepts an array or nodeList containing the relavant elements.\n * @return {this} - The AnchorJS object\n */\n this.add = function(selector) {\n var elements,\n elsWithIds,\n idList,\n elementID,\n i,\n index,\n count,\n tidyText,\n newTidyText,\n anchor,\n hrefBase,\n indexesToDrop = [];\n\n // We reapply options here because somebody may have overwritten the default options object when setting options.\n // For example, this overwrites all options but visible:\n //\n // anchors.options = { visible: 'always'; }\n _applyRemainingDefaultOptions(this.options);\n\n // Provide a sensible default selector, if none is given.\n if (!selector) {\n selector = 'h2, h3, h4, h5, h6';\n }\n\n elements = _getElements(selector);\n\n if (elements.length === 0) {\n return this;\n }\n\n _addBaselineStyles();\n\n // We produce a list of existing IDs so we don't generate a duplicate.\n elsWithIds = document.querySelectorAll('[id]');\n idList = [].map.call(elsWithIds, function(el) {\n return el.id;\n });\n\n for (i = 0; i < elements.length; i++) {\n if (this.hasAnchorJSLink(elements[i])) {\n indexesToDrop.push(i);\n continue;\n }\n\n if (elements[i].hasAttribute('id')) {\n elementID = elements[i].getAttribute('id');\n } else if (elements[i].hasAttribute('data-anchor-id')) {\n elementID = elements[i].getAttribute('data-anchor-id');\n } else {\n tidyText = this.urlify(elements[i].textContent);\n\n // Compare our generated ID to existing IDs (and increment it if needed)\n // before we add it to the page.\n newTidyText = tidyText;\n count = 0;\n do {\n if (index !== undefined) {\n newTidyText = tidyText + '-' + count;\n }\n\n index = idList.indexOf(newTidyText);\n count += 1;\n } while (index !== -1);\n\n index = undefined;\n idList.push(newTidyText);\n\n elements[i].setAttribute('id', newTidyText);\n elementID = newTidyText;\n }\n\n // The following code efficiently builds this DOM structure:\n // `\n // ;`\n anchor = document.createElement('a');\n anchor.className = 'anchorjs-link ' + this.options.class;\n anchor.setAttribute('aria-label', this.options.ariaLabel);\n anchor.setAttribute('data-anchorjs-icon', this.options.icon);\n if (this.options.titleText) {\n anchor.title = this.options.titleText;\n }\n\n // Adjust the href if there's a tag. See https://github.com/bryanbraun/anchorjs/issues/98\n hrefBase = document.querySelector('base') ? window.location.pathname + window.location.search : '';\n hrefBase = this.options.base || hrefBase;\n anchor.href = hrefBase + '#' + elementID;\n\n if (this.options.visible === 'always') {\n anchor.style.opacity = '1';\n }\n\n if (this.options.icon === '\\uE9CB') {\n anchor.style.font = '1em/1 anchorjs-icons';\n\n // We set lineHeight = 1 here because the `anchorjs-icons` font family could otherwise affect the\n // height of the heading. This isn't the case for icons with `placement: left`, so we restore\n // line-height: inherit in that case, ensuring they remain positioned correctly. For more info,\n // see https://github.com/bryanbraun/anchorjs/issues/39.\n if (this.options.placement === 'left') {\n anchor.style.lineHeight = 'inherit';\n }\n }\n\n if (this.options.placement === 'left') {\n anchor.style.position = 'absolute';\n anchor.style.marginLeft = '-1.25em';\n anchor.style.paddingRight = '.25em';\n anchor.style.paddingLeft = '.25em';\n elements[i].insertBefore(anchor, elements[i].firstChild);\n } else { // if the option provided is `right` (or anything else).\n anchor.style.marginLeft = '.1875em';\n anchor.style.paddingRight = '.1875em';\n anchor.style.paddingLeft = '.1875em';\n elements[i].appendChild(anchor);\n }\n }\n\n for (i = 0; i < indexesToDrop.length; i++) {\n elements.splice(indexesToDrop[i] - i, 1);\n }\n\n this.elements = this.elements.concat(elements);\n\n return this;\n };\n\n /**\n * Removes all anchorjs-links from elements targeted by the selector.\n * @param {String|Array|Nodelist} selector - A CSS selector string targeting elements with anchor links,\n * OR a nodeList / array containing the DOM elements.\n * @return {this} - The AnchorJS object\n */\n this.remove = function(selector) {\n var index,\n domAnchor,\n elements = _getElements(selector);\n\n for (var i = 0; i < elements.length; i++) {\n domAnchor = elements[i].querySelector('.anchorjs-link');\n if (domAnchor) {\n // Drop the element from our main list, if it's in there.\n index = this.elements.indexOf(elements[i]);\n if (index !== -1) {\n this.elements.splice(index, 1);\n }\n\n // Remove the anchor from the DOM.\n elements[i].removeChild(domAnchor);\n }\n }\n\n return this;\n };\n\n /**\n * Removes all anchorjs links. Mostly used for tests.\n */\n this.removeAll = function() {\n this.remove(this.elements);\n };\n\n /**\n * Urlify - Refine text so it makes a good ID.\n *\n * To do this, we remove apostrophes, replace non-safe characters with hyphens,\n * remove extra hyphens, truncate, trim hyphens, and make lowercase.\n *\n * @param {String} text - Any text. Usually pulled from the webpage element we are linking to.\n * @return {String} - hyphen-delimited text for use in IDs and URLs.\n */\n this.urlify = function(text) {\n // Decode HTML characters such as ' ' first.\n var textareaElement = document.createElement('textarea');\n textareaElement.innerHTML = text;\n text = textareaElement.value;\n\n // Regex for finding the non-safe URL characters (many need escaping):\n // & +$,:;=?@\"#{}|^~[`%!'<>]./()*\\ (newlines, tabs, backspace, vertical tabs, and non-breaking space)\n var nonsafeChars = /[& +$,:;=?@\"#{}|^~[`%!'<>\\]./()*\\\\\\n\\t\\b\\v\\u00A0]/g;\n\n // The reason we include this _applyRemainingDefaultOptions is so urlify can be called independently,\n // even after setting options. This can be useful for tests or other applications.\n if (!this.options.truncate) {\n _applyRemainingDefaultOptions(this.options);\n }\n\n // Note: we trim hyphens after truncating because truncating can cause dangling hyphens.\n // Example string: // \" \u26A1\u26A1 Don't forget: URL fragments should be i18n-friendly, hyphenated, short, and clean.\"\n return text.trim() // \"\u26A1\u26A1 Don't forget: URL fragments should be i18n-friendly, hyphenated, short, and clean.\"\n .replace(/'/gi, '') // \"\u26A1\u26A1 Dont forget: URL fragments should be i18n-friendly, hyphenated, short, and clean.\"\n .replace(nonsafeChars, '-') // \"\u26A1\u26A1-Dont-forget--URL-fragments-should-be-i18n-friendly--hyphenated--short--and-clean-\"\n .replace(/-{2,}/g, '-') // \"\u26A1\u26A1-Dont-forget-URL-fragments-should-be-i18n-friendly-hyphenated-short-and-clean-\"\n .substring(0, this.options.truncate) // \"\u26A1\u26A1-Dont-forget-URL-fragments-should-be-i18n-friendly-hyphenated-\"\n .replace(/^-+|-+$/gm, '') // \"\u26A1\u26A1-Dont-forget-URL-fragments-should-be-i18n-friendly-hyphenated\"\n .toLowerCase(); // \"\u26A1\u26A1-dont-forget-url-fragments-should-be-i18n-friendly-hyphenated\"\n };\n\n /**\n * Determines if this element already has an AnchorJS link on it.\n * Uses this technique: https://stackoverflow.com/a/5898748/1154642\n * @param {HTMLElement} el - a DOM node\n * @return {Boolean} true/false\n */\n this.hasAnchorJSLink = function(el) {\n var hasLeftAnchor = el.firstChild && (' ' + el.firstChild.className + ' ').indexOf(' anchorjs-link ') > -1,\n hasRightAnchor = el.lastChild && (' ' + el.lastChild.className + ' ').indexOf(' anchorjs-link ') > -1;\n\n return hasLeftAnchor || hasRightAnchor || false;\n };\n\n /**\n * Turns a selector, nodeList, or array of elements into an array of elements (so we can use array methods).\n * It also throws errors on any other inputs. Used to handle inputs to .add and .remove.\n * @param {String|Array|Nodelist} input - A CSS selector string targeting elements with anchor links,\n * OR a nodeList / array containing the DOM elements.\n * @return {Array} - An array containing the elements we want.\n */\n function _getElements(input) {\n var elements;\n if (typeof input === 'string' || input instanceof String) {\n // See https://davidwalsh.name/nodelist-array for the technique transforming nodeList -> Array.\n elements = [].slice.call(document.querySelectorAll(input));\n } else if (Array.isArray(input) || input instanceof NodeList) {\n elements = [].slice.call(input);\n } else {\n throw new TypeError('The selector provided to AnchorJS was invalid.');\n }\n\n return elements;\n }\n\n /**\n * _addBaselineStyles\n * Adds baseline styles to the page, used by all AnchorJS links irregardless of configuration.\n */\n function _addBaselineStyles() {\n // We don't want to add global baseline styles if they've been added before.\n if (document.head.querySelector('style.anchorjs') !== null) {\n return;\n }\n\n var style = document.createElement('style'),\n linkRule =\n '.anchorjs-link{' +\n 'opacity:0;' +\n 'text-decoration:none;' +\n '-webkit-font-smoothing:antialiased;' +\n '-moz-osx-font-smoothing:grayscale' +\n '}',\n hoverRule =\n ':hover>.anchorjs-link,' +\n '.anchorjs-link:focus{' +\n 'opacity:1' +\n '}',\n anchorjsLinkFontFace =\n '@font-face{' +\n 'font-family:anchorjs-icons;' + // Icon from icomoon; 10px wide & 10px tall; 2 empty below & 4 above\n 'src:url(data:n/a;base64,AAEAAAALAIAAAwAwT1MvMg8yG2cAAAE4AAAAYGNtYXDp3gC3AAABpAAAAExnYXNwAAAAEAAAA9wAAAAIZ2x5ZlQCcfwAAAH4AAABCGhlYWQHFvHyAAAAvAAAADZoaGVhBnACFwAAAPQAAAAkaG10eASAADEAAAGYAAAADGxvY2EACACEAAAB8AAAAAhtYXhwAAYAVwAAARgAAAAgbmFtZQGOH9cAAAMAAAAAunBvc3QAAwAA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P) format(\"truetype\")' +\n '}',\n pseudoElContent =\n '[data-anchorjs-icon]::after{' +\n 'content:attr(data-anchorjs-icon)' +\n '}',\n firstStyleEl;\n\n style.className = 'anchorjs';\n style.appendChild(document.createTextNode('')); // Necessary for Webkit.\n\n // We place it in the head with the other style tags, if possible, so as to\n // not look out of place. We insert before the others so these styles can be\n // overridden if necessary.\n firstStyleEl = document.head.querySelector('[rel=\"stylesheet\"],style');\n if (firstStyleEl === undefined) {\n document.head.appendChild(style);\n } else {\n document.head.insertBefore(style, firstStyleEl);\n }\n\n style.sheet.insertRule(linkRule, style.sheet.cssRules.length);\n style.sheet.insertRule(hoverRule, style.sheet.cssRules.length);\n style.sheet.insertRule(pseudoElContent, style.sheet.cssRules.length);\n style.sheet.insertRule(anchorjsLinkFontFace, style.sheet.cssRules.length);\n }\n }\n\n return AnchorJS;\n}));\n", "export * from \"./enums.js\";\nexport * from \"./modifiers/index.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport { popperGenerator, detectOverflow, createPopper as createPopperBase } from \"./createPopper.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper } from \"./popper.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\";", "export var top = 'top';\nexport var bottom = 'bottom';\nexport var right = 'right';\nexport var left = 'left';\nexport var auto = 'auto';\nexport var basePlacements = [top, bottom, right, left];\nexport var start = 'start';\nexport var end = 'end';\nexport var clippingParents = 'clippingParents';\nexport var viewport = 'viewport';\nexport var popper = 'popper';\nexport var reference = 'reference';\nexport var variationPlacements = /*#__PURE__*/basePlacements.reduce(function (acc, placement) {\n return acc.concat([placement + \"-\" + start, placement + \"-\" + end]);\n}, []);\nexport var placements = /*#__PURE__*/[].concat(basePlacements, [auto]).reduce(function (acc, placement) {\n return acc.concat([placement, placement + \"-\" + start, placement + \"-\" + end]);\n}, []); // modifiers that need to read the DOM\n\nexport var beforeRead = 'beforeRead';\nexport var read = 'read';\nexport var afterRead = 'afterRead'; // pure-logic modifiers\n\nexport var beforeMain = 'beforeMain';\nexport var main = 'main';\nexport var afterMain = 'afterMain'; // modifier with the purpose to write to the DOM (or write into a framework state)\n\nexport var beforeWrite = 'beforeWrite';\nexport var write = 'write';\nexport var afterWrite = 'afterWrite';\nexport var modifierPhases = [beforeRead, read, afterRead, beforeMain, main, afterMain, beforeWrite, write, afterWrite];", "export default function getNodeName(element) {\n return element ? (element.nodeName || '').toLowerCase() : null;\n}", "export default function getWindow(node) {\n if (node == null) {\n return window;\n }\n\n if (node.toString() !== '[object Window]') {\n var ownerDocument = node.ownerDocument;\n return ownerDocument ? ownerDocument.defaultView || window : window;\n }\n\n return node;\n}", "import getWindow from \"./getWindow.js\";\n\nfunction isElement(node) {\n var OwnElement = getWindow(node).Element;\n return node instanceof OwnElement || node instanceof Element;\n}\n\nfunction isHTMLElement(node) {\n var OwnElement = getWindow(node).HTMLElement;\n return node instanceof OwnElement || node instanceof HTMLElement;\n}\n\nfunction isShadowRoot(node) {\n // IE 11 has no ShadowRoot\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n\n var OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\n\nexport { isElement, isHTMLElement, isShadowRoot };", "import getNodeName from \"../dom-utils/getNodeName.js\";\nimport { isHTMLElement } from \"../dom-utils/instanceOf.js\"; // This modifier takes the styles prepared by the `computeStyles` modifier\n// and applies them to the HTMLElements such as popper and arrow\n\nfunction applyStyles(_ref) {\n var state = _ref.state;\n Object.keys(state.elements).forEach(function (name) {\n var style = state.styles[name] || {};\n var attributes = state.attributes[name] || {};\n var element = state.elements[name]; // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n } // Flow doesn't support to extend this property, but it's the most\n // effective way to apply styles to an HTMLElement\n // $FlowFixMe[cannot-write]\n\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (name) {\n var value = attributes[name];\n\n if (value === false) {\n element.removeAttribute(name);\n } else {\n element.setAttribute(name, value === true ? '' : value);\n }\n });\n });\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state;\n var initialStyles = {\n popper: {\n position: state.options.strategy,\n left: '0',\n top: '0',\n margin: '0'\n },\n arrow: {\n position: 'absolute'\n },\n reference: {}\n };\n Object.assign(state.elements.popper.style, initialStyles.popper);\n state.styles = initialStyles;\n\n if (state.elements.arrow) {\n Object.assign(state.elements.arrow.style, initialStyles.arrow);\n }\n\n return function () {\n Object.keys(state.elements).forEach(function (name) {\n var element = state.elements[name];\n var attributes = state.attributes[name] || {};\n var styleProperties = Object.keys(state.styles.hasOwnProperty(name) ? state.styles[name] : initialStyles[name]); // Set all values to an empty string to unset them\n\n var style = styleProperties.reduce(function (style, property) {\n style[property] = '';\n return style;\n }, {}); // arrow is optional + virtual elements\n\n if (!isHTMLElement(element) || !getNodeName(element)) {\n return;\n }\n\n Object.assign(element.style, style);\n Object.keys(attributes).forEach(function (attribute) {\n element.removeAttribute(attribute);\n });\n });\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'applyStyles',\n enabled: true,\n phase: 'write',\n fn: applyStyles,\n effect: effect,\n requires: ['computeStyles']\n};", "import { auto } from \"../enums.js\";\nexport default function getBasePlacement(placement) {\n return placement.split('-')[0];\n}", "export var max = Math.max;\nexport var min = Math.min;\nexport var round = Math.round;", "export default function getUAString() {\n var uaData = navigator.userAgentData;\n\n if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) {\n return uaData.brands.map(function (item) {\n return item.brand + \"/\" + item.version;\n }).join(' ');\n }\n\n return navigator.userAgent;\n}", "import getUAString from \"../utils/userAgent.js\";\nexport default function isLayoutViewport() {\n return !/^((?!chrome|android).)*safari/i.test(getUAString());\n}", "import { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport { round } from \"../utils/math.js\";\nimport getWindow from \"./getWindow.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getBoundingClientRect(element, includeScale, isFixedStrategy) {\n if (includeScale === void 0) {\n includeScale = false;\n }\n\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n\n var clientRect = element.getBoundingClientRect();\n var scaleX = 1;\n var scaleY = 1;\n\n if (includeScale && isHTMLElement(element)) {\n scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;\n scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;\n }\n\n var _ref = isElement(element) ? getWindow(element) : window,\n visualViewport = _ref.visualViewport;\n\n var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;\n var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;\n var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;\n var width = clientRect.width / scaleX;\n var height = clientRect.height / scaleY;\n return {\n width: width,\n height: height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x: x,\n y: y\n };\n}", "import getBoundingClientRect from \"./getBoundingClientRect.js\"; // Returns the layout rect of an element relative to its offsetParent. Layout\n// means it doesn't take into account transforms.\n\nexport default function getLayoutRect(element) {\n var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.\n // Fixes https://github.com/popperjs/popper-core/issues/1223\n\n var width = element.offsetWidth;\n var height = element.offsetHeight;\n\n if (Math.abs(clientRect.width - width) <= 1) {\n width = clientRect.width;\n }\n\n if (Math.abs(clientRect.height - height) <= 1) {\n height = clientRect.height;\n }\n\n return {\n x: element.offsetLeft,\n y: element.offsetTop,\n width: width,\n height: height\n };\n}", "import { isShadowRoot } from \"./instanceOf.js\";\nexport default function contains(parent, child) {\n var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method\n\n if (parent.contains(child)) {\n return true;\n } // then fallback to custom implementation with Shadow DOM support\n else if (rootNode && isShadowRoot(rootNode)) {\n var next = child;\n\n do {\n if (next && parent.isSameNode(next)) {\n return true;\n } // $FlowFixMe[prop-missing]: need a better way to handle this...\n\n\n next = next.parentNode || next.host;\n } while (next);\n } // Give up, the result is false\n\n\n return false;\n}", "import getWindow from \"./getWindow.js\";\nexport default function getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}", "import getNodeName from \"./getNodeName.js\";\nexport default function isTableElement(element) {\n return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0;\n}", "import { isElement } from \"./instanceOf.js\";\nexport default function getDocumentElement(element) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]\n element.document) || window.document).documentElement;\n}", "import getNodeName from \"./getNodeName.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport { isShadowRoot } from \"./instanceOf.js\";\nexport default function getParentNode(element) {\n if (getNodeName(element) === 'html') {\n return element;\n }\n\n return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle\n // $FlowFixMe[incompatible-return]\n // $FlowFixMe[prop-missing]\n element.assignedSlot || // step into the shadow DOM of the parent of a slotted node\n element.parentNode || ( // DOM Element detected\n isShadowRoot(element) ? element.host : null) || // ShadowRoot detected\n // $FlowFixMe[incompatible-call]: HTMLElement is a Node\n getDocumentElement(element) // fallback\n\n );\n}", "import getWindow from \"./getWindow.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isHTMLElement, isShadowRoot } from \"./instanceOf.js\";\nimport isTableElement from \"./isTableElement.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getUAString from \"../utils/userAgent.js\";\n\nfunction getTrueOffsetParent(element) {\n if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837\n getComputedStyle(element).position === 'fixed') {\n return null;\n }\n\n return element.offsetParent;\n} // `.offsetParent` reports `null` for fixed elements, while absolute elements\n// return the containing block\n\n\nfunction getContainingBlock(element) {\n var isFirefox = /firefox/i.test(getUAString());\n var isIE = /Trident/i.test(getUAString());\n\n if (isIE && isHTMLElement(element)) {\n // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport\n var elementCss = getComputedStyle(element);\n\n if (elementCss.position === 'fixed') {\n return null;\n }\n }\n\n var currentNode = getParentNode(element);\n\n if (isShadowRoot(currentNode)) {\n currentNode = currentNode.host;\n }\n\n while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {\n var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n\n if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {\n return currentNode;\n } else {\n currentNode = currentNode.parentNode;\n }\n }\n\n return null;\n} // Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\n\n\nexport default function getOffsetParent(element) {\n var window = getWindow(element);\n var offsetParent = getTrueOffsetParent(element);\n\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent);\n }\n\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {\n return window;\n }\n\n return offsetParent || getContainingBlock(element) || window;\n}", "export default function getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';\n}", "import { max as mathMax, min as mathMin } from \"./math.js\";\nexport function within(min, value, max) {\n return mathMax(min, mathMin(value, max));\n}\nexport function withinMaxClamp(min, value, max) {\n var v = within(min, value, max);\n return v > max ? max : v;\n}", "export default function getFreshSideObject() {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n };\n}", "import getFreshSideObject from \"./getFreshSideObject.js\";\nexport default function mergePaddingObject(paddingObject) {\n return Object.assign({}, getFreshSideObject(), paddingObject);\n}", "export default function expandToHashMap(value, keys) {\n return keys.reduce(function (hashMap, key) {\n hashMap[key] = value;\n return hashMap;\n }, {});\n}", "import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport contains from \"../dom-utils/contains.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport { within } from \"../utils/within.js\";\nimport mergePaddingObject from \"../utils/mergePaddingObject.js\";\nimport expandToHashMap from \"../utils/expandToHashMap.js\";\nimport { left, right, basePlacements, top, bottom } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar toPaddingObject = function toPaddingObject(padding, state) {\n padding = typeof padding === 'function' ? padding(Object.assign({}, state.rects, {\n placement: state.placement\n })) : padding;\n return mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n};\n\nfunction arrow(_ref) {\n var _state$modifiersData$;\n\n var state = _ref.state,\n name = _ref.name,\n options = _ref.options;\n var arrowElement = state.elements.arrow;\n var popperOffsets = state.modifiersData.popperOffsets;\n var basePlacement = getBasePlacement(state.placement);\n var axis = getMainAxisFromPlacement(basePlacement);\n var isVertical = [left, right].indexOf(basePlacement) >= 0;\n var len = isVertical ? 'height' : 'width';\n\n if (!arrowElement || !popperOffsets) {\n return;\n }\n\n var paddingObject = toPaddingObject(options.padding, state);\n var arrowRect = getLayoutRect(arrowElement);\n var minProp = axis === 'y' ? top : left;\n var maxProp = axis === 'y' ? bottom : right;\n var endDiff = state.rects.reference[len] + state.rects.reference[axis] - popperOffsets[axis] - state.rects.popper[len];\n var startDiff = popperOffsets[axis] - state.rects.reference[axis];\n var arrowOffsetParent = getOffsetParent(arrowElement);\n var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n var centerToReference = endDiff / 2 - startDiff / 2; // Make sure the arrow doesn't overflow the popper if the center point is\n // outside of the popper bounds\n\n var min = paddingObject[minProp];\n var max = clientSize - arrowRect[len] - paddingObject[maxProp];\n var center = clientSize / 2 - arrowRect[len] / 2 + centerToReference;\n var offset = within(min, center, max); // Prevents breaking syntax highlighting...\n\n var axisProp = axis;\n state.modifiersData[name] = (_state$modifiersData$ = {}, _state$modifiersData$[axisProp] = offset, _state$modifiersData$.centerOffset = offset - center, _state$modifiersData$);\n}\n\nfunction effect(_ref2) {\n var state = _ref2.state,\n options = _ref2.options;\n var _options$element = options.element,\n arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element;\n\n if (arrowElement == null) {\n return;\n } // CSS selector\n\n\n if (typeof arrowElement === 'string') {\n arrowElement = state.elements.popper.querySelector(arrowElement);\n\n if (!arrowElement) {\n return;\n }\n }\n\n if (!contains(state.elements.popper, arrowElement)) {\n return;\n }\n\n state.elements.arrow = arrowElement;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'arrow',\n enabled: true,\n phase: 'main',\n fn: arrow,\n effect: effect,\n requires: ['popperOffsets'],\n requiresIfExists: ['preventOverflow']\n};", "export default function getVariation(placement) {\n return placement.split('-')[1];\n}", "import { top, left, right, bottom, end } from \"../enums.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport getWindow from \"../dom-utils/getWindow.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getComputedStyle from \"../dom-utils/getComputedStyle.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport { round } from \"../utils/math.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar unsetSides = {\n top: 'auto',\n right: 'auto',\n bottom: 'auto',\n left: 'auto'\n}; // Round the offsets to the nearest suitable subpixel based on the DPR.\n// Zooming can change the DPR, but it seems to report a value that will\n// cleanly divide the values into the appropriate subpixels.\n\nfunction roundOffsetsByDPR(_ref, win) {\n var x = _ref.x,\n y = _ref.y;\n var dpr = win.devicePixelRatio || 1;\n return {\n x: round(x * dpr) / dpr || 0,\n y: round(y * dpr) / dpr || 0\n };\n}\n\nexport function mapToStyles(_ref2) {\n var _Object$assign2;\n\n var popper = _ref2.popper,\n popperRect = _ref2.popperRect,\n placement = _ref2.placement,\n variation = _ref2.variation,\n offsets = _ref2.offsets,\n position = _ref2.position,\n gpuAcceleration = _ref2.gpuAcceleration,\n adaptive = _ref2.adaptive,\n roundOffsets = _ref2.roundOffsets,\n isFixed = _ref2.isFixed;\n var _offsets$x = offsets.x,\n x = _offsets$x === void 0 ? 0 : _offsets$x,\n _offsets$y = offsets.y,\n y = _offsets$y === void 0 ? 0 : _offsets$y;\n\n var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({\n x: x,\n y: y\n }) : {\n x: x,\n y: y\n };\n\n x = _ref3.x;\n y = _ref3.y;\n var hasX = offsets.hasOwnProperty('x');\n var hasY = offsets.hasOwnProperty('y');\n var sideX = left;\n var sideY = top;\n var win = window;\n\n if (adaptive) {\n var offsetParent = getOffsetParent(popper);\n var heightProp = 'clientHeight';\n var widthProp = 'clientWidth';\n\n if (offsetParent === getWindow(popper)) {\n offsetParent = getDocumentElement(popper);\n\n if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {\n heightProp = 'scrollHeight';\n widthProp = 'scrollWidth';\n }\n } // $FlowFixMe[incompatible-cast]: force type refinement, we compare offsetParent with window above, but Flow doesn't detect it\n\n\n offsetParent = offsetParent;\n\n if (placement === top || (placement === left || placement === right) && variation === end) {\n sideY = bottom;\n var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]\n offsetParent[heightProp];\n y -= offsetY - popperRect.height;\n y *= gpuAcceleration ? 1 : -1;\n }\n\n if (placement === left || (placement === top || placement === bottom) && variation === end) {\n sideX = right;\n var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]\n offsetParent[widthProp];\n x -= offsetX - popperRect.width;\n x *= gpuAcceleration ? 1 : -1;\n }\n }\n\n var commonStyles = Object.assign({\n position: position\n }, adaptive && unsetSides);\n\n var _ref4 = roundOffsets === true ? roundOffsetsByDPR({\n x: x,\n y: y\n }, getWindow(popper)) : {\n x: x,\n y: y\n };\n\n x = _ref4.x;\n y = _ref4.y;\n\n if (gpuAcceleration) {\n var _Object$assign;\n\n return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? \"translate(\" + x + \"px, \" + y + \"px)\" : \"translate3d(\" + x + \"px, \" + y + \"px, 0)\", _Object$assign));\n }\n\n return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + \"px\" : '', _Object$assign2[sideX] = hasX ? x + \"px\" : '', _Object$assign2.transform = '', _Object$assign2));\n}\n\nfunction computeStyles(_ref5) {\n var state = _ref5.state,\n options = _ref5.options;\n var _options$gpuAccelerat = options.gpuAcceleration,\n gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,\n _options$adaptive = options.adaptive,\n adaptive = _options$adaptive === void 0 ? true : _options$adaptive,\n _options$roundOffsets = options.roundOffsets,\n roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets;\n var commonStyles = {\n placement: getBasePlacement(state.placement),\n variation: getVariation(state.placement),\n popper: state.elements.popper,\n popperRect: state.rects.popper,\n gpuAcceleration: gpuAcceleration,\n isFixed: state.options.strategy === 'fixed'\n };\n\n if (state.modifiersData.popperOffsets != null) {\n state.styles.popper = Object.assign({}, state.styles.popper, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.popperOffsets,\n position: state.options.strategy,\n adaptive: adaptive,\n roundOffsets: roundOffsets\n })));\n }\n\n if (state.modifiersData.arrow != null) {\n state.styles.arrow = Object.assign({}, state.styles.arrow, mapToStyles(Object.assign({}, commonStyles, {\n offsets: state.modifiersData.arrow,\n position: 'absolute',\n adaptive: false,\n roundOffsets: roundOffsets\n })));\n }\n\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-placement': state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'computeStyles',\n enabled: true,\n phase: 'beforeWrite',\n fn: computeStyles,\n data: {}\n};", "import getWindow from \"../dom-utils/getWindow.js\"; // eslint-disable-next-line import/no-unused-modules\n\nvar passive = {\n passive: true\n};\n\nfunction effect(_ref) {\n var state = _ref.state,\n instance = _ref.instance,\n options = _ref.options;\n var _options$scroll = options.scroll,\n scroll = _options$scroll === void 0 ? true : _options$scroll,\n _options$resize = options.resize,\n resize = _options$resize === void 0 ? true : _options$resize;\n var window = getWindow(state.elements.popper);\n var scrollParents = [].concat(state.scrollParents.reference, state.scrollParents.popper);\n\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.addEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.addEventListener('resize', instance.update, passive);\n }\n\n return function () {\n if (scroll) {\n scrollParents.forEach(function (scrollParent) {\n scrollParent.removeEventListener('scroll', instance.update, passive);\n });\n }\n\n if (resize) {\n window.removeEventListener('resize', instance.update, passive);\n }\n };\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'eventListeners',\n enabled: true,\n phase: 'write',\n fn: function fn() {},\n effect: effect,\n data: {}\n};", "var hash = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nexport default function getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, function (matched) {\n return hash[matched];\n });\n}", "var hash = {\n start: 'end',\n end: 'start'\n};\nexport default function getOppositeVariationPlacement(placement) {\n return placement.replace(/start|end/g, function (matched) {\n return hash[matched];\n });\n}", "import getWindow from \"./getWindow.js\";\nexport default function getWindowScroll(node) {\n var win = getWindow(node);\n var scrollLeft = win.pageXOffset;\n var scrollTop = win.pageYOffset;\n return {\n scrollLeft: scrollLeft,\n scrollTop: scrollTop\n };\n}", "import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nexport default function getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n // Popper 1 is broken in this case and never had a bug report so let's assume\n // it's not an issue. I don't think anyone ever specifies width on \n // anyway.\n // Browsers where the left scrollbar doesn't cause an issue report `0` for\n // this (e.g. Edge 2019, IE11, Safari)\n return getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft;\n}", "import getWindow from \"./getWindow.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport isLayoutViewport from \"./isLayoutViewport.js\";\nexport default function getViewportRect(element, strategy) {\n var win = getWindow(element);\n var html = getDocumentElement(element);\n var visualViewport = win.visualViewport;\n var width = html.clientWidth;\n var height = html.clientHeight;\n var x = 0;\n var y = 0;\n\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n var layoutViewport = isLayoutViewport();\n\n if (layoutViewport || !layoutViewport && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n\n return {\n width: width,\n height: height,\n x: x + getWindowScrollBarX(element),\n y: y\n };\n}", "import getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getWindowScroll from \"./getWindowScroll.js\";\nimport { max } from \"../utils/math.js\"; // Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable\n\nexport default function getDocumentRect(element) {\n var _element$ownerDocumen;\n\n var html = getDocumentElement(element);\n var winScroll = getWindowScroll(element);\n var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;\n var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);\n var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);\n var x = -winScroll.scrollLeft + getWindowScrollBarX(element);\n var y = -winScroll.scrollTop;\n\n if (getComputedStyle(body || html).direction === 'rtl') {\n x += max(html.clientWidth, body ? body.clientWidth : 0) - width;\n }\n\n return {\n width: width,\n height: height,\n x: x,\n y: y\n };\n}", "import getComputedStyle from \"./getComputedStyle.js\";\nexport default function isScrollParent(element) {\n // Firefox wants us to check `-x` and `-y` variations as well\n var _getComputedStyle = getComputedStyle(element),\n overflow = _getComputedStyle.overflow,\n overflowX = _getComputedStyle.overflowX,\n overflowY = _getComputedStyle.overflowY;\n\n return /auto|scroll|overlay|hidden/.test(overflow + overflowY + overflowX);\n}", "import getParentNode from \"./getParentNode.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nexport default function getScrollParent(node) {\n if (['html', 'body', '#document'].indexOf(getNodeName(node)) >= 0) {\n // $FlowFixMe[incompatible-return]: assume body is always available\n return node.ownerDocument.body;\n }\n\n if (isHTMLElement(node) && isScrollParent(node)) {\n return node;\n }\n\n return getScrollParent(getParentNode(node));\n}", "import getScrollParent from \"./getScrollParent.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport getWindow from \"./getWindow.js\";\nimport isScrollParent from \"./isScrollParent.js\";\n/*\ngiven a DOM element, return the list of all scroll parents, up the list of ancesors\nuntil we get to the top window object. This list is what we attach scroll listeners\nto, because if any of these parent elements scroll, we'll need to re-calculate the\nreference element's position.\n*/\n\nexport default function listScrollParents(element, list) {\n var _element$ownerDocumen;\n\n if (list === void 0) {\n list = [];\n }\n\n var scrollParent = getScrollParent(element);\n var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body);\n var win = getWindow(scrollParent);\n var target = isBody ? [win].concat(win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : []) : scrollParent;\n var updatedList = list.concat(target);\n return isBody ? updatedList : // $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here\n updatedList.concat(listScrollParents(getParentNode(target)));\n}", "export default function rectToClientRect(rect) {\n return Object.assign({}, rect, {\n left: rect.x,\n top: rect.y,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n });\n}", "import { viewport } from \"../enums.js\";\nimport getViewportRect from \"./getViewportRect.js\";\nimport getDocumentRect from \"./getDocumentRect.js\";\nimport listScrollParents from \"./listScrollParents.js\";\nimport getOffsetParent from \"./getOffsetParent.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport getComputedStyle from \"./getComputedStyle.js\";\nimport { isElement, isHTMLElement } from \"./instanceOf.js\";\nimport getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getParentNode from \"./getParentNode.js\";\nimport contains from \"./contains.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport rectToClientRect from \"../utils/rectToClientRect.js\";\nimport { max, min } from \"../utils/math.js\";\n\nfunction getInnerBoundingClientRect(element, strategy) {\n var rect = getBoundingClientRect(element, false, strategy === 'fixed');\n rect.top = rect.top + element.clientTop;\n rect.left = rect.left + element.clientLeft;\n rect.bottom = rect.top + element.clientHeight;\n rect.right = rect.left + element.clientWidth;\n rect.width = element.clientWidth;\n rect.height = element.clientHeight;\n rect.x = rect.left;\n rect.y = rect.top;\n return rect;\n}\n\nfunction getClientRectFromMixedType(element, clippingParent, strategy) {\n return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));\n} // A \"clipping parent\" is an overflowable container with the characteristic of\n// clipping (or hiding) overflowing elements with a position different from\n// `initial`\n\n\nfunction getClippingParents(element) {\n var clippingParents = listScrollParents(getParentNode(element));\n var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;\n var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;\n\n if (!isElement(clipperElement)) {\n return [];\n } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414\n\n\n return clippingParents.filter(function (clippingParent) {\n return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';\n });\n} // Gets the maximum area that the element is visible in due to any number of\n// clipping parents\n\n\nexport default function getClippingRect(element, boundary, rootBoundary, strategy) {\n var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);\n var clippingParents = [].concat(mainClippingParents, [rootBoundary]);\n var firstClippingParent = clippingParents[0];\n var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {\n var rect = getClientRectFromMixedType(element, clippingParent, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromMixedType(element, firstClippingParent, strategy));\n clippingRect.width = clippingRect.right - clippingRect.left;\n clippingRect.height = clippingRect.bottom - clippingRect.top;\n clippingRect.x = clippingRect.left;\n clippingRect.y = clippingRect.top;\n return clippingRect;\n}", "import getBasePlacement from \"./getBasePlacement.js\";\nimport getVariation from \"./getVariation.js\";\nimport getMainAxisFromPlacement from \"./getMainAxisFromPlacement.js\";\nimport { top, right, bottom, left, start, end } from \"../enums.js\";\nexport default function computeOffsets(_ref) {\n var reference = _ref.reference,\n element = _ref.element,\n placement = _ref.placement;\n var basePlacement = placement ? getBasePlacement(placement) : null;\n var variation = placement ? getVariation(placement) : null;\n var commonX = reference.x + reference.width / 2 - element.width / 2;\n var commonY = reference.y + reference.height / 2 - element.height / 2;\n var offsets;\n\n switch (basePlacement) {\n case top:\n offsets = {\n x: commonX,\n y: reference.y - element.height\n };\n break;\n\n case bottom:\n offsets = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n\n case right:\n offsets = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n\n case left:\n offsets = {\n x: reference.x - element.width,\n y: commonY\n };\n break;\n\n default:\n offsets = {\n x: reference.x,\n y: reference.y\n };\n }\n\n var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null;\n\n if (mainAxis != null) {\n var len = mainAxis === 'y' ? 'height' : 'width';\n\n switch (variation) {\n case start:\n offsets[mainAxis] = offsets[mainAxis] - (reference[len] / 2 - element[len] / 2);\n break;\n\n case end:\n offsets[mainAxis] = offsets[mainAxis] + (reference[len] / 2 - element[len] / 2);\n break;\n\n default:\n }\n }\n\n return offsets;\n}", "import getClippingRect from \"../dom-utils/getClippingRect.js\";\nimport getDocumentElement from \"../dom-utils/getDocumentElement.js\";\nimport getBoundingClientRect from \"../dom-utils/getBoundingClientRect.js\";\nimport computeOffsets from \"./computeOffsets.js\";\nimport rectToClientRect from \"./rectToClientRect.js\";\nimport { clippingParents, reference, popper, bottom, top, right, basePlacements, viewport } from \"../enums.js\";\nimport { isElement } from \"../dom-utils/instanceOf.js\";\nimport mergePaddingObject from \"./mergePaddingObject.js\";\nimport expandToHashMap from \"./expandToHashMap.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport default function detectOverflow(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n _options$placement = _options.placement,\n placement = _options$placement === void 0 ? state.placement : _options$placement,\n _options$strategy = _options.strategy,\n strategy = _options$strategy === void 0 ? state.strategy : _options$strategy,\n _options$boundary = _options.boundary,\n boundary = _options$boundary === void 0 ? clippingParents : _options$boundary,\n _options$rootBoundary = _options.rootBoundary,\n rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary,\n _options$elementConte = _options.elementContext,\n elementContext = _options$elementConte === void 0 ? popper : _options$elementConte,\n _options$altBoundary = _options.altBoundary,\n altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary,\n _options$padding = _options.padding,\n padding = _options$padding === void 0 ? 0 : _options$padding;\n var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));\n var altContext = elementContext === popper ? reference : popper;\n var popperRect = state.rects.popper;\n var element = state.elements[altBoundary ? altContext : elementContext];\n var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary, strategy);\n var referenceClientRect = getBoundingClientRect(state.elements.reference);\n var popperOffsets = computeOffsets({\n reference: referenceClientRect,\n element: popperRect,\n strategy: 'absolute',\n placement: placement\n });\n var popperClientRect = rectToClientRect(Object.assign({}, popperRect, popperOffsets));\n var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect; // positive = overflowing the clipping rect\n // 0 or negative = within the clipping rect\n\n var overflowOffsets = {\n top: clippingClientRect.top - elementClientRect.top + paddingObject.top,\n bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom,\n left: clippingClientRect.left - elementClientRect.left + paddingObject.left,\n right: elementClientRect.right - clippingClientRect.right + paddingObject.right\n };\n var offsetData = state.modifiersData.offset; // Offsets can be applied only to the popper element\n\n if (elementContext === popper && offsetData) {\n var offset = offsetData[placement];\n Object.keys(overflowOffsets).forEach(function (key) {\n var multiply = [right, bottom].indexOf(key) >= 0 ? 1 : -1;\n var axis = [top, bottom].indexOf(key) >= 0 ? 'y' : 'x';\n overflowOffsets[key] += offset[axis] * multiply;\n });\n }\n\n return overflowOffsets;\n}", "import getVariation from \"./getVariation.js\";\nimport { variationPlacements, basePlacements, placements as allPlacements } from \"../enums.js\";\nimport detectOverflow from \"./detectOverflow.js\";\nimport getBasePlacement from \"./getBasePlacement.js\";\nexport default function computeAutoPlacement(state, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _options = options,\n placement = _options.placement,\n boundary = _options.boundary,\n rootBoundary = _options.rootBoundary,\n padding = _options.padding,\n flipVariations = _options.flipVariations,\n _options$allowedAutoP = _options.allowedAutoPlacements,\n allowedAutoPlacements = _options$allowedAutoP === void 0 ? allPlacements : _options$allowedAutoP;\n var variation = getVariation(placement);\n var placements = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement) {\n return getVariation(placement) === variation;\n }) : basePlacements;\n var allowedPlacements = placements.filter(function (placement) {\n return allowedAutoPlacements.indexOf(placement) >= 0;\n });\n\n if (allowedPlacements.length === 0) {\n allowedPlacements = placements;\n } // $FlowFixMe[incompatible-type]: Flow seems to have problems with two array unions...\n\n\n var overflows = allowedPlacements.reduce(function (acc, placement) {\n acc[placement] = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding\n })[getBasePlacement(placement)];\n return acc;\n }, {});\n return Object.keys(overflows).sort(function (a, b) {\n return overflows[a] - overflows[b];\n });\n}", "import getOppositePlacement from \"../utils/getOppositePlacement.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getOppositeVariationPlacement from \"../utils/getOppositeVariationPlacement.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport computeAutoPlacement from \"../utils/computeAutoPlacement.js\";\nimport { bottom, top, start, right, left, auto } from \"../enums.js\";\nimport getVariation from \"../utils/getVariation.js\"; // eslint-disable-next-line import/no-unused-modules\n\nfunction getExpandedFallbackPlacements(placement) {\n if (getBasePlacement(placement) === auto) {\n return [];\n }\n\n var oppositePlacement = getOppositePlacement(placement);\n return [getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement)];\n}\n\nfunction flip(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n\n if (state.modifiersData[name]._skip) {\n return;\n }\n\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis,\n specifiedFallbackPlacements = options.fallbackPlacements,\n padding = options.padding,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n _options$flipVariatio = options.flipVariations,\n flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio,\n allowedAutoPlacements = options.allowedAutoPlacements;\n var preferredPlacement = state.options.placement;\n var basePlacement = getBasePlacement(preferredPlacement);\n var isBasePlacement = basePlacement === preferredPlacement;\n var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement));\n var placements = [preferredPlacement].concat(fallbackPlacements).reduce(function (acc, placement) {\n return acc.concat(getBasePlacement(placement) === auto ? computeAutoPlacement(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n flipVariations: flipVariations,\n allowedAutoPlacements: allowedAutoPlacements\n }) : placement);\n }, []);\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var checksMap = new Map();\n var makeFallbackChecks = true;\n var firstFittingPlacement = placements[0];\n\n for (var i = 0; i < placements.length; i++) {\n var placement = placements[i];\n\n var _basePlacement = getBasePlacement(placement);\n\n var isStartVariation = getVariation(placement) === start;\n var isVertical = [top, bottom].indexOf(_basePlacement) >= 0;\n var len = isVertical ? 'width' : 'height';\n var overflow = detectOverflow(state, {\n placement: placement,\n boundary: boundary,\n rootBoundary: rootBoundary,\n altBoundary: altBoundary,\n padding: padding\n });\n var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top;\n\n if (referenceRect[len] > popperRect[len]) {\n mainVariationSide = getOppositePlacement(mainVariationSide);\n }\n\n var altVariationSide = getOppositePlacement(mainVariationSide);\n var checks = [];\n\n if (checkMainAxis) {\n checks.push(overflow[_basePlacement] <= 0);\n }\n\n if (checkAltAxis) {\n checks.push(overflow[mainVariationSide] <= 0, overflow[altVariationSide] <= 0);\n }\n\n if (checks.every(function (check) {\n return check;\n })) {\n firstFittingPlacement = placement;\n makeFallbackChecks = false;\n break;\n }\n\n checksMap.set(placement, checks);\n }\n\n if (makeFallbackChecks) {\n // `2` may be desired in some cases \u2013 research later\n var numberOfChecks = flipVariations ? 3 : 1;\n\n var _loop = function _loop(_i) {\n var fittingPlacement = placements.find(function (placement) {\n var checks = checksMap.get(placement);\n\n if (checks) {\n return checks.slice(0, _i).every(function (check) {\n return check;\n });\n }\n });\n\n if (fittingPlacement) {\n firstFittingPlacement = fittingPlacement;\n return \"break\";\n }\n };\n\n for (var _i = numberOfChecks; _i > 0; _i--) {\n var _ret = _loop(_i);\n\n if (_ret === \"break\") break;\n }\n }\n\n if (state.placement !== firstFittingPlacement) {\n state.modifiersData[name]._skip = true;\n state.placement = firstFittingPlacement;\n state.reset = true;\n }\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'flip',\n enabled: true,\n phase: 'main',\n fn: flip,\n requiresIfExists: ['offset'],\n data: {\n _skip: false\n }\n};", "import { top, bottom, left, right } from \"../enums.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\n\nfunction getSideOffsets(overflow, rect, preventedOffsets) {\n if (preventedOffsets === void 0) {\n preventedOffsets = {\n x: 0,\n y: 0\n };\n }\n\n return {\n top: overflow.top - rect.height - preventedOffsets.y,\n right: overflow.right - rect.width + preventedOffsets.x,\n bottom: overflow.bottom - rect.height + preventedOffsets.y,\n left: overflow.left - rect.width - preventedOffsets.x\n };\n}\n\nfunction isAnySideFullyClipped(overflow) {\n return [top, right, bottom, left].some(function (side) {\n return overflow[side] >= 0;\n });\n}\n\nfunction hide(_ref) {\n var state = _ref.state,\n name = _ref.name;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var preventedOffsets = state.modifiersData.preventOverflow;\n var referenceOverflow = detectOverflow(state, {\n elementContext: 'reference'\n });\n var popperAltOverflow = detectOverflow(state, {\n altBoundary: true\n });\n var referenceClippingOffsets = getSideOffsets(referenceOverflow, referenceRect);\n var popperEscapeOffsets = getSideOffsets(popperAltOverflow, popperRect, preventedOffsets);\n var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets);\n var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets);\n state.modifiersData[name] = {\n referenceClippingOffsets: referenceClippingOffsets,\n popperEscapeOffsets: popperEscapeOffsets,\n isReferenceHidden: isReferenceHidden,\n hasPopperEscaped: hasPopperEscaped\n };\n state.attributes.popper = Object.assign({}, state.attributes.popper, {\n 'data-popper-reference-hidden': isReferenceHidden,\n 'data-popper-escaped': hasPopperEscaped\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'hide',\n enabled: true,\n phase: 'main',\n requiresIfExists: ['preventOverflow'],\n fn: hide\n};", "import getBasePlacement from \"../utils/getBasePlacement.js\";\nimport { top, left, right, placements } from \"../enums.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport function distanceAndSkiddingToXY(placement, rects, offset) {\n var basePlacement = getBasePlacement(placement);\n var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1;\n\n var _ref = typeof offset === 'function' ? offset(Object.assign({}, rects, {\n placement: placement\n })) : offset,\n skidding = _ref[0],\n distance = _ref[1];\n\n skidding = skidding || 0;\n distance = (distance || 0) * invertDistance;\n return [left, right].indexOf(basePlacement) >= 0 ? {\n x: distance,\n y: skidding\n } : {\n x: skidding,\n y: distance\n };\n}\n\nfunction offset(_ref2) {\n var state = _ref2.state,\n options = _ref2.options,\n name = _ref2.name;\n var _options$offset = options.offset,\n offset = _options$offset === void 0 ? [0, 0] : _options$offset;\n var data = placements.reduce(function (acc, placement) {\n acc[placement] = distanceAndSkiddingToXY(placement, state.rects, offset);\n return acc;\n }, {});\n var _data$state$placement = data[state.placement],\n x = _data$state$placement.x,\n y = _data$state$placement.y;\n\n if (state.modifiersData.popperOffsets != null) {\n state.modifiersData.popperOffsets.x += x;\n state.modifiersData.popperOffsets.y += y;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'offset',\n enabled: true,\n phase: 'main',\n requires: ['popperOffsets'],\n fn: offset\n};", "import computeOffsets from \"../utils/computeOffsets.js\";\n\nfunction popperOffsets(_ref) {\n var state = _ref.state,\n name = _ref.name;\n // Offsets are the actual position the popper needs to have to be\n // properly positioned near its reference element\n // This is the most basic placement, and will be adjusted by\n // the modifiers in the next step\n state.modifiersData[name] = computeOffsets({\n reference: state.rects.reference,\n element: state.rects.popper,\n strategy: 'absolute',\n placement: state.placement\n });\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'popperOffsets',\n enabled: true,\n phase: 'read',\n fn: popperOffsets,\n data: {}\n};", "export default function getAltAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}", "import { top, left, right, bottom, start } from \"../enums.js\";\nimport getBasePlacement from \"../utils/getBasePlacement.js\";\nimport getMainAxisFromPlacement from \"../utils/getMainAxisFromPlacement.js\";\nimport getAltAxis from \"../utils/getAltAxis.js\";\nimport { within, withinMaxClamp } from \"../utils/within.js\";\nimport getLayoutRect from \"../dom-utils/getLayoutRect.js\";\nimport getOffsetParent from \"../dom-utils/getOffsetParent.js\";\nimport detectOverflow from \"../utils/detectOverflow.js\";\nimport getVariation from \"../utils/getVariation.js\";\nimport getFreshSideObject from \"../utils/getFreshSideObject.js\";\nimport { min as mathMin, max as mathMax } from \"../utils/math.js\";\n\nfunction preventOverflow(_ref) {\n var state = _ref.state,\n options = _ref.options,\n name = _ref.name;\n var _options$mainAxis = options.mainAxis,\n checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis,\n _options$altAxis = options.altAxis,\n checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis,\n boundary = options.boundary,\n rootBoundary = options.rootBoundary,\n altBoundary = options.altBoundary,\n padding = options.padding,\n _options$tether = options.tether,\n tether = _options$tether === void 0 ? true : _options$tether,\n _options$tetherOffset = options.tetherOffset,\n tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset;\n var overflow = detectOverflow(state, {\n boundary: boundary,\n rootBoundary: rootBoundary,\n padding: padding,\n altBoundary: altBoundary\n });\n var basePlacement = getBasePlacement(state.placement);\n var variation = getVariation(state.placement);\n var isBasePlacement = !variation;\n var mainAxis = getMainAxisFromPlacement(basePlacement);\n var altAxis = getAltAxis(mainAxis);\n var popperOffsets = state.modifiersData.popperOffsets;\n var referenceRect = state.rects.reference;\n var popperRect = state.rects.popper;\n var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {\n placement: state.placement\n })) : tetherOffset;\n var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {\n mainAxis: tetherOffsetValue,\n altAxis: tetherOffsetValue\n } : Object.assign({\n mainAxis: 0,\n altAxis: 0\n }, tetherOffsetValue);\n var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;\n var data = {\n x: 0,\n y: 0\n };\n\n if (!popperOffsets) {\n return;\n }\n\n if (checkMainAxis) {\n var _offsetModifierState$;\n\n var mainSide = mainAxis === 'y' ? top : left;\n var altSide = mainAxis === 'y' ? bottom : right;\n var len = mainAxis === 'y' ? 'height' : 'width';\n var offset = popperOffsets[mainAxis];\n var min = offset + overflow[mainSide];\n var max = offset - overflow[altSide];\n var additive = tether ? -popperRect[len] / 2 : 0;\n var minLen = variation === start ? referenceRect[len] : popperRect[len];\n var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go\n // outside the reference bounds\n\n var arrowElement = state.elements.arrow;\n var arrowRect = tether && arrowElement ? getLayoutRect(arrowElement) : {\n width: 0,\n height: 0\n };\n var arrowPaddingObject = state.modifiersData['arrow#persistent'] ? state.modifiersData['arrow#persistent'].padding : getFreshSideObject();\n var arrowPaddingMin = arrowPaddingObject[mainSide];\n var arrowPaddingMax = arrowPaddingObject[altSide]; // If the reference length is smaller than the arrow length, we don't want\n // to include its full size in the calculation. If the reference is small\n // and near the edge of a boundary, the popper can overflow even if the\n // reference is not overflowing as well (e.g. virtual elements with no\n // width or height)\n\n var arrowLen = within(0, referenceRect[len], arrowRect[len]);\n var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;\n var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;\n var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);\n var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;\n var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;\n var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;\n var tetherMax = offset + maxOffset - offsetModifierValue;\n var preventedOffset = within(tether ? mathMin(min, tetherMin) : min, offset, tether ? mathMax(max, tetherMax) : max);\n popperOffsets[mainAxis] = preventedOffset;\n data[mainAxis] = preventedOffset - offset;\n }\n\n if (checkAltAxis) {\n var _offsetModifierState$2;\n\n var _mainSide = mainAxis === 'x' ? top : left;\n\n var _altSide = mainAxis === 'x' ? bottom : right;\n\n var _offset = popperOffsets[altAxis];\n\n var _len = altAxis === 'y' ? 'height' : 'width';\n\n var _min = _offset + overflow[_mainSide];\n\n var _max = _offset - overflow[_altSide];\n\n var isOriginSide = [top, left].indexOf(basePlacement) !== -1;\n\n var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;\n\n var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;\n\n var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;\n\n var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);\n\n popperOffsets[altAxis] = _preventedOffset;\n data[altAxis] = _preventedOffset - _offset;\n }\n\n state.modifiersData[name] = data;\n} // eslint-disable-next-line import/no-unused-modules\n\n\nexport default {\n name: 'preventOverflow',\n enabled: true,\n phase: 'main',\n fn: preventOverflow,\n requiresIfExists: ['offset']\n};", "export default function getHTMLElementScroll(element) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n}", "import getWindowScroll from \"./getWindowScroll.js\";\nimport getWindow from \"./getWindow.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getHTMLElementScroll from \"./getHTMLElementScroll.js\";\nexport default function getNodeScroll(node) {\n if (node === getWindow(node) || !isHTMLElement(node)) {\n return getWindowScroll(node);\n } else {\n return getHTMLElementScroll(node);\n }\n}", "import getBoundingClientRect from \"./getBoundingClientRect.js\";\nimport getNodeScroll from \"./getNodeScroll.js\";\nimport getNodeName from \"./getNodeName.js\";\nimport { isHTMLElement } from \"./instanceOf.js\";\nimport getWindowScrollBarX from \"./getWindowScrollBarX.js\";\nimport getDocumentElement from \"./getDocumentElement.js\";\nimport isScrollParent from \"./isScrollParent.js\";\nimport { round } from \"../utils/math.js\";\n\nfunction isElementScaled(element) {\n var rect = element.getBoundingClientRect();\n var scaleX = round(rect.width) / element.offsetWidth || 1;\n var scaleY = round(rect.height) / element.offsetHeight || 1;\n return scaleX !== 1 || scaleY !== 1;\n} // Returns the composite rect of an element relative to its offsetParent.\n// Composite means it takes into account transforms as well as layout.\n\n\nexport default function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {\n if (isFixed === void 0) {\n isFixed = false;\n }\n\n var isOffsetParentAnElement = isHTMLElement(offsetParent);\n var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);\n var documentElement = getDocumentElement(offsetParent);\n var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);\n var scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n var offsets = {\n x: 0,\n y: 0\n };\n\n if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078\n isScrollParent(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n\n if (isHTMLElement(offsetParent)) {\n offsets = getBoundingClientRect(offsetParent, true);\n offsets.x += offsetParent.clientLeft;\n offsets.y += offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}", "import { modifierPhases } from \"../enums.js\"; // source: https://stackoverflow.com/questions/49875255\n\nfunction order(modifiers) {\n var map = new Map();\n var visited = new Set();\n var result = [];\n modifiers.forEach(function (modifier) {\n map.set(modifier.name, modifier);\n }); // On visiting object, check for its dependencies and visit them recursively\n\n function sort(modifier) {\n visited.add(modifier.name);\n var requires = [].concat(modifier.requires || [], modifier.requiresIfExists || []);\n requires.forEach(function (dep) {\n if (!visited.has(dep)) {\n var depModifier = map.get(dep);\n\n if (depModifier) {\n sort(depModifier);\n }\n }\n });\n result.push(modifier);\n }\n\n modifiers.forEach(function (modifier) {\n if (!visited.has(modifier.name)) {\n // check for visited object\n sort(modifier);\n }\n });\n return result;\n}\n\nexport default function orderModifiers(modifiers) {\n // order based on dependencies\n var orderedModifiers = order(modifiers); // order based on phase\n\n return modifierPhases.reduce(function (acc, phase) {\n return acc.concat(orderedModifiers.filter(function (modifier) {\n return modifier.phase === phase;\n }));\n }, []);\n}", "export default function debounce(fn) {\n var pending;\n return function () {\n if (!pending) {\n pending = new Promise(function (resolve) {\n Promise.resolve().then(function () {\n pending = undefined;\n resolve(fn());\n });\n });\n }\n\n return pending;\n };\n}", "export default function mergeByName(modifiers) {\n var merged = modifiers.reduce(function (merged, current) {\n var existing = merged[current.name];\n merged[current.name] = existing ? Object.assign({}, existing, current, {\n options: Object.assign({}, existing.options, current.options),\n data: Object.assign({}, existing.data, current.data)\n }) : current;\n return merged;\n }, {}); // IE11 does not support Object.values\n\n return Object.keys(merged).map(function (key) {\n return merged[key];\n });\n}", "import getCompositeRect from \"./dom-utils/getCompositeRect.js\";\nimport getLayoutRect from \"./dom-utils/getLayoutRect.js\";\nimport listScrollParents from \"./dom-utils/listScrollParents.js\";\nimport getOffsetParent from \"./dom-utils/getOffsetParent.js\";\nimport orderModifiers from \"./utils/orderModifiers.js\";\nimport debounce from \"./utils/debounce.js\";\nimport mergeByName from \"./utils/mergeByName.js\";\nimport detectOverflow from \"./utils/detectOverflow.js\";\nimport { isElement } from \"./dom-utils/instanceOf.js\";\nvar DEFAULT_OPTIONS = {\n placement: 'bottom',\n modifiers: [],\n strategy: 'absolute'\n};\n\nfunction areValidElements() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n\n return !args.some(function (element) {\n return !(element && typeof element.getBoundingClientRect === 'function');\n });\n}\n\nexport function popperGenerator(generatorOptions) {\n if (generatorOptions === void 0) {\n generatorOptions = {};\n }\n\n var _generatorOptions = generatorOptions,\n _generatorOptions$def = _generatorOptions.defaultModifiers,\n defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,\n _generatorOptions$def2 = _generatorOptions.defaultOptions,\n defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;\n return function createPopper(reference, popper, options) {\n if (options === void 0) {\n options = defaultOptions;\n }\n\n var state = {\n placement: 'bottom',\n orderedModifiers: [],\n options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),\n modifiersData: {},\n elements: {\n reference: reference,\n popper: popper\n },\n attributes: {},\n styles: {}\n };\n var effectCleanupFns = [];\n var isDestroyed = false;\n var instance = {\n state: state,\n setOptions: function setOptions(setOptionsAction) {\n var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;\n cleanupModifierEffects();\n state.options = Object.assign({}, defaultOptions, state.options, options);\n state.scrollParents = {\n reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],\n popper: listScrollParents(popper)\n }; // Orders the modifiers based on their dependencies and `phase`\n // properties\n\n var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers\n\n state.orderedModifiers = orderedModifiers.filter(function (m) {\n return m.enabled;\n });\n runModifierEffects();\n return instance.update();\n },\n // Sync update \u2013 it will always be executed, even if not necessary. This\n // is useful for low frequency updates where sync behavior simplifies the\n // logic.\n // For high frequency updates (e.g. `resize` and `scroll` events), always\n // prefer the async Popper#update method\n forceUpdate: function forceUpdate() {\n if (isDestroyed) {\n return;\n }\n\n var _state$elements = state.elements,\n reference = _state$elements.reference,\n popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements\n // anymore\n\n if (!areValidElements(reference, popper)) {\n return;\n } // Store the reference and popper rects to be read by modifiers\n\n\n state.rects = {\n reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),\n popper: getLayoutRect(popper)\n }; // Modifiers have the ability to reset the current update cycle. The\n // most common use case for this is the `flip` modifier changing the\n // placement, which then needs to re-run all the modifiers, because the\n // logic was previously ran for the previous placement and is therefore\n // stale/incorrect\n\n state.reset = false;\n state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier\n // is filled with the initial data specified by the modifier. This means\n // it doesn't persist and is fresh on each update.\n // To ensure persistent data, use `${name}#persistent`\n\n state.orderedModifiers.forEach(function (modifier) {\n return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);\n });\n\n for (var index = 0; index < state.orderedModifiers.length; index++) {\n if (state.reset === true) {\n state.reset = false;\n index = -1;\n continue;\n }\n\n var _state$orderedModifie = state.orderedModifiers[index],\n fn = _state$orderedModifie.fn,\n _state$orderedModifie2 = _state$orderedModifie.options,\n _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,\n name = _state$orderedModifie.name;\n\n if (typeof fn === 'function') {\n state = fn({\n state: state,\n options: _options,\n name: name,\n instance: instance\n }) || state;\n }\n }\n },\n // Async and optimistically optimized update \u2013 it will not be executed if\n // not necessary (debounced to run at most once-per-tick)\n update: debounce(function () {\n return new Promise(function (resolve) {\n instance.forceUpdate();\n resolve(state);\n });\n }),\n destroy: function destroy() {\n cleanupModifierEffects();\n isDestroyed = true;\n }\n };\n\n if (!areValidElements(reference, popper)) {\n return instance;\n }\n\n instance.setOptions(options).then(function (state) {\n if (!isDestroyed && options.onFirstUpdate) {\n options.onFirstUpdate(state);\n }\n }); // Modifiers have the ability to execute arbitrary code before the first\n // update cycle runs. They will be executed in the same order as the update\n // cycle. This is useful when a modifier adds some persistent data that\n // other modifiers need to use, but the modifier is run after the dependent\n // one.\n\n function runModifierEffects() {\n state.orderedModifiers.forEach(function (_ref) {\n var name = _ref.name,\n _ref$options = _ref.options,\n options = _ref$options === void 0 ? {} : _ref$options,\n effect = _ref.effect;\n\n if (typeof effect === 'function') {\n var cleanupFn = effect({\n state: state,\n name: name,\n instance: instance,\n options: options\n });\n\n var noopFn = function noopFn() {};\n\n effectCleanupFns.push(cleanupFn || noopFn);\n }\n });\n }\n\n function cleanupModifierEffects() {\n effectCleanupFns.forEach(function (fn) {\n return fn();\n });\n effectCleanupFns = [];\n }\n\n return instance;\n };\n}\nexport var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules\n\nexport { detectOverflow };", "import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow };", "import { popperGenerator, detectOverflow } from \"./createPopper.js\";\nimport eventListeners from \"./modifiers/eventListeners.js\";\nimport popperOffsets from \"./modifiers/popperOffsets.js\";\nimport computeStyles from \"./modifiers/computeStyles.js\";\nimport applyStyles from \"./modifiers/applyStyles.js\";\nimport offset from \"./modifiers/offset.js\";\nimport flip from \"./modifiers/flip.js\";\nimport preventOverflow from \"./modifiers/preventOverflow.js\";\nimport arrow from \"./modifiers/arrow.js\";\nimport hide from \"./modifiers/hide.js\";\nvar defaultModifiers = [eventListeners, popperOffsets, computeStyles, applyStyles, offset, flip, preventOverflow, arrow, hide];\nvar createPopper = /*#__PURE__*/popperGenerator({\n defaultModifiers: defaultModifiers\n}); // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper, popperGenerator, defaultModifiers, detectOverflow }; // eslint-disable-next-line import/no-unused-modules\n\nexport { createPopper as createPopperLite } from \"./popper-lite.js\"; // eslint-disable-next-line import/no-unused-modules\n\nexport * from \"./modifiers/index.js\";", "/**\n * --------------------------------------------------------------------------\n * Bootstrap dom/data.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\n/**\n * Constants\n */\n\nconst elementMap = new Map()\n\nexport default {\n set(element, key, instance) {\n if (!elementMap.has(element)) {\n elementMap.set(element, new Map())\n }\n\n const instanceMap = elementMap.get(element)\n\n // make it clear we only want one instance per element\n // can be removed later when multiple key/instances are fine to be used\n if (!instanceMap.has(key) && instanceMap.size !== 0) {\n // eslint-disable-next-line no-console\n console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(instanceMap.keys())[0]}.`)\n return\n }\n\n instanceMap.set(key, instance)\n },\n\n get(element, key) {\n if (elementMap.has(element)) {\n return elementMap.get(element).get(key) || null\n }\n\n return null\n },\n\n remove(element, key) {\n if (!elementMap.has(element)) {\n return\n }\n\n const instanceMap = elementMap.get(element)\n\n instanceMap.delete(key)\n\n // free up element references if there are no instances left for an element\n if (instanceMap.size === 0) {\n elementMap.delete(element)\n }\n }\n}\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/index.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nconst MAX_UID = 1_000_000\nconst MILLISECONDS_MULTIPLIER = 1000\nconst TRANSITION_END = 'transitionend'\n\n/**\n * Properly escape IDs selectors to handle weird IDs\n * @param {string} selector\n * @returns {string}\n */\nconst parseSelector = selector => {\n if (selector && window.CSS && window.CSS.escape) {\n // document.querySelector needs escaping to handle IDs (html5+) containing for instance /\n selector = selector.replace(/#([^\\s\"#']+)/g, (match, id) => `#${CSS.escape(id)}`)\n }\n\n return selector\n}\n\n// Shout-out Angus Croll (https://goo.gl/pxwQGp)\nconst toType = object => {\n if (object === null || object === undefined) {\n return `${object}`\n }\n\n return Object.prototype.toString.call(object).match(/\\s([a-z]+)/i)[1].toLowerCase()\n}\n\n/**\n * Public Util API\n */\n\nconst getUID = prefix => {\n do {\n prefix += Math.floor(Math.random() * MAX_UID)\n } while (document.getElementById(prefix))\n\n return prefix\n}\n\nconst getTransitionDurationFromElement = element => {\n if (!element) {\n return 0\n }\n\n // Get transition-duration of the element\n let { transitionDuration, transitionDelay } = window.getComputedStyle(element)\n\n const floatTransitionDuration = Number.parseFloat(transitionDuration)\n const floatTransitionDelay = Number.parseFloat(transitionDelay)\n\n // Return 0 if element or transition duration is not found\n if (!floatTransitionDuration && !floatTransitionDelay) {\n return 0\n }\n\n // If multiple durations are defined, take the first\n transitionDuration = transitionDuration.split(',')[0]\n transitionDelay = transitionDelay.split(',')[0]\n\n return (Number.parseFloat(transitionDuration) + Number.parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER\n}\n\nconst triggerTransitionEnd = element => {\n element.dispatchEvent(new Event(TRANSITION_END))\n}\n\nconst isElement = object => {\n if (!object || typeof object !== 'object') {\n return false\n }\n\n if (typeof object.jquery !== 'undefined') {\n object = object[0]\n }\n\n return typeof object.nodeType !== 'undefined'\n}\n\nconst getElement = object => {\n // it's a jQuery object or a node element\n if (isElement(object)) {\n return object.jquery ? object[0] : object\n }\n\n if (typeof object === 'string' && object.length > 0) {\n return document.querySelector(parseSelector(object))\n }\n\n return null\n}\n\nconst isVisible = element => {\n if (!isElement(element) || element.getClientRects().length === 0) {\n return false\n }\n\n const elementIsVisible = getComputedStyle(element).getPropertyValue('visibility') === 'visible'\n // Handle `details` element as its content may falsie appear visible when it is closed\n const closedDetails = element.closest('details:not([open])')\n\n if (!closedDetails) {\n return elementIsVisible\n }\n\n if (closedDetails !== element) {\n const summary = element.closest('summary')\n if (summary && summary.parentNode !== closedDetails) {\n return false\n }\n\n if (summary === null) {\n return false\n }\n }\n\n return elementIsVisible\n}\n\nconst isDisabled = element => {\n if (!element || element.nodeType !== Node.ELEMENT_NODE) {\n return true\n }\n\n if (element.classList.contains('disabled')) {\n return true\n }\n\n if (typeof element.disabled !== 'undefined') {\n return element.disabled\n }\n\n return element.hasAttribute('disabled') && element.getAttribute('disabled') !== 'false'\n}\n\nconst findShadowRoot = element => {\n if (!document.documentElement.attachShadow) {\n return null\n }\n\n // Can find the shadow root otherwise it'll return the document\n if (typeof element.getRootNode === 'function') {\n const root = element.getRootNode()\n return root instanceof ShadowRoot ? root : null\n }\n\n if (element instanceof ShadowRoot) {\n return element\n }\n\n // when we don't find a shadow root\n if (!element.parentNode) {\n return null\n }\n\n return findShadowRoot(element.parentNode)\n}\n\nconst noop = () => {}\n\n/**\n * Trick to restart an element's animation\n *\n * @param {HTMLElement} element\n * @return void\n *\n * @see https://www.charistheo.io/blog/2021/02/restart-a-css-animation-with-javascript/#restarting-a-css-animation\n */\nconst reflow = element => {\n element.offsetHeight // eslint-disable-line no-unused-expressions\n}\n\nconst getjQuery = () => {\n if (window.jQuery && !document.body.hasAttribute('data-bs-no-jquery')) {\n return window.jQuery\n }\n\n return null\n}\n\nconst DOMContentLoadedCallbacks = []\n\nconst onDOMContentLoaded = callback => {\n if (document.readyState === 'loading') {\n // add listener on the first call when the document is in loading state\n if (!DOMContentLoadedCallbacks.length) {\n document.addEventListener('DOMContentLoaded', () => {\n for (const callback of DOMContentLoadedCallbacks) {\n callback()\n }\n })\n }\n\n DOMContentLoadedCallbacks.push(callback)\n } else {\n callback()\n }\n}\n\nconst isRTL = () => document.documentElement.dir === 'rtl'\n\nconst defineJQueryPlugin = plugin => {\n onDOMContentLoaded(() => {\n const $ = getjQuery()\n /* istanbul ignore if */\n if ($) {\n const name = plugin.NAME\n const JQUERY_NO_CONFLICT = $.fn[name]\n $.fn[name] = plugin.jQueryInterface\n $.fn[name].Constructor = plugin\n $.fn[name].noConflict = () => {\n $.fn[name] = JQUERY_NO_CONFLICT\n return plugin.jQueryInterface\n }\n }\n })\n}\n\nconst execute = (possibleCallback, args = [], defaultValue = possibleCallback) => {\n return typeof possibleCallback === 'function' ? possibleCallback(...args) : defaultValue\n}\n\nconst executeAfterTransition = (callback, transitionElement, waitForTransition = true) => {\n if (!waitForTransition) {\n execute(callback)\n return\n }\n\n const durationPadding = 5\n const emulatedDuration = getTransitionDurationFromElement(transitionElement) + durationPadding\n\n let called = false\n\n const handler = ({ target }) => {\n if (target !== transitionElement) {\n return\n }\n\n called = true\n transitionElement.removeEventListener(TRANSITION_END, handler)\n execute(callback)\n }\n\n transitionElement.addEventListener(TRANSITION_END, handler)\n setTimeout(() => {\n if (!called) {\n triggerTransitionEnd(transitionElement)\n }\n }, emulatedDuration)\n}\n\n/**\n * Return the previous/next element of a list.\n *\n * @param {array} list The list of elements\n * @param activeElement The active element\n * @param shouldGetNext Choose to get next or previous element\n * @param isCycleAllowed\n * @return {Element|elem} The proper element\n */\nconst getNextActiveElement = (list, activeElement, shouldGetNext, isCycleAllowed) => {\n const listLength = list.length\n let index = list.indexOf(activeElement)\n\n // if the element does not exist in the list return an element\n // depending on the direction and if cycle is allowed\n if (index === -1) {\n return !shouldGetNext && isCycleAllowed ? list[listLength - 1] : list[0]\n }\n\n index += shouldGetNext ? 1 : -1\n\n if (isCycleAllowed) {\n index = (index + listLength) % listLength\n }\n\n return list[Math.max(0, Math.min(index, listLength - 1))]\n}\n\nexport {\n defineJQueryPlugin,\n execute,\n executeAfterTransition,\n findShadowRoot,\n getElement,\n getjQuery,\n getNextActiveElement,\n getTransitionDurationFromElement,\n getUID,\n isDisabled,\n isElement,\n isRTL,\n isVisible,\n noop,\n onDOMContentLoaded,\n parseSelector,\n reflow,\n triggerTransitionEnd,\n toType\n}\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap dom/event-handler.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport { getjQuery } from '../util/index.js'\n\n/**\n * Constants\n */\n\nconst namespaceRegex = /[^.]*(?=\\..*)\\.|.*/\nconst stripNameRegex = /\\..*/\nconst stripUidRegex = /::\\d+$/\nconst eventRegistry = {} // Events storage\nlet uidEvent = 1\nconst customEvents = {\n mouseenter: 'mouseover',\n mouseleave: 'mouseout'\n}\n\nconst nativeEvents = new Set([\n 'click',\n 'dblclick',\n 'mouseup',\n 'mousedown',\n 'contextmenu',\n 'mousewheel',\n 'DOMMouseScroll',\n 'mouseover',\n 'mouseout',\n 'mousemove',\n 'selectstart',\n 'selectend',\n 'keydown',\n 'keypress',\n 'keyup',\n 'orientationchange',\n 'touchstart',\n 'touchmove',\n 'touchend',\n 'touchcancel',\n 'pointerdown',\n 'pointermove',\n 'pointerup',\n 'pointerleave',\n 'pointercancel',\n 'gesturestart',\n 'gesturechange',\n 'gestureend',\n 'focus',\n 'blur',\n 'change',\n 'reset',\n 'select',\n 'submit',\n 'focusin',\n 'focusout',\n 'load',\n 'unload',\n 'beforeunload',\n 'resize',\n 'move',\n 'DOMContentLoaded',\n 'readystatechange',\n 'error',\n 'abort',\n 'scroll'\n])\n\n/**\n * Private methods\n */\n\nfunction makeEventUid(element, uid) {\n return (uid && `${uid}::${uidEvent++}`) || element.uidEvent || uidEvent++\n}\n\nfunction getElementEvents(element) {\n const uid = makeEventUid(element)\n\n element.uidEvent = uid\n eventRegistry[uid] = eventRegistry[uid] || {}\n\n return eventRegistry[uid]\n}\n\nfunction bootstrapHandler(element, fn) {\n return function handler(event) {\n hydrateObj(event, { delegateTarget: element })\n\n if (handler.oneOff) {\n EventHandler.off(element, event.type, fn)\n }\n\n return fn.apply(element, [event])\n }\n}\n\nfunction bootstrapDelegationHandler(element, selector, fn) {\n return function handler(event) {\n const domElements = element.querySelectorAll(selector)\n\n for (let { target } = event; target && target !== this; target = target.parentNode) {\n for (const domElement of domElements) {\n if (domElement !== target) {\n continue\n }\n\n hydrateObj(event, { delegateTarget: target })\n\n if (handler.oneOff) {\n EventHandler.off(element, event.type, selector, fn)\n }\n\n return fn.apply(target, [event])\n }\n }\n }\n}\n\nfunction findHandler(events, callable, delegationSelector = null) {\n return Object.values(events)\n .find(event => event.callable === callable && event.delegationSelector === delegationSelector)\n}\n\nfunction normalizeParameters(originalTypeEvent, handler, delegationFunction) {\n const isDelegated = typeof handler === 'string'\n // TODO: tooltip passes `false` instead of selector, so we need to check\n const callable = isDelegated ? delegationFunction : (handler || delegationFunction)\n let typeEvent = getTypeEvent(originalTypeEvent)\n\n if (!nativeEvents.has(typeEvent)) {\n typeEvent = originalTypeEvent\n }\n\n return [isDelegated, callable, typeEvent]\n}\n\nfunction addHandler(element, originalTypeEvent, handler, delegationFunction, oneOff) {\n if (typeof originalTypeEvent !== 'string' || !element) {\n return\n }\n\n let [isDelegated, callable, typeEvent] = normalizeParameters(originalTypeEvent, handler, delegationFunction)\n\n // in case of mouseenter or mouseleave wrap the handler within a function that checks for its DOM position\n // this prevents the handler from being dispatched the same way as mouseover or mouseout does\n if (originalTypeEvent in customEvents) {\n const wrapFunction = fn => {\n return function (event) {\n if (!event.relatedTarget || (event.relatedTarget !== event.delegateTarget && !event.delegateTarget.contains(event.relatedTarget))) {\n return fn.call(this, event)\n }\n }\n }\n\n callable = wrapFunction(callable)\n }\n\n const events = getElementEvents(element)\n const handlers = events[typeEvent] || (events[typeEvent] = {})\n const previousFunction = findHandler(handlers, callable, isDelegated ? handler : null)\n\n if (previousFunction) {\n previousFunction.oneOff = previousFunction.oneOff && oneOff\n\n return\n }\n\n const uid = makeEventUid(callable, originalTypeEvent.replace(namespaceRegex, ''))\n const fn = isDelegated ?\n bootstrapDelegationHandler(element, handler, callable) :\n bootstrapHandler(element, callable)\n\n fn.delegationSelector = isDelegated ? handler : null\n fn.callable = callable\n fn.oneOff = oneOff\n fn.uidEvent = uid\n handlers[uid] = fn\n\n element.addEventListener(typeEvent, fn, isDelegated)\n}\n\nfunction removeHandler(element, events, typeEvent, handler, delegationSelector) {\n const fn = findHandler(events[typeEvent], handler, delegationSelector)\n\n if (!fn) {\n return\n }\n\n element.removeEventListener(typeEvent, fn, Boolean(delegationSelector))\n delete events[typeEvent][fn.uidEvent]\n}\n\nfunction removeNamespacedHandlers(element, events, typeEvent, namespace) {\n const storeElementEvent = events[typeEvent] || {}\n\n for (const [handlerKey, event] of Object.entries(storeElementEvent)) {\n if (handlerKey.includes(namespace)) {\n removeHandler(element, events, typeEvent, event.callable, event.delegationSelector)\n }\n }\n}\n\nfunction getTypeEvent(event) {\n // allow to get the native events from namespaced events ('click.bs.button' --> 'click')\n event = event.replace(stripNameRegex, '')\n return customEvents[event] || event\n}\n\nconst EventHandler = {\n on(element, event, handler, delegationFunction) {\n addHandler(element, event, handler, delegationFunction, false)\n },\n\n one(element, event, handler, delegationFunction) {\n addHandler(element, event, handler, delegationFunction, true)\n },\n\n off(element, originalTypeEvent, handler, delegationFunction) {\n if (typeof originalTypeEvent !== 'string' || !element) {\n return\n }\n\n const [isDelegated, callable, typeEvent] = normalizeParameters(originalTypeEvent, handler, delegationFunction)\n const inNamespace = typeEvent !== originalTypeEvent\n const events = getElementEvents(element)\n const storeElementEvent = events[typeEvent] || {}\n const isNamespace = originalTypeEvent.startsWith('.')\n\n if (typeof callable !== 'undefined') {\n // Simplest case: handler is passed, remove that listener ONLY.\n if (!Object.keys(storeElementEvent).length) {\n return\n }\n\n removeHandler(element, events, typeEvent, callable, isDelegated ? handler : null)\n return\n }\n\n if (isNamespace) {\n for (const elementEvent of Object.keys(events)) {\n removeNamespacedHandlers(element, events, elementEvent, originalTypeEvent.slice(1))\n }\n }\n\n for (const [keyHandlers, event] of Object.entries(storeElementEvent)) {\n const handlerKey = keyHandlers.replace(stripUidRegex, '')\n\n if (!inNamespace || originalTypeEvent.includes(handlerKey)) {\n removeHandler(element, events, typeEvent, event.callable, event.delegationSelector)\n }\n }\n },\n\n trigger(element, event, args) {\n if (typeof event !== 'string' || !element) {\n return null\n }\n\n const $ = getjQuery()\n const typeEvent = getTypeEvent(event)\n const inNamespace = event !== typeEvent\n\n let jQueryEvent = null\n let bubbles = true\n let nativeDispatch = true\n let defaultPrevented = false\n\n if (inNamespace && $) {\n jQueryEvent = $.Event(event, args)\n\n $(element).trigger(jQueryEvent)\n bubbles = !jQueryEvent.isPropagationStopped()\n nativeDispatch = !jQueryEvent.isImmediatePropagationStopped()\n defaultPrevented = jQueryEvent.isDefaultPrevented()\n }\n\n const evt = hydrateObj(new Event(event, { bubbles, cancelable: true }), args)\n\n if (defaultPrevented) {\n evt.preventDefault()\n }\n\n if (nativeDispatch) {\n element.dispatchEvent(evt)\n }\n\n if (evt.defaultPrevented && jQueryEvent) {\n jQueryEvent.preventDefault()\n }\n\n return evt\n }\n}\n\nfunction hydrateObj(obj, meta = {}) {\n for (const [key, value] of Object.entries(meta)) {\n try {\n obj[key] = value\n } catch {\n Object.defineProperty(obj, key, {\n configurable: true,\n get() {\n return value\n }\n })\n }\n }\n\n return obj\n}\n\nexport default EventHandler\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap dom/manipulator.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nfunction normalizeData(value) {\n if (value === 'true') {\n return true\n }\n\n if (value === 'false') {\n return false\n }\n\n if (value === Number(value).toString()) {\n return Number(value)\n }\n\n if (value === '' || value === 'null') {\n return null\n }\n\n if (typeof value !== 'string') {\n return value\n }\n\n try {\n return JSON.parse(decodeURIComponent(value))\n } catch {\n return value\n }\n}\n\nfunction normalizeDataKey(key) {\n return key.replace(/[A-Z]/g, chr => `-${chr.toLowerCase()}`)\n}\n\nconst Manipulator = {\n setDataAttribute(element, key, value) {\n element.setAttribute(`data-bs-${normalizeDataKey(key)}`, value)\n },\n\n removeDataAttribute(element, key) {\n element.removeAttribute(`data-bs-${normalizeDataKey(key)}`)\n },\n\n getDataAttributes(element) {\n if (!element) {\n return {}\n }\n\n const attributes = {}\n const bsKeys = Object.keys(element.dataset).filter(key => key.startsWith('bs') && !key.startsWith('bsConfig'))\n\n for (const key of bsKeys) {\n let pureKey = key.replace(/^bs/, '')\n pureKey = pureKey.charAt(0).toLowerCase() + pureKey.slice(1, pureKey.length)\n attributes[pureKey] = normalizeData(element.dataset[key])\n }\n\n return attributes\n },\n\n getDataAttribute(element, key) {\n return normalizeData(element.getAttribute(`data-bs-${normalizeDataKey(key)}`))\n }\n}\n\nexport default Manipulator\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/config.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport Manipulator from '../dom/manipulator.js'\nimport { isElement, toType } from './index.js'\n\n/**\n * Class definition\n */\n\nclass Config {\n // Getters\n static get Default() {\n return {}\n }\n\n static get DefaultType() {\n return {}\n }\n\n static get NAME() {\n throw new Error('You have to implement the static method \"NAME\", for each component!')\n }\n\n _getConfig(config) {\n config = this._mergeConfigObj(config)\n config = this._configAfterMerge(config)\n this._typeCheckConfig(config)\n return config\n }\n\n _configAfterMerge(config) {\n return config\n }\n\n _mergeConfigObj(config, element) {\n const jsonConfig = isElement(element) ? Manipulator.getDataAttribute(element, 'config') : {} // try to parse\n\n return {\n ...this.constructor.Default,\n ...(typeof jsonConfig === 'object' ? jsonConfig : {}),\n ...(isElement(element) ? Manipulator.getDataAttributes(element) : {}),\n ...(typeof config === 'object' ? config : {})\n }\n }\n\n _typeCheckConfig(config, configTypes = this.constructor.DefaultType) {\n for (const [property, expectedTypes] of Object.entries(configTypes)) {\n const value = config[property]\n const valueType = isElement(value) ? 'element' : toType(value)\n\n if (!new RegExp(expectedTypes).test(valueType)) {\n throw new TypeError(\n `${this.constructor.NAME.toUpperCase()}: Option \"${property}\" provided type \"${valueType}\" but expected type \"${expectedTypes}\".`\n )\n }\n }\n }\n}\n\nexport default Config\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap base-component.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport Data from './dom/data.js'\nimport EventHandler from './dom/event-handler.js'\nimport Config from './util/config.js'\nimport { executeAfterTransition, getElement } from './util/index.js'\n\n/**\n * Constants\n */\n\nconst VERSION = '5.3.2'\n\n/**\n * Class definition\n */\n\nclass BaseComponent extends Config {\n constructor(element, config) {\n super()\n\n element = getElement(element)\n if (!element) {\n return\n }\n\n this._element = element\n this._config = this._getConfig(config)\n\n Data.set(this._element, this.constructor.DATA_KEY, this)\n }\n\n // Public\n dispose() {\n Data.remove(this._element, this.constructor.DATA_KEY)\n EventHandler.off(this._element, this.constructor.EVENT_KEY)\n\n for (const propertyName of Object.getOwnPropertyNames(this)) {\n this[propertyName] = null\n }\n }\n\n _queueCallback(callback, element, isAnimated = true) {\n executeAfterTransition(callback, element, isAnimated)\n }\n\n _getConfig(config) {\n config = this._mergeConfigObj(config, this._element)\n config = this._configAfterMerge(config)\n this._typeCheckConfig(config)\n return config\n }\n\n // Static\n static getInstance(element) {\n return Data.get(getElement(element), this.DATA_KEY)\n }\n\n static getOrCreateInstance(element, config = {}) {\n return this.getInstance(element) || new this(element, typeof config === 'object' ? config : null)\n }\n\n static get VERSION() {\n return VERSION\n }\n\n static get DATA_KEY() {\n return `bs.${this.NAME}`\n }\n\n static get EVENT_KEY() {\n return `.${this.DATA_KEY}`\n }\n\n static eventName(name) {\n return `${name}${this.EVENT_KEY}`\n }\n}\n\nexport default BaseComponent\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap dom/selector-engine.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport { isDisabled, isVisible, parseSelector } from '../util/index.js'\n\nconst getSelector = element => {\n let selector = element.getAttribute('data-bs-target')\n\n if (!selector || selector === '#') {\n let hrefAttribute = element.getAttribute('href')\n\n // The only valid content that could double as a selector are IDs or classes,\n // so everything starting with `#` or `.`. If a \"real\" URL is used as the selector,\n // `document.querySelector` will rightfully complain it is invalid.\n // See https://github.com/twbs/bootstrap/issues/32273\n if (!hrefAttribute || (!hrefAttribute.includes('#') && !hrefAttribute.startsWith('.'))) {\n return null\n }\n\n // Just in case some CMS puts out a full URL with the anchor appended\n if (hrefAttribute.includes('#') && !hrefAttribute.startsWith('#')) {\n hrefAttribute = `#${hrefAttribute.split('#')[1]}`\n }\n\n selector = hrefAttribute && hrefAttribute !== '#' ? parseSelector(hrefAttribute.trim()) : null\n }\n\n return selector\n}\n\nconst SelectorEngine = {\n find(selector, element = document.documentElement) {\n return [].concat(...Element.prototype.querySelectorAll.call(element, selector))\n },\n\n findOne(selector, element = document.documentElement) {\n return Element.prototype.querySelector.call(element, selector)\n },\n\n children(element, selector) {\n return [].concat(...element.children).filter(child => child.matches(selector))\n },\n\n parents(element, selector) {\n const parents = []\n let ancestor = element.parentNode.closest(selector)\n\n while (ancestor) {\n parents.push(ancestor)\n ancestor = ancestor.parentNode.closest(selector)\n }\n\n return parents\n },\n\n prev(element, selector) {\n let previous = element.previousElementSibling\n\n while (previous) {\n if (previous.matches(selector)) {\n return [previous]\n }\n\n previous = previous.previousElementSibling\n }\n\n return []\n },\n // TODO: this is now unused; remove later along with prev()\n next(element, selector) {\n let next = element.nextElementSibling\n\n while (next) {\n if (next.matches(selector)) {\n return [next]\n }\n\n next = next.nextElementSibling\n }\n\n return []\n },\n\n focusableChildren(element) {\n const focusables = [\n 'a',\n 'button',\n 'input',\n 'textarea',\n 'select',\n 'details',\n '[tabindex]',\n '[contenteditable=\"true\"]'\n ].map(selector => `${selector}:not([tabindex^=\"-\"])`).join(',')\n\n return this.find(focusables, element).filter(el => !isDisabled(el) && isVisible(el))\n },\n\n getSelectorFromElement(element) {\n const selector = getSelector(element)\n\n if (selector) {\n return SelectorEngine.findOne(selector) ? selector : null\n }\n\n return null\n },\n\n getElementFromSelector(element) {\n const selector = getSelector(element)\n\n return selector ? SelectorEngine.findOne(selector) : null\n },\n\n getMultipleElementsFromSelector(element) {\n const selector = getSelector(element)\n\n return selector ? SelectorEngine.find(selector) : []\n }\n}\n\nexport default SelectorEngine\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/component-functions.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport EventHandler from '../dom/event-handler.js'\nimport SelectorEngine from '../dom/selector-engine.js'\nimport { isDisabled } from './index.js'\n\nconst enableDismissTrigger = (component, method = 'hide') => {\n const clickEvent = `click.dismiss${component.EVENT_KEY}`\n const name = component.NAME\n\n EventHandler.on(document, clickEvent, `[data-bs-dismiss=\"${name}\"]`, function (event) {\n if (['A', 'AREA'].includes(this.tagName)) {\n event.preventDefault()\n }\n\n if (isDisabled(this)) {\n return\n }\n\n const target = SelectorEngine.getElementFromSelector(this) || this.closest(`.${name}`)\n const instance = component.getOrCreateInstance(target)\n\n // Method argument is left, for Alert and only, as it doesn't implement the 'hide' method\n instance[method]()\n })\n}\n\nexport {\n enableDismissTrigger\n}\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap alert.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport { enableDismissTrigger } from './util/component-functions.js'\nimport { defineJQueryPlugin } from './util/index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'alert'\nconst DATA_KEY = 'bs.alert'\nconst EVENT_KEY = `.${DATA_KEY}`\n\nconst EVENT_CLOSE = `close${EVENT_KEY}`\nconst EVENT_CLOSED = `closed${EVENT_KEY}`\nconst CLASS_NAME_FADE = 'fade'\nconst CLASS_NAME_SHOW = 'show'\n\n/**\n * Class definition\n */\n\nclass Alert extends BaseComponent {\n // Getters\n static get NAME() {\n return NAME\n }\n\n // Public\n close() {\n const closeEvent = EventHandler.trigger(this._element, EVENT_CLOSE)\n\n if (closeEvent.defaultPrevented) {\n return\n }\n\n this._element.classList.remove(CLASS_NAME_SHOW)\n\n const isAnimated = this._element.classList.contains(CLASS_NAME_FADE)\n this._queueCallback(() => this._destroyElement(), this._element, isAnimated)\n }\n\n // Private\n _destroyElement() {\n this._element.remove()\n EventHandler.trigger(this._element, EVENT_CLOSED)\n this.dispose()\n }\n\n // Static\n static jQueryInterface(config) {\n return this.each(function () {\n const data = Alert.getOrCreateInstance(this)\n\n if (typeof config !== 'string') {\n return\n }\n\n if (data[config] === undefined || config.startsWith('_') || config === 'constructor') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config](this)\n })\n }\n}\n\n/**\n * Data API implementation\n */\n\nenableDismissTrigger(Alert, 'close')\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Alert)\n\nexport default Alert\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap button.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport { defineJQueryPlugin } from './util/index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'button'\nconst DATA_KEY = 'bs.button'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst DATA_API_KEY = '.data-api'\n\nconst CLASS_NAME_ACTIVE = 'active'\nconst SELECTOR_DATA_TOGGLE = '[data-bs-toggle=\"button\"]'\nconst EVENT_CLICK_DATA_API = `click${EVENT_KEY}${DATA_API_KEY}`\n\n/**\n * Class definition\n */\n\nclass Button extends BaseComponent {\n // Getters\n static get NAME() {\n return NAME\n }\n\n // Public\n toggle() {\n // Toggle class and sync the `aria-pressed` attribute with the return value of the `.toggle()` method\n this._element.setAttribute('aria-pressed', this._element.classList.toggle(CLASS_NAME_ACTIVE))\n }\n\n // Static\n static jQueryInterface(config) {\n return this.each(function () {\n const data = Button.getOrCreateInstance(this)\n\n if (config === 'toggle') {\n data[config]()\n }\n })\n }\n}\n\n/**\n * Data API implementation\n */\n\nEventHandler.on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, event => {\n event.preventDefault()\n\n const button = event.target.closest(SELECTOR_DATA_TOGGLE)\n const data = Button.getOrCreateInstance(button)\n\n data.toggle()\n})\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Button)\n\nexport default Button\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/swipe.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport EventHandler from '../dom/event-handler.js'\nimport Config from './config.js'\nimport { execute } from './index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'swipe'\nconst EVENT_KEY = '.bs.swipe'\nconst EVENT_TOUCHSTART = `touchstart${EVENT_KEY}`\nconst EVENT_TOUCHMOVE = `touchmove${EVENT_KEY}`\nconst EVENT_TOUCHEND = `touchend${EVENT_KEY}`\nconst EVENT_POINTERDOWN = `pointerdown${EVENT_KEY}`\nconst EVENT_POINTERUP = `pointerup${EVENT_KEY}`\nconst POINTER_TYPE_TOUCH = 'touch'\nconst POINTER_TYPE_PEN = 'pen'\nconst CLASS_NAME_POINTER_EVENT = 'pointer-event'\nconst SWIPE_THRESHOLD = 40\n\nconst Default = {\n endCallback: null,\n leftCallback: null,\n rightCallback: null\n}\n\nconst DefaultType = {\n endCallback: '(function|null)',\n leftCallback: '(function|null)',\n rightCallback: '(function|null)'\n}\n\n/**\n * Class definition\n */\n\nclass Swipe extends Config {\n constructor(element, config) {\n super()\n this._element = element\n\n if (!element || !Swipe.isSupported()) {\n return\n }\n\n this._config = this._getConfig(config)\n this._deltaX = 0\n this._supportPointerEvents = Boolean(window.PointerEvent)\n this._initEvents()\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n dispose() {\n EventHandler.off(this._element, EVENT_KEY)\n }\n\n // Private\n _start(event) {\n if (!this._supportPointerEvents) {\n this._deltaX = event.touches[0].clientX\n\n return\n }\n\n if (this._eventIsPointerPenTouch(event)) {\n this._deltaX = event.clientX\n }\n }\n\n _end(event) {\n if (this._eventIsPointerPenTouch(event)) {\n this._deltaX = event.clientX - this._deltaX\n }\n\n this._handleSwipe()\n execute(this._config.endCallback)\n }\n\n _move(event) {\n this._deltaX = event.touches && event.touches.length > 1 ?\n 0 :\n event.touches[0].clientX - this._deltaX\n }\n\n _handleSwipe() {\n const absDeltaX = Math.abs(this._deltaX)\n\n if (absDeltaX <= SWIPE_THRESHOLD) {\n return\n }\n\n const direction = absDeltaX / this._deltaX\n\n this._deltaX = 0\n\n if (!direction) {\n return\n }\n\n execute(direction > 0 ? this._config.rightCallback : this._config.leftCallback)\n }\n\n _initEvents() {\n if (this._supportPointerEvents) {\n EventHandler.on(this._element, EVENT_POINTERDOWN, event => this._start(event))\n EventHandler.on(this._element, EVENT_POINTERUP, event => this._end(event))\n\n this._element.classList.add(CLASS_NAME_POINTER_EVENT)\n } else {\n EventHandler.on(this._element, EVENT_TOUCHSTART, event => this._start(event))\n EventHandler.on(this._element, EVENT_TOUCHMOVE, event => this._move(event))\n EventHandler.on(this._element, EVENT_TOUCHEND, event => this._end(event))\n }\n }\n\n _eventIsPointerPenTouch(event) {\n return this._supportPointerEvents && (event.pointerType === POINTER_TYPE_PEN || event.pointerType === POINTER_TYPE_TOUCH)\n }\n\n // Static\n static isSupported() {\n return 'ontouchstart' in document.documentElement || navigator.maxTouchPoints > 0\n }\n}\n\nexport default Swipe\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap carousel.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport Manipulator from './dom/manipulator.js'\nimport SelectorEngine from './dom/selector-engine.js'\nimport {\n defineJQueryPlugin,\n getNextActiveElement,\n isRTL,\n isVisible,\n reflow,\n triggerTransitionEnd\n} from './util/index.js'\nimport Swipe from './util/swipe.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'carousel'\nconst DATA_KEY = 'bs.carousel'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst DATA_API_KEY = '.data-api'\n\nconst ARROW_LEFT_KEY = 'ArrowLeft'\nconst ARROW_RIGHT_KEY = 'ArrowRight'\nconst TOUCHEVENT_COMPAT_WAIT = 500 // Time for mouse compat events to fire after touch\n\nconst ORDER_NEXT = 'next'\nconst ORDER_PREV = 'prev'\nconst DIRECTION_LEFT = 'left'\nconst DIRECTION_RIGHT = 'right'\n\nconst EVENT_SLIDE = `slide${EVENT_KEY}`\nconst EVENT_SLID = `slid${EVENT_KEY}`\nconst EVENT_KEYDOWN = `keydown${EVENT_KEY}`\nconst EVENT_MOUSEENTER = `mouseenter${EVENT_KEY}`\nconst EVENT_MOUSELEAVE = `mouseleave${EVENT_KEY}`\nconst EVENT_DRAG_START = `dragstart${EVENT_KEY}`\nconst EVENT_LOAD_DATA_API = `load${EVENT_KEY}${DATA_API_KEY}`\nconst EVENT_CLICK_DATA_API = `click${EVENT_KEY}${DATA_API_KEY}`\n\nconst CLASS_NAME_CAROUSEL = 'carousel'\nconst CLASS_NAME_ACTIVE = 'active'\nconst CLASS_NAME_SLIDE = 'slide'\nconst CLASS_NAME_END = 'carousel-item-end'\nconst CLASS_NAME_START = 'carousel-item-start'\nconst CLASS_NAME_NEXT = 'carousel-item-next'\nconst CLASS_NAME_PREV = 'carousel-item-prev'\n\nconst SELECTOR_ACTIVE = '.active'\nconst SELECTOR_ITEM = '.carousel-item'\nconst SELECTOR_ACTIVE_ITEM = SELECTOR_ACTIVE + SELECTOR_ITEM\nconst SELECTOR_ITEM_IMG = '.carousel-item img'\nconst SELECTOR_INDICATORS = '.carousel-indicators'\nconst SELECTOR_DATA_SLIDE = '[data-bs-slide], [data-bs-slide-to]'\nconst SELECTOR_DATA_RIDE = '[data-bs-ride=\"carousel\"]'\n\nconst KEY_TO_DIRECTION = {\n [ARROW_LEFT_KEY]: DIRECTION_RIGHT,\n [ARROW_RIGHT_KEY]: DIRECTION_LEFT\n}\n\nconst Default = {\n interval: 5000,\n keyboard: true,\n pause: 'hover',\n ride: false,\n touch: true,\n wrap: true\n}\n\nconst DefaultType = {\n interval: '(number|boolean)', // TODO:v6 remove boolean support\n keyboard: 'boolean',\n pause: '(string|boolean)',\n ride: '(boolean|string)',\n touch: 'boolean',\n wrap: 'boolean'\n}\n\n/**\n * Class definition\n */\n\nclass Carousel extends BaseComponent {\n constructor(element, config) {\n super(element, config)\n\n this._interval = null\n this._activeElement = null\n this._isSliding = false\n this.touchTimeout = null\n this._swipeHelper = null\n\n this._indicatorsElement = SelectorEngine.findOne(SELECTOR_INDICATORS, this._element)\n this._addEventListeners()\n\n if (this._config.ride === CLASS_NAME_CAROUSEL) {\n this.cycle()\n }\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n next() {\n this._slide(ORDER_NEXT)\n }\n\n nextWhenVisible() {\n // FIXME TODO use `document.visibilityState`\n // Don't call next when the page isn't visible\n // or the carousel or its parent isn't visible\n if (!document.hidden && isVisible(this._element)) {\n this.next()\n }\n }\n\n prev() {\n this._slide(ORDER_PREV)\n }\n\n pause() {\n if (this._isSliding) {\n triggerTransitionEnd(this._element)\n }\n\n this._clearInterval()\n }\n\n cycle() {\n this._clearInterval()\n this._updateInterval()\n\n this._interval = setInterval(() => this.nextWhenVisible(), this._config.interval)\n }\n\n _maybeEnableCycle() {\n if (!this._config.ride) {\n return\n }\n\n if (this._isSliding) {\n EventHandler.one(this._element, EVENT_SLID, () => this.cycle())\n return\n }\n\n this.cycle()\n }\n\n to(index) {\n const items = this._getItems()\n if (index > items.length - 1 || index < 0) {\n return\n }\n\n if (this._isSliding) {\n EventHandler.one(this._element, EVENT_SLID, () => this.to(index))\n return\n }\n\n const activeIndex = this._getItemIndex(this._getActive())\n if (activeIndex === index) {\n return\n }\n\n const order = index > activeIndex ? ORDER_NEXT : ORDER_PREV\n\n this._slide(order, items[index])\n }\n\n dispose() {\n if (this._swipeHelper) {\n this._swipeHelper.dispose()\n }\n\n super.dispose()\n }\n\n // Private\n _configAfterMerge(config) {\n config.defaultInterval = config.interval\n return config\n }\n\n _addEventListeners() {\n if (this._config.keyboard) {\n EventHandler.on(this._element, EVENT_KEYDOWN, event => this._keydown(event))\n }\n\n if (this._config.pause === 'hover') {\n EventHandler.on(this._element, EVENT_MOUSEENTER, () => this.pause())\n EventHandler.on(this._element, EVENT_MOUSELEAVE, () => this._maybeEnableCycle())\n }\n\n if (this._config.touch && Swipe.isSupported()) {\n this._addTouchEventListeners()\n }\n }\n\n _addTouchEventListeners() {\n for (const img of SelectorEngine.find(SELECTOR_ITEM_IMG, this._element)) {\n EventHandler.on(img, EVENT_DRAG_START, event => event.preventDefault())\n }\n\n const endCallBack = () => {\n if (this._config.pause !== 'hover') {\n return\n }\n\n // If it's a touch-enabled device, mouseenter/leave are fired as\n // part of the mouse compatibility events on first tap - the carousel\n // would stop cycling until user tapped out of it;\n // here, we listen for touchend, explicitly pause the carousel\n // (as if it's the second time we tap on it, mouseenter compat event\n // is NOT fired) and after a timeout (to allow for mouse compatibility\n // events to fire) we explicitly restart cycling\n\n this.pause()\n if (this.touchTimeout) {\n clearTimeout(this.touchTimeout)\n }\n\n this.touchTimeout = setTimeout(() => this._maybeEnableCycle(), TOUCHEVENT_COMPAT_WAIT + this._config.interval)\n }\n\n const swipeConfig = {\n leftCallback: () => this._slide(this._directionToOrder(DIRECTION_LEFT)),\n rightCallback: () => this._slide(this._directionToOrder(DIRECTION_RIGHT)),\n endCallback: endCallBack\n }\n\n this._swipeHelper = new Swipe(this._element, swipeConfig)\n }\n\n _keydown(event) {\n if (/input|textarea/i.test(event.target.tagName)) {\n return\n }\n\n const direction = KEY_TO_DIRECTION[event.key]\n if (direction) {\n event.preventDefault()\n this._slide(this._directionToOrder(direction))\n }\n }\n\n _getItemIndex(element) {\n return this._getItems().indexOf(element)\n }\n\n _setActiveIndicatorElement(index) {\n if (!this._indicatorsElement) {\n return\n }\n\n const activeIndicator = SelectorEngine.findOne(SELECTOR_ACTIVE, this._indicatorsElement)\n\n activeIndicator.classList.remove(CLASS_NAME_ACTIVE)\n activeIndicator.removeAttribute('aria-current')\n\n const newActiveIndicator = SelectorEngine.findOne(`[data-bs-slide-to=\"${index}\"]`, this._indicatorsElement)\n\n if (newActiveIndicator) {\n newActiveIndicator.classList.add(CLASS_NAME_ACTIVE)\n newActiveIndicator.setAttribute('aria-current', 'true')\n }\n }\n\n _updateInterval() {\n const element = this._activeElement || this._getActive()\n\n if (!element) {\n return\n }\n\n const elementInterval = Number.parseInt(element.getAttribute('data-bs-interval'), 10)\n\n this._config.interval = elementInterval || this._config.defaultInterval\n }\n\n _slide(order, element = null) {\n if (this._isSliding) {\n return\n }\n\n const activeElement = this._getActive()\n const isNext = order === ORDER_NEXT\n const nextElement = element || getNextActiveElement(this._getItems(), activeElement, isNext, this._config.wrap)\n\n if (nextElement === activeElement) {\n return\n }\n\n const nextElementIndex = this._getItemIndex(nextElement)\n\n const triggerEvent = eventName => {\n return EventHandler.trigger(this._element, eventName, {\n relatedTarget: nextElement,\n direction: this._orderToDirection(order),\n from: this._getItemIndex(activeElement),\n to: nextElementIndex\n })\n }\n\n const slideEvent = triggerEvent(EVENT_SLIDE)\n\n if (slideEvent.defaultPrevented) {\n return\n }\n\n if (!activeElement || !nextElement) {\n // Some weirdness is happening, so we bail\n // TODO: change tests that use empty divs to avoid this check\n return\n }\n\n const isCycling = Boolean(this._interval)\n this.pause()\n\n this._isSliding = true\n\n this._setActiveIndicatorElement(nextElementIndex)\n this._activeElement = nextElement\n\n const directionalClassName = isNext ? CLASS_NAME_START : CLASS_NAME_END\n const orderClassName = isNext ? CLASS_NAME_NEXT : CLASS_NAME_PREV\n\n nextElement.classList.add(orderClassName)\n\n reflow(nextElement)\n\n activeElement.classList.add(directionalClassName)\n nextElement.classList.add(directionalClassName)\n\n const completeCallBack = () => {\n nextElement.classList.remove(directionalClassName, orderClassName)\n nextElement.classList.add(CLASS_NAME_ACTIVE)\n\n activeElement.classList.remove(CLASS_NAME_ACTIVE, orderClassName, directionalClassName)\n\n this._isSliding = false\n\n triggerEvent(EVENT_SLID)\n }\n\n this._queueCallback(completeCallBack, activeElement, this._isAnimated())\n\n if (isCycling) {\n this.cycle()\n }\n }\n\n _isAnimated() {\n return this._element.classList.contains(CLASS_NAME_SLIDE)\n }\n\n _getActive() {\n return SelectorEngine.findOne(SELECTOR_ACTIVE_ITEM, this._element)\n }\n\n _getItems() {\n return SelectorEngine.find(SELECTOR_ITEM, this._element)\n }\n\n _clearInterval() {\n if (this._interval) {\n clearInterval(this._interval)\n this._interval = null\n }\n }\n\n _directionToOrder(direction) {\n if (isRTL()) {\n return direction === DIRECTION_LEFT ? ORDER_PREV : ORDER_NEXT\n }\n\n return direction === DIRECTION_LEFT ? ORDER_NEXT : ORDER_PREV\n }\n\n _orderToDirection(order) {\n if (isRTL()) {\n return order === ORDER_PREV ? DIRECTION_LEFT : DIRECTION_RIGHT\n }\n\n return order === ORDER_PREV ? DIRECTION_RIGHT : DIRECTION_LEFT\n }\n\n // Static\n static jQueryInterface(config) {\n return this.each(function () {\n const data = Carousel.getOrCreateInstance(this, config)\n\n if (typeof config === 'number') {\n data.to(config)\n return\n }\n\n if (typeof config === 'string') {\n if (data[config] === undefined || config.startsWith('_') || config === 'constructor') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config]()\n }\n })\n }\n}\n\n/**\n * Data API implementation\n */\n\nEventHandler.on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_SLIDE, function (event) {\n const target = SelectorEngine.getElementFromSelector(this)\n\n if (!target || !target.classList.contains(CLASS_NAME_CAROUSEL)) {\n return\n }\n\n event.preventDefault()\n\n const carousel = Carousel.getOrCreateInstance(target)\n const slideIndex = this.getAttribute('data-bs-slide-to')\n\n if (slideIndex) {\n carousel.to(slideIndex)\n carousel._maybeEnableCycle()\n return\n }\n\n if (Manipulator.getDataAttribute(this, 'slide') === 'next') {\n carousel.next()\n carousel._maybeEnableCycle()\n return\n }\n\n carousel.prev()\n carousel._maybeEnableCycle()\n})\n\nEventHandler.on(window, EVENT_LOAD_DATA_API, () => {\n const carousels = SelectorEngine.find(SELECTOR_DATA_RIDE)\n\n for (const carousel of carousels) {\n Carousel.getOrCreateInstance(carousel)\n }\n})\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Carousel)\n\nexport default Carousel\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap collapse.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport SelectorEngine from './dom/selector-engine.js'\nimport {\n defineJQueryPlugin,\n getElement,\n reflow\n} from './util/index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'collapse'\nconst DATA_KEY = 'bs.collapse'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst DATA_API_KEY = '.data-api'\n\nconst EVENT_SHOW = `show${EVENT_KEY}`\nconst EVENT_SHOWN = `shown${EVENT_KEY}`\nconst EVENT_HIDE = `hide${EVENT_KEY}`\nconst EVENT_HIDDEN = `hidden${EVENT_KEY}`\nconst EVENT_CLICK_DATA_API = `click${EVENT_KEY}${DATA_API_KEY}`\n\nconst CLASS_NAME_SHOW = 'show'\nconst CLASS_NAME_COLLAPSE = 'collapse'\nconst CLASS_NAME_COLLAPSING = 'collapsing'\nconst CLASS_NAME_COLLAPSED = 'collapsed'\nconst CLASS_NAME_DEEPER_CHILDREN = `:scope .${CLASS_NAME_COLLAPSE} .${CLASS_NAME_COLLAPSE}`\nconst CLASS_NAME_HORIZONTAL = 'collapse-horizontal'\n\nconst WIDTH = 'width'\nconst HEIGHT = 'height'\n\nconst SELECTOR_ACTIVES = '.collapse.show, .collapse.collapsing'\nconst SELECTOR_DATA_TOGGLE = '[data-bs-toggle=\"collapse\"]'\n\nconst Default = {\n parent: null,\n toggle: true\n}\n\nconst DefaultType = {\n parent: '(null|element)',\n toggle: 'boolean'\n}\n\n/**\n * Class definition\n */\n\nclass Collapse extends BaseComponent {\n constructor(element, config) {\n super(element, config)\n\n this._isTransitioning = false\n this._triggerArray = []\n\n const toggleList = SelectorEngine.find(SELECTOR_DATA_TOGGLE)\n\n for (const elem of toggleList) {\n const selector = SelectorEngine.getSelectorFromElement(elem)\n const filterElement = SelectorEngine.find(selector)\n .filter(foundElement => foundElement === this._element)\n\n if (selector !== null && filterElement.length) {\n this._triggerArray.push(elem)\n }\n }\n\n this._initializeChildren()\n\n if (!this._config.parent) {\n this._addAriaAndCollapsedClass(this._triggerArray, this._isShown())\n }\n\n if (this._config.toggle) {\n this.toggle()\n }\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n toggle() {\n if (this._isShown()) {\n this.hide()\n } else {\n this.show()\n }\n }\n\n show() {\n if (this._isTransitioning || this._isShown()) {\n return\n }\n\n let activeChildren = []\n\n // find active children\n if (this._config.parent) {\n activeChildren = this._getFirstLevelChildren(SELECTOR_ACTIVES)\n .filter(element => element !== this._element)\n .map(element => Collapse.getOrCreateInstance(element, { toggle: false }))\n }\n\n if (activeChildren.length && activeChildren[0]._isTransitioning) {\n return\n }\n\n const startEvent = EventHandler.trigger(this._element, EVENT_SHOW)\n if (startEvent.defaultPrevented) {\n return\n }\n\n for (const activeInstance of activeChildren) {\n activeInstance.hide()\n }\n\n const dimension = this._getDimension()\n\n this._element.classList.remove(CLASS_NAME_COLLAPSE)\n this._element.classList.add(CLASS_NAME_COLLAPSING)\n\n this._element.style[dimension] = 0\n\n this._addAriaAndCollapsedClass(this._triggerArray, true)\n this._isTransitioning = true\n\n const complete = () => {\n this._isTransitioning = false\n\n this._element.classList.remove(CLASS_NAME_COLLAPSING)\n this._element.classList.add(CLASS_NAME_COLLAPSE, CLASS_NAME_SHOW)\n\n this._element.style[dimension] = ''\n\n EventHandler.trigger(this._element, EVENT_SHOWN)\n }\n\n const capitalizedDimension = dimension[0].toUpperCase() + dimension.slice(1)\n const scrollSize = `scroll${capitalizedDimension}`\n\n this._queueCallback(complete, this._element, true)\n this._element.style[dimension] = `${this._element[scrollSize]}px`\n }\n\n hide() {\n if (this._isTransitioning || !this._isShown()) {\n return\n }\n\n const startEvent = EventHandler.trigger(this._element, EVENT_HIDE)\n if (startEvent.defaultPrevented) {\n return\n }\n\n const dimension = this._getDimension()\n\n this._element.style[dimension] = `${this._element.getBoundingClientRect()[dimension]}px`\n\n reflow(this._element)\n\n this._element.classList.add(CLASS_NAME_COLLAPSING)\n this._element.classList.remove(CLASS_NAME_COLLAPSE, CLASS_NAME_SHOW)\n\n for (const trigger of this._triggerArray) {\n const element = SelectorEngine.getElementFromSelector(trigger)\n\n if (element && !this._isShown(element)) {\n this._addAriaAndCollapsedClass([trigger], false)\n }\n }\n\n this._isTransitioning = true\n\n const complete = () => {\n this._isTransitioning = false\n this._element.classList.remove(CLASS_NAME_COLLAPSING)\n this._element.classList.add(CLASS_NAME_COLLAPSE)\n EventHandler.trigger(this._element, EVENT_HIDDEN)\n }\n\n this._element.style[dimension] = ''\n\n this._queueCallback(complete, this._element, true)\n }\n\n _isShown(element = this._element) {\n return element.classList.contains(CLASS_NAME_SHOW)\n }\n\n // Private\n _configAfterMerge(config) {\n config.toggle = Boolean(config.toggle) // Coerce string values\n config.parent = getElement(config.parent)\n return config\n }\n\n _getDimension() {\n return this._element.classList.contains(CLASS_NAME_HORIZONTAL) ? WIDTH : HEIGHT\n }\n\n _initializeChildren() {\n if (!this._config.parent) {\n return\n }\n\n const children = this._getFirstLevelChildren(SELECTOR_DATA_TOGGLE)\n\n for (const element of children) {\n const selected = SelectorEngine.getElementFromSelector(element)\n\n if (selected) {\n this._addAriaAndCollapsedClass([element], this._isShown(selected))\n }\n }\n }\n\n _getFirstLevelChildren(selector) {\n const children = SelectorEngine.find(CLASS_NAME_DEEPER_CHILDREN, this._config.parent)\n // remove children if greater depth\n return SelectorEngine.find(selector, this._config.parent).filter(element => !children.includes(element))\n }\n\n _addAriaAndCollapsedClass(triggerArray, isOpen) {\n if (!triggerArray.length) {\n return\n }\n\n for (const element of triggerArray) {\n element.classList.toggle(CLASS_NAME_COLLAPSED, !isOpen)\n element.setAttribute('aria-expanded', isOpen)\n }\n }\n\n // Static\n static jQueryInterface(config) {\n const _config = {}\n if (typeof config === 'string' && /show|hide/.test(config)) {\n _config.toggle = false\n }\n\n return this.each(function () {\n const data = Collapse.getOrCreateInstance(this, _config)\n\n if (typeof config === 'string') {\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config]()\n }\n })\n }\n}\n\n/**\n * Data API implementation\n */\n\nEventHandler.on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) {\n // preventDefault only for elements (which change the URL) not inside the collapsible element\n if (event.target.tagName === 'A' || (event.delegateTarget && event.delegateTarget.tagName === 'A')) {\n event.preventDefault()\n }\n\n for (const element of SelectorEngine.getMultipleElementsFromSelector(this)) {\n Collapse.getOrCreateInstance(element, { toggle: false }).toggle()\n }\n})\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Collapse)\n\nexport default Collapse\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap dropdown.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport * as Popper from '@popperjs/core'\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport Manipulator from './dom/manipulator.js'\nimport SelectorEngine from './dom/selector-engine.js'\nimport {\n defineJQueryPlugin,\n execute,\n getElement,\n getNextActiveElement,\n isDisabled,\n isElement,\n isRTL,\n isVisible,\n noop\n} from './util/index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'dropdown'\nconst DATA_KEY = 'bs.dropdown'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst DATA_API_KEY = '.data-api'\n\nconst ESCAPE_KEY = 'Escape'\nconst TAB_KEY = 'Tab'\nconst ARROW_UP_KEY = 'ArrowUp'\nconst ARROW_DOWN_KEY = 'ArrowDown'\nconst RIGHT_MOUSE_BUTTON = 2 // MouseEvent.button value for the secondary button, usually the right button\n\nconst EVENT_HIDE = `hide${EVENT_KEY}`\nconst EVENT_HIDDEN = `hidden${EVENT_KEY}`\nconst EVENT_SHOW = `show${EVENT_KEY}`\nconst EVENT_SHOWN = `shown${EVENT_KEY}`\nconst EVENT_CLICK_DATA_API = `click${EVENT_KEY}${DATA_API_KEY}`\nconst EVENT_KEYDOWN_DATA_API = `keydown${EVENT_KEY}${DATA_API_KEY}`\nconst EVENT_KEYUP_DATA_API = `keyup${EVENT_KEY}${DATA_API_KEY}`\n\nconst CLASS_NAME_SHOW = 'show'\nconst CLASS_NAME_DROPUP = 'dropup'\nconst CLASS_NAME_DROPEND = 'dropend'\nconst CLASS_NAME_DROPSTART = 'dropstart'\nconst CLASS_NAME_DROPUP_CENTER = 'dropup-center'\nconst CLASS_NAME_DROPDOWN_CENTER = 'dropdown-center'\n\nconst SELECTOR_DATA_TOGGLE = '[data-bs-toggle=\"dropdown\"]:not(.disabled):not(:disabled)'\nconst SELECTOR_DATA_TOGGLE_SHOWN = `${SELECTOR_DATA_TOGGLE}.${CLASS_NAME_SHOW}`\nconst SELECTOR_MENU = '.dropdown-menu'\nconst SELECTOR_NAVBAR = '.navbar'\nconst SELECTOR_NAVBAR_NAV = '.navbar-nav'\nconst SELECTOR_VISIBLE_ITEMS = '.dropdown-menu .dropdown-item:not(.disabled):not(:disabled)'\n\nconst PLACEMENT_TOP = isRTL() ? 'top-end' : 'top-start'\nconst PLACEMENT_TOPEND = isRTL() ? 'top-start' : 'top-end'\nconst PLACEMENT_BOTTOM = isRTL() ? 'bottom-end' : 'bottom-start'\nconst PLACEMENT_BOTTOMEND = isRTL() ? 'bottom-start' : 'bottom-end'\nconst PLACEMENT_RIGHT = isRTL() ? 'left-start' : 'right-start'\nconst PLACEMENT_LEFT = isRTL() ? 'right-start' : 'left-start'\nconst PLACEMENT_TOPCENTER = 'top'\nconst PLACEMENT_BOTTOMCENTER = 'bottom'\n\nconst Default = {\n autoClose: true,\n boundary: 'clippingParents',\n display: 'dynamic',\n offset: [0, 2],\n popperConfig: null,\n reference: 'toggle'\n}\n\nconst DefaultType = {\n autoClose: '(boolean|string)',\n boundary: '(string|element)',\n display: 'string',\n offset: '(array|string|function)',\n popperConfig: '(null|object|function)',\n reference: '(string|element|object)'\n}\n\n/**\n * Class definition\n */\n\nclass Dropdown extends BaseComponent {\n constructor(element, config) {\n super(element, config)\n\n this._popper = null\n this._parent = this._element.parentNode // dropdown wrapper\n // TODO: v6 revert #37011 & change markup https://getbootstrap.com/docs/5.3/forms/input-group/\n this._menu = SelectorEngine.next(this._element, SELECTOR_MENU)[0] ||\n SelectorEngine.prev(this._element, SELECTOR_MENU)[0] ||\n SelectorEngine.findOne(SELECTOR_MENU, this._parent)\n this._inNavbar = this._detectNavbar()\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n toggle() {\n return this._isShown() ? this.hide() : this.show()\n }\n\n show() {\n if (isDisabled(this._element) || this._isShown()) {\n return\n }\n\n const relatedTarget = {\n relatedTarget: this._element\n }\n\n const showEvent = EventHandler.trigger(this._element, EVENT_SHOW, relatedTarget)\n\n if (showEvent.defaultPrevented) {\n return\n }\n\n this._createPopper()\n\n // If this is a touch-enabled device we add extra\n // empty mouseover listeners to the body's immediate children;\n // only needed because of broken event delegation on iOS\n // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html\n if ('ontouchstart' in document.documentElement && !this._parent.closest(SELECTOR_NAVBAR_NAV)) {\n for (const element of [].concat(...document.body.children)) {\n EventHandler.on(element, 'mouseover', noop)\n }\n }\n\n this._element.focus()\n this._element.setAttribute('aria-expanded', true)\n\n this._menu.classList.add(CLASS_NAME_SHOW)\n this._element.classList.add(CLASS_NAME_SHOW)\n EventHandler.trigger(this._element, EVENT_SHOWN, relatedTarget)\n }\n\n hide() {\n if (isDisabled(this._element) || !this._isShown()) {\n return\n }\n\n const relatedTarget = {\n relatedTarget: this._element\n }\n\n this._completeHide(relatedTarget)\n }\n\n dispose() {\n if (this._popper) {\n this._popper.destroy()\n }\n\n super.dispose()\n }\n\n update() {\n this._inNavbar = this._detectNavbar()\n if (this._popper) {\n this._popper.update()\n }\n }\n\n // Private\n _completeHide(relatedTarget) {\n const hideEvent = EventHandler.trigger(this._element, EVENT_HIDE, relatedTarget)\n if (hideEvent.defaultPrevented) {\n return\n }\n\n // If this is a touch-enabled device we remove the extra\n // empty mouseover listeners we added for iOS support\n if ('ontouchstart' in document.documentElement) {\n for (const element of [].concat(...document.body.children)) {\n EventHandler.off(element, 'mouseover', noop)\n }\n }\n\n if (this._popper) {\n this._popper.destroy()\n }\n\n this._menu.classList.remove(CLASS_NAME_SHOW)\n this._element.classList.remove(CLASS_NAME_SHOW)\n this._element.setAttribute('aria-expanded', 'false')\n Manipulator.removeDataAttribute(this._menu, 'popper')\n EventHandler.trigger(this._element, EVENT_HIDDEN, relatedTarget)\n }\n\n _getConfig(config) {\n config = super._getConfig(config)\n\n if (typeof config.reference === 'object' && !isElement(config.reference) &&\n typeof config.reference.getBoundingClientRect !== 'function'\n ) {\n // Popper virtual elements require a getBoundingClientRect method\n throw new TypeError(`${NAME.toUpperCase()}: Option \"reference\" provided type \"object\" without a required \"getBoundingClientRect\" method.`)\n }\n\n return config\n }\n\n _createPopper() {\n if (typeof Popper === 'undefined') {\n throw new TypeError('Bootstrap\\'s dropdowns require Popper (https://popper.js.org)')\n }\n\n let referenceElement = this._element\n\n if (this._config.reference === 'parent') {\n referenceElement = this._parent\n } else if (isElement(this._config.reference)) {\n referenceElement = getElement(this._config.reference)\n } else if (typeof this._config.reference === 'object') {\n referenceElement = this._config.reference\n }\n\n const popperConfig = this._getPopperConfig()\n this._popper = Popper.createPopper(referenceElement, this._menu, popperConfig)\n }\n\n _isShown() {\n return this._menu.classList.contains(CLASS_NAME_SHOW)\n }\n\n _getPlacement() {\n const parentDropdown = this._parent\n\n if (parentDropdown.classList.contains(CLASS_NAME_DROPEND)) {\n return PLACEMENT_RIGHT\n }\n\n if (parentDropdown.classList.contains(CLASS_NAME_DROPSTART)) {\n return PLACEMENT_LEFT\n }\n\n if (parentDropdown.classList.contains(CLASS_NAME_DROPUP_CENTER)) {\n return PLACEMENT_TOPCENTER\n }\n\n if (parentDropdown.classList.contains(CLASS_NAME_DROPDOWN_CENTER)) {\n return PLACEMENT_BOTTOMCENTER\n }\n\n // We need to trim the value because custom properties can also include spaces\n const isEnd = getComputedStyle(this._menu).getPropertyValue('--bs-position').trim() === 'end'\n\n if (parentDropdown.classList.contains(CLASS_NAME_DROPUP)) {\n return isEnd ? PLACEMENT_TOPEND : PLACEMENT_TOP\n }\n\n return isEnd ? PLACEMENT_BOTTOMEND : PLACEMENT_BOTTOM\n }\n\n _detectNavbar() {\n return this._element.closest(SELECTOR_NAVBAR) !== null\n }\n\n _getOffset() {\n const { offset } = this._config\n\n if (typeof offset === 'string') {\n return offset.split(',').map(value => Number.parseInt(value, 10))\n }\n\n if (typeof offset === 'function') {\n return popperData => offset(popperData, this._element)\n }\n\n return offset\n }\n\n _getPopperConfig() {\n const defaultBsPopperConfig = {\n placement: this._getPlacement(),\n modifiers: [{\n name: 'preventOverflow',\n options: {\n boundary: this._config.boundary\n }\n },\n {\n name: 'offset',\n options: {\n offset: this._getOffset()\n }\n }]\n }\n\n // Disable Popper if we have a static display or Dropdown is in Navbar\n if (this._inNavbar || this._config.display === 'static') {\n Manipulator.setDataAttribute(this._menu, 'popper', 'static') // TODO: v6 remove\n defaultBsPopperConfig.modifiers = [{\n name: 'applyStyles',\n enabled: false\n }]\n }\n\n return {\n ...defaultBsPopperConfig,\n ...execute(this._config.popperConfig, [defaultBsPopperConfig])\n }\n }\n\n _selectMenuItem({ key, target }) {\n const items = SelectorEngine.find(SELECTOR_VISIBLE_ITEMS, this._menu).filter(element => isVisible(element))\n\n if (!items.length) {\n return\n }\n\n // if target isn't included in items (e.g. when expanding the dropdown)\n // allow cycling to get the last item in case key equals ARROW_UP_KEY\n getNextActiveElement(items, target, key === ARROW_DOWN_KEY, !items.includes(target)).focus()\n }\n\n // Static\n static jQueryInterface(config) {\n return this.each(function () {\n const data = Dropdown.getOrCreateInstance(this, config)\n\n if (typeof config !== 'string') {\n return\n }\n\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config]()\n })\n }\n\n static clearMenus(event) {\n if (event.button === RIGHT_MOUSE_BUTTON || (event.type === 'keyup' && event.key !== TAB_KEY)) {\n return\n }\n\n const openToggles = SelectorEngine.find(SELECTOR_DATA_TOGGLE_SHOWN)\n\n for (const toggle of openToggles) {\n const context = Dropdown.getInstance(toggle)\n if (!context || context._config.autoClose === false) {\n continue\n }\n\n const composedPath = event.composedPath()\n const isMenuTarget = composedPath.includes(context._menu)\n if (\n composedPath.includes(context._element) ||\n (context._config.autoClose === 'inside' && !isMenuTarget) ||\n (context._config.autoClose === 'outside' && isMenuTarget)\n ) {\n continue\n }\n\n // Tab navigation through the dropdown menu or events from contained inputs shouldn't close the menu\n if (context._menu.contains(event.target) && ((event.type === 'keyup' && event.key === TAB_KEY) || /input|select|option|textarea|form/i.test(event.target.tagName))) {\n continue\n }\n\n const relatedTarget = { relatedTarget: context._element }\n\n if (event.type === 'click') {\n relatedTarget.clickEvent = event\n }\n\n context._completeHide(relatedTarget)\n }\n }\n\n static dataApiKeydownHandler(event) {\n // If not an UP | DOWN | ESCAPE key => not a dropdown command\n // If input/textarea && if key is other than ESCAPE => not a dropdown command\n\n const isInput = /input|textarea/i.test(event.target.tagName)\n const isEscapeEvent = event.key === ESCAPE_KEY\n const isUpOrDownEvent = [ARROW_UP_KEY, ARROW_DOWN_KEY].includes(event.key)\n\n if (!isUpOrDownEvent && !isEscapeEvent) {\n return\n }\n\n if (isInput && !isEscapeEvent) {\n return\n }\n\n event.preventDefault()\n\n // TODO: v6 revert #37011 & change markup https://getbootstrap.com/docs/5.3/forms/input-group/\n const getToggleButton = this.matches(SELECTOR_DATA_TOGGLE) ?\n this :\n (SelectorEngine.prev(this, SELECTOR_DATA_TOGGLE)[0] ||\n SelectorEngine.next(this, SELECTOR_DATA_TOGGLE)[0] ||\n SelectorEngine.findOne(SELECTOR_DATA_TOGGLE, event.delegateTarget.parentNode))\n\n const instance = Dropdown.getOrCreateInstance(getToggleButton)\n\n if (isUpOrDownEvent) {\n event.stopPropagation()\n instance.show()\n instance._selectMenuItem(event)\n return\n }\n\n if (instance._isShown()) { // else is escape and we check if it is shown\n event.stopPropagation()\n instance.hide()\n getToggleButton.focus()\n }\n }\n}\n\n/**\n * Data API implementation\n */\n\nEventHandler.on(document, EVENT_KEYDOWN_DATA_API, SELECTOR_DATA_TOGGLE, Dropdown.dataApiKeydownHandler)\nEventHandler.on(document, EVENT_KEYDOWN_DATA_API, SELECTOR_MENU, Dropdown.dataApiKeydownHandler)\nEventHandler.on(document, EVENT_CLICK_DATA_API, Dropdown.clearMenus)\nEventHandler.on(document, EVENT_KEYUP_DATA_API, Dropdown.clearMenus)\nEventHandler.on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) {\n event.preventDefault()\n Dropdown.getOrCreateInstance(this).toggle()\n})\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Dropdown)\n\nexport default Dropdown\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/backdrop.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport EventHandler from '../dom/event-handler.js'\nimport Config from './config.js'\nimport { execute, executeAfterTransition, getElement, reflow } from './index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'backdrop'\nconst CLASS_NAME_FADE = 'fade'\nconst CLASS_NAME_SHOW = 'show'\nconst EVENT_MOUSEDOWN = `mousedown.bs.${NAME}`\n\nconst Default = {\n className: 'modal-backdrop',\n clickCallback: null,\n isAnimated: false,\n isVisible: true, // if false, we use the backdrop helper without adding any element to the dom\n rootElement: 'body' // give the choice to place backdrop under different elements\n}\n\nconst DefaultType = {\n className: 'string',\n clickCallback: '(function|null)',\n isAnimated: 'boolean',\n isVisible: 'boolean',\n rootElement: '(element|string)'\n}\n\n/**\n * Class definition\n */\n\nclass Backdrop extends Config {\n constructor(config) {\n super()\n this._config = this._getConfig(config)\n this._isAppended = false\n this._element = null\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n show(callback) {\n if (!this._config.isVisible) {\n execute(callback)\n return\n }\n\n this._append()\n\n const element = this._getElement()\n if (this._config.isAnimated) {\n reflow(element)\n }\n\n element.classList.add(CLASS_NAME_SHOW)\n\n this._emulateAnimation(() => {\n execute(callback)\n })\n }\n\n hide(callback) {\n if (!this._config.isVisible) {\n execute(callback)\n return\n }\n\n this._getElement().classList.remove(CLASS_NAME_SHOW)\n\n this._emulateAnimation(() => {\n this.dispose()\n execute(callback)\n })\n }\n\n dispose() {\n if (!this._isAppended) {\n return\n }\n\n EventHandler.off(this._element, EVENT_MOUSEDOWN)\n\n this._element.remove()\n this._isAppended = false\n }\n\n // Private\n _getElement() {\n if (!this._element) {\n const backdrop = document.createElement('div')\n backdrop.className = this._config.className\n if (this._config.isAnimated) {\n backdrop.classList.add(CLASS_NAME_FADE)\n }\n\n this._element = backdrop\n }\n\n return this._element\n }\n\n _configAfterMerge(config) {\n // use getElement() with the default \"body\" to get a fresh Element on each instantiation\n config.rootElement = getElement(config.rootElement)\n return config\n }\n\n _append() {\n if (this._isAppended) {\n return\n }\n\n const element = this._getElement()\n this._config.rootElement.append(element)\n\n EventHandler.on(element, EVENT_MOUSEDOWN, () => {\n execute(this._config.clickCallback)\n })\n\n this._isAppended = true\n }\n\n _emulateAnimation(callback) {\n executeAfterTransition(callback, this._getElement(), this._config.isAnimated)\n }\n}\n\nexport default Backdrop\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/focustrap.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport EventHandler from '../dom/event-handler.js'\nimport SelectorEngine from '../dom/selector-engine.js'\nimport Config from './config.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'focustrap'\nconst DATA_KEY = 'bs.focustrap'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst EVENT_FOCUSIN = `focusin${EVENT_KEY}`\nconst EVENT_KEYDOWN_TAB = `keydown.tab${EVENT_KEY}`\n\nconst TAB_KEY = 'Tab'\nconst TAB_NAV_FORWARD = 'forward'\nconst TAB_NAV_BACKWARD = 'backward'\n\nconst Default = {\n autofocus: true,\n trapElement: null // The element to trap focus inside of\n}\n\nconst DefaultType = {\n autofocus: 'boolean',\n trapElement: 'element'\n}\n\n/**\n * Class definition\n */\n\nclass FocusTrap extends Config {\n constructor(config) {\n super()\n this._config = this._getConfig(config)\n this._isActive = false\n this._lastTabNavDirection = null\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n activate() {\n if (this._isActive) {\n return\n }\n\n if (this._config.autofocus) {\n this._config.trapElement.focus()\n }\n\n EventHandler.off(document, EVENT_KEY) // guard against infinite focus loop\n EventHandler.on(document, EVENT_FOCUSIN, event => this._handleFocusin(event))\n EventHandler.on(document, EVENT_KEYDOWN_TAB, event => this._handleKeydown(event))\n\n this._isActive = true\n }\n\n deactivate() {\n if (!this._isActive) {\n return\n }\n\n this._isActive = false\n EventHandler.off(document, EVENT_KEY)\n }\n\n // Private\n _handleFocusin(event) {\n const { trapElement } = this._config\n\n if (event.target === document || event.target === trapElement || trapElement.contains(event.target)) {\n return\n }\n\n const elements = SelectorEngine.focusableChildren(trapElement)\n\n if (elements.length === 0) {\n trapElement.focus()\n } else if (this._lastTabNavDirection === TAB_NAV_BACKWARD) {\n elements[elements.length - 1].focus()\n } else {\n elements[0].focus()\n }\n }\n\n _handleKeydown(event) {\n if (event.key !== TAB_KEY) {\n return\n }\n\n this._lastTabNavDirection = event.shiftKey ? TAB_NAV_BACKWARD : TAB_NAV_FORWARD\n }\n}\n\nexport default FocusTrap\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/scrollBar.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport Manipulator from '../dom/manipulator.js'\nimport SelectorEngine from '../dom/selector-engine.js'\nimport { isElement } from './index.js'\n\n/**\n * Constants\n */\n\nconst SELECTOR_FIXED_CONTENT = '.fixed-top, .fixed-bottom, .is-fixed, .sticky-top'\nconst SELECTOR_STICKY_CONTENT = '.sticky-top'\nconst PROPERTY_PADDING = 'padding-right'\nconst PROPERTY_MARGIN = 'margin-right'\n\n/**\n * Class definition\n */\n\nclass ScrollBarHelper {\n constructor() {\n this._element = document.body\n }\n\n // Public\n getWidth() {\n // https://developer.mozilla.org/en-US/docs/Web/API/Window/innerWidth#usage_notes\n const documentWidth = document.documentElement.clientWidth\n return Math.abs(window.innerWidth - documentWidth)\n }\n\n hide() {\n const width = this.getWidth()\n this._disableOverFlow()\n // give padding to element to balance the hidden scrollbar width\n this._setElementAttributes(this._element, PROPERTY_PADDING, calculatedValue => calculatedValue + width)\n // trick: We adjust positive paddingRight and negative marginRight to sticky-top elements to keep showing fullwidth\n this._setElementAttributes(SELECTOR_FIXED_CONTENT, PROPERTY_PADDING, calculatedValue => calculatedValue + width)\n this._setElementAttributes(SELECTOR_STICKY_CONTENT, PROPERTY_MARGIN, calculatedValue => calculatedValue - width)\n }\n\n reset() {\n this._resetElementAttributes(this._element, 'overflow')\n this._resetElementAttributes(this._element, PROPERTY_PADDING)\n this._resetElementAttributes(SELECTOR_FIXED_CONTENT, PROPERTY_PADDING)\n this._resetElementAttributes(SELECTOR_STICKY_CONTENT, PROPERTY_MARGIN)\n }\n\n isOverflowing() {\n return this.getWidth() > 0\n }\n\n // Private\n _disableOverFlow() {\n this._saveInitialAttribute(this._element, 'overflow')\n this._element.style.overflow = 'hidden'\n }\n\n _setElementAttributes(selector, styleProperty, callback) {\n const scrollbarWidth = this.getWidth()\n const manipulationCallBack = element => {\n if (element !== this._element && window.innerWidth > element.clientWidth + scrollbarWidth) {\n return\n }\n\n this._saveInitialAttribute(element, styleProperty)\n const calculatedValue = window.getComputedStyle(element).getPropertyValue(styleProperty)\n element.style.setProperty(styleProperty, `${callback(Number.parseFloat(calculatedValue))}px`)\n }\n\n this._applyManipulationCallback(selector, manipulationCallBack)\n }\n\n _saveInitialAttribute(element, styleProperty) {\n const actualValue = element.style.getPropertyValue(styleProperty)\n if (actualValue) {\n Manipulator.setDataAttribute(element, styleProperty, actualValue)\n }\n }\n\n _resetElementAttributes(selector, styleProperty) {\n const manipulationCallBack = element => {\n const value = Manipulator.getDataAttribute(element, styleProperty)\n // We only want to remove the property if the value is `null`; the value can also be zero\n if (value === null) {\n element.style.removeProperty(styleProperty)\n return\n }\n\n Manipulator.removeDataAttribute(element, styleProperty)\n element.style.setProperty(styleProperty, value)\n }\n\n this._applyManipulationCallback(selector, manipulationCallBack)\n }\n\n _applyManipulationCallback(selector, callBack) {\n if (isElement(selector)) {\n callBack(selector)\n return\n }\n\n for (const sel of SelectorEngine.find(selector, this._element)) {\n callBack(sel)\n }\n }\n}\n\nexport default ScrollBarHelper\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap modal.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport SelectorEngine from './dom/selector-engine.js'\nimport Backdrop from './util/backdrop.js'\nimport { enableDismissTrigger } from './util/component-functions.js'\nimport FocusTrap from './util/focustrap.js'\nimport { defineJQueryPlugin, isRTL, isVisible, reflow } from './util/index.js'\nimport ScrollBarHelper from './util/scrollbar.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'modal'\nconst DATA_KEY = 'bs.modal'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst DATA_API_KEY = '.data-api'\nconst ESCAPE_KEY = 'Escape'\n\nconst EVENT_HIDE = `hide${EVENT_KEY}`\nconst EVENT_HIDE_PREVENTED = `hidePrevented${EVENT_KEY}`\nconst EVENT_HIDDEN = `hidden${EVENT_KEY}`\nconst EVENT_SHOW = `show${EVENT_KEY}`\nconst EVENT_SHOWN = `shown${EVENT_KEY}`\nconst EVENT_RESIZE = `resize${EVENT_KEY}`\nconst EVENT_CLICK_DISMISS = `click.dismiss${EVENT_KEY}`\nconst EVENT_MOUSEDOWN_DISMISS = `mousedown.dismiss${EVENT_KEY}`\nconst EVENT_KEYDOWN_DISMISS = `keydown.dismiss${EVENT_KEY}`\nconst EVENT_CLICK_DATA_API = `click${EVENT_KEY}${DATA_API_KEY}`\n\nconst CLASS_NAME_OPEN = 'modal-open'\nconst CLASS_NAME_FADE = 'fade'\nconst CLASS_NAME_SHOW = 'show'\nconst CLASS_NAME_STATIC = 'modal-static'\n\nconst OPEN_SELECTOR = '.modal.show'\nconst SELECTOR_DIALOG = '.modal-dialog'\nconst SELECTOR_MODAL_BODY = '.modal-body'\nconst SELECTOR_DATA_TOGGLE = '[data-bs-toggle=\"modal\"]'\n\nconst Default = {\n backdrop: true,\n focus: true,\n keyboard: true\n}\n\nconst DefaultType = {\n backdrop: '(boolean|string)',\n focus: 'boolean',\n keyboard: 'boolean'\n}\n\n/**\n * Class definition\n */\n\nclass Modal extends BaseComponent {\n constructor(element, config) {\n super(element, config)\n\n this._dialog = SelectorEngine.findOne(SELECTOR_DIALOG, this._element)\n this._backdrop = this._initializeBackDrop()\n this._focustrap = this._initializeFocusTrap()\n this._isShown = false\n this._isTransitioning = false\n this._scrollBar = new ScrollBarHelper()\n\n this._addEventListeners()\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n toggle(relatedTarget) {\n return this._isShown ? this.hide() : this.show(relatedTarget)\n }\n\n show(relatedTarget) {\n if (this._isShown || this._isTransitioning) {\n return\n }\n\n const showEvent = EventHandler.trigger(this._element, EVENT_SHOW, {\n relatedTarget\n })\n\n if (showEvent.defaultPrevented) {\n return\n }\n\n this._isShown = true\n this._isTransitioning = true\n\n this._scrollBar.hide()\n\n document.body.classList.add(CLASS_NAME_OPEN)\n\n this._adjustDialog()\n\n this._backdrop.show(() => this._showElement(relatedTarget))\n }\n\n hide() {\n if (!this._isShown || this._isTransitioning) {\n return\n }\n\n const hideEvent = EventHandler.trigger(this._element, EVENT_HIDE)\n\n if (hideEvent.defaultPrevented) {\n return\n }\n\n this._isShown = false\n this._isTransitioning = true\n this._focustrap.deactivate()\n\n this._element.classList.remove(CLASS_NAME_SHOW)\n\n this._queueCallback(() => this._hideModal(), this._element, this._isAnimated())\n }\n\n dispose() {\n EventHandler.off(window, EVENT_KEY)\n EventHandler.off(this._dialog, EVENT_KEY)\n\n this._backdrop.dispose()\n this._focustrap.deactivate()\n\n super.dispose()\n }\n\n handleUpdate() {\n this._adjustDialog()\n }\n\n // Private\n _initializeBackDrop() {\n return new Backdrop({\n isVisible: Boolean(this._config.backdrop), // 'static' option will be translated to true, and booleans will keep their value,\n isAnimated: this._isAnimated()\n })\n }\n\n _initializeFocusTrap() {\n return new FocusTrap({\n trapElement: this._element\n })\n }\n\n _showElement(relatedTarget) {\n // try to append dynamic modal\n if (!document.body.contains(this._element)) {\n document.body.append(this._element)\n }\n\n this._element.style.display = 'block'\n this._element.removeAttribute('aria-hidden')\n this._element.setAttribute('aria-modal', true)\n this._element.setAttribute('role', 'dialog')\n this._element.scrollTop = 0\n\n const modalBody = SelectorEngine.findOne(SELECTOR_MODAL_BODY, this._dialog)\n if (modalBody) {\n modalBody.scrollTop = 0\n }\n\n reflow(this._element)\n\n this._element.classList.add(CLASS_NAME_SHOW)\n\n const transitionComplete = () => {\n if (this._config.focus) {\n this._focustrap.activate()\n }\n\n this._isTransitioning = false\n EventHandler.trigger(this._element, EVENT_SHOWN, {\n relatedTarget\n })\n }\n\n this._queueCallback(transitionComplete, this._dialog, this._isAnimated())\n }\n\n _addEventListeners() {\n EventHandler.on(this._element, EVENT_KEYDOWN_DISMISS, event => {\n if (event.key !== ESCAPE_KEY) {\n return\n }\n\n if (this._config.keyboard) {\n this.hide()\n return\n }\n\n this._triggerBackdropTransition()\n })\n\n EventHandler.on(window, EVENT_RESIZE, () => {\n if (this._isShown && !this._isTransitioning) {\n this._adjustDialog()\n }\n })\n\n EventHandler.on(this._element, EVENT_MOUSEDOWN_DISMISS, event => {\n // a bad trick to segregate clicks that may start inside dialog but end outside, and avoid listen to scrollbar clicks\n EventHandler.one(this._element, EVENT_CLICK_DISMISS, event2 => {\n if (this._element !== event.target || this._element !== event2.target) {\n return\n }\n\n if (this._config.backdrop === 'static') {\n this._triggerBackdropTransition()\n return\n }\n\n if (this._config.backdrop) {\n this.hide()\n }\n })\n })\n }\n\n _hideModal() {\n this._element.style.display = 'none'\n this._element.setAttribute('aria-hidden', true)\n this._element.removeAttribute('aria-modal')\n this._element.removeAttribute('role')\n this._isTransitioning = false\n\n this._backdrop.hide(() => {\n document.body.classList.remove(CLASS_NAME_OPEN)\n this._resetAdjustments()\n this._scrollBar.reset()\n EventHandler.trigger(this._element, EVENT_HIDDEN)\n })\n }\n\n _isAnimated() {\n return this._element.classList.contains(CLASS_NAME_FADE)\n }\n\n _triggerBackdropTransition() {\n const hideEvent = EventHandler.trigger(this._element, EVENT_HIDE_PREVENTED)\n if (hideEvent.defaultPrevented) {\n return\n }\n\n const isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight\n const initialOverflowY = this._element.style.overflowY\n // return if the following background transition hasn't yet completed\n if (initialOverflowY === 'hidden' || this._element.classList.contains(CLASS_NAME_STATIC)) {\n return\n }\n\n if (!isModalOverflowing) {\n this._element.style.overflowY = 'hidden'\n }\n\n this._element.classList.add(CLASS_NAME_STATIC)\n this._queueCallback(() => {\n this._element.classList.remove(CLASS_NAME_STATIC)\n this._queueCallback(() => {\n this._element.style.overflowY = initialOverflowY\n }, this._dialog)\n }, this._dialog)\n\n this._element.focus()\n }\n\n /**\n * The following methods are used to handle overflowing modals\n */\n\n _adjustDialog() {\n const isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight\n const scrollbarWidth = this._scrollBar.getWidth()\n const isBodyOverflowing = scrollbarWidth > 0\n\n if (isBodyOverflowing && !isModalOverflowing) {\n const property = isRTL() ? 'paddingLeft' : 'paddingRight'\n this._element.style[property] = `${scrollbarWidth}px`\n }\n\n if (!isBodyOverflowing && isModalOverflowing) {\n const property = isRTL() ? 'paddingRight' : 'paddingLeft'\n this._element.style[property] = `${scrollbarWidth}px`\n }\n }\n\n _resetAdjustments() {\n this._element.style.paddingLeft = ''\n this._element.style.paddingRight = ''\n }\n\n // Static\n static jQueryInterface(config, relatedTarget) {\n return this.each(function () {\n const data = Modal.getOrCreateInstance(this, config)\n\n if (typeof config !== 'string') {\n return\n }\n\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config](relatedTarget)\n })\n }\n}\n\n/**\n * Data API implementation\n */\n\nEventHandler.on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) {\n const target = SelectorEngine.getElementFromSelector(this)\n\n if (['A', 'AREA'].includes(this.tagName)) {\n event.preventDefault()\n }\n\n EventHandler.one(target, EVENT_SHOW, showEvent => {\n if (showEvent.defaultPrevented) {\n // only register focus restorer if modal will actually get shown\n return\n }\n\n EventHandler.one(target, EVENT_HIDDEN, () => {\n if (isVisible(this)) {\n this.focus()\n }\n })\n })\n\n // avoid conflict when clicking modal toggler while another one is open\n const alreadyOpen = SelectorEngine.findOne(OPEN_SELECTOR)\n if (alreadyOpen) {\n Modal.getInstance(alreadyOpen).hide()\n }\n\n const data = Modal.getOrCreateInstance(target)\n\n data.toggle(this)\n})\n\nenableDismissTrigger(Modal)\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Modal)\n\nexport default Modal\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap offcanvas.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport SelectorEngine from './dom/selector-engine.js'\nimport Backdrop from './util/backdrop.js'\nimport { enableDismissTrigger } from './util/component-functions.js'\nimport FocusTrap from './util/focustrap.js'\nimport {\n defineJQueryPlugin,\n isDisabled,\n isVisible\n} from './util/index.js'\nimport ScrollBarHelper from './util/scrollbar.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'offcanvas'\nconst DATA_KEY = 'bs.offcanvas'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst DATA_API_KEY = '.data-api'\nconst EVENT_LOAD_DATA_API = `load${EVENT_KEY}${DATA_API_KEY}`\nconst ESCAPE_KEY = 'Escape'\n\nconst CLASS_NAME_SHOW = 'show'\nconst CLASS_NAME_SHOWING = 'showing'\nconst CLASS_NAME_HIDING = 'hiding'\nconst CLASS_NAME_BACKDROP = 'offcanvas-backdrop'\nconst OPEN_SELECTOR = '.offcanvas.show'\n\nconst EVENT_SHOW = `show${EVENT_KEY}`\nconst EVENT_SHOWN = `shown${EVENT_KEY}`\nconst EVENT_HIDE = `hide${EVENT_KEY}`\nconst EVENT_HIDE_PREVENTED = `hidePrevented${EVENT_KEY}`\nconst EVENT_HIDDEN = `hidden${EVENT_KEY}`\nconst EVENT_RESIZE = `resize${EVENT_KEY}`\nconst EVENT_CLICK_DATA_API = `click${EVENT_KEY}${DATA_API_KEY}`\nconst EVENT_KEYDOWN_DISMISS = `keydown.dismiss${EVENT_KEY}`\n\nconst SELECTOR_DATA_TOGGLE = '[data-bs-toggle=\"offcanvas\"]'\n\nconst Default = {\n backdrop: true,\n keyboard: true,\n scroll: false\n}\n\nconst DefaultType = {\n backdrop: '(boolean|string)',\n keyboard: 'boolean',\n scroll: 'boolean'\n}\n\n/**\n * Class definition\n */\n\nclass Offcanvas extends BaseComponent {\n constructor(element, config) {\n super(element, config)\n\n this._isShown = false\n this._backdrop = this._initializeBackDrop()\n this._focustrap = this._initializeFocusTrap()\n this._addEventListeners()\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n toggle(relatedTarget) {\n return this._isShown ? this.hide() : this.show(relatedTarget)\n }\n\n show(relatedTarget) {\n if (this._isShown) {\n return\n }\n\n const showEvent = EventHandler.trigger(this._element, EVENT_SHOW, { relatedTarget })\n\n if (showEvent.defaultPrevented) {\n return\n }\n\n this._isShown = true\n this._backdrop.show()\n\n if (!this._config.scroll) {\n new ScrollBarHelper().hide()\n }\n\n this._element.setAttribute('aria-modal', true)\n this._element.setAttribute('role', 'dialog')\n this._element.classList.add(CLASS_NAME_SHOWING)\n\n const completeCallBack = () => {\n if (!this._config.scroll || this._config.backdrop) {\n this._focustrap.activate()\n }\n\n this._element.classList.add(CLASS_NAME_SHOW)\n this._element.classList.remove(CLASS_NAME_SHOWING)\n EventHandler.trigger(this._element, EVENT_SHOWN, { relatedTarget })\n }\n\n this._queueCallback(completeCallBack, this._element, true)\n }\n\n hide() {\n if (!this._isShown) {\n return\n }\n\n const hideEvent = EventHandler.trigger(this._element, EVENT_HIDE)\n\n if (hideEvent.defaultPrevented) {\n return\n }\n\n this._focustrap.deactivate()\n this._element.blur()\n this._isShown = false\n this._element.classList.add(CLASS_NAME_HIDING)\n this._backdrop.hide()\n\n const completeCallback = () => {\n this._element.classList.remove(CLASS_NAME_SHOW, CLASS_NAME_HIDING)\n this._element.removeAttribute('aria-modal')\n this._element.removeAttribute('role')\n\n if (!this._config.scroll) {\n new ScrollBarHelper().reset()\n }\n\n EventHandler.trigger(this._element, EVENT_HIDDEN)\n }\n\n this._queueCallback(completeCallback, this._element, true)\n }\n\n dispose() {\n this._backdrop.dispose()\n this._focustrap.deactivate()\n super.dispose()\n }\n\n // Private\n _initializeBackDrop() {\n const clickCallback = () => {\n if (this._config.backdrop === 'static') {\n EventHandler.trigger(this._element, EVENT_HIDE_PREVENTED)\n return\n }\n\n this.hide()\n }\n\n // 'static' option will be translated to true, and booleans will keep their value\n const isVisible = Boolean(this._config.backdrop)\n\n return new Backdrop({\n className: CLASS_NAME_BACKDROP,\n isVisible,\n isAnimated: true,\n rootElement: this._element.parentNode,\n clickCallback: isVisible ? clickCallback : null\n })\n }\n\n _initializeFocusTrap() {\n return new FocusTrap({\n trapElement: this._element\n })\n }\n\n _addEventListeners() {\n EventHandler.on(this._element, EVENT_KEYDOWN_DISMISS, event => {\n if (event.key !== ESCAPE_KEY) {\n return\n }\n\n if (this._config.keyboard) {\n this.hide()\n return\n }\n\n EventHandler.trigger(this._element, EVENT_HIDE_PREVENTED)\n })\n }\n\n // Static\n static jQueryInterface(config) {\n return this.each(function () {\n const data = Offcanvas.getOrCreateInstance(this, config)\n\n if (typeof config !== 'string') {\n return\n }\n\n if (data[config] === undefined || config.startsWith('_') || config === 'constructor') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config](this)\n })\n }\n}\n\n/**\n * Data API implementation\n */\n\nEventHandler.on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) {\n const target = SelectorEngine.getElementFromSelector(this)\n\n if (['A', 'AREA'].includes(this.tagName)) {\n event.preventDefault()\n }\n\n if (isDisabled(this)) {\n return\n }\n\n EventHandler.one(target, EVENT_HIDDEN, () => {\n // focus on trigger when it is closed\n if (isVisible(this)) {\n this.focus()\n }\n })\n\n // avoid conflict when clicking a toggler of an offcanvas, while another is open\n const alreadyOpen = SelectorEngine.findOne(OPEN_SELECTOR)\n if (alreadyOpen && alreadyOpen !== target) {\n Offcanvas.getInstance(alreadyOpen).hide()\n }\n\n const data = Offcanvas.getOrCreateInstance(target)\n data.toggle(this)\n})\n\nEventHandler.on(window, EVENT_LOAD_DATA_API, () => {\n for (const selector of SelectorEngine.find(OPEN_SELECTOR)) {\n Offcanvas.getOrCreateInstance(selector).show()\n }\n})\n\nEventHandler.on(window, EVENT_RESIZE, () => {\n for (const element of SelectorEngine.find('[aria-modal][class*=show][class*=offcanvas-]')) {\n if (getComputedStyle(element).position !== 'fixed') {\n Offcanvas.getOrCreateInstance(element).hide()\n }\n }\n})\n\nenableDismissTrigger(Offcanvas)\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Offcanvas)\n\nexport default Offcanvas\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/sanitizer.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\n// js-docs-start allow-list\nconst ARIA_ATTRIBUTE_PATTERN = /^aria-[\\w-]*$/i\n\nexport const DefaultAllowlist = {\n // Global attributes allowed on any supplied element below.\n '*': ['class', 'dir', 'id', 'lang', 'role', ARIA_ATTRIBUTE_PATTERN],\n a: ['target', 'href', 'title', 'rel'],\n area: [],\n b: [],\n br: [],\n col: [],\n code: [],\n div: [],\n em: [],\n hr: [],\n h1: [],\n h2: [],\n h3: [],\n h4: [],\n h5: [],\n h6: [],\n i: [],\n img: ['src', 'srcset', 'alt', 'title', 'width', 'height'],\n li: [],\n ol: [],\n p: [],\n pre: [],\n s: [],\n small: [],\n span: [],\n sub: [],\n sup: [],\n strong: [],\n u: [],\n ul: []\n}\n// js-docs-end allow-list\n\nconst uriAttributes = new Set([\n 'background',\n 'cite',\n 'href',\n 'itemtype',\n 'longdesc',\n 'poster',\n 'src',\n 'xlink:href'\n])\n\n/**\n * A pattern that recognizes URLs that are safe wrt. XSS in URL navigation\n * contexts.\n *\n * Shout-out to Angular https://github.com/angular/angular/blob/15.2.8/packages/core/src/sanitization/url_sanitizer.ts#L38\n */\n// eslint-disable-next-line unicorn/better-regex\nconst SAFE_URL_PATTERN = /^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i\n\nconst allowedAttribute = (attribute, allowedAttributeList) => {\n const attributeName = attribute.nodeName.toLowerCase()\n\n if (allowedAttributeList.includes(attributeName)) {\n if (uriAttributes.has(attributeName)) {\n return Boolean(SAFE_URL_PATTERN.test(attribute.nodeValue))\n }\n\n return true\n }\n\n // Check if a regular expression validates the attribute.\n return allowedAttributeList.filter(attributeRegex => attributeRegex instanceof RegExp)\n .some(regex => regex.test(attributeName))\n}\n\nexport function sanitizeHtml(unsafeHtml, allowList, sanitizeFunction) {\n if (!unsafeHtml.length) {\n return unsafeHtml\n }\n\n if (sanitizeFunction && typeof sanitizeFunction === 'function') {\n return sanitizeFunction(unsafeHtml)\n }\n\n const domParser = new window.DOMParser()\n const createdDocument = domParser.parseFromString(unsafeHtml, 'text/html')\n const elements = [].concat(...createdDocument.body.querySelectorAll('*'))\n\n for (const element of elements) {\n const elementName = element.nodeName.toLowerCase()\n\n if (!Object.keys(allowList).includes(elementName)) {\n element.remove()\n continue\n }\n\n const attributeList = [].concat(...element.attributes)\n const allowedAttributes = [].concat(allowList['*'] || [], allowList[elementName] || [])\n\n for (const attribute of attributeList) {\n if (!allowedAttribute(attribute, allowedAttributes)) {\n element.removeAttribute(attribute.nodeName)\n }\n }\n }\n\n return createdDocument.body.innerHTML\n}\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap util/template-factory.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport SelectorEngine from '../dom/selector-engine.js'\nimport Config from './config.js'\nimport { DefaultAllowlist, sanitizeHtml } from './sanitizer.js'\nimport { execute, getElement, isElement } from './index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'TemplateFactory'\n\nconst Default = {\n allowList: DefaultAllowlist,\n content: {}, // { selector : text , selector2 : text2 , }\n extraClass: '',\n html: false,\n sanitize: true,\n sanitizeFn: null,\n template: '
    '\n}\n\nconst DefaultType = {\n allowList: 'object',\n content: 'object',\n extraClass: '(string|function)',\n html: 'boolean',\n sanitize: 'boolean',\n sanitizeFn: '(null|function)',\n template: 'string'\n}\n\nconst DefaultContentType = {\n entry: '(string|element|function|null)',\n selector: '(string|element)'\n}\n\n/**\n * Class definition\n */\n\nclass TemplateFactory extends Config {\n constructor(config) {\n super()\n this._config = this._getConfig(config)\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n getContent() {\n return Object.values(this._config.content)\n .map(config => this._resolvePossibleFunction(config))\n .filter(Boolean)\n }\n\n hasContent() {\n return this.getContent().length > 0\n }\n\n changeContent(content) {\n this._checkContent(content)\n this._config.content = { ...this._config.content, ...content }\n return this\n }\n\n toHtml() {\n const templateWrapper = document.createElement('div')\n templateWrapper.innerHTML = this._maybeSanitize(this._config.template)\n\n for (const [selector, text] of Object.entries(this._config.content)) {\n this._setContent(templateWrapper, text, selector)\n }\n\n const template = templateWrapper.children[0]\n const extraClass = this._resolvePossibleFunction(this._config.extraClass)\n\n if (extraClass) {\n template.classList.add(...extraClass.split(' '))\n }\n\n return template\n }\n\n // Private\n _typeCheckConfig(config) {\n super._typeCheckConfig(config)\n this._checkContent(config.content)\n }\n\n _checkContent(arg) {\n for (const [selector, content] of Object.entries(arg)) {\n super._typeCheckConfig({ selector, entry: content }, DefaultContentType)\n }\n }\n\n _setContent(template, content, selector) {\n const templateElement = SelectorEngine.findOne(selector, template)\n\n if (!templateElement) {\n return\n }\n\n content = this._resolvePossibleFunction(content)\n\n if (!content) {\n templateElement.remove()\n return\n }\n\n if (isElement(content)) {\n this._putElementInTemplate(getElement(content), templateElement)\n return\n }\n\n if (this._config.html) {\n templateElement.innerHTML = this._maybeSanitize(content)\n return\n }\n\n templateElement.textContent = content\n }\n\n _maybeSanitize(arg) {\n return this._config.sanitize ? sanitizeHtml(arg, this._config.allowList, this._config.sanitizeFn) : arg\n }\n\n _resolvePossibleFunction(arg) {\n return execute(arg, [this])\n }\n\n _putElementInTemplate(element, templateElement) {\n if (this._config.html) {\n templateElement.innerHTML = ''\n templateElement.append(element)\n return\n }\n\n templateElement.textContent = element.textContent\n }\n}\n\nexport default TemplateFactory\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap tooltip.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport * as Popper from '@popperjs/core'\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport Manipulator from './dom/manipulator.js'\nimport { defineJQueryPlugin, execute, findShadowRoot, getElement, getUID, isRTL, noop } from './util/index.js'\nimport { DefaultAllowlist } from './util/sanitizer.js'\nimport TemplateFactory from './util/template-factory.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'tooltip'\nconst DISALLOWED_ATTRIBUTES = new Set(['sanitize', 'allowList', 'sanitizeFn'])\n\nconst CLASS_NAME_FADE = 'fade'\nconst CLASS_NAME_MODAL = 'modal'\nconst CLASS_NAME_SHOW = 'show'\n\nconst SELECTOR_TOOLTIP_INNER = '.tooltip-inner'\nconst SELECTOR_MODAL = `.${CLASS_NAME_MODAL}`\n\nconst EVENT_MODAL_HIDE = 'hide.bs.modal'\n\nconst TRIGGER_HOVER = 'hover'\nconst TRIGGER_FOCUS = 'focus'\nconst TRIGGER_CLICK = 'click'\nconst TRIGGER_MANUAL = 'manual'\n\nconst EVENT_HIDE = 'hide'\nconst EVENT_HIDDEN = 'hidden'\nconst EVENT_SHOW = 'show'\nconst EVENT_SHOWN = 'shown'\nconst EVENT_INSERTED = 'inserted'\nconst EVENT_CLICK = 'click'\nconst EVENT_FOCUSIN = 'focusin'\nconst EVENT_FOCUSOUT = 'focusout'\nconst EVENT_MOUSEENTER = 'mouseenter'\nconst EVENT_MOUSELEAVE = 'mouseleave'\n\nconst AttachmentMap = {\n AUTO: 'auto',\n TOP: 'top',\n RIGHT: isRTL() ? 'left' : 'right',\n BOTTOM: 'bottom',\n LEFT: isRTL() ? 'right' : 'left'\n}\n\nconst Default = {\n allowList: DefaultAllowlist,\n animation: true,\n boundary: 'clippingParents',\n container: false,\n customClass: '',\n delay: 0,\n fallbackPlacements: ['top', 'right', 'bottom', 'left'],\n html: false,\n offset: [0, 6],\n placement: 'top',\n popperConfig: null,\n sanitize: true,\n sanitizeFn: null,\n selector: false,\n template: '
    ' +\n '
    ' +\n '
    ' +\n '
    ',\n title: '',\n trigger: 'hover focus'\n}\n\nconst DefaultType = {\n allowList: 'object',\n animation: 'boolean',\n boundary: '(string|element)',\n container: '(string|element|boolean)',\n customClass: '(string|function)',\n delay: '(number|object)',\n fallbackPlacements: 'array',\n html: 'boolean',\n offset: '(array|string|function)',\n placement: '(string|function)',\n popperConfig: '(null|object|function)',\n sanitize: 'boolean',\n sanitizeFn: '(null|function)',\n selector: '(string|boolean)',\n template: 'string',\n title: '(string|element|function)',\n trigger: 'string'\n}\n\n/**\n * Class definition\n */\n\nclass Tooltip extends BaseComponent {\n constructor(element, config) {\n if (typeof Popper === 'undefined') {\n throw new TypeError('Bootstrap\\'s tooltips require Popper (https://popper.js.org)')\n }\n\n super(element, config)\n\n // Private\n this._isEnabled = true\n this._timeout = 0\n this._isHovered = null\n this._activeTrigger = {}\n this._popper = null\n this._templateFactory = null\n this._newContent = null\n\n // Protected\n this.tip = null\n\n this._setListeners()\n\n if (!this._config.selector) {\n this._fixTitle()\n }\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n enable() {\n this._isEnabled = true\n }\n\n disable() {\n this._isEnabled = false\n }\n\n toggleEnabled() {\n this._isEnabled = !this._isEnabled\n }\n\n toggle() {\n if (!this._isEnabled) {\n return\n }\n\n this._activeTrigger.click = !this._activeTrigger.click\n if (this._isShown()) {\n this._leave()\n return\n }\n\n this._enter()\n }\n\n dispose() {\n clearTimeout(this._timeout)\n\n EventHandler.off(this._element.closest(SELECTOR_MODAL), EVENT_MODAL_HIDE, this._hideModalHandler)\n\n if (this._element.getAttribute('data-bs-original-title')) {\n this._element.setAttribute('title', this._element.getAttribute('data-bs-original-title'))\n }\n\n this._disposePopper()\n super.dispose()\n }\n\n show() {\n if (this._element.style.display === 'none') {\n throw new Error('Please use show on visible elements')\n }\n\n if (!(this._isWithContent() && this._isEnabled)) {\n return\n }\n\n const showEvent = EventHandler.trigger(this._element, this.constructor.eventName(EVENT_SHOW))\n const shadowRoot = findShadowRoot(this._element)\n const isInTheDom = (shadowRoot || this._element.ownerDocument.documentElement).contains(this._element)\n\n if (showEvent.defaultPrevented || !isInTheDom) {\n return\n }\n\n // TODO: v6 remove this or make it optional\n this._disposePopper()\n\n const tip = this._getTipElement()\n\n this._element.setAttribute('aria-describedby', tip.getAttribute('id'))\n\n const { container } = this._config\n\n if (!this._element.ownerDocument.documentElement.contains(this.tip)) {\n container.append(tip)\n EventHandler.trigger(this._element, this.constructor.eventName(EVENT_INSERTED))\n }\n\n this._popper = this._createPopper(tip)\n\n tip.classList.add(CLASS_NAME_SHOW)\n\n // If this is a touch-enabled device we add extra\n // empty mouseover listeners to the body's immediate children;\n // only needed because of broken event delegation on iOS\n // https://www.quirksmode.org/blog/archives/2014/02/mouse_event_bub.html\n if ('ontouchstart' in document.documentElement) {\n for (const element of [].concat(...document.body.children)) {\n EventHandler.on(element, 'mouseover', noop)\n }\n }\n\n const complete = () => {\n EventHandler.trigger(this._element, this.constructor.eventName(EVENT_SHOWN))\n\n if (this._isHovered === false) {\n this._leave()\n }\n\n this._isHovered = false\n }\n\n this._queueCallback(complete, this.tip, this._isAnimated())\n }\n\n hide() {\n if (!this._isShown()) {\n return\n }\n\n const hideEvent = EventHandler.trigger(this._element, this.constructor.eventName(EVENT_HIDE))\n if (hideEvent.defaultPrevented) {\n return\n }\n\n const tip = this._getTipElement()\n tip.classList.remove(CLASS_NAME_SHOW)\n\n // If this is a touch-enabled device we remove the extra\n // empty mouseover listeners we added for iOS support\n if ('ontouchstart' in document.documentElement) {\n for (const element of [].concat(...document.body.children)) {\n EventHandler.off(element, 'mouseover', noop)\n }\n }\n\n this._activeTrigger[TRIGGER_CLICK] = false\n this._activeTrigger[TRIGGER_FOCUS] = false\n this._activeTrigger[TRIGGER_HOVER] = false\n this._isHovered = null // it is a trick to support manual triggering\n\n const complete = () => {\n if (this._isWithActiveTrigger()) {\n return\n }\n\n if (!this._isHovered) {\n this._disposePopper()\n }\n\n this._element.removeAttribute('aria-describedby')\n EventHandler.trigger(this._element, this.constructor.eventName(EVENT_HIDDEN))\n }\n\n this._queueCallback(complete, this.tip, this._isAnimated())\n }\n\n update() {\n if (this._popper) {\n this._popper.update()\n }\n }\n\n // Protected\n _isWithContent() {\n return Boolean(this._getTitle())\n }\n\n _getTipElement() {\n if (!this.tip) {\n this.tip = this._createTipElement(this._newContent || this._getContentForTemplate())\n }\n\n return this.tip\n }\n\n _createTipElement(content) {\n const tip = this._getTemplateFactory(content).toHtml()\n\n // TODO: remove this check in v6\n if (!tip) {\n return null\n }\n\n tip.classList.remove(CLASS_NAME_FADE, CLASS_NAME_SHOW)\n // TODO: v6 the following can be achieved with CSS only\n tip.classList.add(`bs-${this.constructor.NAME}-auto`)\n\n const tipId = getUID(this.constructor.NAME).toString()\n\n tip.setAttribute('id', tipId)\n\n if (this._isAnimated()) {\n tip.classList.add(CLASS_NAME_FADE)\n }\n\n return tip\n }\n\n setContent(content) {\n this._newContent = content\n if (this._isShown()) {\n this._disposePopper()\n this.show()\n }\n }\n\n _getTemplateFactory(content) {\n if (this._templateFactory) {\n this._templateFactory.changeContent(content)\n } else {\n this._templateFactory = new TemplateFactory({\n ...this._config,\n // the `content` var has to be after `this._config`\n // to override config.content in case of popover\n content,\n extraClass: this._resolvePossibleFunction(this._config.customClass)\n })\n }\n\n return this._templateFactory\n }\n\n _getContentForTemplate() {\n return {\n [SELECTOR_TOOLTIP_INNER]: this._getTitle()\n }\n }\n\n _getTitle() {\n return this._resolvePossibleFunction(this._config.title) || this._element.getAttribute('data-bs-original-title')\n }\n\n // Private\n _initializeOnDelegatedTarget(event) {\n return this.constructor.getOrCreateInstance(event.delegateTarget, this._getDelegateConfig())\n }\n\n _isAnimated() {\n return this._config.animation || (this.tip && this.tip.classList.contains(CLASS_NAME_FADE))\n }\n\n _isShown() {\n return this.tip && this.tip.classList.contains(CLASS_NAME_SHOW)\n }\n\n _createPopper(tip) {\n const placement = execute(this._config.placement, [this, tip, this._element])\n const attachment = AttachmentMap[placement.toUpperCase()]\n return Popper.createPopper(this._element, tip, this._getPopperConfig(attachment))\n }\n\n _getOffset() {\n const { offset } = this._config\n\n if (typeof offset === 'string') {\n return offset.split(',').map(value => Number.parseInt(value, 10))\n }\n\n if (typeof offset === 'function') {\n return popperData => offset(popperData, this._element)\n }\n\n return offset\n }\n\n _resolvePossibleFunction(arg) {\n return execute(arg, [this._element])\n }\n\n _getPopperConfig(attachment) {\n const defaultBsPopperConfig = {\n placement: attachment,\n modifiers: [\n {\n name: 'flip',\n options: {\n fallbackPlacements: this._config.fallbackPlacements\n }\n },\n {\n name: 'offset',\n options: {\n offset: this._getOffset()\n }\n },\n {\n name: 'preventOverflow',\n options: {\n boundary: this._config.boundary\n }\n },\n {\n name: 'arrow',\n options: {\n element: `.${this.constructor.NAME}-arrow`\n }\n },\n {\n name: 'preSetPlacement',\n enabled: true,\n phase: 'beforeMain',\n fn: data => {\n // Pre-set Popper's placement attribute in order to read the arrow sizes properly.\n // Otherwise, Popper mixes up the width and height dimensions since the initial arrow style is for top placement\n this._getTipElement().setAttribute('data-popper-placement', data.state.placement)\n }\n }\n ]\n }\n\n return {\n ...defaultBsPopperConfig,\n ...execute(this._config.popperConfig, [defaultBsPopperConfig])\n }\n }\n\n _setListeners() {\n const triggers = this._config.trigger.split(' ')\n\n for (const trigger of triggers) {\n if (trigger === 'click') {\n EventHandler.on(this._element, this.constructor.eventName(EVENT_CLICK), this._config.selector, event => {\n const context = this._initializeOnDelegatedTarget(event)\n context.toggle()\n })\n } else if (trigger !== TRIGGER_MANUAL) {\n const eventIn = trigger === TRIGGER_HOVER ?\n this.constructor.eventName(EVENT_MOUSEENTER) :\n this.constructor.eventName(EVENT_FOCUSIN)\n const eventOut = trigger === TRIGGER_HOVER ?\n this.constructor.eventName(EVENT_MOUSELEAVE) :\n this.constructor.eventName(EVENT_FOCUSOUT)\n\n EventHandler.on(this._element, eventIn, this._config.selector, event => {\n const context = this._initializeOnDelegatedTarget(event)\n context._activeTrigger[event.type === 'focusin' ? TRIGGER_FOCUS : TRIGGER_HOVER] = true\n context._enter()\n })\n EventHandler.on(this._element, eventOut, this._config.selector, event => {\n const context = this._initializeOnDelegatedTarget(event)\n context._activeTrigger[event.type === 'focusout' ? TRIGGER_FOCUS : TRIGGER_HOVER] =\n context._element.contains(event.relatedTarget)\n\n context._leave()\n })\n }\n }\n\n this._hideModalHandler = () => {\n if (this._element) {\n this.hide()\n }\n }\n\n EventHandler.on(this._element.closest(SELECTOR_MODAL), EVENT_MODAL_HIDE, this._hideModalHandler)\n }\n\n _fixTitle() {\n const title = this._element.getAttribute('title')\n\n if (!title) {\n return\n }\n\n if (!this._element.getAttribute('aria-label') && !this._element.textContent.trim()) {\n this._element.setAttribute('aria-label', title)\n }\n\n this._element.setAttribute('data-bs-original-title', title) // DO NOT USE IT. Is only for backwards compatibility\n this._element.removeAttribute('title')\n }\n\n _enter() {\n if (this._isShown() || this._isHovered) {\n this._isHovered = true\n return\n }\n\n this._isHovered = true\n\n this._setTimeout(() => {\n if (this._isHovered) {\n this.show()\n }\n }, this._config.delay.show)\n }\n\n _leave() {\n if (this._isWithActiveTrigger()) {\n return\n }\n\n this._isHovered = false\n\n this._setTimeout(() => {\n if (!this._isHovered) {\n this.hide()\n }\n }, this._config.delay.hide)\n }\n\n _setTimeout(handler, timeout) {\n clearTimeout(this._timeout)\n this._timeout = setTimeout(handler, timeout)\n }\n\n _isWithActiveTrigger() {\n return Object.values(this._activeTrigger).includes(true)\n }\n\n _getConfig(config) {\n const dataAttributes = Manipulator.getDataAttributes(this._element)\n\n for (const dataAttribute of Object.keys(dataAttributes)) {\n if (DISALLOWED_ATTRIBUTES.has(dataAttribute)) {\n delete dataAttributes[dataAttribute]\n }\n }\n\n config = {\n ...dataAttributes,\n ...(typeof config === 'object' && config ? config : {})\n }\n config = this._mergeConfigObj(config)\n config = this._configAfterMerge(config)\n this._typeCheckConfig(config)\n return config\n }\n\n _configAfterMerge(config) {\n config.container = config.container === false ? document.body : getElement(config.container)\n\n if (typeof config.delay === 'number') {\n config.delay = {\n show: config.delay,\n hide: config.delay\n }\n }\n\n if (typeof config.title === 'number') {\n config.title = config.title.toString()\n }\n\n if (typeof config.content === 'number') {\n config.content = config.content.toString()\n }\n\n return config\n }\n\n _getDelegateConfig() {\n const config = {}\n\n for (const [key, value] of Object.entries(this._config)) {\n if (this.constructor.Default[key] !== value) {\n config[key] = value\n }\n }\n\n config.selector = false\n config.trigger = 'manual'\n\n // In the future can be replaced with:\n // const keysWithDifferentValues = Object.entries(this._config).filter(entry => this.constructor.Default[entry[0]] !== this._config[entry[0]])\n // `Object.fromEntries(keysWithDifferentValues)`\n return config\n }\n\n _disposePopper() {\n if (this._popper) {\n this._popper.destroy()\n this._popper = null\n }\n\n if (this.tip) {\n this.tip.remove()\n this.tip = null\n }\n }\n\n // Static\n static jQueryInterface(config) {\n return this.each(function () {\n const data = Tooltip.getOrCreateInstance(this, config)\n\n if (typeof config !== 'string') {\n return\n }\n\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config]()\n })\n }\n}\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Tooltip)\n\nexport default Tooltip\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap popover.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport Tooltip from './tooltip.js'\nimport { defineJQueryPlugin } from './util/index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'popover'\n\nconst SELECTOR_TITLE = '.popover-header'\nconst SELECTOR_CONTENT = '.popover-body'\n\nconst Default = {\n ...Tooltip.Default,\n content: '',\n offset: [0, 8],\n placement: 'right',\n template: '
    ' +\n '
    ' +\n '

    ' +\n '
    ' +\n '
    ',\n trigger: 'click'\n}\n\nconst DefaultType = {\n ...Tooltip.DefaultType,\n content: '(null|string|element|function)'\n}\n\n/**\n * Class definition\n */\n\nclass Popover extends Tooltip {\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Overrides\n _isWithContent() {\n return this._getTitle() || this._getContent()\n }\n\n // Private\n _getContentForTemplate() {\n return {\n [SELECTOR_TITLE]: this._getTitle(),\n [SELECTOR_CONTENT]: this._getContent()\n }\n }\n\n _getContent() {\n return this._resolvePossibleFunction(this._config.content)\n }\n\n // Static\n static jQueryInterface(config) {\n return this.each(function () {\n const data = Popover.getOrCreateInstance(this, config)\n\n if (typeof config !== 'string') {\n return\n }\n\n if (typeof data[config] === 'undefined') {\n throw new TypeError(`No method named \"${config}\"`)\n }\n\n data[config]()\n })\n }\n}\n\n/**\n * jQuery\n */\n\ndefineJQueryPlugin(Popover)\n\nexport default Popover\n", "/**\n * --------------------------------------------------------------------------\n * Bootstrap scrollspy.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\nimport BaseComponent from './base-component.js'\nimport EventHandler from './dom/event-handler.js'\nimport SelectorEngine from './dom/selector-engine.js'\nimport { defineJQueryPlugin, getElement, isDisabled, isVisible } from './util/index.js'\n\n/**\n * Constants\n */\n\nconst NAME = 'scrollspy'\nconst DATA_KEY = 'bs.scrollspy'\nconst EVENT_KEY = `.${DATA_KEY}`\nconst DATA_API_KEY = '.data-api'\n\nconst EVENT_ACTIVATE = `activate${EVENT_KEY}`\nconst EVENT_CLICK = `click${EVENT_KEY}`\nconst EVENT_LOAD_DATA_API = `load${EVENT_KEY}${DATA_API_KEY}`\n\nconst CLASS_NAME_DROPDOWN_ITEM = 'dropdown-item'\nconst CLASS_NAME_ACTIVE = 'active'\n\nconst SELECTOR_DATA_SPY = '[data-bs-spy=\"scroll\"]'\nconst SELECTOR_TARGET_LINKS = '[href]'\nconst SELECTOR_NAV_LIST_GROUP = '.nav, .list-group'\nconst SELECTOR_NAV_LINKS = '.nav-link'\nconst SELECTOR_NAV_ITEMS = '.nav-item'\nconst SELECTOR_LIST_ITEMS = '.list-group-item'\nconst SELECTOR_LINK_ITEMS = `${SELECTOR_NAV_LINKS}, ${SELECTOR_NAV_ITEMS} > ${SELECTOR_NAV_LINKS}, ${SELECTOR_LIST_ITEMS}`\nconst SELECTOR_DROPDOWN = '.dropdown'\nconst SELECTOR_DROPDOWN_TOGGLE = '.dropdown-toggle'\n\nconst Default = {\n offset: null, // TODO: v6 @deprecated, keep it for backwards compatibility reasons\n rootMargin: '0px 0px -25%',\n smoothScroll: false,\n target: null,\n threshold: [0.1, 0.5, 1]\n}\n\nconst DefaultType = {\n offset: '(number|null)', // TODO v6 @deprecated, keep it for backwards compatibility reasons\n rootMargin: 'string',\n smoothScroll: 'boolean',\n target: 'element',\n threshold: 'array'\n}\n\n/**\n * Class definition\n */\n\nclass ScrollSpy extends BaseComponent {\n constructor(element, config) {\n super(element, config)\n\n // this._element is the observablesContainer and config.target the menu links wrapper\n this._targetLinks = new Map()\n this._observableSections = new Map()\n this._rootElement = getComputedStyle(this._element).overflowY === 'visible' ? null : this._element\n this._activeTarget = null\n this._observer = null\n this._previousScrollData = {\n visibleEntryTop: 0,\n parentScrollTop: 0\n }\n this.refresh() // initialize\n }\n\n // Getters\n static get Default() {\n return Default\n }\n\n static get DefaultType() {\n return DefaultType\n }\n\n static get NAME() {\n return NAME\n }\n\n // Public\n refresh() {\n this._initializeTargetsAndObservables()\n this._maybeEnableSmoothScroll()\n\n if (this._observer) {\n this._observer.disconnect()\n } else {\n this._observer = this._getNewObserver()\n }\n\n for (const section of this._observableSections.values()) {\n this._observer.observe(section)\n }\n }\n\n dispose() {\n this._observer.disconnect()\n super.dispose()\n }\n\n // Private\n _configAfterMerge(config) {\n // TODO: on v6 target should be given explicitly & remove the {target: 'ss-target'} case\n config.target = getElement(config.target) || document.body\n\n // TODO: v6 Only for backwards compatibility reasons. Use rootMargin only\n config.rootMargin = config.offset ? `${config.offset}px 0px -30%` : config.rootMargin\n\n if (typeof config.threshold === 'string') {\n config.threshold = config.threshold.split(',').map(value => Number.parseFloat(value))\n }\n\n return config\n }\n\n _maybeEnableSmoothScroll() {\n if (!this._config.smoothScroll) {\n return\n }\n\n // unregister any previous listeners\n EventHandler.off(this._config.target, EVENT_CLICK)\n\n EventHandler.on(this._config.target, EVENT_CLICK, SELECTOR_TARGET_LINKS, event => {\n const observableSection = this._observableSections.get(event.target.hash)\n if (observableSection) {\n event.preventDefault()\n const root = this._rootElement || window\n const height = observableSection.offsetTop - this._element.offsetTop\n if (root.scrollTo) {\n root.scrollTo({ top: height, behavior: 'smooth' })\n return\n }\n\n // Chrome 60 doesn't support `scrollTo`\n root.scrollTop = height\n }\n })\n }\n\n _getNewObserver() {\n const options = {\n root: this._rootElement,\n threshold: this._config.threshold,\n rootMargin: this._config.rootMargin\n }\n\n return new IntersectionObserver(entries => this._observerCallback(entries), options)\n }\n\n // The logic of selection\n _observerCallback(entries) {\n const targetElement = entry => this._targetLinks.get(`#${entry.target.id}`)\n const activate = entry => {\n this._previousScrollData.visibleEntryTop = entry.target.offsetTop\n this._process(targetElement(entry))\n }\n\n const parentScrollTop = (this._rootElement || document.documentElement).scrollTop\n const userScrollsDown = parentScrollTop >= this._previousScrollData.parentScrollTop\n this._previousScrollData.parentScrollTop = parentScrollTop\n\n for (const entry of entries) {\n if (!entry.isIntersecting) {\n this._activeTarget = null\n this._clearActiveClass(targetElement(entry))\n\n continue\n }\n\n const entryIsLowerThanPrevious = entry.target.offsetTop >= this._previousScrollData.visibleEntryTop\n // if we are scrolling down, pick the bigger offsetTop\n if (userScrollsDown && entryIsLowerThanPrevious) {\n activate(entry)\n // if parent isn't scrolled, let's keep the first visible item, breaking the iteration\n if (!parentScrollTop) {\n return\n }\n\n continue\n }\n\n // if we are scrolling up, pick the smallest offsetTop\n if (!userScrollsDown && !entryIsLowerThanPrevious) {\n activate(entry)\n }\n }\n }\n\n _initializeTargetsAndObservables() {\n this._targetLinks = new Map()\n this._observableSections = new Map()\n\n const targetLinks = SelectorEngine.find(SELECTOR_TARGET_LINKS, this._config.target)\n\n for (const anchor of targetLinks) {\n // ensure that the anchor has an id and is not disabled\n if (!anchor.hash || isDisabled(anchor)) {\n continue\n }\n\n const observableSection = SelectorEngine.findOne(decodeURI(anchor.hash), this._element)\n\n // ensure that the observableSection exists & is visible\n if (isVisible(observableSection)) {\n this._targetLinks.set(decodeURI(anchor.hash), anchor)\n this._observableSections.set(anchor.hash, observableSection)\n }\n }\n }\n\n _process(target) {\n if (this._activeTarget === target) {\n return\n }\n\n this._clearActiveClass(this._config.target)\n this._activeTarget = target\n target.classList.add(CLASS_NAME_ACTIVE)\n this._activateParents(target)\n\n EventHandler.trigger(this._element, EVENT_ACTIVATE, { relatedTarget: target })\n }\n\n _activateParents(target) {\n // Activate dropdown parents\n if (target.classList.contains(CLASS_NAME_DROPDOWN_ITEM)) {\n SelectorEngine.findOne(SELECTOR_DROPDOWN_TOGGLE, target.closest(SELECTOR_DROPDOWN))\n .classList.add(CLASS_NAME_ACTIVE)\n return\n }\n\n for (const listGroup of SelectorEngine.parents(target, SELECTOR_NAV_LIST_GROUP)) {\n // Set triggered links parents as active\n // With both