@hyperfixi/core 2.3.0 → 2.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (203) hide show
  1. package/README.md +8 -11
  2. package/dist/api/dom-processor.d.ts +8 -4
  3. package/dist/api/hyperscript-api.d.ts +5 -1
  4. package/dist/ast-utils/index.js +25320 -94
  5. package/dist/ast-utils/index.mjs +25320 -94
  6. package/dist/ast-utils/interchange/types.d.ts +7 -1
  7. package/dist/behaviors/index.js +54 -100
  8. package/dist/behaviors/index.mjs +54 -100
  9. package/dist/bundle-generator/index.js +44 -6
  10. package/dist/bundle-generator/index.mjs +44 -6
  11. package/dist/bundle-generator/parser-templates.d.ts +1 -1
  12. package/dist/bundle-generator/template-capabilities.d.ts +1 -1
  13. package/dist/chunks/bridge-C4d3blZX.js +2 -0
  14. package/dist/chunks/browser-modular-BwIRlrTM.js +2 -0
  15. package/dist/chunks/feature-eventsource-BpZvPy_K.js +2 -0
  16. package/dist/chunks/{feature-sockets-ClOH7vk7.js → feature-sockets-CrYvjZ4j.js} +2 -2
  17. package/dist/chunks/feature-webworker-BSYguEIW.js +2 -0
  18. package/dist/chunks/index-Beno_SBy.js +2 -0
  19. package/dist/commands/advanced/async.d.ts +6 -2
  20. package/dist/commands/advanced/js.d.ts +1 -1
  21. package/dist/commands/animation/start-view-transition.d.ts +24 -0
  22. package/dist/commands/async/fetch.d.ts +6 -1
  23. package/dist/commands/control-flow/repeat.d.ts +2 -0
  24. package/dist/commands/data/clear.d.ts +23 -0
  25. package/dist/commands/data/set.d.ts +6 -0
  26. package/dist/commands/dom/close.d.ts +19 -0
  27. package/dist/commands/dom/empty.d.ts +19 -0
  28. package/dist/commands/dom/open.d.ts +21 -0
  29. package/dist/commands/dom/reset.d.ts +19 -0
  30. package/dist/commands/dom/select.d.ts +19 -0
  31. package/dist/commands/dom/swap.d.ts +7 -4
  32. package/dist/commands/events/trigger.d.ts +1 -1
  33. package/dist/commands/execution/blur.d.ts +19 -0
  34. package/dist/commands/execution/call.d.ts +1 -2
  35. package/dist/commands/execution/focus.d.ts +19 -0
  36. package/dist/commands/helpers/element-resolution.d.ts +2 -2
  37. package/dist/commands/helpers/event-waiting.d.ts +1 -1
  38. package/dist/commands/helpers/numeric-target-parser.d.ts +7 -0
  39. package/dist/commands/index.d.ts +34 -2
  40. package/dist/commands/index.js +19374 -4848
  41. package/dist/commands/index.mjs +19342 -4849
  42. package/dist/commands/navigation/go.d.ts +3 -0
  43. package/dist/commands/navigation/scroll-to.d.ts +26 -0
  44. package/dist/commands/utility/beep.d.ts +2 -2
  45. package/dist/commands/utility/breakpoint.d.ts +19 -0
  46. package/dist/commands/utility/pick.d.ts +11 -2
  47. package/dist/compatibility/browser-bundle-modular.d.ts +2 -2
  48. package/dist/compatibility/browser-bundle-multilingual.d.ts +1 -1
  49. package/dist/compatibility/browser-bundle-semantic-complete.d.ts +3 -3
  50. package/dist/compatibility/browser-bundle.d.ts +13 -6
  51. package/dist/compatibility/browser-modular.d.ts +1 -3
  52. package/dist/core/expression-evaluator.d.ts +4 -4
  53. package/dist/core/expression-registry.d.ts +8 -0
  54. package/dist/expressions/bundles/common-expressions.d.ts +2 -2
  55. package/dist/expressions/bundles/core-expressions.d.ts +2 -2
  56. package/dist/expressions/bundles/full-expressions.d.ts +2 -2
  57. package/dist/expressions/bundles/index.d.ts +3 -3
  58. package/dist/expressions/collection/index.d.ts +35 -0
  59. package/dist/expressions/conversion/impl/index.d.ts +1 -1
  60. package/dist/expressions/index.d.ts +4 -3
  61. package/dist/expressions/index.js +1117 -1590
  62. package/dist/expressions/index.mjs +1113 -1586
  63. package/dist/expressions/logical/index.d.ts +2 -0
  64. package/dist/expressions/mathematical/index.d.ts +11 -0
  65. package/dist/expressions/shared/index.d.ts +1 -1
  66. package/dist/expressions/shared/number-utils.d.ts +1 -0
  67. package/dist/htmx/htmx-attribute-processor.d.ts +37 -1
  68. package/dist/htmx/htmx-translator.d.ts +2 -0
  69. package/dist/htmx/i18n-hooks.d.ts +15 -0
  70. package/dist/htmx/i18n-orchestrator.d.ts +15 -0
  71. package/dist/htmx/lang-resolver.d.ts +3 -0
  72. package/dist/htmx/sse.d.ts +60 -0
  73. package/dist/htmx/ws.d.ts +59 -0
  74. package/dist/hyperfixi-browser-classic-i18n.js +2 -0
  75. package/dist/hyperfixi-browser-minimal.js +1 -0
  76. package/dist/hyperfixi-browser-standard.js +2 -0
  77. package/dist/hyperfixi-browser.js +2 -0
  78. package/dist/hyperfixi-classic-i18n.js +1 -1
  79. package/dist/hyperfixi-hx-v4.js +1 -0
  80. package/dist/hyperfixi-hx.js +1 -1
  81. package/dist/hyperfixi-hybrid-complete.js +1 -1
  82. package/dist/hyperfixi-hybrid-hx.js +1 -0
  83. package/dist/hyperfixi-minimal.js +1 -1
  84. package/dist/hyperfixi-multilingual.js +1 -1
  85. package/dist/hyperfixi-standard.js +1 -1
  86. package/dist/hyperfixi.js +1 -1
  87. package/dist/hyperfixi.mjs +1 -1
  88. package/dist/index.d.ts +2 -0
  89. package/dist/index.js +43613 -45063
  90. package/dist/index.min.js +1 -1
  91. package/dist/index.mjs +43610 -45064
  92. package/dist/lib/index.d.ts +2 -2
  93. package/dist/lib/morph-adapter.d.ts +0 -13
  94. package/dist/lib/swap-executor.d.ts +0 -10
  95. package/dist/lib/view-transitions.d.ts +1 -30
  96. package/dist/lokascript-browser-classic-i18n.js +1 -1
  97. package/dist/lokascript-browser-minimal.js +1 -1
  98. package/dist/lokascript-browser-standard.js +1 -1
  99. package/dist/lokascript-browser.js +1 -1
  100. package/dist/lokascript-hybrid-complete.js +1 -1
  101. package/dist/lokascript-hybrid-hx.js +1 -1
  102. package/dist/lokascript-multilingual.js +1 -1
  103. package/dist/lsp-metadata.d.ts +9 -4
  104. package/dist/lsp-metadata.js +187 -3
  105. package/dist/lsp-metadata.mjs +185 -4
  106. package/dist/metadata.d.ts +1 -1
  107. package/dist/metadata.js +3 -3
  108. package/dist/metadata.mjs +3 -3
  109. package/dist/multilingual/bridge.d.ts +1 -1
  110. package/dist/multilingual/index.js +79 -22
  111. package/dist/multilingual/index.mjs +79 -22
  112. package/dist/parser/command-parsers/animation-commands.d.ts +1 -0
  113. package/dist/parser/command-parsers/utility-commands.d.ts +1 -0
  114. package/dist/parser/extensions.d.ts +51 -0
  115. package/dist/parser/full-parser.js +1224 -899
  116. package/dist/parser/full-parser.mjs +1224 -899
  117. package/dist/parser/helpers/ast-helpers.d.ts +1 -0
  118. package/dist/parser/helpers/parsing-helpers.d.ts +4 -0
  119. package/dist/parser/hybrid/index.js +7 -0
  120. package/dist/parser/hybrid/index.mjs +7 -0
  121. package/dist/parser/hybrid/parser-core.js +7 -0
  122. package/dist/parser/hybrid/parser-core.mjs +7 -0
  123. package/dist/parser/hybrid/tokenizer.js +7 -0
  124. package/dist/parser/hybrid/tokenizer.mjs +7 -0
  125. package/dist/parser/hybrid-parser.js +7 -0
  126. package/dist/parser/hybrid-parser.mjs +7 -0
  127. package/dist/parser/parser-types.d.ts +8 -28
  128. package/dist/parser/parser.d.ts +3 -7
  129. package/dist/parser/pratt-parser.d.ts +0 -3
  130. package/dist/parser/runtime.d.ts +4 -0
  131. package/dist/parser/semantic-integration.d.ts +17 -0
  132. package/dist/parser/types.d.ts +7 -1
  133. package/dist/reference/index.js +91 -0
  134. package/dist/reference/index.mjs +91 -0
  135. package/dist/registry/index.js +12866 -5876
  136. package/dist/registry/index.mjs +12866 -5876
  137. package/dist/registry/universal-types.d.ts +2 -1
  138. package/dist/runtime/command-adapter.d.ts +23 -16
  139. package/dist/runtime/plugin.d.ts +14 -0
  140. package/dist/runtime/runtime-base.d.ts +32 -7
  141. package/dist/runtime/runtime-factory.d.ts +3 -3
  142. package/dist/runtime/runtime.d.ts +2 -2
  143. package/dist/test-setup.d.ts +1 -0
  144. package/dist/types/base-types.d.ts +3 -0
  145. package/dist/types/feature-types.d.ts +1 -1
  146. package/dist/types/index.d.ts +2 -2
  147. package/package.json +26 -20
  148. package/vocab/htmx/ar.js +60 -0
  149. package/vocab/htmx/bn.js +49 -0
  150. package/vocab/htmx/de.js +60 -0
  151. package/vocab/htmx/en.js +21 -0
  152. package/vocab/htmx/es.js +60 -0
  153. package/vocab/htmx/fr.js +59 -0
  154. package/vocab/htmx/he.js +40 -0
  155. package/vocab/htmx/hi.js +60 -0
  156. package/vocab/htmx/id.js +57 -0
  157. package/vocab/htmx/it.js +58 -0
  158. package/vocab/htmx/ja.js +60 -0
  159. package/vocab/htmx/ko.js +60 -0
  160. package/vocab/htmx/ms.js +35 -0
  161. package/vocab/htmx/pl.js +60 -0
  162. package/vocab/htmx/pt.js +60 -0
  163. package/vocab/htmx/qu.js +60 -0
  164. package/vocab/htmx/ru.js +60 -0
  165. package/vocab/htmx/sw.js +59 -0
  166. package/vocab/htmx/th.js +49 -0
  167. package/vocab/htmx/tl.js +33 -0
  168. package/vocab/htmx/tr.js +60 -0
  169. package/vocab/htmx/uk.js +60 -0
  170. package/vocab/htmx/vi.js +51 -0
  171. package/vocab/htmx/zh.js +60 -0
  172. package/dist/bundles/test-minimal.d.ts +0 -3
  173. package/dist/bundles/test-standard.d.ts +0 -3
  174. package/dist/chunks/bridge-BlRqsZT4.js +0 -2
  175. package/dist/chunks/browser-modular-AbV0Ql4i.js +0 -2
  176. package/dist/chunks/feature-eventsource-B5F2-H1r.js +0 -2
  177. package/dist/chunks/feature-webworker-3bAp0ac9.js +0 -2
  178. package/dist/chunks/index-BDYQHwCF.js +0 -2
  179. package/dist/compatibility/browser-bundle-minimal.d.ts +0 -8
  180. package/dist/compatibility/browser-bundle-standard.d.ts +0 -8
  181. package/dist/compatibility/hyperscript-tests/test-adapter.d.ts +0 -13
  182. package/dist/core/base-expression-evaluator.d.ts +0 -74
  183. package/dist/core/binary-expression-evaluator.d.ts +0 -7
  184. package/dist/core/call-expression-evaluator.d.ts +0 -7
  185. package/dist/core/configurable-expression-evaluator.d.ts +0 -5
  186. package/dist/core/lazy-expression-evaluator.d.ts +0 -22
  187. package/dist/core/parser.d.ts +0 -21
  188. package/dist/core/selector-evaluator.d.ts +0 -15
  189. package/dist/core/template-literal-evaluator.d.ts +0 -5
  190. package/dist/expressions/comparison/index.d.ts +0 -80
  191. package/dist/expressions/comparison/utils.d.ts +0 -2
  192. package/dist/expressions/conversion/impl/bridge.d.ts +0 -117
  193. package/dist/expressions/logical/impl/pattern-matching.d.ts +0 -58
  194. package/dist/expressions/positional/impl/bridge.d.ts +0 -95
  195. package/dist/expressions/property/index.d.ts +0 -55
  196. package/dist/expressions/references/impl/bridge.d.ts +0 -54
  197. package/dist/extensions/index.d.ts +0 -3
  198. package/dist/extensions/tailwind.d.ts +0 -22
  199. package/dist/mod.d.ts +0 -63
  200. package/dist/parser/expression-parser.d.ts +0 -6
  201. package/dist/runtime/runtime-experimental.d.ts +0 -18
  202. package/dist/scripts/code-generator.d.ts +0 -64
  203. package/dist/scripts/generate-missing-commands.d.ts +0 -4
