@danielsimonjr/mathts-expression 0.8.0 → 0.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/README.md +42 -42
  2. package/dist/index.js +261 -333
  3. package/dist/node/AccessorNode.d.ts +121 -132
  4. package/dist/node/AccessorNode.d.ts.map +1 -1
  5. package/dist/node/ArrayNode.d.ts +25 -30
  6. package/dist/node/ArrayNode.d.ts.map +1 -1
  7. package/dist/node/AssignmentNode.d.ts +19 -32
  8. package/dist/node/AssignmentNode.d.ts.map +1 -1
  9. package/dist/node/BlockNode.d.ts +121 -126
  10. package/dist/node/BlockNode.d.ts.map +1 -1
  11. package/dist/node/ConditionalNode.d.ts +25 -30
  12. package/dist/node/ConditionalNode.d.ts.map +1 -1
  13. package/dist/node/ConstantNode.d.ts +93 -100
  14. package/dist/node/ConstantNode.d.ts.map +1 -1
  15. package/dist/node/FunctionAssignmentNode.d.ts +25 -30
  16. package/dist/node/FunctionAssignmentNode.d.ts.map +1 -1
  17. package/dist/node/FunctionNode.d.ts +32 -43
  18. package/dist/node/FunctionNode.d.ts.map +1 -1
  19. package/dist/node/IndexNode.d.ts +25 -34
  20. package/dist/node/IndexNode.d.ts.map +1 -1
  21. package/dist/node/Node.d.ts +41 -38
  22. package/dist/node/Node.d.ts.map +1 -1
  23. package/dist/node/ObjectNode.d.ts +25 -30
  24. package/dist/node/ObjectNode.d.ts.map +1 -1
  25. package/dist/node/OperatorNode.d.ts +29 -42
  26. package/dist/node/OperatorNode.d.ts.map +1 -1
  27. package/dist/node/ParenthesisNode.d.ts +27 -34
  28. package/dist/node/ParenthesisNode.d.ts.map +1 -1
  29. package/dist/node/RangeNode.d.ts +23 -30
  30. package/dist/node/RangeNode.d.ts.map +1 -1
  31. package/dist/node/RelationalNode.d.ts +25 -32
  32. package/dist/node/RelationalNode.d.ts.map +1 -1
  33. package/dist/node/SymbolNode.d.ts +26 -33
  34. package/dist/node/SymbolNode.d.ts.map +1 -1
  35. package/dist/node/utils/access.d.ts +7 -0
  36. package/dist/node/utils/access.d.ts.map +1 -1
  37. package/dist/node/utils/assign.d.ts +8 -0
  38. package/dist/node/utils/assign.d.ts.map +1 -1
  39. package/dist/node/utils/stringSubset.d.ts +8 -8
  40. package/dist/operators.d.ts +12 -15
  41. package/dist/operators.d.ts.map +1 -1
  42. package/dist/parse.d.ts.map +1 -1
  43. package/dist/transform/utils/dimToZeroBase.d.ts +4 -0
  44. package/dist/transform/utils/dimToZeroBase.d.ts.map +1 -1
  45. package/dist/types.d.ts +8 -0
  46. package/dist/types.d.ts.map +1 -1
  47. package/dist/utils/is.d.ts +273 -3
  48. package/dist/utils/is.d.ts.map +1 -1
  49. package/dist/utils/latex.d.ts +12 -0
  50. package/dist/utils/latex.d.ts.map +1 -1
  51. package/package.json +59 -59
@@ -27,61 +27,58 @@ export declare const createRangeNode: import("../utils/factory.js").FactoryFunct
27
27
  /**
28
28
  * Check whether the RangeNode needs the `end` symbol to be defined.
29
29
  * This end is the size of the Matrix in current dimension.
30
- * @return {boolean}
31
30
  */
32
31
  needsEnd(): boolean;
33
32
  /**
34
33
  * Compile a node into a JavaScript function.
35
34
  * This basically pre-calculates as much as possible and only leaves open
36
35
  * calculations which depend on a dynamic scope with variables.
37
- * @param {Object} math Math.js namespace with functions and constants.
38
- * @param {Object} argNames An object with argument names as key and `true`
36
+ * @param math - Math.js namespace with functions and constants.
37
+ * @param argNames - An object with argument names as key and `true`
39
38
  * as value. Used in the SymbolNode to optimize
40
39
  * for arguments from user assigned functions
41
40
  * (see FunctionAssignmentNode) or special symbols
42
41
  * like `end` (see IndexNode).
43
- * @return {function} Returns a function which can be called like:
42
+ * @returns Returns a function which can be called like:
44
43
  * evalNode(scope: Object, args: Object, context: *)
45
44
  */
