@almadar/ui 5.69.0 → 5.71.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.
- package/dist/avl/index.cjs +2034 -1854
- package/dist/avl/index.d.cts +93 -56
- package/dist/avl/index.js +758 -578
- package/dist/components/avl/molecules/AvlEventWireEdge.d.ts +2 -1
- package/dist/components/avl/molecules/AvlTransitionEdge.d.ts +2 -1
- package/dist/components/avl/molecules/avl-behavior-compose-converter.d.ts +7 -5
- package/dist/components/avl/molecules/avl-behavior-compose-types.d.ts +41 -21
- package/dist/components/avl/molecules/avl-canvas-types.d.ts +10 -7
- package/dist/components/avl/molecules/avl-preview-converter.d.ts +5 -5
- package/dist/components/avl/molecules/avl-preview-types.d.ts +15 -4
- package/dist/components/avl/organisms/FlowCanvas.d.ts +2 -2
- package/dist/components/avl/organisms/avl-schema-parser.d.ts +18 -16
- package/dist/components/core/atoms/Button.d.ts +2 -0
- package/dist/components/core/atoms/ConditionalWrapper.d.ts +5 -4
- package/dist/components/core/molecules/Carousel.d.ts +2 -2
- package/dist/components/core/molecules/OrbitalVisualization.d.ts +4 -3
- package/dist/components/core/molecules/PageHeader.d.ts +3 -3
- package/dist/components/core/molecules/RepeatableFormSection.d.ts +4 -3
- package/dist/components/core/molecules/ViolationAlert.d.ts +2 -0
- package/dist/components/core/molecules/WizardContainer.d.ts +23 -22
- package/dist/components/core/organisms/CardGrid.d.ts +2 -2
- package/dist/components/core/organisms/CustomPattern.d.ts +3 -4
- package/dist/components/core/organisms/DataTable.d.ts +2 -2
- package/dist/components/core/organisms/DetailPanel.d.ts +1 -1
- package/dist/components/core/organisms/Form.d.ts +11 -11
- package/dist/components/core/organisms/List.d.ts +3 -5
- package/dist/components/core/organisms/StatCard.d.ts +2 -2
- package/dist/components/core/organisms/book/types.d.ts +1 -1
- package/dist/components/core/organisms/debug/RuntimeDebugger.d.ts +2 -1
- package/dist/components/core/organisms/debug/tabs/EventDispatcherTab.d.ts +2 -1
- package/dist/components/core/organisms/layout/DashboardGrid.d.ts +0 -2
- package/dist/components/core/organisms/types.d.ts +3 -2
- package/dist/components/game/atoms/ScoreDisplay.d.ts +3 -1
- package/dist/components/game/molecules/three/hooks/useSceneGraph.d.ts +2 -1
- package/dist/components/game/molecules/three/index.cjs +37 -24
- package/dist/components/game/molecules/three/index.js +37 -24
- package/dist/components/game/organisms/HolidayRunnerBoard.d.ts +19 -17
- package/dist/components/game/organisms/PinballBoard.d.ts +4 -4
- package/dist/components/game/organisms/RacingBoard.d.ts +25 -17
- package/dist/components/game/organisms/SpaceShmupBoard.d.ts +28 -11
- package/dist/components/game/organisms/boardEntity.d.ts +6 -6
- package/dist/components/game/organisms/puzzles/debugger/DebuggerBoard.d.ts +16 -2
- package/dist/components/game/organisms/puzzles/event-handler/puzzleObject.d.ts +21 -10
- package/dist/components/game/organisms/puzzles/state-architect/StateJsonView.d.ts +2 -1
- package/dist/components/index.cjs +1771 -1614
- package/dist/components/index.js +650 -493
- package/dist/docs/index.cjs +107 -104
- package/dist/docs/index.d.cts +2 -0
- package/dist/docs/index.js +38 -35
- package/dist/lib/getNestedValue.d.ts +2 -13
- package/dist/marketing/index.cjs +97 -98
- package/dist/marketing/index.d.cts +2 -0
- package/dist/marketing/index.js +54 -55
- package/dist/providers/index.cjs +1744 -1587
- package/dist/providers/index.js +635 -478
- package/dist/runtime/index.cjs +1802 -1645
- package/dist/runtime/index.js +641 -484
- package/package.json +1 -1
- package/themes/almadar-website.css +2 -2
- package/themes/almadar.css +2 -2
- package/themes/arctic.css +2 -2
- package/themes/kiosk.css +2 -2
- package/themes/lavender.css +3 -3
- package/themes/midnight.css +2 -2
- package/themes/neon.css +2 -2
- package/themes/notion-editorial.css +2 -2
- package/themes/sunset.css +2 -2
- package/themes/trait-wars.css +2 -2
|
@@ -1,34 +1,36 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { AssetUrl, EventEmit } from '@almadar/core';
|
|
3
|
+
import type { IsometricTile, IsometricUnit, IsometricFeature } from './types/isometric';
|
|
3
4
|
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
5
|
+
import type { IsometricCanvasProps } from '../molecules/IsometricCanvas';
|
|
4
6
|
export interface HolidayRunnerBoardProps extends DisplayStateProps {
|
|
5
|
-
/**
|
|
6
|
-
|
|
7
|
-
/**
|
|
7
|
+
/** Ground/sky terrain tiles for the side-scroll strip */
|
|
8
|
+
tiles?: IsometricTile[];
|
|
9
|
+
/** Runner and obstacle units on the board */
|
|
10
|
+
units?: IsometricUnit[];
|
|
11
|
+
/** Features (gifts, obstacles, etc.) on the board */
|
|
12
|
+
features?: IsometricFeature[];
|
|
13
|
+
/** Asset sprite manifest (same shape as IsometricCanvas.assetManifest) */
|
|
14
|
+
assetManifest?: IsometricCanvasProps['assetManifest'];
|
|
15
|
+
/** Base URL prepended to manifest sprite paths */
|
|
8
16
|
assetBaseUrl?: AssetUrl;
|
|
9
|
-
/** Canvas width in pixels */
|
|
10
|
-
width?: number;
|
|
11
|
-
/** Canvas height in pixels */
|
|
12
|
-
height?: number;
|
|
13
|
-
/** Target frames per second */
|
|
14
|
-
fps?: number;
|
|
15
17
|
/** Render scale */
|
|
16
18
|
scale?: number;
|
|
17
19
|
/** Show minimap overlay */
|
|
18
20
|
showMinimap?: boolean;
|
|
19
21
|
/** Enable camera pan/zoom controls */
|
|
20
22
|
enableCamera?: boolean;
|
|
21
|
-
/** Declarative event: emits UI:{
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
23
|
+
/** Declarative event: emits UI:{tileClickEvent} with { x, y } on tile click */
|
|
24
|
+
tileClickEvent?: EventEmit<{
|
|
25
|
+
x: number;
|
|
26
|
+
y: number;
|
|
25
27
|
}>;
|
|
26
|
-
/** Declarative event: emits UI:{
|
|
27
|
-
|
|
28
|
-
|
|
28
|
+
/** Declarative event: emits UI:{unitClickEvent} with { unitId } on unit click */
|
|
29
|
+
unitClickEvent?: EventEmit<{
|
|
30
|
+
unitId: string;
|
|
29
31
|
}>;
|
|
30
32
|
}
|
|
31
|
-
export declare function HolidayRunnerBoard({
|
|
33
|
+
export declare function HolidayRunnerBoard({ tiles, units, features, assetManifest, assetBaseUrl, scale, showMinimap, enableCamera, tileClickEvent, unitClickEvent, isLoading, error, className, }: HolidayRunnerBoardProps): React.ReactElement;
|
|
32
34
|
export declare namespace HolidayRunnerBoard {
|
|
33
35
|
var displayName: string;
|
|
34
36
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { AssetUrl, EventEmit } from '@almadar/core';
|
|
2
|
+
import type { AssetUrl, EventEmit, EntityRow } from '@almadar/core';
|
|
3
3
|
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
4
4
|
export interface PinballBoardProps extends DisplayStateProps {
|
|
5
5
|
/** Playfield tiles */
|
|
6
|
-
tiles?:
|
|
6
|
+
tiles?: readonly EntityRow[];
|
|
7
7
|
/** Ball units on the board */
|
|
8
|
-
units?:
|
|
8
|
+
units?: readonly EntityRow[];
|
|
9
9
|
/** Features (bumpers, paddles, etc.) on the board */
|
|
10
|
-
features?:
|
|
10
|
+
features?: readonly EntityRow[];
|
|
11
11
|
/** Asset sprite manifest */
|
|
12
12
|
assetManifest?: string;
|
|
13
13
|
/** Base URL prepended to manifest sprite paths */
|
|
@@ -1,28 +1,36 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { AssetUrl, EventEmit } from '@almadar/core';
|
|
3
|
+
import type { IsometricTile, IsometricUnit, IsometricFeature } from './types/isometric';
|
|
3
4
|
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
5
|
+
import type { IsometricCanvasProps } from '../molecules/IsometricCanvas';
|
|
4
6
|
export interface RacingBoardProps extends DisplayStateProps {
|
|
5
|
-
/**
|
|
6
|
-
|
|
7
|
-
/**
|
|
7
|
+
/** Road + grass terrain tiles forming the race circuit */
|
|
8
|
+
tiles?: IsometricTile[];
|
|
9
|
+
/** Car units on the track */
|
|
10
|
+
units?: IsometricUnit[];
|
|
11
|
+
/** Track features (pit lane markers, start/finish line, etc.) */
|
|
12
|
+
features?: IsometricFeature[];
|
|
13
|
+
/** Asset sprite manifest (same shape as IsometricCanvas.assetManifest) */
|
|
14
|
+
assetManifest?: IsometricCanvasProps['assetManifest'];
|
|
15
|
+
/** Base URL prepended to manifest sprite paths */
|
|
8
16
|
assetBaseUrl?: AssetUrl;
|
|
9
|
-
/**
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
|
|
15
|
-
/** Declarative event: emits UI:{
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
/** Render scale */
|
|
18
|
+
scale?: number;
|
|
19
|
+
/** Show minimap overlay */
|
|
20
|
+
showMinimap?: boolean;
|
|
21
|
+
/** Enable camera pan/zoom controls */
|
|
22
|
+
enableCamera?: boolean;
|
|
23
|
+
/** Declarative event: emits UI:{tileClickEvent} with { x, y } on tile click */
|
|
24
|
+
tileClickEvent?: EventEmit<{
|
|
25
|
+
x: number;
|
|
26
|
+
y: number;
|
|
19
27
|
}>;
|
|
20
|
-
/** Declarative event: emits UI:{
|
|
21
|
-
|
|
22
|
-
|
|
28
|
+
/** Declarative event: emits UI:{unitClickEvent} with { unitId } on unit click */
|
|
29
|
+
unitClickEvent?: EventEmit<{
|
|
30
|
+
unitId: string;
|
|
23
31
|
}>;
|
|
24
32
|
}
|
|
25
|
-
export declare function RacingBoard({
|
|
33
|
+
export declare function RacingBoard({ tiles, units, features, assetManifest, assetBaseUrl, scale, showMinimap, enableCamera, tileClickEvent, unitClickEvent, isLoading, error, className, }: RacingBoardProps): React.ReactElement;
|
|
26
34
|
export declare namespace RacingBoard {
|
|
27
35
|
var displayName: string;
|
|
28
36
|
}
|
|
@@ -1,19 +1,36 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { AssetUrl } from '@almadar/core';
|
|
2
|
+
import type { AssetUrl, EventEmit } from '@almadar/core';
|
|
3
|
+
import type { IsometricTile, IsometricUnit, IsometricFeature } from './types/isometric';
|
|
3
4
|
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
5
|
+
import type { IsometricCanvasProps } from '../molecules/IsometricCanvas';
|
|
4
6
|
export interface SpaceShmupBoardProps extends DisplayStateProps {
|
|
5
|
-
/**
|
|
6
|
-
|
|
7
|
-
/**
|
|
7
|
+
/** Space terrain tiles filling the grid */
|
|
8
|
+
tiles?: IsometricTile[];
|
|
9
|
+
/** Player ship and enemy ships on the board */
|
|
10
|
+
units?: IsometricUnit[];
|
|
11
|
+
/** Features (asteroids, power-ups, etc.) on the board */
|
|
12
|
+
features?: IsometricFeature[];
|
|
13
|
+
/** Asset sprite manifest (same shape as IsometricCanvas.assetManifest) */
|
|
14
|
+
assetManifest?: IsometricCanvasProps['assetManifest'];
|
|
15
|
+
/** Base URL prepended to manifest sprite paths */
|
|
8
16
|
assetBaseUrl?: AssetUrl;
|
|
9
|
-
/**
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
|
|
17
|
+
/** Render scale */
|
|
18
|
+
scale?: number;
|
|
19
|
+
/** Show minimap overlay */
|
|
20
|
+
showMinimap?: boolean;
|
|
21
|
+
/** Enable camera pan/zoom controls */
|
|
22
|
+
enableCamera?: boolean;
|
|
23
|
+
/** Declarative event: emits UI:{tileClickEvent} with { x, y } on tile click */
|
|
24
|
+
tileClickEvent?: EventEmit<{
|
|
25
|
+
x: number;
|
|
26
|
+
y: number;
|
|
27
|
+
}>;
|
|
28
|
+
/** Declarative event: emits UI:{unitClickEvent} with { unitId } on unit click */
|
|
29
|
+
unitClickEvent?: EventEmit<{
|
|
30
|
+
unitId: string;
|
|
31
|
+
}>;
|
|
15
32
|
}
|
|
16
|
-
export declare function SpaceShmupBoard({
|
|
33
|
+
export declare function SpaceShmupBoard({ tiles, units, features, assetManifest, assetBaseUrl, scale, showMinimap, enableCamera, tileClickEvent, unitClickEvent, isLoading, error, className, }: SpaceShmupBoardProps): React.ReactElement;
|
|
17
34
|
export declare namespace SpaceShmupBoard {
|
|
18
35
|
var displayName: string;
|
|
19
36
|
}
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
*
|
|
11
11
|
* @packageDocumentation
|
|
12
12
|
*/
|
|
13
|
-
import type { EntityRow } from '@almadar/core';
|
|
13
|
+
import type { EntityRow, FieldValue } from '@almadar/core';
|
|
14
14
|
/** A 2D grid position read off an entity row. */
|
|
15
15
|
export interface Vec2 {
|
|
16
16
|
x: number;
|
|
@@ -27,15 +27,15 @@ export interface TeamUnitTraits {
|
|
|
27
27
|
* an array of rows, or undefined. Boards operate on one board state. */
|
|
28
28
|
export declare function boardEntity(entity: EntityRow | readonly EntityRow[] | undefined): EntityRow | undefined;
|
|
29
29
|
/** Coerce a field value to a string (empty string when absent). */
|
|
30
|
-
export declare function str(v:
|
|
30
|
+
export declare function str(v: FieldValue | undefined): string;
|
|
31
31
|
/** Coerce a field value to a number (0 when absent / non-numeric). */
|
|
32
|
-
export declare function num(v:
|
|
32
|
+
export declare function num(v: FieldValue | undefined, fallback?: number): number;
|
|
33
33
|
/** Coerce a field value to a boolean. */
|
|
34
|
-
export declare function bool(v:
|
|
34
|
+
export declare function bool(v: FieldValue | undefined): boolean;
|
|
35
35
|
/** Coerce a nested array field to a readonly array of entity rows. */
|
|
36
|
-
export declare function rows(v:
|
|
36
|
+
export declare function rows(v: FieldValue | undefined): readonly EntityRow[];
|
|
37
37
|
/** Read an `{ x, y }` position off an entity row's named field. */
|
|
38
|
-
export declare function vec2(v:
|
|
38
|
+
export declare function vec2(v: FieldValue | undefined): Vec2;
|
|
39
39
|
/** Read a unit row's `position` as a `Vec2`. */
|
|
40
40
|
export declare function unitPosition(u: EntityRow): Vec2;
|
|
41
41
|
/** Read a unit row's `team` ('player' | 'enemy' | string). */
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* Events emitted via completeEvent (default UI:PUZZLE_COMPLETE).
|
|
10
10
|
*/
|
|
11
11
|
import React from 'react';
|
|
12
|
-
import type { EventEmit, EntityRow } from '@almadar/core';
|
|
12
|
+
import type { EventEmit, EntityRow, EntityWith } from '@almadar/core';
|
|
13
13
|
import type { DisplayStateProps } from '../../../../core/organisms/types';
|
|
14
14
|
/** A reviewable code line (UI value DTO read off the entity). */
|
|
15
15
|
export interface DebuggerLine {
|
|
@@ -23,7 +23,21 @@ export interface DebuggerBoardProps extends DisplayStateProps {
|
|
|
23
23
|
/** Puzzle board-state entity (single row or array). The board reads
|
|
24
24
|
* `lines` array (each with `isFlagged`), `result`, `attempts`, plus
|
|
25
25
|
* title/description/bugCount/hint off the row. */
|
|
26
|
-
entity?:
|
|
26
|
+
entity?: EntityWith<{
|
|
27
|
+
lines?: DebuggerLine[];
|
|
28
|
+
result?: string;
|
|
29
|
+
attempts?: number;
|
|
30
|
+
title?: string;
|
|
31
|
+
description?: string;
|
|
32
|
+
bugCount?: number;
|
|
33
|
+
hint?: string;
|
|
34
|
+
headerImage?: string;
|
|
35
|
+
theme?: {
|
|
36
|
+
background?: string;
|
|
37
|
+
accentColor?: string;
|
|
38
|
+
};
|
|
39
|
+
successMessage?: string;
|
|
40
|
+
}> | readonly EntityRow[];
|
|
27
41
|
completeEvent?: EventEmit<{
|
|
28
42
|
success: boolean;
|
|
29
43
|
attempts: number;
|
|
@@ -8,14 +8,25 @@
|
|
|
8
8
|
*
|
|
9
9
|
* @packageDocumentation
|
|
10
10
|
*/
|
|
11
|
-
import type {
|
|
11
|
+
import type { EntityWith } from '@almadar/core';
|
|
12
12
|
import type { RuleDefinition, RuleOption } from './RuleEditor';
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
13
|
+
type PuzzleObjectRow = EntityWith<{
|
|
14
|
+
name?: string;
|
|
15
|
+
icon?: string;
|
|
16
|
+
states?: string[];
|
|
17
|
+
currentState?: string;
|
|
18
|
+
availableEvents?: RuleOption[];
|
|
19
|
+
availableActions?: RuleOption[];
|
|
20
|
+
rules?: RuleDefinition[];
|
|
21
|
+
maxRules?: number;
|
|
22
|
+
}>;
|
|
23
|
+
export declare function objId(o: PuzzleObjectRow): string;
|
|
24
|
+
export declare function objName(o: PuzzleObjectRow): string;
|
|
25
|
+
export declare function objIcon(o: PuzzleObjectRow): string;
|
|
26
|
+
export declare function objStates(o: PuzzleObjectRow): string[];
|
|
27
|
+
export declare function objCurrentState(o: PuzzleObjectRow): string;
|
|
28
|
+
export declare function objAvailableEvents(o: PuzzleObjectRow): RuleOption[];
|
|
29
|
+
export declare function objAvailableActions(o: PuzzleObjectRow): RuleOption[];
|
|
30
|
+
export declare function objRules(o: PuzzleObjectRow): RuleDefinition[];
|
|
31
|
+
export declare function objMaxRules(o: PuzzleObjectRow): number;
|
|
32
|
+
export {};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { JsonObject } from '@almadar/core';
|
|
2
3
|
export interface StateJsonViewProps {
|
|
3
4
|
/** JSON data to display */
|
|
4
|
-
data:
|
|
5
|
+
data: JsonObject;
|
|
5
6
|
/** Label */
|
|
6
7
|
label?: string;
|
|
7
8
|
/** Whether the code is expanded by default */
|