@almadar/ui 5.76.7 → 5.78.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 (70) hide show
  1. package/dist/avl/index.cjs +1121 -535
  2. package/dist/avl/index.css +3 -3
  3. package/dist/avl/index.js +1122 -536
  4. package/dist/components/core/atoms/FlipContainer.d.ts +1 -1
  5. package/dist/components/core/atoms/index.d.ts +2 -1
  6. package/dist/components/core/molecules/Card.d.ts +1 -1
  7. package/dist/components/core/molecules/DataGrid.d.ts +1 -1
  8. package/dist/components/core/molecules/DataList.d.ts +1 -1
  9. package/dist/components/core/molecules/DocPagination.d.ts +1 -8
  10. package/dist/components/core/molecules/DocSearch.d.ts +1 -8
  11. package/dist/components/core/molecules/FlipCard.d.ts +1 -1
  12. package/dist/components/core/molecules/MapView.d.ts +1 -18
  13. package/dist/components/core/molecules/SortableList.d.ts +1 -1
  14. package/dist/components/core/molecules/TableView.d.ts +1 -1
  15. package/dist/components/core/molecules/index.d.ts +4 -0
  16. package/dist/components/core/organisms/DataTable.d.ts +1 -1
  17. package/dist/components/core/organisms/debug/RuntimeDebugger.d.ts +1 -10
  18. package/dist/components/core/organisms/debug/tabs/EntitiesTab.d.ts +1 -2
  19. package/dist/components/core/organisms/debug/tabs/EventDispatcherTab.d.ts +1 -2
  20. package/dist/components/core/organisms/debug/tabs/EventFlowTab.d.ts +1 -6
  21. package/dist/components/core/organisms/debug/tabs/GuardsPanel.d.ts +1 -6
  22. package/dist/components/core/organisms/debug/tabs/ServerBridgeTab.d.ts +1 -12
  23. package/dist/components/core/organisms/debug/tabs/TicksTab.d.ts +1 -2
  24. package/dist/components/core/organisms/debug/tabs/TraitsTab.d.ts +1 -2
  25. package/dist/components/core/organisms/debug/tabs/TransitionTimeline.d.ts +1 -11
  26. package/dist/components/core/organisms/debug/tabs/VerificationTab.d.ts +1 -8
  27. package/dist/components/game/2d/atoms/ActionButton.d.ts +1 -2
  28. package/dist/components/game/2d/atoms/ChoiceButton.d.ts +1 -2
  29. package/dist/components/game/2d/atoms/ComboCounter.d.ts +1 -2
  30. package/dist/components/game/2d/atoms/ControlButton.d.ts +1 -2
  31. package/dist/components/game/2d/atoms/DamageNumber.d.ts +1 -2
  32. package/dist/components/game/2d/atoms/DialogueBubble.d.ts +1 -2
  33. package/dist/components/game/2d/atoms/GameIcon.d.ts +1 -2
  34. package/dist/components/game/2d/atoms/HealthBar.d.ts +1 -2
  35. package/dist/components/game/2d/atoms/ItemSlot.d.ts +1 -2
  36. package/dist/components/game/2d/atoms/MiniMap.d.ts +1 -2
  37. package/dist/components/game/2d/atoms/ResourceCounter.d.ts +1 -2
  38. package/dist/components/game/2d/atoms/ScoreDisplay.d.ts +1 -2
  39. package/dist/components/game/2d/atoms/StatusEffect.d.ts +1 -2
  40. package/dist/components/game/2d/atoms/TimerDisplay.d.ts +1 -2
  41. package/dist/components/game/2d/atoms/TurnIndicator.d.ts +1 -2
  42. package/dist/components/game/2d/atoms/WaypointMarker.d.ts +1 -2
  43. package/dist/components/game/2d/molecules/GameHud.d.ts +1 -2
  44. package/dist/components/game/2d/molecules/GameMenu.d.ts +1 -2
  45. package/dist/components/game/2d/molecules/InventoryGrid.d.ts +1 -2
  46. package/dist/components/game/2d/molecules/ResourceBar.d.ts +1 -2
  47. package/dist/components/game/2d/molecules/StatBadge.d.ts +1 -2
  48. package/dist/components/game/shared/lib/editorUtils.d.ts +8 -8
  49. package/dist/components/index.cjs +2334 -1653
  50. package/dist/components/index.css +3 -3
  51. package/dist/components/index.js +1124 -443
  52. package/dist/components/learning/atoms/LearningCanvas.d.ts +80 -0
  53. package/dist/components/learning/molecules/BiologyCanvas.d.ts +47 -0
  54. package/dist/components/learning/molecules/ChemistryCanvas.d.ts +55 -0
  55. package/dist/components/learning/molecules/MathCanvas.d.ts +61 -0
  56. package/dist/components/learning/molecules/PhysicsCanvas.d.ts +54 -0
  57. package/dist/components/marketing/atoms/MarketingStatCard.d.ts +2 -2
  58. package/dist/hooks/useGitHub.d.ts +7 -7
  59. package/dist/marketing/index.cjs +2 -2
  60. package/dist/marketing/index.js +2 -2
  61. package/dist/providers/EventBusProvider.d.ts +1 -1
  62. package/dist/providers/SelectionProvider.d.ts +1 -1
  63. package/dist/providers/ServerBridge.d.ts +1 -1
  64. package/dist/providers/index.cjs +1117 -531
  65. package/dist/providers/index.css +3 -3
  66. package/dist/providers/index.js +1118 -532
  67. package/dist/runtime/index.cjs +1117 -531
  68. package/dist/runtime/index.css +3 -3
  69. package/dist/runtime/index.js +1118 -532
  70. package/package.json +2 -2