@@ -18,6 +18,9 @@ export declare class GoCommand implements DecoratedCommand {
18
18
  }, evaluator: ExpressionEvaluator, context: ExecutionContext): Promise<GoCommandInput>;
19
19
  execute(input: GoCommandInput, context: TypedExecutionContext): Promise<GoCommandOutput>;
20
20
  private isUrlNavigation;
21
+ private isBareUrl;
22
+ private findBareUrl;
23
+ private navigateToBareUrl;
21
24
  private goBack;
22
25
  private navigateToUrl;
23
26
  private isValidUrl;
@@ -0,0 +1,26 @@
1
+ import type { ExecutionContext, TypedExecutionContext } from '../../types/core';
2
+ import type { ASTNode, ExpressionNode } from '../../types/base-types';
3
+ import type { ExpressionEvaluator } from '../../core/expression-evaluator';
4
+ import { type DecoratedCommand, type CommandMetadata } from '../decorators';
5
+ export interface ScrollCommandInput {
6
+ args: unknown[];
7
+ }
8
+ export interface ScrollCommandOutput {
9
+ element: HTMLElement;
10
+ position: ScrollLogicalPosition;
11
+ smooth: boolean;
12
+ }
13
+ export declare class ScrollCommand implements DecoratedCommand {
14
+ readonly name: string;
15
+ readonly metadata: CommandMetadata;
16
+ parseInput(raw: {
17
+ args: ASTNode[];
18
+ modifiers: Record<string, ExpressionNode>;
19
+ }, evaluator: ExpressionEvaluator, context: ExecutionContext): Promise<ScrollCommandInput>;
20
+ execute(input: ScrollCommandInput, context: TypedExecutionContext): Promise<ScrollCommandOutput>;
21
+ private parsePosition;
22
+ private resolveTarget;
23
+ }
24
+ export declare const createScrollCommand: () => ScrollCommand;
25
+ export default ScrollCommand;
26
+ //# sourceMappingURL=scroll-to.d.ts.map
@@ -3,13 +3,13 @@ import type { ASTNode, ExpressionNode } from '../../types/base-types';
3
3
  import type { ExpressionEvaluator } from '../../core/expression-evaluator';