46
45
  _compile(math: Record<string, unknown>, argNames: Record<string, boolean>): CompileFunction;
47
46
  /**
48
47
  * Execute a callback for each of the child nodes of this node
49
- * @param {function(child: Node, path: string, parent: Node)} callback
48
+ * @param callback
50
49
  */
51
50
  forEach(callback: (child: Node, path: string, parent: /*elided*/ any) => void): void;
52
51
  /**
53
52
  * Create a new RangeNode whose children are the results of calling
54
53
  * the provided callback function for each child of the original node.
55
- * @param {function(child: Node, path: string, parent: Node): Node} callback
56
- * @returns {RangeNode} Returns a transformed copy of the node
54
+ * @param callback
55
+ * @returns Returns a transformed copy of the node
57
56
  */
58
57
  map(callback: (child: Node, path: string, parent: /*elided*/ any) => Node): /*elided*/ any;
59
58
  /**
60
59
  * Create a clone of this node, a shallow copy
61
- * @return {RangeNode}
62
60
  */
63
61
  clone(): /*elided*/ any;
64
62
  /**
65
63
  * Get string representation
66
- * @param {Object} options
67
- * @return {string} str
64
+ * @param options
65
+ * @returns str
68
66
  */
69
67
  _toString(options?: StringOptions): string;
70
68
  /**
71
69
  * Get a JSON representation of the node
72
- * @returns {Object}
73
70
  */
74
71
  toJSON(): Record<string, unknown>;
75
72
  /**
76
73
  * Get HTML representation
77
- * @param {Object} options
78
- * @return {string} str
74
+ * @param options
75
+ * @returns str
79
76
  */
80
77
  _toHTML(options?: StringOptions): string;
81
78
  /**
82
79
  * Get LaTeX representation
83
80
  * @params {Object} options
84
- * @return {string} str
81
+ * @returns str
85
82
  */
86
83
  _toTex(options?: StringOptions): string;
87
84
  _ifNode: (node: unknown) => Node;
@@ -95,11 +92,10 @@ export declare const createRangeNode: import("../utils/factory.js").FactoryFunct
95
92
  name: string;
96
93
  /**
97
94
  * Instantiate an RangeNode from its JSON representation
98
- * @param {Object} json
95
+ * @param json
99
96
  * An object structured like
100
97
  * `{"mathjs": "RangeNode", "start": ..., "end": ..., "step": ...}`,
101
98
  * where mathjs is optional
102
- * @returns {RangeNode}
103
99
  */