@@ -0,0 +1,80 @@
1
+ /**
2
+ * LearningCanvas
3
+ *
4
+ * A pure, declarative HTML5 canvas atom for math and science visualizations.
5
+ * Accepts a list of primitive shapes (line, arrow, circle, rect, polygon, path,
6
+ * text, axis, grid) and renders them. Optional interactivity emits click/hover
7
+ * events, and optional animation drives a continuous render loop.
8
+ *
9
+ * This is the foundational atom for the `learning/` behavior family.
10
+ *
11
+ * @packageDocumentation
12
+ */
13
+ import * as React from 'react';
14
+ import type { UiError } from '../../core/atoms/types';
15
+ export type LearningShapeType = 'line' | 'arrow' | 'circle' | 'rect' | 'polygon' | 'path' | 'text' | 'axis' | 'grid';
16
+ export interface LearningPoint {
17
+ x: number;
18
+ y: number;
19
+ }
20
+ export interface LearningShape {
21
+ type: LearningShapeType;
22
+ /** Optional stable id for interaction payloads. */
23
+ id?: string;
24
+ x?: number;
25
+ y?: number;
26
+ x1?: number;
27
+ y1?: number;
28
+ x2?: number;
29
+ y2?: number;
30
+ radius?: number;
31
+ width?: number;
32
+ height?: number;
33
+ points?: LearningPoint[];
34
+ path?: string;
35
+ text?: string;
36
+ label?: string;
37
+ fontSize?: number;
38
+ align?: 'left' | 'center' | 'right';
39
+ axis?: 'x' | 'y';
40
+ min?: number;
41
+ max?: number;
42
+ step?: number;
43
+ color?: string;
44
+ fill?: string;
45
+ lineWidth?: number;
46
+ opacity?: number;
47
+ }
48
+ export interface LearningCanvasProps {
49
+ /** Additional CSS classes. */
50
+ className?: string;
51
+ /** Canvas width in CSS pixels. */
52
+ width?: number;
53
+ /** Canvas height in CSS pixels. */
54
+ height?: number;
55
+ /** Background color (default transparent). */
56
+ backgroundColor?: string;
57
+ /** Declarative shapes to draw. */
58
+ shapes?: LearningShape[];
59
+ /** Enable pointer interaction (click/hover). */
60
+ interactive?: boolean;
61
+ /** Enable continuous redraw loop. */
62
+ animate?: boolean;
63
+ /** Clicked shape payload: { id?, type?, index }. */
64
+ onShapeClick?: (payload: {
65
+ id?: string;
66
+ type?: string;
67
+ index: number;
68
+ }) => void;
69
+ /** Hovered shape payload: { id?, type?, index }. */
70
+ onShapeHover?: (payload: {
71
+ id?: string;
72
+ type?: string;
73
+ index: number;
74
+ }) => void;
75
+ /** Loading state. */
76
+ isLoading?: boolean;
77
+ /** Error state. */
78
+ error?: UiError | null;
79
+ }
80
+ export declare const LearningCanvas: React.FC<LearningCanvasProps>;
@@ -0,0 +1,47 @@
1
+ /**
2
+ * BiologyCanvas
3
+ *
4
+ * A field-scoped learning molecule for biology. Renders cells, organelles,
5
+ * membranes, and connections on top of the declarative `LearningCanvas` atom.
6
+ *
7
+ * @packageDocumentation
8
+ */
9
+ import * as React from 'react';
10
+ import type { LearningShape } from '../atoms/LearningCanvas';
11
+ import type { UiError } from '../../core/atoms/types';
12
+ export interface BiologyNode {
13
+ id?: string;
14
+ x: number;
15
+ y: number;
16
+ radius?: number;
17
+ color?: string;
18
+ label?: string;
19
+ kind?: 'cell' | 'organelle' | 'molecule' | 'organism';
20
+ }
21
+ export interface BiologyEdge {
22
+ from: string;
23
+ to: string;
24
+ color?: string;
25
+ label?: string;
26
+ }
27
+ export interface BiologyCanvasProps {
28
+ className?: string;
29
+ width?: number;
30
+ height?: number;
31
+ title?: string;
32
+ backgroundColor?: string;
33
+ nodes?: BiologyNode[];
34
+ edges?: BiologyEdge[];
35
+ /** Extra declarative shapes in canvas pixel coordinates. */
36
+ shapes?: LearningShape[];
37
+ interactive?: boolean;
38
+ animate?: boolean;
39
+ onShapeClick?: (payload: {
40
+ id?: string;
41
+ type?: string;
42
+ index: number;
43
+ }) => void;
44
+ isLoading?: boolean;
45
+ error?: UiError | null;
46
+ }
47
+ export declare const BiologyCanvas: React.FC<BiologyCanvasProps>;
@@ -0,0 +1,55 @@
1
+ /**
2
+ * ChemistryCanvas
3
+ *
4
+ * A field-scoped learning molecule for chemistry. Renders atoms, bonds, and
5
+ * reaction arrows on top of the declarative `LearningCanvas` atom.
6
+ *
7
+ * @packageDocumentation
8
+ */
9
+ import * as React from 'react';
10
+ import type { LearningShape } from '../atoms/LearningCanvas';
11
+ import type { UiError } from '../../core/atoms/types';
12
+ export interface ChemistryAtom {
13
+ id?: string;
14
+ x: number;
15
+ y: number;
16
+ element?: string;
17
+ radius?: number;
18
+ color?: string;
19
+ }
20
+ export interface ChemistryBond {
21
+ from: string;
22
+ to: string;
23
+ type?: 'single' | 'double' | 'triple';
24
+ color?: string;
25
+ }
26
+ export interface ChemistryArrow {
27
+ x: number;
28
+ y: number;
29
+ angle?: number;
30
+ length?: number;
31
+ color?: string;
32
+ label?: string;
33
+ }
34
+ export interface ChemistryCanvasProps {
35
+ className?: string;
36
+ width?: number;
37
+ height?: number;
38
+ title?: string;
39
+ backgroundColor?: string;
40
+ atoms?: ChemistryAtom[];
41
+ bonds?: ChemistryBond[];
42
+ arrows?: ChemistryArrow[];
43
+ /** Extra declarative shapes in canvas pixel coordinates. */
44
+ shapes?: LearningShape[];
45
+ interactive?: boolean;
46
+ animate?: boolean;
47
+ onShapeClick?: (payload: {
48
+ id?: string;
49
+ type?: string;
50
+ index: number;
51
+ }) => void;
52
+ isLoading?: boolean;
53
+ error?: UiError | null;
54
+ }
55
+ export declare const ChemistryCanvas: React.FC<ChemistryCanvasProps>;
@@ -0,0 +1,61 @@
1
+ /**
2
+ * MathCanvas
3
+ *
4
+ * A field-scoped learning molecule for mathematics. Renders a coordinate plane
5
+ * with axes, grid, curves (sampled points), scatter points, and vectors on top
6
+ * of the declarative `LearningCanvas` atom.
7
+ *
8
+ * @packageDocumentation
9
+ */
10
+ import * as React from 'react';
11
+ import type { LearningShape, LearningPoint } from '../atoms/LearningCanvas';
12
+ import type { UiError } from '../../core/atoms/types';
13
+ export interface MathCurve {
14
+ label?: string;
15
+ color?: string;
16
+ /** Sampled {x,y} points in math coordinates. */
17
+ samples: LearningPoint[];
18
+ }
19
+ export interface MathPoint {
20
+ x: number;
21
+ y: number;
22
+ label?: string;
23
+ color?: string;
24
+ radius?: number;
25
+ }
26
+ export interface MathVector {
27
+ x: number;
28
+ y: number;
29
+ vx: number;
30
+ vy: number;
31
+ color?: string;
32
+ label?: string;
33
+ }
34
+ export interface MathCanvasProps {
35
+ className?: string;
36
+ width?: number;
37
+ height?: number;
38
+ title?: string;
39
+ xMin?: number;
40
+ xMax?: number;
41
+ yMin?: number;
42
+ yMax?: number;
43
+ showAxes?: boolean;
44
+ showGrid?: boolean;
45
+ gridStep?: number;
46
+ curves?: MathCurve[];
47
+ points?: MathPoint[];
48
+ vectors?: MathVector[];
49
+ /** Extra declarative shapes in canvas pixel coordinates. */
50
+ shapes?: LearningShape[];
51
+ interactive?: boolean;
52
+ animate?: boolean;
53
+ onShapeClick?: (payload: {
54
+ id?: string;
55
+ type?: string;
56
+ index: number;
57
+ }) => void;
58
+ isLoading?: boolean;
59
+ error?: UiError | null;
60
+ }
61
+ export declare const MathCanvas: React.FC<MathCanvasProps>;
@@ -0,0 +1,54 @@
1
+ /**
2
+ * PhysicsCanvas
3
+ *
4
+ * A field-scoped learning molecule for physics. Renders bodies, constraints,
5
+ * velocity arrows, and force arrows on top of the declarative `LearningCanvas`
6
+ * atom.
7
+ *
8
+ * @packageDocumentation
9
+ */
10
+ import * as React from 'react';
11
+ import type { LearningShape } from '../atoms/LearningCanvas';
12
+ import type { UiError } from '../../core/atoms/types';
13
+ export interface LearningPhysicsBody {
14
+ id?: string;
15
+ x: number;
16
+ y: number;
17
+ radius?: number;
18
+ color?: string;
19
+ label?: string;
20
+ vx?: number;
21
+ vy?: number;
22
+ fx?: number;
23
+ fy?: number;
24
+ }
25
+ export interface LearningPhysicsConstraint {
26
+ from: string;
27
+ to: string;
28
+ color?: string;
29
+ }
30
+ export interface PhysicsCanvasProps {
31
+ className?: string;
32
+ width?: number;
33
+ height?: number;
34
+ title?: string;
35
+ backgroundColor?: string;
36
+ bodies?: LearningPhysicsBody[];
37
+ constraints?: LearningPhysicsConstraint[];
38
+ showVelocity?: boolean;
39
+ showForces?: boolean;
40
+ velocityScale?: number;
41
+ forceScale?: number;
42
+ /** Extra declarative shapes in canvas pixel coordinates. */
43
+ shapes?: LearningShape[];
44
+ interactive?: boolean;
45
+ animate?: boolean;
46
+ onShapeClick?: (payload: {
47
+ id?: string;
48
+ type?: string;
49
+ index: number;
50
+ }) => void;
51
+ isLoading?: boolean;
52
+ error?: UiError | null;
53
+ }
54
+ export declare const PhysicsCanvas: React.FC<PhysicsCanvasProps>;
@@ -1,6 +1,6 @@
1
1
  import React from "react";
