diff --git a/404.html b/404.html index e3994503a..492730a8d 100644 --- a/404.html +++ b/404.html @@ -3,7 +3,7 @@ - HyperFormula (v2.6.1) + HyperFormula (v2.6.2) + + @@ -19,16 +35,16 @@ - + -

404

That's a Four-Oh-Four.
+ - + \ No newline at end of file diff --git a/api-template.html b/api-template.html index 1476c2def..9004ab8e1 100644 --- a/api-template.html +++ b/api-template.html @@ -3,7 +3,7 @@ - HyperFormula (v2.6.1) + HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
- + \ No newline at end of file diff --git a/api/classes/config.html b/api/classes/config.html index 025ca6195..7b2b0a564 100644 --- a/api/classes/config.html +++ b/api/classes/config.html @@ -3,7 +3,7 @@ - Config | HyperFormula (v2.6.1) + Config | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
- +E.g., for timeFormats = ['hh:mm:ss.sss'], valid time strings include:

  • 1:33:33
  • 1:33:33.3
  • 1:33:33.33
  • 1:33:33.333
  • 01:33:33
  • 1:33:33 AM
  • 1:33:33 PM
  • 1:33:33 am
  • 1:33:33 pm
  • 1:33:33AM
  • 1:33:33PM

default ['hh:mm', 'hh:mm:ss.sss']


# undoLimit Readonly

undoLimit: number

Defined in src/Config.ts:598 (opens new window)

Sets the number of elements kept in the undo history.

default 20


# useArrayArithmetic Readonly

useArrayArithmetic: boolean

Defined in src/Config.ts:533 (opens new window)

When set to true, array arithmetic is enabled globally.

When set to false, array arithmetic is enabled only inside array functions (ARRAYFORMULA, FILTER, and ARRAY_CONSTRAIN).

For more information, see the Arrays guide.

default false


# useColumnIndex Readonly

useColumnIndex: boolean

Defined in src/Config.ts:588 (opens new window)

When set to true, switches column search strategy from binary search to column index.

Using column index improves efficiency of the VLOOKUP and MATCH functions, but increases memory usage.

When searching with wildcards or regular expressions, column search strategy falls back to binary search (even with useColumnIndex set to true).

default false


# useRegularExpressions Readonly

useRegularExpressions: boolean

Defined in src/Config.ts:615 (opens new window)


# useStats Readonly

useStats: boolean

Defined in src/Config.ts:590 (opens new window)

When set to true, enables gathering engine statistics and timings.

Useful for testing and benchmarking.

default false


# useWildcards Readonly

useWildcards: boolean

Defined in src/Config.ts:616 (opens new window)

# Methods

# getConfig

getConfig(): ConfigParams

Defined in src/Config.ts:755 (opens new window)

Returns: ConfigParams


# mergeConfig

mergeConfig(init: Partial‹ConfigParams›): Config

Defined in src/Config.ts:759 (opens new window)

Parameters:

Name Type
init Partial‹ConfigParams

Returns: Config

# Object literals

# defaultConfig Static

#defaultConfig: object

Defined in src/Config.ts:491 (opens new window)

# accentSensitive

accentSensitive: false = false

Defined in src/Config.ts:492 (opens new window)

# arrayColumnSeparator

arrayColumnSeparator: "," = ","

Defined in src/Config.ts:510 (opens new window)

# arrayRowSeparator

arrayRowSeparator: ";" = ";"

Defined in src/Config.ts:511 (opens new window)

# binarySearchThreshold

binarySearchThreshold: number = 20

Defined in src/Config.ts:493 (opens new window)

# caseFirst

caseFirst: "lower" = "lower"

Defined in src/Config.ts:496 (opens new window)

# caseSensitive

caseSensitive: false = false

Defined in src/Config.ts:495 (opens new window)

# chooseAddressMappingPolicy

chooseAddressMappingPolicy: AlwaysDense‹› = new AlwaysDense()

Defined in src/Config.ts:497 (opens new window)

# currencySymbol

currencySymbol: string[] = ['$']

Defined in src/Config.ts:494 (opens new window)

# dateFormats

dateFormats: string[] = ['DD/MM/YYYY', 'DD/MM/YY']

Defined in src/Config.ts:498 (opens new window)

# decimalSeparator

decimalSeparator: "." = "."

Defined in src/Config.ts:499 (opens new window)

# evaluateNullToZero

evaluateNullToZero: false = false

Defined in src/Config.ts:500 (opens new window)

# functionArgSeparator

functionArgSeparator: string = ","

Defined in src/Config.ts:501 (opens new window)

# functionPlugins

functionPlugins: never[] = []

Defined in src/Config.ts:502 (opens new window)

# ignorePunctuation

ignorePunctuation: false = false

Defined in src/Config.ts:503 (opens new window)

# ignoreWhiteSpace

ignoreWhiteSpace: "standard" = "standard"

Defined in src/Config.ts:505 (opens new window)

# language

language: string = "enGB"

Defined in src/Config.ts:504 (opens new window)

# leapYear1900

leapYear1900: false = false

Defined in src/Config.ts:507 (opens new window)

# licenseKey

licenseKey: string = ""

Defined in src/Config.ts:506 (opens new window)

# localeLang

localeLang: string = "en"

Defined in src/Config.ts:508 (opens new window)

# matchWholeCell

matchWholeCell: true = true

Defined in src/Config.ts:509 (opens new window)

# maxColumns

maxColumns: number = 18278

Defined in src/Config.ts:513 (opens new window)

# maxRows

maxRows: number = 40000

Defined in src/Config.ts:512 (opens new window)

# nullYear

nullYear: number = 30

Defined in src/Config.ts:514 (opens new window)

# parseDateTime

parseDateTime: defaultParseToDateTime = defaultParseToDateTime

Defined in src/Config.ts:516 (opens new window)

# precisionEpsilon

precisionEpsilon: number = 1e-13

Defined in src/Config.ts:517 (opens new window)

# precisionRounding

precisionRounding: number = 14

Defined in src/Config.ts:518 (opens new window)

# smartRounding

smartRounding: true = true

Defined in src/Config.ts:519 (opens new window)

# stringifyDateTime

stringifyDateTime: defaultStringifyDateTime = defaultStringifyDateTime

Defined in src/Config.ts:520 (opens new window)

# stringifyDuration

stringifyDuration: defaultStringifyDuration = defaultStringifyDuration

Defined in src/Config.ts:521 (opens new window)

# thousandSeparator

thousandSeparator: "" = ""

Defined in src/Config.ts:523 (opens new window)

# timeFormats

timeFormats: string[] = ['hh:mm', 'hh:mm:ss.sss']

Defined in src/Config.ts:522 (opens new window)

# undoLimit

undoLimit: number = 20

Defined in src/Config.ts:524 (opens new window)

# useArrayArithmetic

useArrayArithmetic: false = false

Defined in src/Config.ts:529 (opens new window)

# useColumnIndex

useColumnIndex: false = false

Defined in src/Config.ts:527 (opens new window)

# useRegularExpressions

useRegularExpressions: false = false

Defined in src/Config.ts:525 (opens new window)

# useStats

useStats: false = false

Defined in src/Config.ts:528 (opens new window)

# useWildcards

useWildcards: true = true

Defined in src/Config.ts:526 (opens new window)

nullDate: object

Defined in src/Config.ts:515 (opens new window)

  • day: number = 30

  • month: number = 12

  • year: number = 1899

+ \ No newline at end of file diff --git a/api/classes/emitter.html b/api/classes/emitter.html index 1c0fd0829..861ef6219 100644 --- a/api/classes/emitter.html +++ b/api/classes/emitter.html @@ -3,7 +3,7 @@ - Emitter | HyperFormula (v2.6.1) + Emitter | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
+ \ No newline at end of file diff --git a/api/classes/hyperformula.html b/api/classes/hyperformula.html index dea11e860..1795221bc 100644 --- a/api/classes/hyperformula.html +++ b/api/classes/hyperformula.html @@ -3,7 +3,7 @@ - HyperFormula | HyperFormula (v2.6.1) + HyperFormula | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -

Parameters:

Name Type Description
sheetName string sheet name, case-insensitive

Returns: boolean


# isItPossibleToClearSheet

isItPossibleToClearSheet(sheetId: number): boolean

Defined in src/HyperFormula.ts:2675 (opens new window)

Returns information whether it is possible to clear a specified sheet. If returns true, doing clearSheet operation won't throw any errors, provided sheet exists and its content can be cleared. Returns false otherwise

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromSheets({
  MySheet1: [ ['1'] ],
@@ -245,7 +261,7 @@
 
 // should return 'true' because 'MySheet2' exists and can be cleared
 const isClearable = hfInstance.isItPossibleToClearSheet(1);
-

Parameters:

Name Type Description
sheetId number sheet ID.

Returns: boolean


# isItPossibleToRemoveSheet

isItPossibleToRemoveSheet(sheetId: number): boolean

Defined in src/HyperFormula.ts:2601 (opens new window)

Returns information whether it is possible to remove sheet for the engine. +

Parameters:

Name Type Description
sheetId number sheet ID.

Returns: boolean


# isItPossibleToRemoveSheet

isItPossibleToRemoveSheet(sheetId: number): boolean

Defined in src/HyperFormula.ts:2601 (opens new window)

Returns information whether it is possible to remove sheet for the engine. Returns true if the provided sheet exists, and therefore it can be removed, doing removeSheet operation won't throw any errors. Returns false otherwise

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromSheets({
  MySheet1: [ ['1'] ],
@@ -254,7 +270,7 @@
 
 // should return 'true' because sheet with ID 1 exists and is removable
 const isRemovable = hfInstance.isItPossibleToRemoveSheet(1);
-

Parameters:

Name Type Description
sheetId number sheet ID.

Returns: boolean


# isItPossibleToRenameSheet

isItPossibleToRenameSheet(sheetId: number, newName: string): boolean

Defined in src/HyperFormula.ts:3384 (opens new window)

Returns information whether it is possible to rename sheet. +

Parameters:

Name Type Description
sheetId number sheet ID.

Returns: boolean


# isItPossibleToRenameSheet

isItPossibleToRenameSheet(sheetId: number, newName: string): boolean

Defined in src/HyperFormula.ts:3384 (opens new window)

Returns information whether it is possible to rename sheet. Returns true if the sheet with provided id exists and new name is available Returns false if sheet cannot be renamed

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromSheets({
   MySheet1: [ ['1'] ],
@@ -263,7 +279,7 @@
 
 // returns true
 hfInstance.isItPossibleToRenameSheet(0, 'MySheet0');
-

Parameters:

Name Type Description
sheetId number a sheet number
newName string a name of the sheet to be given

Returns: boolean


# isItPossibleToReplaceSheetContent

isItPossibleToReplaceSheetContent(sheetId: number, values: RawCellContent[][]): boolean

Defined in src/HyperFormula.ts:2747 (opens new window)

Returns information whether it is possible to replace the sheet content. +

Parameters:

Name Type Description
sheetId number a sheet number
newName string a name of the sheet to be given

Returns: boolean


# isItPossibleToReplaceSheetContent

isItPossibleToReplaceSheetContent(sheetId: number, values: RawCellContent[][]): boolean

Defined in src/HyperFormula.ts:2747 (opens new window)

Returns information whether it is possible to replace the sheet content. If returns true, doing setSheetContent operation won't throw any errors, the provided sheet exists and then its content can be replaced. Returns false otherwise

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromSheets({
  MySheet1: [ ['1'] ],
@@ -273,7 +289,7 @@
 // should return 'true' because sheet of ID 0 exists
 // and the provided content can be placed in this sheet
 const isReplaceable = hfInstance.isItPossibleToReplaceSheetContent(0, [['50'], ['60']]);
-

Parameters:

Name Type Description
sheetId number sheet ID.
values RawCellContent[][] array of new values

Returns: boolean


# removeSheet

removeSheet(sheetId: number): ExportedChange[]

Defined in src/HyperFormula.ts:2644 (opens new window)

Removes a sheet

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires sheetRemoved after the sheet was removed

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromSheets({
+

Parameters:

Name Type Description
sheetId number sheet ID.
values RawCellContent[][] array of new values

Returns: boolean


# removeSheet

removeSheet(sheetId: number): ExportedChange[]

Defined in src/HyperFormula.ts:2644 (opens new window)

Removes a sheet

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires sheetRemoved after the sheet was removed

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromSheets({
  MySheet1: [ ['=SUM(MySheet2!A1:A2)'] ],
  MySheet2: [ ['10'] ],
 });
@@ -285,14 +301,14 @@
 //   newValue: { error: [CellError], value: '#REF!' },
 // }]
 const changes = hfInstance.removeSheet(1);
-

Parameters:

Name Type Description
sheetId number sheet ID.

Returns: ExportedChange[]


# renameSheet

renameSheet(sheetId: number, newName: string): void

Defined in src/HyperFormula.ts:3420 (opens new window)

Renames a specified sheet.

fires sheetRenamed after the sheet was renamed

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[SheetNameAlreadyTakenError]] when the provided sheet name already exists

example

const hfInstance = HyperFormula.buildFromSheets({
+

Parameters:

Name Type Description
sheetId number sheet ID.

Returns: ExportedChange[]


# renameSheet

renameSheet(sheetId: number, newName: string): void

Defined in src/HyperFormula.ts:3420 (opens new window)

Renames a specified sheet.

fires sheetRenamed after the sheet was renamed

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[SheetNameAlreadyTakenError]] when the provided sheet name already exists

example

const hfInstance = HyperFormula.buildFromSheets({
   MySheet1: [ ['1'] ],
   MySheet2: [ ['10'] ],
 });
 
 // renames the sheet 'MySheet1'
 hfInstance.renameSheet(0, 'MySheet0');
-

Parameters:

Name Type Description
sheetId number a sheet ID
newName string a name of the sheet to be given, if is the same as the old one the method does nothing

Returns: void


# setSheetContent

setSheetContent(sheetId: number, values: RawCellContent[][]): ExportedChange[]

Defined in src/HyperFormula.ts:2784 (opens new window)

Replaces the sheet content with new values.

Returns an array of cells whose values changed as a result of this operation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when values argument is not an array of arrays

example

const hfInstance = HyperFormula.buildFromSheets({
+

Parameters:

Name Type Description
sheetId number a sheet ID
newName string a name of the sheet to be given, if is the same as the old one the method does nothing

Returns: void


# setSheetContent

setSheetContent(sheetId: number, values: RawCellContent[][]): ExportedChange[]

Defined in src/HyperFormula.ts:2784 (opens new window)

Replaces the sheet content with new values.

Returns an array of cells whose values changed as a result of this operation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when values argument is not an array of arrays

example

const hfInstance = HyperFormula.buildFromSheets({
  MySheet1: [ ['1'] ],
  MySheet2: [ ['10'] ],
 });
@@ -300,12 +316,12 @@
 // should return a list of cells which values changed after the operation,
 // their absolute addresses and new values
 const changes = hfInstance.setSheetContent(0, [['50'], ['60']]);
-

Parameters:

Name Type Description
sheetId number sheet ID.
values RawCellContent[][] array of new values

Returns: ExportedChange[]


# Ranges

# getFillRangeData

getFillRangeData(source: SimpleCellRange, target: SimpleCellRange, offsetsFromTarget: boolean): RawCellContent[][]

Defined in src/HyperFormula.ts:2489 (opens new window)

Returns values to fill target range using source range, with properly extending the range using wrap-around heuristic.

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[ExpectedValueOfTypeError]] if source or target are of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

example

const hfInstance = HyperFormula.buildFromArray([[1, '=A1'], ['=$A$1', '2']]);
+

Parameters:

Name Type Description
sheetId number sheet ID.
values RawCellContent[][] array of new values

Returns: ExportedChange[]


# Ranges

# getFillRangeData

getFillRangeData(source: SimpleCellRange, target: SimpleCellRange, offsetsFromTarget: boolean): RawCellContent[][]

Defined in src/HyperFormula.ts:2489 (opens new window)

Returns values to fill target range using source range, with properly extending the range using wrap-around heuristic.

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[ExpectedValueOfTypeError]] if source or target are of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

example

const hfInstance = HyperFormula.buildFromArray([[1, '=A1'], ['=$A$1', '2']]);
 
 // should return [['2', '=$A$1', '2'], ['=A3', 1, '=C3'], ['2', '=$A$1', '2']]
 hfInstance.getFillRangeData( {start: {sheet: 0, row: 0, col: 0}, end: {sheet: 0, row: 1, col: 1}},
 {start: {sheet: 0, row: 1, col: 1}, end: {sheet: 0, row: 3, col: 3}});
-

Parameters:

Name Type Default Description
source SimpleCellRange - of data
target SimpleCellRange - range where data is intended to be put
offsetsFromTarget boolean false if true, offsets are computed from target corner, otherwise from source corner

Returns: RawCellContent[][]


# getRangeFormulas

getRangeFormulas(source: SimpleCellRange): (string | undefined)[][]

Defined in src/HyperFormula.ts:2419 (opens new window)

Returns cell formulas in given range.

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Default Description
source SimpleCellRange - of data
target SimpleCellRange - range where data is intended to be put
offsetsFromTarget boolean false if true, offsets are computed from target corner, otherwise from source corner

Returns: RawCellContent[][]


# getRangeFormulas

getRangeFormulas(source: SimpleCellRange): (string | undefined)[][]

Defined in src/HyperFormula.ts:2419 (opens new window)

Returns cell formulas in given range.

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(1, 2)', '2', '10'],
  ['5', '6', '7'],
  ['40', '30', '20'],
@@ -314,7 +330,7 @@
 // returns cell formulas of a given range only:
 // [ [ '=SUM(1, 2)', undefined ], [ undefined, undefined ] ]
 const rangeFormulas = hfInstance.getRangeFormulas({ start: { sheet: 0, col: 0, row: 0 }, end: { sheet: 0, col: 1, row: 1 } });
-

Parameters:

Name Type Description
source SimpleCellRange rectangular range

Returns: (string | undefined)[][]


# getRangeSerialized

getRangeSerialized(source: SimpleCellRange): RawCellContent[][]

Defined in src/HyperFormula.ts:2455 (opens new window)

Returns serialized cells in given range.

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
source SimpleCellRange rectangular range

Returns: (string | undefined)[][]


# getRangeSerialized

getRangeSerialized(source: SimpleCellRange): RawCellContent[][]

Defined in src/HyperFormula.ts:2455 (opens new window)

Returns serialized cells in given range.

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(1, 2)', '2', '10'],
  ['5', '6', '7'],
  ['40', '30', '20'],
@@ -323,7 +339,7 @@
 // should return serialized cell content for the given range:
 // [ [ '=SUM(1, 2)', 2 ], [ 5, 6 ] ]
 const rangeSerialized = hfInstance.getRangeSerialized({ start: { sheet: 0, col: 0, row: 0 }, end: { sheet: 0, col: 1, row: 1 } });
-

Parameters:

Name Type Description
source SimpleCellRange rectangular range

Returns: RawCellContent[][]


# getRangeValues

getRangeValues(source: SimpleCellRange): CellValue[][]

Defined in src/HyperFormula.ts:2383 (opens new window)

Returns the cell content of a given range in a [[CellValue]][][] format.

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
source SimpleCellRange rectangular range

Returns: RawCellContent[][]


# getRangeValues

getRangeValues(source: SimpleCellRange): CellValue[][]

Defined in src/HyperFormula.ts:2383 (opens new window)

Returns the cell content of a given range in a [[CellValue]][][] format.

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(1, 2)', '2', '10'],
  ['5', '6', '7'],
  ['40', '30', '20'],
@@ -331,7 +347,7 @@
 
 // returns calculated cells content: [ [ 3, 2 ], [ 5, 6 ] ]
 const rangeValues = hfInstance.getRangeValues({ start: { sheet: 0, col: 0, row: 0 }, end: { sheet: 0, col: 1, row: 1 } });
-

Parameters:

Name Type Description
source SimpleCellRange rectangular range

Returns: CellValue[][]


# Rows

# addRows

addRows(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1640 (opens new window)

Adds multiple rows into a specified position in a given sheet. +

Parameters:

Name Type Description
source SimpleCellRange rectangular range

Returns: CellValue[][]


# Rows

# addRows

addRows(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1640 (opens new window)

Adds multiple rows into a specified position in a given sheet. Does nothing if rows are outside effective sheet size.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[SheetSizeLimitExceededError]] when performing this operation would result in sheet size limits exceeding

example

const hfInstance = HyperFormula.buildFromArray([
  ['1'],
  ['2'],
@@ -340,7 +356,7 @@
 // should return a list of cells which values changed after the operation,
 // their absolute addresses and new values
 const changes = hfInstance.addRows(0, [0, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID in which rows will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format [row, amount], where row is a row number above which the rows will be added

Returns: ExportedChange[]


# isItPossibleToAddRows

isItPossibleToAddRows(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1598 (opens new window)

Returns information whether it is possible to add rows into a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number sheet ID in which rows will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format [row, amount], where row is a row number above which the rows will be added

Returns: ExportedChange[]


# isItPossibleToAddRows

isItPossibleToAddRows(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1598 (opens new window)

Returns information whether it is possible to add rows into a specified position in a given sheet. Checks against particular rules to ascertain that addRows can be called. If returns true, doing addRows operation won't throw any errors. Returns false if adding rows would exceed the sheet size limit or given arguments are invalid.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -350,7 +366,7 @@
 // should return 'true' for this example,
 // it is possible to add one row in the second row of sheet 0
 const isAddable = hfInstance.isItPossibleToAddRows(0, [1, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID in which rows will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format [row, amount], where row is a row number above which the rows will be added

Returns: boolean


# isItPossibleToMoveRows

isItPossibleToMoveRows(sheetId: number, startRow: number, numberOfRows: number, targetRow: number): boolean

Defined in src/HyperFormula.ts:1995 (opens new window)

Returns information whether it is possible to move a particular number of rows to a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number sheet ID in which rows will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format [row, amount], where row is a row number above which the rows will be added

Returns: boolean


# isItPossibleToMoveRows

isItPossibleToMoveRows(sheetId: number, startRow: number, numberOfRows: number, targetRow: number): boolean

Defined in src/HyperFormula.ts:1995 (opens new window)

Returns information whether it is possible to move a particular number of rows to a specified position in a given sheet. Checks against particular rules to ascertain that moveRows can be called. If returns true, doing moveRows operation won't throw any errors. Returns false if the operation might be disrupted and causes side effects by the fact that there is an array inside the selected rows, the target location includes an array or the provided address is invalid.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -361,7 +377,7 @@
 // should return 'true' for this example
 // it is possible to move one row from row 0 into row 2
 const isMovable = hfInstance.isItPossibleToMoveRows(0, 0, 1, 2);
-

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startRow number number of the first row to move
numberOfRows number number of rows to move
targetRow number row number before which rows will be moved

Returns: boolean


# isItPossibleToRemoveRows

isItPossibleToRemoveRows(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1671 (opens new window)

Returns information whether it is possible to remove rows from a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startRow number number of the first row to move
numberOfRows number number of rows to move
targetRow number row number before which rows will be moved

Returns: boolean


# isItPossibleToRemoveRows

isItPossibleToRemoveRows(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1671 (opens new window)

Returns information whether it is possible to remove rows from a specified position in a given sheet. Checks against particular rules to ascertain that removeRows can be called. If returns true, doing removeRows operation won't throw any errors. Returns false if given arguments are invalid.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -372,7 +388,7 @@
 // should return 'true' for this example
 // it is possible to remove one row from row 1 of sheet 0
 const isRemovable = hfInstance.isItPossibleToRemoveRows(0, [1, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID from which rows will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format: [row, amount]

Returns: boolean


# isItPossibleToSetRowOrder

isItPossibleToSetRowOrder(sheetId: number, newRowOrder: number[]): boolean

Defined in src/HyperFormula.ts:1401 (opens new window)

Checks if it is possible to reorder rows of a sheet according to a permutation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
sheetId number sheet ID from which rows will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format: [row, amount]

Returns: boolean


# isItPossibleToSetRowOrder

isItPossibleToSetRowOrder(sheetId: number, newRowOrder: number[]): boolean

Defined in src/HyperFormula.ts:1401 (opens new window)

Checks if it is possible to reorder rows of a sheet according to a permutation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  [1],
  [2],
  [4, 5],
@@ -383,7 +399,7 @@
 
 // returns false
 hfInstance.isItPossibleToSetRowOrder(0, [2]);
-

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newRowOrder number[] permutation of rows

Returns: boolean


# isItPossibleToSwapRowIndexes

isItPossibleToSwapRowIndexes(sheetId: number, rowMapping: [number, number][]): boolean

Defined in src/HyperFormula.ts:1322 (opens new window)

Checks if it is possible to reorder rows of a sheet according to a source-target mapping.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newRowOrder number[] permutation of rows

Returns: boolean


# isItPossibleToSwapRowIndexes

isItPossibleToSwapRowIndexes(sheetId: number, rowMapping: [number, number][]): boolean

Defined in src/HyperFormula.ts:1322 (opens new window)

Checks if it is possible to reorder rows of a sheet according to a source-target mapping.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  [1],
  [2],
  [4, 5],
@@ -394,7 +410,7 @@
 
 // returns false
 const isSwappable = hfInstance.isItPossibleToSwapRowIndexes(0, [[0, 1]]);
-

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
rowMapping [number, number][] array mapping original positions to final positions of rows

Returns: boolean


# moveRows

moveRows(sheetId: number, startRow: number, numberOfRows: number, targetRow: number): ExportedChange[]

Defined in src/HyperFormula.ts:2042 (opens new window)

Moves a particular number of rows to a specified position in a given sheet.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[SourceLocationHasArrayError]] when the source location has array inside - array cannot be moved

throws [[TargetLocationHasArrayError]] when the target location has array inside - cells cannot be replaced by the array

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
rowMapping [number, number][] array mapping original positions to final positions of rows

Returns: boolean


# moveRows

moveRows(sheetId: number, startRow: number, numberOfRows: number, targetRow: number): ExportedChange[]

Defined in src/HyperFormula.ts:2042 (opens new window)

Moves a particular number of rows to a specified position in a given sheet.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[SourceLocationHasArrayError]] when the source location has array inside - array cannot be moved

throws [[TargetLocationHasArrayError]] when the target location has array inside - cells cannot be replaced by the array

example

const hfInstance = HyperFormula.buildFromArray([
  ['1'],
  ['2'],
 ]);
@@ -402,7 +418,7 @@
 // should return a list of cells which values changed after the operation,
 // their absolute addresses and new values
 const changes = hfInstance.moveRows(0, 0, 1, 2);
-

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startRow number number of the first row to move
numberOfRows number number of rows to move
targetRow number row number before which rows will be moved

Returns: ExportedChange[]


# removeRows

removeRows(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1712 (opens new window)

Removes multiple rows from a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startRow number number of the first row to move
numberOfRows number number of rows to move
targetRow number row number before which rows will be moved

Returns: ExportedChange[]


# removeRows

removeRows(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1712 (opens new window)

Removes multiple rows from a specified position in a given sheet. Does nothing if rows are outside the effective sheet size.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
  ['1'],
  ['2'],
@@ -410,7 +426,7 @@
 
 // should return: [{ sheet: 0, col: 1, row: 2, value: null }] for this example
 const changes = hfInstance.removeRows(0, [1, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID from which rows will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format: [row, amount]

Returns: ExportedChange[]


# setRowOrder

setRowOrder(sheetId: number, newRowOrder: number[]): ExportedChange[]

Defined in src/HyperFormula.ts:1370 (opens new window)

Reorders rows of a sheet according to a permutation of 0-based indexes. +

Parameters:

Name Type Description
sheetId number sheet ID from which rows will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format: [row, amount]

Returns: ExportedChange[]


# setRowOrder

setRowOrder(sheetId: number, newRowOrder: number[]): ExportedChange[]

Defined in src/HyperFormula.ts:1370 (opens new window)

Reorders rows of a sheet according to a permutation of 0-based indexes. Parameter newRowOrder should have a form [ newPositionForRow0, newPositionForRow1, newPositionForRow2, ... ]. This method might be used to sort the rows of a sheet.

Returns an array of cells whose values changed as a result of this operation.

Note: This method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when rowMapping does not define correct row permutation for some subset of rows of the given sheet

throws [[SourceLocationHasArrayError]] when the selected position has array inside

example

const hfInstance = HyperFormula.buildFromArray([
  ['A'],
@@ -424,7 +440,7 @@
 const changes = hfInstance.setRowOrder(0, newRowOrder);
 
 // Sheet after this operation: [['A'], ['D'], ['C'], ['B']]
-

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newRowOrder number[] permutation of rows

Returns: ExportedChange[]


# swapRowIndexes

swapRowIndexes(sheetId: number, rowMapping: [number, number][]): ExportedChange[]

Defined in src/HyperFormula.ts:1291 (opens new window)

Reorders rows of a sheet according to a source-target mapping.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when rowMapping does not define correct row permutation for some subset of rows of the given sheet

throws [[SourceLocationHasArrayError]] when the selected position has array inside

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newRowOrder number[] permutation of rows

Returns: ExportedChange[]


# swapRowIndexes

swapRowIndexes(sheetId: number, rowMapping: [number, number][]): ExportedChange[]

Defined in src/HyperFormula.ts:1291 (opens new window)

Reorders rows of a sheet according to a source-target mapping.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when rowMapping does not define correct row permutation for some subset of rows of the given sheet

throws [[SourceLocationHasArrayError]] when the selected position has array inside

example

const hfInstance = HyperFormula.buildFromArray([
  [1],
  [2],
  [4, 5],
@@ -448,7 +464,7 @@
 //   newValue: 5,
 // }]
 const changes = hfInstance.swapRowIndexes(0, [[0, 2], [2, 0]]);
-

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
rowMapping [number, number][] array mapping original positions to final positions of rows

Returns: ExportedChange[]


# Columns

# addColumns

addColumns(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1788 (opens new window)

Adds multiple columns into a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
rowMapping [number, number][] array mapping original positions to final positions of rows

Returns: ExportedChange[]


# Columns

# addColumns

addColumns(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1788 (opens new window)

Adds multiple columns into a specified position in a given sheet. Does nothing if the columns are outside the effective sheet size.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[SheetSizeLimitExceededError]] when performing this operation would result in sheet size limits exceeding

example

const hfInstance = HyperFormula.buildFromArray([
  ['=RAND()', '42'],
 ]);
@@ -460,7 +476,7 @@
 //   newValue: 0.92754862796338,
 // }]
 const changes = hfInstance.addColumns(0, [0, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID in which columns will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format: [column, amount], where column is a column number from which new columns will be added

Returns: ExportedChange[]


# isItPossibleToAddColumns

isItPossibleToAddColumns(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1742 (opens new window)

Returns information whether it is possible to add columns into a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number sheet ID in which columns will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format: [column, amount], where column is a column number from which new columns will be added

Returns: ExportedChange[]


# isItPossibleToAddColumns

isItPossibleToAddColumns(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1742 (opens new window)

Returns information whether it is possible to add columns into a specified position in a given sheet. Checks against particular rules to ascertain that addColumns can be called. If returns true, doing addColumns operation won't throw any errors. Returns false if adding columns would exceed the sheet size limit or given arguments are invalid.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -470,7 +486,7 @@
 // should return 'true' for this example,
 // it is possible to add 1 column in sheet 0, at column 1
 const isAddable = hfInstance.isItPossibleToAddColumns(0, [1, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID in which columns will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format: [column, amount], where column is a column number from which new columns will be added

Returns: boolean


# isItPossibleToMoveColumns

isItPossibleToMoveColumns(sheetId: number, startColumn: number, numberOfColumns: number, targetColumn: number): boolean

Defined in src/HyperFormula.ts:2077 (opens new window)

Returns information whether it is possible to move a particular number of columns to a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number sheet ID in which columns will be added
...indexes ColumnRowIndex[] non-contiguous indexes with format: [column, amount], where column is a column number from which new columns will be added

Returns: boolean


# isItPossibleToMoveColumns

isItPossibleToMoveColumns(sheetId: number, startColumn: number, numberOfColumns: number, targetColumn: number): boolean

Defined in src/HyperFormula.ts:2077 (opens new window)

Returns information whether it is possible to move a particular number of columns to a specified position in a given sheet. Checks against particular rules to ascertain that moveColumns can be called. If returns true, doing moveColumns operation won't throw any errors. Returns false if the operation might be disrupted and causes side effects by the fact that there is an array inside the selected columns, the target location includes an array or the provided address is invalid.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -480,7 +496,7 @@
 // should return 'true' for this example
 // it is possible to move one column from column 1 into column 2 of sheet 0
 const isMovable = hfInstance.isItPossibleToMoveColumns(0, 1, 1, 2);
-

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startColumn number number of the first column to move
numberOfColumns number number of columns to move
targetColumn number column number before which columns will be moved

Returns: boolean


# isItPossibleToRemoveColumns

isItPossibleToRemoveColumns(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1818 (opens new window)

Returns information whether it is possible to remove columns from a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startColumn number number of the first column to move
numberOfColumns number number of columns to move
targetColumn number column number before which columns will be moved

Returns: boolean


# isItPossibleToRemoveColumns

isItPossibleToRemoveColumns(sheetId: number, ...indexes: ColumnRowIndex[]): boolean

Defined in src/HyperFormula.ts:1818 (opens new window)

Returns information whether it is possible to remove columns from a specified position in a given sheet. Checks against particular rules to ascertain that removeColumns can be called. If returns true, doing removeColumns operation won't throw any errors. Returns false if given arguments are invalid.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -490,7 +506,7 @@
 // should return 'true' for this example
 // it is possible to remove one column, in place of the second column of sheet 0
 const isRemovable = hfInstance.isItPossibleToRemoveColumns(0, [1, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID from which columns will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format [column, amount]

Returns: boolean


# isItPossibleToSetColumnOrder

isItPossibleToSetColumnOrder(sheetId: number, newColumnOrder: number[]): boolean

Defined in src/HyperFormula.ts:1562 (opens new window)

Checks if it is possible to reorder columns of a sheet according to a permutation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
sheetId number sheet ID from which columns will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format [column, amount]

Returns: boolean


# isItPossibleToSetColumnOrder

isItPossibleToSetColumnOrder(sheetId: number, newColumnOrder: number[]): boolean

Defined in src/HyperFormula.ts:1562 (opens new window)

Checks if it is possible to reorder columns of a sheet according to a permutation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  [1, 2, 4],
  [5]
 ]);
@@ -500,7 +516,7 @@
 
 // returns false
 hfInstance.isItPossibleToSetColumnOrder(0, [1]);
-

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newColumnOrder number[] permutation of columns

Returns: boolean


# isItPossibleToSwapColumnIndexes

isItPossibleToSwapColumnIndexes(sheetId: number, columnMapping: [number, number][]): boolean

Defined in src/HyperFormula.ts:1487 (opens new window)

Checks if it is possible to reorder columns of a sheet according to a source-target mapping.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newColumnOrder number[] permutation of columns

Returns: boolean


# isItPossibleToSwapColumnIndexes

isItPossibleToSwapColumnIndexes(sheetId: number, columnMapping: [number, number][]): boolean

Defined in src/HyperFormula.ts:1487 (opens new window)

Checks if it is possible to reorder columns of a sheet according to a source-target mapping.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  [1, 2, 4],
  [5]
 ]);
@@ -510,7 +526,7 @@
 
 // returns false
 hfInstance.isItPossibleToSwapColumnIndexes(0, [[0, 1]]);
-

Parameters:

Name Type
sheetId number
columnMapping [number, number][]

Returns: boolean


# moveColumns

moveColumns(sheetId: number, startColumn: number, numberOfColumns: number, targetColumn: number): ExportedChange[]

Defined in src/HyperFormula.ts:2130 (opens new window)

Moves a particular number of columns to a specified position in a given sheet.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[SourceLocationHasArrayError]] when the source location has array inside - array cannot be moved

throws [[TargetLocationHasArrayError]] when the target location has array inside - cells cannot be replaced by the array

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type
sheetId number
columnMapping [number, number][]

Returns: boolean


# moveColumns

moveColumns(sheetId: number, startColumn: number, numberOfColumns: number, targetColumn: number): ExportedChange[]

Defined in src/HyperFormula.ts:2130 (opens new window)

Moves a particular number of columns to a specified position in a given sheet.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[SourceLocationHasArrayError]] when the source location has array inside - array cannot be moved

throws [[TargetLocationHasArrayError]] when the target location has array inside - cells cannot be replaced by the array

example

const hfInstance = HyperFormula.buildFromArray([
  ['1', '2', '3', '=RAND()', '=SUM(A1:C1)'],
 ]);
 
@@ -524,7 +540,7 @@
 //   newValue: 6.16210054671639,
 // }]
 const changes = hfInstance.moveColumns(0, 1, 1, 2);
-

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startColumn number number of the first column to move
numberOfColumns number number of columns to move
targetColumn number column number before which columns will be moved

Returns: ExportedChange[]


# removeColumns

removeColumns(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1863 (opens new window)

Removes multiple columns from a specified position in a given sheet. +

Parameters:

Name Type Description
sheetId number a sheet number in which the operation will be performed
startColumn number number of the first column to move
numberOfColumns number number of columns to move
targetColumn number column number before which columns will be moved

Returns: ExportedChange[]


# removeColumns

removeColumns(sheetId: number, ...indexes: ColumnRowIndex[]): ExportedChange[]

Defined in src/HyperFormula.ts:1863 (opens new window)

Removes multiple columns from a specified position in a given sheet. Does nothing if columns are outside the effective sheet size.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when the given arguments are invalid

example

const hfInstance = HyperFormula.buildFromArray([
  ['0', '=SUM(1, 2, 3)', '=A1'],
 ]);
@@ -536,7 +552,7 @@
 //   newValue: { error: [CellError], value: '#REF!' },
 // }]
 const changes = hfInstance.removeColumns(0, [0, 1]);
-

Parameters:

Name Type Description
sheetId number sheet ID from which columns will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format: [column, amount]

Returns: ExportedChange[]


# setColumnOrder

setColumnOrder(sheetId: number, newColumnOrder: number[]): ExportedChange[]

Defined in src/HyperFormula.ts:1532 (opens new window)

Reorders columns of a sheet according to a permutation of 0-based indexes. +

Parameters:

Name Type Description
sheetId number sheet ID from which columns will be removed
...indexes ColumnRowIndex[] non-contiguous indexes with format: [column, amount]

Returns: ExportedChange[]


# setColumnOrder

setColumnOrder(sheetId: number, newColumnOrder: number[]): ExportedChange[]

Defined in src/HyperFormula.ts:1532 (opens new window)

Reorders columns of a sheet according to a permutation of 0-based indexes. Parameter newColumnOrder should have a form [ newPositionForColumn0, newPositionForColumn1, newPositionForColumn2, ... ]. This method might be used to sort the columns of a sheet.

Returns an array of cells whose values changed as a result of this operation.

Note: This method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when columnMapping does not define correct column permutation for some subset of columns of the given sheet

throws [[SourceLocationHasArrayError]] when the selected position has array inside

example

const hfInstance = HyperFormula.buildFromArray([
   ['A', 'B', 'C', 'D']
@@ -547,7 +563,7 @@
 const changes = hfInstance.setColumnOrder(0, newColumnOrder);
 
 // Sheet after this operation: [['A', 'D', 'C', 'B']]
-

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newColumnOrder number[] permutation of columns

Returns: ExportedChange[]


# swapColumnIndexes

swapColumnIndexes(sheetId: number, columnMapping: [number, number][]): ExportedChange[]

Defined in src/HyperFormula.ts:1459 (opens new window)

Reorders columns of a sheet according to a source-target mapping.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when columnMapping does not define correct column permutation for some subset of columns of the given sheet

throws [[SourceLocationHasArrayError]] when the selected position has array inside

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
newColumnOrder number[] permutation of columns

Returns: ExportedChange[]


# swapColumnIndexes

swapColumnIndexes(sheetId: number, columnMapping: [number, number][]): ExportedChange[]

Defined in src/HyperFormula.ts:1459 (opens new window)

Reorders columns of a sheet according to a source-target mapping.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when columnMapping does not define correct column permutation for some subset of columns of the given sheet

throws [[SourceLocationHasArrayError]] when the selected position has array inside

example

const hfInstance = HyperFormula.buildFromArray([
  [1, 2, 4],
  [5]
 ]);
@@ -570,7 +586,7 @@
 //   newValue: null,
 // }]
 const changes = hfInstance.swapColumnIndexes(0, [[0, 2], [2, 0]]);
-

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
columnMapping [number, number][] array mapping original positions to final positions of columns

Returns: ExportedChange[]


# Cells

# doesCellHaveFormula

doesCellHaveFormula(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3172 (opens new window)

Returns true if the specified cell contains a formula. +

Parameters:

Name Type Description
sheetId number ID of a sheet to operate on
columnMapping [number, number][] array mapping original positions to final positions of columns

Returns: ExportedChange[]


# Cells

# doesCellHaveFormula

doesCellHaveFormula(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3172 (opens new window)

Returns true if the specified cell contains a formula. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(A2:A3)', '2'],
 ]);
@@ -580,7 +596,7 @@
 
 // should return 'false' since the B1 cell does not contain a formula
 const B1NoFormula = hfInstance.doesCellHaveFormula({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# doesCellHaveSimpleValue

doesCellHaveSimpleValue(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3141 (opens new window)

Returns true if the specified cell contains a simple value. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# doesCellHaveSimpleValue

doesCellHaveSimpleValue(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3141 (opens new window)

Returns true if the specified cell contains a simple value. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(A2:A3)', '2'],
 ]);
@@ -590,7 +606,7 @@
 
 // should return 'false' since the selected cell does not contain a simple value
 const isB1Simple = hfInstance.doesCellHaveSimpleValue({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# getCellFormula

getCellFormula(cellAddress: SimpleCellAddress): string | undefined

Defined in src/HyperFormula.ts:691 (opens new window)

Returns a normalized formula string from the cell of a given address or undefined for an address that does not exist and empty values.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] when cellAddress is of incorrect type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# getCellFormula

getCellFormula(cellAddress: SimpleCellAddress): string | undefined

Defined in src/HyperFormula.ts:691 (opens new window)

Returns a normalized formula string from the cell of a given address or undefined for an address that does not exist and empty values.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] when cellAddress is of incorrect type

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(1, 2, 3)', '0'],
 ]);
 
@@ -599,7 +615,7 @@
 
 // should return a normalized B1 cell formula: 'undefined'
 const B1Formula = hfInstance.getCellFormula({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: string | undefined


getCellHyperlink(cellAddress: SimpleCellAddress): string | undefined

Defined in src/HyperFormula.ts:721 (opens new window)

Returns the HYPERLINK url for a cell of a given address or undefined for an address that does not exist or a cell that is not HYPERLINK

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] when cellAddress is of incorrect type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: string | undefined


getCellHyperlink(cellAddress: SimpleCellAddress): string | undefined

Defined in src/HyperFormula.ts:721 (opens new window)

Returns the HYPERLINK url for a cell of a given address or undefined for an address that does not exist or a cell that is not HYPERLINK

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] when cellAddress is of incorrect type

example

const hfInstance = HyperFormula.buildFromArray([
  ['=HYPERLINK("https://hyperformula.handsontable.com/", "HyperFormula")', '0'],
 ]);
 
@@ -608,7 +624,7 @@
 
 // should return 'undefined' for a cell that is not 'HYPERLINK'
 const B1Hyperlink = hfInstance.getCellHyperlink({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: string | undefined


# getCellSerialized

getCellSerialized(cellAddress: SimpleCellAddress): RawCellContent

Defined in src/HyperFormula.ts:753 (opens new window)

Returns [[RawCellContent]] with a serialized content of the cell of a given address: either a cell formula, an explicit value, or an error.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[ExpectedValueOfTypeError]] when cellAddress is of incorrect type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: string | undefined


# getCellSerialized

getCellSerialized(cellAddress: SimpleCellAddress): RawCellContent

Defined in src/HyperFormula.ts:753 (opens new window)

Returns [[RawCellContent]] with a serialized content of the cell of a given address: either a cell formula, an explicit value, or an error.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[ExpectedValueOfTypeError]] when cellAddress is of incorrect type

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(1, 2, 3)', '0'],
 ]);
 
@@ -617,7 +633,7 @@
 
 // should return serialized content of B1 cell: '0'
 const cellB1Serialized = hfInstance.getCellSerialized({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: RawCellContent


# getCellType

getCellType(cellAddress: SimpleCellAddress): CellType

Defined in src/HyperFormula.ts:3109 (opens new window)

Returns the type of a cell at a given address. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: RawCellContent


# getCellType

getCellType(cellAddress: SimpleCellAddress): CellType

Defined in src/HyperFormula.ts:3109 (opens new window)

Returns the type of a cell at a given address. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(A2:A3)', '2'],
 ]);
@@ -627,7 +643,7 @@
 
 // should return 'VALUE', the cell of given coordinates is of this type
 const cellB1Type = hfInstance.getCellType({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellType


# getCellValue

getCellValue(cellAddress: SimpleCellAddress): CellValue

Defined in src/HyperFormula.ts:660 (opens new window)

Returns the cell value of a given address. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellType


# getCellValue

getCellValue(cellAddress: SimpleCellAddress): CellValue

Defined in src/HyperFormula.ts:660 (opens new window)

Returns the cell value of a given address. Applies rounding and post-processing.

throws [[ExpectedValueOfTypeError]] when cellAddress is of incorrect type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[EvaluationSuspendedError]] when the evaluation is suspended

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(1, 2, 3)', '2'],
 ]);
@@ -637,7 +653,7 @@
 
 // get value of B1 cell, should be '2'
 const B1Value = hfInstance.getCellValue({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellValue


# getCellValueDetailedType

getCellValueDetailedType(cellAddress: SimpleCellAddress): CellValueDetailedType

Defined in src/HyperFormula.ts:3299 (opens new window)

Returns detailed type of the cell value of a given address. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellValue


# getCellValueDetailedType

getCellValueDetailedType(cellAddress: SimpleCellAddress): CellValueDetailedType

Defined in src/HyperFormula.ts:3299 (opens new window)

Returns detailed type of the cell value of a given address. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  ['1%', '1$'],
 ]);
@@ -647,7 +663,7 @@
 
 // should return 'NUMBER_CURRENCY', cell value type of provided coordinates is a number with a format inference currency.
 const cellType = hfInstance.getCellValueDetailedType({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellValueDetailedType


# getCellValueFormat

getCellValueFormat(cellAddress: SimpleCellAddress): FormatInfo

Defined in src/HyperFormula.ts:3333 (opens new window)

Returns auxiliary format information of the cell value of a given address. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellValueDetailedType


# getCellValueFormat

getCellValueFormat(cellAddress: SimpleCellAddress): FormatInfo

Defined in src/HyperFormula.ts:3333 (opens new window)

Returns auxiliary format information of the cell value of a given address. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  ['1$', '1'],
 ]);
@@ -657,7 +673,7 @@
 
 // should return undefined, cell value type of provided coordinates is a number with no format information.
 const cellFormat = hfInstance.getCellValueFormat({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: FormatInfo


# getCellValueType

getCellValueType(cellAddress: SimpleCellAddress): CellValueType

Defined in src/HyperFormula.ts:3265 (opens new window)

Returns type of the cell value of a given address. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: FormatInfo


# getCellValueType

getCellValueType(cellAddress: SimpleCellAddress): CellValueType

Defined in src/HyperFormula.ts:3265 (opens new window)

Returns type of the cell value of a given address. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  ['=SUM(1, 2, 3)', '2'],
 ]);
@@ -667,7 +683,7 @@
 
 // should return 'NUMBER', cell value type of provided coordinates is a number
 const cellValue = hfInstance.getCellValueType({ sheet: 0, col: 0, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellValueType


# isCellEmpty

isCellEmpty(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3204 (opens new window)

Returnstrue if the specified cell is empty. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: CellValueType


# isCellEmpty

isCellEmpty(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3204 (opens new window)

Returnstrue if the specified cell is empty. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
   [null, '1'],
 ]);
@@ -677,14 +693,14 @@
 
 // should return 'false', cell of provided coordinates is not empty
 const isNotEmpty = hfInstance.isCellEmpty({ sheet: 0, col: 1, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# isCellPartOfArray

isCellPartOfArray(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3232 (opens new window)

Returns true if a given cell is a part of an array. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# isCellPartOfArray

isCellPartOfArray(cellAddress: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:3232 (opens new window)

Returns true if a given cell is a part of an array. The method accepts cell coordinates as object with column, row and sheet numbers.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if cellAddress is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
    ['{=TRANSPOSE(B1:B1)}'],
 ]);
 
 // should return 'true', cell of provided coordinates is a part of an array
 const isPartOfArray = hfInstance.isCellPartOfArray({ sheet: 0, col: 0, row: 0 });
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# isItPossibleToMoveCells

isItPossibleToMoveCells(source: SimpleCellRange, destinationLeftCorner: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:1899 (opens new window)

Returns information whether it is possible to move cells to a specified position in a given sheet. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress cell coordinates

Returns: boolean


# isItPossibleToMoveCells

isItPossibleToMoveCells(source: SimpleCellRange, destinationLeftCorner: SimpleCellAddress): boolean

Defined in src/HyperFormula.ts:1899 (opens new window)

Returns information whether it is possible to move cells to a specified position in a given sheet. Checks against particular rules to ascertain that moveCells can be called. If returns true, doing moveCells operation won't throw any errors. Returns false if the operation might be disrupted and causes side effects by the fact that there is an array inside the selected columns, the target location includes an array or the provided address is invalid.

throws [[ExpectedValueOfTypeError]] if destinationLeftCorner, source, or any of basic type arguments are of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

example

const hfInstance = HyperFormula.buildFromArray([
@@ -700,7 +716,7 @@
 // from the corner: column 1 and row 0 of sheet 0
 // into destination corner: column 3, row 0 of sheet 0
 const isMovable = hfInstance.isItPossibleToMoveCells({ start: source, end: source }, destination);
-

Parameters:

Name Type Description
source SimpleCellRange range for a moved block
destinationLeftCorner SimpleCellAddress upper left address of the target cell block

Returns: boolean


# isItPossibleToSetCellContents

isItPossibleToSetCellContents(address: SimpleCellAddress | SimpleCellRange): boolean

Defined in src/HyperFormula.ts:1186 (opens new window)

Returns information whether it is possible to change the content in a rectangular area bounded by the box. +

Parameters:

Name Type Description
source SimpleCellRange range for a moved block
destinationLeftCorner SimpleCellAddress upper left address of the target cell block

Returns: boolean


# isItPossibleToSetCellContents

isItPossibleToSetCellContents(address: SimpleCellAddress | SimpleCellRange): boolean

Defined in src/HyperFormula.ts:1186 (opens new window)

Returns information whether it is possible to change the content in a rectangular area bounded by the box. If returns true, doing setCellContents operation won't throw any errors. Returns false if the address is invalid or the sheet does not exist.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

example

const hfInstance = HyperFormula.buildFromArray([
  ['1', '2'],
@@ -714,7 +730,7 @@
 // should return 'true' for this example, it is possible to set content of
 // width 2, height 1 in the first row and column of sheet 0
 const isSettable = hfInstance.isItPossibleToSetCellContents({ start: address1, end: address2 });
-

Parameters:

Name Type Description
address SimpleCellAddress | SimpleCellRange single cell or block of cells to check

Returns: boolean


# moveCells

moveCells(source: SimpleCellRange, destinationLeftCorner: SimpleCellAddress): ExportedChange[]

Defined in src/HyperFormula.ts:1956 (opens new window)

Moves the content of a cell block from source to the target location.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if destinationLeftCorner or source are of wrong type

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[SheetSizeLimitExceededError]] when performing this operation would result in sheet size limits exceeding

throws [[SourceLocationHasArrayError]] when the source location has array inside - array cannot be moved

throws [[TargetLocationHasArrayError]] when the target location has array inside - cells cannot be replaced by the array

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
address SimpleCellAddress | SimpleCellRange single cell or block of cells to check

Returns: boolean


# moveCells

moveCells(source: SimpleCellRange, destinationLeftCorner: SimpleCellAddress): ExportedChange[]

Defined in src/HyperFormula.ts:1956 (opens new window)

Moves the content of a cell block from source to the target location.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if destinationLeftCorner or source are of wrong type

throws [[InvalidArgumentsError]] when the given arguments are invalid

throws [[SheetSizeLimitExceededError]] when performing this operation would result in sheet size limits exceeding

throws [[SourceLocationHasArrayError]] when the source location has array inside - array cannot be moved

throws [[TargetLocationHasArrayError]] when the target location has array inside - cells cannot be replaced by the array

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

example

const hfInstance = HyperFormula.buildFromArray([
  ['=RAND()', '42'],
 ]);
 
@@ -729,7 +745,7 @@
 //   newValue: 0.93524248002062,
 // }]
 const changes = hfInstance.moveCells({ start: source, end: source }, destination);
-

Parameters:

Name Type Description
source SimpleCellRange range for a moved block
destinationLeftCorner SimpleCellAddress upper left address of the target cell block

Returns: ExportedChange[]


# setCellContents

setCellContents(topLeftCornerAddress: SimpleCellAddress, cellContents: RawCellContent[][] | RawCellContent): ExportedChange[]

Defined in src/HyperFormula.ts:1239 (opens new window)

Sets the content for a block of cells of a given coordinates.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when the value is not an array of arrays or a raw cell value

throws [[SheetSizeLimitExceededError]] when performing this operation would result in sheet size limits exceeding

throws [[ExpectedValueOfTypeError]] if topLeftCornerAddress argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
source SimpleCellRange range for a moved block
destinationLeftCorner SimpleCellAddress upper left address of the target cell block

Returns: ExportedChange[]


# setCellContents

setCellContents(topLeftCornerAddress: SimpleCellAddress, cellContents: RawCellContent[][] | RawCellContent): ExportedChange[]

Defined in src/HyperFormula.ts:1239 (opens new window)

Sets the content for a block of cells of a given coordinates.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[InvalidArgumentsError]] when the value is not an array of arrays or a raw cell value

throws [[SheetSizeLimitExceededError]] when performing this operation would result in sheet size limits exceeding

throws [[ExpectedValueOfTypeError]] if topLeftCornerAddress argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
  ['1', '2', '=A1'],
 ]);
 
@@ -739,7 +755,7 @@
 //   newValue: 2,
 // }]
 const changes = hfInstance.setCellContents({ col: 3, row: 0, sheet: 0 }, [['=B1']]);
-

Parameters:

Name Type Description
topLeftCornerAddress SimpleCellAddress top left corner of block of cells
cellContents RawCellContent[][] | RawCellContent array with content

Returns: ExportedChange[]


# Named Expressions

# addNamedExpression

addNamedExpression(expressionName: string, expression: RawCellContent, scope?: undefined | number, options?: NamedExpressionOptions): ExportedChange[]

Defined in src/HyperFormula.ts:3650 (opens new window)

Adds a specified named expression.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires namedExpressionAdded always, unless batch mode is used

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NamedExpressionNameIsAlreadyTakenError]] when the named-expression name is not available.

throws [[NamedExpressionNameIsInvalidError]] when the named-expression name is not valid

throws [[NoRelativeAddressesAllowedError]] when the named-expression formula contains relative references

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
topLeftCornerAddress SimpleCellAddress top left corner of block of cells
cellContents RawCellContent[][] | RawCellContent array with content

Returns: ExportedChange[]


# Named Expressions

# addNamedExpression

addNamedExpression(expressionName: string, expression: RawCellContent, scope?: undefined | number, options?: NamedExpressionOptions): ExportedChange[]

Defined in src/HyperFormula.ts:3650 (opens new window)

Adds a specified named expression.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires namedExpressionAdded always, unless batch mode is used

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NamedExpressionNameIsAlreadyTakenError]] when the named-expression name is not available.

throws [[NamedExpressionNameIsInvalidError]] when the named-expression name is not valid

throws [[NoRelativeAddressesAllowedError]] when the named-expression formula contains relative references

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
 ]);
 
@@ -751,7 +767,7 @@
 //   newValue: 142,
 // }]
 const changes = hfInstance.addNamedExpression('prettyName', '=Sheet1!$A$1+100', 0);
-

Parameters:

Name Type Description
expressionName string a name of the expression to be added
expression RawCellContent the expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope
options? NamedExpressionOptions additional metadata related to named expression

Returns: ExportedChange[]


# changeNamedExpression

changeNamedExpression(expressionName: string, newExpression: RawCellContent, scope?: undefined | number, options?: NamedExpressionOptions): ExportedChange[]

Defined in src/HyperFormula.ts:3866 (opens new window)

Changes a given named expression to a specified formula.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NamedExpressionDoesNotExistError]] when the given expression does not exist.

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

throws [[ArrayFormulasNotSupportedError]] when the named expression formula is an array formula

throws [[NoRelativeAddressesAllowedError]] when the named expression formula contains relative references

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
expressionName string a name of the expression to be added
expression RawCellContent the expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope
options? NamedExpressionOptions additional metadata related to named expression

Returns: ExportedChange[]


# changeNamedExpression

changeNamedExpression(expressionName: string, newExpression: RawCellContent, scope?: undefined | number, options?: NamedExpressionOptions): ExportedChange[]

Defined in src/HyperFormula.ts:3866 (opens new window)

Changes a given named expression to a specified formula.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NamedExpressionDoesNotExistError]] when the given expression does not exist.

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

throws [[ArrayFormulasNotSupportedError]] when the named expression formula is an array formula

throws [[NoRelativeAddressesAllowedError]] when the named expression formula contains relative references

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
 ]);
 
@@ -760,7 +776,7 @@
 
 // change the named expression
 const changes = hfInstance.changeNamedExpression('prettyName', '=Sheet1!$A$1+200');
-

Parameters:

Name Type Description
expressionName string an expression name, case-insensitive.
newExpression RawCellContent a new expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope
options? NamedExpressionOptions additional metadata related to named expression

Returns: ExportedChange[]


# getAllNamedExpressionsSerialized

getAllNamedExpressionsSerialized(): SerializedNamedExpression[]

Defined in src/HyperFormula.ts:4030 (opens new window)

Returns all named expressions serialized.

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
expressionName string an expression name, case-insensitive.
newExpression RawCellContent a new expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope
options? NamedExpressionOptions additional metadata related to named expression

Returns: ExportedChange[]


# getAllNamedExpressionsSerialized

getAllNamedExpressionsSerialized(): SerializedNamedExpression[]

Defined in src/HyperFormula.ts:4030 (opens new window)

Returns all named expressions serialized.

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
  ['50'],
  ['60'],
@@ -779,7 +795,7 @@
 // {name: 'alsoPrettyName', expression: '=Sheet1!$A$3+100', options: undefined, scope: 0}
 // ]
 const allExpressions = hfInstance.getAllNamedExpressionsSerialized();
-

Returns: SerializedNamedExpression[]


# getNamedExpression

getNamedExpression(expressionName: string, scope?: undefined | number): NamedExpression | undefined

Defined in src/HyperFormula.ts:3769 (opens new window)

Returns a named expression, or undefined for a named expression that does not exist or does not hold a formula.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
+

Returns: SerializedNamedExpression[]


# getNamedExpression

getNamedExpression(expressionName: string, scope?: undefined | number): NamedExpression | undefined

Defined in src/HyperFormula.ts:3769 (opens new window)

Returns a named expression, or undefined for a named expression that does not exist or does not hold a formula.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
 ]);
 
@@ -793,7 +809,7 @@
 
 // for a named expression that doesn't exist, returns 'undefined':
 const myFormulaTwo = hfInstance.getNamedExpression('uglyName', 0);
-

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: NamedExpression | undefined


# getNamedExpressionFormula

getNamedExpressionFormula(expressionName: string, scope?: undefined | number): string | undefined

Defined in src/HyperFormula.ts:3726 (opens new window)

Returns a normalized formula string for given named expression, or undefined for a named expression that does not exist or does not hold a formula.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: NamedExpression | undefined


# getNamedExpressionFormula

getNamedExpressionFormula(expressionName: string, scope?: undefined | number): string | undefined

Defined in src/HyperFormula.ts:3726 (opens new window)

Returns a normalized formula string for given named expression, or undefined for a named expression that does not exist or does not hold a formula.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
 ]);
 
@@ -803,7 +819,7 @@
 // returns a normalized formula string corresponding to the passed name from 'Sheet1' (sheetId=0),
 // '=Sheet1!A1+100' for this example
 const myFormula = hfInstance.getNamedExpressionFormula('prettyName', 0);
-

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: string | undefined


# getNamedExpressionValue

getNamedExpressionValue(expressionName: string, scope?: undefined | number): CellValue | undefined

Defined in src/HyperFormula.ts:3686 (opens new window)

Gets specified named expression value. +

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: string | undefined


# getNamedExpressionValue

getNamedExpressionValue(expressionName: string, scope?: undefined | number): CellValue | undefined

Defined in src/HyperFormula.ts:3686 (opens new window)

Gets specified named expression value. Returns a [[CellValue]] or undefined if the given named expression does not exist.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
 ]);
@@ -813,7 +829,7 @@
 
 // returns the calculated value of a passed named expression, '142' for this example
 const myFormula = hfInstance.getNamedExpressionValue('prettyName', 'Sheet1');
-

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: CellValue | undefined


# isItPossibleToAddNamedExpression

isItPossibleToAddNamedExpression(expressionName: string, expression: RawCellContent, scope?: undefined | number): boolean

Defined in src/HyperFormula.ts:3598 (opens new window)

Returns information whether it is possible to add named expression into a specific scope. +

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: CellValue | undefined


# isItPossibleToAddNamedExpression

isItPossibleToAddNamedExpression(expressionName: string, expression: RawCellContent, scope?: undefined | number): boolean

Defined in src/HyperFormula.ts:3598 (opens new window)

Returns information whether it is possible to add named expression into a specific scope. Checks against particular rules to ascertain that addNamedExpression can be called. If returns true, doing addNamedExpression operation won't throw any errors. Returns false if the operation might be disrupted.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -823,7 +839,7 @@
 // should return 'true' for this example,
 // it is possible to add named expression to global scope
 const isAddable = hfInstance.isItPossibleToAddNamedExpression('prettyName', '=Sheet1!$A$1+100');
-

Parameters:

Name Type Description
expressionName string a name of the expression to be added
expression RawCellContent the expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: boolean


# isItPossibleToChangeNamedExpression

isItPossibleToChangeNamedExpression(expressionName: string, newExpression: RawCellContent, scope?: undefined | number): boolean

Defined in src/HyperFormula.ts:3818 (opens new window)

Returns information whether it is possible to change named expression in a specific scope. +

Parameters:

Name Type Description
expressionName string a name of the expression to be added
expression RawCellContent the expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: boolean


# isItPossibleToChangeNamedExpression

isItPossibleToChangeNamedExpression(expressionName: string, newExpression: RawCellContent, scope?: undefined | number): boolean

Defined in src/HyperFormula.ts:3818 (opens new window)

Returns information whether it is possible to change named expression in a specific scope. Checks against particular rules to ascertain that changeNamedExpression can be called. If returns true, doing changeNamedExpression operation won't throw any errors. Returns false if the operation might be disrupted.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -836,7 +852,7 @@
 // should return 'true' for this example,
 // it is possible to change named expression
 const isAddable = hfInstance.isItPossibleToChangeNamedExpression('prettyName', '=Sheet1!$A$1+100');
-

Parameters:

Name Type Description
expressionName string an expression name, case-insensitive.
newExpression RawCellContent a new expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: boolean


# isItPossibleToRemoveNamedExpression

isItPossibleToRemoveNamedExpression(expressionName: string, scope?: undefined | number): boolean

Defined in src/HyperFormula.ts:3902 (opens new window)

Returns information whether it is possible to remove named expression from a specific scope. +

Parameters:

Name Type Description
expressionName string an expression name, case-insensitive.
newExpression RawCellContent a new expression
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: boolean


# isItPossibleToRemoveNamedExpression

isItPossibleToRemoveNamedExpression(expressionName: string, scope?: undefined | number): boolean

Defined in src/HyperFormula.ts:3902 (opens new window)

Returns information whether it is possible to remove named expression from a specific scope. Checks against particular rules to ascertain that removeNamedExpression can be called. If returns true, doing removeNamedExpression operation won't throw any errors. Returns false if the operation might be disrupted.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
@@ -849,7 +865,7 @@
 // should return 'true' for this example,
 // it is possible to change named expression
 const isAddable = hfInstance.isItPossibleToRemoveNamedExpression('prettyName');
-

Parameters:

Name Type Description
expressionName string an expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: boolean


# listNamedExpressions

listNamedExpressions(scope?: undefined | number): string[]

Defined in src/HyperFormula.ts:3994 (opens new window)

Lists named expressions.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
expressionName string an expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: boolean


# listNamedExpressions

listNamedExpressions(scope?: undefined | number): string[]

Defined in src/HyperFormula.ts:3994 (opens new window)

Lists named expressions.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
  ['50'],
  ['60'],
@@ -865,7 +881,7 @@
 
  // list the expressions, should return: ['alsoPrettyName'] for this example
 const listOfExpressions = hfInstance.listNamedExpressions(0);
-

Parameters:

Name Type Description
scope? undefined | number scope of the named expressions, sheetId for local scope or undefined for global scope

Returns: string[]


# removeNamedExpression

removeNamedExpression(expressionName: string, scope?: undefined | number): ExportedChange[]

Defined in src/HyperFormula.ts:3947 (opens new window)

Removes a named expression.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires namedExpressionRemoved after the expression was removed

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NamedExpressionDoesNotExistError]] when the given expression does not exist.

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
+

Parameters:

Name Type Description
scope? undefined | number scope of the named expressions, sheetId for local scope or undefined for global scope

Returns: string[]


# removeNamedExpression

removeNamedExpression(expressionName: string, scope?: undefined | number): ExportedChange[]

Defined in src/HyperFormula.ts:3947 (opens new window)

Removes a named expression.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires namedExpressionRemoved after the expression was removed

fires valuesUpdated if recalculation was triggered by this change

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NamedExpressionDoesNotExistError]] when the given expression does not exist.

throws [[NoSheetWithIdError]] if no sheet with given sheetId exists

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
 ]);
 
@@ -874,7 +890,7 @@
 
 // remove the named expression
 const changes = hfInstance.removeNamedExpression('prettyName', 0);
-

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: ExportedChange[]


# Helpers

# calculateFormula

calculateFormula(formulaString: string, sheetId: number): CellValue | CellValue[][]

Defined in src/HyperFormula.ts:4095 (opens new window)

Calculates fire-and-forget formula, returns the calculated value.

throws [[ExpectedValueOfTypeError]] if any of its basic type arguments is of wrong type.

throws [[NotAFormulaError]] when the provided string is not a valid formula (i.e., doesn't start with =).

throws [[NoSheetWithIdError]] when the provided sheetID doesn't exist.

example

const hfInstance = HyperFormula.buildFromSheets({
+

Parameters:

Name Type Description
expressionName string expression name, case-insensitive.
scope? undefined | number scope definition, sheetId for local scope or undefined for global scope

Returns: ExportedChange[]


# Helpers

# calculateFormula

calculateFormula(formulaString: string, sheetId: number): CellValue | CellValue[][]

Defined in src/HyperFormula.ts:4095 (opens new window)

Calculates fire-and-forget formula, returns the calculated value.

throws [[ExpectedValueOfTypeError]] if any of its basic type arguments is of wrong type.

throws [[NotAFormulaError]] when the provided string is not a valid formula (i.e., doesn't start with =).

throws [[NoSheetWithIdError]] when the provided sheetID doesn't exist.

example

const hfInstance = HyperFormula.buildFromSheets({
  Sheet1: [['58']],
  Sheet2: [['1', '2', '3'], ['4', '5', '6']]
 });
@@ -885,15 +901,15 @@
 
 // for this example, returns [['11', '12', '13'], ['14', '15', '16']]
 const calculatedFormula = hfInstance.calculateFormula('=A1:B3+10', 1);
-

Parameters:

Name Type Description
formulaString string A formula in a proper format, starting with =.
sheetId number The ID of a sheet in context of which the formula gets evaluated.

Returns: CellValue | CellValue[][]


# getCellDependents

getCellDependents(address: SimpleCellAddress | SimpleCellRange): (SimpleCellRange | SimpleCellAddress)[]

Defined in src/HyperFormula.ts:2936 (opens new window)

Returns all the out-neighbors in the dependency graph for a given cell address or range. Including:

The exact result depends on the optimizations applied by the HyperFormula to the dependency graph, some of which are described in the section "Optimizations for large ranges".

The returned array includes also named expression dependents. They are represented as cell references with sheet ID -1.

throws [[ExpectedValueOfTypeError]] if address is not [[SimpleCellAddress]] or [[SimpleCellRange]]

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray( [ ['1', '=A1', '=A1+B1'] ] );
+

Parameters:

Name Type Description
formulaString string A formula in a proper format, starting with =.
sheetId number The ID of a sheet in context of which the formula gets evaluated.

Returns: CellValue | CellValue[][]


# getCellDependents

getCellDependents(address: SimpleCellAddress | SimpleCellRange): (SimpleCellRange | SimpleCellAddress)[]

Defined in src/HyperFormula.ts:2936 (opens new window)

Returns all the out-neighbors in the dependency graph for a given cell address or range. Including:

The exact result depends on the optimizations applied by the HyperFormula to the dependency graph, some of which are described in the section "Optimizations for large ranges".

The returned array includes also named expression dependents. They are represented as cell references with sheet ID -1.

throws [[ExpectedValueOfTypeError]] if address is not [[SimpleCellAddress]] or [[SimpleCellRange]]

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray( [ ['1', '=A1', '=A1+B1'] ] );
 
 hfInstance.getCellDependents({ sheet: 0, col: 0, row: 0});
 // returns [{ sheet: 0, col: 1, row: 0}, { sheet: 0, col: 2, row: 0}]
-

Parameters:

Name Type Description
address SimpleCellAddress | SimpleCellRange object representation of an absolute address or range of addresses

Returns: (SimpleCellRange | SimpleCellAddress)[]


# getCellPrecedents

getCellPrecedents(address: SimpleCellAddress | SimpleCellRange): (SimpleCellRange | SimpleCellAddress)[]

Defined in src/HyperFormula.ts:2974 (opens new window)

Returns all the in-neighbors in the dependency graph for a given cell address or range. In particular:

The returned array includes also named expression precedents. They are represented as cell references with sheet ID -1.

throws [[ExpectedValueOfTypeError]] if address is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray( [ ['1', '=A1', '=A1+B1'] ] );
+

Parameters:

Name Type Description
address SimpleCellAddress | SimpleCellRange object representation of an absolute address or range of addresses

Returns: (SimpleCellRange | SimpleCellAddress)[]


# getCellPrecedents

getCellPrecedents(address: SimpleCellAddress | SimpleCellRange): (SimpleCellRange | SimpleCellAddress)[]

Defined in src/HyperFormula.ts:2974 (opens new window)

Returns all the in-neighbors in the dependency graph for a given cell address or range. In particular:

The returned array includes also named expression precedents. They are represented as cell references with sheet ID -1.

throws [[ExpectedValueOfTypeError]] if address is of wrong type

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray( [ ['1', '=A1', '=A1+B1'] ] );
 
 hfInstance.getCellPrecedents({ sheet: 0, col: 2, row: 0});
 // returns [{ sheet: 0, col: 0, row: 0}, { sheet: 0, col: 1, row: 0}]
-

Parameters:

Name Type Description
address SimpleCellAddress | SimpleCellRange object representation of an absolute address or range of addresses

Returns: (SimpleCellRange | SimpleCellAddress)[]


# normalizeFormula

normalizeFormula(formulaString: string): string

Defined in src/HyperFormula.ts:4059 (opens new window)

Parses and then unparses a formula. +

Parameters:

Name Type Description
address SimpleCellAddress | SimpleCellRange object representation of an absolute address or range of addresses

Returns: (SimpleCellRange | SimpleCellAddress)[]


# normalizeFormula

normalizeFormula(formulaString: string): string

Defined in src/HyperFormula.ts:4059 (opens new window)

Parses and then unparses a formula. Returns a normalized formula (e.g., restores the original capitalization of sheet names, function names, cell addresses, and named expressions).

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[NotAFormulaError]] when the provided string is not a valid formula, i.e., does not start with "="

example

const hfInstance = HyperFormula.buildFromArray([
  ['42'],
  ['50'],
@@ -904,25 +920,25 @@
 
 // returns '=3*$A$1'
 const normalizedFormula = hfInstance.normalizeFormula('=3*$a$1');
-

Parameters:

Name Type Description
formulaString string a formula in a proper format - it must start with "="

Returns: string


# numberToDate

numberToDate(inputNumber: number): DateTime

Defined in src/HyperFormula.ts:4247 (opens new window)

Interprets number as a date.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
+

Parameters:

Name Type Description
formulaString string a formula in a proper format - it must start with "="

Returns: string


# numberToDate

numberToDate(inputNumber: number): DateTime

Defined in src/HyperFormula.ts:4247 (opens new window)

Interprets number as a date.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
 
 // pass the number of days since nullDate
 // the method should return formatted date, for this example:
 // {year: 2020, month: 1, day: 15}
 const dateFromNumber = hfInstance.numberToDate(43845);
-

Parameters:

Name Type Description
inputNumber number number of days since nullDate, should be non-negative, fractions are ignored.

Returns: DateTime


# numberToDateTime

numberToDateTime(inputNumber: number): DateTime

Defined in src/HyperFormula.ts:4223 (opens new window)

Interprets number as a date + time.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
+

Parameters:

Name Type Description
inputNumber number number of days since nullDate, should be non-negative, fractions are ignored.

Returns: DateTime


# numberToDateTime

numberToDateTime(inputNumber: number): DateTime

Defined in src/HyperFormula.ts:4223 (opens new window)

Interprets number as a date + time.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
 
 // pass the number of days since nullDate
 // the method should return formatted date and time, for this example:
 // {year: 2020, month: 1, day: 15, hours: 2, minutes: 24, seconds: 0}
 const dateTimeFromNumber = hfInstance.numberToDateTime(43845.1);
 
-

Parameters:

Name Type Description
inputNumber number number of days since nullDate, should be non-negative, fractions are interpreted as hours/minutes/seconds.

Returns: DateTime


# numberToTime

numberToTime(inputNumber: number): DateTime

Defined in src/HyperFormula.ts:4270 (opens new window)

Interprets number as a time (hours/minutes/seconds).

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
+

Parameters:

Name Type Description
inputNumber number number of days since nullDate, should be non-negative, fractions are interpreted as hours/minutes/seconds.

Returns: DateTime


# numberToTime

numberToTime(inputNumber: number): DateTime

Defined in src/HyperFormula.ts:4270 (opens new window)

Interprets number as a time (hours/minutes/seconds).

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
 
 // pass a number to be interpreted as a time
 // should return {hours: 26, minutes: 24} for this example
 const timeFromNumber = hfInstance.numberToTime(1.1);
-

Parameters:

Name Type Description
inputNumber number time in 24h units.

Returns: DateTime


# simpleCellAddressFromString

simpleCellAddressFromString(cellAddress: string, contextSheetId: number): SimpleCellAddress | undefined

Defined in src/HyperFormula.ts:2820 (opens new window)

Computes the simple (absolute) address of a cell address, based on its string representation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
+

Parameters:

Name Type Description
inputNumber number time in 24h units.

Returns: DateTime


# simpleCellAddressFromString

simpleCellAddressFromString(cellAddress: string, contextSheetId: number): SimpleCellAddress | undefined

Defined in src/HyperFormula.ts:2820 (opens new window)

Computes the simple (absolute) address of a cell address, based on its string representation.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
 hfInstance.addSheet('Sheet0'); //sheetId = 0
 
 // returns { sheet: 0, col: 0, row: 0 }
@@ -936,18 +952,18 @@
 
 // returns 'undefined', as there's no 'Sheet 2' in the HyperFormula instance
 const simpleCellAddress = hfInstance.simpleCellAddressFromString('Sheet2!A6');
-

Parameters:

Name Type Description
cellAddress string string representation of cell address in A1 notation
contextSheetId number context used in case of missing sheet in the first argument

Returns: SimpleCellAddress | undefined


# simpleCellAddressToString

simpleCellAddressToString(cellAddress: SimpleCellAddress, sheetId: number): string | undefined

Defined in src/HyperFormula.ts:2872 (opens new window)

Returns string representation of an absolute address in A1 notation or undefined if the sheet index is not present in the engine.

throws [[ExpectedValueOfTypeError]] if its arguments are of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
+

Parameters:

Name Type Description
cellAddress string string representation of cell address in A1 notation
contextSheetId number context used in case of missing sheet in the first argument

Returns: SimpleCellAddress | undefined


# simpleCellAddressToString

simpleCellAddressToString(cellAddress: SimpleCellAddress, sheetId: number): string | undefined

Defined in src/HyperFormula.ts:2872 (opens new window)

Returns string representation of an absolute address in A1 notation or undefined if the sheet index is not present in the engine.

throws [[ExpectedValueOfTypeError]] if its arguments are of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
 hfInstance.addSheet('Sheet0'); //sheetId = 0
 
 // should return 'B2'
 const A1Notation = hfInstance.simpleCellAddressToString({ sheet: 0, col: 1, row: 1 }, 0);
-

Parameters:

Name Type Description
cellAddress SimpleCellAddress object representation of an absolute address
sheetId number context used in case of missing sheet in the first argument

Returns: string | undefined


# simpleCellRangeFromString

simpleCellRangeFromString(cellRange: string, sheetId: number): SimpleCellRange | undefined

Defined in src/HyperFormula.ts:2847 (opens new window)

Computes simple (absolute) address of a cell range based on its string representation. +

Parameters:

Name Type Description
cellAddress SimpleCellAddress object representation of an absolute address
sheetId number context used in case of missing sheet in the first argument

Returns: string | undefined


# simpleCellRangeFromString

simpleCellRangeFromString(cellRange: string, sheetId: number): SimpleCellRange | undefined

Defined in src/HyperFormula.ts:2847 (opens new window)

Computes simple (absolute) address of a cell range based on its string representation. If sheet name is present in string representation but not present in the engine, returns undefined.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
 hfInstance.addSheet('Sheet0'); //sheetId = 0
 
 // should return { start: { sheet: 0, col: 0, row: 0 }, end: { sheet: 0, col: 1, row: 0 } }
 const simpleCellAddress = hfInstance.simpleCellRangeFromString('A1:A2', 0);
-

Parameters:

Name Type Description
cellRange string string representation of cell range in A1 notation
sheetId number context used in case of missing sheet in the first argument

Returns: SimpleCellRange | undefined


# simpleCellRangeToString

simpleCellRangeToString(cellRange: SimpleCellRange, sheetId: number): string | undefined

Defined in src/HyperFormula.ts:2903 (opens new window)

Returns string representation of an absolute range in A1 notation or undefined if the sheet index is not present in the engine.

throws [[ExpectedValueOfTypeError]] if its arguments are of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
+

Parameters:

Name Type Description
cellRange string string representation of cell range in A1 notation
sheetId number context used in case of missing sheet in the first argument

Returns: SimpleCellRange | undefined


# simpleCellRangeToString

simpleCellRangeToString(cellRange: SimpleCellRange, sheetId: number): string | undefined

Defined in src/HyperFormula.ts:2903 (opens new window)

Returns string representation of an absolute range in A1 notation or undefined if the sheet index is not present in the engine.

throws [[ExpectedValueOfTypeError]] if its arguments are of wrong type

example

const hfInstance = HyperFormula.buildEmpty();
 hfInstance.addSheet('Sheet0'); //sheetId = 0
 hfInstance.addSheet('Sheet1'); //sheetId = 1
 
@@ -956,13 +972,13 @@
 
  // should return 'Sheet1!B2:C2'
 const another = hfInstance.simpleCellRangeToString({ start: { sheet: 1, col: 1, row: 1 }, end: { sheet: 1, col: 2, row: 1 } }, 0);
-

Parameters:

Name Type Description
cellRange SimpleCellRange object representation of an absolute range
sheetId number context used in case of missing sheet in the first argument

Returns: string | undefined


# validateFormula

validateFormula(formulaString: string): boolean

Defined in src/HyperFormula.ts:4124 (opens new window)

Validates the formula. +

Parameters:

Name Type Description
cellRange SimpleCellRange object representation of an absolute range
sheetId number context used in case of missing sheet in the first argument

Returns: string | undefined


# validateFormula

validateFormula(formulaString: string): boolean

Defined in src/HyperFormula.ts:4124 (opens new window)

Validates the formula. If the provided string starts with "=" and is a parsable formula, the method returns true. The validation is purely grammatical: the method doesn't verify if the formula can be calculated or not.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// checks if the given string is a valid formula, should return 'true' for this example
 const isFormula = hfInstance.validateFormula('=SUM(1, 2)');
-

Parameters:

Name Type Description
formulaString string a formula in a proper format - it must start with "="

Returns: boolean


# Clipboard

# clearClipboard

clearClipboard(): void

Defined in src/HyperFormula.ts:2302 (opens new window)

Clears the clipboard content.

example

// clears the clipboard, isClipboardEmpty() should return true if called afterwards
+

Parameters:

Name Type Description
formulaString string a formula in a proper format - it must start with "="

Returns: boolean


# Clipboard

# clearClipboard

clearClipboard(): void

Defined in src/HyperFormula.ts:2302 (opens new window)

Clears the clipboard content.

example

// clears the clipboard, isClipboardEmpty() should return true if called afterwards
 hfInstance.clearClipboard();
-

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Returns: void


# copy

copy(source: SimpleCellRange): CellValue[][]

Defined in src/HyperFormula.ts:2166 (opens new window)

Stores a copy of the cell block in internal clipboard for the further paste. +

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Returns: void


# copy

copy(source: SimpleCellRange): CellValue[][]

Defined in src/HyperFormula.ts:2166 (opens new window)

Stores a copy of the cell block in internal clipboard for the further paste. Returns the copied values for use in external clipboard.

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

example

const hfInstance = HyperFormula.buildFromArray([
   ['1', '2'],
 ]);
@@ -972,7 +988,7 @@
   start: { sheet: 0, col: 1, row: 0 },
   end: { sheet: 0, col: 1, row: 0 },
 });
-

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Parameters:

Name Type Description
source SimpleCellRange rectangle range to copy

Returns: CellValue[][]


# cut

cut(source: SimpleCellRange): CellValue[][]

Defined in src/HyperFormula.ts:2204 (opens new window)

Stores information of the cell block in internal clipboard for further paste. +

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Parameters:

Name Type Description
source SimpleCellRange rectangle range to copy

Returns: CellValue[][]


# cut

cut(source: SimpleCellRange): CellValue[][]

Defined in src/HyperFormula.ts:2204 (opens new window)

Stores information of the cell block in internal clipboard for further paste. Calling paste right after this method is equivalent to call moveCells. Almost any CRUD operation called after this method will abort the cut operation. Returns the cut values for use in external clipboard.

throws [[ExpectedValueOfTypeError]] if source is of wrong type

throws [[SheetsNotEqual]] if range provided has distinct sheet numbers for start and end

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

example

const hfInstance = HyperFormula.buildFromArray([
@@ -984,7 +1000,7 @@
   start: { sheet: 0, col: 0, row: 0 },
   end: { sheet: 0, col: 0, row: 0 },
 });
-

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Parameters:

Name Type Description
source SimpleCellRange rectangle range to cut

Returns: CellValue[][]


# isClipboardEmpty

isClipboardEmpty(): boolean

Defined in src/HyperFormula.ts:2285 (opens new window)

Returns information whether there is something in the clipboard.

example

const hfInstance = HyperFormula.buildFromArray([
+

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Parameters:

Name Type Description
source SimpleCellRange rectangle range to cut

Returns: CellValue[][]


# isClipboardEmpty

isClipboardEmpty(): boolean

Defined in src/HyperFormula.ts:2285 (opens new window)

Returns information whether there is something in the clipboard.

example

const hfInstance = HyperFormula.buildFromArray([
  ['1', '2'],
 ]);
 
@@ -996,7 +1012,7 @@
 
 // returns 'false', there is content in the clipboard
 const isClipboardEmpty = hfInstance.isClipboardEmpty();
-

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Returns: boolean


# paste

paste(targetLeftCorner: SimpleCellAddress): ExportedChange[]

Defined in src/HyperFormula.ts:2253 (opens new window)

When called after copy it pastes copied values and formulas into a cell block. +

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Returns: boolean


# paste

paste(targetLeftCorner: SimpleCellAddress): ExportedChange[]

Defined in src/HyperFormula.ts:2253 (opens new window)

When called after copy it pastes copied values and formulas into a cell block. When called after cut it performs moveCells operation into the cell block. Does nothing if the clipboard is empty.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoSheetWithIdError]] when the given sheet ID does not exist

throws [[EvaluationSuspendedError]] when the evaluation is suspended

throws [[SheetSizeLimitExceededError]] when performing this operation would result in sheet size limits exceeding

throws [[NothingToPasteError]] when clipboard is empty

throws [[TargetLocationHasArrayError]] when the selected target area has array inside

throws [[ExpectedValueOfTypeError]] if targetLeftCorner is of wrong type

example

const hfInstance = HyperFormula.buildFromArray([
   ['1', '2'],
@@ -1010,7 +1026,7 @@
 
 // returns a list of modified cells: their absolute addresses and new values
 const changes = hfInstance.paste({ sheet: 0, col: 1, row: 0 });
-

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Parameters:

Name Type Description
targetLeftCorner SimpleCellAddress upper left address of the target cell block

Returns: ExportedChange[]


# Undo and Redo

# clearRedoStack

clearRedoStack(): void

Defined in src/HyperFormula.ts:2330 (opens new window)

Clears the redo stack in undoRedo history.

example

const hfInstance = HyperFormula.buildFromArray([
+

The usage of the internal clipboard is described thoroughly in the Clipboard Operations guide.

Parameters:

Name Type Description
targetLeftCorner SimpleCellAddress upper left address of the target cell block

Returns: ExportedChange[]


# Undo and Redo

# clearRedoStack

clearRedoStack(): void

Defined in src/HyperFormula.ts:2330 (opens new window)

Clears the redo stack in undoRedo history.

example

const hfInstance = HyperFormula.buildFromArray([
   ['1', '2', '3'],
 ]);
 
@@ -1025,7 +1041,7 @@
 
 // clear the redo stack
 hfInstance.clearRedoStack();
-

Returns: void


# clearUndoStack

clearUndoStack(): void

Defined in src/HyperFormula.ts:2355 (opens new window)

Clears the undo stack in undoRedo history.

example

const hfInstance = HyperFormula.buildFromArray([
+

Returns: void


# clearUndoStack

clearUndoStack(): void

Defined in src/HyperFormula.ts:2355 (opens new window)

Clears the undo stack in undoRedo history.

example

const hfInstance = HyperFormula.buildFromArray([
   ['1', '2', '3'],
 ]);
 
@@ -1037,11 +1053,11 @@
 
 // clear the undo stack
 hfInstance.clearUndoStack();
-

Returns: void


# isThereSomethingToRedo

isThereSomethingToRedo(): boolean

Defined in src/HyperFormula.ts:1154 (opens new window)

Checks if there is at least one operation that can be re-done.

example

hfInstance.undo();
+

Returns: void


# isThereSomethingToRedo

isThereSomethingToRedo(): boolean

Defined in src/HyperFormula.ts:1154 (opens new window)

Checks if there is at least one operation that can be re-done.

example

hfInstance.undo();
 
 // when there is an action to redo, this returns 'true'
 const isSomethingToRedo = hfInstance.isThereSomethingToRedo();
-

Returns: boolean


# isThereSomethingToUndo

isThereSomethingToUndo(): boolean

Defined in src/HyperFormula.ts:1137 (opens new window)

Checks if there is at least one operation that can be undone.

example

const hfInstance = HyperFormula.buildFromArray([
+

Returns: boolean


# isThereSomethingToUndo

isThereSomethingToUndo(): boolean

Defined in src/HyperFormula.ts:1137 (opens new window)

Checks if there is at least one operation that can be undone.

example

const hfInstance = HyperFormula.buildFromArray([
  ['1'],
  ['2'],
  ['3'],
@@ -1053,7 +1069,7 @@
 // should return 'true', it is possible to undo last operation
 // which is removing rows in this example
 const isSomethingToUndo = hfInstance.isThereSomethingToUndo();
-

Returns: boolean


# redo

redo(): ExportedChange[]

Defined in src/HyperFormula.ts:1111 (opens new window)

Re-do recently undone operation.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoOperationToRedoError]] when there is no operation running that can be re-done

example

const hfInstance = HyperFormula.buildFromArray([
+

Returns: boolean


# redo

redo(): ExportedChange[]

Defined in src/HyperFormula.ts:1111 (opens new window)

Re-do recently undone operation.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoOperationToRedoError]] when there is no operation running that can be re-done

example

const hfInstance = HyperFormula.buildFromArray([
  ['1'],
  ['2'],
  ['3'],
@@ -1067,7 +1083,7 @@
 
 // do a redo, it should return the values after removing the second row: [['1'], ['3']]
 const changes = hfInstance.redo();
-

Returns: ExportedChange[]


# undo

undo(): ExportedChange[]

Defined in src/HyperFormula.ts:1075 (opens new window)

Undo the previous operation.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoOperationToUndoError]] when there is no operation running that can be undone

example

const hfInstance = HyperFormula.buildFromArray([
+

Returns: ExportedChange[]


# undo

undo(): ExportedChange[]

Defined in src/HyperFormula.ts:1075 (opens new window)

Undo the previous operation.

Returns an array of cells whose values changed as a result of this operation.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

throws [[NoOperationToUndoError]] when there is no operation running that can be undone

example

const hfInstance = HyperFormula.buildFromArray([
  ['1', '2'],
  ['3', ''],
 ]);
@@ -1077,7 +1093,7 @@
 
 // undo the operation, it should return the changes
 const changes = hfInstance.undo();
-

Returns: ExportedChange[]


# Batch

# batch

batch(batchOperations: function): ExportedChange[]

Defined in src/HyperFormula.ts:3460 (opens new window)

Runs the provided callback as a single batch operation and returns the changed cells.

Returns an array of cells whose values changed as a result of all batched operations.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

fires evaluationSuspended always

fires evaluationResumed after the recomputation of necessary values

example

const hfInstance = HyperFormula.buildFromSheets({
+

Returns: ExportedChange[]


# Batch

# batch

batch(batchOperations: function): ExportedChange[]

Defined in src/HyperFormula.ts:3460 (opens new window)

Runs the provided callback as a single batch operation and returns the changed cells.

Returns an array of cells whose values changed as a result of all batched operations.

Note that this method may trigger dependency graph recalculation.

fires valuesUpdated if recalculation was triggered by this change

fires evaluationSuspended always

fires evaluationResumed after the recomputation of necessary values

example

const hfInstance = HyperFormula.buildFromSheets({
  MySheet1: [ ['1'] ],
  MySheet2: [ ['10'] ],
 });
@@ -1089,7 +1105,7 @@
  hfInstance.setCellContents({ col: 3, row: 0, sheet: 0 }, [['=B1']]);
  hfInstance.setCellContents({ col: 4, row: 0, sheet: 0 }, [['=A1']]);
 });
-

Parameters:

batchOperations: function

a function with operations to be performed

▸ (): void

Returns: ExportedChange[]


# isEvaluationSuspended

isEvaluationSuspended(): boolean

Defined in src/HyperFormula.ts:3569 (opens new window)

Checks if the dependency graph recalculation process is suspended or not.

example

const hfInstance = HyperFormula.buildEmpty();
+

Parameters:

batchOperations: function

a function with operations to be performed

▸ (): void

Returns: ExportedChange[]


# isEvaluationSuspended

isEvaluationSuspended(): boolean

Defined in src/HyperFormula.ts:3569 (opens new window)

Checks if the dependency graph recalculation process is suspended or not.

example

const hfInstance = HyperFormula.buildEmpty();
 
 // suspend the evaluation
 hfInstance.suspendEvaluation();
@@ -1099,7 +1115,7 @@
 const isEvaluationSuspended = hfInstance.isEvaluationSuspended();
 
 const changes = hfInstance.resumeEvaluation();
-

Returns: boolean


# resumeEvaluation

resumeEvaluation(): ExportedChange[]

Defined in src/HyperFormula.ts:3543 (opens new window)

Resumes the dependency graph recalculation that was suspended with suspendEvaluation. +

Returns: boolean


# resumeEvaluation

resumeEvaluation(): ExportedChange[]

Defined in src/HyperFormula.ts:3543 (opens new window)

Resumes the dependency graph recalculation that was suspended with suspendEvaluation. It also triggers the recalculation and returns an array of cells whose values changed as a result of all batched operations.

fires valuesUpdated if recalculation was triggered by this change

fires evaluationResumed after the recomputation of necessary values

example

const hfInstance = HyperFormula.buildFromSheets({
  MySheet1: [ ['1'] ],
  MySheet2: [ ['10'] ],
@@ -1118,7 +1134,7 @@
 
 // resume the evaluation
 const changes = hfInstance.resumeEvaluation();
-

Returns: ExportedChange[]


# suspendEvaluation

suspendEvaluation(): void

Defined in src/HyperFormula.ts:3507 (opens new window)

Suspends the dependency graph recalculation to start a batch operation. +

Returns: ExportedChange[]


# suspendEvaluation

suspendEvaluation(): void

Defined in src/HyperFormula.ts:3507 (opens new window)

Suspends the dependency graph recalculation to start a batch operation. It allows optimizing the performance. With this method, multiple CRUD operations can be done without triggering recalculation after every operation. Suspending evaluation should result in an overall faster calculation compared to recalculating after each operation separately. @@ -1140,7 +1156,7 @@ // use resumeEvaluation to resume const changes = hfInstance.resumeEvaluation(); -

Returns: void


# Events

# off

offEvent›(event: Event, listener: Listeners[Event]): void

Defined in src/HyperFormula.ts:4356 (opens new window)

Unsubscribes from an event or from all events. +

Returns: void


# Events

# off

offEvent›(event: Event, listener: Listeners[Event]): void

Defined in src/HyperFormula.ts:4356 (opens new window)

Unsubscribes from an event or from all events. For the list of all available events, see Listeners.

example

const hfInstance = HyperFormula.buildEmpty();
 
 // define a simple function to be called upon emitting an event
@@ -1158,7 +1174,7 @@
 
 // add a sheet, the console should not print anything
 hfInstance.addSheet('FooBaz');
-

Type parameters:

Event: keyof Listeners

Parameters:

Name Type Description
event Event the name of the event to subscribe to
listener Listeners[Event] to be called when event is emitted

Returns: void


# on

onEvent›(event: Event, listener: Listeners[Event]): void

Defined in src/HyperFormula.ts:4296 (opens new window)

Subscribes to an event. +

Type parameters:

Event: keyof Listeners

Parameters:

Name Type Description
event Event the name of the event to subscribe to
listener Listeners[Event] to be called when event is emitted

Returns: void


# on

onEvent›(event: Event, listener: Listeners[Event]): void

Defined in src/HyperFormula.ts:4296 (opens new window)

Subscribes to an event. For the list of all available events, see Listeners.

example

const hfInstance = HyperFormula.buildEmpty();
 
 // subscribe to a 'sheetAdded', pass a simple handler
@@ -1167,7 +1183,7 @@
 // add a sheet to trigger an event,
 // console should print 'foo' after each time sheet is added in this example
 hfInstance.addSheet('FooBar');
-

Type parameters:

Event: keyof Listeners

Parameters:

Name Type Description
event Event the name of the event to subscribe to
listener Listeners[Event] to be called when event is emitted

Returns: void


# once

onceEvent›(event: Event, listener: Listeners[Event]): void

Defined in src/HyperFormula.ts:4322 (opens new window)

Subscribes to an event once. +

Type parameters:

Event: keyof Listeners

Parameters:

Name Type Description
event Event the name of the event to subscribe to
listener Listeners[Event] to be called when event is emitted

Returns: void


# once

onceEvent›(event: Event, listener: Listeners[Event]): void

Defined in src/HyperFormula.ts:4322 (opens new window)

Subscribes to an event once. For the list of all available events, see Listeners.

example

const hfInstance = HyperFormula.buildEmpty();
 
 // subscribe to a 'sheetAdded', pass a simple handler
@@ -1177,11 +1193,11 @@
 // console should print 'foo' only once when the sheet is added in this example
 hfInstance.addSheet('FooBar');
 hfInstance.addSheet('FooBaz');
-

Type parameters:

Event: keyof Listeners

Parameters:

Name Type Description
event Event the name of the event to subscribe to
listener Listeners[Event] to be called when event is emitted

Returns: void


# Custom Functions

# getAllFunctionPlugins

getAllFunctionPlugins(): FunctionPluginDefinition[]

Defined in src/HyperFormula.ts:4199 (opens new window)

Returns classes of all plugins registered in this instance of HyperFormula

example

const hfInstance = HyperFormula.buildEmpty();
+

Type parameters:

Event: keyof Listeners

Parameters:

Name Type Description
event Event the name of the event to subscribe to
listener Listeners[Event] to be called when event is emitted

Returns: void


# Custom Functions

# getAllFunctionPlugins

getAllFunctionPlugins(): FunctionPluginDefinition[]

Defined in src/HyperFormula.ts:4199 (opens new window)

Returns classes of all plugins registered in this instance of HyperFormula

example

const hfInstance = HyperFormula.buildEmpty();
 
 // return classes of all plugins registered, assign to a variable
 const allNames = hfInstance.getAllFunctionPlugins();
-

Returns: FunctionPluginDefinition[]


# getFunctionPlugin

getFunctionPlugin(functionId: string): FunctionPluginDefinition | undefined

Defined in src/HyperFormula.ts:4181 (opens new window)

Returns class of a plugin used by function with given id

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// import your own plugin
+

Returns: FunctionPluginDefinition[]


# getFunctionPlugin

getFunctionPlugin(functionId: string): FunctionPluginDefinition | undefined

Defined in src/HyperFormula.ts:4181 (opens new window)

Returns class of a plugin used by function with given id

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// import your own plugin
 import { MyExamplePlugin } from './file_with_your_plugin';
 
 const hfInstance = HyperFormula.buildEmpty();
@@ -1191,14 +1207,14 @@
 
 // get the plugin
 const myPlugin = hfInstance.getFunctionPlugin('EXAMPLE');
-

Parameters:

Name Type Description
functionId string id of a function, e.g., 'SUMIF'

Returns: FunctionPluginDefinition | undefined


# getRegisteredFunctionNames

getRegisteredFunctionNames(): string[]

Defined in src/HyperFormula.ts:4153 (opens new window)

Returns translated names of all functions registered in this instance of HyperFormula +

Parameters:

Name Type Description
functionId string id of a function, e.g., 'SUMIF'

Returns: FunctionPluginDefinition | undefined


# getRegisteredFunctionNames

getRegisteredFunctionNames(): string[]

Defined in src/HyperFormula.ts:4153 (opens new window)

Returns translated names of all functions registered in this instance of HyperFormula according to the language set in the configuration

example

const hfInstance = HyperFormula.buildEmpty();
 
 // return translated names of all functions, assign to a variable
 const allNames = hfInstance.getRegisteredFunctionNames();
-

Returns: string[]


# Static Methods

# getAllFunctionPlugins Static

getAllFunctionPlugins(): FunctionPluginDefinition[]

Defined in src/HyperFormula.ts:612 (opens new window)

Returns classes of all plugins registered in HyperFormula.

example

// return classes of all plugins
+

Returns: string[]


# Static Methods

# getAllFunctionPlugins Static

getAllFunctionPlugins(): FunctionPluginDefinition[]

Defined in src/HyperFormula.ts:612 (opens new window)

Returns classes of all plugins registered in HyperFormula.

example

// return classes of all plugins
 const allClasses = HyperFormula.getAllFunctionPlugins();
-

Returns: FunctionPluginDefinition[]


# getFunctionPlugin Static

getFunctionPlugin(functionId: string): FunctionPluginDefinition | undefined

Defined in src/HyperFormula.ts:596 (opens new window)

Returns class of a plugin used by function with given id

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// import your own plugin
+

Returns: FunctionPluginDefinition[]


# getFunctionPlugin Static

getFunctionPlugin(functionId: string): FunctionPluginDefinition | undefined

Defined in src/HyperFormula.ts:596 (opens new window)

Returns class of a plugin used by function with given id

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// import your own plugin
 import { MyExamplePlugin } from './file_with_your_plugin';
 
 // register a plugin
@@ -1206,29 +1222,29 @@
 
 // return the class of a given plugin
 const myFunctionClass = HyperFormula.getFunctionPlugin('EXAMPLE');
-

Parameters:

Name Type Description
functionId string id of a function, e.g., 'SUMIF'

Returns: FunctionPluginDefinition | undefined


# getLanguage Static

getLanguage(languageCode: string): TranslationPackage

Defined in src/HyperFormula.ts:347 (opens new window)

Returns registered language from its code string.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[LanguageNotRegisteredError]] when trying to retrieve not registered language

example

// return registered language
+

Parameters:

Name Type Description
functionId string id of a function, e.g., 'SUMIF'

Returns: FunctionPluginDefinition | undefined


# getLanguage Static

getLanguage(languageCode: string): TranslationPackage

Defined in src/HyperFormula.ts:347 (opens new window)

Returns registered language from its code string.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[LanguageNotRegisteredError]] when trying to retrieve not registered language

example

// return registered language
 const language = HyperFormula.getLanguage('enGB');
-

Parameters:

Name Type Description
languageCode string code string of the translation package

Returns: TranslationPackage


# getRegisteredFunctionNames Static

getRegisteredFunctionNames(code: string): string[]

Defined in src/HyperFormula.ts:568 (opens new window)

Returns translated names of all registered functions for a given language

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// return a list of function names registered for enGB
+

Parameters:

Name Type Description
languageCode string code string of the translation package

Returns: TranslationPackage


# getRegisteredFunctionNames Static

getRegisteredFunctionNames(code: string): string[]

Defined in src/HyperFormula.ts:568 (opens new window)

Returns translated names of all registered functions for a given language

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// return a list of function names registered for enGB
 const allNames = HyperFormula.getRegisteredFunctionNames('enGB');
-

Parameters:

Name Type Description
code string language code

Returns: string[]


# getRegisteredLanguagesCodes Static

getRegisteredLanguagesCodes(): string[]

Defined in src/HyperFormula.ts:426 (opens new window)

Returns all registered languages codes.

example

// should return all registered language codes: ['enGB', 'plPL']
+

Parameters:

Name Type Description
code string language code

Returns: string[]


# getRegisteredLanguagesCodes Static

getRegisteredLanguagesCodes(): string[]

Defined in src/HyperFormula.ts:426 (opens new window)

Returns all registered languages codes.

example

// should return all registered language codes: ['enGB', 'plPL']
 const registeredLanguages = HyperFormula.getRegisteredLanguagesCodes();
-

Returns: string[]


# registerFunction Static

registerFunction(functionId: string, plugin: FunctionPluginDefinition, translations?: FunctionTranslationsPackage): void

Defined in src/HyperFormula.ts:504 (opens new window)

Registers a function with a given id if such exists in a plugin.

Note: This method does not affect the existing HyperFormula instances.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[FunctionPluginValidationError]] when function with a given id does not exist in plugin or plugin class definition is not consistent with metadata

throws [[ProtectedFunctionTranslationError]] when trying to register translation for protected function

example

// import your own plugin
+

Returns: string[]


# registerFunction Static

registerFunction(functionId: string, plugin: FunctionPluginDefinition, translations?: FunctionTranslationsPackage): void

Defined in src/HyperFormula.ts:504 (opens new window)

Registers a function with a given id if such exists in a plugin.

Note: This method does not affect the existing HyperFormula instances.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[FunctionPluginValidationError]] when function with a given id does not exist in plugin or plugin class definition is not consistent with metadata

throws [[ProtectedFunctionTranslationError]] when trying to register translation for protected function

example

// import your own plugin
 import { MyExamplePlugin } from './file_with_your_plugin';
 
 // register a function
 HyperFormula.registerFunction('EXAMPLE', MyExamplePlugin);
-

Parameters:

Name Type Description
functionId string function id, e.g., 'SUMIF'
plugin FunctionPluginDefinition plugin class
translations? FunctionTranslationsPackage translations for the function name

Returns: void


# registerFunctionPlugin Static

registerFunctionPlugin(plugin: FunctionPluginDefinition, translations?: FunctionTranslationsPackage): void

Defined in src/HyperFormula.ts:454 (opens new window)

Registers all functions in a given plugin with optional translations.

Note: FunctionPlugins must be registered prior to the creation of HyperFormula instances in which they are used. +

Parameters:

Name Type Description
functionId string function id, e.g., 'SUMIF'
plugin FunctionPluginDefinition plugin class
translations? FunctionTranslationsPackage translations for the function name

Returns: void


# registerFunctionPlugin Static

registerFunctionPlugin(plugin: FunctionPluginDefinition, translations?: FunctionTranslationsPackage): void

Defined in src/HyperFormula.ts:454 (opens new window)

Registers all functions in a given plugin with optional translations.

Note: FunctionPlugins must be registered prior to the creation of HyperFormula instances in which they are used. HyperFormula instances created prior to the registration of a FunctionPlugin are unable to access the FunctionPlugin. Registering a FunctionPlugin with [[custom-functions]] requires the translations parameter.

throws [[FunctionPluginValidationError]] when plugin class definition is not consistent with metadata

throws [[ProtectedFunctionTranslationError]] when trying to register translation for protected function

example

// import your own plugin
 import { MyExamplePlugin } from './file_with_your_plugin';
 
 // register the plugin
 HyperFormula.registerFunctionPlugin(MyExamplePlugin);
-

Parameters:

Name Type Description
plugin FunctionPluginDefinition plugin class
translations? FunctionTranslationsPackage optional package of function names translations

Returns: void


# registerLanguage Static

registerLanguage(languageCode: string, languagePackage: RawTranslationPackage): void

Defined in src/HyperFormula.ts:378 (opens new window)

Registers language under given code string.

For more information, see the Localizing functions guide.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[ProtectedFunctionTranslationError]] when trying to register translation for protected function

throws [[LanguageAlreadyRegisteredError]] when given language is already registered

example

// return registered language
+

Parameters:

Name Type Description
plugin FunctionPluginDefinition plugin class
translations? FunctionTranslationsPackage optional package of function names translations

Returns: void


# registerLanguage Static

registerLanguage(languageCode: string, languagePackage: RawTranslationPackage): void

Defined in src/HyperFormula.ts:378 (opens new window)

Registers language under given code string.

For more information, see the Localizing functions guide.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[ProtectedFunctionTranslationError]] when trying to register translation for protected function

throws [[LanguageAlreadyRegisteredError]] when given language is already registered

example

// return registered language
 HyperFormula.registerLanguage('enUS', enUS);
 const engine = HyperFormula.buildEmpty({language: 'enUS'});
-

Parameters:

Name Type Description
languageCode string code string of the translation package
languagePackage RawTranslationPackage translation package to be registered

Returns: void


# unregisterAllFunctions Static

unregisterAllFunctions(): void

Defined in src/HyperFormula.ts:549 (opens new window)

Clears function registry.

Note: This method does not affect the existing HyperFormula instances.

example

HyperFormula.unregisterAllFunctions();
-

Returns: void


# unregisterFunction Static

unregisterFunction(functionId: string): void

Defined in src/HyperFormula.ts:532 (opens new window)

Unregisters a function with a given id.

Note: This method does not affect the existing HyperFormula instances.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// import your own plugin
+

Parameters:

Name Type Description
languageCode string code string of the translation package
languagePackage RawTranslationPackage translation package to be registered

Returns: void


# unregisterAllFunctions Static

unregisterAllFunctions(): void

Defined in src/HyperFormula.ts:549 (opens new window)

Clears function registry.

Note: This method does not affect the existing HyperFormula instances.

example

HyperFormula.unregisterAllFunctions();
+

Returns: void


# unregisterFunction Static

unregisterFunction(functionId: string): void

Defined in src/HyperFormula.ts:532 (opens new window)

Unregisters a function with a given id.

Note: This method does not affect the existing HyperFormula instances.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

example

// import your own plugin
 import { MyExamplePlugin } from './file_with_your_plugin';
 
 // register a function
@@ -1236,12 +1252,12 @@
 
 // unregister a function
 HyperFormula.unregisterFunction('EXAMPLE');
-

Parameters:

Name Type Description
functionId string function id, e.g., 'SUMIF'

Returns: void


# unregisterFunctionPlugin Static

unregisterFunctionPlugin(plugin: FunctionPluginDefinition): void

Defined in src/HyperFormula.ts:476 (opens new window)

Unregisters all functions defined in given plugin.

Note: This method does not affect the existing HyperFormula instances.

example

// get the class of a plugin
+

Parameters:

Name Type Description
functionId string function id, e.g., 'SUMIF'

Returns: void


# unregisterFunctionPlugin Static

unregisterFunctionPlugin(plugin: FunctionPluginDefinition): void

Defined in src/HyperFormula.ts:476 (opens new window)

Unregisters all functions defined in given plugin.

Note: This method does not affect the existing HyperFormula instances.

example

// get the class of a plugin
 const registeredPluginClass = HyperFormula.getFunctionPlugin('EXAMPLE');
 
 // unregister all functions defined in a plugin of ID 'EXAMPLE'
 HyperFormula.unregisterFunctionPlugin(registeredPluginClass);
-

Parameters:

Name Type Description
plugin FunctionPluginDefinition plugin class

Returns: void


# unregisterLanguage Static

unregisterLanguage(languageCode: string): void

Defined in src/HyperFormula.ts:406 (opens new window)

Unregisters language that is registered under given code string.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[LanguageNotRegisteredError]] when given language is not registered

example

// register the language for the instance
+

Parameters:

Name Type Description
plugin FunctionPluginDefinition plugin class

Returns: void


# unregisterLanguage Static

unregisterLanguage(languageCode: string): void

Defined in src/HyperFormula.ts:406 (opens new window)

Unregisters language that is registered under given code string.

throws [[ExpectedValueOfTypeError]] if any of its basic type argument is of wrong type

throws [[LanguageNotRegisteredError]] when given language is not registered

example

// register the language for the instance
 HyperFormula.registerLanguage('plPL', plPL);
 
 // unregister plPL
@@ -1255,6 +1271,6 @@
       
       →
     

- + \ No newline at end of file diff --git a/api/enums/events.html b/api/enums/events.html index c1c3301b3..0595805c1 100644 --- a/api/enums/events.html +++ b/api/enums/events.html @@ -3,7 +3,7 @@ - Events | HyperFormula (v2.6.1) + Events | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
+ \ No newline at end of file diff --git a/api/globals.html b/api/globals.html index 6d2bc57a0..101cd23f4 100644 --- a/api/globals.html +++ b/api/globals.html @@ -3,7 +3,7 @@ - HyperFormula API reference | HyperFormula (v2.6.1) + HyperFormula API reference | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
+ \ No newline at end of file diff --git a/api/index.html b/api/index.html index b4aef06d1..ea8f33930 100644 --- a/api/index.html +++ b/api/index.html @@ -3,7 +3,7 @@ - HyperFormula API reference | HyperFormula (v2.6.1) + HyperFormula API reference | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
- + \ No newline at end of file diff --git a/api/interfaces/configparams.html b/api/interfaces/configparams.html index c9b933f51..3e02f4742 100644 --- a/api/interfaces/configparams.html +++ b/api/interfaces/configparams.html @@ -3,7 +3,7 @@ - ConfigParams | HyperFormula (v2.6.1) + ConfigParams | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
- + \ No newline at end of file diff --git a/api/interfaces/listeners.html b/api/interfaces/listeners.html index dfee41caf..05002e4e9 100644 --- a/api/interfaces/listeners.html +++ b/api/interfaces/listeners.html @@ -3,7 +3,7 @@ - Listeners | HyperFormula (v2.6.1) + Listeners | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
- + \ No newline at end of file diff --git a/api/interfaces/typedemitter.html b/api/interfaces/typedemitter.html index 7ad077efc..07fde90d4 100644 --- a/api/interfaces/typedemitter.html +++ b/api/interfaces/typedemitter.html @@ -3,7 +3,7 @@ - TypedEmitter | HyperFormula (v2.6.1) + TypedEmitter | HyperFormula (v2.6.2) + + @@ -19,14 +35,14 @@ - + -
+ \ No newline at end of file diff --git a/assets/js/1.8e49a3ce.js b/assets/js/1.47b64d8b.js similarity index 98% rename from assets/js/1.8e49a3ce.js rename to assets/js/1.47b64d8b.js index 130f511ea..381ab2d9e 100644 --- a/assets/js/1.8e49a3ce.js +++ b/assets/js/1.47b64d8b.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[1,3,13,16,21,22,24],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return r})),n.d(e,"i",(function(){return a})),n.d(e,"f",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"b",(function(){return p})),n.d(e,"e",(function(){return h})),n.d(e,"k",(function(){return d})),n.d(e,"l",(function(){return f})),n.d(e,"c",(function(){return m})),n.d(e,"j",(function(){return g}));n(90);const i=/#.*$/,s=/\.(md|html)$/,r=/\/$/,a=/^[a-z]+:/i;function o(t){return decodeURI(t).replace(i,"").replace(s,"")}function l(t){return a.test(t)}function u(t){return/^mailto:/.test(t)}function c(t){return/^tel:/.test(t)}function p(t){if(l(t))return t;const e=t.match(i),n=e?e[0]:"",s=o(t);return r.test(s)?t:s+".html"+n}function h(t,e){const n=decodeURIComponent(t.hash),s=function(t){const e=t.match(i);if(e)return e[0]}(e);if(s&&n!==s)return!1;return o(t.path)===o(e)}function d(t,e,n){if(l(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const s=e.split("/");n&&s[s.length-1]||s.pop();const r=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,s=1){if("string"==typeof e)return d(n,e,i);if(Array.isArray(e))return Object.assign(d(n,e[0],i),{title:e[1]});{const r=e.children||[];return 0===r.length&&e.path?Object.assign(d(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:r.map(e=>t(e,n,i,s+1)),collapsable:!1!==e.collapsable}}}(t,s,n)):[]}return[]}function b(t){const e=m(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function m(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function g(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),s={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},r=n(14),a=Object(r.a)(s,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=a.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},s=(n(242),n(14)),r=Object(s.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=r.exports},246:function(t,e,n){},250:function(t,e,n){},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),s=n(244),r=n(91),a=n.n(r),o={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:s.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>a()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(o,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports},254:function(t,e,n){"use strict";n(246)},262:function(t,e,n){},263:function(t,e,n){"use strict";n(250)},264:function(t,e,n){"use strict";n.r(e);var i=n(252),s=n(239),r={name:"NavLinks",components:{NavLink:n(241).default,DropdownLink:i.default},computed:{userNav(){return this.$themeLocaleConfig.nav||this.$site.themeConfig.nav||[]},nav(){const{locales:t}=this.$site;if(t&&Object.keys(t).length>1){const e=this.$page.path,n=this.$router.options.routes,i=this.$site.themeConfig.locales||{},s={text:this.$themeLocaleConfig.selectText||"Languages",ariaLabel:this.$themeLocaleConfig.ariaLabel||"Select language",items:Object.keys(t).map(s=>{const r=t[s],a=i[s]&&i[s].label||r.lang;let o;return r.lang===this.$lang?o=e:(o=e.replace(this.$localeConfig.path,s),n.some(t=>t.path===o)||(o=s)),{text:a,link:o}})};return[...this.userNav,s]}return this.userNav},userLinks(){return(this.nav||[]).map(t=>Object.assign(Object(s.j)(t),{items:(t.items||[]).map(s.j)}))},repoLink(){const{repo:t}=this.$site.themeConfig;return t?/^https?:/.test(t)?t:"https://github.com/"+t:null},repoLabel(){if(!this.repoLink)return;if(this.$site.themeConfig.repoLabel)return this.$site.themeConfig.repoLabel;const t=this.repoLink.match(/^https?:\/\/[^/]+/)[0],e=["GitHub","GitLab","Bitbucket"];for(let n=0;n"group"===e.type?a(t,e):"page"===e.type&&Object(r.e)(t,e.path));return n||i}return!1}var o={name:"SidebarLinks",components:{SidebarGroup:i.default,SidebarLink:s.default},props:["items","depth","sidebarDepth","initialOpenGroupIndex"],data(){return{openGroupIndex:this.initialOpenGroupIndex||0}},watch:{$route(){this.refreshIndex()}},created(){this.refreshIndex()},methods:{refreshIndex(){const t=function(t,e){for(let n=0;n-1&&(this.openGroupIndex=t)},toggleGroup(t){this.openGroupIndex=t===this.openGroupIndex?-1:t},isActive(t){return Object(r.e)(this.$route,t.regularPath)}}},l=n(14),u=Object(l.a)(o,(function(){var t=this,e=t._self._c;return t.items.length?e("ul",{staticClass:"sidebar-links"},t._l(t.items,(function(n,i){return e("li",{key:i},["group"===n.type?e("SidebarGroup",{attrs:{item:n,open:i===t.openGroupIndex,collapsable:n.collapsable||n.collapsible,depth:t.depth},on:{toggle:function(e){return t.toggleGroup(i)}}}):e("SidebarLink",{attrs:{"sidebar-depth":t.sidebarDepth,item:n}})],1)})),0):t._e()}),[],!1,null,null,null);e.default=u.exports},270:function(t,e,n){"use strict";n.r(e);var i=n(239);function s(t,e,n,i,s){const r={props:{to:e,activeClass:"",exactActiveClass:""},class:{active:i,"sidebar-link":!0}};return s>2&&(r.style={"padding-left":s+"rem"}),t("RouterLink",r,n)}function r(t,e,n,a,o,l=1){return!e||l>o?null:t("ul",{class:"sidebar-sub-headers"},e.map(e=>{const u=Object(i.e)(a,n+"#"+e.slug);return t("li",{class:"sidebar-sub-header"},[s(t,n+"#"+e.slug,e.title,u,e.level-1),r(t,e.children,n,a,o,l+1)])}))}var a={functional:!0,props:["item","sidebarDepth"],render(t,{parent:{$page:e,$site:n,$route:a,$themeConfig:o,$themeLocaleConfig:l},props:{item:u,sidebarDepth:c}}){const p=Object(i.e)(a,u.path),h="auto"===u.type?p||u.children.some(t=>Object(i.e)(a,u.basePath+"#"+t.slug)):p,d="external"===u.type?function(t,e,n){return t("a",{attrs:{href:e,target:"_blank",rel:"noopener noreferrer"},class:{"sidebar-link":!0}},[n,t("OutboundLink")])}(t,u.path,u.title||u.path):s(t,u.path,u.title||u.path,h),f=[e.frontmatter.sidebarDepth,c,l.sidebarDepth,o.sidebarDepth,1].find(t=>void 0!==t),b=l.displayAllHeaders||o.displayAllHeaders;if("auto"===u.type)return[d,r(t,u.children,u.basePath,a,f)];if((h||b)&&u.headers&&!i.d.test(u.path)){return[d,r(t,Object(i.c)(u.headers),u.path,a,f)]}return d}},o=(n(263),n(14)),l=Object(o.a)(a,void 0,void 0,!1,null,null,null);e.default=l.exports},275:function(t,e,n){"use strict";n(262)},277:function(t,e,n){"use strict";n.r(e);var i=n(239),s={name:"SidebarGroup",components:{DropdownTransition:n(244).default},props:["item","open","collapsable","depth"],beforeCreate(){this.$options.components.SidebarLinks=n(268).default},methods:{isActive:i.e}},r=(n(275),n(14)),a=Object(r.a)(s,(function(){var t=this,e=t._self._c;return e("section",{staticClass:"sidebar-group",class:[{collapsable:t.collapsable,"is-sub-group":0!==t.depth},"depth-"+t.depth]},[t.item.path?e("RouterLink",{staticClass:"sidebar-heading clickable",class:{open:t.open,active:t.isActive(t.$route,t.item.path)},attrs:{to:t.item.path},nativeOn:{click:function(e){return t.$emit("toggle")}}},[e("span",[t._v(t._s(t.item.title))]),t._v(" "),t.collapsable?e("span",{staticClass:"arrow",class:t.open?"down":"right"}):t._e()]):e("p",{staticClass:"sidebar-heading",class:{open:t.open},on:{click:function(e){return t.$emit("toggle")}}},[e("span",[t._v(t._s(t.item.title))]),t._v(" "),t.collapsable?e("span",{staticClass:"arrow",class:t.open?"down":"right"}):t._e()]),t._v(" "),e("DropdownTransition",[t.open||!t.collapsable?e("SidebarLinks",{staticClass:"sidebar-group-items",attrs:{items:t.item.children,"sidebar-depth":t.item.sidebarDepth,"initial-open-group-index":t.item.initialOpenGroupIndex,depth:t.depth+1}}):t._e()],1)],1)}),[],!1,null,null,null);e.default=a.exports},280:function(t,e,n){},293:function(t,e,n){"use strict";n(280)},308:function(t,e,n){"use strict";n.r(e);var i=n(268),s=n(264),r={name:"Sidebar",components:{SidebarLinks:i.default,NavLinks:s.default},props:["items"]},a=(n(293),n(14)),o=Object(a.a)(r,(function(){var t=this._self._c;return t("aside",{staticClass:"sidebar"},[t("NavLinks"),this._v(" "),this._t("top"),this._v(" "),t("SidebarLinks",{attrs:{depth:0,items:this.items}}),this._v(" "),this._t("bottom")],2)}),[],!1,null,null,null);e.default=o.exports}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[1,3,13,16,21,22,24],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return r})),n.d(e,"i",(function(){return a})),n.d(e,"f",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"b",(function(){return p})),n.d(e,"e",(function(){return h})),n.d(e,"k",(function(){return d})),n.d(e,"l",(function(){return f})),n.d(e,"c",(function(){return m})),n.d(e,"j",(function(){return g}));n(89);const i=/#.*$/,s=/\.(md|html)$/,r=/\/$/,a=/^[a-z]+:/i;function o(t){return decodeURI(t).replace(i,"").replace(s,"")}function l(t){return a.test(t)}function u(t){return/^mailto:/.test(t)}function c(t){return/^tel:/.test(t)}function p(t){if(l(t))return t;const e=t.match(i),n=e?e[0]:"",s=o(t);return r.test(s)?t:s+".html"+n}function h(t,e){const n=decodeURIComponent(t.hash),s=function(t){const e=t.match(i);if(e)return e[0]}(e);if(s&&n!==s)return!1;return o(t.path)===o(e)}function d(t,e,n){if(l(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const s=e.split("/");n&&s[s.length-1]||s.pop();const r=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,s=1){if("string"==typeof e)return d(n,e,i);if(Array.isArray(e))return Object.assign(d(n,e[0],i),{title:e[1]});{const r=e.children||[];return 0===r.length&&e.path?Object.assign(d(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:r.map(e=>t(e,n,i,s+1)),collapsable:!1!==e.collapsable}}}(t,s,n)):[]}return[]}function b(t){const e=m(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function m(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function g(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),s={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},r=n(14),a=Object(r.a)(s,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=a.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},s=(n(242),n(14)),r=Object(s.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=r.exports},246:function(t,e,n){},250:function(t,e,n){},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),s=n(244),r=n(90),a=n.n(r),o={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:s.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>a()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(o,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports},254:function(t,e,n){"use strict";n(246)},262:function(t,e,n){},263:function(t,e,n){"use strict";n(250)},264:function(t,e,n){"use strict";n.r(e);var i=n(252),s=n(239),r={name:"NavLinks",components:{NavLink:n(241).default,DropdownLink:i.default},computed:{userNav(){return this.$themeLocaleConfig.nav||this.$site.themeConfig.nav||[]},nav(){const{locales:t}=this.$site;if(t&&Object.keys(t).length>1){const e=this.$page.path,n=this.$router.options.routes,i=this.$site.themeConfig.locales||{},s={text:this.$themeLocaleConfig.selectText||"Languages",ariaLabel:this.$themeLocaleConfig.ariaLabel||"Select language",items:Object.keys(t).map(s=>{const r=t[s],a=i[s]&&i[s].label||r.lang;let o;return r.lang===this.$lang?o=e:(o=e.replace(this.$localeConfig.path,s),n.some(t=>t.path===o)||(o=s)),{text:a,link:o}})};return[...this.userNav,s]}return this.userNav},userLinks(){return(this.nav||[]).map(t=>Object.assign(Object(s.j)(t),{items:(t.items||[]).map(s.j)}))},repoLink(){const{repo:t}=this.$site.themeConfig;return t?/^https?:/.test(t)?t:"https://github.com/"+t:null},repoLabel(){if(!this.repoLink)return;if(this.$site.themeConfig.repoLabel)return this.$site.themeConfig.repoLabel;const t=this.repoLink.match(/^https?:\/\/[^/]+/)[0],e=["GitHub","GitLab","Bitbucket"];for(let n=0;n"group"===e.type?a(t,e):"page"===e.type&&Object(r.e)(t,e.path));return n||i}return!1}var o={name:"SidebarLinks",components:{SidebarGroup:i.default,SidebarLink:s.default},props:["items","depth","sidebarDepth","initialOpenGroupIndex"],data(){return{openGroupIndex:this.initialOpenGroupIndex||0}},watch:{$route(){this.refreshIndex()}},created(){this.refreshIndex()},methods:{refreshIndex(){const t=function(t,e){for(let n=0;n-1&&(this.openGroupIndex=t)},toggleGroup(t){this.openGroupIndex=t===this.openGroupIndex?-1:t},isActive(t){return Object(r.e)(this.$route,t.regularPath)}}},l=n(14),u=Object(l.a)(o,(function(){var t=this,e=t._self._c;return t.items.length?e("ul",{staticClass:"sidebar-links"},t._l(t.items,(function(n,i){return e("li",{key:i},["group"===n.type?e("SidebarGroup",{attrs:{item:n,open:i===t.openGroupIndex,collapsable:n.collapsable||n.collapsible,depth:t.depth},on:{toggle:function(e){return t.toggleGroup(i)}}}):e("SidebarLink",{attrs:{"sidebar-depth":t.sidebarDepth,item:n}})],1)})),0):t._e()}),[],!1,null,null,null);e.default=u.exports},270:function(t,e,n){"use strict";n.r(e);var i=n(239);function s(t,e,n,i,s){const r={props:{to:e,activeClass:"",exactActiveClass:""},class:{active:i,"sidebar-link":!0}};return s>2&&(r.style={"padding-left":s+"rem"}),t("RouterLink",r,n)}function r(t,e,n,a,o,l=1){return!e||l>o?null:t("ul",{class:"sidebar-sub-headers"},e.map(e=>{const u=Object(i.e)(a,n+"#"+e.slug);return t("li",{class:"sidebar-sub-header"},[s(t,n+"#"+e.slug,e.title,u,e.level-1),r(t,e.children,n,a,o,l+1)])}))}var a={functional:!0,props:["item","sidebarDepth"],render(t,{parent:{$page:e,$site:n,$route:a,$themeConfig:o,$themeLocaleConfig:l},props:{item:u,sidebarDepth:c}}){const p=Object(i.e)(a,u.path),h="auto"===u.type?p||u.children.some(t=>Object(i.e)(a,u.basePath+"#"+t.slug)):p,d="external"===u.type?function(t,e,n){return t("a",{attrs:{href:e,target:"_blank",rel:"noopener noreferrer"},class:{"sidebar-link":!0}},[n,t("OutboundLink")])}(t,u.path,u.title||u.path):s(t,u.path,u.title||u.path,h),f=[e.frontmatter.sidebarDepth,c,l.sidebarDepth,o.sidebarDepth,1].find(t=>void 0!==t),b=l.displayAllHeaders||o.displayAllHeaders;if("auto"===u.type)return[d,r(t,u.children,u.basePath,a,f)];if((h||b)&&u.headers&&!i.d.test(u.path)){return[d,r(t,Object(i.c)(u.headers),u.path,a,f)]}return d}},o=(n(263),n(14)),l=Object(o.a)(a,void 0,void 0,!1,null,null,null);e.default=l.exports},275:function(t,e,n){"use strict";n(262)},277:function(t,e,n){"use strict";n.r(e);var i=n(239),s={name:"SidebarGroup",components:{DropdownTransition:n(244).default},props:["item","open","collapsable","depth"],beforeCreate(){this.$options.components.SidebarLinks=n(268).default},methods:{isActive:i.e}},r=(n(275),n(14)),a=Object(r.a)(s,(function(){var t=this,e=t._self._c;return e("section",{staticClass:"sidebar-group",class:[{collapsable:t.collapsable,"is-sub-group":0!==t.depth},"depth-"+t.depth]},[t.item.path?e("RouterLink",{staticClass:"sidebar-heading clickable",class:{open:t.open,active:t.isActive(t.$route,t.item.path)},attrs:{to:t.item.path},nativeOn:{click:function(e){return t.$emit("toggle")}}},[e("span",[t._v(t._s(t.item.title))]),t._v(" "),t.collapsable?e("span",{staticClass:"arrow",class:t.open?"down":"right"}):t._e()]):e("p",{staticClass:"sidebar-heading",class:{open:t.open},on:{click:function(e){return t.$emit("toggle")}}},[e("span",[t._v(t._s(t.item.title))]),t._v(" "),t.collapsable?e("span",{staticClass:"arrow",class:t.open?"down":"right"}):t._e()]),t._v(" "),e("DropdownTransition",[t.open||!t.collapsable?e("SidebarLinks",{staticClass:"sidebar-group-items",attrs:{items:t.item.children,"sidebar-depth":t.item.sidebarDepth,"initial-open-group-index":t.item.initialOpenGroupIndex,depth:t.depth+1}}):t._e()],1)],1)}),[],!1,null,null,null);e.default=a.exports},280:function(t,e,n){},293:function(t,e,n){"use strict";n(280)},307:function(t,e,n){"use strict";n.r(e);var i=n(268),s=n(264),r={name:"Sidebar",components:{SidebarLinks:i.default,NavLinks:s.default},props:["items"]},a=(n(293),n(14)),o=Object(a.a)(r,(function(){var t=this._self._c;return t("aside",{staticClass:"sidebar"},[t("NavLinks"),this._v(" "),this._t("top"),this._v(" "),t("SidebarLinks",{attrs:{depth:0,items:this.items}}),this._v(" "),this._t("bottom")],2)}),[],!1,null,null,null);e.default=o.exports}}]); \ No newline at end of file diff --git a/assets/js/11.9edb0d97.js b/assets/js/11.3076e705.js similarity index 98% rename from assets/js/11.9edb0d97.js rename to assets/js/11.3076e705.js index 14b19c68e..425175089 100644 --- a/assets/js/11.9edb0d97.js +++ b/assets/js/11.3076e705.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[11,4,13,16,22,23,24],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return r})),n.d(e,"i",(function(){return o})),n.d(e,"f",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"b",(function(){return h})),n.d(e,"e",(function(){return f})),n.d(e,"k",(function(){return p})),n.d(e,"l",(function(){return d})),n.d(e,"c",(function(){return m})),n.d(e,"j",(function(){return k}));n(90);const i=/#.*$/,s=/\.(md|html)$/,r=/\/$/,o=/^[a-z]+:/i;function a(t){return decodeURI(t).replace(i,"").replace(s,"")}function l(t){return o.test(t)}function u(t){return/^mailto:/.test(t)}function c(t){return/^tel:/.test(t)}function h(t){if(l(t))return t;const e=t.match(i),n=e?e[0]:"",s=a(t);return r.test(s)?t:s+".html"+n}function f(t,e){const n=decodeURIComponent(t.hash),s=function(t){const e=t.match(i);if(e)return e[0]}(e);if(s&&n!==s)return!1;return a(t.path)===a(e)}function p(t,e,n){if(l(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const s=e.split("/");n&&s[s.length-1]||s.pop();const r=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,s=1){if("string"==typeof e)return p(n,e,i);if(Array.isArray(e))return Object.assign(p(n,e[0],i),{title:e[1]});{const r=e.children||[];return 0===r.length&&e.path?Object.assign(p(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:r.map(e=>t(e,n,i,s+1)),collapsable:!1!==e.collapsable}}}(t,s,n)):[]}return[]}function g(t){const e=m(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function m(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function k(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),s={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},r=n(14),o=Object(r.a)(s,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=o.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},s=(n(242),n(14)),r=Object(s.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=r.exports},246:function(t,e,n){},247:function(t,e,n){},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),s=n(244),r=n(91),o=n.n(r),a={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:s.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>o()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(a,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports},254:function(t,e,n){"use strict";n(246)},255:function(t,e,n){},256:function(t,e,n){"use strict";n(247)},257:function(t,e,n){},264:function(t,e,n){"use strict";n.r(e);var i=n(252),s=n(239),r={name:"NavLinks",components:{NavLink:n(241).default,DropdownLink:i.default},computed:{userNav(){return this.$themeLocaleConfig.nav||this.$site.themeConfig.nav||[]},nav(){const{locales:t}=this.$site;if(t&&Object.keys(t).length>1){const e=this.$page.path,n=this.$router.options.routes,i=this.$site.themeConfig.locales||{},s={text:this.$themeLocaleConfig.selectText||"Languages",ariaLabel:this.$themeLocaleConfig.ariaLabel||"Select language",items:Object.keys(t).map(s=>{const r=t[s],o=i[s]&&i[s].label||r.lang;let a;return r.lang===this.$lang?a=e:(a=e.replace(this.$localeConfig.path,s),n.some(t=>t.path===a)||(a=s)),{text:o,link:a}})};return[...this.userNav,s]}return this.userNav},userLinks(){return(this.nav||[]).map(t=>Object.assign(Object(s.j)(t),{items:(t.items||[]).map(s.j)}))},repoLink(){const{repo:t}=this.$site.themeConfig;return t?/^https?:/.test(t)?t:"https://github.com/"+t:null},repoLabel(){if(!this.repoLink)return;if(this.$site.themeConfig.repoLabel)return this.$site.themeConfig.repoLabel;const t=this.repoLink.match(/^https?:\/\/[^/]+/)[0],e=["GitHub","GitLab","Bitbucket"];for(let n=0;n{let i=s()(e,"title","");return s()(e,"frontmatter.tags")&&(i+=" "+e.frontmatter.tags.join(" ")),n&&(i+=" "+n),o(t,i)};const o=(t,e)=>{const n=e.toLowerCase();return t.toLowerCase().split(/\s+/g).map(t=>t.trim()).filter(t=>!!t).every(t=>n.indexOf(t)>-1)};var a={name:"SearchBox",data:()=>({query:"",focused:!1,focusIndex:0,placeholder:void 0}),computed:{showSuggestions(){return this.focused&&this.suggestions&&this.suggestions.length},suggestions(){return[{name:"Guides",filterFn:t=>!this.isFromApiReference(t),limit:this.$site.themeConfig.searchLimitGuide||5},{name:"API Reference",filterFn:this.isFromApiReference,limit:this.$site.themeConfig.searchLimitApi||5}].map(t=>this.suggestionsFromCategory(t.name,t.filterFn,t.limit)).reduce((t,e)=>t.concat(e),[])},alignRight(){return(this.$site.themeConfig.nav||[]).length+(this.$site.repo?1:0)<=2}},mounted(){this.placeholder=this.$site.themeConfig.searchPlaceholder||"",document.addEventListener("keydown",this.onHotkey)},beforeDestroy(){document.removeEventListener("keydown",this.onHotkey)},methods:{suggestionsFromCategory(t,e,n){const i=this.query.trim().toLowerCase();if(!i)return[];const{pages:s}=this.$site,o=this.$localePath,a=[];for(let l=0;l=n);l++){const u=s[l];if(this.getPageLocalePath(u)===o&&e(u)&&this.isSearchable(u))if(r(i,u))a.push({...u,category:t});else if(u.headers)for(let e=0;e=n);e++){const n=u.headers[e];n.title&&r(i,u,n.title)&&a.push({...u,path:u.path+"#"+n.slug,header:n,category:t})}}return a},isFromApiReference:t=>t.path.startsWith("/api/"),getPageLocalePath(t){for(const e in this.$site.locales||{})if("/"!==e&&0===t.path.indexOf(e))return e;return"/"},isSearchable(t){let e=null;return null===e||(e=Array.isArray(e)?e:new Array(e),e.filter(e=>t.path.match(e)).length>0)},onHotkey(t){t.srcElement===document.body&&["s","/"].includes(t.key)&&(this.$refs.input.focus(),t.preventDefault())},onUp(){this.showSuggestions&&(this.focusIndex>0?this.focusIndex--:this.focusIndex=this.suggestions.length-1)},onDown(){this.showSuggestions&&(this.focusIndex "+t._s(n.header.title))]):t._e()])])]}))],2):t._e()])}),[],!1,null,null,null);e.a=u.exports},286:function(t,e,n){"use strict";n.r(e);var i=n(276),s=n(269),r=n(264);function o(t,e){return t.ownerDocument.defaultView.getComputedStyle(t,null)[e]}var a={name:"Navbar",components:{SidebarButton:s.default,NavLinks:r.default,SearchBox:i.a,AlgoliaSearchBox:{}},data:()=>({linksWrapMaxWidth:null}),computed:{algolia(){return this.$themeLocaleConfig.algolia||this.$site.themeConfig.algolia||{}},isAlgoliaSearch(){return this.algolia&&this.algolia.apiKey&&this.algolia.indexName}},mounted(){const t=parseInt(o(this.$el,"paddingLeft"))+parseInt(o(this.$el,"paddingRight")),e=()=>{document.documentElement.clientWidth<719?this.linksWrapMaxWidth=null:this.linksWrapMaxWidth=this.$el.offsetWidth-t-(this.$refs.siteName&&this.$refs.siteName.offsetWidth||0)};e(),window.addEventListener("resize",e,!1)}},l=(n(273),n(14)),u=Object(l.a)(a,(function(){var t=this,e=t._self._c;return e("header",{staticClass:"navbar"},[e("SidebarButton",{on:{"toggle-sidebar":function(e){return t.$emit("toggle-sidebar")}}}),t._v(" "),e("RouterLink",{staticClass:"home-link",attrs:{to:t.$localePath}},[t.$site.themeConfig.logo?e("img",{staticClass:"logo",attrs:{src:t.$withBase(t.$site.themeConfig.logo),alt:t.$siteTitle}}):t._e(),t._v(" "),t.$siteTitle?e("span",{ref:"siteName",staticClass:"site-name",class:{"can-hide":t.$site.themeConfig.logo}},[t._v(t._s(t.$siteTitle))]):t._e()]),t._v(" "),e("div",{staticClass:"links",style:t.linksWrapMaxWidth?{"max-width":t.linksWrapMaxWidth+"px"}:{}},[t.isAlgoliaSearch?e("AlgoliaSearchBox",{attrs:{options:t.algolia}}):!1!==t.$site.themeConfig.search&&!1!==t.$page.frontmatter.search?e("SearchBox"):t._e(),t._v(" "),e("NavLinks",{staticClass:"can-hide"})],1)],1)}),[],!1,null,null,null);e.default=u.exports}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[11,4,13,16,22,23,24],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return r})),n.d(e,"i",(function(){return o})),n.d(e,"f",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"b",(function(){return h})),n.d(e,"e",(function(){return f})),n.d(e,"k",(function(){return p})),n.d(e,"l",(function(){return d})),n.d(e,"c",(function(){return m})),n.d(e,"j",(function(){return k}));n(89);const i=/#.*$/,s=/\.(md|html)$/,r=/\/$/,o=/^[a-z]+:/i;function a(t){return decodeURI(t).replace(i,"").replace(s,"")}function l(t){return o.test(t)}function u(t){return/^mailto:/.test(t)}function c(t){return/^tel:/.test(t)}function h(t){if(l(t))return t;const e=t.match(i),n=e?e[0]:"",s=a(t);return r.test(s)?t:s+".html"+n}function f(t,e){const n=decodeURIComponent(t.hash),s=function(t){const e=t.match(i);if(e)return e[0]}(e);if(s&&n!==s)return!1;return a(t.path)===a(e)}function p(t,e,n){if(l(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const s=e.split("/");n&&s[s.length-1]||s.pop();const r=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,s=1){if("string"==typeof e)return p(n,e,i);if(Array.isArray(e))return Object.assign(p(n,e[0],i),{title:e[1]});{const r=e.children||[];return 0===r.length&&e.path?Object.assign(p(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:r.map(e=>t(e,n,i,s+1)),collapsable:!1!==e.collapsable}}}(t,s,n)):[]}return[]}function g(t){const e=m(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function m(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function k(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),s={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},r=n(14),o=Object(r.a)(s,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=o.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},s=(n(242),n(14)),r=Object(s.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=r.exports},246:function(t,e,n){},247:function(t,e,n){},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),s=n(244),r=n(90),o=n.n(r),a={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:s.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>o()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(a,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports},254:function(t,e,n){"use strict";n(246)},255:function(t,e,n){},256:function(t,e,n){"use strict";n(247)},257:function(t,e,n){},264:function(t,e,n){"use strict";n.r(e);var i=n(252),s=n(239),r={name:"NavLinks",components:{NavLink:n(241).default,DropdownLink:i.default},computed:{userNav(){return this.$themeLocaleConfig.nav||this.$site.themeConfig.nav||[]},nav(){const{locales:t}=this.$site;if(t&&Object.keys(t).length>1){const e=this.$page.path,n=this.$router.options.routes,i=this.$site.themeConfig.locales||{},s={text:this.$themeLocaleConfig.selectText||"Languages",ariaLabel:this.$themeLocaleConfig.ariaLabel||"Select language",items:Object.keys(t).map(s=>{const r=t[s],o=i[s]&&i[s].label||r.lang;let a;return r.lang===this.$lang?a=e:(a=e.replace(this.$localeConfig.path,s),n.some(t=>t.path===a)||(a=s)),{text:o,link:a}})};return[...this.userNav,s]}return this.userNav},userLinks(){return(this.nav||[]).map(t=>Object.assign(Object(s.j)(t),{items:(t.items||[]).map(s.j)}))},repoLink(){const{repo:t}=this.$site.themeConfig;return t?/^https?:/.test(t)?t:"https://github.com/"+t:null},repoLabel(){if(!this.repoLink)return;if(this.$site.themeConfig.repoLabel)return this.$site.themeConfig.repoLabel;const t=this.repoLink.match(/^https?:\/\/[^/]+/)[0],e=["GitHub","GitLab","Bitbucket"];for(let n=0;n{let i=s()(e,"title","");return s()(e,"frontmatter.tags")&&(i+=" "+e.frontmatter.tags.join(" ")),n&&(i+=" "+n),o(t,i)};const o=(t,e)=>{const n=e.toLowerCase();return t.toLowerCase().split(/\s+/g).map(t=>t.trim()).filter(t=>!!t).every(t=>n.indexOf(t)>-1)};var a={name:"SearchBox",data:()=>({query:"",focused:!1,focusIndex:0,placeholder:void 0}),computed:{showSuggestions(){return this.focused&&this.suggestions&&this.suggestions.length},suggestions(){return[{name:"Guides",filterFn:t=>!this.isFromApiReference(t),limit:this.$site.themeConfig.searchLimitGuide||5},{name:"API Reference",filterFn:this.isFromApiReference,limit:this.$site.themeConfig.searchLimitApi||5}].map(t=>this.suggestionsFromCategory(t.name,t.filterFn,t.limit)).reduce((t,e)=>t.concat(e),[])},alignRight(){return(this.$site.themeConfig.nav||[]).length+(this.$site.repo?1:0)<=2}},mounted(){this.placeholder=this.$site.themeConfig.searchPlaceholder||"",document.addEventListener("keydown",this.onHotkey)},beforeDestroy(){document.removeEventListener("keydown",this.onHotkey)},methods:{suggestionsFromCategory(t,e,n){const i=this.query.trim().toLowerCase();if(!i)return[];const{pages:s}=this.$site,o=this.$localePath,a=[];for(let l=0;l=n);l++){const u=s[l];if(this.getPageLocalePath(u)===o&&e(u)&&this.isSearchable(u))if(r(i,u))a.push({...u,category:t});else if(u.headers)for(let e=0;e=n);e++){const n=u.headers[e];n.title&&r(i,u,n.title)&&a.push({...u,path:u.path+"#"+n.slug,header:n,category:t})}}return a},isFromApiReference:t=>t.path.startsWith("/api/"),getPageLocalePath(t){for(const e in this.$site.locales||{})if("/"!==e&&0===t.path.indexOf(e))return e;return"/"},isSearchable(t){let e=null;return null===e||(e=Array.isArray(e)?e:new Array(e),e.filter(e=>t.path.match(e)).length>0)},onHotkey(t){t.srcElement===document.body&&["s","/"].includes(t.key)&&(this.$refs.input.focus(),t.preventDefault())},onUp(){this.showSuggestions&&(this.focusIndex>0?this.focusIndex--:this.focusIndex=this.suggestions.length-1)},onDown(){this.showSuggestions&&(this.focusIndex "+t._s(n.header.title))]):t._e()])])]}))],2):t._e()])}),[],!1,null,null,null);e.a=u.exports},286:function(t,e,n){"use strict";n.r(e);var i=n(276),s=n(269),r=n(264);function o(t,e){return t.ownerDocument.defaultView.getComputedStyle(t,null)[e]}var a={name:"Navbar",components:{SidebarButton:s.default,NavLinks:r.default,SearchBox:i.a,AlgoliaSearchBox:{}},data:()=>({linksWrapMaxWidth:null}),computed:{algolia(){return this.$themeLocaleConfig.algolia||this.$site.themeConfig.algolia||{}},isAlgoliaSearch(){return this.algolia&&this.algolia.apiKey&&this.algolia.indexName}},mounted(){const t=parseInt(o(this.$el,"paddingLeft"))+parseInt(o(this.$el,"paddingRight")),e=()=>{document.documentElement.clientWidth<719?this.linksWrapMaxWidth=null:this.linksWrapMaxWidth=this.$el.offsetWidth-t-(this.$refs.siteName&&this.$refs.siteName.offsetWidth||0)};e(),window.addEventListener("resize",e,!1)}},l=(n(273),n(14)),u=Object(l.a)(a,(function(){var t=this,e=t._self._c;return e("header",{staticClass:"navbar"},[e("SidebarButton",{on:{"toggle-sidebar":function(e){return t.$emit("toggle-sidebar")}}}),t._v(" "),e("RouterLink",{staticClass:"home-link",attrs:{to:t.$localePath}},[t.$site.themeConfig.logo?e("img",{staticClass:"logo",attrs:{src:t.$withBase(t.$site.themeConfig.logo),alt:t.$siteTitle}}):t._e(),t._v(" "),t.$siteTitle?e("span",{ref:"siteName",staticClass:"site-name",class:{"can-hide":t.$site.themeConfig.logo}},[t._v(t._s(t.$siteTitle))]):t._e()]),t._v(" "),e("div",{staticClass:"links",style:t.linksWrapMaxWidth?{"max-width":t.linksWrapMaxWidth+"px"}:{}},[t.isAlgoliaSearch?e("AlgoliaSearchBox",{attrs:{options:t.algolia}}):!1!==t.$site.themeConfig.search&&!1!==t.$page.frontmatter.search?e("SearchBox"):t._e(),t._v(" "),e("NavLinks",{staticClass:"can-hide"})],1)],1)}),[],!1,null,null,null);e.default=u.exports}}]); \ No newline at end of file diff --git a/assets/js/12.8051c357.js b/assets/js/12.4379d8a8.js similarity index 98% rename from assets/js/12.8051c357.js rename to assets/js/12.4379d8a8.js index 6f53f7d34..d106ab380 100644 --- a/assets/js/12.8051c357.js +++ b/assets/js/12.4379d8a8.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[12,17,19],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return r})),n.d(e,"a",(function(){return a})),n.d(e,"i",(function(){return s})),n.d(e,"f",(function(){return u})),n.d(e,"g",(function(){return c})),n.d(e,"h",(function(){return l})),n.d(e,"b",(function(){return p})),n.d(e,"e",(function(){return f})),n.d(e,"k",(function(){return d})),n.d(e,"l",(function(){return h})),n.d(e,"c",(function(){return v})),n.d(e,"j",(function(){return m}));n(90);const r=/#.*$/,i=/\.(md|html)$/,a=/\/$/,s=/^[a-z]+:/i;function o(t){return decodeURI(t).replace(r,"").replace(i,"")}function u(t){return s.test(t)}function c(t){return/^mailto:/.test(t)}function l(t){return/^tel:/.test(t)}function p(t){if(u(t))return t;const e=t.match(r),n=e?e[0]:"",i=o(t);return a.test(i)?t:i+".html"+n}function f(t,e){const n=decodeURIComponent(t.hash),i=function(t){const e=t.match(r);if(e)return e[0]}(e);if(i&&n!==i)return!1;return o(t.path)===o(e)}function d(t,e,n){if(u(e))return{type:"external",path:e};n&&(e=function(t,e,n){const r=t.charAt(0);if("/"===r)return t;if("?"===r||"#"===r)return e+t;const i=e.split("/");n&&i[i.length-1]||i.pop();const a=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,r,i=1){if("string"==typeof e)return d(n,e,r);if(Array.isArray(e))return Object.assign(d(n,e[0],r),{title:e[1]});{const a=e.children||[];return 0===a.length&&e.path?Object.assign(d(n,e.path,r),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:a.map(e=>t(e,n,r,i+1)),collapsable:!1!==e.collapsable}}}(t,i,n)):[]}return[]}function g(t){const e=v(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function v(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function m(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},245:function(t,e){t.exports=function(t){return null==t}},248:function(t,e,n){},249:function(t,e,n){},258:function(t,e,n){"use strict";n(248)},259:function(t,e,n){var r=n(11),i=n(5),a=n(10);t.exports=function(t){return"string"==typeof t||!i(t)&&a(t)&&"[object String]"==r(t)}},260:function(t,e,n){"use strict";n(249)},261:function(t,e,n){},266:function(t,e,n){"use strict";n.r(e);var r=n(245),i=n.n(r),a=n(239),s={name:"PageEdit",computed:{lastUpdated(){return this.$page.lastUpdated},lastUpdatedText(){return"string"==typeof this.$themeLocaleConfig.lastUpdated?this.$themeLocaleConfig.lastUpdated:"string"==typeof this.$site.themeConfig.lastUpdated?this.$site.themeConfig.lastUpdated:"Last Updated"},editLink(){const t=i()(this.$page.frontmatter.editLink)?this.$site.themeConfig.editLinks:this.$page.frontmatter.editLink,{repo:e,docsDir:n="",docsBranch:r="master",docsRepo:a=e}=this.$site.themeConfig;return t&&a&&this.$page.relativePath?this.createEditLink(e,a,n,r,this.$page.relativePath):null},editLinkText(){return this.$themeLocaleConfig.editLinkText||this.$site.themeConfig.editLinkText||"Edit this page"}},methods:{createEditLink(t,e,n,r,i){if(/bitbucket.org/.test(e)){return e.replace(a.a,"")+"/src"+`/${r}/`+(n?n.replace(a.a,"")+"/":"")+i+`?mode=edit&spa=0&at=${r}&fileviewer=file-view-default`}if(/gitlab.com/.test(e)){return e.replace(a.a,"")+"/-/edit"+`/${r}/`+(n?n.replace(a.a,"")+"/":"")+i}return(a.i.test(e)?e:"https://github.com/"+e).replace(a.a,"")+"/edit"+`/${r}/`+(n?n.replace(a.a,"")+"/":"")+i}}},o=(n(258),n(14)),u=Object(o.a)(s,(function(){var t=this,e=t._self._c;return e("footer",{staticClass:"page-edit"},[t.editLink?e("div",{staticClass:"edit-link"},[e("a",{attrs:{href:t.editLink,target:"_blank",rel:"noopener noreferrer"}},[t._v(t._s(t.editLinkText))]),t._v(" "),e("OutboundLink")],1):t._e(),t._v(" "),t.lastUpdated?e("div",{staticClass:"last-updated"},[e("span",{staticClass:"prefix"},[t._v(t._s(t.lastUpdatedText)+":")]),t._v(" "),e("span",{staticClass:"time"},[t._v(t._s(t.lastUpdated))])]):t._e()])}),[],!1,null,null,null);e.default=u.exports},267:function(t,e,n){"use strict";n.r(e);n(90);var r=n(239),i=n(259),a=n.n(i),s=n(245),o=n.n(s),u={name:"PageNav",props:["sidebarItems"],computed:{prev(){return l(c.PREV,this)},next(){return l(c.NEXT,this)}}};const c={NEXT:{resolveLink:function(t,e){return p(t,e,1)},getThemeLinkConfig:({nextLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.next},PREV:{resolveLink:function(t,e){return p(t,e,-1)},getThemeLinkConfig:({prevLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.prev}};function l(t,{$themeConfig:e,$page:n,$route:i,$site:s,sidebarItems:u}){const{resolveLink:c,getThemeLinkConfig:l,getPageLinkConfig:p}=t,f=l(e),d=p(n),h=o()(d)?f:d;return!1===h?void 0:a()(h)?Object(r.k)(s.pages,h,i.path):c(n,u)}function p(t,e,n){const r=[];!function t(e,n){for(let r=0,i=e.length;rfunction t(e,n,r,i=1){if("string"==typeof e)return d(n,e,r);if(Array.isArray(e))return Object.assign(d(n,e[0],r),{title:e[1]});{const a=e.children||[];return 0===a.length&&e.path?Object.assign(d(n,e.path,r),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:a.map(e=>t(e,n,r,i+1)),collapsable:!1!==e.collapsable}}}(t,i,n)):[]}return[]}function g(t){const e=v(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function v(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function m(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},245:function(t,e){t.exports=function(t){return null==t}},248:function(t,e,n){},249:function(t,e,n){},258:function(t,e,n){"use strict";n(248)},259:function(t,e,n){var r=n(11),i=n(5),a=n(10);t.exports=function(t){return"string"==typeof t||!i(t)&&a(t)&&"[object String]"==r(t)}},260:function(t,e,n){"use strict";n(249)},261:function(t,e,n){},266:function(t,e,n){"use strict";n.r(e);var r=n(245),i=n.n(r),a=n(239),s={name:"PageEdit",computed:{lastUpdated(){return this.$page.lastUpdated},lastUpdatedText(){return"string"==typeof this.$themeLocaleConfig.lastUpdated?this.$themeLocaleConfig.lastUpdated:"string"==typeof this.$site.themeConfig.lastUpdated?this.$site.themeConfig.lastUpdated:"Last Updated"},editLink(){const t=i()(this.$page.frontmatter.editLink)?this.$site.themeConfig.editLinks:this.$page.frontmatter.editLink,{repo:e,docsDir:n="",docsBranch:r="master",docsRepo:a=e}=this.$site.themeConfig;return t&&a&&this.$page.relativePath?this.createEditLink(e,a,n,r,this.$page.relativePath):null},editLinkText(){return this.$themeLocaleConfig.editLinkText||this.$site.themeConfig.editLinkText||"Edit this page"}},methods:{createEditLink(t,e,n,r,i){if(/bitbucket.org/.test(e)){return e.replace(a.a,"")+"/src"+`/${r}/`+(n?n.replace(a.a,"")+"/":"")+i+`?mode=edit&spa=0&at=${r}&fileviewer=file-view-default`}if(/gitlab.com/.test(e)){return e.replace(a.a,"")+"/-/edit"+`/${r}/`+(n?n.replace(a.a,"")+"/":"")+i}return(a.i.test(e)?e:"https://github.com/"+e).replace(a.a,"")+"/edit"+`/${r}/`+(n?n.replace(a.a,"")+"/":"")+i}}},o=(n(258),n(14)),u=Object(o.a)(s,(function(){var t=this,e=t._self._c;return e("footer",{staticClass:"page-edit"},[t.editLink?e("div",{staticClass:"edit-link"},[e("a",{attrs:{href:t.editLink,target:"_blank",rel:"noopener noreferrer"}},[t._v(t._s(t.editLinkText))]),t._v(" "),e("OutboundLink")],1):t._e(),t._v(" "),t.lastUpdated?e("div",{staticClass:"last-updated"},[e("span",{staticClass:"prefix"},[t._v(t._s(t.lastUpdatedText)+":")]),t._v(" "),e("span",{staticClass:"time"},[t._v(t._s(t.lastUpdated))])]):t._e()])}),[],!1,null,null,null);e.default=u.exports},267:function(t,e,n){"use strict";n.r(e);n(89);var r=n(239),i=n(259),a=n.n(i),s=n(245),o=n.n(s),u={name:"PageNav",props:["sidebarItems"],computed:{prev(){return l(c.PREV,this)},next(){return l(c.NEXT,this)}}};const c={NEXT:{resolveLink:function(t,e){return p(t,e,1)},getThemeLinkConfig:({nextLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.next},PREV:{resolveLink:function(t,e){return p(t,e,-1)},getThemeLinkConfig:({prevLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.prev}};function l(t,{$themeConfig:e,$page:n,$route:i,$site:s,sidebarItems:u}){const{resolveLink:c,getThemeLinkConfig:l,getPageLinkConfig:p}=t,f=l(e),d=p(n),h=o()(d)?f:d;return!1===h?void 0:a()(h)?Object(r.k)(s.pages,h,i.path):c(n,u)}function p(t,e,n){const r=[];!function t(e,n){for(let r=0,i=e.length;rfunction t(e,n,i,r=1){if("string"==typeof e)return f(n,e,i);if(Array.isArray(e))return Object.assign(f(n,e[0],i),{title:e[1]});{const s=e.children||[];return 0===s.length&&e.path?Object.assign(f(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:s.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function m(t){const e=b(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function b(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function g(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),r={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},s=n(14),a=Object(s.a)(r,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=a.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},r=(n(242),n(14)),s=Object(r.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=s.exports},246:function(t,e,n){},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),r=n(244),s=n(91),a=n.n(s),o={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:r.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>a()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(o,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports},254:function(t,e,n){"use strict";n(246)},264:function(t,e,n){"use strict";n.r(e);var i=n(252),r=n(239),s={name:"NavLinks",components:{NavLink:n(241).default,DropdownLink:i.default},computed:{userNav(){return this.$themeLocaleConfig.nav||this.$site.themeConfig.nav||[]},nav(){const{locales:t}=this.$site;if(t&&Object.keys(t).length>1){const e=this.$page.path,n=this.$router.options.routes,i=this.$site.themeConfig.locales||{},r={text:this.$themeLocaleConfig.selectText||"Languages",ariaLabel:this.$themeLocaleConfig.ariaLabel||"Select language",items:Object.keys(t).map(r=>{const s=t[r],a=i[r]&&i[r].label||s.lang;let o;return s.lang===this.$lang?o=e:(o=e.replace(this.$localeConfig.path,r),n.some(t=>t.path===o)||(o=r)),{text:a,link:o}})};return[...this.userNav,r]}return this.userNav},userLinks(){return(this.nav||[]).map(t=>Object.assign(Object(r.j)(t),{items:(t.items||[]).map(r.j)}))},repoLink(){const{repo:t}=this.$site.themeConfig;return t?/^https?:/.test(t)?t:"https://github.com/"+t:null},repoLabel(){if(!this.repoLink)return;if(this.$site.themeConfig.repoLabel)return this.$site.themeConfig.repoLabel;const t=this.repoLink.match(/^https?:\/\/[^/]+/)[0],e=["GitHub","GitLab","Bitbucket"];for(let n=0;nfunction t(e,n,i,r=1){if("string"==typeof e)return f(n,e,i);if(Array.isArray(e))return Object.assign(f(n,e[0],i),{title:e[1]});{const s=e.children||[];return 0===s.length&&e.path?Object.assign(f(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:s.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function m(t){const e=b(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function b(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function g(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),r={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},s=n(14),a=Object(s.a)(r,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=a.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},r=(n(242),n(14)),s=Object(r.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=s.exports},246:function(t,e,n){},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),r=n(244),s=n(90),a=n.n(s),o={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:r.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>a()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(o,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports},254:function(t,e,n){"use strict";n(246)},264:function(t,e,n){"use strict";n.r(e);var i=n(252),r=n(239),s={name:"NavLinks",components:{NavLink:n(241).default,DropdownLink:i.default},computed:{userNav(){return this.$themeLocaleConfig.nav||this.$site.themeConfig.nav||[]},nav(){const{locales:t}=this.$site;if(t&&Object.keys(t).length>1){const e=this.$page.path,n=this.$router.options.routes,i=this.$site.themeConfig.locales||{},r={text:this.$themeLocaleConfig.selectText||"Languages",ariaLabel:this.$themeLocaleConfig.ariaLabel||"Select language",items:Object.keys(t).map(r=>{const s=t[r],a=i[r]&&i[r].label||s.lang;let o;return s.lang===this.$lang?o=e:(o=e.replace(this.$localeConfig.path,r),n.some(t=>t.path===o)||(o=r)),{text:a,link:o}})};return[...this.userNav,r]}return this.userNav},userLinks(){return(this.nav||[]).map(t=>Object.assign(Object(r.j)(t),{items:(t.items||[]).map(r.j)}))},repoLink(){const{repo:t}=this.$site.themeConfig;return t?/^https?:/.test(t)?t:"https://github.com/"+t:null},repoLabel(){if(!this.repoLink)return;if(this.$site.themeConfig.repoLabel)return this.$site.themeConfig.repoLabel;const t=this.repoLink.match(/^https?:\/\/[^/]+/)[0],e=["GitHub","GitLab","Bitbucket"];for(let n=0;n79&&s<83||!h("reduceRight")},{reduceRight:function(t){return r(this,t,arguments.length,arguments.length>1?arguments[1]:void 0)}})},303:function(t,i,e){var n,r,h;r=[],void 0===(h="function"==typeof(n=function(){function t(t){o(r(t.target.getAttribute("label"),"terminal","label"),"diagramRectUsage")}function i(t){var i,e,n,a,u=(i=t.target,e=i.getAttribute("rulename"),n=r(e,"non-terminal","rulename"),a=h(e),{rects:n,header:a,ruleName:e});o(u.rects,"diagramRectUsage"),s(u.header,"diagramHeaderDef")}function e(t){var i,e,n,r,s,o,a,c=h(t.target.getAttribute("rulename"));i=c.offsetTop,e=666,n="easeInOutQuint",r=window.scrollY,i=i||0,e=e||2e3,n=n||"easeOutSine",s=0,o=Math.max(.1,Math.min(Math.abs(r-i)/e,.8)),Math.PI,a={easeOutSine:function(t){return Math.sin(t*(Math.PI/2))},easeInOutSine:function(t){return-.5*(Math.cos(Math.PI*t)-1)},easeInOutQuint:function(t){return(t/=.5)<1?.5*Math.pow(t,5):.5*(Math.pow(t-2,5)+2)}},function t(){var e=(s+=1/60)/o,h=a[n](e);e<1?(u(t),window.scrollTo(0,r+(i-r)*h)):window.scrollTo(0,i)}()}function n(t){s(t.target,"diagramHeaderDef"),o(r(t.target.innerHTML,"non-terminal","rulename"),"diagramRectUsage")}function r(t,i,e){return c(a(document.getElementsByClassName(i)),"rect").filter((function(i){return i.parentNode.getElementsByTagName("text")[0].getAttribute(e)===t}))}function h(t){return a(document.getElementsByClassName("diagramHeader")).find((function(i){return i.innerHTML===t}))}function s(t,i){t.classList.contains(i)?t.classList.remove(i):t.classList.add(i)}function o(t,i){t.forEach((function(t){s(t,i)}))}function a(t){return Array.prototype.slice.call(t)}var u=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)};function c(t,i){var e=[];return t.forEach((function(t){a(t.children).forEach((function(t){t.tagName===i&&e.push(t)}))})),e}return{initDiagramsBehavior:function(r){void 0===r&&(r=!0),a(document.getElementsByClassName("diagramHeader")).forEach((function(t){t.addEventListener("mouseover",n),t.addEventListener("mouseout",n)})),c(a(document.getElementsByClassName("non-terminal")),"text").forEach((function(t){t.addEventListener("mouseover",i),t.addEventListener("mouseout",i),r&&t.addEventListener("click",e)})),c(a(document.getElementsByClassName("terminal")),"text").forEach((function(i){i.addEventListener("mouseover",t),i.addEventListener("mouseout",t)}))}}})?n.apply(i,r):n)||(t.exports=h)},304:function(t,i,e){var n,r,h;r=[e(305)],void 0===(h="function"==typeof(n=function(t){var i=t.Diagram,e=t.Sequence,n=t.Choice,r=t.Optional,h=t.OneOrMore,s=t.ZeroOrMore,o=(t.Terminal,t.NonTerminal);function a(i,e,n){var r=void 0;return"string"!=typeof i.pattern&&"[object RegExp]"!==Object.prototype.toString.call(i.pattern)||(r=i.pattern),t.Terminal(i.label,void 0,r,i.occurrenceInParent,e,n,i.name)}function u(t,c){if("NonTerminal"===t.type)return o(function(t){return void 0!==t.nonTerminalName?t.nonTerminalName:t.name}(t),void 0,t.occurrenceInParent,c);if("Terminal"===t.type){if("Terminal"===t.type)return a(t,c,"consume");throw Error("non exhaustive match")}var d=function(t,i){return t.map((function(t){return u(t,i)}))}(t.definition,c);if("Rule"===t.type)return i.apply(this,d);if("Flat"===t.type)return e.apply(this,d);if("Option"===t.type){if(d.length>1)return r(e.apply(this,d));if(1===d.length)return r(d[0]);throw Error("Empty Optional production, OOPS!")}if("Repetition"===t.type){if(d.length>1)return s(e.apply(this,d));if(1===d.length)return s(d[0]);throw Error("Empty Optional production, OOPS!")}if("Alternation"===t.type)return n.apply(this,[0].concat(d));if("RepetitionMandatory"===t.type){if(d.length>1)return h(e.apply(this,d));if(1===d.length)return h(d[0]);throw Error("Empty Optional production, OOPS!")}if("RepetitionWithSeparator"===t.type){if(d.length>0)return r(e.apply(this,d.concat([s(e.apply(this,[a(t.separator,c,"many_sep")].concat(d)))])));throw Error("Empty Optional production, OOPS!")}if("RepetitionMandatoryWithSeparator"===t.type){if(d.length>0)return e.apply(this,d.concat([s(e.apply(this,[a(t.separator,c,"at_least_one_sep")].concat(d)))]));throw Error("Empty Optional production, OOPS!")}}return{buildSyntaxDiagramsText:function(t){var i="";return t.forEach((function(t){var e=u(t,t.name);i+='

'+t.name+"

"+e})),i},convertProductionToDiagram:u}})?n.apply(i,r):n)||(t.exports=h)},305:function(t,i,e){var n;(function(e){function r(t,i){t.prototype=Object.create(i.prototype),t.prototype.$super=i.prototype}function h(){return[].slice.call(arguments).reduce((function(t,i){return void 0!==t?t:i}))}function s(t,i){var e=t-i;switch(d.INTERNAL_ALIGNMENT){case"left":return[0,e];case"right":return[e,0];case"center":default:return[e/2,e/2]}}function o(t){return"string"==typeof t?new y(t):t}function a(t){for(var i=0;i\n"},r(c,u),c.prototype.m=function(t,i){return this.attrs.d+="m"+t+" "+i,this},c.prototype.h=function(t){return this.attrs.d+="h"+t,this},c.prototype.right=c.prototype.h,c.prototype.left=function(t){return this.h(-t)},c.prototype.v=function(t){return this.attrs.d+="v"+t,this},c.prototype.down=c.prototype.v,c.prototype.up=function(t){return this.v(-t)},c.prototype.arc=function(t){var i=d.ARC_RADIUS,e=d.ARC_RADIUS;if("e"!=t[0]&&"w"!=t[1]||(i*=-1),"s"!=t[0]&&"n"!=t[1]||(e*=-1),"ne"==t||"es"==t||"sw"==t||"wn"==t)var n=1;else n=0;return this.attrs.d+="a"+d.ARC_RADIUS+" "+d.ARC_RADIUS+" 0 0 "+n+" "+i+" "+e,this},c.prototype.format=function(){return this.attrs.d+="h.5",this},r(d,u),e)d[f]=e[f];function p(t){if(!(this instanceof p))return new p([].slice.call(arguments));if(u.call(this,"g"),a(t))throw new RangeError("Stack() must only occur at the very last position of Sequence().");this.items=t.map(o),this.width=this.items.reduce((function(t,i){return t+i.width+(i.needsSpace?20:0)}),0),this.offsetX=0,this.height=this.items.reduce((function(t,i){return t+i.height}),0),this.up=this.items.reduce((function(t,i){return Math.max(t,i.up)}),0),this.down=this.items.reduce((function(t,i){return Math.max(t,i.down)}),0)}function m(t){if(!(this instanceof m))return new m([].slice.call(arguments));if(u.call(this,"g"),a(t))throw new RangeError("Stack() must only occur at the very last position of Stack().");if(0===t.length)throw new RangeError("Stack() must have at least one child.");this.items=t.map(o),this.width=this.items.reduce((function(t,i){return Math.max(t,i.width+(i.needsSpace?20:0))}),0),this.items.length>1&&(this.width+=2*d.ARC_RADIUS),this.up=this.items[0].up,this.down=this.items[this.items.length-1].down,this.height=0;for(var i=0;i1&&(this.offsetX+=2*d.ARC_RADIUS))}function l(t,i){if(!(this instanceof l))return new l(t,[].slice.call(arguments,1));if(u.call(this,"g"),"number"!=typeof t||t!==Math.floor(t))throw new TypeError("The first argument of Choice() must be an integer.");if(t<0||t>=i.length)throw new RangeError("The first argument of Choice() must be an index for one of the items.");this.normal=t,this.items=i.map(o),this.width=this.items.reduce((function(t,i){return Math.max(t,i.width)}),0)+4*d.ARC_RADIUS,this.offsetX=0,this.height=this.items[t].height,this.up=this.down=0;for(var e=0;et&&(this.down+=Math.max(d.ARC_RADIUS,d.VERTICAL_SEPARATION+n.up+n.down+n.height))}}function g(t,i){if(void 0===i)return l(1,v(),t);if("skip"===i)return l(0,v(),t);throw"Unknown value for Optional()'s 'skip' argument."}function w(t,i){if(!(this instanceof w))return new w(t,i);u.call(this,"g"),i=i||new v,this.item=o(t),this.rep=o(i),this.width=Math.max(this.item.width,this.rep.width)+2*d.ARC_RADIUS,this.offsetX=0,this.height=this.item.height,this.up=this.item.up,this.down=Math.max(2*d.ARC_RADIUS,this.item.down+d.VERTICAL_SEPARATION+this.rep.up+this.rep.height+this.rep.down)}function A(t){if(!(this instanceof A))return new A;u.call(this,"path"),this.width=20,this.height=0,this.offsetX=0,this.up=10,this.down=10,this.simpleType=t}function R(t){if(!(this instanceof R))return new R;u.call(this,"path"),this.width=20,this.height=0,this.offsetX=0,this.up=10,this.down=10,this.simpleType=t}function y(t,i,e,n,r,h,s){if(!(this instanceof y))return new y(t,i,e,n,r,h,s);u.call(this,"g",{class:"terminal"}),this.text=t,this.label=t,this.href=i,this.title=e,this.occurrenceIdx=n,this.topRuleName=r,this.dslRuleName=h,this.tokenName=s,this.width=8*t.length+20,this.height=0,this.offsetX=0,this.up=11,this.down=11}function S(t,i,e,n){if(!(this instanceof S))return new S(t,i,e,n);u.call(this,"g",{class:"non-terminal"}),this.text=t,this.ruleName=t,this.href=i,this.occurrenceIdx=e,this.topRuleName=n,this.width=8*t.length+20,this.height=0,this.offsetX=0,this.up=11,this.down=11}function T(t){if(!(this instanceof T))return new T(t);u.call(this,"g"),this.text=t,this.width=7*t.length+10,this.height=0,this.offsetX=0,this.up=11,this.down=11}function v(){if(!(this instanceof v))return new v;u.call(this,"g"),this.width=0,this.height=0,this.offsetX=0,this.up=0,this.down=0}var I;d.prototype.format=function(t,i,e,n){t=h(t,20),i=h(i,t,20),e=h(e,t,20);var r=n=h(n,i,20),s=t;s+=this.up;for(var o=u("g",d.STROKE_ODD_PIXEL_LENGTH?{transform:"translate(.5 .5)"}:{}),a=0;a=0;o--){var a=this.items[o];if(o==this.normal-1)var u=Math.max(2*d.ARC_RADIUS,this.items[o+1].up+d.VERTICAL_SEPARATION+a.height+a.down);c(t,i).arc("se").up(u-2*d.ARC_RADIUS).arc("wn").addTo(this),a.format(t+2*d.ARC_RADIUS,i-u,h).addTo(this),c(t+2*d.ARC_RADIUS+h,i-u+a.height).arc("ne").down(u-a.height+this.items[this.normal].height-2*d.ARC_RADIUS).arc("ws").addTo(this),u+=Math.max(d.ARC_RADIUS,a.up+d.VERTICAL_SEPARATION+(0==o?0:this.items[o-1].down+this.items[o-1].height))}c(t,i).right(2*d.ARC_RADIUS).addTo(this),this.items[this.normal].format(t+2*d.ARC_RADIUS,i,h).addTo(this),c(t+2*d.ARC_RADIUS+h,i+this.height).right(2*d.ARC_RADIUS).addTo(this);for(o=this.normal+1;o<=r;o++){a=this.items[o];if(o==this.normal+1)u=Math.max(2*d.ARC_RADIUS,this.items[o-1].height+this.items[o-1].down+d.VERTICAL_SEPARATION+a.up);c(t,i).arc("ne").down(u-2*d.ARC_RADIUS).arc("ws").addTo(this),a.format(t+2*d.ARC_RADIUS,i+u,h).addTo(this),c(t+2*d.ARC_RADIUS+h,i+u+a.height).arc("se").up(u-2*d.ARC_RADIUS+a.height-this.items[this.normal].height).arc("wn").addTo(this),u+=Math.max(d.ARC_RADIUS,a.height+a.down+d.VERTICAL_SEPARATION+(o==r?0:this.items[o+1].up))}return this},r(w,u),w.prototype.needsSpace=!0,w.prototype.format=function(t,i,e){var n=s(e,this.width);c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i+this.height).h(n[1]).addTo(this),c(t+=n[0],i).right(d.ARC_RADIUS).addTo(this),this.item.format(t+d.ARC_RADIUS,i,this.width-2*d.ARC_RADIUS).addTo(this),c(t+this.width-d.ARC_RADIUS,i+this.height).right(d.ARC_RADIUS).addTo(this);var r=Math.max(2*d.ARC_RADIUS,this.item.height+this.item.down+d.VERTICAL_SEPARATION+this.rep.up);return c(t+d.ARC_RADIUS,i).arc("nw").down(r-2*d.ARC_RADIUS).arc("ws").addTo(this),this.rep.format(t+d.ARC_RADIUS,i+r,this.width-2*d.ARC_RADIUS).addTo(this),c(t+this.width-d.ARC_RADIUS,i+r+this.rep.height).arc("se").up(r-2*d.ARC_RADIUS+this.rep.height-this.item.height).arc("en").addTo(this),this},r(A,u),A.prototype.format=function(t,i){return!1===this.simpleType?this.attrs.d="M "+t+" "+(i-10)+" v 20 m 0 -10 h 20.5":this.attrs.d="M "+t+" "+(i-10)+" v 20 m 10 -20 v 20 m -10 -10 h 20.5",this},r(R,u),R.prototype.format=function(t,i){return!1===this.simpleType?this.attrs.d="M "+t+" "+i+" h 20 m 0 -10 v 20":this.attrs.d="M "+t+" "+i+" h 20 m -10 -10 v 20 m 10 -20 v 20",this},r(y,u),y.prototype.needsSpace=!0,y.prototype.format=function(t,i,e){var n=s(e,this.width);c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i).h(n[1]).addTo(this),u("rect",{x:t+=n[0],y:i-11,width:this.width,height:this.up+this.down,rx:10,ry:10}).addTo(this);var r=u("text",{x:t+this.width/2,y:i+4,occurrenceIdx:this.occurrenceIdx,topRuleName:this.topRuleName,dslRuleName:this.dslRuleName,tokenName:this.tokenName,label:this.label},this.text),h=u("title",{},this.title);return this.href?u("a",{"xlink:href":this.href},[r]).addTo(this):(r.addTo(this),void 0!==this.title&&h.addTo(this)),this},r(S,u),S.prototype.needsSpace=!0,S.prototype.format=function(t,i,e){var n=s(e,this.width);c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i).h(n[1]).addTo(this),u("rect",{x:t+=n[0],y:i-11,width:this.width,height:this.up+this.down}).addTo(this);var r=u("text",{x:t+this.width/2,y:i+4,occurrenceIdx:this.occurrenceIdx,topRuleName:this.topRuleName,ruleName:this.ruleName},this.text);return this.href?u("a",{"xlink:href":this.href},[r]).addTo(this):r.addTo(this),this},r(T,u),T.prototype.needsSpace=!0,T.prototype.format=function(t,i,e){var n=s(e,this.width);return c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i+this.height).h(n[1]).addTo(this),u("text",{x:(t+=n[0])+this.width/2,y:i+5,class:"comment"},this.text).addTo(this),this},r(v,u),v.prototype.format=function(t,i,e){return c(t,i).right(e).addTo(this),this},I={},void 0===(n=function(){return I}.apply(i,[]))||(t.exports=n);var E=[d,function(){var t=new d([].slice.call(arguments)),i=t.items;return i.shift(),i.pop(),i.unshift(new A(!1)),i.push(new R(!1)),t.items=i,t},p,m,l,g,w,function(t,i,e){return g(w(t,i),e)},y,S,T,v];["Diagram","ComplexDiagram","Sequence","Stack","Choice","Optional","OneOrMore","ZeroOrMore","Terminal","NonTerminal","Comment","Skip"].forEach((function(t,i){I[t]=E[i]}))}).call(this,{VERTICAL_SEPARATION:8,ARC_RADIUS:10,DIAGRAM_CLASS:"railroad-diagram",STROKE_ODD_PIXEL_LENGTH:!0,INTERNAL_ALIGNMENT:"center"})},306:function(t,i,e){"use strict";e(284)}}]); \ No newline at end of file diff --git a/assets/js/14.fc597aa3.js b/assets/js/14.fc597aa3.js new file mode 100644 index 000000000..545ef33f2 --- /dev/null +++ b/assets/js/14.fc597aa3.js @@ -0,0 +1 @@ +(window.webpackJsonp=window.webpackJsonp||[]).push([[14],{265:function(t,i,e){"use strict";var n=e(93),r=e(15);t.exports=function(t,i,e){return e.get&&n(e.get,i,{getter:!0}),e.set&&n(e.set,i,{setter:!0}),r.f(t,i,e)}},284:function(t,i,e){},298:function(t,i,e){"use strict";e(23)({target:"Object",stat:!0},{hasOwn:e(7)})},299:function(t,i,e){"use strict";var n=e(0),r=e(4),h=e(265),s=e(300),o=e(3),a=n.RegExp,u=a.prototype;r&&o((function(){var t=!0;try{a(".","d")}catch(i){t=!1}var i={},e="",n=t?"dgimsy":"gimsy",r=function(t,n){Object.defineProperty(i,t,{get:function(){return e+=n,!0}})},h={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};for(var s in t&&(h.hasIndices="d"),h)r(s,h[s]);return Object.getOwnPropertyDescriptor(u,"flags").get.call(i)!==n||e!==n}))&&h(u,"flags",{configurable:!0,get:s})},300:function(t,i,e){"use strict";var n=e(24);t.exports=function(){var t=n(this),i="";return t.hasIndices&&(i+="d"),t.global&&(i+="g"),t.ignoreCase&&(i+="i"),t.multiline&&(i+="m"),t.dotAll&&(i+="s"),t.unicode&&(i+="u"),t.unicodeSets&&(i+="v"),t.sticky&&(i+="y"),i}},301:function(t,i,e){"use strict";var n=e(23),r=e(0),h=e(265),s=e(4),o=TypeError,a=Object.defineProperty,u=r.self!==r;try{if(s){var c=Object.getOwnPropertyDescriptor(r,"self");!u&&c&&c.get&&c.enumerable||h(r,"self",{get:function(){return r},set:function(t){if(this!==r)throw new o("Illegal invocation");a(r,"self",{value:t,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})}else n({global:!0,simple:!0,forced:u},{self:r})}catch(t){}},302:function(t,i,e){var n,r,h;r=[],void 0===(h="function"==typeof(n=function(){function t(t){o(r(t.target.getAttribute("label"),"terminal","label"),"diagramRectUsage")}function i(t){var i,e,n,a,u=(i=t.target,e=i.getAttribute("rulename"),n=r(e,"non-terminal","rulename"),a=h(e),{rects:n,header:a,ruleName:e});o(u.rects,"diagramRectUsage"),s(u.header,"diagramHeaderDef")}function e(t){var i,e,n,r,s,o,a,c=h(t.target.getAttribute("rulename"));i=c.offsetTop,e=666,n="easeInOutQuint",r=window.scrollY,i=i||0,e=e||2e3,n=n||"easeOutSine",s=0,o=Math.max(.1,Math.min(Math.abs(r-i)/e,.8)),Math.PI,a={easeOutSine:function(t){return Math.sin(t*(Math.PI/2))},easeInOutSine:function(t){return-.5*(Math.cos(Math.PI*t)-1)},easeInOutQuint:function(t){return(t/=.5)<1?.5*Math.pow(t,5):.5*(Math.pow(t-2,5)+2)}},function t(){var e=(s+=1/60)/o,h=a[n](e);e<1?(u(t),window.scrollTo(0,r+(i-r)*h)):window.scrollTo(0,i)}()}function n(t){s(t.target,"diagramHeaderDef"),o(r(t.target.innerHTML,"non-terminal","rulename"),"diagramRectUsage")}function r(t,i,e){return c(a(document.getElementsByClassName(i)),"rect").filter((function(i){return i.parentNode.getElementsByTagName("text")[0].getAttribute(e)===t}))}function h(t){return a(document.getElementsByClassName("diagramHeader")).find((function(i){return i.innerHTML===t}))}function s(t,i){t.classList.contains(i)?t.classList.remove(i):t.classList.add(i)}function o(t,i){t.forEach((function(t){s(t,i)}))}function a(t){return Array.prototype.slice.call(t)}var u=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(t){window.setTimeout(t,1e3/60)};function c(t,i){var e=[];return t.forEach((function(t){a(t.children).forEach((function(t){t.tagName===i&&e.push(t)}))})),e}return{initDiagramsBehavior:function(r){void 0===r&&(r=!0),a(document.getElementsByClassName("diagramHeader")).forEach((function(t){t.addEventListener("mouseover",n),t.addEventListener("mouseout",n)})),c(a(document.getElementsByClassName("non-terminal")),"text").forEach((function(t){t.addEventListener("mouseover",i),t.addEventListener("mouseout",i),r&&t.addEventListener("click",e)})),c(a(document.getElementsByClassName("terminal")),"text").forEach((function(i){i.addEventListener("mouseover",t),i.addEventListener("mouseout",t)}))}}})?n.apply(i,r):n)||(t.exports=h)},303:function(t,i,e){var n,r,h;r=[e(304)],void 0===(h="function"==typeof(n=function(t){var i=t.Diagram,e=t.Sequence,n=t.Choice,r=t.Optional,h=t.OneOrMore,s=t.ZeroOrMore,o=(t.Terminal,t.NonTerminal);function a(i,e,n){var r=void 0;return"string"!=typeof i.pattern&&"[object RegExp]"!==Object.prototype.toString.call(i.pattern)||(r=i.pattern),t.Terminal(i.label,void 0,r,i.occurrenceInParent,e,n,i.name)}function u(t,c){if("NonTerminal"===t.type)return o(function(t){return void 0!==t.nonTerminalName?t.nonTerminalName:t.name}(t),void 0,t.occurrenceInParent,c);if("Terminal"===t.type){if("Terminal"===t.type)return a(t,c,"consume");throw Error("non exhaustive match")}var d=function(t,i){return t.map((function(t){return u(t,i)}))}(t.definition,c);if("Rule"===t.type)return i.apply(this,d);if("Flat"===t.type)return e.apply(this,d);if("Option"===t.type){if(d.length>1)return r(e.apply(this,d));if(1===d.length)return r(d[0]);throw Error("Empty Optional production, OOPS!")}if("Repetition"===t.type){if(d.length>1)return s(e.apply(this,d));if(1===d.length)return s(d[0]);throw Error("Empty Optional production, OOPS!")}if("Alternation"===t.type)return n.apply(this,[0].concat(d));if("RepetitionMandatory"===t.type){if(d.length>1)return h(e.apply(this,d));if(1===d.length)return h(d[0]);throw Error("Empty Optional production, OOPS!")}if("RepetitionWithSeparator"===t.type){if(d.length>0)return r(e.apply(this,d.concat([s(e.apply(this,[a(t.separator,c,"many_sep")].concat(d)))])));throw Error("Empty Optional production, OOPS!")}if("RepetitionMandatoryWithSeparator"===t.type){if(d.length>0)return e.apply(this,d.concat([s(e.apply(this,[a(t.separator,c,"at_least_one_sep")].concat(d)))]));throw Error("Empty Optional production, OOPS!")}}return{buildSyntaxDiagramsText:function(t){var i="";return t.forEach((function(t){var e=u(t,t.name);i+='

'+t.name+"

"+e})),i},convertProductionToDiagram:u}})?n.apply(i,r):n)||(t.exports=h)},304:function(t,i,e){var n;(function(e){function r(t,i){t.prototype=Object.create(i.prototype),t.prototype.$super=i.prototype}function h(){return[].slice.call(arguments).reduce((function(t,i){return void 0!==t?t:i}))}function s(t,i){var e=t-i;switch(d.INTERNAL_ALIGNMENT){case"left":return[0,e];case"right":return[e,0];case"center":default:return[e/2,e/2]}}function o(t){return"string"==typeof t?new y(t):t}function a(t){for(var i=0;i\n"},r(c,u),c.prototype.m=function(t,i){return this.attrs.d+="m"+t+" "+i,this},c.prototype.h=function(t){return this.attrs.d+="h"+t,this},c.prototype.right=c.prototype.h,c.prototype.left=function(t){return this.h(-t)},c.prototype.v=function(t){return this.attrs.d+="v"+t,this},c.prototype.down=c.prototype.v,c.prototype.up=function(t){return this.v(-t)},c.prototype.arc=function(t){var i=d.ARC_RADIUS,e=d.ARC_RADIUS;if("e"!=t[0]&&"w"!=t[1]||(i*=-1),"s"!=t[0]&&"n"!=t[1]||(e*=-1),"ne"==t||"es"==t||"sw"==t||"wn"==t)var n=1;else n=0;return this.attrs.d+="a"+d.ARC_RADIUS+" "+d.ARC_RADIUS+" 0 0 "+n+" "+i+" "+e,this},c.prototype.format=function(){return this.attrs.d+="h.5",this},r(d,u),e)d[f]=e[f];function p(t){if(!(this instanceof p))return new p([].slice.call(arguments));if(u.call(this,"g"),a(t))throw new RangeError("Stack() must only occur at the very last position of Sequence().");this.items=t.map(o),this.width=this.items.reduce((function(t,i){return t+i.width+(i.needsSpace?20:0)}),0),this.offsetX=0,this.height=this.items.reduce((function(t,i){return t+i.height}),0),this.up=this.items.reduce((function(t,i){return Math.max(t,i.up)}),0),this.down=this.items.reduce((function(t,i){return Math.max(t,i.down)}),0)}function m(t){if(!(this instanceof m))return new m([].slice.call(arguments));if(u.call(this,"g"),a(t))throw new RangeError("Stack() must only occur at the very last position of Stack().");if(0===t.length)throw new RangeError("Stack() must have at least one child.");this.items=t.map(o),this.width=this.items.reduce((function(t,i){return Math.max(t,i.width+(i.needsSpace?20:0))}),0),this.items.length>1&&(this.width+=2*d.ARC_RADIUS),this.up=this.items[0].up,this.down=this.items[this.items.length-1].down,this.height=0;for(var i=0;i1&&(this.offsetX+=2*d.ARC_RADIUS))}function l(t,i){if(!(this instanceof l))return new l(t,[].slice.call(arguments,1));if(u.call(this,"g"),"number"!=typeof t||t!==Math.floor(t))throw new TypeError("The first argument of Choice() must be an integer.");if(t<0||t>=i.length)throw new RangeError("The first argument of Choice() must be an index for one of the items.");this.normal=t,this.items=i.map(o),this.width=this.items.reduce((function(t,i){return Math.max(t,i.width)}),0)+4*d.ARC_RADIUS,this.offsetX=0,this.height=this.items[t].height,this.up=this.down=0;for(var e=0;et&&(this.down+=Math.max(d.ARC_RADIUS,d.VERTICAL_SEPARATION+n.up+n.down+n.height))}}function g(t,i){if(void 0===i)return l(1,v(),t);if("skip"===i)return l(0,v(),t);throw"Unknown value for Optional()'s 'skip' argument."}function w(t,i){if(!(this instanceof w))return new w(t,i);u.call(this,"g"),i=i||new v,this.item=o(t),this.rep=o(i),this.width=Math.max(this.item.width,this.rep.width)+2*d.ARC_RADIUS,this.offsetX=0,this.height=this.item.height,this.up=this.item.up,this.down=Math.max(2*d.ARC_RADIUS,this.item.down+d.VERTICAL_SEPARATION+this.rep.up+this.rep.height+this.rep.down)}function A(t){if(!(this instanceof A))return new A;u.call(this,"path"),this.width=20,this.height=0,this.offsetX=0,this.up=10,this.down=10,this.simpleType=t}function R(t){if(!(this instanceof R))return new R;u.call(this,"path"),this.width=20,this.height=0,this.offsetX=0,this.up=10,this.down=10,this.simpleType=t}function y(t,i,e,n,r,h,s){if(!(this instanceof y))return new y(t,i,e,n,r,h,s);u.call(this,"g",{class:"terminal"}),this.text=t,this.label=t,this.href=i,this.title=e,this.occurrenceIdx=n,this.topRuleName=r,this.dslRuleName=h,this.tokenName=s,this.width=8*t.length+20,this.height=0,this.offsetX=0,this.up=11,this.down=11}function S(t,i,e,n){if(!(this instanceof S))return new S(t,i,e,n);u.call(this,"g",{class:"non-terminal"}),this.text=t,this.ruleName=t,this.href=i,this.occurrenceIdx=e,this.topRuleName=n,this.width=8*t.length+20,this.height=0,this.offsetX=0,this.up=11,this.down=11}function T(t){if(!(this instanceof T))return new T(t);u.call(this,"g"),this.text=t,this.width=7*t.length+10,this.height=0,this.offsetX=0,this.up=11,this.down=11}function v(){if(!(this instanceof v))return new v;u.call(this,"g"),this.width=0,this.height=0,this.offsetX=0,this.up=0,this.down=0}var I;d.prototype.format=function(t,i,e,n){t=h(t,20),i=h(i,t,20),e=h(e,t,20);var r=n=h(n,i,20),s=t;s+=this.up;for(var o=u("g",d.STROKE_ODD_PIXEL_LENGTH?{transform:"translate(.5 .5)"}:{}),a=0;a=0;o--){var a=this.items[o];if(o==this.normal-1)var u=Math.max(2*d.ARC_RADIUS,this.items[o+1].up+d.VERTICAL_SEPARATION+a.height+a.down);c(t,i).arc("se").up(u-2*d.ARC_RADIUS).arc("wn").addTo(this),a.format(t+2*d.ARC_RADIUS,i-u,h).addTo(this),c(t+2*d.ARC_RADIUS+h,i-u+a.height).arc("ne").down(u-a.height+this.items[this.normal].height-2*d.ARC_RADIUS).arc("ws").addTo(this),u+=Math.max(d.ARC_RADIUS,a.up+d.VERTICAL_SEPARATION+(0==o?0:this.items[o-1].down+this.items[o-1].height))}c(t,i).right(2*d.ARC_RADIUS).addTo(this),this.items[this.normal].format(t+2*d.ARC_RADIUS,i,h).addTo(this),c(t+2*d.ARC_RADIUS+h,i+this.height).right(2*d.ARC_RADIUS).addTo(this);for(o=this.normal+1;o<=r;o++){a=this.items[o];if(o==this.normal+1)u=Math.max(2*d.ARC_RADIUS,this.items[o-1].height+this.items[o-1].down+d.VERTICAL_SEPARATION+a.up);c(t,i).arc("ne").down(u-2*d.ARC_RADIUS).arc("ws").addTo(this),a.format(t+2*d.ARC_RADIUS,i+u,h).addTo(this),c(t+2*d.ARC_RADIUS+h,i+u+a.height).arc("se").up(u-2*d.ARC_RADIUS+a.height-this.items[this.normal].height).arc("wn").addTo(this),u+=Math.max(d.ARC_RADIUS,a.height+a.down+d.VERTICAL_SEPARATION+(o==r?0:this.items[o+1].up))}return this},r(w,u),w.prototype.needsSpace=!0,w.prototype.format=function(t,i,e){var n=s(e,this.width);c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i+this.height).h(n[1]).addTo(this),c(t+=n[0],i).right(d.ARC_RADIUS).addTo(this),this.item.format(t+d.ARC_RADIUS,i,this.width-2*d.ARC_RADIUS).addTo(this),c(t+this.width-d.ARC_RADIUS,i+this.height).right(d.ARC_RADIUS).addTo(this);var r=Math.max(2*d.ARC_RADIUS,this.item.height+this.item.down+d.VERTICAL_SEPARATION+this.rep.up);return c(t+d.ARC_RADIUS,i).arc("nw").down(r-2*d.ARC_RADIUS).arc("ws").addTo(this),this.rep.format(t+d.ARC_RADIUS,i+r,this.width-2*d.ARC_RADIUS).addTo(this),c(t+this.width-d.ARC_RADIUS,i+r+this.rep.height).arc("se").up(r-2*d.ARC_RADIUS+this.rep.height-this.item.height).arc("en").addTo(this),this},r(A,u),A.prototype.format=function(t,i){return!1===this.simpleType?this.attrs.d="M "+t+" "+(i-10)+" v 20 m 0 -10 h 20.5":this.attrs.d="M "+t+" "+(i-10)+" v 20 m 10 -20 v 20 m -10 -10 h 20.5",this},r(R,u),R.prototype.format=function(t,i){return!1===this.simpleType?this.attrs.d="M "+t+" "+i+" h 20 m 0 -10 v 20":this.attrs.d="M "+t+" "+i+" h 20 m -10 -10 v 20 m 10 -20 v 20",this},r(y,u),y.prototype.needsSpace=!0,y.prototype.format=function(t,i,e){var n=s(e,this.width);c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i).h(n[1]).addTo(this),u("rect",{x:t+=n[0],y:i-11,width:this.width,height:this.up+this.down,rx:10,ry:10}).addTo(this);var r=u("text",{x:t+this.width/2,y:i+4,occurrenceIdx:this.occurrenceIdx,topRuleName:this.topRuleName,dslRuleName:this.dslRuleName,tokenName:this.tokenName,label:this.label},this.text),h=u("title",{},this.title);return this.href?u("a",{"xlink:href":this.href},[r]).addTo(this):(r.addTo(this),void 0!==this.title&&h.addTo(this)),this},r(S,u),S.prototype.needsSpace=!0,S.prototype.format=function(t,i,e){var n=s(e,this.width);c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i).h(n[1]).addTo(this),u("rect",{x:t+=n[0],y:i-11,width:this.width,height:this.up+this.down}).addTo(this);var r=u("text",{x:t+this.width/2,y:i+4,occurrenceIdx:this.occurrenceIdx,topRuleName:this.topRuleName,ruleName:this.ruleName},this.text);return this.href?u("a",{"xlink:href":this.href},[r]).addTo(this):r.addTo(this),this},r(T,u),T.prototype.needsSpace=!0,T.prototype.format=function(t,i,e){var n=s(e,this.width);return c(t,i).h(n[0]).addTo(this),c(t+n[0]+this.width,i+this.height).h(n[1]).addTo(this),u("text",{x:(t+=n[0])+this.width/2,y:i+5,class:"comment"},this.text).addTo(this),this},r(v,u),v.prototype.format=function(t,i,e){return c(t,i).right(e).addTo(this),this},I={},void 0===(n=function(){return I}.apply(i,[]))||(t.exports=n);var E=[d,function(){var t=new d([].slice.call(arguments)),i=t.items;return i.shift(),i.pop(),i.unshift(new A(!1)),i.push(new R(!1)),t.items=i,t},p,m,l,g,w,function(t,i,e){return g(w(t,i),e)},y,S,T,v];["Diagram","ComplexDiagram","Sequence","Stack","Choice","Optional","OneOrMore","ZeroOrMore","Terminal","NonTerminal","Comment","Skip"].forEach((function(t,i){I[t]=E[i]}))}).call(this,{VERTICAL_SEPARATION:8,ARC_RADIUS:10,DIAGRAM_CLASS:"railroad-diagram",STROKE_ODD_PIXEL_LENGTH:!0,INTERNAL_ALIGNMENT:"center"})},305:function(t,i,e){"use strict";e(284)}}]); \ No newline at end of file diff --git a/assets/js/15.c708c53c.js b/assets/js/15.7a9c53e4.js similarity index 84% rename from assets/js/15.c708c53c.js rename to assets/js/15.7a9c53e4.js index ed4cd58f9..d34abe2ac 100644 --- a/assets/js/15.c708c53c.js +++ b/assets/js/15.7a9c53e4.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[15],{265:function(e,t,a){"use strict";var i=a(94),n=a(15);e.exports=function(e,t,a){return a.get&&i(a.get,t,{getter:!0}),a.set&&i(a.set,t,{setter:!0}),n.f(e,t,a)}},278:function(e,t,a){"use strict";var i=TypeError;e.exports=function(e,t){if(e({placeholder:void 0}),watch:{$lang(e){this.update(this.options,e)},options(e){this.update(e,this.$lang)}},mounted(){this.initialize(this.options,this.$lang),this.placeholder=this.$site.themeConfig.searchPlaceholder||""},methods:{initialize(e,t){Promise.all([Promise.all([a.e(0),a.e(10)]).then(a.t.bind(null,309,7)),Promise.all([a.e(0),a.e(10)]).then(a.t.bind(null,310,7))]).then(([a])=>{a=a.default;const{algoliaOptions:i={}}=e;a(Object.assign({},e,{inputSelector:"#algolia-search-input",algoliaOptions:{...i,facetFilters:["lang:"+t].concat(i.facetFilters||[])},handleSelected:(e,t,a)=>{const{pathname:i,hash:n}=new URL(a.url),r=i.replace(this.$site.base,"/"),s=decodeURIComponent(n);this.$router.push(`${r}${s}`)}}))})},update(e,t){this.$el.innerHTML='',this.initialize(e,t)}}},n=(a(292),a(14)),r=Object(n.a)(i,(function(){var e=this._self._c;return e("form",{staticClass:"algolia-search-wrapper search-box",attrs:{id:"search-form",role:"search"}},[e("input",{staticClass:"search-query",attrs:{id:"algolia-search-input",placeholder:this.placeholder}})])}),[],!1,null,null,null);t.default=r.exports}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[15],{265:function(e,t,a){"use strict";var i=a(93),n=a(15);e.exports=function(e,t,a){return a.get&&i(a.get,t,{getter:!0}),a.set&&i(a.set,t,{setter:!0}),n.f(e,t,a)}},278:function(e,t,a){"use strict";var i=TypeError;e.exports=function(e,t){if(e({placeholder:void 0}),watch:{$lang(e){this.update(this.options,e)},options(e){this.update(e,this.$lang)}},mounted(){this.initialize(this.options,this.$lang),this.placeholder=this.$site.themeConfig.searchPlaceholder||""},methods:{initialize(e,t){Promise.all([Promise.all([a.e(0),a.e(10)]).then(a.t.bind(null,308,7)),Promise.all([a.e(0),a.e(10)]).then(a.t.bind(null,309,7))]).then(([a])=>{a=a.default;const{algoliaOptions:i={}}=e;a(Object.assign({},e,{inputSelector:"#algolia-search-input",algoliaOptions:{...i,facetFilters:["lang:"+t].concat(i.facetFilters||[])},handleSelected:(e,t,a)=>{const{pathname:i,hash:n}=new URL(a.url),r=i.replace(this.$site.base,"/"),s=decodeURIComponent(n);this.$router.push(`${r}${s}`)}}))})},update(e,t){this.$el.innerHTML='',this.initialize(e,t)}}},n=(a(292),a(14)),r=Object(n.a)(i,(function(){var e=this._self._c;return e("form",{staticClass:"algolia-search-wrapper search-box",attrs:{id:"search-form",role:"search"}},[e("input",{staticClass:"search-query",attrs:{id:"algolia-search-input",placeholder:this.placeholder}})])}),[],!1,null,null,null);t.default=r.exports}}]); \ No newline at end of file diff --git a/assets/js/16.23c3033b.js b/assets/js/16.e1d3bb5c.js similarity index 98% rename from assets/js/16.23c3033b.js rename to assets/js/16.e1d3bb5c.js index 994b5d0e4..f03736ad1 100644 --- a/assets/js/16.23c3033b.js +++ b/assets/js/16.e1d3bb5c.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[16,22,24],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return s})),n.d(e,"i",(function(){return o})),n.d(e,"f",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"b",(function(){return p})),n.d(e,"e",(function(){return f})),n.d(e,"k",(function(){return h})),n.d(e,"l",(function(){return d})),n.d(e,"c",(function(){return b})),n.d(e,"j",(function(){return g}));n(90);const i=/#.*$/,r=/\.(md|html)$/,s=/\/$/,o=/^[a-z]+:/i;function a(t){return decodeURI(t).replace(i,"").replace(r,"")}function l(t){return o.test(t)}function u(t){return/^mailto:/.test(t)}function c(t){return/^tel:/.test(t)}function p(t){if(l(t))return t;const e=t.match(i),n=e?e[0]:"",r=a(t);return s.test(r)?t:r+".html"+n}function f(t,e){const n=decodeURIComponent(t.hash),r=function(t){const e=t.match(i);if(e)return e[0]}(e);if(r&&n!==r)return!1;return a(t.path)===a(e)}function h(t,e,n){if(l(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const r=e.split("/");n&&r[r.length-1]||r.pop();const s=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,r=1){if("string"==typeof e)return h(n,e,i);if(Array.isArray(e))return Object.assign(h(n,e[0],i),{title:e[1]});{const s=e.children||[];return 0===s.length&&e.path?Object.assign(h(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:s.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function m(t){const e=b(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function b(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function g(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),r={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},s=n(14),o=Object(s.a)(r,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=o.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},r=(n(242),n(14)),s=Object(r.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=s.exports},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),r=n(244),s=n(91),o=n.n(s),a={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:r.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>o()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(a,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[16,22,24],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return s})),n.d(e,"i",(function(){return o})),n.d(e,"f",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"b",(function(){return p})),n.d(e,"e",(function(){return f})),n.d(e,"k",(function(){return h})),n.d(e,"l",(function(){return d})),n.d(e,"c",(function(){return b})),n.d(e,"j",(function(){return g}));n(89);const i=/#.*$/,r=/\.(md|html)$/,s=/\/$/,o=/^[a-z]+:/i;function a(t){return decodeURI(t).replace(i,"").replace(r,"")}function l(t){return o.test(t)}function u(t){return/^mailto:/.test(t)}function c(t){return/^tel:/.test(t)}function p(t){if(l(t))return t;const e=t.match(i),n=e?e[0]:"",r=a(t);return s.test(r)?t:r+".html"+n}function f(t,e){const n=decodeURIComponent(t.hash),r=function(t){const e=t.match(i);if(e)return e[0]}(e);if(r&&n!==r)return!1;return a(t.path)===a(e)}function h(t,e,n){if(l(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const r=e.split("/");n&&r[r.length-1]||r.pop();const s=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,r=1){if("string"==typeof e)return h(n,e,i);if(Array.isArray(e))return Object.assign(h(n,e[0],i),{title:e[1]});{const s=e.children||[];return 0===s.length&&e.path?Object.assign(h(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:s.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function m(t){const e=b(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function b(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function g(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},240:function(t,e,n){},241:function(t,e,n){"use strict";n.r(e);var i=n(239),r={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},s=n(14),o=Object(s.a)(r,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=o.exports},242:function(t,e,n){"use strict";n(240)},243:function(t,e,n){},244:function(t,e,n){"use strict";n.r(e);var i={name:"DropdownTransition",methods:{setHeight(t){t.style.height=t.scrollHeight+"px"},unsetHeight(t){t.style.height=""}}},r=(n(242),n(14)),s=Object(r.a)(i,(function(){return(0,this._self._c)("transition",{attrs:{name:"dropdown"},on:{enter:this.setHeight,"after-enter":this.unsetHeight,"before-leave":this.setHeight}},[this._t("default")],2)}),[],!1,null,null,null);e.default=s.exports},251:function(t,e,n){"use strict";n(243)},252:function(t,e,n){"use strict";n.r(e);var i=n(241),r=n(244),s=n(90),o=n.n(s),a={name:"DropdownLink",components:{NavLink:i.default,DropdownTransition:r.default},props:{item:{required:!0}},data:()=>({open:!1}),computed:{dropdownAriaLabel(){return this.item.ariaLabel||this.item.text}},watch:{$route(){this.open=!1}},methods:{setOpen(t){this.open=t},isLastItemOfArray:(t,e)=>o()(e)===t,handleDropdown(){0===event.detail&&this.setOpen(!this.open)}}},l=(n(251),n(14)),u=Object(l.a)(a,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"dropdown-wrapper",class:{open:t.open}},[e("button",{staticClass:"dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:t.handleDropdown}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow down"})]),t._v(" "),e("button",{staticClass:"mobile-dropdown-title",attrs:{type:"button","aria-label":t.dropdownAriaLabel},on:{click:function(e){return t.setOpen(!t.open)}}},[e("span",{staticClass:"title"},[t._v(t._s(t.item.text))]),t._v(" "),e("span",{staticClass:"arrow",class:t.open?"down":"right"})]),t._v(" "),e("DropdownTransition",[e("ul",{directives:[{name:"show",rawName:"v-show",value:t.open,expression:"open"}],staticClass:"nav-dropdown"},t._l(t.item.items,(function(n,i){return e("li",{key:n.link||i,staticClass:"dropdown-item"},["links"===n.type?e("h4",[t._v("\n "+t._s(n.text)+"\n ")]):t._e(),t._v(" "),"links"===n.type?e("ul",{staticClass:"dropdown-subitem-wrapper"},t._l(n.items,(function(i){return e("li",{key:i.link,staticClass:"dropdown-subitem"},[e("NavLink",{attrs:{item:i},on:{focusout:function(e){t.isLastItemOfArray(i,n.items)&&t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0):e("NavLink",{attrs:{item:n},on:{focusout:function(e){t.isLastItemOfArray(n,t.item.items)&&t.setOpen(!1)}}})],1)})),0)])],1)}),[],!1,null,null,null);e.default=u.exports}}]); \ No newline at end of file diff --git a/assets/js/17.6cecb61e.js b/assets/js/17.c2ea0a37.js similarity index 97% rename from assets/js/17.6cecb61e.js rename to assets/js/17.c2ea0a37.js index b98b15cbb..940c82763 100644 --- a/assets/js/17.6cecb61e.js +++ b/assets/js/17.c2ea0a37.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[17],{239:function(t,n,e){"use strict";e.d(n,"d",(function(){return r})),e.d(n,"a",(function(){return o})),e.d(n,"i",(function(){return a})),e.d(n,"f",(function(){return u})),e.d(n,"g",(function(){return c})),e.d(n,"h",(function(){return p})),e.d(n,"b",(function(){return l})),e.d(n,"e",(function(){return f})),e.d(n,"k",(function(){return h})),e.d(n,"l",(function(){return d})),e.d(n,"c",(function(){return v})),e.d(n,"j",(function(){return b}));e(90);const r=/#.*$/,i=/\.(md|html)$/,o=/\/$/,a=/^[a-z]+:/i;function s(t){return decodeURI(t).replace(r,"").replace(i,"")}function u(t){return a.test(t)}function c(t){return/^mailto:/.test(t)}function p(t){return/^tel:/.test(t)}function l(t){if(u(t))return t;const n=t.match(r),e=n?n[0]:"",i=s(t);return o.test(i)?t:i+".html"+e}function f(t,n){const e=decodeURIComponent(t.hash),i=function(t){const n=t.match(r);if(n)return n[0]}(n);if(i&&e!==i)return!1;return s(t.path)===s(n)}function h(t,n,e){if(u(n))return{type:"external",path:n};e&&(n=function(t,n,e){const r=t.charAt(0);if("/"===r)return t;if("?"===r||"#"===r)return n+t;const i=n.split("/");e&&i[i.length-1]||i.pop();const o=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(n,e,r,i=1){if("string"==typeof n)return h(e,n,r);if(Array.isArray(n))return Object.assign(h(e,n[0],r),{title:n[1]});{const o=n.children||[];return 0===o.length&&n.path?Object.assign(h(e,n.path,r),{title:n.title}):{type:"group",path:n.path,title:n.title,sidebarDepth:n.sidebarDepth,initialOpenGroupIndex:n.initialOpenGroupIndex,children:o.map(n=>t(n,e,r,i+1)),collapsable:!1!==n.collapsable}}}(t,i,e)):[]}return[]}function g(t){const n=v(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:n.map(n=>({type:"auto",title:n.title,basePath:t.path,path:t.path+"#"+n.slug,children:n.children||[]}))}]}function v(t){let n;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?n=t:n&&(n.children||(n.children=[])).push(t)}),t.filter(t=>2===t.level)}function b(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},245:function(t,n){t.exports=function(t){return null==t}},249:function(t,n,e){},259:function(t,n,e){var r=e(11),i=e(5),o=e(10);t.exports=function(t){return"string"==typeof t||!i(t)&&o(t)&&"[object String]"==r(t)}},260:function(t,n,e){"use strict";e(249)},267:function(t,n,e){"use strict";e.r(n);e(90);var r=e(239),i=e(259),o=e.n(i),a=e(245),s=e.n(a),u={name:"PageNav",props:["sidebarItems"],computed:{prev(){return p(c.PREV,this)},next(){return p(c.NEXT,this)}}};const c={NEXT:{resolveLink:function(t,n){return l(t,n,1)},getThemeLinkConfig:({nextLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.next},PREV:{resolveLink:function(t,n){return l(t,n,-1)},getThemeLinkConfig:({prevLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.prev}};function p(t,{$themeConfig:n,$page:e,$route:i,$site:a,sidebarItems:u}){const{resolveLink:c,getThemeLinkConfig:p,getPageLinkConfig:l}=t,f=p(n),h=l(e),d=s()(h)?f:h;return!1===d?void 0:o()(d)?Object(r.k)(a.pages,d,i.path):c(e,u)}function l(t,n,e){const r=[];!function t(n,e){for(let r=0,i=n.length;rfunction t(n,e,r,i=1){if("string"==typeof n)return h(e,n,r);if(Array.isArray(n))return Object.assign(h(e,n[0],r),{title:n[1]});{const o=n.children||[];return 0===o.length&&n.path?Object.assign(h(e,n.path,r),{title:n.title}):{type:"group",path:n.path,title:n.title,sidebarDepth:n.sidebarDepth,initialOpenGroupIndex:n.initialOpenGroupIndex,children:o.map(n=>t(n,e,r,i+1)),collapsable:!1!==n.collapsable}}}(t,i,e)):[]}return[]}function g(t){const n=v(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:n.map(n=>({type:"auto",title:n.title,basePath:t.path,path:t.path+"#"+n.slug,children:n.children||[]}))}]}function v(t){let n;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?n=t:n&&(n.children||(n.children=[])).push(t)}),t.filter(t=>2===t.level)}function b(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},245:function(t,n){t.exports=function(t){return null==t}},249:function(t,n,e){},259:function(t,n,e){var r=e(11),i=e(5),o=e(10);t.exports=function(t){return"string"==typeof t||!i(t)&&o(t)&&"[object String]"==r(t)}},260:function(t,n,e){"use strict";e(249)},267:function(t,n,e){"use strict";e.r(n);e(89);var r=e(239),i=e(259),o=e.n(i),a=e(245),s=e.n(a),u={name:"PageNav",props:["sidebarItems"],computed:{prev(){return p(c.PREV,this)},next(){return p(c.NEXT,this)}}};const c={NEXT:{resolveLink:function(t,n){return l(t,n,1)},getThemeLinkConfig:({nextLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.next},PREV:{resolveLink:function(t,n){return l(t,n,-1)},getThemeLinkConfig:({prevLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.prev}};function p(t,{$themeConfig:n,$page:e,$route:i,$site:a,sidebarItems:u}){const{resolveLink:c,getThemeLinkConfig:p,getPageLinkConfig:l}=t,f=p(n),h=l(e),d=s()(h)?f:h;return!1===d?void 0:o()(d)?Object(r.k)(a.pages,d,i.path):c(e,u)}function l(t,n,e){const r=[];!function t(n,e){for(let r=0,i=n.length;rfunction t(e,n,i,r=1){if("string"==typeof e)return d(n,e,i);if(Array.isArray(e))return Object.assign(d(n,e[0],i),{title:e[1]});{const a=e.children||[];return 0===a.length&&e.path?Object.assign(d(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:a.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function m(t){const e=g(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function g(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function b(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},241:function(t,e,n){"use strict";n.r(e);var i=n(239),r={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},a=n(14),s=Object(a.a)(r,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=s.exports},253:function(t,e,n){},271:function(t,e,n){"use strict";n(253)},287:function(t,e,n){"use strict";n.r(e);var i={name:"Home",components:{NavLink:n(241).default},computed:{data(){return this.$page.frontmatter},actionLink(){return{link:this.data.actionLink,text:this.data.actionText}}}},r=(n(271),n(14)),a=Object(r.a)(i,(function(){var t=this,e=t._self._c;return e("main",{staticClass:"home",attrs:{"aria-labelledby":null!==t.data.heroText?"main-title":null}},[e("header",{staticClass:"hero"},[t.data.heroImage?e("img",{attrs:{src:t.$withBase(t.data.heroImage),alt:t.data.heroAlt||"hero"}}):t._e(),t._v(" "),null!==t.data.heroText?e("h1",{attrs:{id:"main-title"}},[t._v("\n "+t._s(t.data.heroText||t.$title||"Hello")+"\n ")]):t._e(),t._v(" "),null!==t.data.tagline?e("p",{staticClass:"description"},[t._v("\n "+t._s(t.data.tagline||t.$description||"Welcome to your VuePress site")+"\n ")]):t._e(),t._v(" "),t.data.actionText&&t.data.actionLink?e("p",{staticClass:"action"},[e("NavLink",{staticClass:"action-button",attrs:{item:t.actionLink}})],1):t._e()]),t._v(" "),t.data.features&&t.data.features.length?e("div",{staticClass:"features"},t._l(t.data.features,(function(n,i){return e("div",{key:i,staticClass:"feature"},[e("h2",[t._v(t._s(n.title))]),t._v(" "),e("p",[t._v(t._s(n.details))])])})),0):t._e(),t._v(" "),e("Content",{staticClass:"theme-default-content custom"}),t._v(" "),t.data.footer?e("div",{staticClass:"footer"},[t._v("\n "+t._s(t.data.footer)+"\n ")]):e("Content",{staticClass:"footer",attrs:{"slot-key":"footer"}})],1)}),[],!1,null,null,null);e.default=a.exports}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[18,24],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return a})),n.d(e,"i",(function(){return s})),n.d(e,"f",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return c})),n.d(e,"b",(function(){return f})),n.d(e,"e",(function(){return h})),n.d(e,"k",(function(){return d})),n.d(e,"l",(function(){return p})),n.d(e,"c",(function(){return g})),n.d(e,"j",(function(){return b}));n(89);const i=/#.*$/,r=/\.(md|html)$/,a=/\/$/,s=/^[a-z]+:/i;function o(t){return decodeURI(t).replace(i,"").replace(r,"")}function l(t){return s.test(t)}function u(t){return/^mailto:/.test(t)}function c(t){return/^tel:/.test(t)}function f(t){if(l(t))return t;const e=t.match(i),n=e?e[0]:"",r=o(t);return a.test(r)?t:r+".html"+n}function h(t,e){const n=decodeURIComponent(t.hash),r=function(t){const e=t.match(i);if(e)return e[0]}(e);if(r&&n!==r)return!1;return o(t.path)===o(e)}function d(t,e,n){if(l(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const r=e.split("/");n&&r[r.length-1]||r.pop();const a=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,r=1){if("string"==typeof e)return d(n,e,i);if(Array.isArray(e))return Object.assign(d(n,e[0],i),{title:e[1]});{const a=e.children||[];return 0===a.length&&e.path?Object.assign(d(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:a.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function m(t){const e=g(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function g(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function b(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},241:function(t,e,n){"use strict";n.r(e);var i=n(239),r={name:"NavLink",props:{item:{required:!0}},computed:{link(){return Object(i.b)(this.item.link)},exact(){return this.$site.locales?Object.keys(this.$site.locales).some(t=>t===this.link):"/"===this.link},isNonHttpURI(){return Object(i.g)(this.link)||Object(i.h)(this.link)},isBlankTarget(){return"_blank"===this.target},isInternal(){return!Object(i.f)(this.link)&&!this.isBlankTarget},target(){return this.isNonHttpURI?null:this.item.target?this.item.target:Object(i.f)(this.link)?"_blank":""},rel(){return this.isNonHttpURI||!1===this.item.rel?null:this.item.rel?this.item.rel:this.isBlankTarget?"noopener noreferrer":null}},methods:{focusoutAction(){this.$emit("focusout")}}},a=n(14),s=Object(a.a)(r,(function(){var t=this,e=t._self._c;return t.isInternal?e("RouterLink",{staticClass:"nav-link",attrs:{to:t.link,exact:t.exact},nativeOn:{focusout:function(e){return t.focusoutAction.apply(null,arguments)}}},[t._v("\n "+t._s(t.item.text)+"\n")]):e("a",{staticClass:"nav-link external",attrs:{href:t.link,target:t.target,rel:t.rel},on:{focusout:t.focusoutAction}},[t._v("\n "+t._s(t.item.text)+"\n "),t.isBlankTarget?e("OutboundLink"):t._e()],1)}),[],!1,null,null,null);e.default=s.exports},253:function(t,e,n){},271:function(t,e,n){"use strict";n(253)},287:function(t,e,n){"use strict";n.r(e);var i={name:"Home",components:{NavLink:n(241).default},computed:{data(){return this.$page.frontmatter},actionLink(){return{link:this.data.actionLink,text:this.data.actionText}}}},r=(n(271),n(14)),a=Object(r.a)(i,(function(){var t=this,e=t._self._c;return e("main",{staticClass:"home",attrs:{"aria-labelledby":null!==t.data.heroText?"main-title":null}},[e("header",{staticClass:"hero"},[t.data.heroImage?e("img",{attrs:{src:t.$withBase(t.data.heroImage),alt:t.data.heroAlt||"hero"}}):t._e(),t._v(" "),null!==t.data.heroText?e("h1",{attrs:{id:"main-title"}},[t._v("\n "+t._s(t.data.heroText||t.$title||"Hello")+"\n ")]):t._e(),t._v(" "),null!==t.data.tagline?e("p",{staticClass:"description"},[t._v("\n "+t._s(t.data.tagline||t.$description||"Welcome to your VuePress site")+"\n ")]):t._e(),t._v(" "),t.data.actionText&&t.data.actionLink?e("p",{staticClass:"action"},[e("NavLink",{staticClass:"action-button",attrs:{item:t.actionLink}})],1):t._e()]),t._v(" "),t.data.features&&t.data.features.length?e("div",{staticClass:"features"},t._l(t.data.features,(function(n,i){return e("div",{key:i,staticClass:"feature"},[e("h2",[t._v(t._s(n.title))]),t._v(" "),e("p",[t._v(t._s(n.details))])])})),0):t._e(),t._v(" "),e("Content",{staticClass:"theme-default-content custom"}),t._v(" "),t.data.footer?e("div",{staticClass:"footer"},[t._v("\n "+t._s(t.data.footer)+"\n ")]):e("Content",{staticClass:"footer",attrs:{"slot-key":"footer"}})],1)}),[],!1,null,null,null);e.default=a.exports}}]); \ No newline at end of file diff --git a/assets/js/19.6a236fad.js b/assets/js/19.d5ecdc39.js similarity index 98% rename from assets/js/19.6a236fad.js rename to assets/js/19.d5ecdc39.js index 62272c7dd..d5ad954a2 100644 --- a/assets/js/19.6a236fad.js +++ b/assets/js/19.d5ecdc39.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[19],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return a})),n.d(e,"i",(function(){return s})),n.d(e,"f",(function(){return c})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return l})),n.d(e,"b",(function(){return d})),n.d(e,"e",(function(){return p})),n.d(e,"k",(function(){return f})),n.d(e,"l",(function(){return h})),n.d(e,"c",(function(){return m})),n.d(e,"j",(function(){return b}));n(90);const i=/#.*$/,r=/\.(md|html)$/,a=/\/$/,s=/^[a-z]+:/i;function o(t){return decodeURI(t).replace(i,"").replace(r,"")}function c(t){return s.test(t)}function u(t){return/^mailto:/.test(t)}function l(t){return/^tel:/.test(t)}function d(t){if(c(t))return t;const e=t.match(i),n=e?e[0]:"",r=o(t);return a.test(r)?t:r+".html"+n}function p(t,e){const n=decodeURIComponent(t.hash),r=function(t){const e=t.match(i);if(e)return e[0]}(e);if(r&&n!==r)return!1;return o(t.path)===o(e)}function f(t,e,n){if(c(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const r=e.split("/");n&&r[r.length-1]||r.pop();const a=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,r=1){if("string"==typeof e)return f(n,e,i);if(Array.isArray(e))return Object.assign(f(n,e[0],i),{title:e[1]});{const a=e.children||[];return 0===a.length&&e.path?Object.assign(f(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:a.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function g(t){const e=m(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function m(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function b(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},245:function(t,e){t.exports=function(t){return null==t}},248:function(t,e,n){},258:function(t,e,n){"use strict";n(248)},266:function(t,e,n){"use strict";n.r(e);var i=n(245),r=n.n(i),a=n(239),s={name:"PageEdit",computed:{lastUpdated(){return this.$page.lastUpdated},lastUpdatedText(){return"string"==typeof this.$themeLocaleConfig.lastUpdated?this.$themeLocaleConfig.lastUpdated:"string"==typeof this.$site.themeConfig.lastUpdated?this.$site.themeConfig.lastUpdated:"Last Updated"},editLink(){const t=r()(this.$page.frontmatter.editLink)?this.$site.themeConfig.editLinks:this.$page.frontmatter.editLink,{repo:e,docsDir:n="",docsBranch:i="master",docsRepo:a=e}=this.$site.themeConfig;return t&&a&&this.$page.relativePath?this.createEditLink(e,a,n,i,this.$page.relativePath):null},editLinkText(){return this.$themeLocaleConfig.editLinkText||this.$site.themeConfig.editLinkText||"Edit this page"}},methods:{createEditLink(t,e,n,i,r){if(/bitbucket.org/.test(e)){return e.replace(a.a,"")+"/src"+`/${i}/`+(n?n.replace(a.a,"")+"/":"")+r+`?mode=edit&spa=0&at=${i}&fileviewer=file-view-default`}if(/gitlab.com/.test(e)){return e.replace(a.a,"")+"/-/edit"+`/${i}/`+(n?n.replace(a.a,"")+"/":"")+r}return(a.i.test(e)?e:"https://github.com/"+e).replace(a.a,"")+"/edit"+`/${i}/`+(n?n.replace(a.a,"")+"/":"")+r}}},o=(n(258),n(14)),c=Object(o.a)(s,(function(){var t=this,e=t._self._c;return e("footer",{staticClass:"page-edit"},[t.editLink?e("div",{staticClass:"edit-link"},[e("a",{attrs:{href:t.editLink,target:"_blank",rel:"noopener noreferrer"}},[t._v(t._s(t.editLinkText))]),t._v(" "),e("OutboundLink")],1):t._e(),t._v(" "),t.lastUpdated?e("div",{staticClass:"last-updated"},[e("span",{staticClass:"prefix"},[t._v(t._s(t.lastUpdatedText)+":")]),t._v(" "),e("span",{staticClass:"time"},[t._v(t._s(t.lastUpdated))])]):t._e()])}),[],!1,null,null,null);e.default=c.exports}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[19],{239:function(t,e,n){"use strict";n.d(e,"d",(function(){return i})),n.d(e,"a",(function(){return a})),n.d(e,"i",(function(){return s})),n.d(e,"f",(function(){return c})),n.d(e,"g",(function(){return u})),n.d(e,"h",(function(){return l})),n.d(e,"b",(function(){return d})),n.d(e,"e",(function(){return p})),n.d(e,"k",(function(){return f})),n.d(e,"l",(function(){return h})),n.d(e,"c",(function(){return m})),n.d(e,"j",(function(){return b}));n(89);const i=/#.*$/,r=/\.(md|html)$/,a=/\/$/,s=/^[a-z]+:/i;function o(t){return decodeURI(t).replace(i,"").replace(r,"")}function c(t){return s.test(t)}function u(t){return/^mailto:/.test(t)}function l(t){return/^tel:/.test(t)}function d(t){if(c(t))return t;const e=t.match(i),n=e?e[0]:"",r=o(t);return a.test(r)?t:r+".html"+n}function p(t,e){const n=decodeURIComponent(t.hash),r=function(t){const e=t.match(i);if(e)return e[0]}(e);if(r&&n!==r)return!1;return o(t.path)===o(e)}function f(t,e,n){if(c(e))return{type:"external",path:e};n&&(e=function(t,e,n){const i=t.charAt(0);if("/"===i)return t;if("?"===i||"#"===i)return e+t;const r=e.split("/");n&&r[r.length-1]||r.pop();const a=t.replace(/^\//,"").split("/");for(let t=0;tfunction t(e,n,i,r=1){if("string"==typeof e)return f(n,e,i);if(Array.isArray(e))return Object.assign(f(n,e[0],i),{title:e[1]});{const a=e.children||[];return 0===a.length&&e.path?Object.assign(f(n,e.path,i),{title:e.title}):{type:"group",path:e.path,title:e.title,sidebarDepth:e.sidebarDepth,initialOpenGroupIndex:e.initialOpenGroupIndex,children:a.map(e=>t(e,n,i,r+1)),collapsable:!1!==e.collapsable}}}(t,r,n)):[]}return[]}function g(t){const e=m(t.headers||[]);return[{type:"group",collapsable:!1,title:t.title,path:null,children:e.map(e=>({type:"auto",title:e.title,basePath:t.path,path:t.path+"#"+e.slug,children:e.children||[]}))}]}function m(t){let e;return(t=t.map(t=>Object.assign({},t))).forEach(t=>{2===t.level?e=t:e&&(e.children||(e.children=[])).push(t)}),t.filter(t=>2===t.level)}function b(t){return Object.assign(t,{type:t.items&&t.items.length?"links":"link"})}},245:function(t,e){t.exports=function(t){return null==t}},248:function(t,e,n){},258:function(t,e,n){"use strict";n(248)},266:function(t,e,n){"use strict";n.r(e);var i=n(245),r=n.n(i),a=n(239),s={name:"PageEdit",computed:{lastUpdated(){return this.$page.lastUpdated},lastUpdatedText(){return"string"==typeof this.$themeLocaleConfig.lastUpdated?this.$themeLocaleConfig.lastUpdated:"string"==typeof this.$site.themeConfig.lastUpdated?this.$site.themeConfig.lastUpdated:"Last Updated"},editLink(){const t=r()(this.$page.frontmatter.editLink)?this.$site.themeConfig.editLinks:this.$page.frontmatter.editLink,{repo:e,docsDir:n="",docsBranch:i="master",docsRepo:a=e}=this.$site.themeConfig;return t&&a&&this.$page.relativePath?this.createEditLink(e,a,n,i,this.$page.relativePath):null},editLinkText(){return this.$themeLocaleConfig.editLinkText||this.$site.themeConfig.editLinkText||"Edit this page"}},methods:{createEditLink(t,e,n,i,r){if(/bitbucket.org/.test(e)){return e.replace(a.a,"")+"/src"+`/${i}/`+(n?n.replace(a.a,"")+"/":"")+r+`?mode=edit&spa=0&at=${i}&fileviewer=file-view-default`}if(/gitlab.com/.test(e)){return e.replace(a.a,"")+"/-/edit"+`/${i}/`+(n?n.replace(a.a,"")+"/":"")+r}return(a.i.test(e)?e:"https://github.com/"+e).replace(a.a,"")+"/edit"+`/${i}/`+(n?n.replace(a.a,"")+"/":"")+r}}},o=(n(258),n(14)),c=Object(o.a)(s,(function(){var t=this,e=t._self._c;return e("footer",{staticClass:"page-edit"},[t.editLink?e("div",{staticClass:"edit-link"},[e("a",{attrs:{href:t.editLink,target:"_blank",rel:"noopener noreferrer"}},[t._v(t._s(t.editLinkText))]),t._v(" "),e("OutboundLink")],1):t._e(),t._v(" "),t.lastUpdated?e("div",{staticClass:"last-updated"},[e("span",{staticClass:"prefix"},[t._v(t._s(t.lastUpdatedText)+":")]),t._v(" "),e("span",{staticClass:"time"},[t._v(t._s(t.lastUpdated))])]):t._e()])}),[],!1,null,null,null);e.default=c.exports}}]); \ No newline at end of file diff --git a/assets/js/2.983881db.js b/assets/js/2.41e4d318.js similarity index 98% rename from assets/js/2.983881db.js rename to assets/js/2.41e4d318.js index 070df3bb4..b32872b5a 100644 --- a/assets/js/2.983881db.js +++ b/assets/js/2.41e4d318.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[2,23],{245:function(t,e){t.exports=function(t){return null==t}},247:function(t,e,a){},248:function(t,e,a){},249:function(t,e,a){},253:function(t,e,a){},256:function(t,e,a){"use strict";a(247)},257:function(t,e,a){},258:function(t,e,a){"use strict";a(248)},259:function(t,e,a){var i=a(11),n=a(5),s=a(10);t.exports=function(t){return"string"==typeof t||!n(t)&&s(t)&&"[object String]"==i(t)}},260:function(t,e,a){"use strict";a(249)},261:function(t,e,a){},266:function(t,e,a){"use strict";a.r(e);var i=a(245),n=a.n(i),s=a(239),r={name:"PageEdit",computed:{lastUpdated(){return this.$page.lastUpdated},lastUpdatedText(){return"string"==typeof this.$themeLocaleConfig.lastUpdated?this.$themeLocaleConfig.lastUpdated:"string"==typeof this.$site.themeConfig.lastUpdated?this.$site.themeConfig.lastUpdated:"Last Updated"},editLink(){const t=n()(this.$page.frontmatter.editLink)?this.$site.themeConfig.editLinks:this.$page.frontmatter.editLink,{repo:e,docsDir:a="",docsBranch:i="master",docsRepo:s=e}=this.$site.themeConfig;return t&&s&&this.$page.relativePath?this.createEditLink(e,s,a,i,this.$page.relativePath):null},editLinkText(){return this.$themeLocaleConfig.editLinkText||this.$site.themeConfig.editLinkText||"Edit this page"}},methods:{createEditLink(t,e,a,i,n){if(/bitbucket.org/.test(e)){return e.replace(s.a,"")+"/src"+`/${i}/`+(a?a.replace(s.a,"")+"/":"")+n+`?mode=edit&spa=0&at=${i}&fileviewer=file-view-default`}if(/gitlab.com/.test(e)){return e.replace(s.a,"")+"/-/edit"+`/${i}/`+(a?a.replace(s.a,"")+"/":"")+n}return(s.i.test(e)?e:"https://github.com/"+e).replace(s.a,"")+"/edit"+`/${i}/`+(a?a.replace(s.a,"")+"/":"")+n}}},o=(a(258),a(14)),l=Object(o.a)(r,(function(){var t=this,e=t._self._c;return e("footer",{staticClass:"page-edit"},[t.editLink?e("div",{staticClass:"edit-link"},[e("a",{attrs:{href:t.editLink,target:"_blank",rel:"noopener noreferrer"}},[t._v(t._s(t.editLinkText))]),t._v(" "),e("OutboundLink")],1):t._e(),t._v(" "),t.lastUpdated?e("div",{staticClass:"last-updated"},[e("span",{staticClass:"prefix"},[t._v(t._s(t.lastUpdatedText)+":")]),t._v(" "),e("span",{staticClass:"time"},[t._v(t._s(t.lastUpdated))])]):t._e()])}),[],!1,null,null,null);e.default=l.exports},267:function(t,e,a){"use strict";a.r(e);a(90);var i=a(239),n=a(259),s=a.n(n),r=a(245),o=a.n(r),l={name:"PageNav",props:["sidebarItems"],computed:{prev(){return u(c.PREV,this)},next(){return u(c.NEXT,this)}}};const c={NEXT:{resolveLink:function(t,e){return d(t,e,1)},getThemeLinkConfig:({nextLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.next},PREV:{resolveLink:function(t,e){return d(t,e,-1)},getThemeLinkConfig:({prevLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.prev}};function u(t,{$themeConfig:e,$page:a,$route:n,$site:r,sidebarItems:l}){const{resolveLink:c,getThemeLinkConfig:u,getPageLinkConfig:d}=t,h=u(e),p=d(a),f=o()(p)?h:p;return!1===f?void 0:s()(f)?Object(i.k)(r.pages,f,n.path):c(a,l)}function d(t,e,a){const i=[];!function t(e,a){for(let i=0,n=e.length;i({linksWrapMaxWidth:null}),computed:{algolia(){return this.$themeLocaleConfig.algolia||this.$site.themeConfig.algolia||{}},isAlgoliaSearch(){return this.algolia&&this.algolia.apiKey&&this.algolia.indexName}},mounted(){const t=parseInt(r(this.$el,"paddingLeft"))+parseInt(r(this.$el,"paddingRight")),e=()=>{document.documentElement.clientWidth<719?this.linksWrapMaxWidth=null:this.linksWrapMaxWidth=this.$el.offsetWidth-t-(this.$refs.siteName&&this.$refs.siteName.offsetWidth||0)};e(),window.addEventListener("resize",e,!1)}},l=(a(273),a(14)),c=Object(l.a)(o,(function(){var t=this,e=t._self._c;return e("header",{staticClass:"navbar"},[e("SidebarButton",{on:{"toggle-sidebar":function(e){return t.$emit("toggle-sidebar")}}}),t._v(" "),e("RouterLink",{staticClass:"home-link",attrs:{to:t.$localePath}},[t.$site.themeConfig.logo?e("img",{staticClass:"logo",attrs:{src:t.$withBase(t.$site.themeConfig.logo),alt:t.$siteTitle}}):t._e(),t._v(" "),t.$siteTitle?e("span",{ref:"siteName",staticClass:"site-name",class:{"can-hide":t.$site.themeConfig.logo}},[t._v(t._s(t.$siteTitle))]):t._e()]),t._v(" "),e("div",{staticClass:"links",style:t.linksWrapMaxWidth?{"max-width":t.linksWrapMaxWidth+"px"}:{}},[t.isAlgoliaSearch?e("AlgoliaSearchBox",{attrs:{options:t.algolia}}):!1!==t.$site.themeConfig.search&&!1!==t.$page.frontmatter.search?e("SearchBox"):t._e(),t._v(" "),e("NavLinks",{staticClass:"can-hide"})],1)],1)}),[],!1,null,null,null);e.default=c.exports},287:function(t,e,a){"use strict";a.r(e);var i={name:"Home",components:{NavLink:a(241).default},computed:{data(){return this.$page.frontmatter},actionLink(){return{link:this.data.actionLink,text:this.data.actionText}}}},n=(a(271),a(14)),s=Object(n.a)(i,(function(){var t=this,e=t._self._c;return e("main",{staticClass:"home",attrs:{"aria-labelledby":null!==t.data.heroText?"main-title":null}},[e("header",{staticClass:"hero"},[t.data.heroImage?e("img",{attrs:{src:t.$withBase(t.data.heroImage),alt:t.data.heroAlt||"hero"}}):t._e(),t._v(" "),null!==t.data.heroText?e("h1",{attrs:{id:"main-title"}},[t._v("\n "+t._s(t.data.heroText||t.$title||"Hello")+"\n ")]):t._e(),t._v(" "),null!==t.data.tagline?e("p",{staticClass:"description"},[t._v("\n "+t._s(t.data.tagline||t.$description||"Welcome to your VuePress site")+"\n ")]):t._e(),t._v(" "),t.data.actionText&&t.data.actionLink?e("p",{staticClass:"action"},[e("NavLink",{staticClass:"action-button",attrs:{item:t.actionLink}})],1):t._e()]),t._v(" "),t.data.features&&t.data.features.length?e("div",{staticClass:"features"},t._l(t.data.features,(function(a,i){return e("div",{key:i,staticClass:"feature"},[e("h2",[t._v(t._s(a.title))]),t._v(" "),e("p",[t._v(t._s(a.details))])])})),0):t._e(),t._v(" "),e("Content",{staticClass:"theme-default-content custom"}),t._v(" "),t.data.footer?e("div",{staticClass:"footer"},[t._v("\n "+t._s(t.data.footer)+"\n ")]):e("Content",{staticClass:"footer",attrs:{"slot-key":"footer"}})],1)}),[],!1,null,null,null);e.default=s.exports},288:function(t,e,a){"use strict";a.r(e);var i=a(266),n=a(267),s={components:{PageEdit:i.default,PageNav:n.default},props:["sidebarItems"]},r=(a(274),a(14)),o=Object(r.a)(s,(function(){var t=this._self._c;return t("main",{staticClass:"page"},[this._t("top"),this._v(" "),t("Content",{staticClass:"theme-default-content"}),this._v(" "),t("PageEdit"),this._v(" "),t("PageNav",this._b({},"PageNav",{sidebarItems:this.sidebarItems},!1)),this._v(" "),this._t("bottom")],2)}),[],!1,null,null,null);e.default=o.exports},315:function(t,e,a){"use strict";a.r(e);var i=a(287),n=a(286),s=a(288),r=a(308),o=a(239),l={name:"Layout",components:{Home:i.default,Page:s.default,Sidebar:r.default,Navbar:n.default},data:()=>({isSidebarOpen:!1}),computed:{shouldShowNavbar(){const{themeConfig:t}=this.$site,{frontmatter:e}=this.$page;return!1!==e.navbar&&!1!==t.navbar&&(this.$title||t.logo||t.repo||t.nav||this.$themeLocaleConfig.nav)},shouldShowSidebar(){const{frontmatter:t}=this.$page;return!t.home&&!1!==t.sidebar&&this.sidebarItems.length},sidebarItems(){return Object(o.l)(this.$page,this.$page.regularPath,this.$site,this.$localePath)},pageClasses(){const t=this.$page.frontmatter.pageClass;return[{"no-navbar":!this.shouldShowNavbar,"sidebar-open":this.isSidebarOpen,"no-sidebar":!this.shouldShowSidebar},t]}},mounted(){this.$router.afterEach(()=>{this.isSidebarOpen=!1})},methods:{toggleSidebar(t){this.isSidebarOpen="boolean"==typeof t?t:!this.isSidebarOpen,this.$emit("toggle-sidebar",this.isSidebarOpen)},onTouchStart(t){this.touchStart={x:t.changedTouches[0].clientX,y:t.changedTouches[0].clientY}},onTouchEnd(t){const e=t.changedTouches[0].clientX-this.touchStart.x,a=t.changedTouches[0].clientY-this.touchStart.y;Math.abs(e)>Math.abs(a)&&Math.abs(e)>40&&(e>0&&this.touchStart.x<=80?this.toggleSidebar(!0):this.toggleSidebar(!1))}}},c=a(14),u=Object(c.a)(l,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"theme-container",class:t.pageClasses,on:{touchstart:t.onTouchStart,touchend:t.onTouchEnd}},[t.shouldShowNavbar?e("Navbar",{on:{"toggle-sidebar":t.toggleSidebar}}):t._e(),t._v(" "),e("div",{staticClass:"sidebar-mask",on:{click:function(e){return t.toggleSidebar(!1)}}}),t._v(" "),e("Sidebar",{attrs:{items:t.sidebarItems},on:{"toggle-sidebar":t.toggleSidebar},scopedSlots:t._u([{key:"top",fn:function(){return[t._t("sidebar-top")]},proxy:!0},{key:"bottom",fn:function(){return[t._t("sidebar-bottom")]},proxy:!0}],null,!0)}),t._v(" "),t.$page.frontmatter.home?e("Home"):e("Page",{attrs:{"sidebar-items":t.sidebarItems},scopedSlots:t._u([{key:"top",fn:function(){return[t._t("page-top")]},proxy:!0},{key:"bottom",fn:function(){return[t._t("page-bottom")]},proxy:!0}],null,!0)})],1)}),[],!1,null,null,null);e.default=u.exports}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[2,23],{245:function(t,e){t.exports=function(t){return null==t}},247:function(t,e,a){},248:function(t,e,a){},249:function(t,e,a){},253:function(t,e,a){},256:function(t,e,a){"use strict";a(247)},257:function(t,e,a){},258:function(t,e,a){"use strict";a(248)},259:function(t,e,a){var i=a(11),n=a(5),s=a(10);t.exports=function(t){return"string"==typeof t||!n(t)&&s(t)&&"[object String]"==i(t)}},260:function(t,e,a){"use strict";a(249)},261:function(t,e,a){},266:function(t,e,a){"use strict";a.r(e);var i=a(245),n=a.n(i),s=a(239),r={name:"PageEdit",computed:{lastUpdated(){return this.$page.lastUpdated},lastUpdatedText(){return"string"==typeof this.$themeLocaleConfig.lastUpdated?this.$themeLocaleConfig.lastUpdated:"string"==typeof this.$site.themeConfig.lastUpdated?this.$site.themeConfig.lastUpdated:"Last Updated"},editLink(){const t=n()(this.$page.frontmatter.editLink)?this.$site.themeConfig.editLinks:this.$page.frontmatter.editLink,{repo:e,docsDir:a="",docsBranch:i="master",docsRepo:s=e}=this.$site.themeConfig;return t&&s&&this.$page.relativePath?this.createEditLink(e,s,a,i,this.$page.relativePath):null},editLinkText(){return this.$themeLocaleConfig.editLinkText||this.$site.themeConfig.editLinkText||"Edit this page"}},methods:{createEditLink(t,e,a,i,n){if(/bitbucket.org/.test(e)){return e.replace(s.a,"")+"/src"+`/${i}/`+(a?a.replace(s.a,"")+"/":"")+n+`?mode=edit&spa=0&at=${i}&fileviewer=file-view-default`}if(/gitlab.com/.test(e)){return e.replace(s.a,"")+"/-/edit"+`/${i}/`+(a?a.replace(s.a,"")+"/":"")+n}return(s.i.test(e)?e:"https://github.com/"+e).replace(s.a,"")+"/edit"+`/${i}/`+(a?a.replace(s.a,"")+"/":"")+n}}},o=(a(258),a(14)),l=Object(o.a)(r,(function(){var t=this,e=t._self._c;return e("footer",{staticClass:"page-edit"},[t.editLink?e("div",{staticClass:"edit-link"},[e("a",{attrs:{href:t.editLink,target:"_blank",rel:"noopener noreferrer"}},[t._v(t._s(t.editLinkText))]),t._v(" "),e("OutboundLink")],1):t._e(),t._v(" "),t.lastUpdated?e("div",{staticClass:"last-updated"},[e("span",{staticClass:"prefix"},[t._v(t._s(t.lastUpdatedText)+":")]),t._v(" "),e("span",{staticClass:"time"},[t._v(t._s(t.lastUpdated))])]):t._e()])}),[],!1,null,null,null);e.default=l.exports},267:function(t,e,a){"use strict";a.r(e);a(89);var i=a(239),n=a(259),s=a.n(n),r=a(245),o=a.n(r),l={name:"PageNav",props:["sidebarItems"],computed:{prev(){return u(c.PREV,this)},next(){return u(c.NEXT,this)}}};const c={NEXT:{resolveLink:function(t,e){return d(t,e,1)},getThemeLinkConfig:({nextLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.next},PREV:{resolveLink:function(t,e){return d(t,e,-1)},getThemeLinkConfig:({prevLinks:t})=>t,getPageLinkConfig:({frontmatter:t})=>t.prev}};function u(t,{$themeConfig:e,$page:a,$route:n,$site:r,sidebarItems:l}){const{resolveLink:c,getThemeLinkConfig:u,getPageLinkConfig:d}=t,h=u(e),p=d(a),f=o()(p)?h:p;return!1===f?void 0:s()(f)?Object(i.k)(r.pages,f,n.path):c(a,l)}function d(t,e,a){const i=[];!function t(e,a){for(let i=0,n=e.length;i({linksWrapMaxWidth:null}),computed:{algolia(){return this.$themeLocaleConfig.algolia||this.$site.themeConfig.algolia||{}},isAlgoliaSearch(){return this.algolia&&this.algolia.apiKey&&this.algolia.indexName}},mounted(){const t=parseInt(r(this.$el,"paddingLeft"))+parseInt(r(this.$el,"paddingRight")),e=()=>{document.documentElement.clientWidth<719?this.linksWrapMaxWidth=null:this.linksWrapMaxWidth=this.$el.offsetWidth-t-(this.$refs.siteName&&this.$refs.siteName.offsetWidth||0)};e(),window.addEventListener("resize",e,!1)}},l=(a(273),a(14)),c=Object(l.a)(o,(function(){var t=this,e=t._self._c;return e("header",{staticClass:"navbar"},[e("SidebarButton",{on:{"toggle-sidebar":function(e){return t.$emit("toggle-sidebar")}}}),t._v(" "),e("RouterLink",{staticClass:"home-link",attrs:{to:t.$localePath}},[t.$site.themeConfig.logo?e("img",{staticClass:"logo",attrs:{src:t.$withBase(t.$site.themeConfig.logo),alt:t.$siteTitle}}):t._e(),t._v(" "),t.$siteTitle?e("span",{ref:"siteName",staticClass:"site-name",class:{"can-hide":t.$site.themeConfig.logo}},[t._v(t._s(t.$siteTitle))]):t._e()]),t._v(" "),e("div",{staticClass:"links",style:t.linksWrapMaxWidth?{"max-width":t.linksWrapMaxWidth+"px"}:{}},[t.isAlgoliaSearch?e("AlgoliaSearchBox",{attrs:{options:t.algolia}}):!1!==t.$site.themeConfig.search&&!1!==t.$page.frontmatter.search?e("SearchBox"):t._e(),t._v(" "),e("NavLinks",{staticClass:"can-hide"})],1)],1)}),[],!1,null,null,null);e.default=c.exports},287:function(t,e,a){"use strict";a.r(e);var i={name:"Home",components:{NavLink:a(241).default},computed:{data(){return this.$page.frontmatter},actionLink(){return{link:this.data.actionLink,text:this.data.actionText}}}},n=(a(271),a(14)),s=Object(n.a)(i,(function(){var t=this,e=t._self._c;return e("main",{staticClass:"home",attrs:{"aria-labelledby":null!==t.data.heroText?"main-title":null}},[e("header",{staticClass:"hero"},[t.data.heroImage?e("img",{attrs:{src:t.$withBase(t.data.heroImage),alt:t.data.heroAlt||"hero"}}):t._e(),t._v(" "),null!==t.data.heroText?e("h1",{attrs:{id:"main-title"}},[t._v("\n "+t._s(t.data.heroText||t.$title||"Hello")+"\n ")]):t._e(),t._v(" "),null!==t.data.tagline?e("p",{staticClass:"description"},[t._v("\n "+t._s(t.data.tagline||t.$description||"Welcome to your VuePress site")+"\n ")]):t._e(),t._v(" "),t.data.actionText&&t.data.actionLink?e("p",{staticClass:"action"},[e("NavLink",{staticClass:"action-button",attrs:{item:t.actionLink}})],1):t._e()]),t._v(" "),t.data.features&&t.data.features.length?e("div",{staticClass:"features"},t._l(t.data.features,(function(a,i){return e("div",{key:i,staticClass:"feature"},[e("h2",[t._v(t._s(a.title))]),t._v(" "),e("p",[t._v(t._s(a.details))])])})),0):t._e(),t._v(" "),e("Content",{staticClass:"theme-default-content custom"}),t._v(" "),t.data.footer?e("div",{staticClass:"footer"},[t._v("\n "+t._s(t.data.footer)+"\n ")]):e("Content",{staticClass:"footer",attrs:{"slot-key":"footer"}})],1)}),[],!1,null,null,null);e.default=s.exports},288:function(t,e,a){"use strict";a.r(e);var i=a(266),n=a(267),s={components:{PageEdit:i.default,PageNav:n.default},props:["sidebarItems"]},r=(a(274),a(14)),o=Object(r.a)(s,(function(){var t=this._self._c;return t("main",{staticClass:"page"},[this._t("top"),this._v(" "),t("Content",{staticClass:"theme-default-content"}),this._v(" "),t("PageEdit"),this._v(" "),t("PageNav",this._b({},"PageNav",{sidebarItems:this.sidebarItems},!1)),this._v(" "),this._t("bottom")],2)}),[],!1,null,null,null);e.default=o.exports},314:function(t,e,a){"use strict";a.r(e);var i=a(287),n=a(286),s=a(288),r=a(307),o=a(239),l={name:"Layout",components:{Home:i.default,Page:s.default,Sidebar:r.default,Navbar:n.default},data:()=>({isSidebarOpen:!1}),computed:{shouldShowNavbar(){const{themeConfig:t}=this.$site,{frontmatter:e}=this.$page;return!1!==e.navbar&&!1!==t.navbar&&(this.$title||t.logo||t.repo||t.nav||this.$themeLocaleConfig.nav)},shouldShowSidebar(){const{frontmatter:t}=this.$page;return!t.home&&!1!==t.sidebar&&this.sidebarItems.length},sidebarItems(){return Object(o.l)(this.$page,this.$page.regularPath,this.$site,this.$localePath)},pageClasses(){const t=this.$page.frontmatter.pageClass;return[{"no-navbar":!this.shouldShowNavbar,"sidebar-open":this.isSidebarOpen,"no-sidebar":!this.shouldShowSidebar},t]}},mounted(){this.$router.afterEach(()=>{this.isSidebarOpen=!1})},methods:{toggleSidebar(t){this.isSidebarOpen="boolean"==typeof t?t:!this.isSidebarOpen,this.$emit("toggle-sidebar",this.isSidebarOpen)},onTouchStart(t){this.touchStart={x:t.changedTouches[0].clientX,y:t.changedTouches[0].clientY}},onTouchEnd(t){const e=t.changedTouches[0].clientX-this.touchStart.x,a=t.changedTouches[0].clientY-this.touchStart.y;Math.abs(e)>Math.abs(a)&&Math.abs(e)>40&&(e>0&&this.touchStart.x<=80?this.toggleSidebar(!0):this.toggleSidebar(!1))}}},c=a(14),u=Object(c.a)(l,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"theme-container",class:t.pageClasses,on:{touchstart:t.onTouchStart,touchend:t.onTouchEnd}},[t.shouldShowNavbar?e("Navbar",{on:{"toggle-sidebar":t.toggleSidebar}}):t._e(),t._v(" "),e("div",{staticClass:"sidebar-mask",on:{click:function(e){return t.toggleSidebar(!1)}}}),t._v(" "),e("Sidebar",{attrs:{items:t.sidebarItems},on:{"toggle-sidebar":t.toggleSidebar},scopedSlots:t._u([{key:"top",fn:function(){return[t._t("sidebar-top")]},proxy:!0},{key:"bottom",fn:function(){return[t._t("sidebar-bottom")]},proxy:!0}],null,!0)}),t._v(" "),t.$page.frontmatter.home?e("Home"):e("Page",{attrs:{"sidebar-items":t.sidebarItems},scopedSlots:t._u([{key:"top",fn:function(){return[t._t("page-top")]},proxy:!0},{key:"bottom",fn:function(){return[t._t("page-bottom")]},proxy:!0}],null,!0)})],1)}),[],!1,null,null,null);e.default=u.exports}}]); \ No newline at end of file diff --git a/assets/js/20.10b3ff81.js b/assets/js/20.6fbe829b.js similarity index 62% rename from assets/js/20.10b3ff81.js rename to assets/js/20.6fbe829b.js index c85e01606..5d2cfdb10 100644 --- a/assets/js/20.10b3ff81.js +++ b/assets/js/20.6fbe829b.js @@ -675,603 +675,603 @@ * Public License instead of this License. But first, please read * . * - * Version: 2.6.1 - * Release date: 27/12/2023 (built at 27/12/2023 12:57:13) + * Version: 2.6.2 + * Release date: 15/02/2024 (built at 15/02/2024 11:09:54) */ -var n;r(298),r(92),r(90),r(100),r(299),r(300),r(302),"undefined"!=typeof self&&self,n=function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=0)}([function(e,t,r){"use strict";t.__esModule=!0,t.default=void 0;var n=r(1);t.ArraySize=n.ArraySize;var o=r(74);t.CellError=o.CellError,t.CellType=o.CellType,t.CellValueDetailedType=o.CellValueDetailedType,t.CellValueType=o.CellValueType,t.ErrorType=o.ErrorType;var s=r(172);t.DetailedCellError=s.DetailedCellError;var i=r(173),a=r(177);t.AlwaysDense=a.AlwaysDense,t.AlwaysSparse=a.AlwaysSparse,t.DenseSparseChooseBasedOnThreshold=a.DenseSparseChooseBasedOnThreshold;var u=r(148);t.ConfigValueTooBigError=u.ConfigValueTooBigError,t.ConfigValueTooSmallError=u.ConfigValueTooSmallError,t.EvaluationSuspendedError=u.EvaluationSuspendedError,t.ExpectedOneOfValuesError=u.ExpectedOneOfValuesError,t.ExpectedValueOfTypeError=u.ExpectedValueOfTypeError,t.FunctionPluginValidationError=u.FunctionPluginValidationError,t.InvalidAddressError=u.InvalidAddressError,t.InvalidArgumentsError=u.InvalidArgumentsError,t.LanguageAlreadyRegisteredError=u.LanguageAlreadyRegisteredError,t.LanguageNotRegisteredError=u.LanguageNotRegisteredError,t.MissingTranslationError=u.MissingTranslationError,t.NamedExpressionDoesNotExistError=u.NamedExpressionDoesNotExistError,t.NamedExpressionNameIsAlreadyTakenError=u.NamedExpressionNameIsAlreadyTakenError,t.NamedExpressionNameIsInvalidError=u.NamedExpressionNameIsInvalidError,t.NoOperationToRedoError=u.NoOperationToRedoError,t.NoOperationToUndoError=u.NoOperationToUndoError,t.NoRelativeAddressesAllowedError=u.NoRelativeAddressesAllowedError,t.NoSheetWithIdError=u.NoSheetWithIdError,t.NoSheetWithNameError=u.NoSheetWithNameError,t.NotAFormulaError=u.NotAFormulaError,t.NothingToPasteError=u.NothingToPasteError,t.ProtectedFunctionTranslationError=u.ProtectedFunctionTranslationError,t.SheetNameAlreadyTakenError=u.SheetNameAlreadyTakenError,t.SheetSizeLimitExceededError=u.SheetSizeLimitExceededError,t.SourceLocationHasArrayError=u.SourceLocationHasArrayError,t.TargetLocationHasArrayError=u.TargetLocationHasArrayError,t.UnableToParseError=u.UnableToParseError;var c=r(200);t.ExportedCellChange=c.ExportedCellChange,t.ExportedNamedExpressionChange=c.ExportedNamedExpressionChange;var l=r(182);t.HyperFormula=l.HyperFormula;var h,d=(h=r(218))&&h.__esModule?h:{default:h},p=r(167);t.FunctionPlugin=p.FunctionPlugin,t.FunctionArgumentType=p.FunctionArgumentType,t.EmptyValue=p.EmptyValue;var m=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var r=f(t);if(r&&r.has(e))return r.get(e);var n={__proto__:null},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var i=o?Object.getOwnPropertyDescriptor(e,s):null;i&&(i.get||i.set)?Object.defineProperty(n,s,i):n[s]=e[s]}return n.default=e,r&&r.set(e,n),n}(r(219)),g=r(140);function f(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(f=function(e){return e?r:t})(e)}t.SimpleRangeValue=g.SimpleRangeValue; +var n;r(96),r(89),r(91),r(298),r(299),r(301),"undefined"!=typeof self&&self,n=function(){return function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=0)}([function(e,t,r){"use strict";t.__esModule=!0,t.default=void 0;var n=r(1);t.ArraySize=n.ArraySize;var o=r(73);t.CellError=o.CellError,t.CellType=o.CellType,t.CellValueDetailedType=o.CellValueDetailedType,t.CellValueType=o.CellValueType,t.ErrorType=o.ErrorType;var s=r(170);t.DetailedCellError=s.DetailedCellError;var i=r(171),a=r(175);t.AlwaysDense=a.AlwaysDense,t.AlwaysSparse=a.AlwaysSparse,t.DenseSparseChooseBasedOnThreshold=a.DenseSparseChooseBasedOnThreshold;var u=r(147);t.ConfigValueTooBigError=u.ConfigValueTooBigError,t.ConfigValueTooSmallError=u.ConfigValueTooSmallError,t.EvaluationSuspendedError=u.EvaluationSuspendedError,t.ExpectedOneOfValuesError=u.ExpectedOneOfValuesError,t.ExpectedValueOfTypeError=u.ExpectedValueOfTypeError,t.FunctionPluginValidationError=u.FunctionPluginValidationError,t.InvalidAddressError=u.InvalidAddressError,t.InvalidArgumentsError=u.InvalidArgumentsError,t.LanguageAlreadyRegisteredError=u.LanguageAlreadyRegisteredError,t.LanguageNotRegisteredError=u.LanguageNotRegisteredError,t.MissingTranslationError=u.MissingTranslationError,t.NamedExpressionDoesNotExistError=u.NamedExpressionDoesNotExistError,t.NamedExpressionNameIsAlreadyTakenError=u.NamedExpressionNameIsAlreadyTakenError,t.NamedExpressionNameIsInvalidError=u.NamedExpressionNameIsInvalidError,t.NoOperationToRedoError=u.NoOperationToRedoError,t.NoOperationToUndoError=u.NoOperationToUndoError,t.NoRelativeAddressesAllowedError=u.NoRelativeAddressesAllowedError,t.NoSheetWithIdError=u.NoSheetWithIdError,t.NoSheetWithNameError=u.NoSheetWithNameError,t.NotAFormulaError=u.NotAFormulaError,t.NothingToPasteError=u.NothingToPasteError,t.ProtectedFunctionTranslationError=u.ProtectedFunctionTranslationError,t.SheetNameAlreadyTakenError=u.SheetNameAlreadyTakenError,t.SheetSizeLimitExceededError=u.SheetSizeLimitExceededError,t.SourceLocationHasArrayError=u.SourceLocationHasArrayError,t.TargetLocationHasArrayError=u.TargetLocationHasArrayError,t.UnableToParseError=u.UnableToParseError;var c=r(198);t.ExportedCellChange=c.ExportedCellChange,t.ExportedNamedExpressionChange=c.ExportedNamedExpressionChange;var l=r(180);t.HyperFormula=l.HyperFormula;var h,d=(h=r(216))&&h.__esModule?h:{default:h},p=r(166);t.FunctionPlugin=p.FunctionPlugin,t.FunctionArgumentType=p.FunctionArgumentType,t.EmptyValue=p.EmptyValue;var m=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var r=f(t);if(r&&r.has(e))return r.get(e);var n={__proto__:null},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var i=o?Object.getOwnPropertyDescriptor(e,s):null;i&&(i.get||i.set)?Object.defineProperty(n,s,i):n[s]=e[s]}return n.default=e,r&&r.set(e,n),n}(r(217)),g=r(139);function f(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(f=function(e){return e?r:t})(e)}t.SimpleRangeValue=g.SimpleRangeValue; /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ -class E extends l.HyperFormula{}E.HyperFormula=l.HyperFormula,E.ErrorType=o.ErrorType,E.CellError=o.CellError,E.CellType=o.CellType,E.CellValueType=o.CellValueType,E.CellValueDetailedType=o.CellValueDetailedType,E.DetailedCellError=s.DetailedCellError,E.ExportedCellChange=c.ExportedCellChange,E.ExportedNamedExpressionChange=c.ExportedNamedExpressionChange,E.ConfigValueTooBigError=u.ConfigValueTooBigError,E.ConfigValueTooSmallError=u.ConfigValueTooSmallError,E.EvaluationSuspendedError=u.EvaluationSuspendedError,E.ExpectedOneOfValuesError=u.ExpectedOneOfValuesError,E.ExpectedValueOfTypeError=u.ExpectedValueOfTypeError,E.ArraySize=n.ArraySize,E.SimpleRangeValue=g.SimpleRangeValue,E.EmptyValue=p.EmptyValue,E.FunctionPlugin=p.FunctionPlugin,E.FunctionArgumentType=p.FunctionArgumentType,E.FunctionPluginValidationError=u.FunctionPluginValidationError,E.InvalidAddressError=u.InvalidAddressError,E.InvalidArgumentsError=u.InvalidArgumentsError,E.LanguageNotRegisteredError=u.LanguageNotRegisteredError,E.LanguageAlreadyRegisteredError=u.LanguageAlreadyRegisteredError,E.MissingTranslationError=u.MissingTranslationError,E.NamedExpressionDoesNotExistError=u.NamedExpressionDoesNotExistError,E.NamedExpressionNameIsAlreadyTakenError=u.NamedExpressionNameIsAlreadyTakenError,E.NamedExpressionNameIsInvalidError=u.NamedExpressionNameIsInvalidError,E.NoOperationToRedoError=u.NoOperationToRedoError,E.NoOperationToUndoError=u.NoOperationToUndoError,E.NoRelativeAddressesAllowedError=u.NoRelativeAddressesAllowedError,E.NoSheetWithIdError=u.NoSheetWithIdError,E.NoSheetWithNameError=u.NoSheetWithNameError,E.NotAFormulaError=u.NotAFormulaError,E.NothingToPasteError=u.NothingToPasteError,E.ProtectedFunctionTranslationError=u.ProtectedFunctionTranslationError,E.SheetNameAlreadyTakenError=u.SheetNameAlreadyTakenError,E.SheetSizeLimitExceededError=u.SheetSizeLimitExceededError,E.SourceLocationHasArrayError=u.SourceLocationHasArrayError,E.TargetLocationHasArrayError=u.TargetLocationHasArrayError,E.UnableToParseError=u.UnableToParseError;const T=i.Config.defaultConfig.language;l.HyperFormula.registerLanguage(T,d.default),l.HyperFormula.languages[d.default.langCode]=d.default;for(const e of Object.getOwnPropertyNames(m))e.startsWith("_")||l.HyperFormula.registerFunctionPlugin(m[e]);t.default=E},function(e,t,r){"use strict";t.__esModule=!0,t.ArraySizePredictor=t.ArraySize=void 0,r(2);var n=r(73),o=r(166),s=r(167),i=r(78); +class E extends l.HyperFormula{}E.HyperFormula=l.HyperFormula,E.ErrorType=o.ErrorType,E.CellError=o.CellError,E.CellType=o.CellType,E.CellValueType=o.CellValueType,E.CellValueDetailedType=o.CellValueDetailedType,E.DetailedCellError=s.DetailedCellError,E.ExportedCellChange=c.ExportedCellChange,E.ExportedNamedExpressionChange=c.ExportedNamedExpressionChange,E.ConfigValueTooBigError=u.ConfigValueTooBigError,E.ConfigValueTooSmallError=u.ConfigValueTooSmallError,E.EvaluationSuspendedError=u.EvaluationSuspendedError,E.ExpectedOneOfValuesError=u.ExpectedOneOfValuesError,E.ExpectedValueOfTypeError=u.ExpectedValueOfTypeError,E.ArraySize=n.ArraySize,E.SimpleRangeValue=g.SimpleRangeValue,E.EmptyValue=p.EmptyValue,E.FunctionPlugin=p.FunctionPlugin,E.FunctionArgumentType=p.FunctionArgumentType,E.FunctionPluginValidationError=u.FunctionPluginValidationError,E.InvalidAddressError=u.InvalidAddressError,E.InvalidArgumentsError=u.InvalidArgumentsError,E.LanguageNotRegisteredError=u.LanguageNotRegisteredError,E.LanguageAlreadyRegisteredError=u.LanguageAlreadyRegisteredError,E.MissingTranslationError=u.MissingTranslationError,E.NamedExpressionDoesNotExistError=u.NamedExpressionDoesNotExistError,E.NamedExpressionNameIsAlreadyTakenError=u.NamedExpressionNameIsAlreadyTakenError,E.NamedExpressionNameIsInvalidError=u.NamedExpressionNameIsInvalidError,E.NoOperationToRedoError=u.NoOperationToRedoError,E.NoOperationToUndoError=u.NoOperationToUndoError,E.NoRelativeAddressesAllowedError=u.NoRelativeAddressesAllowedError,E.NoSheetWithIdError=u.NoSheetWithIdError,E.NoSheetWithNameError=u.NoSheetWithNameError,E.NotAFormulaError=u.NotAFormulaError,E.NothingToPasteError=u.NothingToPasteError,E.ProtectedFunctionTranslationError=u.ProtectedFunctionTranslationError,E.SheetNameAlreadyTakenError=u.SheetNameAlreadyTakenError,E.SheetSizeLimitExceededError=u.SheetSizeLimitExceededError,E.SourceLocationHasArrayError=u.SourceLocationHasArrayError,E.TargetLocationHasArrayError=u.TargetLocationHasArrayError,E.UnableToParseError=u.UnableToParseError;const T=i.Config.defaultConfig.language;l.HyperFormula.registerLanguage(T,d.default),l.HyperFormula.languages[d.default.langCode]=d.default;for(const e of Object.getOwnPropertyNames(m))e.startsWith("_")||l.HyperFormula.registerFunctionPlugin(m[e]);t.default=E},function(e,t,r){"use strict";t.__esModule=!0,t.ArraySizePredictor=t.ArraySize=void 0,r(2);var n=r(72),o=r(165),s=r(166),i=r(77); /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ -class a{constructor(e,t,r=!1){this.width=e,this.height=t,this.isRef=r}static error(){return new a(1,1,!0)}static scalar(){return new a(1,1,!1)}isScalar(){return 1===this.width&&1===this.height||this.isRef}}t.ArraySize=a,t.ArraySizePredictor=class{constructor(e,t){this.config=e,this.functionRegistry=t}checkArraySize(e,t){return this.checkArraySizeForAst(e,{formulaAddress:t,arraysFlag:this.config.useArrayArithmetic})}checkArraySizeForAst(e,t){switch(e.type){case i.AstNodeType.FUNCTION_CALL:return this.checkArraySizeForFunction(e,t);case i.AstNodeType.COLUMN_RANGE:case i.AstNodeType.ROW_RANGE:case i.AstNodeType.CELL_RANGE:{const r=n.AbsoluteCellRange.fromAstOrUndef(e,t.formulaAddress);return void 0===r?a.error():new a(r.width(),r.height(),!0)}case i.AstNodeType.ARRAY:{const r=[],n=[];for(const o of e.args){const e=o.map(e=>this.checkArraySizeForAst(e,t)),s=Math.min(...e.map(e=>e.height)),i=e.reduce((e,t)=>e+t.width,0);r.push(s),n.push(i)}const o=r.reduce((e,t)=>e+t,0),s=Math.min(...n);return new a(s,o)}case i.AstNodeType.STRING:case i.AstNodeType.NUMBER:return a.scalar();case i.AstNodeType.CELL_REFERENCE:return new a(1,1,!0);case i.AstNodeType.DIV_OP:case i.AstNodeType.CONCATENATE_OP:case i.AstNodeType.EQUALS_OP:case i.AstNodeType.GREATER_THAN_OP:case i.AstNodeType.GREATER_THAN_OR_EQUAL_OP:case i.AstNodeType.LESS_THAN_OP:case i.AstNodeType.LESS_THAN_OR_EQUAL_OP:case i.AstNodeType.MINUS_OP:case i.AstNodeType.NOT_EQUAL_OP:case i.AstNodeType.PLUS_OP:case i.AstNodeType.POWER_OP:case i.AstNodeType.TIMES_OP:{const r=this.checkArraySizeForAst(e.left,t),n=this.checkArraySizeForAst(e.right,t);return!t.arraysFlag&&(r.height>1||r.width>1||n.height>1||n.width>1)?a.error():(o=r,s=n,new a(Math.max(o.width,s.width),Math.max(o.height,s.height)))}case i.AstNodeType.MINUS_UNARY_OP:case i.AstNodeType.PLUS_UNARY_OP:case i.AstNodeType.PERCENT_OP:{const n=this.checkArraySizeForAst(e.value,t);return!t.arraysFlag&&(n.height>1||n.width>1)?a.error():new a((r=n).width,r.height)}case i.AstNodeType.PARENTHESIS:return this.checkArraySizeForAst(e.expression,t);case i.AstNodeType.EMPTY:default:return a.error()}var r,o,s}checkArraySizeForFunction(e,t){const r=this.functionRegistry.getArraySizeFunction(e.procedureName);if(void 0!==r)return r(e,t);const n=this.functionRegistry.getMetadata(e.procedureName);if(void 0===n||n.expandRanges||!t.arraysFlag||n.vectorizationForbidden||void 0===n.parameters)return new a(1,1);const i=e.args.map(e=>{var r;return this.checkArraySizeForAst(e,new o.InterpreterState(t.formulaAddress,t.arraysFlag||null!==(r=null==n?void 0:n.arrayFunction)&&void 0!==r&&r))}),u=[...n.parameters];if(void 0!==n.repeatLastArgs&&u.length0&&n[0]<4?1:+(n[0]+n[1])),!o&&i&&(!(n=i.match(/Edge\/(\d+)/))||n[1]>=74)&&(n=i.match(/Chrome\/(\d+)/))&&(o=+n[1]),e.exports=o},function(e,t,r){"use strict";e.exports="undefined"!=typeof navigator&&String(navigator.userAgent)||""},function(e,t,r){"use strict";var n=r(32),o=r(18);e.exports=function(e,t){var r=e[t];return o(r)?void 0:n(r)}},function(e,t,r){"use strict";var n=r(22),o=r(33),s=TypeError;e.exports=function(e){if(n(e))return e;throw new s(o(e)+" is not a function")}},function(e,t,r){"use strict";var n=String;e.exports=function(e){try{return n(e)}catch(e){return"Object"}}},function(e,t,r){"use strict";var n=r(9),o=r(22),s=r(21),i=TypeError;e.exports=function(e,t){var r,a;if("string"===t&&o(r=e.toString)&&!s(a=n(r,e)))return a;if(o(r=e.valueOf)&&!s(a=n(r,e)))return a;if("string"!==t&&o(r=e.toString)&&!s(a=n(r,e)))return a;throw new i("Can't convert object to primitive value")}},function(e,t,r){"use strict";var n=r(4),o=r(36),s=r(40),i=r(42),a=r(28),u=r(27),c=n.Symbol,l=o("wks"),h=u?c.for||c:c&&c.withoutSetter||i;e.exports=function(e){return s(l,e)||(l[e]=a&&s(c,e)?c[e]:h("Symbol."+e)),l[e]}},function(e,t,r){"use strict";var n=r(37),o=r(38);(e.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.34.0",mode:n?"pure":"global",copyright:"© 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.34.0/LICENSE",source:"https://github.com/zloirock/core-js"})},function(e,t,r){"use strict";e.exports=!1},function(e,t,r){"use strict";var n=r(4),o=r(39),s=n["__core-js_shared__"]||o("__core-js_shared__",{});e.exports=s},function(e,t,r){"use strict";var n=r(4),o=Object.defineProperty;e.exports=function(e,t){try{o(n,e,{value:t,configurable:!0,writable:!0})}catch(r){n[e]=t}return t}},function(e,t,r){"use strict";var n=r(15),o=r(41),s=n({}.hasOwnProperty);e.exports=Object.hasOwn||function(e,t){return s(o(e),t)}},function(e,t,r){"use strict";var n=r(17),o=Object;e.exports=function(e){return o(n(e))}},function(e,t,r){"use strict";var n=r(15),o=0,s=Math.random(),i=n(1..toString);e.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+i(++o+s,36)}},function(e,t,r){"use strict";var n=r(7),o=r(8),s=r(44);e.exports=!n&&!o((function(){return 7!==Object.defineProperty(s("div"),"a",{get:function(){return 7}}).a}))},function(e,t,r){"use strict";var n=r(4),o=r(21),s=n.document,i=o(s)&&o(s.createElement);e.exports=function(e){return i?s.createElement(e):{}}},function(e,t,r){"use strict";var n=r(7),o=r(46),s=r(12);e.exports=n?function(e,t,r){return o.f(e,t,s(1,r))}:function(e,t,r){return e[t]=r,e}},function(e,t,r){"use strict";var n=r(7),o=r(43),s=r(47),i=r(48),a=r(19),u=TypeError,c=Object.defineProperty,l=Object.getOwnPropertyDescriptor;t.f=n?s?function(e,t,r){if(i(e),t=a(t),i(r),"function"==typeof e&&"prototype"===t&&"value"in r&&"writable"in r&&!r.writable){var n=l(e,t);n&&n.writable&&(e[t]=r.value,r={configurable:"configurable"in r?r.configurable:n.configurable,enumerable:"enumerable"in r?r.enumerable:n.enumerable,writable:!1})}return c(e,t,r)}:c:function(e,t,r){if(i(e),t=a(t),i(r),o)try{return c(e,t,r)}catch(e){}if("get"in r||"set"in r)throw new u("Accessors not supported");return"value"in r&&(e[t]=r.value),e}},function(e,t,r){"use strict";var n=r(7),o=r(8);e.exports=n&&o((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},function(e,t,r){"use strict";var n=r(21),o=String,s=TypeError;e.exports=function(e){if(n(e))return e;throw new s(o(e)+" is not an object")}},function(e,t,r){"use strict";var n=r(22),o=r(46),s=r(50),i=r(39);e.exports=function(e,t,r,a){a||(a={});var u=a.enumerable,c=void 0!==a.name?a.name:t;if(n(r)&&s(r,c,a),a.global)u?e[t]=r:i(t,r);else{try{a.unsafe?e[t]&&(u=!0):delete e[t]}catch(e){}u?e[t]=r:o.f(e,t,{value:r,enumerable:!1,configurable:!a.nonConfigurable,writable:!a.nonWritable})}return e}},function(e,t,r){"use strict";var n=r(15),o=r(8),s=r(22),i=r(40),a=r(7),u=r(51).CONFIGURABLE,c=r(52),l=r(53),h=l.enforce,d=l.get,p=String,m=Object.defineProperty,g=n("".slice),f=n("".replace),E=n([].join),T=a&&!o((function(){return 8!==m((function(){}),"length",{value:8}).length})),y=String(String).split("String"),A=e.exports=function(e,t,r){"Symbol("===g(p(t),0,7)&&(t="["+f(p(t),/^Symbol\(([^)]*)\)/,"$1")+"]"),r&&r.getter&&(t="get "+t),r&&r.setter&&(t="set "+t),(!i(e,"name")||u&&e.name!==t)&&(a?m(e,"name",{value:t,configurable:!0}):e.name=t),T&&r&&i(r,"arity")&&e.length!==r.arity&&m(e,"length",{value:r.arity});try{r&&i(r,"constructor")&&r.constructor?a&&m(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var n=h(e);return i(n,"source")||(n.source=E(y,"string"==typeof t?t:"")),e};Function.prototype.toString=A((function(){return s(this)&&d(this).source||c(this)}),"toString")},function(e,t,r){"use strict";var n=r(7),o=r(40),s=Function.prototype,i=n&&Object.getOwnPropertyDescriptor,a=o(s,"name"),u=a&&"something"===function(){}.name,c=a&&(!n||n&&i(s,"name").configurable);e.exports={EXISTS:a,PROPER:u,CONFIGURABLE:c}},function(e,t,r){"use strict";var n=r(15),o=r(22),s=r(38),i=n(Function.toString);o(s.inspectSource)||(s.inspectSource=function(e){return i(e)}),e.exports=s.inspectSource},function(e,t,r){"use strict";var n,o,s,i=r(54),a=r(4),u=r(21),c=r(45),l=r(40),h=r(38),d=r(55),p=r(56),m=a.TypeError,g=a.WeakMap;if(i||h.state){var f=h.state||(h.state=new g);f.get=f.get,f.has=f.has,f.set=f.set,n=function(e,t){if(f.has(e))throw new m("Object already initialized");return t.facade=e,f.set(e,t),t},o=function(e){return f.get(e)||{}},s=function(e){return f.has(e)}}else{var E=d("state");p[E]=!0,n=function(e,t){if(l(e,E))throw new m("Object already initialized");return t.facade=e,c(e,E,t),t},o=function(e){return l(e,E)?e[E]:{}},s=function(e){return l(e,E)}}e.exports={set:n,get:o,has:s,enforce:function(e){return s(e)?o(e):n(e,{})},getterFor:function(e){return function(t){var r;if(!u(t)||(r=o(t)).type!==e)throw new m("Incompatible receiver, "+e+" required");return r}}}},function(e,t,r){"use strict";var n=r(4),o=r(22),s=n.WeakMap;e.exports=o(s)&&/native code/.test(String(s))},function(e,t,r){"use strict";var n=r(36),o=r(42),s=n("keys");e.exports=function(e){return s[e]||(s[e]=o(e))}},function(e,t,r){"use strict";e.exports={}},function(e,t,r){"use strict";var n=r(40),o=r(58),s=r(6),i=r(46);e.exports=function(e,t,r){for(var a=o(t),u=i.f,c=s.f,l=0;lc;)o(n,r=t[c++])&&(~i(l,r)||u(l,r));return l}},function(e,t,r){"use strict";var n=r(13),o=r(62),s=r(65),i=function(e){return function(t,r,i){var a,u=n(t),c=s(u),l=o(i,c);if(e&&r!=r){for(;c>l;)if((a=u[l++])!=a)return!0}else for(;c>l;l++)if((e||l in u)&&u[l]===r)return e||l||0;return!e&&-1}};e.exports={includes:i(!0),indexOf:i(!1)}},function(e,t,r){"use strict";var n=r(63),o=Math.max,s=Math.min;e.exports=function(e,t){var r=n(e);return r<0?o(r+t,0):s(r,t)}},function(e,t,r){"use strict";var n=r(64);e.exports=function(e){var t=+e;return t!=t||0===t?0:n(t)}},function(e,t,r){"use strict";var n=Math.ceil,o=Math.floor;e.exports=Math.trunc||function(e){var t=+e;return(t>0?o:n)(t)}},function(e,t,r){"use strict";var n=r(66);e.exports=function(e){return n(e.length)}},function(e,t,r){"use strict";var n=r(63),o=Math.min;e.exports=function(e){return e>0?o(n(e),9007199254740991):0}},function(e,t,r){"use strict";e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(e,t,r){"use strict";t.f=Object.getOwnPropertySymbols},function(e,t,r){"use strict";var n=r(8),o=r(22),s=/#|\.prototype\./,i=function(e,t){var r=u[a(e)];return r===l||r!==c&&(o(t)?n(t):!!t)},a=i.normalize=function(e){return String(e).replace(s,".").toLowerCase()},u=i.data={},c=i.NATIVE="N",l=i.POLYFILL="P";e.exports=i},function(e,t,r){"use strict";var n=r(7),o=r(71),s=TypeError,i=Object.getOwnPropertyDescriptor,a=n&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}();e.exports=a?function(e,t){if(o(e)&&!i(e,"length").writable)throw new s("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t}},function(e,t,r){"use strict";var n=r(16);e.exports=Array.isArray||function(e){return"Array"===n(e)}},function(e,t,r){"use strict";var n=TypeError;e.exports=function(e){if(e>9007199254740991)throw n("Maximum allowed index exceeded");return e}},function(e,t,r){"use strict";t.__esModule=!0,t.WRONG_RANGE_SIZE=t.AbsoluteRowRange=t.AbsoluteColumnRange=t.AbsoluteCellRange=void 0,t.isSimpleCellRange=function(e){return!(!e||"object"!=typeof e&&"function"!=typeof e)&&"start"in e&&(0,n.isSimpleCellAddress)(e.start)&&"end"in e&&(0,n.isSimpleCellAddress)(e.end)},t.simpleCellRange=void 0,r(2);var n=r(74),o=r(148),s=r(78),i=r(142); +class a{constructor(e,t,r=!1){this.width=e,this.height=t,this.isRef=r}static error(){return new a(1,1,!0)}static scalar(){return new a(1,1,!1)}isScalar(){return 1===this.width&&1===this.height||this.isRef}}t.ArraySize=a,t.ArraySizePredictor=class{constructor(e,t){this.config=e,this.functionRegistry=t}checkArraySize(e,t){return this.checkArraySizeForAst(e,{formulaAddress:t,arraysFlag:this.config.useArrayArithmetic})}checkArraySizeForAst(e,t){switch(e.type){case i.AstNodeType.FUNCTION_CALL:return this.checkArraySizeForFunction(e,t);case i.AstNodeType.COLUMN_RANGE:case i.AstNodeType.ROW_RANGE:case i.AstNodeType.CELL_RANGE:{const r=n.AbsoluteCellRange.fromAstOrUndef(e,t.formulaAddress);return void 0===r?a.error():new a(r.width(),r.height(),!0)}case i.AstNodeType.ARRAY:{const r=[],n=[];for(const o of e.args){const e=o.map(e=>this.checkArraySizeForAst(e,t)),s=Math.min(...e.map(e=>e.height)),i=e.reduce((e,t)=>e+t.width,0);r.push(s),n.push(i)}const o=r.reduce((e,t)=>e+t,0),s=Math.min(...n);return new a(s,o)}case i.AstNodeType.STRING:case i.AstNodeType.NUMBER:return a.scalar();case i.AstNodeType.CELL_REFERENCE:return new a(1,1,!0);case i.AstNodeType.DIV_OP:case i.AstNodeType.CONCATENATE_OP:case i.AstNodeType.EQUALS_OP:case i.AstNodeType.GREATER_THAN_OP:case i.AstNodeType.GREATER_THAN_OR_EQUAL_OP:case i.AstNodeType.LESS_THAN_OP:case i.AstNodeType.LESS_THAN_OR_EQUAL_OP:case i.AstNodeType.MINUS_OP:case i.AstNodeType.NOT_EQUAL_OP:case i.AstNodeType.PLUS_OP:case i.AstNodeType.POWER_OP:case i.AstNodeType.TIMES_OP:{const r=this.checkArraySizeForAst(e.left,t),n=this.checkArraySizeForAst(e.right,t);return!t.arraysFlag&&(r.height>1||r.width>1||n.height>1||n.width>1)?a.error():(o=r,s=n,new a(Math.max(o.width,s.width),Math.max(o.height,s.height)))}case i.AstNodeType.MINUS_UNARY_OP:case i.AstNodeType.PLUS_UNARY_OP:case i.AstNodeType.PERCENT_OP:{const n=this.checkArraySizeForAst(e.value,t);return!t.arraysFlag&&(n.height>1||n.width>1)?a.error():new a((r=n).width,r.height)}case i.AstNodeType.PARENTHESIS:return this.checkArraySizeForAst(e.expression,t);case i.AstNodeType.EMPTY:default:return a.error()}var r,o,s}checkArraySizeForFunction(e,t){const r=this.functionRegistry.getArraySizeFunction(e.procedureName);if(void 0!==r)return r(e,t);const n=this.functionRegistry.getMetadata(e.procedureName);if(void 0===n||n.expandRanges||!t.arraysFlag||n.vectorizationForbidden||void 0===n.parameters)return new a(1,1);const i=e.args.map(e=>{var r;return this.checkArraySizeForAst(e,new o.InterpreterState(t.formulaAddress,t.arraysFlag||null!==(r=null==n?void 0:n.arrayFunction)&&void 0!==r&&r))}),u=[...n.parameters];if(void 0!==n.repeatLastArgs&&u.length0&&n[0]<4?1:+(n[0]+n[1])),!o&&i&&(!(n=i.match(/Edge\/(\d+)/))||n[1]>=74)&&(n=i.match(/Chrome\/(\d+)/))&&(o=+n[1]),e.exports=o},function(e,t,r){"use strict";e.exports="undefined"!=typeof navigator&&String(navigator.userAgent)||""},function(e,t,r){"use strict";var n=r(31),o=r(18);e.exports=function(e,t){var r=e[t];return o(r)?void 0:n(r)}},function(e,t,r){"use strict";var n=r(22),o=r(32),s=TypeError;e.exports=function(e){if(n(e))return e;throw new s(o(e)+" is not a function")}},function(e,t,r){"use strict";var n=String;e.exports=function(e){try{return n(e)}catch(e){return"Object"}}},function(e,t,r){"use strict";var n=r(9),o=r(22),s=r(21),i=TypeError;e.exports=function(e,t){var r,a;if("string"===t&&o(r=e.toString)&&!s(a=n(r,e)))return a;if(o(r=e.valueOf)&&!s(a=n(r,e)))return a;if("string"!==t&&o(r=e.toString)&&!s(a=n(r,e)))return a;throw new i("Can't convert object to primitive value")}},function(e,t,r){"use strict";var n=r(4),o=r(35),s=r(39),i=r(41),a=r(27),u=r(26),c=n.Symbol,l=o("wks"),h=u?c.for||c:c&&c.withoutSetter||i;e.exports=function(e){return s(l,e)||(l[e]=a&&s(c,e)?c[e]:h("Symbol."+e)),l[e]}},function(e,t,r){"use strict";var n=r(36),o=r(37);(e.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.35.1",mode:n?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.35.1/LICENSE",source:"https://github.com/zloirock/core-js"})},function(e,t,r){"use strict";e.exports=!1},function(e,t,r){"use strict";var n=r(4),o=r(38),s=n["__core-js_shared__"]||o("__core-js_shared__",{});e.exports=s},function(e,t,r){"use strict";var n=r(4),o=Object.defineProperty;e.exports=function(e,t){try{o(n,e,{value:t,configurable:!0,writable:!0})}catch(r){n[e]=t}return t}},function(e,t,r){"use strict";var n=r(15),o=r(40),s=n({}.hasOwnProperty);e.exports=Object.hasOwn||function(e,t){return s(o(e),t)}},function(e,t,r){"use strict";var n=r(17),o=Object;e.exports=function(e){return o(n(e))}},function(e,t,r){"use strict";var n=r(15),o=0,s=Math.random(),i=n(1..toString);e.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+i(++o+s,36)}},function(e,t,r){"use strict";var n=r(7),o=r(8),s=r(43);e.exports=!n&&!o((function(){return 7!==Object.defineProperty(s("div"),"a",{get:function(){return 7}}).a}))},function(e,t,r){"use strict";var n=r(4),o=r(21),s=n.document,i=o(s)&&o(s.createElement);e.exports=function(e){return i?s.createElement(e):{}}},function(e,t,r){"use strict";var n=r(7),o=r(45),s=r(12);e.exports=n?function(e,t,r){return o.f(e,t,s(1,r))}:function(e,t,r){return e[t]=r,e}},function(e,t,r){"use strict";var n=r(7),o=r(42),s=r(46),i=r(47),a=r(19),u=TypeError,c=Object.defineProperty,l=Object.getOwnPropertyDescriptor;t.f=n?s?function(e,t,r){if(i(e),t=a(t),i(r),"function"==typeof e&&"prototype"===t&&"value"in r&&"writable"in r&&!r.writable){var n=l(e,t);n&&n.writable&&(e[t]=r.value,r={configurable:"configurable"in r?r.configurable:n.configurable,enumerable:"enumerable"in r?r.enumerable:n.enumerable,writable:!1})}return c(e,t,r)}:c:function(e,t,r){if(i(e),t=a(t),i(r),o)try{return c(e,t,r)}catch(e){}if("get"in r||"set"in r)throw new u("Accessors not supported");return"value"in r&&(e[t]=r.value),e}},function(e,t,r){"use strict";var n=r(7),o=r(8);e.exports=n&&o((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},function(e,t,r){"use strict";var n=r(21),o=String,s=TypeError;e.exports=function(e){if(n(e))return e;throw new s(o(e)+" is not an object")}},function(e,t,r){"use strict";var n=r(22),o=r(45),s=r(49),i=r(38);e.exports=function(e,t,r,a){a||(a={});var u=a.enumerable,c=void 0!==a.name?a.name:t;if(n(r)&&s(r,c,a),a.global)u?e[t]=r:i(t,r);else{try{a.unsafe?e[t]&&(u=!0):delete e[t]}catch(e){}u?e[t]=r:o.f(e,t,{value:r,enumerable:!1,configurable:!a.nonConfigurable,writable:!a.nonWritable})}return e}},function(e,t,r){"use strict";var n=r(15),o=r(8),s=r(22),i=r(39),a=r(7),u=r(50).CONFIGURABLE,c=r(51),l=r(52),h=l.enforce,d=l.get,p=String,m=Object.defineProperty,g=n("".slice),f=n("".replace),E=n([].join),T=a&&!o((function(){return 8!==m((function(){}),"length",{value:8}).length})),y=String(String).split("String"),A=e.exports=function(e,t,r){"Symbol("===g(p(t),0,7)&&(t="["+f(p(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),r&&r.getter&&(t="get "+t),r&&r.setter&&(t="set "+t),(!i(e,"name")||u&&e.name!==t)&&(a?m(e,"name",{value:t,configurable:!0}):e.name=t),T&&r&&i(r,"arity")&&e.length!==r.arity&&m(e,"length",{value:r.arity});try{r&&i(r,"constructor")&&r.constructor?a&&m(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var n=h(e);return i(n,"source")||(n.source=E(y,"string"==typeof t?t:"")),e};Function.prototype.toString=A((function(){return s(this)&&d(this).source||c(this)}),"toString")},function(e,t,r){"use strict";var n=r(7),o=r(39),s=Function.prototype,i=n&&Object.getOwnPropertyDescriptor,a=o(s,"name"),u=a&&"something"===function(){}.name,c=a&&(!n||n&&i(s,"name").configurable);e.exports={EXISTS:a,PROPER:u,CONFIGURABLE:c}},function(e,t,r){"use strict";var n=r(15),o=r(22),s=r(37),i=n(Function.toString);o(s.inspectSource)||(s.inspectSource=function(e){return i(e)}),e.exports=s.inspectSource},function(e,t,r){"use strict";var n,o,s,i=r(53),a=r(4),u=r(21),c=r(44),l=r(39),h=r(37),d=r(54),p=r(55),m=a.TypeError,g=a.WeakMap;if(i||h.state){var f=h.state||(h.state=new g);f.get=f.get,f.has=f.has,f.set=f.set,n=function(e,t){if(f.has(e))throw new m("Object already initialized");return t.facade=e,f.set(e,t),t},o=function(e){return f.get(e)||{}},s=function(e){return f.has(e)}}else{var E=d("state");p[E]=!0,n=function(e,t){if(l(e,E))throw new m("Object already initialized");return t.facade=e,c(e,E,t),t},o=function(e){return l(e,E)?e[E]:{}},s=function(e){return l(e,E)}}e.exports={set:n,get:o,has:s,enforce:function(e){return s(e)?o(e):n(e,{})},getterFor:function(e){return function(t){var r;if(!u(t)||(r=o(t)).type!==e)throw new m("Incompatible receiver, "+e+" required");return r}}}},function(e,t,r){"use strict";var n=r(4),o=r(22),s=n.WeakMap;e.exports=o(s)&&/native code/.test(String(s))},function(e,t,r){"use strict";var n=r(35),o=r(41),s=n("keys");e.exports=function(e){return s[e]||(s[e]=o(e))}},function(e,t,r){"use strict";e.exports={}},function(e,t,r){"use strict";var n=r(39),o=r(57),s=r(6),i=r(45);e.exports=function(e,t,r){for(var a=o(t),u=i.f,c=s.f,l=0;lc;)o(n,r=t[c++])&&(~i(l,r)||u(l,r));return l}},function(e,t,r){"use strict";var n=r(13),o=r(61),s=r(64),i=function(e){return function(t,r,i){var a,u=n(t),c=s(u),l=o(i,c);if(e&&r!=r){for(;c>l;)if((a=u[l++])!=a)return!0}else for(;c>l;l++)if((e||l in u)&&u[l]===r)return e||l||0;return!e&&-1}};e.exports={includes:i(!0),indexOf:i(!1)}},function(e,t,r){"use strict";var n=r(62),o=Math.max,s=Math.min;e.exports=function(e,t){var r=n(e);return r<0?o(r+t,0):s(r,t)}},function(e,t,r){"use strict";var n=r(63);e.exports=function(e){var t=+e;return t!=t||0===t?0:n(t)}},function(e,t,r){"use strict";var n=Math.ceil,o=Math.floor;e.exports=Math.trunc||function(e){var t=+e;return(t>0?o:n)(t)}},function(e,t,r){"use strict";var n=r(65);e.exports=function(e){return n(e.length)}},function(e,t,r){"use strict";var n=r(62),o=Math.min;e.exports=function(e){var t=n(e);return t>0?o(t,9007199254740991):0}},function(e,t,r){"use strict";e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(e,t,r){"use strict";t.f=Object.getOwnPropertySymbols},function(e,t,r){"use strict";var n=r(8),o=r(22),s=/#|\.prototype\./,i=function(e,t){var r=u[a(e)];return r===l||r!==c&&(o(t)?n(t):!!t)},a=i.normalize=function(e){return String(e).replace(s,".").toLowerCase()},u=i.data={},c=i.NATIVE="N",l=i.POLYFILL="P";e.exports=i},function(e,t,r){"use strict";var n=r(7),o=r(70),s=TypeError,i=Object.getOwnPropertyDescriptor,a=n&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}();e.exports=a?function(e,t){if(o(e)&&!i(e,"length").writable)throw new s("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t}},function(e,t,r){"use strict";var n=r(16);e.exports=Array.isArray||function(e){return"Array"===n(e)}},function(e,t,r){"use strict";var n=TypeError;e.exports=function(e){if(e>9007199254740991)throw n("Maximum allowed index exceeded");return e}},function(e,t,r){"use strict";t.__esModule=!0,t.WRONG_RANGE_SIZE=t.AbsoluteRowRange=t.AbsoluteColumnRange=t.AbsoluteCellRange=void 0,t.isSimpleCellRange=function(e){return!(!e||"object"!=typeof e&&"function"!=typeof e)&&"start"in e&&(0,n.isSimpleCellAddress)(e.start)&&"end"in e&&(0,n.isSimpleCellAddress)(e.end)},t.simpleCellRange=void 0,r(2);var n=r(73),o=r(147),s=r(77),i=r(141); /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ -const a=t.WRONG_RANGE_SIZE="AbsoluteCellRange: Wrong range size";t.simpleCellRange=(e,t)=>({start:e,end:t});class u{constructor(e,t){if(e.sheet!==t.sheet)throw new o.SheetsNotEqual(e.sheet,t.sheet);this.start=(0,n.simpleCellAddress)(e.sheet,e.col,e.row),this.end=(0,n.simpleCellAddress)(t.sheet,t.col,t.row)}get sheet(){return this.start.sheet}static fromSimpleCellAddresses(e,t){if(e.sheet!==t.sheet)throw new o.SheetsNotEqual(e.sheet,t.sheet);const r=t.col-e.col,n=t.row-e.row;return Number.isFinite(n)&&Number.isFinite(r)?new u(e,t):Number.isFinite(n)?new l(e.sheet,e.row,t.row):new c(e.sheet,e.col,t.col)}static fromAst(e,t){return e.type===s.AstNodeType.CELL_RANGE?u.fromCellRange(e,t):e.type===s.AstNodeType.COLUMN_RANGE?c.fromColumnRange(e,t):l.fromRowRangeAst(e,t)}static fromAstOrUndef(e,t){try{return u.fromAst(e,t)}catch(e){return}}static fromCellRange(e,t){return new u(e.start.toSimpleCellAddress(t),e.end.toSimpleCellAddress(t))}static spanFrom(e,t,r){const n=u.spanFromOrUndef(e,t,r);if(void 0===n)throw new Error(a);return n}static spanFromOrUndef(e,t,r){if(!Number.isFinite(t)&&Number.isFinite(r)){if(0!==e.col)return;return new l(e.sheet,e.row,e.row+r-1)}if(!Number.isFinite(r)&&Number.isFinite(t)){if(0!==e.row)return;return new c(e.sheet,e.col,e.col+t-1)}if(Number.isFinite(r)&&Number.isFinite(t))return new u(e,(0,n.simpleCellAddress)(e.sheet,e.col+t-1,e.row+r-1))}static fromCoordinates(e,t,r,o,s){return new u((0,n.simpleCellAddress)(e,t,r),(0,n.simpleCellAddress)(e,o,s))}isFinite(){return Number.isFinite(this.size())}doesOverlap(e){return!(this.start.sheet!=e.start.sheet||this.end.rowe.end.row||this.end.cole.end.col)}addressInRange(e){return this.sheet===e.sheet&&this.start.row<=e.row&&this.end.row>=e.row&&this.start.col<=e.col&&this.end.col>=e.col}columnInRange(e){return this.sheet===e.sheet&&this.start.col<=e.col&&this.end.col>=e.col}rowInRange(e){return this.sheet===e.sheet&&this.start.row<=e.row&&this.end.row>=e.row}containsRange(e){return this.addressInRange(e.start)&&this.addressInRange(e.end)}intersectionWith(e){if(this.sheet!==e.start.sheet)return;const t=Math.max(this.start.row,e.start.row),r=Math.min(this.end.row,e.end.row),o=Math.max(this.start.col,e.start.col),s=Math.min(this.end.col,e.end.col);return t>r||o>s?void 0:new u((0,n.simpleCellAddress)(this.sheet,o,t),(0,n.simpleCellAddress)(this.sheet,s,r))}includesRow(e){return this.start.row=e}includesColumn(e){return this.start.col=e}shiftByRows(e){this.start.row+=e,this.end.row+=e}expandByRows(e){this.end.row+=e}shiftByColumns(e){this.start.col+=e,this.end.col+=e}shifted(e,t){return u.spanFrom((0,n.simpleCellAddress)(this.sheet,this.start.col+e,this.start.row+t),this.width(),this.height())}expandByColumns(e){this.end.col+=e}moveToSheet(e){this.start.sheet=e,this.end.sheet=e}removeSpan(e){e instanceof i.RowsSpan?this.removeRows(e.start,e.end):this.removeColumns(e.start,e.end)}shouldBeRemoved(){return this.width()<=0||this.height()<=0}rangeWithSameWidth(e,t){return u.spanFrom((0,n.simpleCellAddress)(this.sheet,this.start.col,e),this.width(),t)}rangeWithSameHeight(e,t){return u.spanFrom((0,n.simpleCellAddress)(this.sheet,e,this.start.row),t,this.height())}toString(){return`${this.start.sheet},${this.start.col},${this.start.row},${this.end.col},${this.end.row}`}width(){return this.end.col-this.start.col+1}height(){return this.end.row-this.start.row+1}size(){return this.height()*this.width()}arrayOfAddressesInRange(){const e=[];for(let t=0;t0)if(t>0){let e=this.effectiveEndRow(r);for(;e>=this.start.row;){let t=this.effectiveEndColumn(r);for(;t>=this.start.col;)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t-=1;e-=1}}else{let e=this.start.row;for(;e<=this.effectiveEndRow(r);){let t=this.effectiveEndColumn(r);for(;t>=this.start.col;)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t-=1;e+=1}}else if(t>0){let e=this.effectiveEndRow(r);for(;e>=this.start.row;){let t=this.start.col;for(;t<=this.effectiveEndColumn(r);)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t+=1;e-=1}}else{let e=this.start.row;for(;e<=this.effectiveEndRow(r);){let t=this.start.col;for(;t<=this.effectiveEndColumn(r);)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t+=1;e+=1}}}getAddress(e,t){if(e<0||t<0||t>this.height()-1||e>this.width()-1)throw Error("Index out of bound");return(0,n.simpleCellAddress)(this.start.sheet,this.start.col+e,this.start.row+t)}exceedsSheetSizeLimits(e,t){return this.end.col>=e||this.end.row>=t}effectiveEndColumn(e){return this.end.col}effectiveEndRow(e){return this.end.row}effectiveWidth(e){return this.width()}effectiveHeight(e){return this.height()}removeRows(e,t){if(!(e>this.end.row)){if(tthis.end.col)){if(t=e}effectiveEndRow(e){return this.effectiveHeight(e)-1}effectiveHeight(e){return e.getSheetHeight(this.sheet)}removeRows(e,t){}}t.AbsoluteColumnRange=c;class l extends u{constructor(e,t,r){super((0,n.simpleCellAddress)(e,0,t),(0,n.simpleCellAddress)(e,Number.POSITIVE_INFINITY,r))}static fromRowRangeAst(e,t){const r=e.start.toSimpleRowAddress(t),n=e.end.toSimpleRowAddress(t);if(r.sheet!==n.sheet)throw new o.SheetsNotEqual(r.sheet,n.sheet);return new l(r.sheet,r.row,n.row)}shouldBeRemoved(){return this.height()<=0}shiftByColumns(e){}expandByColumns(e){}shifted(e,t){return new l(this.sheet,this.start.row+t,this.end.row+t)}rangeWithSameWidth(e,t){return new l(this.sheet,e,e+t-1)}exceedsSheetSizeLimits(e,t){return this.end.row>=t}effectiveEndColumn(e){return this.effectiveWidth(e)-1}effectiveWidth(e){return e.getSheetWidth(this.sheet)}removeColumns(e,t){}}t.AbsoluteRowRange=l},function(e,t,r){"use strict";t.__esModule=!0,t.invalidSimpleRowAddress=t.invalidSimpleColumnAddress=t.invalidSimpleCellAddress=t.getCellValueType=t.getCellValueFormat=t.getCellValueDetailedType=t.getCellType=t.equalSimpleCellAddress=t.addressKey=t.absoluteSheetReference=t.ErrorType=t.CellValueTypeOrd=t.CellValueType=t.CellValueNoNumber=t.CellValueJustNumber=t.CellValueDetailedType=t.CellType=t.CellError=void 0,t.isSimpleCellAddress=function(e){var t,r,n;return e&&("object"==typeof e||"function"==typeof e)&&"number"==typeof(null===(t=e)||void 0===t?void 0:t.sheet)&&"number"==typeof(null===(r=e)||void 0===r?void 0:r.col)&&"number"==typeof(null===(n=e)||void 0===n?void 0:n.row)},t.simpleRowAddress=t.simpleColumnAddress=t.simpleCellAddress=t.movedSimpleCellAddress=void 0;var n,o,s,i,a=r(75),u=r(132),c=r(141),l=r(140);!function(e){e.DIV_BY_ZERO="DIV_BY_ZERO",e.NAME="NAME",e.VALUE="VALUE",e.NUM="NUM",e.NA="NA",e.CYCLE="CYCLE",e.REF="REF",e.SPILL="SPILL",e.LIC="LIC",e.ERROR="ERROR"}(n||(t.ErrorType=n={})),function(e){e.FORMULA="FORMULA",e.VALUE="VALUE",e.ARRAY="ARRAY",e.EMPTY="EMPTY",e.ARRAYFORMULA="ARRAYFORMULA"}(o||(t.CellType=o={})),t.getCellType=(e,t)=>e instanceof a.ArrayVertex?e.isLeftCorner(t)?o.ARRAYFORMULA:o.ARRAY:e instanceof a.FormulaCellVertex||e instanceof a.ParsingErrorVertex?o.FORMULA:e instanceof a.ValueCellVertex?o.VALUE:o.EMPTY,function(e){e.EMPTY="EMPTY",e.NUMBER="NUMBER",e.STRING="STRING",e.BOOLEAN="BOOLEAN",e.ERROR="ERROR"}(s||(t.CellValueNoNumber=s={})),function(e){e.NUMBER="NUMBER"}(i||(t.CellValueJustNumber=i={}));const h=t.CellValueType=Object.assign(Object.assign({},s),i);t.CellValueDetailedType=Object.assign(Object.assign({},s),c.NumberType),t.CellValueTypeOrd=e=>{switch(e){case h.EMPTY:return 0;case h.NUMBER:return 1;case h.STRING:return 2;case h.BOOLEAN:return 3;case h.ERROR:return 4}throw new Error("Cell value not computed")};const d=e=>{if(e===c.EmptyValue)return h.EMPTY;if(e instanceof p||e instanceof l.SimpleRangeValue)return h.ERROR;if("string"==typeof e)return h.STRING;if((0,c.isExtendedNumber)(e))return h.NUMBER;if("boolean"==typeof e)return h.BOOLEAN;throw new Error("Cell value not computed")};t.getCellValueType=d,t.getCellValueDetailedType=e=>(0,c.isExtendedNumber)(e)?(0,c.getTypeOfExtendedNumber)(e):d(e),t.getCellValueFormat=e=>(0,c.isExtendedNumber)(e)?(0,c.getFormatOfExtendedNumber)(e):void 0;class p{constructor(e,t,r){this.type=e,this.message=t,this.root=r}static parsingError(e){return new p(n.ERROR,`${u.ErrorMessage.ParseError}${e?" "+e:""}`)}attachRootVertex(e){return void 0===this.root?new p(this.type,this.message,e):this}}t.CellError=p,t.simpleRowAddress=(e,t)=>({sheet:e,row:t}),t.invalidSimpleRowAddress=e=>e.row<0,t.simpleColumnAddress=(e,t)=>({sheet:e,col:t}),t.invalidSimpleColumnAddress=e=>e.col<0;const m=(e,t,r)=>({sheet:e,col:t,row:r});t.simpleCellAddress=m,t.invalidSimpleCellAddress=e=>e.col<0||e.row<0,t.movedSimpleCellAddress=(e,t,r,n)=>m(t,e.col+r,e.row+n),t.addressKey=e=>`${e.sheet},${e.row},${e.col}`,t.absoluteSheetReference=(e,t)=>{var r;return null!==(r=e.sheet)&&void 0!==r?r:t.sheet},t.equalSimpleCellAddress=(e,t)=>e.sheet===t.sheet&&e.col===t.col&&e.row===t.row},function(e,t,r){"use strict";t.__esModule=!0,t.ValueCellVertex=t.TopSort=t.SparseStrategy=t.SheetMapping=t.RangeVertex=t.RangeMapping=t.ParsingErrorVertex=t.Graph=t.FormulaCellVertex=t.EmptyCellVertex=t.DependencyGraph=t.DenseStrategy=t.ArrayVertex=t.ArrayMapping=t.AddressMapping=void 0;var n=r(76);t.DependencyGraph=n.DependencyGraph;var o=r(147);t.AddressMapping=o.AddressMapping;var s=r(154);t.Graph=s.Graph;var i=r(155);t.TopSort=i.TopSort;var a=r(157);t.RangeMapping=a.RangeMapping;var u=r(158);t.SheetMapping=u.SheetMapping;var c=r(149);t.ArrayMapping=c.ArrayMapping;var l=r(151);t.FormulaCellVertex=l.FormulaCellVertex,t.ArrayVertex=l.ArrayVertex;var h=r(161);t.EmptyCellVertex=h.EmptyCellVertex;var d=r(162);t.ValueCellVertex=d.ValueCellVertex;var p=r(163);t.ParsingErrorVertex=p.ParsingErrorVertex;var m=r(153);t.RangeVertex=m.RangeVertex;var g=r(164);t.SparseStrategy=g.SparseStrategy;var f=r(165);t.DenseStrategy=f.DenseStrategy},function(e,t,r){"use strict";t.__esModule=!0,t.DependencyGraph=void 0,r(2);var n=r(73),o=r(77),s=r(74),i=r(139),a=r(132),u=r(141),c=r(140),l=r(78),h=r(142),d=r(143),p=r(75),m=r(147),g=r(149),f=r(150),E=r(151),T=r(154),y=r(157),A=r(158); +const a=t.WRONG_RANGE_SIZE="AbsoluteCellRange: Wrong range size";t.simpleCellRange=(e,t)=>({start:e,end:t});class u{constructor(e,t){if(e.sheet!==t.sheet)throw new o.SheetsNotEqual(e.sheet,t.sheet);this.start=(0,n.simpleCellAddress)(e.sheet,e.col,e.row),this.end=(0,n.simpleCellAddress)(t.sheet,t.col,t.row)}get sheet(){return this.start.sheet}static fromSimpleCellAddresses(e,t){if(e.sheet!==t.sheet)throw new o.SheetsNotEqual(e.sheet,t.sheet);const r=t.col-e.col,n=t.row-e.row;return Number.isFinite(n)&&Number.isFinite(r)?new u(e,t):Number.isFinite(n)?new l(e.sheet,e.row,t.row):new c(e.sheet,e.col,t.col)}static fromAst(e,t){return e.type===s.AstNodeType.CELL_RANGE?u.fromCellRange(e,t):e.type===s.AstNodeType.COLUMN_RANGE?c.fromColumnRange(e,t):l.fromRowRangeAst(e,t)}static fromAstOrUndef(e,t){try{return u.fromAst(e,t)}catch(e){return}}static fromCellRange(e,t){return new u(e.start.toSimpleCellAddress(t),e.end.toSimpleCellAddress(t))}static spanFrom(e,t,r){const n=u.spanFromOrUndef(e,t,r);if(void 0===n)throw new Error(a);return n}static spanFromOrUndef(e,t,r){if(!Number.isFinite(t)&&Number.isFinite(r)){if(0!==e.col)return;return new l(e.sheet,e.row,e.row+r-1)}if(!Number.isFinite(r)&&Number.isFinite(t)){if(0!==e.row)return;return new c(e.sheet,e.col,e.col+t-1)}if(Number.isFinite(r)&&Number.isFinite(t))return new u(e,(0,n.simpleCellAddress)(e.sheet,e.col+t-1,e.row+r-1))}static fromCoordinates(e,t,r,o,s){return new u((0,n.simpleCellAddress)(e,t,r),(0,n.simpleCellAddress)(e,o,s))}isFinite(){return Number.isFinite(this.size())}doesOverlap(e){return!(this.start.sheet!=e.start.sheet||this.end.rowe.end.row||this.end.cole.end.col)}addressInRange(e){return this.sheet===e.sheet&&this.start.row<=e.row&&this.end.row>=e.row&&this.start.col<=e.col&&this.end.col>=e.col}columnInRange(e){return this.sheet===e.sheet&&this.start.col<=e.col&&this.end.col>=e.col}rowInRange(e){return this.sheet===e.sheet&&this.start.row<=e.row&&this.end.row>=e.row}containsRange(e){return this.addressInRange(e.start)&&this.addressInRange(e.end)}intersectionWith(e){if(this.sheet!==e.start.sheet)return;const t=Math.max(this.start.row,e.start.row),r=Math.min(this.end.row,e.end.row),o=Math.max(this.start.col,e.start.col),s=Math.min(this.end.col,e.end.col);return t>r||o>s?void 0:new u((0,n.simpleCellAddress)(this.sheet,o,t),(0,n.simpleCellAddress)(this.sheet,s,r))}includesRow(e){return this.start.row=e}includesColumn(e){return this.start.col=e}shiftByRows(e){this.start.row+=e,this.end.row+=e}expandByRows(e){this.end.row+=e}shiftByColumns(e){this.start.col+=e,this.end.col+=e}shifted(e,t){return u.spanFrom((0,n.simpleCellAddress)(this.sheet,this.start.col+e,this.start.row+t),this.width(),this.height())}expandByColumns(e){this.end.col+=e}moveToSheet(e){this.start.sheet=e,this.end.sheet=e}removeSpan(e){e instanceof i.RowsSpan?this.removeRows(e.start,e.end):this.removeColumns(e.start,e.end)}shouldBeRemoved(){return this.width()<=0||this.height()<=0}rangeWithSameWidth(e,t){return u.spanFrom((0,n.simpleCellAddress)(this.sheet,this.start.col,e),this.width(),t)}rangeWithSameHeight(e,t){return u.spanFrom((0,n.simpleCellAddress)(this.sheet,e,this.start.row),t,this.height())}toString(){return`${this.start.sheet},${this.start.col},${this.start.row},${this.end.col},${this.end.row}`}width(){return this.end.col-this.start.col+1}height(){return this.end.row-this.start.row+1}size(){return this.height()*this.width()}arrayOfAddressesInRange(){const e=[];for(let t=0;t0)if(t>0){let e=this.effectiveEndRow(r);for(;e>=this.start.row;){let t=this.effectiveEndColumn(r);for(;t>=this.start.col;)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t-=1;e-=1}}else{let e=this.start.row;for(;e<=this.effectiveEndRow(r);){let t=this.effectiveEndColumn(r);for(;t>=this.start.col;)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t-=1;e+=1}}else if(t>0){let e=this.effectiveEndRow(r);for(;e>=this.start.row;){let t=this.start.col;for(;t<=this.effectiveEndColumn(r);)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t+=1;e-=1}}else{let e=this.start.row;for(;e<=this.effectiveEndRow(r);){let t=this.start.col;for(;t<=this.effectiveEndColumn(r);)yield(0,n.simpleCellAddress)(this.start.sheet,t,e),t+=1;e+=1}}}getAddress(e,t){if(e<0||t<0||t>this.height()-1||e>this.width()-1)throw Error("Index out of bound");return(0,n.simpleCellAddress)(this.start.sheet,this.start.col+e,this.start.row+t)}exceedsSheetSizeLimits(e,t){return this.end.col>=e||this.end.row>=t}effectiveEndColumn(e){return this.end.col}effectiveEndRow(e){return this.end.row}effectiveWidth(e){return this.width()}effectiveHeight(e){return this.height()}removeRows(e,t){if(!(e>this.end.row)){if(tthis.end.col)){if(t=e}effectiveEndRow(e){return this.effectiveHeight(e)-1}effectiveHeight(e){return e.getSheetHeight(this.sheet)}removeRows(e,t){}}t.AbsoluteColumnRange=c;class l extends u{constructor(e,t,r){super((0,n.simpleCellAddress)(e,0,t),(0,n.simpleCellAddress)(e,Number.POSITIVE_INFINITY,r))}static fromRowRangeAst(e,t){const r=e.start.toSimpleRowAddress(t),n=e.end.toSimpleRowAddress(t);if(r.sheet!==n.sheet)throw new o.SheetsNotEqual(r.sheet,n.sheet);return new l(r.sheet,r.row,n.row)}shouldBeRemoved(){return this.height()<=0}shiftByColumns(e){}expandByColumns(e){}shifted(e,t){return new l(this.sheet,this.start.row+t,this.end.row+t)}rangeWithSameWidth(e,t){return new l(this.sheet,e,e+t-1)}exceedsSheetSizeLimits(e,t){return this.end.row>=t}effectiveEndColumn(e){return this.effectiveWidth(e)-1}effectiveWidth(e){return e.getSheetWidth(this.sheet)}removeColumns(e,t){}}t.AbsoluteRowRange=l},function(e,t,r){"use strict";t.__esModule=!0,t.invalidSimpleRowAddress=t.invalidSimpleColumnAddress=t.invalidSimpleCellAddress=t.getCellValueType=t.getCellValueFormat=t.getCellValueDetailedType=t.getCellType=t.equalSimpleCellAddress=t.addressKey=t.absoluteSheetReference=t.ErrorType=t.CellValueTypeOrd=t.CellValueType=t.CellValueNoNumber=t.CellValueJustNumber=t.CellValueDetailedType=t.CellType=t.CellError=void 0,t.isSimpleCellAddress=function(e){var t,r,n;return e&&("object"==typeof e||"function"==typeof e)&&"number"==typeof(null===(t=e)||void 0===t?void 0:t.sheet)&&"number"==typeof(null===(r=e)||void 0===r?void 0:r.col)&&"number"==typeof(null===(n=e)||void 0===n?void 0:n.row)},t.simpleRowAddress=t.simpleColumnAddress=t.simpleCellAddress=t.movedSimpleCellAddress=void 0;var n,o,s,i,a=r(74),u=r(131),c=r(140),l=r(139);!function(e){e.DIV_BY_ZERO="DIV_BY_ZERO",e.NAME="NAME",e.VALUE="VALUE",e.NUM="NUM",e.NA="NA",e.CYCLE="CYCLE",e.REF="REF",e.SPILL="SPILL",e.LIC="LIC",e.ERROR="ERROR"}(n||(t.ErrorType=n={})),function(e){e.FORMULA="FORMULA",e.VALUE="VALUE",e.ARRAY="ARRAY",e.EMPTY="EMPTY",e.ARRAYFORMULA="ARRAYFORMULA"}(o||(t.CellType=o={})),t.getCellType=(e,t)=>e instanceof a.ArrayVertex?e.isLeftCorner(t)?o.ARRAYFORMULA:o.ARRAY:e instanceof a.FormulaCellVertex||e instanceof a.ParsingErrorVertex?o.FORMULA:e instanceof a.ValueCellVertex?o.VALUE:o.EMPTY,function(e){e.EMPTY="EMPTY",e.NUMBER="NUMBER",e.STRING="STRING",e.BOOLEAN="BOOLEAN",e.ERROR="ERROR"}(s||(t.CellValueNoNumber=s={})),function(e){e.NUMBER="NUMBER"}(i||(t.CellValueJustNumber=i={}));const h=t.CellValueType=Object.assign(Object.assign({},s),i);t.CellValueDetailedType=Object.assign(Object.assign({},s),c.NumberType),t.CellValueTypeOrd=e=>{switch(e){case h.EMPTY:return 0;case h.NUMBER:return 1;case h.STRING:return 2;case h.BOOLEAN:return 3;case h.ERROR:return 4}throw new Error("Cell value not computed")};const d=e=>{if(e===c.EmptyValue)return h.EMPTY;if(e instanceof p||e instanceof l.SimpleRangeValue)return h.ERROR;if("string"==typeof e)return h.STRING;if((0,c.isExtendedNumber)(e))return h.NUMBER;if("boolean"==typeof e)return h.BOOLEAN;throw new Error("Cell value not computed")};t.getCellValueType=d,t.getCellValueDetailedType=e=>(0,c.isExtendedNumber)(e)?(0,c.getTypeOfExtendedNumber)(e):d(e),t.getCellValueFormat=e=>(0,c.isExtendedNumber)(e)?(0,c.getFormatOfExtendedNumber)(e):void 0;class p{constructor(e,t,r){this.type=e,this.message=t,this.root=r}static parsingError(e){return new p(n.ERROR,`${u.ErrorMessage.ParseError}${e?" "+e:""}`)}attachRootVertex(e){return void 0===this.root?new p(this.type,this.message,e):this}}t.CellError=p,t.simpleRowAddress=(e,t)=>({sheet:e,row:t}),t.invalidSimpleRowAddress=e=>e.row<0,t.simpleColumnAddress=(e,t)=>({sheet:e,col:t}),t.invalidSimpleColumnAddress=e=>e.col<0;const m=(e,t,r)=>({sheet:e,col:t,row:r});t.simpleCellAddress=m,t.invalidSimpleCellAddress=e=>e.col<0||e.row<0,t.movedSimpleCellAddress=(e,t,r,n)=>m(t,e.col+r,e.row+n),t.addressKey=e=>`${e.sheet},${e.row},${e.col}`,t.absoluteSheetReference=(e,t)=>{var r;return null!==(r=e.sheet)&&void 0!==r?r:t.sheet},t.equalSimpleCellAddress=(e,t)=>e.sheet===t.sheet&&e.col===t.col&&e.row===t.row},function(e,t,r){"use strict";t.__esModule=!0,t.ValueCellVertex=t.TopSort=t.SparseStrategy=t.SheetMapping=t.RangeVertex=t.RangeMapping=t.ParsingErrorVertex=t.Graph=t.FormulaCellVertex=t.EmptyCellVertex=t.DependencyGraph=t.DenseStrategy=t.ArrayVertex=t.ArrayMapping=t.AddressMapping=void 0;var n=r(75);t.DependencyGraph=n.DependencyGraph;var o=r(146);t.AddressMapping=o.AddressMapping;var s=r(153);t.Graph=s.Graph;var i=r(154);t.TopSort=i.TopSort;var a=r(156);t.RangeMapping=a.RangeMapping;var u=r(157);t.SheetMapping=u.SheetMapping;var c=r(148);t.ArrayMapping=c.ArrayMapping;var l=r(150);t.FormulaCellVertex=l.FormulaCellVertex,t.ArrayVertex=l.ArrayVertex;var h=r(160);t.EmptyCellVertex=h.EmptyCellVertex;var d=r(161);t.ValueCellVertex=d.ValueCellVertex;var p=r(162);t.ParsingErrorVertex=p.ParsingErrorVertex;var m=r(152);t.RangeVertex=m.RangeVertex;var g=r(163);t.SparseStrategy=g.SparseStrategy;var f=r(164);t.DenseStrategy=f.DenseStrategy},function(e,t,r){"use strict";t.__esModule=!0,t.DependencyGraph=void 0,r(2);var n=r(72),o=r(76),s=r(73),i=r(138),a=r(131),u=r(140),c=r(139),l=r(77),h=r(141),d=r(142),p=r(74),m=r(146),g=r(148),f=r(149),E=r(150),T=r(153),y=r(156),A=r(157); /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ -class R{constructor(e,t,r,a,u,c,h,d){this.addressMapping=e,this.rangeMapping=t,this.sheetMapping=r,this.arrayMapping=a,this.stats=u,this.lazilyTransformingAstService=c,this.functionRegistry=h,this.namedExpressions=d,this.changes=i.ContentChanges.empty(),this.dependencyQueryAddresses=e=>{if(e instanceof p.RangeVertex)return this.rangeDependencyQuery(e).map(([e,t])=>e);{const t=this.formulaDependencyQuery(e);if(void 0!==t){const[e,r]=t;return r.map(t=>t instanceof l.NamedExpressionDependency?this.namedExpressions.namedExpressionOrPlaceholder(t.name,e.sheet).address:(0,s.isSimpleCellAddress)(t)?t:(0,n.simpleCellRange)(t.start,t.end))}return[]}},this.dependencyQueryVertices=e=>{if(e instanceof p.RangeVertex)return this.rangeDependencyQuery(e);{const t=this.formulaDependencyQuery(e);if(void 0!==t){const[e,r]=t;return r.map(t=>{if(t instanceof n.AbsoluteCellRange)return[t.start,this.rangeMapping.fetchRange(t.start,t.end)];if(t instanceof l.NamedExpressionDependency){const r=this.namedExpressions.namedExpressionOrPlaceholder(t.name,e.sheet);return[r.address,this.addressMapping.fetchCell(r.address)]}return[t,this.addressMapping.fetchCell(t)]})}return[]}},this.rangeDependencyQuery=e=>{const t=[],{smallerRangeVertex:r,restRange:o}=this.rangeMapping.findSmallerRange(e.range);let s;void 0!==r&&this.graph.adjacentNodes(r).has(e)?(s=o,t.push([new n.AbsoluteCellRange(r.start,r.end),r])):s=e.range;for(const e of s.addresses(this)){const r=this.addressMapping.getCell(e);void 0!==r&&t.push([e,r])}return t},this.formulaDependencyQuery=e=>{let t,r;if(!(e instanceof E.FormulaVertex))return;r=e.getAddress(this.lazilyTransformingAstService),t=e.getFormula(this.lazilyTransformingAstService);const n=(0,l.collectDependencies)(t,this.functionRegistry);return[r,(0,o.absolutizeDependencies)(n,r)]},this.graph=new T.Graph(this.dependencyQueryVertices)}static buildEmpty(e,t,r,n,o){return new R(new m.AddressMapping(t.chooseAddressMappingPolicy),new y.RangeMapping,new A.SheetMapping(t.translationPackage),new g.ArrayMapping,o,e,r,n)}setFormulaToCell(e,t,r,n,o,s){const i=E.FormulaVertex.fromAst(t,e,n,this.lazilyTransformingAstService.version());return this.exchangeOrAddFormulaVertex(i),this.processCellDependencies(r,i),this.graph.markNodeAsDirty(i),o&&this.markAsVolatile(i),s&&this.markAsDependentOnStructureChange(i),this.correctInfiniteRangesDependency(e),this.getAndClearContentChanges()}setParsingErrorToCell(e,t){const r=this.shrinkPossibleArrayAndGetCell(e);return this.exchangeOrAddGraphNode(r,t),this.addressMapping.setCell(e,t),this.graph.markNodeAsDirty(t),this.correctInfiniteRangesDependency(e),this.getAndClearContentChanges()}setValueToCell(e,t){const r=this.shrinkPossibleArrayAndGetCell(e);if(r instanceof p.ArrayVertex&&this.arrayMapping.removeArray(r.getRange()),r instanceof p.ValueCellVertex)r.getValues().rawValue!==t.rawValue&&(r.setValues(t),this.graph.markNodeAsDirty(r));else{const n=new p.ValueCellVertex(t.parsedValue,t.rawValue);this.exchangeOrAddGraphNode(r,n),this.addressMapping.setCell(e,n),this.graph.markNodeAsDirty(n)}return this.correctInfiniteRangesDependency(e),this.getAndClearContentChanges()}setCellEmpty(e){const t=this.shrinkPossibleArrayAndGetCell(e);if(void 0===t)return i.ContentChanges.empty();if(this.graph.adjacentNodes(t).size>0){const r=new p.EmptyCellVertex;this.exchangeGraphNode(t,r),0===this.graph.adjacentNodesCount(r)?(this.removeVertex(r),this.addressMapping.removeCell(e)):(this.graph.markNodeAsDirty(r),this.addressMapping.setCell(e,r))}else this.removeVertex(t),this.addressMapping.removeCell(e);return this.getAndClearContentChanges()}clearDirtyVertices(){this.graph.clearDirtyNodes()}verticesToRecompute(){return this.graph.getDirtyAndVolatileNodes()}processCellDependencies(e,t){const r=this.graph.getNodeId(t);e.forEach(e=>{if(e instanceof n.AbsoluteCellRange){const t=e;let n=this.getRange(t.start,t.end);void 0===n&&(n=new p.RangeVertex(t),this.rangeMapping.setRange(n)),this.graph.addNodeAndReturnId(n);const o=this.graph.getNodeId(n);t.isFinite()||this.graph.markNodeAsInfiniteRange(o);const{smallerRangeVertex:s,restRange:i}=this.rangeMapping.findSmallerRange(t);if(void 0!==s){if(this.graph.addEdge(s,o),n.bruteForce){n.bruteForce=!1;for(const e of t.addresses(this))this.graph.removeEdge(this.fetchCell(e),o)}}else n.bruteForce=!0;const a=this.arrayMapping.getArray(i);if(void 0!==a)this.graph.addEdge(a,o);else for(const e of i.addresses(this)){const{vertex:t,id:r}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=r?r:t,o)}this.graph.addEdge(o,r),t.isFinite()&&this.correctInfiniteRangesDependenciesByRangeVertex(n)}else if(e instanceof l.NamedExpressionDependency){const n=t.getAddress(this.lazilyTransformingAstService).sheet,{vertex:o,id:s}=this.fetchNamedExpressionVertex(e.name,n);this.graph.addEdge(null!=s?s:o,r)}else{const{vertex:t,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:t,r)}})}fetchNamedExpressionVertex(e,t){const r=this.namedExpressions.namedExpressionOrPlaceholder(e,t);return this.fetchCellOrCreateEmpty(r.address)}exchangeNode(e,t){const r=this.fetchCellOrCreateEmpty(e).vertex,n=this.fetchCellOrCreateEmpty(t).vertex;this.addressMapping.removeCell(e),this.exchangeGraphNode(r,n)}fetchCellOrCreateEmpty(e){const t=this.addressMapping.getCell(e);if(void 0!==t)return{vertex:t,id:void 0};const r=new p.EmptyCellVertex,n=this.graph.addNodeAndReturnId(r);return this.addressMapping.setCell(e,r),{vertex:r,id:n}}removeRows(e){this.stats.measure(d.StatType.ADJUSTING_GRAPH,()=>{for(const[t,r]of this.addressMapping.entriesFromRowsSpan(e)){for(const e of this.graph.adjacentNodes(r))this.graph.markNodeAsDirty(e);if(r instanceof p.ArrayVertex){if(!r.isLeftCorner(t))continue;this.shrinkArrayToCorner(r),this.arrayMapping.removeArray(r.getRange())}this.removeVertex(r)}}),this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.removeRows(e)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.truncateRanges(e,e=>e.row);return this.getArrayVerticesRelatedToRanges(t)});return this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>{this.fixArraysAfterRemovingRows(e.sheet,e.rowStart,e.numberOfRows)}),this.addStructuralNodesToChangeSet(),{affectedArrays:t,contentChanges:this.getAndClearContentChanges()}}removeSheet(e){this.clearSheet(e);for(const[t,r]of this.addressMapping.sheetEntries(e)){for(const e of this.graph.adjacentNodes(r))this.graph.markNodeAsDirty(e);this.removeVertex(r),this.addressMapping.removeCell(t)}this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.rangeMapping.removeRangesInSheet(e);for(const e of t)this.removeVertex(e);this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.removeSheet(e)})})}clearSheet(e){const t=new Set;for(const[r,n]of this.addressMapping.sheetEntries(e))n instanceof p.ArrayVertex?t.add(n):this.setCellEmpty(r);for(const e of t.values())this.setArrayEmpty(e);this.addStructuralNodesToChangeSet()}removeColumns(e){this.stats.measure(d.StatType.ADJUSTING_GRAPH,()=>{for(const[t,r]of this.addressMapping.entriesFromColumnsSpan(e)){for(const e of this.graph.adjacentNodes(r))this.graph.markNodeAsDirty(e);if(r instanceof p.ArrayVertex){if(!r.isLeftCorner(t))continue;this.shrinkArrayToCorner(r),this.arrayMapping.removeArray(r.getRange())}this.removeVertex(r)}}),this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.removeColumns(e)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.truncateRanges(e,e=>e.col);return this.getArrayVerticesRelatedToRanges(t)});return this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>this.fixArraysAfterRemovingColumns(e.sheet,e.columnStart,e.numberOfColumns)),this.addStructuralNodesToChangeSet(),{affectedArrays:t,contentChanges:this.getAndClearContentChanges()}}addRows(e){this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.addRows(e.sheet,e.rowStart,e.numberOfRows)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.rangeMapping.moveAllRangesInSheetAfterRowByRows(e.sheet,e.rowStart,e.numberOfRows);return this.fixRangesWhenAddingRows(e.sheet,e.rowStart,e.numberOfRows),this.getArrayVerticesRelatedToRanges(t.verticesWithChangedSize)});this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>{this.fixArraysAfterAddingRow(e.sheet,e.rowStart,e.numberOfRows)});for(const t of this.addressMapping.verticesFromRowsSpan(e))this.graph.markNodeAsDirty(t);return this.addStructuralNodesToChangeSet(),{affectedArrays:t}}addColumns(e){this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.addColumns(e.sheet,e.columnStart,e.numberOfColumns)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.rangeMapping.moveAllRangesInSheetAfterColumnByColumns(e.sheet,e.columnStart,e.numberOfColumns);return this.fixRangesWhenAddingColumns(e.sheet,e.columnStart,e.numberOfColumns),this.getArrayVerticesRelatedToRanges(t.verticesWithChangedSize)});this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>this.fixArraysAfterAddingColumn(e.sheet,e.columnStart,e.numberOfColumns));for(const t of this.addressMapping.verticesFromColumnsSpan(e))this.graph.markNodeAsDirty(t);return this.addStructuralNodesToChangeSet(),{affectedArrays:t,contentChanges:this.getAndClearContentChanges()}}isThereSpaceForArray(e){const t=e.getRangeOrUndef();if(void 0===t)return!1;for(const r of t.addresses(this)){const t=this.addressMapping.getCell(r);if(void 0!==t&&!(t instanceof p.EmptyCellVertex)&&t!==e)return!1}return!0}moveCells(e,t,r,n){for(const o of e.addressesWithDirection(t,r,this)){const i=(0,s.simpleCellAddress)(n,o.col+t,o.row+r);let a=this.addressMapping.getCell(o);const u=this.addressMapping.getCell(i);if(this.addressMapping.removeCell(o),void 0!==a){this.graph.markNodeAsDirty(a),this.addressMapping.setCell(i,a);let t=void 0;for(const r of this.graph.adjacentNodes(a))r instanceof p.RangeVertex&&!e.containsRange(r.range)&&(t=null!=t?t:this.fetchCellOrCreateEmpty(o).vertex,this.graph.addEdge(t,r),this.graph.removeEdge(a,r));t&&(this.graph.markNodeAsDirty(t),this.addressMapping.setCell(o,t))}if(void 0!==u){void 0===a&&this.addressMapping.removeCell(i);for(const e of this.graph.adjacentNodes(u))a=null!=a?a:this.fetchCellOrCreateEmpty(i).vertex,this.graph.addEdge(a,e),this.graph.markNodeAsDirty(a);this.removeVertex(u)}}for(const t of this.rangeMapping.rangeVerticesContainedInRange(e))for(const r of this.graph.adjacentNodes(t))if(r instanceof p.RangeVertex&&!e.containsRange(r.range)){this.graph.removeEdge(t,r);for(const e of t.range.addresses(this)){const{vertex:t,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:t,r),this.addressMapping.setCell(e,t),this.graph.markNodeAsDirty(t)}}this.rangeMapping.moveRangesInsideSourceRange(e,t,r,n)}setArrayEmpty(e){const t=n.AbsoluteCellRange.spanFrom(e.getAddress(this.lazilyTransformingAstService),e.width,e.height),r=this.graph.adjacentNodes(e);for(const e of t.addresses(this))this.addressMapping.removeCell(e);for(const t of r.values()){const r=(0,f.collectAddressesDependentToRange)(this.functionRegistry,t,e.getRange(),this.lazilyTransformingAstService,this);for(const e of r){const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:r,t)}r.length>0&&this.graph.markNodeAsDirty(t)}this.removeVertex(e),this.arrayMapping.removeArray(e.getRange())}addVertex(e,t){this.graph.addNodeAndReturnId(t),this.addressMapping.setCell(e,t)}addArrayVertex(e,t){this.graph.addNodeAndReturnId(t),this.setAddressMappingForArrayVertex(t,e)}*arrayFormulaNodes(){for(const e of this.graph.getNodes())e instanceof p.ArrayVertex&&(yield e)}*entriesFromRowsSpan(e){yield*this.addressMapping.entriesFromRowsSpan(e)}*entriesFromColumnsSpan(e){yield*this.addressMapping.entriesFromColumnsSpan(e)}fetchCell(e){return this.addressMapping.fetchCell(e)}getCell(e){return this.addressMapping.getCell(e)}getCellValue(e){return this.addressMapping.getCellValue(e)}getRawValue(e){return this.addressMapping.getRawValue(e)}getScalarValue(e){const t=this.addressMapping.getCellValue(e);return t instanceof c.SimpleRangeValue?new s.CellError(s.ErrorType.VALUE,a.ErrorMessage.ScalarExpected):t}existsEdge(e,t){return this.graph.existsEdge(e,t)}getSheetId(e){return this.sheetMapping.fetch(e)}getSheetHeight(e){return this.addressMapping.getHeight(e)}getSheetWidth(e){return this.addressMapping.getWidth(e)}getArray(e){return this.arrayMapping.getArray(e)}getRange(e,t){return this.rangeMapping.getRange(e,t)}topSortWithScc(){return this.graph.topSortWithScc()}markAsVolatile(e){this.graph.markNodeAsVolatile(e)}markAsDependentOnStructureChange(e){this.graph.markNodeAsChangingWithStructure(e)}forceApplyPostponedTransformations(){for(const e of this.graph.getNodes())e instanceof p.FormulaCellVertex&&e.ensureRecentData(this.lazilyTransformingAstService)}*rawValuesFromRange(e){for(const t of e.addresses(this)){const e=this.getScalarValue(t);e!==u.EmptyValue&&(yield[(0,u.getRawValue)(e),t])}}computeListOfValuesInRange(e){const t=[];for(const r of e.addresses(this)){const e=this.getScalarValue(r);t.push(e)}return t}shrinkArrayToCorner(e){this.cleanAddressMappingUnderArray(e);for(const t of this.adjacentArrayVertices(e)){let r;r=t instanceof E.FormulaVertex?this.formulaDirectDependenciesToArray(t,e):this.rangeDirectDependenciesToArray(t,e);let n=!1;for(const[o,s]of r)e.isLeftCorner(o)&&(n=!0),this.graph.addEdge(s,t),this.graph.markNodeAsDirty(s);n||this.graph.removeEdge(e,t)}this.graph.markNodeAsDirty(e)}isArrayInternalCell(e){const t=this.getCell(e);return t instanceof p.ArrayVertex&&!t.isLeftCorner(e)}getAndClearContentChanges(){const e=this.changes;return this.changes=i.ContentChanges.empty(),e}getAdjacentNodesAddresses(e){const t=this.graph.adjacentNodes(e),r=[];return t.forEach(e=>{const t=e;t instanceof p.RangeVertex?r.push((0,n.simpleCellRange)(t.start,t.end)):r.push(t.getAddress(this.lazilyTransformingAstService))}),r}exchangeGraphNode(e,t){this.graph.addNodeAndReturnId(t);const r=this.graph.adjacentNodes(e);this.removeVertex(e),r.forEach(e=>{this.graph.hasNode(e)&&this.graph.addEdge(t,e)})}setArray(e,t){this.arrayMapping.setArray(e,t)}correctInfiniteRangesDependency(e){const t=this.graph.getInfiniteRanges().filter(({node:t})=>t.range.addressInRange(e));if(t.length<=0)return;const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(e),o=null!=n?n:this.graph.getNodeId(r);t.forEach(({id:e})=>{this.graph.addEdge(o,e)})}exchangeOrAddGraphNode(e,t){e?this.exchangeGraphNode(e,t):this.graph.addNodeAndReturnId(t)}getArrayVerticesRelatedToRanges(e){const t=new Set;return e.forEach(e=>{this.graph.hasNode(e)&&this.graph.adjacentNodes(e).forEach(e=>{e instanceof p.ArrayVertex&&t.add(e)})}),t}correctInfiniteRangesDependenciesByRangeVertex(e){this.graph.getInfiniteRanges().forEach(({id:t,node:r})=>{const n=e.range.intersectionWith(r.range);void 0!==n&&n.addresses(this).forEach(e=>{const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:r,t)})})}cleanAddressMappingUnderArray(e){const t=e.getRange();for(const r of t.addresses(this)){const t=e.getArrayCellValue(r);this.getCell(r)===e?e.isLeftCorner(r)?this.changes.addChange(new s.CellError(s.ErrorType.REF),r,t):(this.addressMapping.removeCell(r),this.changes.addChange(u.EmptyValue,r,t)):this.changes.addChange(u.EmptyValue,r,t)}}*formulaDirectDependenciesToArray(e,t){var r;const[,o]=null!==(r=this.formulaDependencyQuery(e))&&void 0!==r?r:[];if(void 0!==o)for(const e of o)if(!(e instanceof l.NamedExpressionDependency||e instanceof n.AbsoluteCellRange)&&t.getRange().addressInRange(e)){const t=this.fetchCellOrCreateEmpty(e).vertex;yield[e,t]}}*rangeDirectDependenciesToArray(e,t){const{restRange:r}=this.rangeMapping.findSmallerRange(e.range);for(const e of r.addresses(this))if(t.getRange().addressInRange(e)){const t=this.fetchCellOrCreateEmpty(e).vertex;yield[e,t]}}*adjacentArrayVertices(e){const t=this.graph.adjacentNodes(e);for(const e of t)(e instanceof E.FormulaVertex||e instanceof p.RangeVertex)&&(yield e)}addStructuralNodesToChangeSet(){this.graph.markChangingWithStructureNodesAsDirty()}fixRangesWhenAddingRows(e,t,r){const o=Array.from(this.rangeMapping.rangesInSheet(e));for(const e of o)if(e.range.includesRow(t+r))if(e.bruteForce){const n=e.range.rangeWithSameWidth(t,r);for(const t of n.addresses(this)){const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(t);this.graph.addEdge(null!=n?n:r,e)}}else{let t=e,r=this.rangeMapping.findSmallerRange(t.range);if(void 0!==r.smallerRangeVertex)continue;for(;void 0===r.smallerRangeVertex;){const e=new p.RangeVertex(n.AbsoluteCellRange.spanFrom(t.range.start,t.range.width(),t.range.height()-1));this.rangeMapping.setRange(e),this.graph.addNodeAndReturnId(e);const o=new n.AbsoluteCellRange((0,s.simpleCellAddress)(t.range.start.sheet,t.range.start.col,t.range.end.row),t.range.end);this.addAllFromRange(o,t),this.graph.addEdge(e,t),t=e,r=this.rangeMapping.findSmallerRange(t.range)}this.graph.addEdge(r.smallerRangeVertex,t),this.addAllFromRange(r.restRange,t),this.graph.removeEdge(r.smallerRangeVertex,e)}}addAllFromRange(e,t){for(const r of e.addresses(this)){const{vertex:e,id:n}=this.fetchCellOrCreateEmpty(r);this.graph.addEdge(null!=n?n:e,t)}}fixRangesWhenAddingColumns(e,t,r){for(const o of this.rangeMapping.rangesInSheet(e))if(o.range.includesColumn(t+r)){let i;i=o.bruteForce?o.range.rangeWithSameHeight(t,r):n.AbsoluteCellRange.spanFrom((0,s.simpleCellAddress)(e,t,o.range.end.row),r,1);for(const e of i.addresses(this)){const{vertex:t,id:r}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=r?r:t,o)}}}exchangeOrAddFormulaVertex(e){const t=e.getAddress(this.lazilyTransformingAstService),r=n.AbsoluteCellRange.spanFrom(t,e.width,e.height),o=this.shrinkPossibleArrayAndGetCell(t);if(e instanceof p.ArrayVertex&&this.setArray(r,e),this.exchangeOrAddGraphNode(o,e),this.addressMapping.setCell(t,e),e instanceof p.ArrayVertex){if(!this.isThereSpaceForArray(e))return;for(const t of r.addresses(this)){if(e.isLeftCorner(t))continue;const r=this.getCell(t);this.exchangeOrAddGraphNode(r,e)}}for(const t of r.addresses(this))this.addressMapping.setCell(t,e)}setAddressMappingForArrayVertex(e,t){if(this.addressMapping.setCell(t,e),!(e instanceof p.ArrayVertex))return;const r=n.AbsoluteCellRange.spanFromOrUndef(t,e.width,e.height);if(void 0!==r&&(this.setArray(r,e),this.isThereSpaceForArray(e)))for(const t of r.addresses(this))this.addressMapping.setCell(t,e)}truncateRanges(e,t){const{verticesToRemove:r,verticesToMerge:n,verticesWithChangedSize:o}=this.rangeMapping.truncateRanges(e,t);for(const[e,t]of n)this.mergeRangeVertices(e,t);for(const e of r)this.removeVertexAndCleanupDependencies(e);return o}fixArraysAfterAddingRow(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterRowByRows(e,t,r),!(t<=0))for(const[,n]of this.arrayMapping.arraysInRows(h.RowsSpan.fromRowStartAndEnd(e,t-1,t-1))){const o=n.getRange();for(let i=o.start.col;i<=o.end.col;++i)for(let a=t;a<=o.end.row;++a){const t=(0,s.simpleCellAddress)(e,i,a),o=(0,s.simpleCellAddress)(e,i,a+r),c=n.getArrayCellValue(t);this.addressMapping.moveCell(o,t),this.changes.addChange(u.EmptyValue,o,c)}}}fixArraysAfterRemovingRows(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterRowByRows(e,t,-r),!(t<=0))for(const[,r]of this.arrayMapping.arraysInRows(h.RowsSpan.fromRowStartAndEnd(e,t-1,t-1)))if(this.isThereSpaceForArray(r))for(const e of r.getRange().addresses(this))this.addressMapping.setCell(e,r);else this.setNoSpaceIfArray(r)}fixArraysAfterAddingColumn(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterColumnByColumns(e,t,r),!(t<=0))for(const[,n]of this.arrayMapping.arraysInCols(h.ColumnsSpan.fromColumnStartAndEnd(e,t-1,t-1))){const o=n.getRange();for(let i=o.start.row;i<=o.end.row;++i)for(let a=t;a<=o.end.col;++a){const t=(0,s.simpleCellAddress)(e,a,i),o=(0,s.simpleCellAddress)(e,a+r,i),c=n.getArrayCellValue(t);this.addressMapping.moveCell(o,t),this.changes.addChange(u.EmptyValue,o,c)}}}fixArraysAfterRemovingColumns(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterColumnByColumns(e,t,-r),!(t<=0))for(const[,r]of this.arrayMapping.arraysInCols(h.ColumnsSpan.fromColumnStartAndEnd(e,t-1,t-1)))if(this.isThereSpaceForArray(r))for(const e of r.getRange().addresses(this))this.addressMapping.setCell(e,r);else this.setNoSpaceIfArray(r)}shrinkPossibleArrayAndGetCell(e){const t=this.getCell(e);return t instanceof p.ArrayVertex?(this.setNoSpaceIfArray(t),this.getCell(e)):t}setNoSpaceIfArray(e){e instanceof p.ArrayVertex&&(this.shrinkArrayToCorner(e),e.setNoSpace())}removeVertex(e){this.removeVertexAndCleanupDependencies(e),e instanceof p.RangeVertex&&this.rangeMapping.removeRange(e)}mergeRangeVertices(e,t){const r=this.graph.adjacentNodes(t);this.removeVertexAndCleanupDependencies(t),this.graph.removeEdgeIfExists(e,t),r.forEach(t=>{this.graph.hasNode(t)&&this.graph.addEdge(e,t)})}removeVertexAndCleanupDependencies(e){const t=new Set(this.graph.removeNode(e));for(;t.size>0;){const e=t.values().next().value;t.delete(e);const[r,n]=e;this.graph.hasNode(n)&&0===this.graph.adjacentNodesCount(n)&&((n instanceof p.RangeVertex||n instanceof p.EmptyCellVertex)&&this.graph.removeNode(n).forEach(e=>t.add(e)),n instanceof p.RangeVertex?this.rangeMapping.removeRange(n):n instanceof p.EmptyCellVertex&&this.addressMapping.removeCell(r))}}}t.DependencyGraph=R},function(e,t,r){"use strict";t.__esModule=!0,t.filterDependenciesOutOfScope=t.absolutizeDependencies=void 0;var n=r(73),o=r(74),s=r(78);t.absolutizeDependencies=(e,t)=>e.map(e=>e.absolutize(t)),t.filterDependenciesOutOfScope=e=>e.filter(e=>e instanceof s.NamedExpressionDependency||(e instanceof n.AbsoluteCellRange?!((0,o.invalidSimpleCellAddress)(e.start)||(0,o.invalidSimpleCellAddress)(e.end)):!(0,o.invalidSimpleCellAddress)(e)))},function(e,t,r){"use strict";t.__esModule=!0,t.simpleCellRangeToString=t.simpleCellRangeFromString=t.simpleCellAddressToString=t.simpleCellAddressFromString=t.collectDependencies=t.cellAddressFromString=t.buildProcedureAst=t.buildParsingErrorAst=t.buildLexerConfig=t.buildCellRangeAst=t.buildCellErrorAst=t.Unparser=t.RowRangeDependency=t.ParsingErrorType=t.ParserWithCaching=t.NamedExpressionDependency=t.FormulaLexer=t.ColumnRangeDependency=t.CellRangeDependency=t.CellAddress=t.AstNodeType=t.AddressDependency=void 0;var n=r(79);t.cellAddressFromString=n.cellAddressFromString,t.simpleCellAddressFromString=n.simpleCellAddressFromString,t.simpleCellAddressToString=n.simpleCellAddressToString,t.simpleCellRangeFromString=n.simpleCellRangeFromString,t.simpleCellRangeToString=n.simpleCellRangeToString;var o=r(80);t.CellAddress=o.CellAddress;var s=r(84);t.ParserWithCaching=s.ParserWithCaching;var i=r(137);t.collectDependencies=i.collectDependencies;var a=r(133);t.buildLexerConfig=a.buildLexerConfig;var u=r(131);t.FormulaLexer=u.FormulaLexer;var c=r(128);t.AstNodeType=c.AstNodeType,t.ParsingErrorType=c.ParsingErrorType,t.buildProcedureAst=c.buildProcedureAst,t.buildCellRangeAst=c.buildCellRangeAst,t.buildParsingErrorAst=c.buildParsingErrorAst,t.buildCellErrorAst=c.buildCellErrorAst;var l=r(136);t.Unparser=l.Unparser;var h=r(138);t.AddressDependency=h.AddressDependency,t.CellRangeDependency=h.CellRangeDependency,t.ColumnRangeDependency=h.ColumnRangeDependency,t.RowRangeDependency=h.RowRangeDependency,t.NamedExpressionDependency=h.NamedExpressionDependency},function(e,t,r){"use strict";t.__esModule=!0,t.columnAddressFromString=t.cellAddressFromString=void 0,t.columnIndexToLabel=f,t.rowAddressFromString=void 0,t.sheetIndexToString=E,t.simpleCellRangeToString=t.simpleCellRangeFromString=t.simpleCellAddressToString=t.simpleCellAddressFromString=void 0;var n=r(73),o=r(74),s=r(80),i=r(81),a=r(83),u=r(82); +class R{constructor(e,t,r,a,u,c,h,d){this.addressMapping=e,this.rangeMapping=t,this.sheetMapping=r,this.arrayMapping=a,this.stats=u,this.lazilyTransformingAstService=c,this.functionRegistry=h,this.namedExpressions=d,this.changes=i.ContentChanges.empty(),this.dependencyQueryAddresses=e=>{if(e instanceof p.RangeVertex)return this.rangeDependencyQuery(e).map(([e,t])=>e);{const t=this.formulaDependencyQuery(e);if(void 0!==t){const[e,r]=t;return r.map(t=>t instanceof l.NamedExpressionDependency?this.namedExpressions.namedExpressionOrPlaceholder(t.name,e.sheet).address:(0,s.isSimpleCellAddress)(t)?t:(0,n.simpleCellRange)(t.start,t.end))}return[]}},this.dependencyQueryVertices=e=>{if(e instanceof p.RangeVertex)return this.rangeDependencyQuery(e);{const t=this.formulaDependencyQuery(e);if(void 0!==t){const[e,r]=t;return r.map(t=>{if(t instanceof n.AbsoluteCellRange)return[t.start,this.rangeMapping.fetchRange(t.start,t.end)];if(t instanceof l.NamedExpressionDependency){const r=this.namedExpressions.namedExpressionOrPlaceholder(t.name,e.sheet);return[r.address,this.addressMapping.fetchCell(r.address)]}return[t,this.addressMapping.fetchCell(t)]})}return[]}},this.rangeDependencyQuery=e=>{const t=[],{smallerRangeVertex:r,restRange:o}=this.rangeMapping.findSmallerRange(e.range);let s;void 0!==r&&this.graph.adjacentNodes(r).has(e)?(s=o,t.push([new n.AbsoluteCellRange(r.start,r.end),r])):s=e.range;for(const e of s.addresses(this)){const r=this.addressMapping.getCell(e);void 0!==r&&t.push([e,r])}return t},this.formulaDependencyQuery=e=>{let t,r;if(!(e instanceof E.FormulaVertex))return;r=e.getAddress(this.lazilyTransformingAstService),t=e.getFormula(this.lazilyTransformingAstService);const n=(0,l.collectDependencies)(t,this.functionRegistry);return[r,(0,o.absolutizeDependencies)(n,r)]},this.graph=new T.Graph(this.dependencyQueryVertices)}static buildEmpty(e,t,r,n,o){return new R(new m.AddressMapping(t.chooseAddressMappingPolicy),new y.RangeMapping,new A.SheetMapping(t.translationPackage),new g.ArrayMapping,o,e,r,n)}setFormulaToCell(e,t,r,n,o,s){const i=E.FormulaVertex.fromAst(t,e,n,this.lazilyTransformingAstService.version());return this.exchangeOrAddFormulaVertex(i),this.processCellDependencies(r,i),this.graph.markNodeAsDirty(i),o&&this.markAsVolatile(i),s&&this.markAsDependentOnStructureChange(i),this.correctInfiniteRangesDependency(e),this.getAndClearContentChanges()}setParsingErrorToCell(e,t){const r=this.shrinkPossibleArrayAndGetCell(e);return this.exchangeOrAddGraphNode(r,t),this.addressMapping.setCell(e,t),this.graph.markNodeAsDirty(t),this.correctInfiniteRangesDependency(e),this.getAndClearContentChanges()}setValueToCell(e,t){const r=this.shrinkPossibleArrayAndGetCell(e);if(r instanceof p.ArrayVertex&&this.arrayMapping.removeArray(r.getRange()),r instanceof p.ValueCellVertex)r.getValues().rawValue!==t.rawValue&&(r.setValues(t),this.graph.markNodeAsDirty(r));else{const n=new p.ValueCellVertex(t.parsedValue,t.rawValue);this.exchangeOrAddGraphNode(r,n),this.addressMapping.setCell(e,n),this.graph.markNodeAsDirty(n)}return this.correctInfiniteRangesDependency(e),this.getAndClearContentChanges()}setCellEmpty(e){const t=this.shrinkPossibleArrayAndGetCell(e);if(void 0===t)return i.ContentChanges.empty();if(this.graph.adjacentNodes(t).size>0){const r=new p.EmptyCellVertex;this.exchangeGraphNode(t,r),0===this.graph.adjacentNodesCount(r)?(this.removeVertex(r),this.addressMapping.removeCell(e)):(this.graph.markNodeAsDirty(r),this.addressMapping.setCell(e,r))}else this.removeVertex(t),this.addressMapping.removeCell(e);return this.getAndClearContentChanges()}clearDirtyVertices(){this.graph.clearDirtyNodes()}verticesToRecompute(){return this.graph.getDirtyAndVolatileNodes()}processCellDependencies(e,t){const r=this.graph.getNodeId(t);e.forEach(e=>{if(e instanceof n.AbsoluteCellRange){const t=e;let n=this.getRange(t.start,t.end);void 0===n&&(n=new p.RangeVertex(t),this.rangeMapping.setRange(n)),this.graph.addNodeAndReturnId(n);const o=this.graph.getNodeId(n);t.isFinite()||this.graph.markNodeAsInfiniteRange(o);const{smallerRangeVertex:s,restRange:i}=this.rangeMapping.findSmallerRange(t);if(void 0!==s){if(this.graph.addEdge(s,o),n.bruteForce){n.bruteForce=!1;for(const e of t.addresses(this))this.graph.removeEdge(this.fetchCell(e),o)}}else n.bruteForce=!0;const a=this.arrayMapping.getArray(i);if(void 0!==a)this.graph.addEdge(a,o);else for(const e of i.addresses(this)){const{vertex:t,id:r}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=r?r:t,o)}this.graph.addEdge(o,r),t.isFinite()&&this.correctInfiniteRangesDependenciesByRangeVertex(n)}else if(e instanceof l.NamedExpressionDependency){const n=t.getAddress(this.lazilyTransformingAstService).sheet,{vertex:o,id:s}=this.fetchNamedExpressionVertex(e.name,n);this.graph.addEdge(null!=s?s:o,r)}else{const{vertex:t,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:t,r)}})}fetchNamedExpressionVertex(e,t){const r=this.namedExpressions.namedExpressionOrPlaceholder(e,t);return this.fetchCellOrCreateEmpty(r.address)}exchangeNode(e,t){const r=this.fetchCellOrCreateEmpty(e).vertex,n=this.fetchCellOrCreateEmpty(t).vertex;this.addressMapping.removeCell(e),this.exchangeGraphNode(r,n)}fetchCellOrCreateEmpty(e){const t=this.addressMapping.getCell(e);if(void 0!==t)return{vertex:t,id:void 0};const r=new p.EmptyCellVertex,n=this.graph.addNodeAndReturnId(r);return this.addressMapping.setCell(e,r),{vertex:r,id:n}}removeRows(e){this.stats.measure(d.StatType.ADJUSTING_GRAPH,()=>{for(const[t,r]of this.addressMapping.entriesFromRowsSpan(e)){for(const e of this.graph.adjacentNodes(r))this.graph.markNodeAsDirty(e);if(r instanceof p.ArrayVertex){if(!r.isLeftCorner(t))continue;this.shrinkArrayToCorner(r),this.arrayMapping.removeArray(r.getRange())}this.removeVertex(r)}}),this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.removeRows(e)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.truncateRanges(e,e=>e.row);return this.getArrayVerticesRelatedToRanges(t)});return this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>{this.fixArraysAfterRemovingRows(e.sheet,e.rowStart,e.numberOfRows)}),this.addStructuralNodesToChangeSet(),{affectedArrays:t,contentChanges:this.getAndClearContentChanges()}}removeSheet(e){this.clearSheet(e);for(const[t,r]of this.addressMapping.sheetEntries(e)){for(const e of this.graph.adjacentNodes(r))this.graph.markNodeAsDirty(e);this.removeVertex(r),this.addressMapping.removeCell(t)}this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.rangeMapping.removeRangesInSheet(e);for(const e of t)this.removeVertex(e);this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.removeSheet(e)})})}clearSheet(e){const t=new Set;for(const[r,n]of this.addressMapping.sheetEntries(e))n instanceof p.ArrayVertex?t.add(n):this.setCellEmpty(r);for(const e of t.values())this.setArrayEmpty(e);this.addStructuralNodesToChangeSet()}removeColumns(e){this.stats.measure(d.StatType.ADJUSTING_GRAPH,()=>{for(const[t,r]of this.addressMapping.entriesFromColumnsSpan(e)){for(const e of this.graph.adjacentNodes(r))this.graph.markNodeAsDirty(e);if(r instanceof p.ArrayVertex){if(!r.isLeftCorner(t))continue;this.shrinkArrayToCorner(r),this.arrayMapping.removeArray(r.getRange())}this.removeVertex(r)}}),this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.removeColumns(e)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.truncateRanges(e,e=>e.col);return this.getArrayVerticesRelatedToRanges(t)});return this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>this.fixArraysAfterRemovingColumns(e.sheet,e.columnStart,e.numberOfColumns)),this.addStructuralNodesToChangeSet(),{affectedArrays:t,contentChanges:this.getAndClearContentChanges()}}addRows(e){this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.addRows(e.sheet,e.rowStart,e.numberOfRows)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.rangeMapping.moveAllRangesInSheetAfterRowByRows(e.sheet,e.rowStart,e.numberOfRows);return this.fixRangesWhenAddingRows(e.sheet,e.rowStart,e.numberOfRows),this.getArrayVerticesRelatedToRanges(t.verticesWithChangedSize)});this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>{this.fixArraysAfterAddingRow(e.sheet,e.rowStart,e.numberOfRows)});for(const t of this.addressMapping.verticesFromRowsSpan(e))this.graph.markNodeAsDirty(t);return this.addStructuralNodesToChangeSet(),{affectedArrays:t}}addColumns(e){this.stats.measure(d.StatType.ADJUSTING_ADDRESS_MAPPING,()=>{this.addressMapping.addColumns(e.sheet,e.columnStart,e.numberOfColumns)});const t=this.stats.measure(d.StatType.ADJUSTING_RANGES,()=>{const t=this.rangeMapping.moveAllRangesInSheetAfterColumnByColumns(e.sheet,e.columnStart,e.numberOfColumns);return this.fixRangesWhenAddingColumns(e.sheet,e.columnStart,e.numberOfColumns),this.getArrayVerticesRelatedToRanges(t.verticesWithChangedSize)});this.stats.measure(d.StatType.ADJUSTING_ARRAY_MAPPING,()=>this.fixArraysAfterAddingColumn(e.sheet,e.columnStart,e.numberOfColumns));for(const t of this.addressMapping.verticesFromColumnsSpan(e))this.graph.markNodeAsDirty(t);return this.addStructuralNodesToChangeSet(),{affectedArrays:t,contentChanges:this.getAndClearContentChanges()}}isThereSpaceForArray(e){const t=e.getRangeOrUndef();if(void 0===t)return!1;for(const r of t.addresses(this)){const t=this.addressMapping.getCell(r);if(void 0!==t&&!(t instanceof p.EmptyCellVertex)&&t!==e)return!1}return!0}moveCells(e,t,r,n){for(const o of e.addressesWithDirection(t,r,this)){const i=(0,s.simpleCellAddress)(n,o.col+t,o.row+r);let a=this.addressMapping.getCell(o);const u=this.addressMapping.getCell(i);if(this.addressMapping.removeCell(o),void 0!==a){this.graph.markNodeAsDirty(a),this.addressMapping.setCell(i,a);let t=void 0;for(const r of this.graph.adjacentNodes(a))r instanceof p.RangeVertex&&!e.containsRange(r.range)&&(t=null!=t?t:this.fetchCellOrCreateEmpty(o).vertex,this.graph.addEdge(t,r),this.graph.removeEdge(a,r));t&&(this.graph.markNodeAsDirty(t),this.addressMapping.setCell(o,t))}if(void 0!==u){void 0===a&&this.addressMapping.removeCell(i);for(const e of this.graph.adjacentNodes(u))a=null!=a?a:this.fetchCellOrCreateEmpty(i).vertex,this.graph.addEdge(a,e),this.graph.markNodeAsDirty(a);this.removeVertex(u)}}for(const t of this.rangeMapping.rangeVerticesContainedInRange(e))for(const r of this.graph.adjacentNodes(t))if(r instanceof p.RangeVertex&&!e.containsRange(r.range)){this.graph.removeEdge(t,r);for(const e of t.range.addresses(this)){const{vertex:t,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:t,r),this.addressMapping.setCell(e,t),this.graph.markNodeAsDirty(t)}}this.rangeMapping.moveRangesInsideSourceRange(e,t,r,n)}setArrayEmpty(e){const t=n.AbsoluteCellRange.spanFrom(e.getAddress(this.lazilyTransformingAstService),e.width,e.height),r=this.graph.adjacentNodes(e);for(const e of t.addresses(this))this.addressMapping.removeCell(e);for(const t of r.values()){const r=(0,f.collectAddressesDependentToRange)(this.functionRegistry,t,e.getRange(),this.lazilyTransformingAstService,this);for(const e of r){const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:r,t)}r.length>0&&this.graph.markNodeAsDirty(t)}this.removeVertex(e),this.arrayMapping.removeArray(e.getRange())}addVertex(e,t){this.graph.addNodeAndReturnId(t),this.addressMapping.setCell(e,t)}addArrayVertex(e,t){this.graph.addNodeAndReturnId(t),this.setAddressMappingForArrayVertex(t,e)}*arrayFormulaNodes(){for(const e of this.graph.getNodes())e instanceof p.ArrayVertex&&(yield e)}*entriesFromRowsSpan(e){yield*this.addressMapping.entriesFromRowsSpan(e)}*entriesFromColumnsSpan(e){yield*this.addressMapping.entriesFromColumnsSpan(e)}fetchCell(e){return this.addressMapping.fetchCell(e)}getCell(e){return this.addressMapping.getCell(e)}getCellValue(e){return this.addressMapping.getCellValue(e)}getRawValue(e){return this.addressMapping.getRawValue(e)}getScalarValue(e){const t=this.addressMapping.getCellValue(e);return t instanceof c.SimpleRangeValue?new s.CellError(s.ErrorType.VALUE,a.ErrorMessage.ScalarExpected):t}existsEdge(e,t){return this.graph.existsEdge(e,t)}getSheetId(e){return this.sheetMapping.fetch(e)}getSheetHeight(e){return this.addressMapping.getHeight(e)}getSheetWidth(e){return this.addressMapping.getWidth(e)}getArray(e){return this.arrayMapping.getArray(e)}getRange(e,t){return this.rangeMapping.getRange(e,t)}topSortWithScc(){return this.graph.topSortWithScc()}markAsVolatile(e){this.graph.markNodeAsVolatile(e)}markAsDependentOnStructureChange(e){this.graph.markNodeAsChangingWithStructure(e)}forceApplyPostponedTransformations(){for(const e of this.graph.getNodes())e instanceof p.FormulaCellVertex&&e.ensureRecentData(this.lazilyTransformingAstService)}*rawValuesFromRange(e){for(const t of e.addresses(this)){const e=this.getScalarValue(t);e!==u.EmptyValue&&(yield[(0,u.getRawValue)(e),t])}}computeListOfValuesInRange(e){const t=[];for(const r of e.addresses(this)){const e=this.getScalarValue(r);t.push(e)}return t}shrinkArrayToCorner(e){this.cleanAddressMappingUnderArray(e);for(const t of this.adjacentArrayVertices(e)){let r;r=t instanceof E.FormulaVertex?this.formulaDirectDependenciesToArray(t,e):this.rangeDirectDependenciesToArray(t,e);let n=!1;for(const[o,s]of r)e.isLeftCorner(o)&&(n=!0),this.graph.addEdge(s,t),this.graph.markNodeAsDirty(s);n||this.graph.removeEdge(e,t)}this.graph.markNodeAsDirty(e)}isArrayInternalCell(e){const t=this.getCell(e);return t instanceof p.ArrayVertex&&!t.isLeftCorner(e)}getAndClearContentChanges(){const e=this.changes;return this.changes=i.ContentChanges.empty(),e}getAdjacentNodesAddresses(e){const t=this.graph.adjacentNodes(e),r=[];return t.forEach(e=>{const t=e;t instanceof p.RangeVertex?r.push((0,n.simpleCellRange)(t.start,t.end)):r.push(t.getAddress(this.lazilyTransformingAstService))}),r}exchangeGraphNode(e,t){this.graph.addNodeAndReturnId(t);const r=this.graph.adjacentNodes(e);this.removeVertex(e),r.forEach(e=>{this.graph.hasNode(e)&&this.graph.addEdge(t,e)})}setArray(e,t){this.arrayMapping.setArray(e,t)}correctInfiniteRangesDependency(e){const t=this.graph.getInfiniteRanges().filter(({node:t})=>t.range.addressInRange(e));if(t.length<=0)return;const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(e),o=null!=n?n:this.graph.getNodeId(r);t.forEach(({id:e})=>{this.graph.addEdge(o,e)})}exchangeOrAddGraphNode(e,t){e?this.exchangeGraphNode(e,t):this.graph.addNodeAndReturnId(t)}getArrayVerticesRelatedToRanges(e){const t=new Set;return e.forEach(e=>{this.graph.hasNode(e)&&this.graph.adjacentNodes(e).forEach(e=>{e instanceof p.ArrayVertex&&t.add(e)})}),t}correctInfiniteRangesDependenciesByRangeVertex(e){this.graph.getInfiniteRanges().forEach(({id:t,node:r})=>{const n=e.range.intersectionWith(r.range);void 0!==n&&n.addresses(this).forEach(e=>{const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=n?n:r,t)})})}cleanAddressMappingUnderArray(e){const t=e.getRange();for(const r of t.addresses(this)){const t=e.getArrayCellValue(r);this.getCell(r)===e?e.isLeftCorner(r)?this.changes.addChange(new s.CellError(s.ErrorType.REF),r,t):(this.addressMapping.removeCell(r),this.changes.addChange(u.EmptyValue,r,t)):this.changes.addChange(u.EmptyValue,r,t)}}*formulaDirectDependenciesToArray(e,t){var r;const[,o]=null!==(r=this.formulaDependencyQuery(e))&&void 0!==r?r:[];if(void 0!==o)for(const e of o)if(!(e instanceof l.NamedExpressionDependency||e instanceof n.AbsoluteCellRange)&&t.getRange().addressInRange(e)){const t=this.fetchCellOrCreateEmpty(e).vertex;yield[e,t]}}*rangeDirectDependenciesToArray(e,t){const{restRange:r}=this.rangeMapping.findSmallerRange(e.range);for(const e of r.addresses(this))if(t.getRange().addressInRange(e)){const t=this.fetchCellOrCreateEmpty(e).vertex;yield[e,t]}}*adjacentArrayVertices(e){const t=this.graph.adjacentNodes(e);for(const e of t)(e instanceof E.FormulaVertex||e instanceof p.RangeVertex)&&(yield e)}addStructuralNodesToChangeSet(){this.graph.markChangingWithStructureNodesAsDirty()}fixRangesWhenAddingRows(e,t,r){const o=Array.from(this.rangeMapping.rangesInSheet(e));for(const e of o)if(e.range.includesRow(t+r))if(e.bruteForce){const n=e.range.rangeWithSameWidth(t,r);for(const t of n.addresses(this)){const{vertex:r,id:n}=this.fetchCellOrCreateEmpty(t);this.graph.addEdge(null!=n?n:r,e)}}else{let t=e,r=this.rangeMapping.findSmallerRange(t.range);if(void 0!==r.smallerRangeVertex)continue;for(;void 0===r.smallerRangeVertex;){const e=new p.RangeVertex(n.AbsoluteCellRange.spanFrom(t.range.start,t.range.width(),t.range.height()-1));this.rangeMapping.setRange(e),this.graph.addNodeAndReturnId(e);const o=new n.AbsoluteCellRange((0,s.simpleCellAddress)(t.range.start.sheet,t.range.start.col,t.range.end.row),t.range.end);this.addAllFromRange(o,t),this.graph.addEdge(e,t),t=e,r=this.rangeMapping.findSmallerRange(t.range)}this.graph.addEdge(r.smallerRangeVertex,t),this.addAllFromRange(r.restRange,t),this.graph.removeEdge(r.smallerRangeVertex,e)}}addAllFromRange(e,t){for(const r of e.addresses(this)){const{vertex:e,id:n}=this.fetchCellOrCreateEmpty(r);this.graph.addEdge(null!=n?n:e,t)}}fixRangesWhenAddingColumns(e,t,r){for(const o of this.rangeMapping.rangesInSheet(e))if(o.range.includesColumn(t+r)){let i;i=o.bruteForce?o.range.rangeWithSameHeight(t,r):n.AbsoluteCellRange.spanFrom((0,s.simpleCellAddress)(e,t,o.range.end.row),r,1);for(const e of i.addresses(this)){const{vertex:t,id:r}=this.fetchCellOrCreateEmpty(e);this.graph.addEdge(null!=r?r:t,o)}}}exchangeOrAddFormulaVertex(e){const t=e.getAddress(this.lazilyTransformingAstService),r=n.AbsoluteCellRange.spanFrom(t,e.width,e.height),o=this.shrinkPossibleArrayAndGetCell(t);if(e instanceof p.ArrayVertex&&this.setArray(r,e),this.exchangeOrAddGraphNode(o,e),this.addressMapping.setCell(t,e),e instanceof p.ArrayVertex){if(!this.isThereSpaceForArray(e))return;for(const t of r.addresses(this)){if(e.isLeftCorner(t))continue;const r=this.getCell(t);this.exchangeOrAddGraphNode(r,e)}}for(const t of r.addresses(this))this.addressMapping.setCell(t,e)}setAddressMappingForArrayVertex(e,t){if(this.addressMapping.setCell(t,e),!(e instanceof p.ArrayVertex))return;const r=n.AbsoluteCellRange.spanFromOrUndef(t,e.width,e.height);if(void 0!==r&&(this.setArray(r,e),this.isThereSpaceForArray(e)))for(const t of r.addresses(this))this.addressMapping.setCell(t,e)}truncateRanges(e,t){const{verticesToRemove:r,verticesToMerge:n,verticesWithChangedSize:o}=this.rangeMapping.truncateRanges(e,t);for(const[e,t]of n)this.mergeRangeVertices(e,t);for(const e of r)this.removeVertexAndCleanupDependencies(e);return o}fixArraysAfterAddingRow(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterRowByRows(e,t,r),!(t<=0))for(const[,n]of this.arrayMapping.arraysInRows(h.RowsSpan.fromRowStartAndEnd(e,t-1,t-1))){const o=n.getRange();for(let i=o.start.col;i<=o.end.col;++i)for(let a=t;a<=o.end.row;++a){const t=(0,s.simpleCellAddress)(e,i,a),o=(0,s.simpleCellAddress)(e,i,a+r),c=n.getArrayCellValue(t);this.addressMapping.moveCell(o,t),this.changes.addChange(u.EmptyValue,o,c)}}}fixArraysAfterRemovingRows(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterRowByRows(e,t,-r),!(t<=0))for(const[,r]of this.arrayMapping.arraysInRows(h.RowsSpan.fromRowStartAndEnd(e,t-1,t-1)))if(this.isThereSpaceForArray(r))for(const e of r.getRange().addresses(this))this.addressMapping.setCell(e,r);else this.setNoSpaceIfArray(r)}fixArraysAfterAddingColumn(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterColumnByColumns(e,t,r),!(t<=0))for(const[,n]of this.arrayMapping.arraysInCols(h.ColumnsSpan.fromColumnStartAndEnd(e,t-1,t-1))){const o=n.getRange();for(let i=o.start.row;i<=o.end.row;++i)for(let a=t;a<=o.end.col;++a){const t=(0,s.simpleCellAddress)(e,a,i),o=(0,s.simpleCellAddress)(e,a+r,i),c=n.getArrayCellValue(t);this.addressMapping.moveCell(o,t),this.changes.addChange(u.EmptyValue,o,c)}}}fixArraysAfterRemovingColumns(e,t,r){if(this.arrayMapping.moveArrayVerticesAfterColumnByColumns(e,t,-r),!(t<=0))for(const[,r]of this.arrayMapping.arraysInCols(h.ColumnsSpan.fromColumnStartAndEnd(e,t-1,t-1)))if(this.isThereSpaceForArray(r))for(const e of r.getRange().addresses(this))this.addressMapping.setCell(e,r);else this.setNoSpaceIfArray(r)}shrinkPossibleArrayAndGetCell(e){const t=this.getCell(e);return t instanceof p.ArrayVertex?(this.setNoSpaceIfArray(t),this.getCell(e)):t}setNoSpaceIfArray(e){e instanceof p.ArrayVertex&&(this.shrinkArrayToCorner(e),e.setNoSpace())}removeVertex(e){this.removeVertexAndCleanupDependencies(e),e instanceof p.RangeVertex&&this.rangeMapping.removeRange(e)}mergeRangeVertices(e,t){const r=this.graph.adjacentNodes(t);this.removeVertexAndCleanupDependencies(t),this.graph.removeEdgeIfExists(e,t),r.forEach(t=>{this.graph.hasNode(t)&&this.graph.addEdge(e,t)})}removeVertexAndCleanupDependencies(e){const t=new Set(this.graph.removeNode(e));for(;t.size>0;){const e=t.values().next().value;t.delete(e);const[r,n]=e;this.graph.hasNode(n)&&0===this.graph.adjacentNodesCount(n)&&((n instanceof p.RangeVertex||n instanceof p.EmptyCellVertex)&&this.graph.removeNode(n).forEach(e=>t.add(e)),n instanceof p.RangeVertex?this.rangeMapping.removeRange(n):n instanceof p.EmptyCellVertex&&this.addressMapping.removeCell(r))}}}t.DependencyGraph=R},function(e,t,r){"use strict";t.__esModule=!0,t.filterDependenciesOutOfScope=t.absolutizeDependencies=void 0;var n=r(72),o=r(73),s=r(77);t.absolutizeDependencies=(e,t)=>e.map(e=>e.absolutize(t)),t.filterDependenciesOutOfScope=e=>e.filter(e=>e instanceof s.NamedExpressionDependency||(e instanceof n.AbsoluteCellRange?!((0,o.invalidSimpleCellAddress)(e.start)||(0,o.invalidSimpleCellAddress)(e.end)):!(0,o.invalidSimpleCellAddress)(e)))},function(e,t,r){"use strict";t.__esModule=!0,t.simpleCellRangeToString=t.simpleCellRangeFromString=t.simpleCellAddressToString=t.simpleCellAddressFromString=t.collectDependencies=t.cellAddressFromString=t.buildProcedureAst=t.buildParsingErrorAst=t.buildLexerConfig=t.buildCellRangeAst=t.buildCellErrorAst=t.Unparser=t.RowRangeDependency=t.ParsingErrorType=t.ParserWithCaching=t.NamedExpressionDependency=t.FormulaLexer=t.ColumnRangeDependency=t.CellRangeDependency=t.CellAddress=t.AstNodeType=t.AddressDependency=void 0;var n=r(78);t.cellAddressFromString=n.cellAddressFromString,t.simpleCellAddressFromString=n.simpleCellAddressFromString,t.simpleCellAddressToString=n.simpleCellAddressToString,t.simpleCellRangeFromString=n.simpleCellRangeFromString,t.simpleCellRangeToString=n.simpleCellRangeToString;var o=r(79);t.CellAddress=o.CellAddress;var s=r(83);t.ParserWithCaching=s.ParserWithCaching;var i=r(136);t.collectDependencies=i.collectDependencies;var a=r(132);t.buildLexerConfig=a.buildLexerConfig;var u=r(130);t.FormulaLexer=u.FormulaLexer;var c=r(127);t.AstNodeType=c.AstNodeType,t.ParsingErrorType=c.ParsingErrorType,t.buildProcedureAst=c.buildProcedureAst,t.buildCellRangeAst=c.buildCellRangeAst,t.buildParsingErrorAst=c.buildParsingErrorAst,t.buildCellErrorAst=c.buildCellErrorAst;var l=r(135);t.Unparser=l.Unparser;var h=r(137);t.AddressDependency=h.AddressDependency,t.CellRangeDependency=h.CellRangeDependency,t.ColumnRangeDependency=h.ColumnRangeDependency,t.RowRangeDependency=h.RowRangeDependency,t.NamedExpressionDependency=h.NamedExpressionDependency},function(e,t,r){"use strict";t.__esModule=!0,t.columnAddressFromString=t.cellAddressFromString=void 0,t.columnIndexToLabel=f,t.rowAddressFromString=void 0,t.sheetIndexToString=E,t.simpleCellRangeToString=t.simpleCellRangeFromString=t.simpleCellAddressToString=t.simpleCellAddressFromString=void 0;var n=r(72),o=r(73),s=r(79),i=r(80),a=r(82),u=r(81); /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ -const c=new RegExp(`^(${a.SHEET_NAME_PATTERN})?(\\${a.ABSOLUTE_OPERATOR}?)([A-Za-z]+)(\\${a.ABSOLUTE_OPERATOR}?)([0-9]+)$`),l=new RegExp(`^(${a.SHEET_NAME_PATTERN})?(\\${a.ABSOLUTE_OPERATOR}?)([A-Za-z]+)$`),h=new RegExp(`^(${a.SHEET_NAME_PATTERN})?(\\${a.ABSOLUTE_OPERATOR}?)([0-9]+)$`),d=new RegExp(`^${a.UNQUOTED_SHEET_NAME_PATTERN}$`);t.cellAddressFromString=(e,t,r)=>{const n=c.exec(t),o=g(n[6]);let i=T(n,e);if(void 0===i)return;null===i&&(i=void 0);const u=Number(n[8])-1;return n[5]===a.ABSOLUTE_OPERATOR&&n[7]===a.ABSOLUTE_OPERATOR?s.CellAddress.absolute(o,u,i):n[5]===a.ABSOLUTE_OPERATOR?s.CellAddress.absoluteCol(o,u-r.row,i):n[7]===a.ABSOLUTE_OPERATOR?s.CellAddress.absoluteRow(o-r.col,u,i):s.CellAddress.relative(o-r.col,u-r.row,i)},t.columnAddressFromString=(e,t,r)=>{const n=l.exec(t);let o=T(n,e);if(void 0===o)return;null===o&&(o=void 0);const s=g(n[6]);return n[5]===a.ABSOLUTE_OPERATOR?i.ColumnAddress.absolute(s,o):i.ColumnAddress.relative(s-r.col,o)},t.rowAddressFromString=(e,t,r)=>{const n=h.exec(t);let o=T(n,e);if(void 0===o)return;null===o&&(o=void 0);const s=Number(n[6])-1;return n[5]===a.ABSOLUTE_OPERATOR?u.RowAddress.absolute(s,o):u.RowAddress.relative(s-r.row,o)};const p=(e,t,r)=>{const n=c.exec(t);if(!n)return;const s=g(n[6]);let i=T(n,e);if(void 0===i)return;null===i&&(i=r);const a=Number(n[8])-1;return(0,o.simpleCellAddress)(i,s,a)};t.simpleCellAddressFromString=p,t.simpleCellRangeFromString=(e,t,r)=>{const o=t.split(a.RANGE_OPERATOR);if(2!==o.length)return;const[s,i]=o,u=p(e,s,r);if(void 0===u)return;const c=p(e,i,u.sheet);return void 0!==c&&u.sheet===c.sheet?(0,n.simpleCellRange)(u,c):void 0};const m=(e,t,r)=>{const n=f(t.col),o=E(t.sheet,e);if(void 0!==o)return r!==t.sheet?`${o}!${n}${t.row+1}`:`${n}${t.row+1}`};function g(e){return 1===e.length?e.toUpperCase().charCodeAt(0)-65:e.split("").reduce((e,t)=>26*e+(t.toUpperCase().charCodeAt(0)-64),0)-1}function f(e){let t="";for(;e>=0;)t=String.fromCharCode(e%26+97)+t,e=Math.floor(e/26)-1;return t.toUpperCase()}function E(e,t){let r=t(e);if(void 0!==r)return d.test(r)?r:(r=r.replace(/'/g,"''"),`'${r}'`)}function T(e,t){var r;let n=null!==(r=e[3])&&void 0!==r?r:e[2];return n?(n=n.replace(/''/g,"'"),t(n)):null}t.simpleCellAddressToString=m,t.simpleCellRangeToString=(e,t,r)=>{const n=m(e,t.start,r),o=m(e,t.end,t.start.sheet);return void 0===n||void 0===o?void 0:`${n}${a.RANGE_OPERATOR}${o}`}},function(e,t,r){"use strict";t.__esModule=!0,t.CellReferenceType=t.CellAddress=void 0;var n,o=r(74),s=r(79),i=r(81),a=r(82);!function(e){e.CELL_REFERENCE_RELATIVE="CELL_REFERENCE",e.CELL_REFERENCE_ABSOLUTE="CELL_REFERENCE_ABSOLUTE",e.CELL_REFERENCE_ABSOLUTE_COL="CELL_REFERENCE_ABSOLUTE_COL",e.CELL_REFERENCE_ABSOLUTE_ROW="CELL_REFERENCE_ABSOLUTE_ROW"}(n||(t.CellReferenceType=n={}));class u{constructor(e,t,r,n){this.col=e,this.row=t,this.type=r,this.sheet=n}static fromColAndRow(e,t,r){return(e.isColumnAbsolute()&&t.isRowAbsolute()?u.absolute.bind(this):e.isColumnAbsolute()?u.absoluteCol.bind(this):t.isRowAbsolute()?u.absoluteRow.bind(this):u.relative.bind(this))(e.col,t.row,r)}static relative(e,t,r){return new u(e,t,n.CELL_REFERENCE_RELATIVE,r)}static absolute(e,t,r){return new u(e,t,n.CELL_REFERENCE_ABSOLUTE,r)}static absoluteCol(e,t,r){return new u(e,t,n.CELL_REFERENCE_ABSOLUTE_COL,r)}static absoluteRow(e,t,r){return new u(e,t,n.CELL_REFERENCE_ABSOLUTE_ROW,r)}toSimpleCellAddress(e){const t=(0,o.absoluteSheetReference)(this,e);return this.type===n.CELL_REFERENCE_ABSOLUTE?(0,o.simpleCellAddress)(t,this.col,this.row):this.type===n.CELL_REFERENCE_ABSOLUTE_ROW?(0,o.simpleCellAddress)(t,e.col+this.col,this.row):this.type===n.CELL_REFERENCE_ABSOLUTE_COL?(0,o.simpleCellAddress)(t,this.col,e.row+this.row):(0,o.simpleCellAddress)(t,e.col+this.col,e.row+this.row)}toColumnAddress(){const e=this.isColumnRelative()?i.ReferenceType.RELATIVE:i.ReferenceType.ABSOLUTE;return new i.ColumnAddress(e,this.col,this.sheet)}toRowAddress(){const e=this.isRowRelative()?i.ReferenceType.RELATIVE:i.ReferenceType.ABSOLUTE;return new a.RowAddress(e,this.row,this.sheet)}toSimpleColumnAddress(e){const t=(0,o.absoluteSheetReference)(this,e);let r=this.col;return this.isColumnRelative()&&(r+=e.col),(0,o.simpleColumnAddress)(t,r)}toSimpleRowAddress(e){const t=(0,o.absoluteSheetReference)(this,e);let r=this.row;return this.isRowRelative()&&(r+=e.row),(0,o.simpleRowAddress)(t,r)}isRowAbsolute(){return this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_ROW}isColumnAbsolute(){return this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_COL}isColumnRelative(){return this.type===n.CELL_REFERENCE_RELATIVE||this.type===n.CELL_REFERENCE_ABSOLUTE_ROW}isRowRelative(){return this.type===n.CELL_REFERENCE_RELATIVE||this.type===n.CELL_REFERENCE_ABSOLUTE_COL}isAbsolute(){return this.type===n.CELL_REFERENCE_ABSOLUTE&&void 0!==this.sheet}shiftedByRows(e){return new u(this.col,this.row+e,this.type,this.sheet)}shiftedByColumns(e){return new u(this.col+e,this.row,this.type,this.sheet)}moved(e,t,r){const n=void 0===this.sheet?void 0:e;return new u(this.col+t,this.row+r,this.type,n)}withSheet(e){return new u(this.col,this.row,this.type,e)}isInvalid(e){return(0,o.invalidSimpleCellAddress)(this.toSimpleCellAddress(e))}shiftRelativeDimensions(e,t){const r=this.isColumnAbsolute()?this.col:this.col+e,n=this.isRowAbsolute()?this.row:this.row+t;return new u(r,n,this.type,this.sheet)}shiftAbsoluteDimensions(e,t){const r=this.isColumnRelative()?this.col:this.col+e,n=this.isRowRelative()?this.row:this.row+t;return new u(r,n,this.type,this.sheet)}hash(e){const t=e&&void 0!==this.sheet?"#"+this.sheet:"";switch(this.type){case n.CELL_REFERENCE_RELATIVE:return`${t}#${this.row}R${this.col}`;case n.CELL_REFERENCE_ABSOLUTE:return`${t}#${this.row}A${this.col}`;case n.CELL_REFERENCE_ABSOLUTE_COL:return`${t}#${this.row}AC${this.col}`;case n.CELL_REFERENCE_ABSOLUTE_ROW:return`${t}#${this.row}AR${this.col}`}}unparse(e){const t=this.toSimpleCellAddress(e);if((0,o.invalidSimpleCellAddress)(t))return;const r=(0,s.columnIndexToLabel)(t.col),i=this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_ROW?"$":"";return`${this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_COL?"$":""}${r}${i}${t.row+1}`}exceedsSheetSizeLimits(e,t){return this.row>=t||this.col>=e}}t.CellAddress=u},function(e,t,r){"use strict";t.__esModule=!0,t.ReferenceType=t.ColumnAddress=void 0;var n,o=r(74),s=r(79);!function(e){e.RELATIVE="RELATIVE",e.ABSOLUTE="ABSOLUTE"}(n||(t.ReferenceType=n={}));class i{constructor(e,t,r){this.type=e,this.col=t,this.sheet=r}static absolute(e,t){return new i(n.ABSOLUTE,e,t)}static relative(e,t){return new i(n.RELATIVE,e,t)}static compareByAbsoluteAddress(e){return(t,r)=>t.toSimpleColumnAddress(e).col-r.toSimpleColumnAddress(e).col}isColumnAbsolute(){return this.type===n.ABSOLUTE}isColumnRelative(){return this.type===n.RELATIVE}isAbsolute(){return this.type===n.ABSOLUTE&&void 0!==this.sheet}moved(e,t,r){const n=void 0===this.sheet?void 0:e;return new i(this.type,this.col+t,n)}shiftedByColumns(e){return new i(this.type,this.col+e,this.sheet)}toSimpleColumnAddress(e){const t=(0,o.absoluteSheetReference)(this,e);let r=this.col;return this.isColumnRelative()&&(r=e.col+this.col),(0,o.simpleColumnAddress)(t,r)}shiftRelativeDimensions(e,t){const r=this.isColumnRelative()?this.col+e:this.col;return new i(this.type,r,this.sheet)}shiftAbsoluteDimensions(e,t){const r=this.isColumnAbsolute()?this.col+e:this.col;return new i(this.type,r,this.sheet)}withSheet(e){return new i(this.type,this.col,e)}isInvalid(e){return this.toSimpleColumnAddress(e).col<0}hash(e){const t=e&&void 0!==this.sheet?"#"+this.sheet:"";switch(this.type){case n.RELATIVE:return`${t}#COLR${this.col}`;case n.ABSOLUTE:return`${t}#COLA${this.col}`}}unparse(e){const t=this.toSimpleColumnAddress(e);if((0,o.invalidSimpleColumnAddress)(t))return;const r=(0,s.columnIndexToLabel)(t.col);return`${this.type===n.ABSOLUTE?"$":""}${r}`}exceedsSheetSizeLimits(e){return this.col>=e}}t.ColumnAddress=i},function(e,t,r){"use strict";t.__esModule=!0,t.RowAddress=void 0;var n=r(74),o=r(81); +const c=new RegExp(`^(${a.SHEET_NAME_PATTERN})?(\\${a.ABSOLUTE_OPERATOR}?)([A-Za-z]+)(\\${a.ABSOLUTE_OPERATOR}?)([0-9]+)$`),l=new RegExp(`^(${a.SHEET_NAME_PATTERN})?(\\${a.ABSOLUTE_OPERATOR}?)([A-Za-z]+)$`),h=new RegExp(`^(${a.SHEET_NAME_PATTERN})?(\\${a.ABSOLUTE_OPERATOR}?)([0-9]+)$`),d=new RegExp(`^${a.UNQUOTED_SHEET_NAME_PATTERN}$`);t.cellAddressFromString=(e,t,r)=>{const n=c.exec(t),o=g(n[6]);let i=T(n,e);if(void 0===i)return;null===i&&(i=void 0);const u=Number(n[8])-1;return n[5]===a.ABSOLUTE_OPERATOR&&n[7]===a.ABSOLUTE_OPERATOR?s.CellAddress.absolute(o,u,i):n[5]===a.ABSOLUTE_OPERATOR?s.CellAddress.absoluteCol(o,u-r.row,i):n[7]===a.ABSOLUTE_OPERATOR?s.CellAddress.absoluteRow(o-r.col,u,i):s.CellAddress.relative(o-r.col,u-r.row,i)},t.columnAddressFromString=(e,t,r)=>{const n=l.exec(t);let o=T(n,e);if(void 0===o)return;null===o&&(o=void 0);const s=g(n[6]);return n[5]===a.ABSOLUTE_OPERATOR?i.ColumnAddress.absolute(s,o):i.ColumnAddress.relative(s-r.col,o)},t.rowAddressFromString=(e,t,r)=>{const n=h.exec(t);let o=T(n,e);if(void 0===o)return;null===o&&(o=void 0);const s=Number(n[6])-1;return n[5]===a.ABSOLUTE_OPERATOR?u.RowAddress.absolute(s,o):u.RowAddress.relative(s-r.row,o)};const p=(e,t,r)=>{const n=c.exec(t);if(!n)return;const s=g(n[6]);let i=T(n,e);if(void 0===i)return;null===i&&(i=r);const a=Number(n[8])-1;return(0,o.simpleCellAddress)(i,s,a)};t.simpleCellAddressFromString=p,t.simpleCellRangeFromString=(e,t,r)=>{const o=t.split(a.RANGE_OPERATOR);if(2!==o.length)return;const[s,i]=o,u=p(e,s,r);if(void 0===u)return;const c=p(e,i,u.sheet);return void 0!==c&&u.sheet===c.sheet?(0,n.simpleCellRange)(u,c):void 0};const m=(e,t,r)=>{const n=f(t.col),o=E(t.sheet,e);if(void 0!==o)return r!==t.sheet?`${o}!${n}${t.row+1}`:`${n}${t.row+1}`};function g(e){return 1===e.length?e.toUpperCase().charCodeAt(0)-65:e.split("").reduce((e,t)=>26*e+(t.toUpperCase().charCodeAt(0)-64),0)-1}function f(e){let t="";for(;e>=0;)t=String.fromCharCode(e%26+97)+t,e=Math.floor(e/26)-1;return t.toUpperCase()}function E(e,t){let r=t(e);if(void 0!==r)return d.test(r)?r:(r=r.replace(/'/g,"''"),`'${r}'`)}function T(e,t){var r;let n=null!==(r=e[3])&&void 0!==r?r:e[2];return n?(n=n.replace(/''/g,"'"),t(n)):null}t.simpleCellAddressToString=m,t.simpleCellRangeToString=(e,t,r)=>{const n=m(e,t.start,r),o=m(e,t.end,t.start.sheet);return void 0===n||void 0===o?void 0:`${n}${a.RANGE_OPERATOR}${o}`}},function(e,t,r){"use strict";t.__esModule=!0,t.CellReferenceType=t.CellAddress=void 0;var n,o=r(73),s=r(78),i=r(80),a=r(81);!function(e){e.CELL_REFERENCE_RELATIVE="CELL_REFERENCE",e.CELL_REFERENCE_ABSOLUTE="CELL_REFERENCE_ABSOLUTE",e.CELL_REFERENCE_ABSOLUTE_COL="CELL_REFERENCE_ABSOLUTE_COL",e.CELL_REFERENCE_ABSOLUTE_ROW="CELL_REFERENCE_ABSOLUTE_ROW"}(n||(t.CellReferenceType=n={}));class u{constructor(e,t,r,n){this.col=e,this.row=t,this.type=r,this.sheet=n}static fromColAndRow(e,t,r){return(e.isColumnAbsolute()&&t.isRowAbsolute()?u.absolute.bind(this):e.isColumnAbsolute()?u.absoluteCol.bind(this):t.isRowAbsolute()?u.absoluteRow.bind(this):u.relative.bind(this))(e.col,t.row,r)}static relative(e,t,r){return new u(e,t,n.CELL_REFERENCE_RELATIVE,r)}static absolute(e,t,r){return new u(e,t,n.CELL_REFERENCE_ABSOLUTE,r)}static absoluteCol(e,t,r){return new u(e,t,n.CELL_REFERENCE_ABSOLUTE_COL,r)}static absoluteRow(e,t,r){return new u(e,t,n.CELL_REFERENCE_ABSOLUTE_ROW,r)}toSimpleCellAddress(e){const t=(0,o.absoluteSheetReference)(this,e);return this.type===n.CELL_REFERENCE_ABSOLUTE?(0,o.simpleCellAddress)(t,this.col,this.row):this.type===n.CELL_REFERENCE_ABSOLUTE_ROW?(0,o.simpleCellAddress)(t,e.col+this.col,this.row):this.type===n.CELL_REFERENCE_ABSOLUTE_COL?(0,o.simpleCellAddress)(t,this.col,e.row+this.row):(0,o.simpleCellAddress)(t,e.col+this.col,e.row+this.row)}toColumnAddress(){const e=this.isColumnRelative()?i.ReferenceType.RELATIVE:i.ReferenceType.ABSOLUTE;return new i.ColumnAddress(e,this.col,this.sheet)}toRowAddress(){const e=this.isRowRelative()?i.ReferenceType.RELATIVE:i.ReferenceType.ABSOLUTE;return new a.RowAddress(e,this.row,this.sheet)}toSimpleColumnAddress(e){const t=(0,o.absoluteSheetReference)(this,e);let r=this.col;return this.isColumnRelative()&&(r+=e.col),(0,o.simpleColumnAddress)(t,r)}toSimpleRowAddress(e){const t=(0,o.absoluteSheetReference)(this,e);let r=this.row;return this.isRowRelative()&&(r+=e.row),(0,o.simpleRowAddress)(t,r)}isRowAbsolute(){return this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_ROW}isColumnAbsolute(){return this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_COL}isColumnRelative(){return this.type===n.CELL_REFERENCE_RELATIVE||this.type===n.CELL_REFERENCE_ABSOLUTE_ROW}isRowRelative(){return this.type===n.CELL_REFERENCE_RELATIVE||this.type===n.CELL_REFERENCE_ABSOLUTE_COL}isAbsolute(){return this.type===n.CELL_REFERENCE_ABSOLUTE&&void 0!==this.sheet}shiftedByRows(e){return new u(this.col,this.row+e,this.type,this.sheet)}shiftedByColumns(e){return new u(this.col+e,this.row,this.type,this.sheet)}moved(e,t,r){const n=void 0===this.sheet?void 0:e;return new u(this.col+t,this.row+r,this.type,n)}withSheet(e){return new u(this.col,this.row,this.type,e)}isInvalid(e){return(0,o.invalidSimpleCellAddress)(this.toSimpleCellAddress(e))}shiftRelativeDimensions(e,t){const r=this.isColumnAbsolute()?this.col:this.col+e,n=this.isRowAbsolute()?this.row:this.row+t;return new u(r,n,this.type,this.sheet)}shiftAbsoluteDimensions(e,t){const r=this.isColumnRelative()?this.col:this.col+e,n=this.isRowRelative()?this.row:this.row+t;return new u(r,n,this.type,this.sheet)}hash(e){const t=e&&void 0!==this.sheet?"#"+this.sheet:"";switch(this.type){case n.CELL_REFERENCE_RELATIVE:return`${t}#${this.row}R${this.col}`;case n.CELL_REFERENCE_ABSOLUTE:return`${t}#${this.row}A${this.col}`;case n.CELL_REFERENCE_ABSOLUTE_COL:return`${t}#${this.row}AC${this.col}`;case n.CELL_REFERENCE_ABSOLUTE_ROW:return`${t}#${this.row}AR${this.col}`}}unparse(e){const t=this.toSimpleCellAddress(e);if((0,o.invalidSimpleCellAddress)(t))return;const r=(0,s.columnIndexToLabel)(t.col),i=this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_ROW?"$":"";return`${this.type===n.CELL_REFERENCE_ABSOLUTE||this.type===n.CELL_REFERENCE_ABSOLUTE_COL?"$":""}${r}${i}${t.row+1}`}exceedsSheetSizeLimits(e,t){return this.row>=t||this.col>=e}}t.CellAddress=u},function(e,t,r){"use strict";t.__esModule=!0,t.ReferenceType=t.ColumnAddress=void 0;var n,o=r(73),s=r(78);!function(e){e.RELATIVE="RELATIVE",e.ABSOLUTE="ABSOLUTE"}(n||(t.ReferenceType=n={}));class i{constructor(e,t,r){this.type=e,this.col=t,this.sheet=r}static absolute(e,t){return new i(n.ABSOLUTE,e,t)}static relative(e,t){return new i(n.RELATIVE,e,t)}static compareByAbsoluteAddress(e){return(t,r)=>t.toSimpleColumnAddress(e).col-r.toSimpleColumnAddress(e).col}isColumnAbsolute(){return this.type===n.ABSOLUTE}isColumnRelative(){return this.type===n.RELATIVE}isAbsolute(){return this.type===n.ABSOLUTE&&void 0!==this.sheet}moved(e,t,r){const n=void 0===this.sheet?void 0:e;return new i(this.type,this.col+t,n)}shiftedByColumns(e){return new i(this.type,this.col+e,this.sheet)}toSimpleColumnAddress(e){const t=(0,o.absoluteSheetReference)(this,e);let r=this.col;return this.isColumnRelative()&&(r=e.col+this.col),(0,o.simpleColumnAddress)(t,r)}shiftRelativeDimensions(e,t){const r=this.isColumnRelative()?this.col+e:this.col;return new i(this.type,r,this.sheet)}shiftAbsoluteDimensions(e,t){const r=this.isColumnAbsolute()?this.col+e:this.col;return new i(this.type,r,this.sheet)}withSheet(e){return new i(this.type,this.col,e)}isInvalid(e){return this.toSimpleColumnAddress(e).col<0}hash(e){const t=e&&void 0!==this.sheet?"#"+this.sheet:"";switch(this.type){case n.RELATIVE:return`${t}#COLR${this.col}`;case n.ABSOLUTE:return`${t}#COLA${this.col}`}}unparse(e){const t=this.toSimpleColumnAddress(e);if((0,o.invalidSimpleColumnAddress)(t))return;const r=(0,s.columnIndexToLabel)(t.col);return`${this.type===n.ABSOLUTE?"$":""}${r}`}exceedsSheetSizeLimits(e){return this.col>=e}}t.ColumnAddress=i},function(e,t,r){"use strict";t.__esModule=!0,t.RowAddress=void 0;var n=r(73),o=r(80); /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ class s{constructor(e,t,r){this.type=e,this.row=t,this.sheet=r}static absolute(e,t){return new s(o.ReferenceType.ABSOLUTE,e,t)}static relative(e,t){return new s(o.ReferenceType.RELATIVE,e,t)}static compareByAbsoluteAddress(e){return(t,r)=>t.toSimpleRowAddress(e).row-r.toSimpleRowAddress(e).row}isRowAbsolute(){return this.type===o.ReferenceType.ABSOLUTE}isRowRelative(){return this.type===o.ReferenceType.RELATIVE}isAbsolute(){return this.type===o.ReferenceType.ABSOLUTE&&void 0!==this.sheet}moved(e,t,r){const n=void 0===this.sheet?void 0:e;return new s(this.type,this.row+r,n)}shiftedByRows(e){return new s(this.type,this.row+e,this.sheet)}toSimpleRowAddress(e){const t=(0,n.absoluteSheetReference)(this,e);let r=this.row;return this.isRowRelative()&&(r=e.row+this.row),(0,n.simpleRowAddress)(t,r)}shiftRelativeDimensions(e,t){const r=this.isRowRelative()?this.row+t:this.row;return new s(this.type,r,this.sheet)}shiftAbsoluteDimensions(e,t){const r=this.isRowAbsolute()?this.row+t:this.row;return new s(this.type,r,this.sheet)}withSheet(e){return new s(this.type,this.row,e)}isInvalid(e){return this.toSimpleRowAddress(e).row<0}hash(e){const t=e&&void 0!==this.sheet?"#"+this.sheet:"";switch(this.type){case o.ReferenceType.RELATIVE:return`${t}#ROWR${this.row}`;case o.ReferenceType.ABSOLUTE:return`${t}#ROWA${this.row}`}}unparse(e){const t=this.toSimpleRowAddress(e);if(!(0,n.invalidSimpleRowAddress)(t))return`${this.type===o.ReferenceType.ABSOLUTE?"$":""}${t.row+1}`}exceedsSheetSizeLimits(e){return this.row>=e}}t.RowAddress=s},function(e,t,r){"use strict";t.__esModule=!0,t.UNQUOTED_SHEET_NAME_PATTERN=t.UNICODE_LETTER_PATTERN=t.SHEET_NAME_PATTERN=t.ROW_REFERENCE_PATTERN=t.RANGE_OPERATOR=t.R1C1_CELL_REFERENCE_PATTERN=t.QUOTED_SHEET_NAME_PATTERN=t.ODFF_WHITESPACE_PATTERN=t.NON_RESERVED_CHARACTER_PATTERN=t.NAMED_EXPRESSION_PATTERN=t.COLUMN_REFERENCE_PATTERN=t.CELL_REFERENCE_WITH_NEXT_CHARACTER_PATTERN=t.CELL_REFERENCE_PATTERN=t.ALL_WHITESPACE_PATTERN=t.ALL_UNICODE_LETTERS_ARRAY=t.ALL_DIGITS_ARRAY=t.ABSOLUTE_OPERATOR=void 0,t.RANGE_OPERATOR=":"; /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ -const n=t.ABSOLUTE_OPERATOR="$",o=(t.ALL_WHITESPACE_PATTERN="\\s+",t.ODFF_WHITESPACE_PATTERN="[ \\t\\n\\r]+",t.UNICODE_LETTER_PATTERN="A-Za-zÀ-ʯ"),s=t.NON_RESERVED_CHARACTER_PATTERN=o+"0-9_.",i=t.UNQUOTED_SHEET_NAME_PATTERN=`[${o}0-9_]+`,a=t.QUOTED_SHEET_NAME_PATTERN="'(((?!').|'')*)'",u=t.SHEET_NAME_PATTERN=`(${i}|${a})!`,c=t.CELL_REFERENCE_PATTERN=`(${u})?\\${n}?[A-Za-z]+\\${n}?[0-9]+`;t.COLUMN_REFERENCE_PATTERN=`(${u})?\\${n}?[A-Za-z]+`,t.ROW_REFERENCE_PATTERN=`(${u})?\\${n}?[0-9]+`,t.R1C1_CELL_REFERENCE_PATTERN="[rR][0-9]*[cC][0-9]*",t.CELL_REFERENCE_WITH_NEXT_CHARACTER_PATTERN=`(${c})[^${s}]`,t.NAMED_EXPRESSION_PATTERN=`[${o}_][${s}]*`,t.ALL_DIGITS_ARRAY=["0","1","2","3","4","5","6","7","8","9"],t.ALL_UNICODE_LETTERS_ARRAY=[...Array.from(Array(26)).map((e,t)=>t+"A".charCodeAt(0)),...Array.from(Array(26)).map((e,t)=>t+"a".charCodeAt(0)),...Array.from(Array(496)).map((e,t)=>t+192)].map(e=>String.fromCharCode(e))},function(e,t,r){"use strict";t.__esModule=!0,t.ParserWithCaching=void 0,r(2);var n=r(85),o=r(74),s=r(78),i=r(79),a=r(128),u=r(129),c=r(130),l=r(131),h=r(133),d=r(136),p=r(81),m=r(82); +const n=t.ABSOLUTE_OPERATOR="$",o=(t.ALL_WHITESPACE_PATTERN="\\s+",t.ODFF_WHITESPACE_PATTERN="[ \\t\\n\\r]+",t.UNICODE_LETTER_PATTERN="A-Za-zÀ-ʯ"),s=t.NON_RESERVED_CHARACTER_PATTERN=o+"0-9_.",i=t.UNQUOTED_SHEET_NAME_PATTERN=`[${o}0-9_]+`,a=t.QUOTED_SHEET_NAME_PATTERN="'(((?!').|'')*)'",u=t.SHEET_NAME_PATTERN=`(${i}|${a})!`,c=t.CELL_REFERENCE_PATTERN=`(${u})?\\${n}?[A-Za-z]+\\${n}?[0-9]+`;t.COLUMN_REFERENCE_PATTERN=`(${u})?\\${n}?[A-Za-z]+`,t.ROW_REFERENCE_PATTERN=`(${u})?\\${n}?[0-9]+`,t.R1C1_CELL_REFERENCE_PATTERN="[rR][0-9]*[cC][0-9]*",t.CELL_REFERENCE_WITH_NEXT_CHARACTER_PATTERN=`(${c})[^${s}]`,t.NAMED_EXPRESSION_PATTERN=`[${o}_][${s}]*`,t.ALL_DIGITS_ARRAY=["0","1","2","3","4","5","6","7","8","9"],t.ALL_UNICODE_LETTERS_ARRAY=[...Array.from(Array(26)).map((e,t)=>t+"A".charCodeAt(0)),...Array.from(Array(26)).map((e,t)=>t+"a".charCodeAt(0)),...Array.from(Array(496)).map((e,t)=>t+192)].map(e=>String.fromCharCode(e))},function(e,t,r){"use strict";t.__esModule=!0,t.ParserWithCaching=void 0,r(2);var n=r(84),o=r(73),s=r(77),i=r(78),a=r(127),u=r(128),c=r(129),l=r(130),h=r(132),d=r(135),p=r(80),m=r(81); /** * @license - * Copyright (c) 2023 Handsoncode. All rights reserved. + * Copyright (c) 2024 Handsoncode. All rights reserved. */ -class g{constructor(e,t,r){this.config=e,this.functionRegistry=t,this.sheetMapping=r,this.statsCacheUsed=0,this.lexerConfig=(0,h.buildLexerConfig)(e),this.lexer=new l.FormulaLexer(this.lexerConfig),this.formulaParser=new l.FormulaParser(this.lexerConfig,this.sheetMapping),this.cache=new c.Cache(this.functionRegistry)}parse(e,t){this.formulaAddress=t;const r=this.tokenizeFormula(e);if(r.errors.length>0){const e=r.errors.map(e=>({type:a.ParsingErrorType.LexingError,message:e.message}));return{ast:(0,s.buildParsingErrorAst)(),errors:e,hasVolatileFunction:!1,hasStructuralChangeFunction:!1,dependencies:[]}}const n=this.computeHashFromTokens(r.tokens,t);let o=this.cache.get(n);if(void 0!==o)++this.statsCacheUsed;else{const e=this.bindWhitespacesToTokens(r.tokens),s=this.formulaParser.parseFromTokens(e,t);if(s.errors.length>0)return Object.assign(Object.assign({},s),{hasVolatileFunction:!1,hasStructuralChangeFunction:!1,dependencies:[]});o=this.cache.set(n,s.ast)}const{ast:i,hasVolatileFunction:u,hasStructuralChangeFunction:c}=o,l=this.convertReversedRangesToRegularRanges(i);return{ast:l,errors:[],hasVolatileFunction:u,hasStructuralChangeFunction:c,dependencies:(0,s.collectDependencies)(l,this.functionRegistry)}}convertReversedRangesToRegularRanges(e){switch(e.type){case s.AstNodeType.EMPTY:case s.AstNodeType.NUMBER:case s.AstNodeType.STRING:case s.AstNodeType.ERROR:case s.AstNodeType.ERROR_WITH_RAW_INPUT:case s.AstNodeType.CELL_REFERENCE:case s.AstNodeType.NAMED_EXPRESSION:return e;case s.AstNodeType.CELL_RANGE:{const{start:t,end:r}=e,n=this.orderCellRangeEnds(t,r);return Object.assign(Object.assign({},e),{start:n.start,end:n.end})}case s.AstNodeType.COLUMN_RANGE:{const{start:t,end:r}=e,n=this.orderColumnRangeEnds(t,r);return Object.assign(Object.assign({},e),{start:n.start,end:n.end})}case s.AstNodeType.ROW_RANGE:{const{start:t,end:r}=e,n=this.orderRowRangeEnds(t,r);return Object.assign(Object.assign({},e),{start:n.start,end:n.end})}case s.AstNodeType.PERCENT_OP:case s.AstNodeType.PLUS_UNARY_OP:case s.AstNodeType.MINUS_UNARY_OP:{const t=this.convertReversedRangesToRegularRanges(e.value);return Object.assign(Object.assign({},e),{value:t})}case s.AstNodeType.CONCATENATE_OP:case s.AstNodeType.EQUALS_OP:case s.AstNodeType.NOT_EQUAL_OP:case s.AstNodeType.LESS_THAN_OP:case s.AstNodeType.GREATER_THAN_OP:case s.AstNodeType.LESS_THAN_OR_EQUAL_OP:case s.AstNodeType.GREATER_THAN_OR_EQUAL_OP:case s.AstNodeType.MINUS_OP:case s.AstNodeType.PLUS_OP:case s.AstNodeType.TIMES_OP:case s.AstNodeType.DIV_OP:case s.AstNodeType.POWER_OP:{const t=this.convertReversedRangesToRegularRanges(e.left),r=this.convertReversedRangesToRegularRanges(e.right);return Object.assign(Object.assign({},e),{left:t,right:r})}case s.AstNodeType.PARENTHESIS:{const t=this.convertReversedRangesToRegularRanges(e.expression);return Object.assign(Object.assign({},e),{expression:t})}case s.AstNodeType.FUNCTION_CALL:{const t=e.args.map(e=>this.convertReversedRangesToRegularRanges(e));return Object.assign(Object.assign({},e),{args:t})}case s.AstNodeType.ARRAY:{const t=e.args.map(e=>e.map(e=>this.convertReversedRangesToRegularRanges(e)));return Object.assign(Object.assign({},e),{args:t})}}}orderCellRangeEnds(e,t){const r=[e,t],[n,o]=r.map(e=>e.toColumnAddress()).sort(p.ColumnAddress.compareByAbsoluteAddress(this.formulaAddress)),[i,a]=r.map(e=>e.toRowAddress()).sort(m.RowAddress.compareByAbsoluteAddress(this.formulaAddress)),[u,c]=r.map(e=>e.sheet).sort(g.compareSheetIds.bind(this));return{start:s.CellAddress.fromColAndRow(n,i,u),end:s.CellAddress.fromColAndRow(o,a,c)}}orderColumnRangeEnds(e,t){const r=[e,t],[n,o]=r.sort(p.ColumnAddress.compareByAbsoluteAddress(this.formulaAddress)),[s,i]=r.map(e=>e.sheet).sort(g.compareSheetIds.bind(this));return{start:new p.ColumnAddress(n.type,n.col,s),end:new p.ColumnAddress(o.type,o.col,i)}}orderRowRangeEnds(e,t){const r=[e,t],[n,o]=r.sort(m.RowAddress.compareByAbsoluteAddress(this.formulaAddress)),[s,i]=r.map(e=>e.sheet).sort(g.compareSheetIds.bind(this));return{start:new m.RowAddress(n.type,n.row,s),end:new m.RowAddress(o.type,o.row,i)}}static compareSheetIds(e,t){return(e=null!=e?e:1/0)-(t=null!=t?t:1/0)}fetchCachedResultForAst(e){const t=this.computeHashFromAst(e);return this.fetchCachedResult(t)}fetchCachedResult(e){const t=this.cache.get(e);if(void 0===t)throw new Error("There is no AST with such key in the cache");{const{ast:e,hasVolatileFunction:r,hasStructuralChangeFunction:n,relativeDependencies:o}=t;return{ast:e,errors:[],hasVolatileFunction:r,hasStructuralChangeFunction:n,dependencies:o}}}computeHashFromTokens(e,t){var r;let o="",s=0;for(;sthis.computeHashOfAstNode(e)).join(this.config.functionArgSeparator),r=e.procedureName+"("+t+(0,a.imageWithWhitespace)(")",e.internalWhitespace);return(0,a.imageWithWhitespace)(r,e.leadingWhitespace)}case s.AstNodeType.CELL_REFERENCE:return(0,a.imageWithWhitespace)(e.reference.hash(!0),e.leadingWhitespace);case s.AstNodeType.COLUMN_RANGE:case s.AstNodeType.ROW_RANGE:case s.AstNodeType.CELL_RANGE:{const t=e.start.hash(e.sheetReferenceType!==a.RangeSheetReferenceType.RELATIVE),r=e.end.hash(e.sheetReferenceType===a.RangeSheetReferenceType.BOTH_ABSOLUTE);return(0,a.imageWithWhitespace)(t+":"+r,e.leadingWhitespace)}case s.AstNodeType.MINUS_UNARY_OP:return(0,a.imageWithWhitespace)("-"+this.computeHashOfAstNode(e.value),e.leadingWhitespace);case s.AstNodeType.PLUS_UNARY_OP:return(0,a.imageWithWhitespace)("+"+this.computeHashOfAstNode(e.value),e.leadingWhitespace);case s.AstNodeType.PERCENT_OP:return this.computeHashOfAstNode(e.value)+(0,a.imageWithWhitespace)("%",e.leadingWhitespace);case s.AstNodeType.ERROR:{const t=this.config.translationPackage.getErrorTranslation(e.error?e.error.type:o.ErrorType.ERROR);return(0,a.imageWithWhitespace)(t,e.leadingWhitespace)}case s.AstNodeType.ERROR_WITH_RAW_INPUT:return(0,a.imageWithWhitespace)(e.rawInput,e.leadingWhitespace);case s.AstNodeType.ARRAY:{const t=e.args.map(e=>e.map(e=>this.computeHashOfAstNode(e)).join(",")).join(";");return(0,a.imageWithWhitespace)("{"+t+(0,a.imageWithWhitespace)("}",e.internalWhitespace),e.leadingWhitespace)}case s.AstNodeType.PARENTHESIS:{const t="("+this.computeHashOfAstNode(e.expression)+(0,a.imageWithWhitespace)(")",e.internalWhitespace);return(0,a.imageWithWhitespace)(t,e.leadingWhitespace)}default:return this.computeHashOfAstNode(e.left)+(0,a.imageWithWhitespace)(u.binaryOpTokenMap[e.type],e.leadingWhitespace)+this.computeHashOfAstNode(e.right)}}bindWhitespacesToTokens(e){const t=[],r=e[0];(0,n.tokenMatcher)(r,this.lexerConfig.WhiteSpace)||t.push(r);for(let r=1;r IParserConfig property is soft-deprecated and will be removed in future versions.\n\tPlease use the flag on the relevant DSL method instead."),this.ignoredIssues=Object(o.has)(t,"ignoredIssues")?t.ignoredIssues:S.ignoredIssues,this.skipValidations=Object(o.has)(t,"skipValidations")?t.skipValidations:S.skipValidations}return e.performSelfAnalysis=function(e){e.performSelfAnalysis()},e.prototype.performSelfAnalysis=function(){var t=this;this.TRACE_INIT("performSelfAnalysis",(function(){var r;t.selfAnalysisDone=!0;var n=t.className;t.TRACE_INIT("toFastProps",(function(){Object(o.toFastProperties)(t)})),t.TRACE_INIT("Grammar Recording",(function(){try{t.enableRecording(),Object(o.forEach)(t.definedRulesNames,(function(e){var r=t[e].originalGrammarAction,n=void 0;t.TRACE_INIT(e+" Rule",(function(){n=t.topLevelRuleRecord(e,r)})),t.gastProductionsCache[e]=n}))}finally{t.disableRecording()}}));var i=[];if(t.TRACE_INIT("Grammar Resolving",(function(){i=Object(c.resolveGrammar)({rules:Object(o.values)(t.gastProductionsCache)}),t.definitionErrors.push.apply(t.definitionErrors,i)})),t.TRACE_INIT("Grammar Validations",(function(){if(Object(o.isEmpty)(i)&&!1===t.skipValidations){var e=Object(c.validateGrammar)({rules:Object(o.values)(t.gastProductionsCache),maxLookahead:t.maxLookahead,tokenTypes:Object(o.values)(t.tokensMap),ignoredIssues:t.ignoredIssues,errMsgProvider:u.defaultGrammarValidatorErrorProvider,grammarName:n});t.definitionErrors.push.apply(t.definitionErrors,e)}})),Object(o.isEmpty)(t.definitionErrors)&&(t.recoveryEnabled&&t.TRACE_INIT("computeAllProdsFollows",(function(){var e=Object(s.computeAllProdsFollows)(Object(o.values)(t.gastProductionsCache));t.resyncFollows=e})),t.TRACE_INIT("ComputeLookaheadFunctions",(function(){t.preComputeLookaheadFunctions(Object(o.values)(t.gastProductionsCache))}))),t.TRACE_INIT("expandAllNestedRuleNames",(function(){var e=Object(a.expandAllNestedRuleNames)(Object(o.values)(t.gastProductionsCache),t.fullRuleNameToShort);t.allRuleNames=e.allRuleNames})),!e.DEFER_DEFINITION_ERRORS_HANDLING&&!Object(o.isEmpty)(t.definitionErrors))throw r=Object(o.map)(t.definitionErrors,(function(e){return e.message})),new Error("Parser Definition Errors detected:\n "+r.join("\n-------------------------------\n"))}))},e.DEFER_DEFINITION_ERRORS_HANDLING=!1,e}();Object(o.applyMixins)(O,[l.Recoverable,h.LooksAhead,d.TreeBuilder,p.LexerAdapter,g.RecognizerEngine,m.RecognizerApi,f.ErrorHandler,E.ContentAssist,T.GastRecorder,y.PerformanceTracer]);var I=function(e){function t(t,r){void 0===r&&(r=S);var n=Object(o.cloneObj)(r);return n.outputCst=!0,e.call(this,t,n)||this}return A(t,e),t}(O),M=function(e){function t(t,r){void 0===r&&(r=S);var n=Object(o.cloneObj)(r);return n.outputCst=!1,e.call(this,t,n)||this}return A(t,e),t}(O)},function(e,t,r){"use strict";function n(e){return e&&0===e.length}function o(e){return null==e?[]:Object.keys(e)}function s(e){for(var t=[],r=Object.keys(e),n=0;n property on the Lexer config.\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS");if(t.safeMode&&t.ensureOptimizations)throw Error('"safeMode" and "ensureOptimizations" flags are mutually exclusive.');r.trackStartLines=/full|onlyStart/i.test(r.config.positionTracking),r.trackEndLines=/full/i.test(r.config.positionTracking),Object(s.isArray)(e)?((n={modes:{}}).modes[o.DEFAULT_MODE]=Object(s.cloneArr)(e),n[o.DEFAULT_MODE]=o.DEFAULT_MODE):(a=!1,n=Object(s.cloneObj)(e))})),!1===r.config.skipValidations&&(r.TRACE_INIT("performRuntimeChecks",(function(){r.lexerDefinitionErrors=r.lexerDefinitionErrors.concat(Object(o.performRuntimeChecks)(n,r.trackStartLines,r.config.lineTerminatorCharacters))})),r.TRACE_INIT("performWarningRuntimeChecks",(function(){r.lexerDefinitionWarning=r.lexerDefinitionWarning.concat(Object(o.performWarningRuntimeChecks)(n,r.trackStartLines,r.config.lineTerminatorCharacters))}))),n.modes=n.modes?n.modes:{},Object(s.forEach)(n.modes,(function(e,t){n.modes[t]=Object(s.reject)(e,(function(e){return Object(s.isUndefined)(e)}))}));var l=Object(s.keys)(n.modes);if(Object(s.forEach)(n.modes,(function(e,n){r.TRACE_INIT("Mode: <"+n+"> processing",(function(){var a;r.modes.push(n),!1===r.config.skipValidations&&r.TRACE_INIT("validatePatterns",(function(){r.lexerDefinitionErrors=r.lexerDefinitionErrors.concat(Object(o.validatePatterns)(e,l))})),Object(s.isEmpty)(r.lexerDefinitionErrors)&&(Object(i.augmentTokenTypes)(e),r.TRACE_INIT("analyzeTokenTypes",(function(){a=Object(o.analyzeTokenTypes)(e,{lineTerminatorCharacters:r.config.lineTerminatorCharacters,positionTracking:t.positionTracking,ensureOptimizations:t.ensureOptimizations,safeMode:t.safeMode,tracer:r.TRACE_INIT.bind(r)})})),r.patternIdxToConfig[n]=a.patternIdxToConfig,r.charCodeToPatternIdxToConfig[n]=a.charCodeToPatternIdxToConfig,r.emptyGroups=Object(s.merge)(r.emptyGroups,a.emptyGroups),r.hasCustom=a.hasCustom||r.hasCustom,r.canModeBeOptimized[n]=a.canBeOptimized)}))})),r.defaultMode=n.defaultMode,!Object(s.isEmpty)(r.lexerDefinitionErrors)&&!r.config.deferDefinitionErrorsHandling){var h=Object(s.map)(r.lexerDefinitionErrors,(function(e){return e.message})).join("-----------------------\n");throw new Error("Errors detected in definition of Lexer:\n"+h)}Object(s.forEach)(r.lexerDefinitionWarning,(function(e){Object(s.PRINT_WARNING)(e.message)})),r.TRACE_INIT("Choosing sub-methods implementations",(function(){if(o.SUPPORT_STICKY?(r.chopInput=s.IDENTITY,r.match=r.matchWithTest):(r.updateLastIndex=s.NOOP,r.match=r.matchWithExec),a&&(r.handleModes=s.NOOP),!1===r.trackStartLines&&(r.computeNewColumn=s.IDENTITY),!1===r.trackEndLines&&(r.updateTokenEndLineColumnLocation=s.NOOP),/full/i.test(r.config.positionTracking))r.createTokenInstance=r.createFullToken;else if(/onlyStart/i.test(r.config.positionTracking))r.createTokenInstance=r.createStartOnlyToken;else{if(!/onlyOffset/i.test(r.config.positionTracking))throw Error('Invalid config option: "'+r.config.positionTracking+'"');r.createTokenInstance=r.createOffsetOnlyToken}r.hasCustom?(r.addToken=r.addTokenUsingPush,r.handlePayload=r.handlePayloadWithCustom):(r.addToken=r.addTokenUsingMemberAccess,r.handlePayload=r.handlePayloadNoCustom)})),r.TRACE_INIT("Failed Optimization Warnings",(function(){var e=Object(s.reduce)(r.canModeBeOptimized,(function(e,t,r){return!1===t&&e.push(r),e}),[]);if(t.ensureOptimizations&&!Object(s.isEmpty)(e))throw Error("Lexer Modes: < "+e.join(", ")+' > cannot be optimized.\n\t Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode.\n\t Or inspect the console log for details on how to resolve these issues.')})),r.TRACE_INIT("clearRegExpParserCache",(function(){Object(u.clearRegExpParserCache)()})),r.TRACE_INIT("toFastProperties",(function(){Object(s.toFastProperties)(r)}))}))}return e.prototype.tokenize=function(e,t){if(void 0===t&&(t=this.defaultMode),!Object(s.isEmpty)(this.lexerDefinitionErrors)){var r=Object(s.map)(this.lexerDefinitionErrors,(function(e){return e.message})).join("-----------------------\n");throw new Error("Unable to Tokenize because Errors detected in definition of Lexer:\n"+r)}return this.tokenizeInternal(e,t)},e.prototype.tokenizeInternal=function(e,t){var r,n,i,a,u,c,l,h,d,p,m,g,f,E,T=this,y=e,A=y.length,R=0,N=0,S=this.hasCustom?0:Math.floor(e.length/10),C=new Array(S),v=[],O=this.trackStartLines?1:void 0,I=this.trackStartLines?1:void 0,M=Object(o.cloneEmptyGroups)(this.emptyGroups),F=this.trackStartLines,b=this.config.lineTerminatorsPattern,w=0,_=[],L=[],x=[],P=[];Object.freeze(P);var U=void 0;function V(){return _}function D(e){var t=Object(o.charCodeToOptimizedIndex)(e),r=L[t];return void 0===r?P:r}var B,k=function(e){if(1===x.length&&void 0===e.tokenType.PUSH_MODE){var t=T.config.errorMessageProvider.buildUnableToPopLexerModeMessage(e);v.push({offset:e.startOffset,line:void 0!==e.startLine?e.startLine:void 0,column:void 0!==e.startColumn?e.startColumn:void 0,length:e.image.length,message:t})}else{x.pop();var r=Object(s.last)(x);_=T.patternIdxToConfig[r],L=T.charCodeToPatternIdxToConfig[r],w=_.length;var n=T.canModeBeOptimized[r]&&!1===T.config.safeMode;U=L&&n?D:V}};function G(e){x.push(e),L=this.charCodeToPatternIdxToConfig[e],_=this.patternIdxToConfig[e],w=_.length,w=_.length;var t=this.canModeBeOptimized[e]&&!1===this.config.safeMode;U=L&&t?D:V}for(G.call(this,t);Ru.length&&(u=i,c=l,B=Y)}break}}if(null!==u){if(h=u.length,void 0!==(d=B.group)&&(p=B.tokenTypeIdx,m=this.createTokenInstance(u,R,p,B.tokenType,O,I,h),this.handlePayload(m,c),!1===d?N=this.addToken(C,N,m):M[d].push(m)),e=this.chopInput(e,h),R+=h,I=this.computeNewColumn(I,h),!0===F&&!0===B.canLineTerminator){var K=0,$=void 0,q=void 0;b.lastIndex=0;do{!0===($=b.test(u))&&(q=b.lastIndex-1,K++)}while(!0===$);0!==K&&(O+=K,I=h-q,this.updateTokenEndLineColumnLocation(m,d,q,K,O,I,h))}this.handleModes(B,k,G,m)}else{for(var Q=R,Z=O,J=I,ee=!1;!ee&&R");var n=Object(s.timer)(t),o=n.time,i=n.value,a=o>10?console.warn:console.log;return this.traceInitIndent time: "+o+"ms"),this.traceInitIndent--,i}return t()},e.SKIPPED="This marks a skipped Token pattern, this means each token identified by it willbe consumed and then thrown into oblivion, this can be used to for example to completely ignore whitespace.",e.NA=/NOT_APPLICABLE/,e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"DEFAULT_MODE",(function(){return h})),r.d(t,"MODES",(function(){return d})),r.d(t,"SUPPORT_STICKY",(function(){return p})),r.d(t,"disableSticky",(function(){return m})),r.d(t,"enableSticky",(function(){return g})),r.d(t,"analyzeTokenTypes",(function(){return f})),r.d(t,"validatePatterns",(function(){return E})),r.d(t,"findMissingPatterns",(function(){return T})),r.d(t,"findInvalidPatterns",(function(){return y})),r.d(t,"findEndOfInputAnchor",(function(){return R})),r.d(t,"findEmptyMatchRegExps",(function(){return N})),r.d(t,"findStartOfInputAnchor",(function(){return C})),r.d(t,"findUnsupportedFlags",(function(){return v})),r.d(t,"findDuplicatePatterns",(function(){return O})),r.d(t,"findInvalidGroupType",(function(){return I})),r.d(t,"findModesThatDoNotExist",(function(){return M})),r.d(t,"findUnreachablePatterns",(function(){return F})),r.d(t,"addStartOfInput",(function(){return b})),r.d(t,"addStickyFlag",(function(){return w})),r.d(t,"performRuntimeChecks",(function(){return _})),r.d(t,"performWarningRuntimeChecks",(function(){return L})),r.d(t,"cloneEmptyGroups",(function(){return x})),r.d(t,"isCustomPattern",(function(){return P})),r.d(t,"isShortPattern",(function(){return U})),r.d(t,"LineTerminatorOptimizedTester",(function(){return V})),r.d(t,"buildLineBreakIssueMessage",(function(){return B})),r.d(t,"minOptimizationVal",(function(){return j})),r.d(t,"charCodeToOptimizedIndex",(function(){return W}));var n,o=r(95),s=r(93),i=r(88),a=r(96),u=r(97),c=(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),l="PATTERN",h="defaultMode",d="modes",p="boolean"==typeof new RegExp("(?:)").sticky;function m(){p=!1}function g(){p=!0}function f(e,t){var r,n=(t=Object(i.defaults)(t,{useSticky:p,debug:!1,safeMode:!1,positionTracking:"full",lineTerminatorCharacters:["\r","\n"],tracer:function(e,t){return t()}})).tracer;n("initCharCodeToOptimizedIndexMap",(function(){!function(){if(Object(i.isEmpty)(H)){H=new Array(65536);for(var e=0;e<65536;e++)H[e]=e>255?255+~~(e/255):e}}()})),n("Reject Lexer.NA",(function(){r=Object(i.reject)(e,(function(e){return e[l]===s.Lexer.NA}))}));var o,u,c,h,d,m,g,f,E,T,y,A=!1;n("Transform Patterns",(function(){A=!1,o=Object(i.map)(r,(function(e){var r=e[l];if(Object(i.isRegExp)(r)){var n=r.source;return 1===n.length&&"^"!==n&&"$"!==n&&"."!==n?n:2!==n.length||"\\"!==n[0]||Object(i.contains)(["d","D","s","S","t","r","n","t","0","c","b","B","f","v","w","W"],n[1])?t.useSticky?w(r):b(r):n[1]}if(Object(i.isFunction)(r))return A=!0,{exec:r};if(Object(i.has)(r,"exec"))return A=!0,r;if("string"==typeof r){if(1===r.length)return r;var o=r.replace(/[\\^$.*+?()[\]{}|]/g,"\\$&"),s=new RegExp(o);return t.useSticky?w(s):b(s)}throw Error("non exhaustive match")}))})),n("misc mapping",(function(){u=Object(i.map)(r,(function(e){return e.tokenTypeIdx})),c=Object(i.map)(r,(function(e){var t=e.GROUP;if(t!==s.Lexer.SKIPPED){if(Object(i.isString)(t))return t;if(Object(i.isUndefined)(t))return!1;throw Error("non exhaustive match")}})),h=Object(i.map)(r,(function(e){var t=e.LONGER_ALT;if(t)return Object(i.indexOf)(r,t)})),d=Object(i.map)(r,(function(e){return e.PUSH_MODE})),m=Object(i.map)(r,(function(e){return Object(i.has)(e,"POP_MODE")}))})),n("Line Terminator Handling",(function(){var e=k(t.lineTerminatorCharacters);g=Object(i.map)(r,(function(e){return!1})),"onlyOffset"!==t.positionTracking&&(g=Object(i.map)(r,(function(t){return Object(i.has)(t,"LINE_BREAKS")?t.LINE_BREAKS:!1===D(t,e)?Object(a.canMatchCharCode)(e,t.PATTERN):void 0})))})),n("Misc Mapping #2",(function(){f=Object(i.map)(r,P),E=Object(i.map)(o,U),T=Object(i.reduce)(r,(function(e,t){var r=t.GROUP;return Object(i.isString)(r)&&r!==s.Lexer.SKIPPED&&(e[r]=[]),e}),{}),y=Object(i.map)(o,(function(e,t){return{pattern:o[t],longerAlt:h[t],canLineTerminator:g[t],isCustom:f[t],short:E[t],group:c[t],push:d[t],pop:m[t],tokenTypeIdx:u[t],tokenType:r[t]}}))}));var R=!0,N=[];return t.safeMode||n("First Char Optimization",(function(){N=Object(i.reduce)(r,(function(e,r,n){if("string"==typeof r.PATTERN){var o=W(r.PATTERN.charCodeAt(0));G(e,o,y[n])}else if(Object(i.isArray)(r.START_CHARS_HINT)){var s;Object(i.forEach)(r.START_CHARS_HINT,(function(t){var r=W("string"==typeof t?t.charCodeAt(0):t);s!==r&&(s=r,G(e,r,y[n]))}))}else if(Object(i.isRegExp)(r.PATTERN))if(r.PATTERN.unicode)R=!1,t.ensureOptimizations&&Object(i.PRINT_ERROR)(a.failedOptimizationPrefixMsg+"\tUnable to analyze < "+r.PATTERN.toString()+" > pattern.\n\tThe regexp unicode flag is not currently supported by the regexp-to-ast library.\n\tThis will disable the lexer's first char optimizations.\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE");else{var u=Object(a.getOptimizedStartCodesIndices)(r.PATTERN,t.ensureOptimizations);Object(i.isEmpty)(u)&&(R=!1),Object(i.forEach)(u,(function(t){G(e,t,y[n])}))}else t.ensureOptimizations&&Object(i.PRINT_ERROR)(a.failedOptimizationPrefixMsg+"\tTokenType: <"+r.name+"> is using a custom token pattern without providing parameter.\n\tThis will disable the lexer's first char optimizations.\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE"),R=!1;return e}),[])})),n("ArrayPacking",(function(){N=Object(i.packArray)(N)})),{emptyGroups:T,patternIdxToConfig:y,charCodeToPatternIdxToConfig:N,hasCustom:A,canBeOptimized:R}}function E(e,t){var r=[],n=T(e);r=r.concat(n.errors);var o=y(n.valid),s=o.valid;return r=(r=(r=(r=(r=r.concat(o.errors)).concat(function(e){var t=[],r=Object(i.filter)(e,(function(e){return Object(i.isRegExp)(e[l])}));return t=(t=(t=(t=(t=t.concat(R(r))).concat(C(r))).concat(v(r))).concat(O(r))).concat(N(r))}(s))).concat(I(s))).concat(M(s,t))).concat(F(s))}function T(e){var t=Object(i.filter)(e,(function(e){return!Object(i.has)(e,l)}));return{errors:Object(i.map)(t,(function(e){return{message:"Token Type: ->"+e.name+"<- missing static 'PATTERN' property",type:s.LexerDefinitionErrorType.MISSING_PATTERN,tokenTypes:[e]}})),valid:Object(i.difference)(e,t)}}function y(e){var t=Object(i.filter)(e,(function(e){var t=e[l];return!(Object(i.isRegExp)(t)||Object(i.isFunction)(t)||Object(i.has)(t,"exec")||Object(i.isString)(t))}));return{errors:Object(i.map)(t,(function(e){return{message:"Token Type: ->"+e.name+"<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.",type:s.LexerDefinitionErrorType.INVALID_PATTERN,tokenTypes:[e]}})),valid:Object(i.difference)(e,t)}}var A=/[^\\][\$]/;function R(e){var t=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.found=!1,t}return c(t,e),t.prototype.visitEndAnchor=function(e){this.found=!0},t}(o.BaseRegExpVisitor),r=Object(i.filter)(e,(function(e){var r=e[l];try{var n=Object(u.getRegExpAst)(r),o=new t;return o.visit(n),o.found}catch(e){return A.test(r.source)}}));return Object(i.map)(r,(function(e){return{message:"Unexpected RegExp Anchor Error:\n\tToken Type: ->"+e.name+"<- static 'PATTERN' cannot contain end of input anchor '$'\n\tSee sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#ANCHORS\tfor details.",type:s.LexerDefinitionErrorType.EOI_ANCHOR_FOUND,tokenTypes:[e]}}))}function N(e){var t=Object(i.filter)(e,(function(e){return e[l].test("")}));return Object(i.map)(t,(function(e){return{message:"Token Type: ->"+e.name+"<- static 'PATTERN' must not match an empty string",type:s.LexerDefinitionErrorType.EMPTY_MATCH_PATTERN,tokenTypes:[e]}}))}var S=/[^\\[][\^]|^\^/;function C(e){var t=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.found=!1,t}return c(t,e),t.prototype.visitStartAnchor=function(e){this.found=!0},t}(o.BaseRegExpVisitor),r=Object(i.filter)(e,(function(e){var r=e[l];try{var n=Object(u.getRegExpAst)(r),o=new t;return o.visit(n),o.found}catch(e){return S.test(r.source)}}));return Object(i.map)(r,(function(e){return{message:"Unexpected RegExp Anchor Error:\n\tToken Type: ->"+e.name+"<- static 'PATTERN' cannot contain start of input anchor '^'\n\tSee https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#ANCHORS\tfor details.",type:s.LexerDefinitionErrorType.SOI_ANCHOR_FOUND,tokenTypes:[e]}}))}function v(e){var t=Object(i.filter)(e,(function(e){var t=e[l];return t instanceof RegExp&&(t.multiline||t.global)}));return Object(i.map)(t,(function(e){return{message:"Token Type: ->"+e.name+"<- static 'PATTERN' may NOT contain global('g') or multiline('m')",type:s.LexerDefinitionErrorType.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[e]}}))}function O(e){var t=[],r=Object(i.map)(e,(function(r){return Object(i.reduce)(e,(function(e,n){return r.PATTERN.source!==n.PATTERN.source||Object(i.contains)(t,n)||n.PATTERN===s.Lexer.NA||(t.push(n),e.push(n)),e}),[])}));r=Object(i.compact)(r);var n=Object(i.filter)(r,(function(e){return e.length>1}));return Object(i.map)(n,(function(e){var t=Object(i.map)(e,(function(e){return e.name}));return{message:"The same RegExp pattern ->"+Object(i.first)(e).PATTERN+"<-has been used in all of the following Token Types: "+t.join(", ")+" <-",type:s.LexerDefinitionErrorType.DUPLICATE_PATTERNS_FOUND,tokenTypes:e}}))}function I(e){var t=Object(i.filter)(e,(function(e){if(!Object(i.has)(e,"GROUP"))return!1;var t=e.GROUP;return t!==s.Lexer.SKIPPED&&t!==s.Lexer.NA&&!Object(i.isString)(t)}));return Object(i.map)(t,(function(e){return{message:"Token Type: ->"+e.name+"<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String",type:s.LexerDefinitionErrorType.INVALID_GROUP_TYPE_FOUND,tokenTypes:[e]}}))}function M(e,t){var r=Object(i.filter)(e,(function(e){return void 0!==e.PUSH_MODE&&!Object(i.contains)(t,e.PUSH_MODE)}));return Object(i.map)(r,(function(e){return{message:"Token Type: ->"+e.name+"<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->"+e.PUSH_MODE+"<-which does not exist",type:s.LexerDefinitionErrorType.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[e]}}))}function F(e){var t=[],r=Object(i.reduce)(e,(function(e,t,r){var n,o=t.PATTERN;return o===s.Lexer.NA||(Object(i.isString)(o)?e.push({str:o,idx:r,tokenType:t}):Object(i.isRegExp)(o)&&(n=o,void 0===Object(i.find)([".","\\","[","]","|","^","$","(",")","?","*","+","{"],(function(e){return-1!==n.source.indexOf(e)})))&&e.push({str:o.source,idx:r,tokenType:t})),e}),[]);return Object(i.forEach)(e,(function(e,n){Object(i.forEach)(r,(function(r){var o=r.str,a=r.idx,u=r.tokenType;if(n"+e.name+"<-in the lexer's definition.\nSee https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#UNREACHABLE";t.push({message:c,type:s.LexerDefinitionErrorType.UNREACHABLE_PATTERN,tokenTypes:[e,u]})}}))})),t}function b(e){var t=e.ignoreCase?"i":"";return new RegExp("^(?:"+e.source+")",t)}function w(e){var t=e.ignoreCase?"iy":"y";return new RegExp(""+e.source,t)}function _(e,t,r){var n=[];return Object(i.has)(e,h)||n.push({message:"A MultiMode Lexer cannot be initialized without a <"+h+"> property in its definition\n",type:s.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),Object(i.has)(e,d)||n.push({message:"A MultiMode Lexer cannot be initialized without a <"+d+"> property in its definition\n",type:s.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),Object(i.has)(e,d)&&Object(i.has)(e,h)&&!Object(i.has)(e.modes,e.defaultMode)&&n.push({message:"A MultiMode Lexer cannot be initialized with a "+h+": <"+e.defaultMode+">which does not exist\n",type:s.LexerDefinitionErrorType.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),Object(i.has)(e,d)&&Object(i.forEach)(e.modes,(function(e,t){Object(i.forEach)(e,(function(e,r){Object(i.isUndefined)(e)&&n.push({message:"A Lexer cannot be initialized using an undefined Token Type. Mode:<"+t+"> at index: <"+r+">\n",type:s.LexerDefinitionErrorType.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED})}))})),n}function L(e,t,r){var n=[],o=!1,u=Object(i.compact)(Object(i.flatten)(Object(i.mapValues)(e.modes,(function(e){return e})))),c=Object(i.reject)(u,(function(e){return e[l]===s.Lexer.NA})),h=k(r);return t&&Object(i.forEach)(c,(function(e){var t=D(e,h);if(!1!==t){var r={message:B(e,t),type:t.issue,tokenType:e};n.push(r)}else Object(i.has)(e,"LINE_BREAKS")?!0===e.LINE_BREAKS&&(o=!0):Object(a.canMatchCharCode)(h,e.PATTERN)&&(o=!0)})),t&&!o&&n.push({message:"Warning: No LINE_BREAKS Found.\n\tThis Lexer has been defined to track line and column information,\n\tBut none of the Token Types can be identified as matching a line terminator.\n\tSee https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#LINE_BREAKS \n\tfor details.",type:s.LexerDefinitionErrorType.NO_LINE_BREAKS_FLAGS}),n}function x(e){var t={},r=Object(i.keys)(e);return Object(i.forEach)(r,(function(r){var n=e[r];if(!Object(i.isArray)(n))throw Error("non exhaustive match");t[r]=[]})),t}function P(e){var t=e.PATTERN;if(Object(i.isRegExp)(t))return!1;if(Object(i.isFunction)(t))return!0;if(Object(i.has)(t,"exec"))return!0;if(Object(i.isString)(t))return!1;throw Error("non exhaustive match")}function U(e){return!(!Object(i.isString)(e)||1!==e.length)&&e.charCodeAt(0)}var V={test:function(e){for(var t=e.length,r=this.lastIndex;r Token Type\n\t Root cause: "+t.errMsg+".\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR";if(t.issue===s.LexerDefinitionErrorType.CUSTOM_LINE_BREAK)return"Warning: A Custom Token Pattern should specify the option.\n\tThe problem is in the <"+e.name+"> Token Type\n\tFor details See: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK";throw Error("non exhaustive match")}function k(e){return Object(i.map)(e,(function(e){return Object(i.isString)(e)&&e.length>0?e.charCodeAt(0):e}))}function G(e,t,r){void 0===e[t]?e[t]=[r]:e[t].push(r)}var j=256;function W(e){return e=this.input.length)throw Error("Unexpected end of input");this.idx++};var t,r=/[0-9a-fA-F]/,n=/[0-9]/,o=/[1-9]/;function s(e){return e.charCodeAt(0)}function i(e,t){void 0!==e.length?e.forEach((function(e){t.push(e)})):t.push(e)}function a(e,t){if(!0===e[t])throw"duplicate flag "+t;e[t]=!0}function u(e){if(void 0===e)throw Error("Internal Error - Should never get here!")}var c=[];for(t=s("0");t<=s("9");t++)c.push(t);var l=[s("_")].concat(c);for(t=s("a");t<=s("z");t++)l.push(t);for(t=s("A");t<=s("Z");t++)l.push(t);var h=[s(" "),s("\f"),s("\n"),s("\r"),s("\t"),s("\v"),s("\t"),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s(" "),s("\u2028"),s("\u2029"),s(" "),s(" "),s(" "),s("\ufeff")];function d(){}return d.prototype.visitChildren=function(e){for(var t in e){var r=e[t];e.hasOwnProperty(t)&&(void 0!==r.type?this.visit(r):Array.isArray(r)&&r.forEach((function(e){this.visit(e)}),this))}},d.prototype.visit=function(e){switch(e.type){case"Pattern":this.visitPattern(e);break;case"Flags":this.visitFlags(e);break;case"Disjunction":this.visitDisjunction(e);break;case"Alternative":this.visitAlternative(e);break;case"StartAnchor":this.visitStartAnchor(e);break;case"EndAnchor":this.visitEndAnchor(e);break;case"WordBoundary":this.visitWordBoundary(e);break;case"NonWordBoundary":this.visitNonWordBoundary(e);break;case"Lookahead":this.visitLookahead(e);break;case"NegativeLookahead":this.visitNegativeLookahead(e);break;case"Character":this.visitCharacter(e);break;case"Set":this.visitSet(e);break;case"Group":this.visitGroup(e);break;case"GroupBackReference":this.visitGroupBackReference(e);break;case"Quantifier":this.visitQuantifier(e)}this.visitChildren(e)},d.prototype.visitPattern=function(e){},d.prototype.visitFlags=function(e){},d.prototype.visitDisjunction=function(e){},d.prototype.visitAlternative=function(e){},d.prototype.visitStartAnchor=function(e){},d.prototype.visitEndAnchor=function(e){},d.prototype.visitWordBoundary=function(e){},d.prototype.visitNonWordBoundary=function(e){},d.prototype.visitLookahead=function(e){},d.prototype.visitNegativeLookahead=function(e){},d.prototype.visitCharacter=function(e){},d.prototype.visitSet=function(e){},d.prototype.visitGroup=function(e){},d.prototype.visitGroupBackReference=function(e){},d.prototype.visitQuantifier=function(e){},{RegExpParser:e,BaseRegExpVisitor:d,VERSION:"0.4.0"}})?n.apply(t,o):n)||(e.exports=s)},function(e,t,r){"use strict";r.r(t),r.d(t,"failedOptimizationPrefixMsg",(function(){return c})),r.d(t,"getOptimizedStartCodesIndices",(function(){return l})),r.d(t,"firstCharOptimizedIndices",(function(){return h})),r.d(t,"canMatchCharCode",(function(){return f}));var n,o=r(95),s=r(88),i=r(97),a=r(94),u=(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),c='Unable to use "first char" lexer optimizations:\n';function l(e,t){void 0===t&&(t=!1);try{var r=Object(i.getRegExpAst)(e);return h(r.value,{},r.flags.ignoreCase)}catch(r){if("Complement Sets are not supported for first char optimization"===r.message)t&&Object(s.PRINT_WARNING)(c+"\tUnable to optimize: < "+e.toString()+" >\n\tComplement Sets cannot be automatically optimized.\n\tThis will disable the lexer's first char optimizations.\n\tSee: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.");else{var n="";t&&(n="\n\tThis will disable the lexer's first char optimizations.\n\tSee: https://sap.github.io/chevrotain/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details."),Object(s.PRINT_ERROR)(c+"\n\tFailed parsing: < "+e.toString()+" >\n\tUsing the regexp-to-ast library version: "+o.VERSION+"\n\tPlease open an issue at: https://github.com/bd82/regexp-to-ast/issues"+n)}}return[]}function h(e,t,r){switch(e.type){case"Disjunction":for(var n=0;n=a.minOptimizationVal)for(var s=n.from>=a.minOptimizationVal?n.from:a.minOptimizationVal,i=n.to,u=Object(a.charCodeToOptimizedIndex)(s),c=Object(a.charCodeToOptimizedIndex)(i),l=u;l<=c;l++)t[l]=l}}}));break;case"Group":h(u.value,t,r);break;default:throw Error("Non Exhaustive Match")}var c=void 0!==u.quantifier&&0===u.quantifier.atLeast;if("Group"===u.type&&!1===m(u)||"Group"!==u.type&&!1===c)break}break;default:throw Error("non exhaustive match!")}return Object(s.values)(t)}function d(e,t,r){var n=Object(a.charCodeToOptimizedIndex)(e);t[n]=n,!0===r&&function(e,t){var r=String.fromCharCode(e),n=r.toUpperCase();if(n!==r){var o=Object(a.charCodeToOptimizedIndex)(n.charCodeAt(0));t[o]=o}else{var s=r.toLowerCase();s!==r&&(o=Object(a.charCodeToOptimizedIndex)(s.charCodeAt(0)),t[o]=o)}}(e,t)}function p(e,t){return Object(s.find)(e.value,(function(e){if("number"==typeof e)return Object(s.contains)(t,e);var r=e;return void 0!==Object(s.find)(t,(function(e){return r.from<=e&&e<=r.to}))}))}function m(e){return!(!e.quantifier||0!==e.quantifier.atLeast)||!!e.value&&(Object(s.isArray)(e.value)?Object(s.every)(e.value,m):m(e.value))}var g=function(e){function t(t){var r=e.call(this)||this;return r.targetCharCodes=t,r.found=!1,r}return u(t,e),t.prototype.visitChildren=function(t){if(!0!==this.found){switch(t.type){case"Lookahead":return void this.visitLookahead(t);case"NegativeLookahead":return void this.visitNegativeLookahead(t)}e.prototype.visitChildren.call(this,t)}},t.prototype.visitCharacter=function(e){Object(s.contains)(this.targetCharCodes,e.value)&&(this.found=!0)},t.prototype.visitSet=function(e){e.complement?void 0===p(e,this.targetCharCodes)&&(this.found=!0):void 0!==p(e,this.targetCharCodes)&&(this.found=!0)},t}(o.BaseRegExpVisitor);function f(e,t){if(t instanceof RegExp){var r=Object(i.getRegExpAst)(t),n=new g(e);return n.visit(r),n.found}return void 0!==Object(s.find)(t,(function(t){return Object(s.contains)(e,t.charCodeAt(0))}))}},function(e,t,r){"use strict";r.r(t),r.d(t,"getRegExpAst",(function(){return i})),r.d(t,"clearRegExpParserCache",(function(){return a}));var n=r(95),o={},s=new n.RegExpParser;function i(e){var t=e.toString();if(o.hasOwnProperty(t))return o[t];var r=s.pattern(t);return o[t]=r,r}function a(){o={}}},function(e,t,r){"use strict";r.r(t),r.d(t,"tokenStructuredMatcher",(function(){return o})),r.d(t,"tokenStructuredMatcherNoCategories",(function(){return s})),r.d(t,"tokenShortNameIdx",(function(){return i})),r.d(t,"tokenIdxToClass",(function(){return a})),r.d(t,"augmentTokenTypes",(function(){return u})),r.d(t,"expandCategories",(function(){return c})),r.d(t,"assignTokenDefaultProps",(function(){return l})),r.d(t,"assignCategoriesTokensProp",(function(){return h})),r.d(t,"assignCategoriesMapProp",(function(){return d})),r.d(t,"singleAssignCategoriesToksMap",(function(){return p})),r.d(t,"hasShortKeyProperty",(function(){return m})),r.d(t,"hasCategoriesProperty",(function(){return g})),r.d(t,"hasExtendingTokensTypesProperty",(function(){return f})),r.d(t,"hasExtendingTokensTypesMapProperty",(function(){return E})),r.d(t,"isTokenType",(function(){return T}));var n=r(88);function o(e,t){var r=e.tokenTypeIdx;return r===t.tokenTypeIdx||!0===t.isParent&&!0===t.categoryMatchesMap[r]}function s(e,t){return e.tokenTypeIdx===t.tokenTypeIdx}var i=1,a={};function u(e){var t=c(e);l(t),d(t),h(t),Object(n.forEach)(t,(function(e){e.isParent=e.categoryMatches.length>0}))}function c(e){for(var t=Object(n.cloneArr)(e),r=e,o=!0;o;){r=Object(n.compact)(Object(n.flatten)(Object(n.map)(r,(function(e){return e.CATEGORIES}))));var s=Object(n.difference)(r,t);t=t.concat(s),Object(n.isEmpty)(s)?o=!1:r=s}return t}function l(e){Object(n.forEach)(e,(function(e){m(e)||(a[i]=e,e.tokenTypeIdx=i++),g(e)&&!Object(n.isArray)(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),g(e)||(e.CATEGORIES=[]),f(e)||(e.categoryMatches=[]),E(e)||(e.categoryMatchesMap={})}))}function h(e){Object(n.forEach)(e,(function(e){e.categoryMatches=[],Object(n.forEach)(e.categoryMatchesMap,(function(t,r){e.categoryMatches.push(a[r].tokenTypeIdx)}))}))}function d(e){Object(n.forEach)(e,(function(e){p([],e)}))}function p(e,t){Object(n.forEach)(e,(function(e){t.categoryMatchesMap[e.tokenTypeIdx]=!0})),Object(n.forEach)(t.CATEGORIES,(function(r){var o=e.concat(t);Object(n.contains)(o,r)||p(o,r)}))}function m(e){return Object(n.has)(e,"tokenTypeIdx")}function g(e){return Object(n.has)(e,"CATEGORIES")}function f(e){return Object(n.has)(e,"categoryMatches")}function E(e){return Object(n.has)(e,"categoryMatchesMap")}function T(e){return Object(n.has)(e,"tokenTypeIdx")}},function(e,t,r){"use strict";r.r(t),r.d(t,"defaultLexerErrorProvider",(function(){return n}));var n={buildUnableToPopLexerModeMessage:function(e){return"Unable to pop Lexer Mode after encountering Token ->"+e.image+"<- The Mode Stack is empty"},buildUnexpectedCharactersMessage:function(e,t,r,n,o){return"unexpected character: ->"+e.charAt(t)+"<- at offset: "+t+", skipped "+r+" characters."}}},function(e,t,r){"use strict";r.r(t),r.d(t,"first",(function(){return i})),r.d(t,"firstForSequence",(function(){return a})),r.d(t,"firstForBranching",(function(){return u})),r.d(t,"firstForTerminal",(function(){return c}));var n=r(88),o=r(91),s=r(101);function i(e){if(e instanceof o.NonTerminal)return i(e.referencedRule);if(e instanceof o.Terminal)return c(e);if(Object(s.isSequenceProd)(e))return a(e);if(Object(s.isBranchingProd)(e))return u(e);throw Error("non exhaustive match")}function a(e){for(var t,r=[],o=e.definition,a=0,u=o.length>a,c=!0;u&&c;)t=o[a],c=Object(s.isOptionalProd)(t),r=r.concat(i(t)),a+=1,u=o.length>a;return Object(n.uniq)(r)}function u(e){var t=Object(n.map)(e.definition,(function(e){return i(e)}));return Object(n.uniq)(Object(n.flatten)(t))}function c(e){return[e.terminalType]}},function(e,t,r){"use strict";r.r(t),r.d(t,"isSequenceProd",(function(){return u})),r.d(t,"isOptionalProd",(function(){return c})),r.d(t,"isBranchingProd",(function(){return l})),r.d(t,"getProductionDslName",(function(){return h})),r.d(t,"DslMethodsCollectorVisitor",(function(){return d})),r.d(t,"collectMethods",(function(){return m}));var n,o=r(88),s=r(91),i=r(102),a=(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});function u(e){return e instanceof s.Flat||e instanceof s.Option||e instanceof s.Repetition||e instanceof s.RepetitionMandatory||e instanceof s.RepetitionMandatoryWithSeparator||e instanceof s.RepetitionWithSeparator||e instanceof s.Terminal||e instanceof s.Rule}function c(e,t){return void 0===t&&(t=[]),!!(e instanceof s.Option||e instanceof s.Repetition||e instanceof s.RepetitionWithSeparator)||(e instanceof s.Alternation?Object(o.some)(e.definition,(function(e){return c(e,t)})):!(e instanceof s.NonTerminal&&Object(o.contains)(t,e))&&e instanceof s.AbstractProduction&&(e instanceof s.NonTerminal&&t.push(e),Object(o.every)(e.definition,(function(e){return c(e,t)}))))}function l(e){return e instanceof s.Alternation}function h(e){if(e instanceof s.NonTerminal)return"SUBRULE";if(e instanceof s.Option)return"OPTION";if(e instanceof s.Alternation)return"OR";if(e instanceof s.RepetitionMandatory)return"AT_LEAST_ONE";if(e instanceof s.RepetitionMandatoryWithSeparator)return"AT_LEAST_ONE_SEP";if(e instanceof s.RepetitionWithSeparator)return"MANY_SEP";if(e instanceof s.Repetition)return"MANY";if(e instanceof s.Terminal)return"CONSUME";throw Error("non exhaustive match")}var d=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.separator="-",t.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]},t}return a(t,e),t.prototype.reset=function(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}},t.prototype.visitTerminal=function(e){var t=e.terminalType.name+this.separator+"Terminal";Object(o.has)(this.dslMethods,t)||(this.dslMethods[t]=[]),this.dslMethods[t].push(e)},t.prototype.visitNonTerminal=function(e){var t=e.nonTerminalName+this.separator+"Terminal";Object(o.has)(this.dslMethods,t)||(this.dslMethods[t]=[]),this.dslMethods[t].push(e)},t.prototype.visitOption=function(e){this.dslMethods.option.push(e)},t.prototype.visitRepetitionWithSeparator=function(e){this.dslMethods.repetitionWithSeparator.push(e)},t.prototype.visitRepetitionMandatory=function(e){this.dslMethods.repetitionMandatory.push(e)},t.prototype.visitRepetitionMandatoryWithSeparator=function(e){this.dslMethods.repetitionMandatoryWithSeparator.push(e)},t.prototype.visitRepetition=function(e){this.dslMethods.repetition.push(e)},t.prototype.visitAlternation=function(e){this.dslMethods.alternation.push(e)},t}(i.GAstVisitor),p=new d;function m(e){p.reset(),e.accept(p);var t=p.dslMethods;return p.reset(),t}},function(e,t,r){"use strict";r.r(t),r.d(t,"GAstVisitor",(function(){return o}));var n=r(91),o=function(){function e(){}return e.prototype.visit=function(e){var t=e;switch(t.constructor){case n.NonTerminal:return this.visitNonTerminal(t);case n.Flat:return this.visitFlat(t);case n.Option:return this.visitOption(t);case n.RepetitionMandatory:return this.visitRepetitionMandatory(t);case n.RepetitionMandatoryWithSeparator:return this.visitRepetitionMandatoryWithSeparator(t);case n.RepetitionWithSeparator:return this.visitRepetitionWithSeparator(t);case n.Repetition:return this.visitRepetition(t);case n.Alternation:return this.visitAlternation(t);case n.Terminal:return this.visitTerminal(t);case n.Rule:return this.visitRule(t);default:throw Error("non exhaustive match")}},e.prototype.visitNonTerminal=function(e){},e.prototype.visitFlat=function(e){},e.prototype.visitOption=function(e){},e.prototype.visitRepetition=function(e){},e.prototype.visitRepetitionMandatory=function(e){},e.prototype.visitRepetitionMandatoryWithSeparator=function(e){},e.prototype.visitRepetitionWithSeparator=function(e){},e.prototype.visitAlternation=function(e){},e.prototype.visitTerminal=function(e){},e.prototype.visitRule=function(e){},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"IN",(function(){return n}));var n="_~IN~_"},function(e,t,r){"use strict";r.r(t),r.d(t,"setNodeLocationOnlyOffset",(function(){return c})),r.d(t,"setNodeLocationFull",(function(){return l})),r.d(t,"addTerminalToCst",(function(){return h})),r.d(t,"addNoneTerminalToCst",(function(){return d})),r.d(t,"NamedDSLMethodsCollectorVisitor",(function(){return p})),r.d(t,"expandAllNestedRuleNames",(function(){return m}));var n,o=r(88),s=r(105),i=r(91),a=r(102),u=(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});function c(e,t){!0===isNaN(e.startOffset)?(e.startOffset=t.startOffset,e.endOffset=t.endOffset):e.endOffset1;Object(o.forEach)(e.definition,(function(n,a){if(!Object(o.isUndefined)(n.name)){var u=n.definition;u=r?[new i.Option({definition:n.definition})]:n.definition;var c=Object(s.getKeyForAltIndex)(t.ruleIdx,s.OR_IDX,e.idx,a);t.result.push({def:u,key:c,name:n.name,orgProd:n})}}))},t}(a.GAstVisitor);function m(e,t){var r={allRuleNames:[]};return Object(o.forEach)(e,(function(e){var n=t[e.name];r.allRuleNames.push(e.name);var s=new p(n);e.accept(s),Object(o.forEach)(s.result,(function(t){t.def,t.key;var n=t.name;r.allRuleNames.push(e.name+n)}))})),r}},function(e,t,r){"use strict";r.r(t),r.d(t,"BITS_FOR_METHOD_TYPE",(function(){return n})),r.d(t,"BITS_FOR_OCCURRENCE_IDX",(function(){return o})),r.d(t,"BITS_FOR_RULE_IDX",(function(){return s})),r.d(t,"BITS_FOR_ALT_IDX",(function(){return i})),r.d(t,"OR_IDX",(function(){return a})),r.d(t,"OPTION_IDX",(function(){return u})),r.d(t,"MANY_IDX",(function(){return c})),r.d(t,"AT_LEAST_ONE_IDX",(function(){return l})),r.d(t,"MANY_SEP_IDX",(function(){return h})),r.d(t,"AT_LEAST_ONE_SEP_IDX",(function(){return d})),r.d(t,"getKeyForAutomaticLookahead",(function(){return p})),r.d(t,"getKeyForAltIndex",(function(){return g}));var n=4,o=8,s=12,i=8,a=1<"+i}};Object.freeze(u);var c={buildRuleNotFoundError:function(e,t){return"Invalid grammar, reference to a rule which is not defined: ->"+t.nonTerminalName+"<-\ninside top level rule: ->"+e.name+"<-"}},l={buildDuplicateFoundError:function(e,t){var r,n=e.name,a=Object(o.first)(t),u=a.idx,c=Object(i.getProductionDslName)(a),l=(r=a)instanceof s.Terminal?r.terminalType.name:r instanceof s.NonTerminal?r.nonTerminalName:"",h="->"+c+(u>0?u:"")+"<- "+(l?"with argument: ->"+l+"<-":"")+"\n appears more than once ("+t.length+" times) in the top level rule: ->"+n+"<-. \n For further details see: https://sap.github.io/chevrotain/docs/FAQ.html#NUMERICAL_SUFFIXES \n ";return h=(h=h.replace(/[ \t]+/g," ")).replace(/\s\s+/g,"\n")},buildInvalidNestedRuleNameError:function(e,t){return"Invalid nested rule name: ->"+t.name+"<- inside rule: ->"+e.name+"<-\nit must match the pattern: ->"+a.validNestedRuleName.toString()+"<-.\nNote that this means a nested rule name must start with the '$'(dollar) sign."},buildDuplicateNestedRuleNameError:function(e,t){return"Duplicate nested rule name: ->"+Object(o.first)(t).name+"<- inside rule: ->"+e.name+"<-\nA nested name must be unique in the scope of a top level grammar rule."},buildNamespaceConflictError:function(e){return"Namespace conflict found in grammar.\nThe grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <"+e.name+">.\nTo resolve this make sure each Terminal and Non-Terminal names are unique\nThis is easy to accomplish by using the convention that Terminal names start with an uppercase letter\nand Non-Terminal names start with a lower case letter."},buildAlternationPrefixAmbiguityError:function(e){var t=Object(o.map)(e.prefixPath,(function(e){return Object(n.tokenLabel)(e)})).join(", "),r=0===e.alternation.idx?"":e.alternation.idx;return"Ambiguous alternatives: <"+e.ambiguityIndices.join(" ,")+"> due to common lookahead prefix\nin inside <"+e.topLevelRule.name+"> Rule,\n<"+t+"> may appears as a prefix path in all these alternatives.\nSee: https://sap.github.io/chevrotain/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX\nFor Further details."},buildAlternationAmbiguityError:function(e){var t=Object(o.map)(e.prefixPath,(function(e){return Object(n.tokenLabel)(e)})).join(", "),r=0===e.alternation.idx?"":e.alternation.idx,s="Ambiguous Alternatives Detected: <"+e.ambiguityIndices.join(" ,")+"> in inside <"+e.topLevelRule.name+"> Rule,\n<"+t+"> may appears as a prefix path in all these alternatives.\n";return s+="See: https://sap.github.io/chevrotain/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES\nFor Further details."},buildEmptyRepetitionError:function(e){var t=Object(i.getProductionDslName)(e.repetition);return 0!==e.repetition.idx&&(t+=e.repetition.idx),"The repetition <"+t+"> within Rule <"+e.topLevelRule.name+"> can never consume any tokens.\nThis could lead to an infinite loop."},buildTokenNameError:function(e){return"Invalid Grammar Token name: ->"+e.tokenType.name+"<- it must match the pattern: ->"+e.expectedPattern.toString()+"<-"},buildEmptyAlternationError:function(e){return"Ambiguous empty alternative: <"+(e.emptyChoiceIdx+1)+"> in inside <"+e.topLevelRule.name+"> Rule.\nOnly the last alternative may be an empty alternative."},buildTooManyAlternativesError:function(e){return"An Alternation cannot have more than 256 alternatives:\n inside <"+e.topLevelRule.name+"> Rule.\n has "+(e.alternation.definition.length+1)+" alternatives."},buildLeftRecursionError:function(e){var t=e.topLevelRule.name;return"Left Recursion found in grammar.\nrule: <"+t+"> can be invoked from itself (directly or indirectly)\nwithout consuming any Tokens. The grammar path that causes this is: \n "+t+" --\x3e "+o.map(e.leftRecursionPath,(function(e){return e.name})).concat([t]).join(" --\x3e ")+"\n To fix this refactor your grammar to remove the left recursion.\nsee: https://en.wikipedia.org/wiki/LL_parser#Left_Factoring."},buildInvalidRuleNameError:function(e){return"Invalid grammar rule name: ->"+e.topLevelRule.name+"<- it must match the pattern: ->"+e.expectedPattern.toString()+"<-"},buildDuplicateRuleNameError:function(e){return"Duplicate definition, rule: ->"+(e.topLevelRule instanceof s.Rule?e.topLevelRule.name:e.topLevelRule)+"<- is already defined in the grammar: ->"+e.grammarName+"<-"}}},function(e,t,r){"use strict";r.r(t),r.d(t,"validateGrammar",(function(){return p})),r.d(t,"identifyProductionForDuplicates",(function(){return m})),r.d(t,"OccurrenceValidationCollector",(function(){return f})),r.d(t,"validTermsPattern",(function(){return E})),r.d(t,"validNestedRuleName",(function(){return T})),r.d(t,"validateRuleName",(function(){return y})),r.d(t,"validateNestedRuleName",(function(){return A})),r.d(t,"validateTokenName",(function(){return R})),r.d(t,"validateRuleDoesNotAlreadyExist",(function(){return N})),r.d(t,"validateRuleIsOverridden",(function(){return S})),r.d(t,"validateNoLeftRecursion",(function(){return C})),r.d(t,"getFirstNoneTerminal",(function(){return v})),r.d(t,"validateEmptyOrAlternative",(function(){return I})),r.d(t,"validateAmbiguousAlternationAlternatives",(function(){return M})),r.d(t,"RepetionCollector",(function(){return F})),r.d(t,"validateTooManyAlts",(function(){return b})),r.d(t,"validateSomeNonEmptyLookaheadPath",(function(){return w})),r.d(t,"checkPrefixAlternativesAmbiguities",(function(){return _}));var n,o=r(88),s=r(87),i=r(101),a=r(108),u=r(104),c=r(109),l=r(91),h=r(102),d=(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});function p(e,t,r,n,a,c){var l=o.map(e,(function(e){return function(e,t){var r=new f;e.accept(r);var n=r.allProductions,a=o.groupBy(n,m),u=o.pick(a,(function(e){return e.length>1}));return o.map(o.values(u),(function(r){var n=o.first(r),a=t.buildDuplicateFoundError(e,r),u=Object(i.getProductionDslName)(n),c={message:a,type:s.ParserDefinitionErrorType.DUPLICATE_PRODUCTIONS,ruleName:e.name,dslName:u,occurrence:n.idx},l=g(n);return l&&(c.parameter=l),c}))}(e,a)})),h=o.map(e,(function(e){return C(e,e,a)})),d=[],p=[],E=[];Object(o.every)(h,o.isEmpty)&&(d=Object(o.map)(e,(function(e){return I(e,a)})),p=Object(o.map)(e,(function(e){return M(e,t,n,a)})),E=w(e,t,a));var T=function(e,t,r){var n=[],i=Object(o.map)(t,(function(e){return e.name}));return Object(o.forEach)(e,(function(e){var t=e.name;if(Object(o.contains)(i,t)){var a=r.buildNamespaceConflictError(e);n.push({message:a,type:s.ParserDefinitionErrorType.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:t})}})),n}(e,r,a),S=o.map(r,(function(e){return R(e,a)})),v=function(e,t){var r=[];return Object(o.forEach)(e,(function(e){var n=new u.NamedDSLMethodsCollectorVisitor("");e.accept(n);var s=Object(o.map)(n.result,(function(e){return e.orgProd}));r.push(Object(o.map)(s,(function(r){return A(e,r,t)})))})),Object(o.flatten)(r)}(e,a),O=function(e,t){var r=[];return Object(o.forEach)(e,(function(e){var n=new u.NamedDSLMethodsCollectorVisitor("");e.accept(n);var i=Object(o.groupBy)(n.result,(function(e){return e.name})),a=Object(o.pick)(i,(function(e){return e.length>1}));Object(o.forEach)(Object(o.values)(a),(function(n){var i=Object(o.map)(n,(function(e){return e.orgProd})),a=t.buildDuplicateNestedRuleNameError(e,i);r.push({message:a,type:s.ParserDefinitionErrorType.DUPLICATE_NESTED_NAME,ruleName:e.name})}))})),r}(e,a),F=Object(o.map)(e,(function(e){return b(e,a)})),_=Object(o.map)(e,(function(e){return y(e,a)})),L=Object(o.map)(e,(function(t){return N(t,e,c,a)}));return o.flatten(l.concat(S,v,O,E,h,d,p,T,F,_,L))}function m(e){return Object(i.getProductionDslName)(e)+"_#_"+e.idx+"_#_"+g(e)}function g(e){return e instanceof l.Terminal?e.terminalType.name:e instanceof l.NonTerminal?e.nonTerminalName:""}var f=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.allProductions=[],t}return d(t,e),t.prototype.visitNonTerminal=function(e){this.allProductions.push(e)},t.prototype.visitOption=function(e){this.allProductions.push(e)},t.prototype.visitRepetitionWithSeparator=function(e){this.allProductions.push(e)},t.prototype.visitRepetitionMandatory=function(e){this.allProductions.push(e)},t.prototype.visitRepetitionMandatoryWithSeparator=function(e){this.allProductions.push(e)},t.prototype.visitRepetition=function(e){this.allProductions.push(e)},t.prototype.visitAlternation=function(e){this.allProductions.push(e)},t.prototype.visitTerminal=function(e){this.allProductions.push(e)},t}(h.GAstVisitor),E=/^[a-zA-Z_]\w*$/,T=new RegExp(E.source.replace("^","^\\$"));function y(e,t){var r=[],n=e.name;return n.match(E)||r.push({message:t.buildInvalidRuleNameError({topLevelRule:e,expectedPattern:E}),type:s.ParserDefinitionErrorType.INVALID_RULE_NAME,ruleName:n}),r}function A(e,t,r){var n,o=[];return t.name.match(T)||(n=r.buildInvalidNestedRuleNameError(e,t),o.push({message:n,type:s.ParserDefinitionErrorType.INVALID_NESTED_RULE_NAME,ruleName:e.name})),o}function R(e,t){var r=[];return e.name.match(E)||r.push({message:t.buildTokenNameError({tokenType:e,expectedPattern:E}),type:s.ParserDefinitionErrorType.INVALID_TOKEN_NAME}),r}function N(e,t,r,n){var i=[];if(Object(o.reduce)(t,(function(t,r){return r.name===e.name?t+1:t}),0)>1){var a=n.buildDuplicateRuleNameError({topLevelRule:e,grammarName:r});i.push({message:a,type:s.ParserDefinitionErrorType.DUPLICATE_RULE_NAME,ruleName:e.name})}return i}function S(e,t,r){var n,i=[];return o.contains(t,e)||(n="Invalid rule override, rule: ->"+e+"<- cannot be overridden in the grammar: ->"+r+"<-as it is not defined in any of the super grammars ",i.push({message:n,type:s.ParserDefinitionErrorType.INVALID_RULE_OVERRIDE,ruleName:e})),i}function C(e,t,r,n){void 0===n&&(n=[]);var i=[],a=v(t.definition);if(o.isEmpty(a))return[];var u=e.name;o.contains(a,e)&&i.push({message:r.buildLeftRecursionError({topLevelRule:e,leftRecursionPath:n}),type:s.ParserDefinitionErrorType.LEFT_RECURSION,ruleName:u});var c=o.difference(a,n.concat([e])),l=o.map(c,(function(t){var s=o.cloneArr(n);return s.push(t),C(e,t,r,s)}));return i.concat(o.flatten(l))}function v(e){var t=[];if(o.isEmpty(e))return t;var r=o.first(e);if(r instanceof l.NonTerminal)t.push(r.referencedRule);else if(r instanceof l.Flat||r instanceof l.Option||r instanceof l.RepetitionMandatory||r instanceof l.RepetitionMandatoryWithSeparator||r instanceof l.RepetitionWithSeparator||r instanceof l.Repetition)t=t.concat(v(r.definition));else if(r instanceof l.Alternation)t=o.flatten(o.map(r.definition,(function(e){return v(e.definition)})));else if(!(r instanceof l.Terminal))throw Error("non exhaustive match");var n=Object(i.isOptionalProd)(r),s=e.length>1;if(n&&s){var a=o.drop(e);return t.concat(v(a))}return t}var O=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.alternations=[],t}return d(t,e),t.prototype.visitAlternation=function(e){this.alternations.push(e)},t}(h.GAstVisitor);function I(e,t){var r=new O;e.accept(r);var n=r.alternations;return o.reduce(n,(function(r,n){var i=o.dropRight(n.definition),a=o.map(i,(function(r,i){var a=Object(c.nextPossibleTokensAfter)([r],[],null,1);return o.isEmpty(a)?{message:t.buildEmptyAlternationError({topLevelRule:e,alternation:n,emptyChoiceIdx:i}),type:s.ParserDefinitionErrorType.NONE_LAST_EMPTY_ALT,ruleName:e.name,occurrence:n.idx,alternative:i+1}:null}));return r.concat(o.compact(a))}),[])}function M(e,t,r,n){var u=new O;e.accept(u);var c=u.alternations,l=r[e.name];return l&&(c=Object(o.reject)(c,(function(e){return l[Object(i.getProductionDslName)(e)+(0===e.idx?"":e.idx)]}))),c=Object(o.reject)(c,(function(e){return!0===e.ignoreAmbiguities})),o.reduce(c,(function(r,i){var u=i.idx,c=i.maxLookahead||t,l=Object(a.getLookaheadPathsForOr)(u,e,c,i),h=function(e,t,r,n){var i=[],u=Object(o.reduce)(e,(function(r,n,s){return!0===t.definition[s].ignoreAmbiguities||Object(o.forEach)(n,(function(n){var u=[s];Object(o.forEach)(e,(function(e,r){s!==r&&Object(a.containsPath)(e,n)&&!0!==t.definition[r].ignoreAmbiguities&&u.push(r)})),u.length>1&&!Object(a.containsPath)(i,n)&&(i.push(n),r.push({alts:u,path:n}))})),r}),[]);return o.map(u,(function(e){var i=Object(o.map)(e.alts,(function(e){return e+1}));return{message:n.buildAlternationAmbiguityError({topLevelRule:r,alternation:t,ambiguityIndices:i,prefixPath:e.path}),type:s.ParserDefinitionErrorType.AMBIGUOUS_ALTS,ruleName:r.name,occurrence:t.idx,alternatives:[e.alts]}}))}(l,i,e,n),d=_(l,i,e,n);return r.concat(h,d)}),[])}var F=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.allProductions=[],t}return d(t,e),t.prototype.visitRepetitionWithSeparator=function(e){this.allProductions.push(e)},t.prototype.visitRepetitionMandatory=function(e){this.allProductions.push(e)},t.prototype.visitRepetitionMandatoryWithSeparator=function(e){this.allProductions.push(e)},t.prototype.visitRepetition=function(e){this.allProductions.push(e)},t}(h.GAstVisitor);function b(e,t){var r=new O;e.accept(r);var n=r.alternations;return o.reduce(n,(function(r,n){return n.definition.length>255&&r.push({message:t.buildTooManyAlternativesError({topLevelRule:e,alternation:n}),type:s.ParserDefinitionErrorType.TOO_MANY_ALTS,ruleName:e.name,occurrence:n.idx}),r}),[])}function w(e,t,r){var n=[];return Object(o.forEach)(e,(function(e){var i=new F;e.accept(i);var u=i.allProductions;Object(o.forEach)(u,(function(i){var u=Object(a.getProdType)(i),c=i.maxLookahead||t,l=i.idx,h=Object(a.getLookaheadPathsForOptionalProd)(l,e,u,c)[0];if(Object(o.isEmpty)(Object(o.flatten)(h))){var d=r.buildEmptyRepetitionError({topLevelRule:e,repetition:i});n.push({message:d,type:s.ParserDefinitionErrorType.NO_NON_EMPTY_LOOKAHEAD,ruleName:e.name})}}))})),n}function _(e,t,r,n){var i=[],u=Object(o.reduce)(e,(function(e,t,r){var n=Object(o.map)(t,(function(e){return{idx:r,path:e}}));return e.concat(n)}),[]);return Object(o.forEach)(u,(function(e){if(!0!==t.definition[e.idx].ignoreAmbiguities){var c=e.idx,l=e.path,h=Object(o.findAll)(u,(function(e){return!0!==t.definition[e.idx].ignoreAmbiguities&&e.idx=0;M--){var F={idx:m,def:E.definition[M].definition.concat(Object(s.drop)(p)),ruleStack:g,occurrenceStack:f};h.push(F),h.push("EXIT_ALTERNATIVE")}else if(E instanceof a.Flat)h.push({idx:m,def:E.definition.concat(Object(s.drop)(p)),ruleStack:g,occurrenceStack:f});else{if(!(E instanceof a.Rule))throw Error("non exhaustive match");h.push(T(E,m,g,f))}}}else i&&Object(s.last)(h).idx<=c&&h.pop()}return l}function T(e,t,r,n){var o=Object(s.cloneArr)(r);o.push(e.name);var i=Object(s.cloneArr)(n);return i.push(1),{idx:t,def:e.definition,ruleStack:o,occurrenceStack:i}}},function(e,t,r){"use strict";r.r(t),r.d(t,"resolveGrammar",(function(){return u})),r.d(t,"validateGrammar",(function(){return c})),r.d(t,"assignOccurrenceIndices",(function(){return l}));var n=r(88),o=r(111),s=r(107),i=r(106),a=r(101);function u(e){e=Object(n.defaults)(e,{errMsgProvider:i.defaultGrammarResolverErrorProvider});var t={};return Object(n.forEach)(e.rules,(function(e){t[e.name]=e})),Object(o.resolveGrammar)(t,e.errMsgProvider)}function c(e){return e=Object(n.defaults)(e,{errMsgProvider:i.defaultGrammarValidatorErrorProvider,ignoredIssues:{}}),Object(s.validateGrammar)(e.rules,e.maxLookahead,e.tokenTypes,e.ignoredIssues,e.errMsgProvider,e.grammarName)}function l(e){Object(n.forEach)(e.rules,(function(e){var t=new a.DslMethodsCollectorVisitor;e.accept(t),Object(n.forEach)(t.dslMethods,(function(e){Object(n.forEach)(e,(function(e,t){e.idx=t+1}))}))}))}},function(e,t,r){"use strict";r.r(t),r.d(t,"resolveGrammar",(function(){return u})),r.d(t,"GastRefResolverVisitor",(function(){return c}));var n,o=r(87),s=r(88),i=r(102),a=(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});function u(e,t){var r=new c(e,t);return r.resolveRefs(),r.errors}var c=function(e){function t(t,r){var n=e.call(this)||this;return n.nameToTopRule=t,n.errMsgProvider=r,n.errors=[],n}return a(t,e),t.prototype.resolveRefs=function(){var e=this;Object(s.forEach)(Object(s.values)(this.nameToTopRule),(function(t){e.currTopLevel=t,t.accept(e)}))},t.prototype.visitNonTerminal=function(e){var t=this.nameToTopRule[e.nonTerminalName];if(t)e.referencedRule=t;else{var r=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,e);this.errors.push({message:r,type:o.ParserDefinitionErrorType.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:e.nonTerminalName})}},t}(i.GAstVisitor)},function(e,t,r){"use strict";r.r(t),r.d(t,"EOF_FOLLOW_KEY",(function(){return u})),r.d(t,"IN_RULE_RECOVERY_EXCEPTION",(function(){return c})),r.d(t,"InRuleRecoveryException",(function(){return l})),r.d(t,"Recoverable",(function(){return h})),r.d(t,"attemptInRepetitionRecovery",(function(){return d}));var n=r(92),o=r(88),s=r(113),i=r(103),a=r(87),u={},c="InRuleRecoveryException";function l(e){this.name=c,this.message=e}l.prototype=Error.prototype;var h=function(){function e(){}return e.prototype.initRecoverable=function(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=Object(o.has)(e,"recoveryEnabled")?e.recoveryEnabled:a.DEFAULT_PARSER_CONFIG.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=d)},e.prototype.getTokenToInsert=function(e){var t=Object(n.createTokenInstance)(e,"",NaN,NaN,NaN,NaN,NaN,NaN);return t.isInsertedInRecovery=!0,t},e.prototype.canTokenTypeBeInsertedInRecovery=function(e){return!0},e.prototype.tryInRepetitionRecovery=function(e,t,r,n){for(var i=this,a=this.findReSyncTokenType(),u=this.exportLexerState(),c=[],l=!1,h=this.LA(1),d=this.LA(1),p=function(){var e=i.LA(0),t=i.errorMessageProvider.buildMismatchTokenMessage({expected:n,actual:h,previous:e,ruleName:i.getCurrRuleFullName()}),r=new s.MismatchedTokenException(t,h,i.LA(0));r.resyncedTokens=Object(o.dropRight)(c),i.SAVE_ERROR(r)};!l;){if(this.tokenMatcher(d,n))return void p();if(r.call(this))return p(),void e.apply(this,t);this.tokenMatcher(d,a)?l=!0:(d=this.SKIP_TOKEN(),this.addToResyncTokens(d,c))}this.importLexerState(u)},e.prototype.shouldInRepetitionRecoveryBeTried=function(e,t,r){return!1!==r&&void 0!==e&&void 0!==t&&!this.tokenMatcher(this.LA(1),e)&&!this.isBackTracking()&&!this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,t))},e.prototype.getFollowsForInRuleRecovery=function(e,t){var r=this.getCurrentGrammarPath(e,t);return this.getNextPossibleTokenTypes(r)},e.prototype.tryInRuleRecovery=function(e,t){if(this.canRecoverWithSingleTokenInsertion(e,t))return this.getTokenToInsert(e);if(this.canRecoverWithSingleTokenDeletion(e)){var r=this.SKIP_TOKEN();return this.consumeToken(),r}throw new l("sad sad panda")},e.prototype.canPerformInRuleRecovery=function(e,t){return this.canRecoverWithSingleTokenInsertion(e,t)||this.canRecoverWithSingleTokenDeletion(e)},e.prototype.canRecoverWithSingleTokenInsertion=function(e,t){var r=this;if(!this.canTokenTypeBeInsertedInRecovery(e))return!1;if(Object(o.isEmpty)(t))return!1;var n=this.LA(1);return void 0!==Object(o.find)(t,(function(e){return r.tokenMatcher(n,e)}))},e.prototype.canRecoverWithSingleTokenDeletion=function(e){return this.tokenMatcher(this.LA(2),e)},e.prototype.isInCurrentRuleReSyncSet=function(e){var t=this.getCurrFollowKey(),r=this.getFollowSetFromFollowKey(t);return Object(o.contains)(r,e)},e.prototype.findReSyncTokenType=function(){for(var e=this.flattenFollowSet(),t=this.LA(1),r=2;;){var n=t.tokenType;if(Object(o.contains)(e,n))return n;t=this.LA(r),r++}},e.prototype.getCurrFollowKey=function(){if(1===this.RULE_STACK.length)return u;var e=this.getLastExplicitRuleShortName(),t=this.getLastExplicitRuleOccurrenceIndex(),r=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:t,inRule:this.shortRuleNameToFullName(r)}},e.prototype.buildFullFollowKeyStack=function(){var e=this,t=this.RULE_STACK,r=this.RULE_OCCURRENCE_STACK;return Object(o.isEmpty)(this.LAST_EXPLICIT_RULE_STACK)||(t=Object(o.map)(this.LAST_EXPLICIT_RULE_STACK,(function(t){return e.RULE_STACK[t]})),r=Object(o.map)(this.LAST_EXPLICIT_RULE_STACK,(function(t){return e.RULE_OCCURRENCE_STACK[t]}))),Object(o.map)(t,(function(n,o){return 0===o?u:{ruleName:e.shortRuleNameToFullName(n),idxInCallingRule:r[o],inRule:e.shortRuleNameToFullName(t[o-1])}}))},e.prototype.flattenFollowSet=function(){var e=this,t=Object(o.map)(this.buildFullFollowKeyStack(),(function(t){return e.getFollowSetFromFollowKey(t)}));return Object(o.flatten)(t)},e.prototype.getFollowSetFromFollowKey=function(e){if(e===u)return[n.EOF];var t=e.ruleName+e.idxInCallingRule+i.IN+e.inRule;return this.resyncFollows[t]},e.prototype.addToResyncTokens=function(e,t){return this.tokenMatcher(e,n.EOF)||t.push(e),t},e.prototype.reSyncTo=function(e){for(var t=[],r=this.LA(1);!1===this.tokenMatcher(r,e);)r=this.SKIP_TOKEN(),this.addToResyncTokens(r,t);return Object(o.dropRight)(t)},e.prototype.attemptInRepetitionRecovery=function(e,t,r,n,o,s,i){},e.prototype.getCurrentGrammarPath=function(e,t){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:Object(o.cloneArr)(this.RULE_OCCURRENCE_STACK),lastTok:e,lastTokOccurrence:t}},e.prototype.getHumanReadableRuleStack=function(){var e=this;return Object(o.isEmpty)(this.LAST_EXPLICIT_RULE_STACK)?Object(o.map)(this.RULE_STACK,(function(t){return e.shortRuleNameToFullName(t)})):Object(o.map)(this.LAST_EXPLICIT_RULE_STACK,(function(t){return e.shortRuleNameToFullName(e.RULE_STACK[t])}))},e}();function d(e,t,r,o,s,i,a){var u=this.getKeyForAutomaticLookahead(o,s),c=this.firstAfterRepMap[u];if(void 0===c){var l=this.getCurrRuleFullName();c=new i(this.getGAstProductions()[l],s).startWalking(),this.firstAfterRepMap[u]=c}var h=c.token,d=c.occurrence,p=c.isEndOfRule;1===this.RULE_STACK.length&&p&&void 0===h&&(h=n.EOF,d=1),this.shouldInRepetitionRecoveryBeTried(h,d,a)&&this.tryInRepetitionRecovery(e,t,r,h)}},function(e,t,r){"use strict";r.r(t),r.d(t,"isRecognitionException",(function(){return s})),r.d(t,"MismatchedTokenException",(function(){return i})),r.d(t,"NoViableAltException",(function(){return a})),r.d(t,"NotAllInputParsedException",(function(){return u})),r.d(t,"EarlyExitException",(function(){return c}));var n=r(88),o=["MismatchedTokenException","NoViableAltException","EarlyExitException","NotAllInputParsedException"];function s(e){return Object(n.contains)(o,e.name)}function i(e,t,r){this.name="MismatchedTokenException",this.message=e,this.token=t,this.previousToken=r,this.resyncedTokens=[]}function a(e,t,r){this.name="NoViableAltException",this.message=e,this.token=t,this.previousToken=r,this.resyncedTokens=[]}function u(e,t){this.name="NotAllInputParsedException",this.message=e,this.token=t,this.resyncedTokens=[]}function c(e,t,r){this.name="EarlyExitException",this.message=e,this.token=t,this.previousToken=r,this.resyncedTokens=[]}Object.freeze(o),i.prototype=Error.prototype,a.prototype=Error.prototype,u.prototype=Error.prototype,c.prototype=Error.prototype},function(e,t,r){"use strict";r.r(t),r.d(t,"LooksAhead",(function(){return u}));var n=r(108),o=r(88),s=r(87),i=r(105),a=r(101),u=function(){function e(){}return e.prototype.initLooksAhead=function(e){this.dynamicTokensEnabled=Object(o.has)(e,"dynamicTokensEnabled")?e.dynamicTokensEnabled:s.DEFAULT_PARSER_CONFIG.dynamicTokensEnabled,this.maxLookahead=Object(o.has)(e,"maxLookahead")?e.maxLookahead:s.DEFAULT_PARSER_CONFIG.maxLookahead,this.lookAheadFuncsCache=Object(o.isES2015MapSupported)()?new Map:[],Object(o.isES2015MapSupported)()?(this.getLaFuncFromCache=this.getLaFuncFromMap,this.setLaFuncCache=this.setLaFuncCacheUsingMap):(this.getLaFuncFromCache=this.getLaFuncFromObj,this.setLaFuncCache=this.setLaFuncUsingObj)},e.prototype.preComputeLookaheadFunctions=function(e){var t=this;Object(o.forEach)(e,(function(e){t.TRACE_INIT(e.name+" Rule Lookahead",(function(){var r=Object(a.collectMethods)(e),s=r.alternation,u=r.repetition,c=r.option,l=r.repetitionMandatory,h=r.repetitionMandatoryWithSeparator,d=r.repetitionWithSeparator;Object(o.forEach)(s,(function(r){var o=0===r.idx?"":r.idx;t.TRACE_INIT(""+Object(a.getProductionDslName)(r)+o,(function(){var o=Object(n.buildLookaheadFuncForOr)(r.idx,e,r.maxLookahead||t.maxLookahead,r.hasPredicates,t.dynamicTokensEnabled,t.lookAheadBuilderForAlternatives),s=Object(i.getKeyForAutomaticLookahead)(t.fullRuleNameToShort[e.name],i.OR_IDX,r.idx);t.setLaFuncCache(s,o)}))})),Object(o.forEach)(u,(function(r){t.computeLookaheadFunc(e,r.idx,i.MANY_IDX,n.PROD_TYPE.REPETITION,r.maxLookahead,Object(a.getProductionDslName)(r))})),Object(o.forEach)(c,(function(r){t.computeLookaheadFunc(e,r.idx,i.OPTION_IDX,n.PROD_TYPE.OPTION,r.maxLookahead,Object(a.getProductionDslName)(r))})),Object(o.forEach)(l,(function(r){t.computeLookaheadFunc(e,r.idx,i.AT_LEAST_ONE_IDX,n.PROD_TYPE.REPETITION_MANDATORY,r.maxLookahead,Object(a.getProductionDslName)(r))})),Object(o.forEach)(h,(function(r){t.computeLookaheadFunc(e,r.idx,i.AT_LEAST_ONE_SEP_IDX,n.PROD_TYPE.REPETITION_MANDATORY_WITH_SEPARATOR,r.maxLookahead,Object(a.getProductionDslName)(r))})),Object(o.forEach)(d,(function(r){t.computeLookaheadFunc(e,r.idx,i.MANY_SEP_IDX,n.PROD_TYPE.REPETITION_WITH_SEPARATOR,r.maxLookahead,Object(a.getProductionDslName)(r))}))}))}))},e.prototype.computeLookaheadFunc=function(e,t,r,o,s,a){var u=this;this.TRACE_INIT(""+a+(0===t?"":t),(function(){var a=Object(n.buildLookaheadFuncForOptionalProd)(t,e,s||u.maxLookahead,u.dynamicTokensEnabled,o,u.lookAheadBuilderForOptional),c=Object(i.getKeyForAutomaticLookahead)(u.fullRuleNameToShort[e.name],r,t);u.setLaFuncCache(c,a)}))},e.prototype.lookAheadBuilderForOptional=function(e,t,r){return Object(n.buildSingleAlternativeLookaheadFunction)(e,t,r)},e.prototype.lookAheadBuilderForAlternatives=function(e,t,r,o){return Object(n.buildAlternativesLookAheadFunc)(e,t,r,o)},e.prototype.getKeyForAutomaticLookahead=function(e,t){var r=this.getLastExplicitRuleShortName();return Object(i.getKeyForAutomaticLookahead)(r,e,t)},e.prototype.getLaFuncFromCache=function(e){},e.prototype.getLaFuncFromMap=function(e){return this.lookAheadFuncsCache.get(e)},e.prototype.getLaFuncFromObj=function(e){return this.lookAheadFuncsCache[e]},e.prototype.setLaFuncCache=function(e,t){},e.prototype.setLaFuncCacheUsingMap=function(e,t){this.lookAheadFuncsCache.set(e,t)},e.prototype.setLaFuncUsingObj=function(e,t){this.lookAheadFuncsCache[e]=t},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"TreeBuilder",(function(){return u}));var n=r(104),o=r(88),s=r(116),i=r(105),a=r(87),u=function(){function e(){}return e.prototype.initTreeBuilder=function(e){if(this.LAST_EXPLICIT_RULE_STACK=[],this.CST_STACK=[],this.outputCst=Object(o.has)(e,"outputCst")?e.outputCst:a.DEFAULT_PARSER_CONFIG.outputCst,this.nodeLocationTracking=Object(o.has)(e,"nodeLocationTracking")?e.nodeLocationTracking:a.DEFAULT_PARSER_CONFIG.nodeLocationTracking,this.outputCst)if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=n.setNodeLocationFull,this.setNodeLocationFromNode=n.setNodeLocationFull,this.cstPostRule=o.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=o.NOOP,this.setNodeLocationFromNode=o.NOOP,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=n.setNodeLocationOnlyOffset,this.setNodeLocationFromNode=n.setNodeLocationOnlyOffset,this.cstPostRule=o.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=o.NOOP,this.setNodeLocationFromNode=o.NOOP,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else{if(!/none/i.test(this.nodeLocationTracking))throw Error('Invalid config option: "'+e.nodeLocationTracking+'"');this.setNodeLocationFromToken=o.NOOP,this.setNodeLocationFromNode=o.NOOP,this.cstPostRule=o.NOOP,this.setInitialNodeLocation=o.NOOP}else this.cstInvocationStateUpdate=o.NOOP,this.cstFinallyStateUpdate=o.NOOP,this.cstPostTerminal=o.NOOP,this.cstPostNonTerminal=o.NOOP,this.cstPostRule=o.NOOP,this.getLastExplicitRuleShortName=this.getLastExplicitRuleShortNameNoCst,this.getPreviousExplicitRuleShortName=this.getPreviousExplicitRuleShortNameNoCst,this.getLastExplicitRuleOccurrenceIndex=this.getLastExplicitRuleOccurrenceIndexNoCst,this.manyInternal=this.manyInternalNoCst,this.orInternal=this.orInternalNoCst,this.optionInternal=this.optionInternalNoCst,this.atLeastOneInternal=this.atLeastOneInternalNoCst,this.manySepFirstInternal=this.manySepFirstInternalNoCst,this.atLeastOneSepFirstInternal=this.atLeastOneSepFirstInternalNoCst},e.prototype.setInitialNodeLocationOnlyOffsetRecovery=function(e){e.location={startOffset:NaN,endOffset:NaN}},e.prototype.setInitialNodeLocationOnlyOffsetRegular=function(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}},e.prototype.setInitialNodeLocationFullRecovery=function(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}},e.prototype.setInitialNodeLocationFullRegular=function(e){var t=this.LA(1);e.location={startOffset:t.startOffset,startLine:t.startLine,startColumn:t.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}},e.prototype.cstNestedInvocationStateUpdate=function(e,t){var r={name:e,fullName:this.shortRuleNameToFull[this.getLastExplicitRuleShortName()]+e,children:{}};this.setInitialNodeLocation(r),this.CST_STACK.push(r)},e.prototype.cstInvocationStateUpdate=function(e,t){this.LAST_EXPLICIT_RULE_STACK.push(this.RULE_STACK.length-1);var r={name:e,children:{}};this.setInitialNodeLocation(r),this.CST_STACK.push(r)},e.prototype.cstFinallyStateUpdate=function(){this.LAST_EXPLICIT_RULE_STACK.pop(),this.CST_STACK.pop()},e.prototype.cstNestedFinallyStateUpdate=function(){var e=this.CST_STACK.pop();this.cstPostRule(e)},e.prototype.cstPostRuleFull=function(e){var t=this.LA(0),r=e.location;r.startOffset<=t.startOffset==1?(r.endOffset=t.endOffset,r.endLine=t.endLine,r.endColumn=t.endColumn):(r.startOffset=NaN,r.startLine=NaN,r.startColumn=NaN)},e.prototype.cstPostRuleOnlyOffset=function(e){var t=this.LA(0),r=e.location;r.startOffset<=t.startOffset==1?r.endOffset=t.endOffset:r.startOffset=NaN},e.prototype.cstPostTerminal=function(e,t){var r=this.CST_STACK[this.CST_STACK.length-1];Object(n.addTerminalToCst)(r,t,e),this.setNodeLocationFromToken(r.location,t)},e.prototype.cstPostNonTerminal=function(e,t){if(!0!==this.isBackTracking()){var r=this.CST_STACK[this.CST_STACK.length-1];Object(n.addNoneTerminalToCst)(r,t,e),this.setNodeLocationFromNode(r.location,e.location)}},e.prototype.getBaseCstVisitorConstructor=function(){if(Object(o.isUndefined)(this.baseCstVisitorConstructor)){var e=Object(s.createBaseSemanticVisitorConstructor)(this.className,this.allRuleNames);return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor},e.prototype.getBaseCstVisitorConstructorWithDefaults=function(){if(Object(o.isUndefined)(this.baseCstVisitorWithDefaultsConstructor)){var e=Object(s.createBaseVisitorConstructorWithDefaults)(this.className,this.allRuleNames,this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor},e.prototype.nestedRuleBeforeClause=function(e,t){var r;return void 0!==e.NAME?(r=e.NAME,this.nestedRuleInvocationStateUpdate(r,t),r):void 0},e.prototype.nestedAltBeforeClause=function(e,t,r,n){var o,s=this.getLastExplicitRuleShortName(),a=Object(i.getKeyForAltIndex)(s,r,t,n);return void 0!==e.NAME?(o=e.NAME,this.nestedRuleInvocationStateUpdate(o,a),{shortName:a,nestedName:o}):void 0},e.prototype.nestedRuleFinallyClause=function(e,t){var r=this.CST_STACK,o=r[r.length-1];this.nestedRuleFinallyStateUpdate();var s=r[r.length-1];Object(n.addNoneTerminalToCst)(s,t,o),this.setNodeLocationFromNode(s.location,o.location)},e.prototype.getLastExplicitRuleShortName=function(){var e=this.LAST_EXPLICIT_RULE_STACK[this.LAST_EXPLICIT_RULE_STACK.length-1];return this.RULE_STACK[e]},e.prototype.getLastExplicitRuleShortNameNoCst=function(){var e=this.RULE_STACK;return e[e.length-1]},e.prototype.getPreviousExplicitRuleShortName=function(){var e=this.LAST_EXPLICIT_RULE_STACK[this.LAST_EXPLICIT_RULE_STACK.length-2];return this.RULE_STACK[e]},e.prototype.getPreviousExplicitRuleShortNameNoCst=function(){var e=this.RULE_STACK;return e[e.length-2]},e.prototype.getLastExplicitRuleOccurrenceIndex=function(){var e=this.LAST_EXPLICIT_RULE_STACK[this.LAST_EXPLICIT_RULE_STACK.length-1];return this.RULE_OCCURRENCE_STACK[e]},e.prototype.getLastExplicitRuleOccurrenceIndexNoCst=function(){var e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]},e.prototype.nestedRuleInvocationStateUpdate=function(e,t){this.RULE_OCCURRENCE_STACK.push(1),this.RULE_STACK.push(t),this.cstNestedInvocationStateUpdate(e,t)},e.prototype.nestedRuleFinallyStateUpdate=function(){this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstNestedFinallyStateUpdate()},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"defaultVisit",(function(){return a})),r.d(t,"createBaseSemanticVisitorConstructor",(function(){return u})),r.d(t,"createBaseVisitorConstructorWithDefaults",(function(){return c})),r.d(t,"CstVisitorDefinitionError",(function(){return n})),r.d(t,"validateVisitor",(function(){return l})),r.d(t,"validateMissingCstMethods",(function(){return h})),r.d(t,"validateRedundantMethods",(function(){return p}));var n,o=r(88),s=r(117),i=r(107);function a(e,t){for(var r=Object(o.keys)(e),n=r.length,s=0;s:\n\t"+r.join("\n\n").replace(/\n/g,"\n\t"))}}}).constructor=r,r._RULE_NAMES=t,r}function c(e,t,r){var n=function(){};Object(s.defineNameProp)(n,e+"BaseSemanticsWithDefaults");var i=Object.create(r.prototype);return Object(o.forEach)(t,(function(e){i[e]=a})),(n.prototype=i).constructor=n,n}function l(e,t){var r=h(e,t),n=p(e,t);return r.concat(n)}function h(e,t){var r=Object(o.map)(t,(function(t){if(!Object(o.isFunction)(e[t]))return{msg:"Missing visitor method: <"+t+"> on "+Object(s.functionName)(e.constructor)+" CST Visitor.",type:n.MISSING_METHOD,methodName:t}}));return Object(o.compact)(r)}!function(e){e[e.REDUNDANT_METHOD=0]="REDUNDANT_METHOD",e[e.MISSING_METHOD=1]="MISSING_METHOD"}(n||(n={}));var d=["constructor","visit","validateVisitor"];function p(e,t){var r=[];for(var a in e)i.validTermsPattern.test(a)&&Object(o.isFunction)(e[a])&&!Object(o.contains)(d,a)&&!Object(o.contains)(t,a)&&r.push({msg:"Redundant visitor method: <"+a+"> on "+Object(s.functionName)(e.constructor)+" CST Visitor\nThere is no Grammar Rule corresponding to this method's name.\nFor utility methods on visitor classes use methods names that do not match /"+i.validTermsPattern.source+"/.",type:n.REDUNDANT_METHOD,methodName:a});return r}},function(e,t,r){"use strict";r.r(t),r.d(t,"classNameFromInstance",(function(){return o})),r.d(t,"functionName",(function(){return i})),r.d(t,"defineNameProp",(function(){return a}));var n=r(88);function o(e){return i(e.constructor)}var s=/^\s*function\s*(\S*)\s*\(/;function i(e){var t=e.name;return t||e.toString().match(s)[1]}function a(e,t){var r=Object.getOwnPropertyDescriptor(e,"name");return!(!Object(n.isUndefined)(r)&&!r.configurable||(Object.defineProperty(e,"name",{enumerable:!1,configurable:!0,writable:!1,value:t}),0))}},function(e,t,r){"use strict";r.r(t),r.d(t,"LexerAdapter",(function(){return o}));var n=r(87),o=function(){function e(){}return e.prototype.initLexerAdapter=function(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1},Object.defineProperty(e.prototype,"input",{get:function(){return this.tokVector},set:function(e){if(!0!==this.selfAnalysisDone)throw Error("Missing invocation at the end of the Parser's constructor.");this.reset(),this.tokVector=e,this.tokVectorLength=e.length},enumerable:!0,configurable:!0}),e.prototype.SKIP_TOKEN=function(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):n.END_OF_FILE},e.prototype.LA=function(e){var t=this.currIdx+e;return t<0||this.tokVectorLength<=t?n.END_OF_FILE:this.tokVector[t]},e.prototype.consumeToken=function(){this.currIdx++},e.prototype.exportLexerState=function(){return this.currIdx},e.prototype.importLexerState=function(e){this.currIdx=e},e.prototype.resetLexerState=function(){this.currIdx=-1},e.prototype.moveToTerminatedState=function(){this.currIdx=this.tokVector.length-1},e.prototype.getLexerPosition=function(){return this.exportLexerState()},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"RecognizerApi",(function(){return c}));var n=r(88),o=r(113),s=r(87),i=r(106),a=r(107),u=r(91),c=function(){function e(){}return e.prototype.ACTION=function(e){return e.call(this)},e.prototype.consume=function(e,t,r){return this.consumeInternal(t,e,r)},e.prototype.subrule=function(e,t,r){return this.subruleInternal(t,e,r)},e.prototype.option=function(e,t){return this.optionInternal(t,e)},e.prototype.or=function(e,t){return this.orInternal(t,e)},e.prototype.many=function(e,t){return this.manyInternal(e,t)},e.prototype.atLeastOne=function(e,t){return this.atLeastOneInternal(e,t)},e.prototype.CONSUME=function(e,t){return this.consumeInternal(e,0,t)},e.prototype.CONSUME1=function(e,t){return this.consumeInternal(e,1,t)},e.prototype.CONSUME2=function(e,t){return this.consumeInternal(e,2,t)},e.prototype.CONSUME3=function(e,t){return this.consumeInternal(e,3,t)},e.prototype.CONSUME4=function(e,t){return this.consumeInternal(e,4,t)},e.prototype.CONSUME5=function(e,t){return this.consumeInternal(e,5,t)},e.prototype.CONSUME6=function(e,t){return this.consumeInternal(e,6,t)},e.prototype.CONSUME7=function(e,t){return this.consumeInternal(e,7,t)},e.prototype.CONSUME8=function(e,t){return this.consumeInternal(e,8,t)},e.prototype.CONSUME9=function(e,t){return this.consumeInternal(e,9,t)},e.prototype.SUBRULE=function(e,t){return this.subruleInternal(e,0,t)},e.prototype.SUBRULE1=function(e,t){return this.subruleInternal(e,1,t)},e.prototype.SUBRULE2=function(e,t){return this.subruleInternal(e,2,t)},e.prototype.SUBRULE3=function(e,t){return this.subruleInternal(e,3,t)},e.prototype.SUBRULE4=function(e,t){return this.subruleInternal(e,4,t)},e.prototype.SUBRULE5=function(e,t){return this.subruleInternal(e,5,t)},e.prototype.SUBRULE6=function(e,t){return this.subruleInternal(e,6,t)},e.prototype.SUBRULE7=function(e,t){return this.subruleInternal(e,7,t)},e.prototype.SUBRULE8=function(e,t){return this.subruleInternal(e,8,t)},e.prototype.SUBRULE9=function(e,t){return this.subruleInternal(e,9,t)},e.prototype.OPTION=function(e){return this.optionInternal(e,0)},e.prototype.OPTION1=function(e){return this.optionInternal(e,1)},e.prototype.OPTION2=function(e){return this.optionInternal(e,2)},e.prototype.OPTION3=function(e){return this.optionInternal(e,3)},e.prototype.OPTION4=function(e){return this.optionInternal(e,4)},e.prototype.OPTION5=function(e){return this.optionInternal(e,5)},e.prototype.OPTION6=function(e){return this.optionInternal(e,6)},e.prototype.OPTION7=function(e){return this.optionInternal(e,7)},e.prototype.OPTION8=function(e){return this.optionInternal(e,8)},e.prototype.OPTION9=function(e){return this.optionInternal(e,9)},e.prototype.OR=function(e){return this.orInternal(e,0)},e.prototype.OR1=function(e){return this.orInternal(e,1)},e.prototype.OR2=function(e){return this.orInternal(e,2)},e.prototype.OR3=function(e){return this.orInternal(e,3)},e.prototype.OR4=function(e){return this.orInternal(e,4)},e.prototype.OR5=function(e){return this.orInternal(e,5)},e.prototype.OR6=function(e){return this.orInternal(e,6)},e.prototype.OR7=function(e){return this.orInternal(e,7)},e.prototype.OR8=function(e){return this.orInternal(e,8)},e.prototype.OR9=function(e){return this.orInternal(e,9)},e.prototype.MANY=function(e){this.manyInternal(0,e)},e.prototype.MANY1=function(e){this.manyInternal(1,e)},e.prototype.MANY2=function(e){this.manyInternal(2,e)},e.prototype.MANY3=function(e){this.manyInternal(3,e)},e.prototype.MANY4=function(e){this.manyInternal(4,e)},e.prototype.MANY5=function(e){this.manyInternal(5,e)},e.prototype.MANY6=function(e){this.manyInternal(6,e)},e.prototype.MANY7=function(e){this.manyInternal(7,e)},e.prototype.MANY8=function(e){this.manyInternal(8,e)},e.prototype.MANY9=function(e){this.manyInternal(9,e)},e.prototype.MANY_SEP=function(e){this.manySepFirstInternal(0,e)},e.prototype.MANY_SEP1=function(e){this.manySepFirstInternal(1,e)},e.prototype.MANY_SEP2=function(e){this.manySepFirstInternal(2,e)},e.prototype.MANY_SEP3=function(e){this.manySepFirstInternal(3,e)},e.prototype.MANY_SEP4=function(e){this.manySepFirstInternal(4,e)},e.prototype.MANY_SEP5=function(e){this.manySepFirstInternal(5,e)},e.prototype.MANY_SEP6=function(e){this.manySepFirstInternal(6,e)},e.prototype.MANY_SEP7=function(e){this.manySepFirstInternal(7,e)},e.prototype.MANY_SEP8=function(e){this.manySepFirstInternal(8,e)},e.prototype.MANY_SEP9=function(e){this.manySepFirstInternal(9,e)},e.prototype.AT_LEAST_ONE=function(e){this.atLeastOneInternal(0,e)},e.prototype.AT_LEAST_ONE1=function(e){return this.atLeastOneInternal(1,e)},e.prototype.AT_LEAST_ONE2=function(e){this.atLeastOneInternal(2,e)},e.prototype.AT_LEAST_ONE3=function(e){this.atLeastOneInternal(3,e)},e.prototype.AT_LEAST_ONE4=function(e){this.atLeastOneInternal(4,e)},e.prototype.AT_LEAST_ONE5=function(e){this.atLeastOneInternal(5,e)},e.prototype.AT_LEAST_ONE6=function(e){this.atLeastOneInternal(6,e)},e.prototype.AT_LEAST_ONE7=function(e){this.atLeastOneInternal(7,e)},e.prototype.AT_LEAST_ONE8=function(e){this.atLeastOneInternal(8,e)},e.prototype.AT_LEAST_ONE9=function(e){this.atLeastOneInternal(9,e)},e.prototype.AT_LEAST_ONE_SEP=function(e){this.atLeastOneSepFirstInternal(0,e)},e.prototype.AT_LEAST_ONE_SEP1=function(e){this.atLeastOneSepFirstInternal(1,e)},e.prototype.AT_LEAST_ONE_SEP2=function(e){this.atLeastOneSepFirstInternal(2,e)},e.prototype.AT_LEAST_ONE_SEP3=function(e){this.atLeastOneSepFirstInternal(3,e)},e.prototype.AT_LEAST_ONE_SEP4=function(e){this.atLeastOneSepFirstInternal(4,e)},e.prototype.AT_LEAST_ONE_SEP5=function(e){this.atLeastOneSepFirstInternal(5,e)},e.prototype.AT_LEAST_ONE_SEP6=function(e){this.atLeastOneSepFirstInternal(6,e)},e.prototype.AT_LEAST_ONE_SEP7=function(e){this.atLeastOneSepFirstInternal(7,e)},e.prototype.AT_LEAST_ONE_SEP8=function(e){this.atLeastOneSepFirstInternal(8,e)},e.prototype.AT_LEAST_ONE_SEP9=function(e){this.atLeastOneSepFirstInternal(9,e)},e.prototype.RULE=function(e,t,r){if(void 0===r&&(r=s.DEFAULT_RULE_CONFIG),Object(n.contains)(this.definedRulesNames,e)){var o={message:i.defaultGrammarValidatorErrorProvider.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),type:s.ParserDefinitionErrorType.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(o)}this.definedRulesNames.push(e);var a=this.defineRule(e,t,r);return this[e]=a,a},e.prototype.OVERRIDE_RULE=function(e,t,r){void 0===r&&(r=s.DEFAULT_RULE_CONFIG);var n=[];n=n.concat(Object(a.validateRuleIsOverridden)(e,this.definedRulesNames,this.className)),this.definitionErrors.push.apply(this.definitionErrors,n);var o=this.defineRule(e,t,r);return this[e]=o,o},e.prototype.BACKTRACK=function(e,t){return function(){this.isBackTrackingStack.push(1);var r=this.saveRecogState();try{return e.apply(this,t),!0}catch(e){if(Object(o.isRecognitionException)(e))return!1;throw e}finally{this.reloadRecogState(r),this.isBackTrackingStack.pop()}}},e.prototype.getGAstProductions=function(){return this.gastProductionsCache},e.prototype.getSerializedGastProductions=function(){return Object(u.serializeGrammar)(Object(n.values)(this.gastProductionsCache))},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"RecognizerEngine",(function(){return p}));var n=r(88),o=r(105),s=r(113),i=r(108),a=r(109),u=r(87),c=r(112),l=r(92),h=r(98),d=r(117),p=function(){function e(){}return e.prototype.initRecognizerEngine=function(e,t){if(this.className=Object(d.classNameFromInstance)(this),this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=h.tokenStructuredMatcherNoCategories,this.definedRulesNames=[],this.tokensMap={},this.allRuleNames=[],this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},Object(n.has)(t,"serializedGrammar"))throw Error("The Parser's configuration can no longer contain a property.\n\tSee: https://sap.github.io/chevrotain/docs/changes/BREAKING_CHANGES.html#_6-0-0\n\tFor Further details.");if(Object(n.isArray)(e)){if(Object(n.isEmpty)(e))throw Error("A Token Vocabulary cannot be empty.\n\tNote that the first argument for the parser constructor\n\tis no longer a Token vector (since v4.0).");if("number"==typeof e[0].startOffset)throw Error("The Parser constructor no longer accepts a token vector as the first argument.\n\tSee: https://sap.github.io/chevrotain/docs/changes/BREAKING_CHANGES.html#_4-0-0\n\tFor Further details.")}if(Object(n.isArray)(e))this.tokensMap=Object(n.reduce)(e,(function(e,t){return e[t.name]=t,e}),{});else if(Object(n.has)(e,"modes")&&Object(n.every)(Object(n.flatten)(Object(n.values)(e.modes)),h.isTokenType)){var r=Object(n.flatten)(Object(n.values)(e.modes)),o=Object(n.uniq)(r);this.tokensMap=Object(n.reduce)(o,(function(e,t){return e[t.name]=t,e}),{})}else{if(!Object(n.isObject)(e))throw new Error(" argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition");this.tokensMap=Object(n.cloneObj)(e)}this.tokensMap.EOF=l.EOF;var s=Object(n.every)(Object(n.values)(e),(function(e){return Object(n.isEmpty)(e.categoryMatches)}));this.tokenMatcher=s?h.tokenStructuredMatcherNoCategories:h.tokenStructuredMatcher,Object(h.augmentTokenTypes)(Object(n.values)(this.tokensMap))},e.prototype.defineRule=function(e,t,r){if(this.selfAnalysisDone)throw Error("Grammar rule <"+e+"> may not be defined after the 'performSelfAnalysis' method has been called'\nMake sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.");var s,i=Object(n.has)(r,"resyncEnabled")?r.resyncEnabled:u.DEFAULT_RULE_CONFIG.resyncEnabled,a=Object(n.has)(r,"recoveryValueFunc")?r.recoveryValueFunc:u.DEFAULT_RULE_CONFIG.recoveryValueFunc,c=this.ruleShortNameIdx<t},e.prototype.orInternalNoCst=function(e,t){var r=Object(n.isArray)(e)?e:e.DEF,s=this.getKeyForAutomaticLookahead(o.OR_IDX,t),i=this.getLaFuncFromCache(s).call(this,r);if(void 0!==i)return r[i].ALT.call(this);this.raiseNoAltException(t,e.ERR_MSG)},e.prototype.orInternal=function(e,t){var r=this.getKeyForAutomaticLookahead(o.OR_IDX,t),s=this.nestedRuleBeforeClause(e,r);try{var i=Object(n.isArray)(e)?e:e.DEF,a=this.getLaFuncFromCache(r).call(this,i);if(void 0!==a){var u=i[a],c=this.nestedAltBeforeClause(u,t,o.OR_IDX,a);try{return u.ALT.call(this)}finally{void 0!==c&&this.nestedRuleFinallyClause(c.shortName,c.nestedName)}}this.raiseNoAltException(t,e.ERR_MSG)}finally{void 0!==s&&this.nestedRuleFinallyClause(r,s)}},e.prototype.ruleFinallyStateUpdate=function(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),0===this.RULE_STACK.length&&!1===this.isAtEndOfInput()){var e=this.LA(1),t=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new s.NotAllInputParsedException(t,e))}},e.prototype.subruleInternal=function(e,t,r){var n;try{var o=void 0!==r?r.ARGS:void 0;return n=e.call(this,t,o),this.cstPostNonTerminal(n,void 0!==r&&void 0!==r.LABEL?r.LABEL:e.ruleName),n}catch(t){this.subruleInternalError(t,r,e.ruleName)}},e.prototype.subruleInternalError=function(e,t,r){throw Object(s.isRecognitionException)(e)&&void 0!==e.partialCstResult&&(this.cstPostNonTerminal(e.partialCstResult,void 0!==t&&void 0!==t.LABEL?t.LABEL:r),delete e.partialCstResult),e},e.prototype.consumeInternal=function(e,t,r){var n;try{var o=this.LA(1);!0===this.tokenMatcher(o,e)?(this.consumeToken(),n=o):this.consumeInternalError(e,o,r)}catch(r){n=this.consumeInternalRecovery(e,t,r)}return this.cstPostTerminal(void 0!==r&&void 0!==r.LABEL?r.LABEL:e.name,n),n},e.prototype.consumeInternalError=function(e,t,r){var n,o=this.LA(0);throw n=void 0!==r&&r.ERR_MSG?r.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:t,previous:o,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new s.MismatchedTokenException(n,t,o))},e.prototype.consumeInternalRecovery=function(e,t,r){if(!this.recoveryEnabled||"MismatchedTokenException"!==r.name||this.isBackTracking())throw r;var n=this.getFollowsForInRuleRecovery(e,t);try{return this.tryInRuleRecovery(e,n)}catch(e){throw e.name===c.IN_RULE_RECOVERY_EXCEPTION?r:e}},e.prototype.saveRecogState=function(){var e=this.errors,t=Object(n.cloneArr)(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:t,CST_STACK:this.CST_STACK,LAST_EXPLICIT_RULE_STACK:this.LAST_EXPLICIT_RULE_STACK}},e.prototype.reloadRecogState=function(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK},e.prototype.ruleInvocationStateUpdate=function(e,t,r){this.RULE_OCCURRENCE_STACK.push(r),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(t,e)},e.prototype.isBackTracking=function(){return 0!==this.isBackTrackingStack.length},e.prototype.getCurrRuleFullName=function(){var e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]},e.prototype.shortRuleNameToFullName=function(e){return this.shortRuleNameToFull[e]},e.prototype.isAtEndOfInput=function(){return this.tokenMatcher(this.LA(1),l.EOF)},e.prototype.reset=function(){this.resetLexerState(),this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.LAST_EXPLICIT_RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"ErrorHandler",(function(){return a}));var n=r(113),o=r(88),s=r(108),i=r(87),a=function(){function e(){}return e.prototype.initErrorHandler=function(e){this._errors=[],this.errorMessageProvider=Object(o.defaults)(e.errorMessageProvider,i.DEFAULT_PARSER_CONFIG.errorMessageProvider)},e.prototype.SAVE_ERROR=function(e){if(Object(n.isRecognitionException)(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:Object(o.cloneArr)(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error("Trying to save an Error which is not a RecognitionException")},Object.defineProperty(e.prototype,"errors",{get:function(){return Object(o.cloneArr)(this._errors)},set:function(e){this._errors=e},enumerable:!0,configurable:!0}),e.prototype.raiseEarlyExitException=function(e,t,r){for(var o=this.getCurrRuleFullName(),i=this.getGAstProductions()[o],a=Object(s.getLookaheadPathsForOptionalProd)(e,i,t,this.maxLookahead)[0],u=[],c=1;c<=this.maxLookahead;c++)u.push(this.LA(c));var l=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:u,previous:this.LA(0),customUserDescription:r,ruleName:o});throw this.SAVE_ERROR(new n.EarlyExitException(l,this.LA(1),this.LA(0)))},e.prototype.raiseNoAltException=function(e,t){for(var r=this.getCurrRuleFullName(),o=this.getGAstProductions()[r],i=Object(s.getLookaheadPathsForOr)(e,o,this.maxLookahead),a=[],u=1;u<=this.maxLookahead;u++)a.push(this.LA(u));var c=this.LA(0),l=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:i,actual:a,previous:c,customUserDescription:t,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new n.NoViableAltException(l,this.LA(1),c))},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"ContentAssist",(function(){return s}));var n=r(109),o=r(88),s=function(){function e(){}return e.prototype.initContentAssist=function(){},e.prototype.computeContentAssist=function(e,t){var r=this.gastProductionsCache[e];if(Object(o.isUndefined)(r))throw Error("Rule ->"+e+"<- does not exist in this grammar.");return Object(n.nextPossibleTokensAfter)([r],t,this.tokenMatcher,this.maxLookahead)},e.prototype.getNextPossibleTokenTypes=function(e){var t=Object(o.first)(e.ruleStack),r=this.getGAstProductions()[t];return new n.NextAfterTokenWalker(r,e).startWalking()},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"GastRecorder",(function(){return g}));var n=r(88),o=r(91),s=r(93),i=r(98),a=r(92),u=r(87),c=r(105),l={description:"This Object indicates the Parser is during Recording Phase"};Object.freeze(l);var h=Math.pow(2,c.BITS_FOR_OCCURRENCE_IDX)-1,d=Object(a.createToken)({name:"RECORDING_PHASE_TOKEN",pattern:s.Lexer.NA});Object(i.augmentTokenTypes)([d]);var p=Object(a.createTokenInstance)(d,"This IToken indicates the Parser is in Recording Phase\n\tSee: https://sap.github.io/chevrotain/docs/guide/internals.html#grammar-recording for details",-1,-1,-1,-1,-1,-1);Object.freeze(p);var m={name:"This CSTNode indicates the Parser is in Recording Phase\n\tSee: https://sap.github.io/chevrotain/docs/guide/internals.html#grammar-recording for details",children:{}},g=function(){function e(){}return e.prototype.initGastRecorder=function(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1},e.prototype.enableRecording=function(){var e=this;this.RECORDING_PHASE=!0,this.TRACE_INIT("Enable Recording",(function(){for(var t=function(t){var r=t>0?t:"";e["CONSUME"+r]=function(e,r){return this.consumeInternalRecord(e,t,r)},e["SUBRULE"+r]=function(e,r){return this.subruleInternalRecord(e,t,r)},e["OPTION"+r]=function(e){return this.optionInternalRecord(e,t)},e["OR"+r]=function(e){return this.orInternalRecord(e,t)},e["MANY"+r]=function(e){this.manyInternalRecord(t,e)},e["MANY_SEP"+r]=function(e){this.manySepFirstInternalRecord(t,e)},e["AT_LEAST_ONE"+r]=function(e){this.atLeastOneInternalRecord(t,e)},e["AT_LEAST_ONE_SEP"+r]=function(e){this.atLeastOneSepFirstInternalRecord(t,e)}},r=0;r<10;r++)t(r);e.consume=function(e,t,r){return this.consumeInternalRecord(t,e,r)},e.subrule=function(e,t,r){return this.subruleInternalRecord(t,e,r)},e.option=function(e,t){return this.optionInternalRecord(t,e)},e.or=function(e,t){return this.orInternalRecord(t,e)},e.many=function(e,t){this.manyInternalRecord(e,t)},e.atLeastOne=function(e,t){this.atLeastOneInternalRecord(e,t)},e.ACTION=e.ACTION_RECORD,e.BACKTRACK=e.BACKTRACK_RECORD,e.LA=e.LA_RECORD}))},e.prototype.disableRecording=function(){var e=this;this.RECORDING_PHASE=!1,this.TRACE_INIT("Deleting Recording methods",(function(){for(var t=0;t<10;t++){var r=t>0?t:"";delete e["CONSUME"+r],delete e["SUBRULE"+r],delete e["OPTION"+r],delete e["OR"+r],delete e["MANY"+r],delete e["MANY_SEP"+r],delete e["AT_LEAST_ONE"+r],delete e["AT_LEAST_ONE_SEP"+r]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA}))},e.prototype.ACTION_RECORD=function(e){},e.prototype.BACKTRACK_RECORD=function(e,t){return function(){return!0}},e.prototype.LA_RECORD=function(e){return u.END_OF_FILE},e.prototype.topLevelRuleRecord=function(e,t){try{var r=new o.Rule({definition:[],name:e});return r.name=e,this.recordingProdStack.push(r),t.call(this),this.recordingProdStack.pop(),r}catch(e){if(!0!==e.KNOWN_RECORDER_ERROR)try{e.message=e.message+'\n\t This error was thrown during the "grammar recording phase" For more info see:\n\thttps://sap.github.io/chevrotain/docs/guide/internals.html#grammar-recording'}catch(t){throw e}throw e}},e.prototype.optionInternalRecord=function(e,t){return f.call(this,o.Option,e,t)},e.prototype.atLeastOneInternalRecord=function(e,t){f.call(this,o.RepetitionMandatory,t,e)},e.prototype.atLeastOneSepFirstInternalRecord=function(e,t){f.call(this,o.RepetitionMandatoryWithSeparator,t,e,!0)},e.prototype.manyInternalRecord=function(e,t){f.call(this,o.Repetition,t,e)},e.prototype.manySepFirstInternalRecord=function(e,t){f.call(this,o.RepetitionWithSeparator,t,e,!0)},e.prototype.orInternalRecord=function(e,t){return E.call(this,e,t)},e.prototype.subruleInternalRecord=function(e,t,r){if(y(t),!e||!1===Object(n.has)(e,"ruleName")){var s=new Error(" argument is invalid expecting a Parser method reference but got: <"+JSON.stringify(e)+">\n inside top level rule: <"+this.recordingProdStack[0].name+">");throw s.KNOWN_RECORDER_ERROR=!0,s}var i=Object(n.peek)(this.recordingProdStack),a=e.ruleName,u=new o.NonTerminal({idx:t,nonTerminalName:a,referencedRule:void 0});return i.definition.push(u),this.outputCst?m:l},e.prototype.consumeInternalRecord=function(e,t,r){if(y(t),!Object(i.hasShortKeyProperty)(e)){var s=new Error(" argument is invalid expecting a TokenType reference but got: <"+JSON.stringify(e)+">\n inside top level rule: <"+this.recordingProdStack[0].name+">");throw s.KNOWN_RECORDER_ERROR=!0,s}var a=Object(n.peek)(this.recordingProdStack),u=new o.Terminal({idx:t,terminalType:e});return a.definition.push(u),p},e}();function f(e,t,r,o){void 0===o&&(o=!1),y(r);var s=Object(n.peek)(this.recordingProdStack),i=Object(n.isFunction)(t)?t:t.DEF,a=new e({definition:[],idx:r});return Object(n.has)(t,"NAME")&&(a.name=t.NAME),o&&(a.separator=t.SEP),Object(n.has)(t,"MAX_LOOKAHEAD")&&(a.maxLookahead=t.MAX_LOOKAHEAD),this.recordingProdStack.push(a),i.call(this),s.definition.push(a),this.recordingProdStack.pop(),l}function E(e,t){var r=this;y(t);var s=Object(n.peek)(this.recordingProdStack),i=!1===Object(n.isArray)(e),a=!1===i?e:e.DEF,u=new o.Alternation({definition:[],idx:t,ignoreAmbiguities:i&&!0===e.IGNORE_AMBIGUITIES});Object(n.has)(e,"NAME")&&(u.name=e.NAME),Object(n.has)(e,"MAX_LOOKAHEAD")&&(u.maxLookahead=e.MAX_LOOKAHEAD);var c=Object(n.some)(a,(function(e){return Object(n.isFunction)(e.GATE)}));return u.hasPredicates=c,s.definition.push(u),Object(n.forEach)(a,(function(e){var t=new o.Flat({definition:[]});u.definition.push(t),Object(n.has)(e,"NAME")&&(t.name=e.NAME),Object(n.has)(e,"IGNORE_AMBIGUITIES")?t.ignoreAmbiguities=e.IGNORE_AMBIGUITIES:Object(n.has)(e,"GATE")&&(t.ignoreAmbiguities=!0),r.recordingProdStack.push(t),e.ALT.call(r),r.recordingProdStack.pop()})),l}function T(e){return 0===e?"":""+e}function y(e){if(e<0||e>h){var t=new Error("Invalid DSL Method idx value: <"+e+">\n\tIdx value must be a none negative value smaller than "+(h+1));throw t.KNOWN_RECORDER_ERROR=!0,t}}},function(e,t,r){"use strict";r.r(t),r.d(t,"PerformanceTracer",(function(){return s}));var n=r(88),o=r(87),s=function(){function e(){}return e.prototype.initPerformanceTracer=function(e){if(Object(n.has)(e,"traceInitPerf")){var t=e.traceInitPerf,r="number"==typeof t;this.traceInitMaxIdent=r?t:1/0,this.traceInitPerf=r?t>0:t}else this.traceInitMaxIdent=0,this.traceInitPerf=o.DEFAULT_PARSER_CONFIG.traceInitPerf;this.traceInitIndent=-1},e.prototype.TRACE_INIT=function(e,t){if(!0===this.traceInitPerf){this.traceInitIndent++;var r=new Array(this.traceInitIndent+1).join("\t");this.traceInitIndent");var o=Object(n.timer)(t),s=o.time,i=o.value,a=s>10?console.warn:console.log;return this.traceInitIndent time: "+s+"ms"),this.traceInitIndent--,i}return t()},e}()},function(e,t,r){"use strict";r.r(t),r.d(t,"createSyntaxDiagramsCode",(function(){return o}));var n=r(86);function o(e,t){var r=void 0===t?{}:t,o=r.resourceBase,s=void 0===o?"https://unpkg.com/chevrotain@"+n.VERSION+"/diagrams/":o,i=r.css;return"\n\x3c!-- This is a generated file --\x3e\n\n\n\n\n\n\n\n + + @@ -19,14 +35,14 @@ - + -