104
100
  fromJSON(json: {
105
101
  start: Node;
@@ -114,61 +110,58 @@ export declare const createRangeNode: import("../utils/factory.js").FactoryFunct
114
110
  /**
115
111
  * Check whether the RangeNode needs the `end` symbol to be defined.
116
112
  * This end is the size of the Matrix in current dimension.
117
- * @return {boolean}
118
113
  */
119
114
  needsEnd(): boolean;
120
115
  /**
121
116
  * Compile a node into a JavaScript function.
122
117
  * This basically pre-calculates as much as possible and only leaves open
123
118
  * calculations which depend on a dynamic scope with variables.
124
- * @param {Object} math Math.js namespace with functions and constants.
125
- * @param {Object} argNames An object with argument names as key and `true`
119
+ * @param math - Math.js namespace with functions and constants.
120
+ * @param argNames - An object with argument names as key and `true`
126
121
  * as value. Used in the SymbolNode to optimize
127
122
  * for arguments from user assigned functions
128
123
  * (see FunctionAssignmentNode) or special symbols
129
124
  * like `end` (see IndexNode).
130
- * @return {function} Returns a function which can be called like:
125
+ * @returns Returns a function which can be called like:
131
126
  * evalNode(scope: Object, args: Object, context: *)
132
127
  */
133
128
  _compile(math: Record<string, unknown>, argNames: Record<string, boolean>): CompileFunction;
134
129
  /**
135
130
  * Execute a callback for each of the child nodes of this node
136
- * @param {function(child: Node, path: string, parent: Node)} callback
131
+ * @param callback
137
132
  */
138
133
  forEach(callback: (child: Node, path: string, parent: /*elided*/ any) => void): void;
139
134
  /**
140
135
  * Create a new RangeNode whose children are the results of calling
141
136
  * the provided callback function for each child of the original node.
142
- * @param {function(child: Node, path: string, parent: Node): Node} callback
143
- * @returns {RangeNode} Returns a transformed copy of the node
137
+ * @param callback
138
+ * @returns Returns a transformed copy of the node
144
139
  */
145
140
  map(callback: (child: Node, path: string, parent: /*elided*/ any) => Node): /*elided*/ any;
146
141
  /**
147
142
  * Create a clone of this node, a shallow copy
148
- * @return {RangeNode}
149
143
  */
150
144
  clone(): /*elided*/ any;
151
145
  /**
152
146
  * Get string representation
153
- * @param {Object} options
154
- * @return {string} str
147
+ * @param options
148
+ * @returns str
155
149
  */
156
150
  _toString(options?: StringOptions): string;
157
151
  /**
158
152
  * Get a JSON representation of the node
159
- * @returns {Object}
160
153
  */
161
154
  toJSON(): Record<string, unknown>;
162
155
  /**
163
156
  * Get HTML representation
164
- * @param {Object} options
165
- * @return {string} str
157
+ * @param options
158
+ * @returns str
166
159
  */
167
160
  _toHTML(options?: StringOptions): string;
168
161
  /**
169
162
  * Get LaTeX representation
170
163
  * @params {Object} options
171
- * @return {string} str
164
+ * @returns str
172
165
  */
173
166
  _toTex(options?: StringOptions): string;
174
167
  _ifNode: (node: unknown) => Node;
@@ -1 +1 @@
1
- {"version":3,"file":"RangeNode.d.ts","sourceRoot":"","sources":["../../src/node/RangeNode.ts"],"names":[],"mappings":"AAKA,UAAU,IAAI;IACZ,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,eAAe,CAAC;IAChG,OAAO,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAC;IACjC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,OAAO,KAAK,IAAI,EAAE,CAAC;IACtD,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM,CAAC;IAC9C,MAAM,EAAE,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM,CAAC;IAC5C,KAAK,EAAE,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM,CAAC;IAC3C,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,KAAK,eAAe,GAAG,CACrB,KAAK,EAAE,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,EAC3B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,OAAO,EAAE,OAAO,KACb,OAAO,CAAC;AAEb,UAAU,aAAa;IACrB,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,KAAK,CAAC;IACtC,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB;AAQD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KH;;;;WAIG;4BACiB,aAAa,GAAG,MAAM;QAkC1C;;WAEG;kBACO,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;QAoBjC;;;;WAIG;0BACe,aAAa,GAAG,MAAM;QA2CxC;;;;WAIG;yBACc,aAAa,GAAG,MAAM;iBAtTlC,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI;gBACxB,CAAC,QAAQ,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,OAAO,KAAK,IAAI,EAAE;kBAC3C,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM;gBACrC,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM;eACpC,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM;uBAC3B,OAAO;eACf,MAAM;;EAkVd,CAAC"}
@@ -25,54 +25,51 @@ export declare const createRelationalNode: import("../utils/factory.js").Factory
25
25
  * Compile a node into a JavaScript function.
26
26
  * This basically pre-calculates as much as possible and only leaves open
27
27
  * calculations which depend on a dynamic scope with variables.
28
- * @param {Object} math Math.js namespace with functions and constants.
29
- * @param {Object} argNames An object with argument names as key and `true`
28
+ * @param math - Math.js namespace with functions and constants.
29
+ * @param argNames - An object with argument names as key and `true`
30
30
  * as value. Used in the SymbolNode to optimize
31
31
  * for arguments from user assigned functions
32
32
  * (see FunctionAssignmentNode) or special symbols
33
33
  * like `end` (see IndexNode).
34
- * @return {function} Returns a function which can be called like:
34
+ * @returns Returns a function which can be called like:
35
35
  * evalNode(scope: Object, args: Object, context: *)
36
36
  */
37
37
  _compile(math: Record<string, unknown>, argNames: Record<string, boolean>): CompileFunction;
38
38
  /**
39
39
  * Execute a callback for each of the child nodes of this node
40
- * @param {function(child: Node, path: string, parent: Node)} callback
40
+ * @param callback
41
41
  */
42
42
  forEach(callback: (child: Node, path: string, parent: /*elided*/ any) => void): void;
43
43
  /**
44
44
  * Create a new RelationalNode whose children are the results of calling
45
45
  * the provided callback function for each child of the original node.
46
- * @param {function(child: Node, path: string, parent: Node): Node} callback
47
- * @returns {RelationalNode} Returns a transformed copy of the node
46
+ * @param callback
47
+ * @returns Returns a transformed copy of the node
48
48
  */
49
49
  map(callback: (child: Node, path: string, parent: /*elided*/ any) => Node): /*elided*/ any;
50
50
  /**
51
51
  * Create a clone of this node, a shallow copy
52
- * @return {RelationalNode}
53
52
  */
54
53
  clone(): /*elided*/ any;
55
54
  /**
56
55
  * Get string representation.
57
- * @param {Object} options
58
- * @return {string} str
56
+ * @param options
57
+ * @returns str
59
58
  */
60
59
  _toString(options?: StringOptions): string;
61
60
  /**
62
61
  * Get a JSON representation of the node
63
- * @returns {Object}
64
62
  */
65
63
  toJSON(): Record<string, unknown>;
66
64
  /**
67
65
  * Get HTML representation
68
- * @param {Object} options
69
- * @return {string} str
66
+ * @param options
67
+ * @returns str
70
68
  */
71
69
  _toHTML(options?: StringOptions): string;
72
70
  /**
73
- * Get LaTeX representation
74
- * @param {Object} options
75
- * @return {string} str
71
+ * Get the MathML representation of this node.
72
+ * @returns str
76
73
  */
77
74
  _toMathML(): string;
78
75
  _toTex(options?: StringOptions): string;
@@ -85,11 +82,10 @@ export declare const createRelationalNode: import("../utils/factory.js").Factory
85
82
  name: string;
86
83
  /**
87
84
  * Instantiate a RelationalNode from its JSON representation
88
- * @param {Object} json
85
+ * @param json
89
86
  * An object structured like
90
87
  * `{"mathjs": "RelationalNode", "conditionals": ..., "params": ...}`,
91
88
  * where mathjs is optional
92
- * @returns {RelationalNode}
93
89
  */
94
90
  fromJSON(json: {
95
91
  conditionals: string[];
@@ -103,54 +99,51 @@ export declare const createRelationalNode: import("../utils/factory.js").Factory
103
99
  * Compile a node into a JavaScript function.
104
100
  * This basically pre-calculates as much as possible and only leaves open
105
101
  * calculations which depend on a dynamic scope with variables.
106
- * @param {Object} math Math.js namespace with functions and constants.
107
- * @param {Object} argNames An object with argument names as key and `true`
102
+ * @param math - Math.js namespace with functions and constants.
103
+ * @param argNames - An object with argument names as key and `true`
108
104
  * as value. Used in the SymbolNode to optimize
109
105
  * for arguments from user assigned functions
110
106
  * (see FunctionAssignmentNode) or special symbols
111
107
  * like `end` (see IndexNode).
112
- * @return {function} Returns a function which can be called like:
108
+ * @returns Returns a function which can be called like:
113
109
  * evalNode(scope: Object, args: Object, context: *)
114
110
  */
115
111
  _compile(math: Record<string, unknown>, argNames: Record<string, boolean>): CompileFunction;
116
112
  /**
117
113
  * Execute a callback for each of the child nodes of this node
118
- * @param {function(child: Node, path: string, parent: Node)} callback
114
+ * @param callback
119
115
  */
120
116
  forEach(callback: (child: Node, path: string, parent: /*elided*/ any) => void): void;
121
117
  /**
122
118
  * Create a new RelationalNode whose children are the results of calling
123
119
  * the provided callback function for each child of the original node.
124
- * @param {function(child: Node, path: string, parent: Node): Node} callback
125
- * @returns {RelationalNode} Returns a transformed copy of the node
120
+ * @param callback
121
+ * @returns Returns a transformed copy of the node
126
122
  */
127
123
  map(callback: (child: Node, path: string, parent: /*elided*/ any) => Node): /*elided*/ any;
128
124
  /**
129
125
  * Create a clone of this node, a shallow copy
130
- * @return {RelationalNode}
131
126
  */
132
127
  clone(): /*elided*/ any;
133
128
  /**
134
129
  * Get string representation.
135
- * @param {Object} options
136
- * @return {string} str
130
+ * @param options
131
+ * @returns str
137
132
  */
138
133
  _toString(options?: StringOptions): string;
139
134
  /**
140
135
  * Get a JSON representation of the node
141
- * @returns {Object}
142
136
  */
143
137
  toJSON(): Record<string, unknown>;
144
138
  /**
145
139
  * Get HTML representation
146
- * @param {Object} options
147
- * @return {string} str
140
+ * @param options
141
+ * @returns str
148
142
  */
149
143
  _toHTML(options?: StringOptions): string;
150
144
  /**
151
- * Get LaTeX representation
152
- * @param {Object} options
153
- * @return {string} str
145
+ * Get the MathML representation of this node.
146
+ * @returns str
154
147
  */
155
148
  _toMathML(): string;
156
149
  _toTex(options?: StringOptions): string;
@@ -1 +1 @@
1
- {"version":3,"file":"RelationalNode.d.ts","sourceRoot":"","sources":["../../src/node/RelationalNode.ts"],"names":[],"mappings":"AAQA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C,YAAY,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,eAAe;QA0B3F;;;WAGG;0BACe,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,gBAAgB,KAAK,IAAI,GAAG,IAAI;QAIpF;;;;;WAKG;sBACW,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,gBAAgB,KAAK,IAAI;QAUzE;;WAEG;;QAKH;;;;WAIG;4BACiB,aAAa,GAAG,MAAM;QAiC1C;;WAEG;kBACO,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;QAmBjC;;;;WAIG;0BACe,aAAa,GAAG,MAAM;QAuCxC;;;WAGG;qBACU,MAAM;yBAaF,aAAa,GAAG,MAAM;iBAhRlC,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI;kBACtB,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM;gBACrC,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM;eACpC,CAAC,OAAO,CAAC,EAAE,aAAa,KAAK,MAAM;kBAChC,MAAM,MAAM;;EAiTvB,CAAC"}
@@ -23,56 +23,53 @@ export declare const createSymbolNode: import("../utils/factory.js").FactoryFunc
23
23
  * Compile a node into a JavaScript function.
24
24
  * This basically pre-calculates as much as possible and only leaves open
25
25
  * calculations which depend on a dynamic scope with variables.
26
- * @param {Object} math Math.js namespace with functions and constants.
27
- * @param {Object} argNames An object with argument names as key and `true`
26
+ * @param math - Math.js namespace with functions and constants.
27
+ * @param argNames - An object with argument names as key and `true`
28
28
  * as value. Used in the SymbolNode to optimize
29
29
  * for arguments from user assigned functions
30
30
  * (see FunctionAssignmentNode) or special symbols
31
31
  * like `end` (see IndexNode).
32
- * @return {function} Returns a function which can be called like:
32
+ * @returns Returns a function which can be called like:
33
33
  * evalNode(scope: Object, args: Object, context: *)
34
34
  */
35
35
  _compile(math: Record<string, unknown>, argNames: Record<string, boolean>): CompileFunction;
36
36
  /**
37
37
  * Execute a callback for each of the child nodes of this node
38
- * @param {function(child: Node, path: string, parent: Node)} callback
38
+ * @param _callback
39
39
  */
40
40
  forEach(_callback: (child: Node, path: string, parent: /*elided*/ any) => void): void;
41
41
  /**
42
42
  * Create a new SymbolNode with children produced by the given callback.
43
43
  * Trivial since a SymbolNode has no children
44
- * @param {function(child: Node, path: string, parent: Node) : Node} callback
45
- * @returns {SymbolNode} Returns a clone of the node
44
+ * @param _callback
45
+ * @returns Returns a clone of the node
46
46
  */
47
47
  map(_callback: (child: Node, path: string, parent: /*elided*/ any) => Node): /*elided*/ any;
48
48
  /**
49
49
  * Create a clone of this node, a shallow copy
50
- * @return {SymbolNode}
51
50
  */
52
51
  clone(): /*elided*/ any;
53
52
  /**
54
53
  * Get string representation
55
- * @param {Object} options
56
- * @return {string} str
54
+ * @param _options
55
+ * @returns str
57
56
  * @override
58
57
  */
59
58
  _toString(_options?: StringOptions): string;
60
59
  /**
61
60
  * Get HTML representation
62
- * @param {Object} options
63
- * @return {string} str
61
+ * @param _options
62
+ * @returns str
64
63
  * @override
65
64
  */
66
65
  _toHTML(_options?: StringOptions): string;
67
66
  /**
68
67
  * Get a JSON representation of the node
69
- * @returns {Object}
70
68
  */
71
69
  toJSON(): Record<string, unknown>;
72
70
  /**
73
- * Get LaTeX representation
74
- * @param {Object} options
75
- * @return {string} str
71
+ * Get the MathML representation of this node.
72
+ * @returns str
76
73
  * @override
77
74
  */
78
75
  _toMathML(): string;
@@ -80,15 +77,14 @@ export declare const createSymbolNode: import("../utils/factory.js").FactoryFunc
80
77
  };
81
78
  /**
82
79
  * Throws an error 'Undefined symbol {name}'
83
- * @param {string} name
80
+ * @param name
84
81
  */
85
82
  onUndefinedSymbol(name: string): never;
86
83
  /**
87
84
  * Instantiate a SymbolNode from its JSON representation
88
- * @param {Object} json An object structured like
85
+ * @param json - An object structured like
89
86
  * `{"mathjs": "SymbolNode", name: "x"}`,
90
87
  * where mathjs is optional
91
- * @returns {SymbolNode}
92
88
  */
93
89
  fromJSON(json: {
94
90
  name: string;
@@ -100,56 +96,53 @@ export declare const createSymbolNode: import("../utils/factory.js").FactoryFunc
100
96
  * Compile a node into a JavaScript function.
101
97
  * This basically pre-calculates as much as possible and only leaves open
102
98
  * calculations which depend on a dynamic scope with variables.
103
- * @param {Object} math Math.js namespace with functions and constants.
104
- * @param {Object} argNames An object with argument names as key and `true`
99
+ * @param math - Math.js namespace with functions and constants.
100
+ * @param argNames - An object with argument names as key and `true`
105
101
  * as value. Used in the SymbolNode to optimize
106
102
  * for arguments from user assigned functions
107
103
  * (see FunctionAssignmentNode) or special symbols
108
104
  * like `end` (see IndexNode).
109
- * @return {function} Returns a function which can be called like:
105
+ * @returns Returns a function which can be called like:
110
106
  * evalNode(scope: Object, args: Object, context: *)
111
107
  */
112
108
  _compile(math: Record<string, unknown>, argNames: Record<string, boolean>): CompileFunction;
113
109
  /**
114
110
  * Execute a callback for each of the child nodes of this node
115
- * @param {function(child: Node, path: string, parent: Node)} callback
111
+ * @param _callback
116
112
  */
117
113
  forEach(_callback: (child: Node, path: string, parent: /*elided*/ any) => void): void;
118
114
  /**
119
115
  * Create a new SymbolNode with children produced by the given callback.
120
116
  * Trivial since a SymbolNode has no children
121
- * @param {function(child: Node, path: string, parent: Node) : Node} callback
122
- * @returns {SymbolNode} Returns a clone of the node
117
+ * @param _callback
118
+ * @returns Returns a clone of the node
123
119
  */
124
120
  map(_callback: (child: Node, path: string, parent: /*elided*/ any) => Node): /*elided*/ any;
125
121
  /**
126
122
  * Create a clone of this node, a shallow copy
127
- * @return {SymbolNode}
128
123
  */
129
124
  clone(): /*elided*/ any;
130
125
  /**
131
126
  * Get string representation
132
- * @param {Object} options
133
- * @return {string} str
127
+ * @param _options
128
+ * @returns str
134
129
  * @override
135
130
  */
136
131
  _toString(_options?: StringOptions): string;
137
132
  /**
138
133
  * Get HTML representation
139
- * @param {Object} options
140
- * @return {string} str
134
+ * @param _options
135
+ * @returns str
141
136
  * @override
142
137
  */
143
138
  _toHTML(_options?: StringOptions): string;
144
139
  /**
145
140
  * Get a JSON representation of the node
146
- * @returns {Object}
147
141
  */
148
142
  toJSON(): Record<string, unknown>;
149
143
  /**
150
- * Get LaTeX representation
151
- * @param {Object} options
152
- * @return {string} str
144
+ * Get the MathML representation of this node.
145
+ * @returns str
153
146
  * @override
154
147
  */
155
148
  _toMathML(): string;
@@ -1 +1 @@
1
- {"version":3,"file":"SymbolNode.d.ts","sourceRoot":"","sources":["../../src/node/SymbolNode.ts"],"names":[],"mappings":"AAOA,UAAU,IAAI;IACZ,KAAK,EAAE,MAAM,IAAI,CAAC;CACnB;AAED,KAAK,eAAe,GAAG,CACrB,KAAK,EAAE,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,EAC3B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,OAAO,EAAE,OAAO,KACb,OAAO,CAAC;AAEb,UAAU,aAAa;IACrB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB;AAED,UAAU,eAAe;IACvB,KAAK,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;IAC5C,eAAe,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC;CAC5C;AAED,UAAU,YAAY;IACpB,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC9B,IAAI,CAAC,EAAE,eAAe,CAAC;IACvB,IAAI,EAAE,KAAK,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,IAAI,CAAC;CACxC;AAKD,eAAO,MAAM,gBAAgB;eAuBL,MAAM;cATlB,MAAM;oBAmBA,MAAM;4BAGE,OAAO;QAI3B;;;;;;;;;;;;WAYG;uBACY,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,eAAe;QAuC3F;;;WAGG;2BACgB,CAAC,KAAK,EAAE,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M;0BAID,aAAa,GAAG,MAAM;;IAjFxC;;;OAGG;4BAC4B,MAAM,GAAG,KAAK;IA0D7C;;;;;OAKG;mBACmB;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE;cApKhC,MAAM;oBAmBA,MAAM;4BAGE,OAAO;QAI3B;;;;;;;;;;;;WAYG;uBACY,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,eAAe;QAuC3F;;;WAGG;2BACgB,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,gBAAY,KAAK,IAAI,GAAG,IAAI;QAIjF;;;;;WAKG;uBACY,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,gBAAY,KAAK,IAAI;QAYtE;;WAEG;;QAMH;;;;;WAKG;6BACkB,aAAa,GAAG,MAAM;QAI3C;;;;;WAKG;2BACgB,aAAa,GAAG,MAAM;QAoBzC;;WAEG;kBACO,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;QAiBjC;;;;WAIG;qBACU,MAAM;0BAID,aAAa,GAAG,MAAM;;EAmB7C,CAAC"}
@@ -1,3 +1,10 @@
1
+ /**
2
+ * Make the `access` function that the expression nodes use to read a part of a value.
3
+ * The `subset` dependency reads a part of an Array.
4
+ * The `access` function reads a Matrix subset, a string subset or an object property.
5
+ * It throws a TypeError for a numeric index on an object and for other value types.
6
+ * Before it throws an IndexError again, it changes the indices to one-based.
7
+ */
1
8
  export declare function accessFactory({ subset }: {
2
9
  subset: (...args: unknown[]) => unknown;
3
10
  }): (object: unknown, index: {
@@ -1 +1 @@
1
- {"version":3,"file":"access.d.ts","sourceRoot":"","sources":["../../../src/node/utils/access.ts"],"names":[],"mappings":"AAIA,wBAAgB,aAAa,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,OAAO,CAAA;CAAE,YAazE,OAAO,SACR;IAAE,gBAAgB,EAAE,MAAM,OAAO,CAAC;IAAC,iBAAiB,EAAE,MAAM,MAAM,CAAA;CAAE,aAwB9E"}
1
+ {"version":3,"file":"access.d.ts","sourceRoot":"","sources":["../../../src/node/utils/access.ts"],"names":[],"mappings":"AAIA;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,OAAO,CAAA;CAAE,YAazE,OAAO,SACR;IAAE,gBAAgB,EAAE,MAAM,OAAO,CAAC;IAAC,iBAAiB,EAAE,MAAM,MAAM,CAAA;CAAE,aAwB9E"}
@@ -1,4 +1,12 @@
1
1
  import type { IndexLike } from './stringSubset.js';
2
+ /**
3
+ * Make the `assign` function that the expression nodes use to write a part of a value.
4
+ * For an Array, `assign` copies the result of `subset` into the original array and returns that array.
5
+ * For a Matrix, it returns the result of the `subset` method of the matrix.
6
+ * For a string, it returns a new string. For an object, it sets the property and returns the object.
7
+ * It throws a TypeError for a numeric index on an object and for other value types.
8
+ * Before it throws an IndexError again, it changes the indices to one-based.
9
+ */
2
10
  export declare function assignFactory({ subset }: {
3
11
  subset: (...args: unknown[]) => unknown;
4
12
  }): (object: unknown, index: {
@@ -1 +1 @@
1
- {"version":3,"file":"assign.d.ts","sourceRoot":"","sources":["../../../src/node/utils/assign.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD,wBAAgB,aAAa,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,OAAO,CAAA;CAAE,YAgBzE,OAAO,SACR;IAAE,gBAAgB,EAAE,MAAM,OAAO,CAAC;IAAC,iBAAiB,EAAE,MAAM,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,OAAO,CAAA;CAAE,GAAG,SAAS,SACnG,OAAO,aA8BjB"}
1
+ {"version":3,"file":"assign.d.ts","sourceRoot":"","sources":["../../../src/node/utils/assign.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,CAAC,GAAG,IAAI,EAAE,OAAO,EAAE,KAAK,OAAO,CAAA;CAAE,YAgBzE,OAAO,SACR;IACL,gBAAgB,EAAE,MAAM,OAAO,CAAC;IAChC,iBAAiB,EAAE,MAAM,MAAM,CAAC;IAChC,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,GAAG,SAAS,SACN,OAAO,aA8BjB"}
@@ -14,19 +14,19 @@ export interface IndexLike {
14
14
  }
15
15
  /**
16
16
  * Retrieve a subset of a string
17
- * @param {string} str string from which to get a substring
18
- * @param {IndexLike} index An index or list of indices (character positions)
19
- * @returns {string} substring
17
+ * @param str - string from which to get a substring
18
+ * @param index - An index or list of indices (character positions)
19
+ * @returns substring
20
20
  */
21
21
  export declare function getStringSubset(str: string, index: IndexLike): string;
22
22
  /**
23
23
  * Replace a substring in a string
24
- * @param {string} str string to be replaced
25
- * @param {IndexLike} index An index or list of indices (character positions)
26
- * @param {string} replacement Replacement string
27
- * @param {string} [defaultValue] Default value to be used when resizing
24
+ * @param str - string to be replaced
25
+ * @param index - An index or list of indices (character positions)
26
+ * @param replacement - Replacement string
27
+ * @param defaultValue - Optional. Default value to be used when resizing
28
28
  * the string. is ' ' by default
29
- * @returns {string} result
29
+ * @returns result
30
30
  */
31
31
  export declare function setStringSubset(str: string, index: IndexLike, replacement: string, defaultValue?: string): string;
32
32
  export {};
@@ -18,11 +18,10 @@ export declare const properties: OperatorGroup[];
18
18
  * Higher number for higher precedence, starting with 0.
19
19
  * Returns null if the precedence is undefined.
20
20
  *
21
- * @param {Node} _node
22
- * @param {string} parenthesis
23
- * @param {string} implicit
24
- * @param {Node} parent (for determining context for implicit multiplication)
25
- * @return {number | null}
21
+ * @param _node
22
+ * @param parenthesis
23
+ * @param implicit
24
+ * @param parent - (for determining context for implicit multiplication)
26
25
  */
27
26
  export declare function getPrecedence(_node: unknown, parenthesis: string | undefined, implicit: string | undefined, parent: unknown): number | null;
28
27
  /**
@@ -30,20 +29,18 @@ export declare function getPrecedence(_node: unknown, parenthesis: string | unde
30
29
  * Returns a string containing 'left' or 'right' or null if
31
30
  * the associativity is not defined.
32
31
  *
33
- * @param {Node} _node
34
- * @param {string} parenthesis
35
- * @return {string|null}
36
- * @throws {Error}
32
+ * @param _node
33
+ * @param parenthesis
34
+ * @throws Error
37
35
  */
38
36
  export declare function getAssociativity(_node: unknown, parenthesis: string | undefined): 'left' | 'right' | null;
39
37
  /**
40
38
  * Check if an operator is associative with another operator.
41
39
  * Returns either true or false or null if not defined.
42
40
  *
43
- * @param {Node} nodeA
44
- * @param {Node} nodeB
45
- * @param {string} parenthesis
46
- * @return {boolean | null}
41
+ * @param nodeA
42
+ * @param nodeB
43
+ * @param parenthesis
47
44
  */
48
45
  export declare function isAssociativeWith(nodeA: unknown, nodeB: unknown, parenthesis: string | undefined): boolean | null;
49
46
  /**
@@ -52,8 +49,8 @@ export declare function isAssociativeWith(nodeA: unknown, nodeB: unknown, parent
52
49
  * input is not the name of a function associated with an
53
50
  * operator.
54
51
  *
55
- * @param {string} Function name
56
- * @return {string | null} Associated operator symbol, if any
52
+ * @param fn - The function name.
53
+ * @returns Associated operator symbol, if any
57
54
  */
58
55
  export declare function getOperator(fn: string): string | null;
59
56
  //# sourceMappingURL=operators.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"operators.d.ts","sourceRoot":"","sources":["../src/operators.ts"],"names":[],"mappings":"AAqBA;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,aAAa,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAC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