2
2
  export type StatCardSize = "sm" | "md" | "lg";
3
- export interface StatCardProps {
3
+ export interface MarketingStatCardProps {
4
4
  /** The stat value to display prominently */
5
5
  value: string;
6
6
  /** Label describing the value */
@@ -10,4 +10,4 @@ export interface StatCardProps {
10
10
  /** Additional class names */
11
11
  className?: string;
12
12
  }
13
- export declare const MarketingStatCard: React.FC<StatCardProps>;
13
+ export declare const MarketingStatCard: React.FC<MarketingStatCardProps>;
@@ -25,7 +25,7 @@ export interface GitHubRepo {
25
25
  /**
26
26
  * Hook to get GitHub connection status
27
27
  */
28
- export declare function useGitHubStatus(): import("@tanstack/react-query").UseQueryResult<NoInfer<GitHubStatus>, Error>;
28
+ export declare function useGitHubStatus(): import("@tanstack/react-query").UseQueryResult<GitHubStatus, Error>;
29
29
  /**
30
30
  * Hook to connect GitHub (initiate OAuth flow)
31
31
  */
@@ -39,20 +39,20 @@ export declare function useDisconnectGitHub(): import("@tanstack/react-query").U
39
39
  /**
40
40
  * Hook to list GitHub repositories
41
41
  */
42
- export declare function useGitHubRepos(page?: number, perPage?: number): import("@tanstack/react-query").UseQueryResult<NoInfer<{
42
+ export declare function useGitHubRepos(page?: number, perPage?: number): import("@tanstack/react-query").UseQueryResult<{
43
43
  repos: GitHubRepo[];
44
44
  page: number;
45
45
  perPage: number;
46
- }>, Error>;
46
+ }, Error>;
47
47
  /**
48
48
  * Hook to get repository details
49
49
  */
50
- export declare function useGitHubRepo(owner: string, repo: string, enabled?: boolean): import("@tanstack/react-query").UseQueryResult<NoInfer<{
50
+ export declare function useGitHubRepo(owner: string, repo: string, enabled?: boolean): import("@tanstack/react-query").UseQueryResult<{
51
51
  repo: GitHubRepo;
52
- }>, Error>;
52
+ }, Error>;
53
53
  /**
54
54
  * Hook to list repository branches
55
55
  */
56
- export declare function useGitHubBranches(owner: string, repo: string, enabled?: boolean): import("@tanstack/react-query").UseQueryResult<NoInfer<{
56
+ export declare function useGitHubBranches(owner: string, repo: string, enabled?: boolean): import("@tanstack/react-query").UseQueryResult<{
57
57
  branches: string[];
58
- }>, Error>;
58
+ }, Error>;
@@ -28,7 +28,7 @@ function _interopNamespace(e) {
28
28
  var React11__default = /*#__PURE__*/_interopDefault(React11);
29
29
  var LucideIcons2__namespace = /*#__PURE__*/_interopNamespace(LucideIcons2);
30
30
 
31
- // node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
31
+ // node_modules/clsx/dist/clsx.mjs
32
32
  function r(e) {
33
33
  var t, f3, n = "";
34
34
  if ("string" == typeof e || "number" == typeof e) n += e;
@@ -43,7 +43,7 @@ function clsx() {
43
43
  return n;
44
44
  }
45
45
 
46
- // node_modules/.pnpm/tailwind-merge@2.6.1/node_modules/tailwind-merge/dist/bundle-mjs.mjs
46
+ // node_modules/tailwind-merge/dist/bundle-mjs.mjs
47
47
  var CLASS_PART_SEPARATOR = "-";
48
48
  var createClassGroupUtils = (config) => {
49
49
  const classMap = createClassMap(config);
@@ -4,7 +4,7 @@ import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
4
4
  import * as LucideIcons2 from 'lucide-react';
5
5
  import { Loader2, X } from 'lucide-react';
6
6
 
7
- // node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
7
+ // node_modules/clsx/dist/clsx.mjs
8
8
  function r(e) {
9
9
  var t, f3, n = "";
10
10
  if ("string" == typeof e || "number" == typeof e) n += e;
@@ -19,7 +19,7 @@ function clsx() {
19
19
  return n;
20
20
  }
21
21
 
22
- // node_modules/.pnpm/tailwind-merge@2.6.1/node_modules/tailwind-merge/dist/bundle-mjs.mjs
22
+ // node_modules/tailwind-merge/dist/bundle-mjs.mjs
23
23
  var CLASS_PART_SEPARATOR = "-";
24
24
  var createClassGroupUtils = (config) => {
25
25
  const classMap = createClassMap(config);
@@ -43,5 +43,5 @@ interface EventBusProviderProps {
43
43
  */
44
44
  isolated?: boolean;
45
45
  }
46
- export declare function EventBusProvider({ children, isolated }: EventBusProviderProps): React.JSX.Element;
46
+ export declare function EventBusProvider({ children, isolated }: EventBusProviderProps): import("react/jsx-runtime").JSX.Element;
47
47
  export type { EventBusContextType };
@@ -50,7 +50,7 @@ interface SelectionProviderProps {
50
50
  * }
51
51
  * ```
52
52
  */
53
- export declare function SelectionProvider({ children, debug, compareEntities, }: SelectionProviderProps): React.JSX.Element;
53
+ export declare function SelectionProvider({ children, debug, compareEntities, }: SelectionProviderProps): import("react/jsx-runtime").JSX.Element;
54
54
  /**
55
55
  * Hook to access selection state.
56
56
  *
@@ -98,5 +98,5 @@ export interface ServerBridgeProviderProps {
98
98
  transport?: ServerBridgeTransport;
99
99
  children: ReactNode;
100
100
  }
101
- export declare function ServerBridgeProvider({ schema, serverUrl, transport: customTransport, children, }: ServerBridgeProviderProps): import("react").JSX.Element;
101
+ export declare function ServerBridgeProvider({ schema, serverUrl, transport: customTransport, children, }: ServerBridgeProviderProps): import("react/jsx-runtime").JSX.Element;
102
102
  export {};