4
4
  import { type DecoratedCommand, type CommandMetadata } from '../decorators';
5
5
  export interface BeepCommandInput {
6
- expressions?: any[];
6
+ expressions?: unknown[];
7
7
  }
8
8
  export interface BeepCommandOutput {
9
9
  expressionCount: number;
10
10
  debugged: boolean;
11
11
  outputs: Array<{
12
- value: any;
12
+ value: unknown;
13
13
  type: string;
14
14
  representation: string;
15
15
  }>;
@@ -0,0 +1,19 @@
1
+ import type { ExecutionContext, TypedExecutionContext, ASTNode, ExpressionNode } from '../../types/base-types';
2
+ import type { ExpressionEvaluator } from '../../core/expression-evaluator';
3
+ import { type DecoratedCommand, type CommandMetadata } from '../decorators';
4
+ export interface BreakpointCommandInput {
5
+ _tag?: 'breakpoint';
6
+ }
7
+ export declare class BreakpointCommand implements DecoratedCommand {
8
+ readonly name: string;
9
+ readonly metadata: CommandMetadata;
10
+ parseInput(_raw: {
11
+ args: ASTNode[];
12
+ modifiers: Record<string, ExpressionNode>;
13
+ }, _evaluator: ExpressionEvaluator, _context: ExecutionContext): Promise<BreakpointCommandInput>;
14
+ execute(_input: BreakpointCommandInput, _context: TypedExecutionContext): Promise<void>;
15
+ validate(input: unknown): input is BreakpointCommandInput;
16
+ }
17
+ export declare const createBreakpointCommand: () => BreakpointCommand;
18
+ export default BreakpointCommand;
19
+ //# sourceMappingURL=breakpoint.d.ts.map
@@ -3,14 +3,23 @@ import type { ASTNode, ExpressionNode } from '../../types/base-types';
3
3
  import type { ExpressionEvaluator } from '../../core/expression-evaluator';
4
4
  import { type DecoratedCommand, type CommandMetadata } from '../decorators';
5
5
  export interface PickCommandInput {
6
+ variant?: 'first' | 'last' | 'random' | 'range' | 'match' | 'matches';
6
7
  items?: unknown[];
7
8
  array?: unknown[];
9
+ count?: number;
10
+ rangeStart?: number | 'start';
11
+ rangeEnd?: number | 'end';
12
+ rangeMode?: 'default' | 'inclusive' | 'exclusive';
13
+ source?: string;
14
+ regex?: string;
15
+ flags?: string;
8
16
  }
9
17
  export interface PickCommandOutput {
10
18
  selectedItem: unknown;
11
- selectedIndex: number;
19
+ selectedIndex?: number;
12
20
  sourceLength: number;
13
- sourceType: 'items' | 'array';
21
+ sourceType: 'items' | 'array' | 'string';
22
+ variant: PickCommandInput['variant'];
14
23
  }
15
24
  export declare class PickCommand implements DecoratedCommand {
16
25
  readonly name: string;
@@ -1,5 +1,5 @@
1
1
  import { createRuntime, type LokaScriptRuntime } from '../runtime/runtime-factory';
2
- import { ConfigurableExpressionEvaluator } from '../core/configurable-expression-evaluator';
2
+ import { createExpressionRegistry } from '../core/expression-registry';
3
3
  declare const hyperfixi: LokaScriptRuntime;
4
4
  declare const api: {
5
5
  version: string;
@@ -14,5 +14,5 @@ declare const api: {
14
14
  };
15
15
  declare function processElements(root?: Element | Document): void;
16
16
  export default api;
17
- export { hyperfixi, api, processElements, createRuntime, ConfigurableExpressionEvaluator, };
17
+ export { hyperfixi, api, processElements, createRuntime, createExpressionRegistry, };
18
18
  //# sourceMappingURL=browser-bundle-modular.d.ts.map
@@ -6,7 +6,7 @@ declare const api: {
6
6
  translate(code: string, sourceLang: string, targetLang: string): string;
7
7
  getAllTranslations(code: string, sourceLang: string): Record<string, string>;
8
8
  createContext: typeof createContext;
9
- runtime: import("../runtime/runtime-experimental").RuntimeExperimental;
9
+ runtime: import("..").RuntimeBase;
10
10
  version: string;
11
11
  commands: readonly ["hide", "show", "add", "remove", "toggle", "put", "make", "wait", "fetch", "set", "get", "increment", "decrement", "default", "trigger", "send", "go", "if", "repeat", "break", "continue", "halt", "return", "exit", "unless", "throw", "call", "pseudo-command", "append", "transition", "measure", "settle", "take", "js", "async", "log", "tell", "copy", "pick", "beep", "install", "render"];
12
12
  supportedLanguages: readonly ["en", "ja", "ar", "es", "ko", "zh", "tr", "pt", "fr", "de", "id", "qu", "sw"];
@@ -1,6 +1,6 @@
1
1
  import { createContext } from '../core/context';
2
2
  import type { ASTNode } from '../types/base-types';
3
- import { getSupportedLanguages } from '@lokascript/semantic';
3
+ import { parseSemantic, getSupportedLanguages } from '@lokascript/semantic';
4
4
  declare const api: {
5
5
  execute(code: string, lang: string, context?: any): Promise<any>;
6
6
  parse(code: string, lang: string): ASTNode | null;
@@ -10,8 +10,8 @@ declare const api: {
10
10
  isLanguageSupported(lang: string): boolean;
11
11
  getTokenizer(lang: string): import("@lokascript/semantic").LanguageTokenizer | undefined;
12
12
  createContext: typeof createContext;
13
- runtime: import("../runtime/runtime-experimental").RuntimeExperimental;
14
- analyzer: import("@lokascript/semantic").SemanticAnalyzer;
13
+ runtime: import("..").RuntimeBase;
14
+ parseSemantic: typeof parseSemantic;
15
15
  version: string;
16
16
  semanticVersion: string;
17
17
  commands: readonly ["hide", "show", "add", "remove", "toggle", "put", "make", "wait", "fetch", "set", "get", "increment", "decrement", "default", "trigger", "send", "go", "if", "repeat", "break", "continue", "halt", "return", "exit", "unless", "throw", "call", "pseudo-command", "append", "transition", "measure", "settle", "take", "js", "async", "log", "tell", "copy", "pick", "beep", "install", "render"];
@@ -2,22 +2,22 @@ import { evalHyperScript, evalHyperScriptAsync, evalHyperScriptSmart } from './e
2
2
  import { hyperscript, config } from '../api/lokascript-api';
3
3
  import type { RuntimeHooks } from '../types/hooks';
4
4
  import { defaultAttributeProcessor } from '../dom/attribute-processor';
5
- import { tailwindExtension } from '../extensions/tailwind';
6
5
  import { Parser } from '../parser/parser';
7
6
  import { Runtime } from '../runtime/runtime';
8
7
  import { tokenize } from '../parser/tokenizer';
9
8
  import { debug, debugControl } from '../utils/debug';
10
9
  import { styleBatcher, ObjectPool } from '../utils/performance';
11
10
  import { enableDebugEvents, disableDebugEvents, isDebugEnabled, getDebugStats, resetDebugStats, getEventHistory, replayEvents } from '../utils/debug-events';
12
- import { createSemanticAnalyzer, parse as semanticParse, translate, render, toExplicit, fromExplicit } from '@lokascript/semantic';
11
+ import { parseSemantic, parse as semanticParse, translate, render, toExplicit, fromExplicit } from '@lokascript/semantic';
13
12
  import type { LokaScriptRegistry } from '../registry';
14
13
  import { registerFetchResponseType } from '../commands/async/fetch';
14
+ import { installPlugin } from '../runtime/plugin';
15
+ import { getParserExtensionRegistry } from '../parser/extensions';
15
16
  import type { CompileResult, NewCompileOptions } from '../api/hyperscript-api';
16
17
  interface HyperFixiBrowserAPI {
17
18
  evalHyperScript: typeof evalHyperScript;
18
19
  evalHyperScriptAsync: typeof evalHyperScriptAsync;
19
20
  evalHyperScriptSmart: typeof evalHyperScriptSmart;
20
- tailwindExtension: typeof tailwindExtension;
21
21
  compile: (code: string, options?: NewCompileOptions) => CompileResult;
22
22
  compileSync: (code: string, options?: NewCompileOptions) => CompileResult;
23
23
  compileMultilingual: (code: string, language: string) => Promise<CompileResult>;
@@ -30,13 +30,15 @@ interface HyperFixiBrowserAPI {
30
30
  Parser: typeof Parser;
31
31
  Runtime: typeof Runtime;
32
32
  tokenize: typeof tokenize;
33
+ installPlugin: typeof installPlugin;
34
+ getParserExtensionRegistry: typeof getParserExtensionRegistry;
33
35
  attributeProcessor: typeof defaultAttributeProcessor;
34
36
  debug: typeof debug;
35
37
  debugControl: typeof debugControl;
36
38
  styleBatcher: typeof styleBatcher;
37
39
  ObjectPool: typeof ObjectPool;
38
40
  semantic: {
39
- createAnalyzer: typeof createSemanticAnalyzer;
41
+ parseSemantic: typeof parseSemantic;
40
42
  parse: typeof semanticParse;
41
43
  translate: typeof translate;
42
44
  render: typeof render;
@@ -57,8 +59,10 @@ interface HyperFixiBrowserAPI {
57
59
  registerHooks: (name: string, hooks: RuntimeHooks) => void;
58
60
  unregisterHooks: (name: string) => boolean;
59
61
  getRegisteredHooks: () => string[];
62
+ getDefaultRuntime: typeof hyperscript.getDefaultRuntime;
60
63
  registry: LokaScriptRegistry;
61
64
  registerFetchResponseType: typeof registerFetchResponseType;
65
+ evalLSENode(node: import('@lokascript/framework').SemanticNode, element?: Element): Promise<unknown>;
62
66
  }
63
67
  declare global {
64
68
  interface Window {
@@ -84,10 +88,11 @@ declare const hyperfixiAPI: {
84
88
  Parser: typeof Parser;
85
89
  Runtime: typeof Runtime;
86
90
  tokenize: typeof tokenize;
91
+ installPlugin: typeof installPlugin;
92
+ getParserExtensionRegistry: typeof getParserExtensionRegistry;
87
93
  processNode: (element: Element | Document) => Promise<void>;
88
94
  process: (element: Element | Document) => Promise<void>;
89
95
  attributeProcessor: import("../dom/attribute-processor").AttributeProcessor;
90
- tailwindExtension: import("../extensions/tailwind").TailwindExtension;
91
96
  styleBatcher: import("../utils/performance").StyleBatcher;
92
97
  ObjectPool: typeof ObjectPool;
93
98
  debug: {
@@ -111,7 +116,7 @@ declare const hyperfixiAPI: {
111
116
  };
112
117
  };
113
118
  semantic: {
114
- createAnalyzer: typeof createSemanticAnalyzer;
119
+ parseSemantic: typeof parseSemantic;
115
120
  parse: typeof semanticParse;
116
121
  translate: typeof translate;
117
122
  render: typeof render;
@@ -132,8 +137,10 @@ declare const hyperfixiAPI: {
132
137
  registerHooks: (name: string, hooks: RuntimeHooks) => void;
133
138
  unregisterHooks: (name: string) => boolean;
134
139
  getRegisteredHooks: () => string[];
140
+ getDefaultRuntime: () => Runtime;
135
141
  registry: LokaScriptRegistry;
136
142
  registerFetchResponseType: typeof registerFetchResponseType;
143
+ evalLSENode: (node: import("@lokascript/framework").SemanticNode, element?: Element) => Promise<unknown>;
137
144
  version: string;
138
145
  };
139
146
  export default hyperfixiAPI;
@@ -1,7 +1,6 @@
1
1
  import { evalHyperScript, evalHyperScriptAsync, evalHyperScriptSmart } from './eval-hyperscript';
2
2
  import { hyperscript } from '../api/hyperscript-api';
3
3
  import { defaultAttributeProcessor } from '../dom/attribute-processor';
4
- import { tailwindExtension } from '../extensions/tailwind';
5
4
  import { Parser } from '../parser/parser';
6
5
  import { Runtime } from '../runtime/runtime';
7
6
  import { tokenize } from '../parser/tokenizer';
@@ -24,7 +23,6 @@ declare const hyperfixi: {
24
23
  processNode: (element: Element | Document) => Promise<void>;
25
24
  process: (element: Element | Document) => Promise<void>;
26
25
  attributeProcessor: import("../dom/attribute-processor").AttributeProcessor;
27
- tailwindExtension: import("../extensions/tailwind").TailwindExtension;
28
26
  styleBatcher: import("../utils/performance").StyleBatcher;
29
27
  ObjectPool: typeof ObjectPool;
30
28
  debug: {
@@ -48,6 +46,6 @@ declare const hyperfixi: {
48
46
  };
49
47
  version: string;
50
48
  };
51
- export { evalHyperScript, evalHyperScriptAsync, evalHyperScriptSmart, hyperscript, Parser, Runtime, tokenize, defaultAttributeProcessor, tailwindExtension, debug, styleBatcher, ObjectPool, preloadDocumentFeatures, loadRequiredFeatures, detectFeatures, isFeatureLoaded, getLoadedFeatures, preloadFeatures, };
49
+ export { evalHyperScript, evalHyperScriptAsync, evalHyperScriptSmart, hyperscript, Parser, Runtime, tokenize, defaultAttributeProcessor, debug, styleBatcher, ObjectPool, preloadDocumentFeatures, loadRequiredFeatures, detectFeatures, isFeatureLoaded, getLoadedFeatures, preloadFeatures, };
52
50
  export default hyperfixi;
53
51
  //# sourceMappingURL=browser-modular.d.ts.map
@@ -1,6 +1,6 @@
1
- import { BaseExpressionEvaluator } from './base-expression-evaluator';
2
- export declare class ExpressionEvaluator extends BaseExpressionEvaluator {
3
- constructor();
4
- private registerExpressions;
1
+ import type { ASTNode } from '../types/base-types';
2
+ import type { ExecutionContext } from '../types/core';
3
+ export interface ExpressionEvaluator {
4
+ evaluate(node: ASTNode, context: ExecutionContext): Promise<any>;
5
5
  }
6
6
  //# sourceMappingURL=expression-evaluator.d.ts.map
@@ -0,0 +1,8 @@
1
+ import type { ExpressionImplementation } from '../types/core';
2
+ export type ExpressionRegistry = ReadonlyMap<string, ExpressionImplementation>;
3
+ interface ExpressionLike {
4
+ evaluate: (...args: any[]) => any;
5
+ }
6
+ export declare function createExpressionRegistry(...categories: ReadonlyArray<Readonly<Record<string, ExpressionLike>>>): ExpressionRegistry;
7
+ export {};
8
+ //# sourceMappingURL=expression-registry.d.ts.map
@@ -1,9 +1,9 @@
1
- import { ConfigurableExpressionEvaluator } from '../../core/configurable-expression-evaluator';
1
+ import type { ExpressionRegistry } from '../../core/expression-registry';
2
2
  import { referencesExpressions } from '../references/index';
3
3
  import { logicalExpressions } from '../logical/index';
4
4
  import { specialExpressions } from '../special/index';
5
5
  import { conversionExpressions } from '../conversion/index';
6
6
  import { positionalExpressions } from '../positional/index';
7
- export declare function createCommonExpressionEvaluator(): ConfigurableExpressionEvaluator;
7
+ export declare function createCommonRegistry(): ExpressionRegistry;
8
8
  export { referencesExpressions, logicalExpressions, specialExpressions, conversionExpressions, positionalExpressions, };
9
9
  //# sourceMappingURL=common-expressions.d.ts.map
@@ -1,7 +1,7 @@
1
- import { ConfigurableExpressionEvaluator } from '../../core/configurable-expression-evaluator';
1
+ import type { ExpressionRegistry } from '../../core/expression-registry';
2
2
  import { referencesExpressions } from '../references/index';
3
3
  import { logicalExpressions } from '../logical/index';
4
4
  import { specialExpressions } from '../special/index';
5
- export declare function createCoreExpressionEvaluator(): ConfigurableExpressionEvaluator;
5
+ export declare function createCoreRegistry(): ExpressionRegistry;
6
6
  export { referencesExpressions, logicalExpressions, specialExpressions };
7
7
  //# sourceMappingURL=core-expressions.d.ts.map
@@ -1,10 +1,10 @@
1
- import { ConfigurableExpressionEvaluator } from '../../core/configurable-expression-evaluator';
1
+ import type { ExpressionRegistry } from '../../core/expression-registry';
2
2
  import { referencesExpressions } from '../references/index';
3
3
  import { logicalExpressions } from '../logical/index';
4
4
  import { specialExpressions } from '../special/index';
5
5
  import { conversionExpressions } from '../conversion/index';
6
6
  import { positionalExpressions } from '../positional/index';
7
7
  import { propertiesExpressions } from '../properties/index';
8
- export declare function createFullExpressionEvaluator(): ConfigurableExpressionEvaluator;
8
+ export declare function createFullRegistry(): ExpressionRegistry;
9
9
  export { referencesExpressions, logicalExpressions, specialExpressions, conversionExpressions, positionalExpressions, propertiesExpressions, };
10
10
  //# sourceMappingURL=full-expressions.d.ts.map
@@ -1,6 +1,6 @@
1
- export { createCoreExpressionEvaluator } from './core-expressions';
2
- export { createCommonExpressionEvaluator } from './common-expressions';
3
- export { createFullExpressionEvaluator } from './full-expressions';
1
+ export { createCoreRegistry } from './core-expressions';
2
+ export { createCommonRegistry } from './common-expressions';
3
+ export { createFullRegistry } from './full-expressions';
4
4
  export { referencesExpressions, logicalExpressions, specialExpressions } from './core-expressions';
5
5
  export { conversionExpressions, positionalExpressions } from './common-expressions';
6
6
  export { propertiesExpressions } from './full-expressions';
@@ -0,0 +1,35 @@
1
+ import type { ExpressionImplementation } from '../../types/core';
2
+ import type { ASTNode } from '../../types/base-types';
3
+ export type CollectionOperator = 'where' | 'sorted by' | 'mapped to' | 'split by' | 'joined by';
4
+ export type SortOrder = 'asc' | 'desc';
5
+ export interface CollectionExpressionNode {
6
+ type: 'collectionExpression';
7
+ operator: CollectionOperator;
8
+ collection: ASTNode;
9
+ right: ASTNode;
10
+ order?: SortOrder;
11
+ start?: number;
12
+ end?: number;
13
+ line?: number;
14
+ column?: number;
15
+ }
16
+ export declare function toIterableArray(value: unknown): unknown[];
17
+ export declare function evaluateWhere(collection: unknown, predicate: ASTNode, evalWithIt: (node: ASTNode, it: unknown) => Promise<unknown>): Promise<unknown[]>;
18
+ export declare function evaluateSortedBy(collection: unknown, keyExpr: ASTNode, order: SortOrder, evalWithIt: (node: ASTNode, it: unknown) => Promise<unknown>): Promise<unknown[]>;
19
+ export declare function evaluateMappedTo(collection: unknown, expr: ASTNode, evalWithIt: (node: ASTNode, it: unknown) => Promise<unknown>): Promise<unknown[]>;
20
+ export declare function evaluateSplitBy(value: unknown, separator: unknown): string[];
21
+ export declare function evaluateJoinedBy(value: unknown, separator: unknown): string;
22
+ export declare const whereExpression: ExpressionImplementation;
23
+ export declare const sortedByExpression: ExpressionImplementation;
24
+ export declare const mappedToExpression: ExpressionImplementation;
25
+ export declare const splitByExpression: ExpressionImplementation;
26
+ export declare const joinedByExpression: ExpressionImplementation;
27
+ export declare const collectionExpressions: {
28
+ readonly where: ExpressionImplementation;
29
+ readonly sortedBy: ExpressionImplementation;
30
+ readonly mappedTo: ExpressionImplementation;
31
+ readonly splitBy: ExpressionImplementation;
32
+ readonly joinedBy: ExpressionImplementation;
33
+ };
34
+ export type CollectionExpressionName = keyof typeof collectionExpressions;
35
+ //# sourceMappingURL=index.d.ts.map
@@ -2,7 +2,7 @@ import { type RuntimeValidator } from '../../../validation/lightweight-validator
2
2
  import type { TypedExpressionContext, EvaluationResult, ExpressionMetadata, BaseTypedExpression, ValidationResult, EvaluationType } from '../../../types/base-types';
3
3
  import type { ExpressionCategory, LLMDocumentation } from '../../../types/expression-types';
4
4
  import { BaseExpressionImpl } from '../../base-expression';
5
- export type SupportedConversionType = 'Array' | 'Boolean' | 'Date' | 'Float' | 'Fragment' | 'HTML' | 'Int' | 'JSON' | 'Number' | 'Object' | 'String' | 'Values' | 'Values:Form' | 'Values:JSON' | `Fixed:${number}` | string;
5
+ export type SupportedConversionType = 'Array' | 'Boolean' | 'Date' | 'Float' | 'Fragment' | 'FormEncoded' | 'HTML' | 'Int' | 'JSON' | 'JSONString' | 'Number' | 'Object' | 'String' | 'Values' | 'Values:Form' | 'Values:JSON' | `Fixed:${number}` | string;
6
6
  export interface EnhancedTypeConverter<T = unknown> {
7
7
  (value: unknown, context: TypedExpressionContext): EvaluationResult<T>;
8
8
  }
@@ -4,8 +4,9 @@ export { specialExpressions as special } from './bundles/core-expressions';
4
4
  export { conversionExpressions as conversion } from './bundles/common-expressions';
5
5
  export { positionalExpressions as positional } from './bundles/common-expressions';
6
6
  export { propertiesExpressions as properties } from './bundles/full-expressions';
7
- export { createCoreExpressionEvaluator, createCommonExpressionEvaluator, createFullExpressionEvaluator, } from './bundles';
8
- export { ConfigurableExpressionEvaluator } from '../core/configurable-expression-evaluator';
9
- export { BaseExpressionEvaluator } from '../core/base-expression-evaluator';
7
+ export { createCoreRegistry, createCommonRegistry, createFullRegistry } from './bundles';
8
+ export declare function createFullExpressionRegistry(): import("../core/expression-registry").ExpressionRegistry;
9
+ export { createExpressionRegistry } from '../core/expression-registry';
10
+ export type { ExpressionRegistry } from '../core/expression-registry';
10
11
  export * from './bundles';
11
12
  //# sourceMappingURL=index.d.ts.map