@a2ui/angular 0.9.0-alpha.3 → 0.9.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/fesm2022/a2ui-angular-src-v0_9.mjs +84 -47
- package/fesm2022/a2ui-angular-src-v0_9.mjs.map +1 -1
- package/fesm2022/a2ui-angular-v0_9.mjs +84 -47
- package/fesm2022/a2ui-angular-v0_9.mjs.map +1 -1
- package/package.json +3 -3
- package/types/a2ui-angular-src-v0_9.d.ts +91 -53
- package/types/a2ui-angular-v0_9.d.ts +91 -53
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@a2ui/angular",
|
|
3
|
-
"version": "0.9.0
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"homepage": "https://a2ui.org/",
|
|
6
6
|
"repository": {
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"renderer"
|
|
21
21
|
],
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@a2ui/web_core": "^0.9.1
|
|
23
|
+
"@a2ui/web_core": "^0.9.1",
|
|
24
24
|
"@preact/signals-core": "^1.13.0",
|
|
25
25
|
"tslib": "^2.3.0",
|
|
26
26
|
"zod": "^3.25.76"
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"@angular/common": "^21.2.0",
|
|
30
30
|
"@angular/core": "^21.2.0",
|
|
31
31
|
"@angular/platform-browser": "^21.2.0",
|
|
32
|
-
"@a2ui/markdown-it": "^0.0.2
|
|
32
|
+
"@a2ui/markdown-it": "^0.0.2"
|
|
33
33
|
},
|
|
34
34
|
"peerDependenciesMeta": {
|
|
35
35
|
"@a2ui/markdown-it": {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _angular_core from '@angular/core';
|
|
2
|
-
import { Type, InjectionToken, OnDestroy,
|
|
2
|
+
import { Type, InjectionToken, OnDestroy, Signal, OnInit, DestroyRef, NgZone } from '@angular/core';
|
|
3
3
|
import { Catalog, ComponentApi, A2uiClientAction, A2uiMessage, SurfaceGroupModel, ComponentContext, Signal as Signal$1, FunctionImplementation } from '@a2ui/web_core/v0_9';
|
|
4
4
|
export { signal as preactSignal } from '@a2ui/web_core/v0_9';
|
|
5
5
|
export { BASIC_FUNCTIONS } from '@a2ui/web_core/v0_9/basic_catalog';
|
|
@@ -108,56 +108,6 @@ declare class A2uiRendererService implements OnDestroy {
|
|
|
108
108
|
static ɵprov: _angular_core.ɵɵInjectableDeclaration<A2uiRendererService>;
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
/**
|
|
112
|
-
* Dynamically renders an A2UI component as defined in the current surface model.
|
|
113
|
-
*
|
|
114
|
-
* This component acts as a bridge between the A2UI surface model and Angular components.
|
|
115
|
-
* It resolves the appropriate component from the catalog based on the component's type,
|
|
116
|
-
* and uses {@link ComponentBinder} to create reactive property bindings.
|
|
117
|
-
*
|
|
118
|
-
* Usually, you'll use the higher-level {@link SurfaceComponent} which automatically
|
|
119
|
-
* sets up a host for the 'root' component.
|
|
120
|
-
*/
|
|
121
|
-
declare class ComponentHostComponent implements OnInit {
|
|
122
|
-
/** The key of the component to render, either an ID string or an object with ID and basePath. Defaults to 'root'. */
|
|
123
|
-
componentKey: _angular_core.InputSignal<string | {
|
|
124
|
-
id: string;
|
|
125
|
-
basePath: string;
|
|
126
|
-
}>;
|
|
127
|
-
/** The unique identifier of the surface this component belongs to. */
|
|
128
|
-
surfaceId: _angular_core.InputSignal<string>;
|
|
129
|
-
private rendererService;
|
|
130
|
-
private binder;
|
|
131
|
-
private destroyRef;
|
|
132
|
-
protected componentType: Type<any> | null;
|
|
133
|
-
protected props: any;
|
|
134
|
-
private context?;
|
|
135
|
-
protected resolvedComponentId: string;
|
|
136
|
-
protected resolvedDataContextPath: string;
|
|
137
|
-
ngOnInit(): void;
|
|
138
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ComponentHostComponent, never>;
|
|
139
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ComponentHostComponent, "a2ui-v09-component-host", never, { "componentKey": { "alias": "componentKey"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
/**
|
|
143
|
-
* High-level component for rendering an entire A2UI surface.
|
|
144
|
-
*
|
|
145
|
-
* This component handles the boilerplate of setting up a {@link ComponentHostComponent}
|
|
146
|
-
* for the 'root' component of a surface. It is the recommended way to embed an
|
|
147
|
-
* A2UI surface in an Angular application.
|
|
148
|
-
*/
|
|
149
|
-
declare class SurfaceComponent {
|
|
150
|
-
/** The unique identifier of the surface to render. */
|
|
151
|
-
surfaceId: _angular_core.InputSignal<string>;
|
|
152
|
-
/**
|
|
153
|
-
* The path within the surface's data model that represents the current state.
|
|
154
|
-
* Defaults to the root ('/').
|
|
155
|
-
*/
|
|
156
|
-
dataContextPath: _angular_core.InputSignal<string>;
|
|
157
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SurfaceComponent, never>;
|
|
158
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SurfaceComponent, "a2ui-v09-surface", never, { "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
111
|
/**
|
|
162
112
|
* Copyright 2026 Google LLC
|
|
163
113
|
*
|
|
@@ -207,6 +157,65 @@ interface BoundProperty<T = any> {
|
|
|
207
157
|
readonly onUpdate: (newValue: T) => void;
|
|
208
158
|
}
|
|
209
159
|
|
|
160
|
+
/**
|
|
161
|
+
* Dynamically renders an A2UI component as defined in the current surface model.
|
|
162
|
+
*
|
|
163
|
+
* This component acts as a bridge between the A2UI surface model and Angular components.
|
|
164
|
+
* It resolves the appropriate component from the catalog based on the component's type,
|
|
165
|
+
* and uses {@link ComponentBinder} to create reactive property bindings.
|
|
166
|
+
*
|
|
167
|
+
* Usually, you'll use the higher-level {@link SurfaceComponent} which automatically
|
|
168
|
+
* sets up a host for the 'root' component.
|
|
169
|
+
*/
|
|
170
|
+
declare class ComponentHostComponent implements OnInit {
|
|
171
|
+
/** The key of the component to render, either an ID string or an object with ID and basePath. Defaults to 'root'. */
|
|
172
|
+
componentKey: _angular_core.InputSignal<string | {
|
|
173
|
+
id: string;
|
|
174
|
+
basePath: string;
|
|
175
|
+
}>;
|
|
176
|
+
/** The unique identifier of the surface this component belongs to. */
|
|
177
|
+
surfaceId: _angular_core.InputSignal<string>;
|
|
178
|
+
private readonly rendererService;
|
|
179
|
+
private readonly binder;
|
|
180
|
+
private readonly destroyRef;
|
|
181
|
+
private readonly cdr;
|
|
182
|
+
protected componentType: Type<any> | null;
|
|
183
|
+
protected props: Record<string, BoundProperty>;
|
|
184
|
+
private context?;
|
|
185
|
+
protected weight: _angular_core.WritableSignal<string | number | null>;
|
|
186
|
+
get flexStyle(): string;
|
|
187
|
+
protected resolvedComponentId: string;
|
|
188
|
+
protected resolvedDataContextPath: string;
|
|
189
|
+
ngOnInit(): void;
|
|
190
|
+
private initializeComponent;
|
|
191
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ComponentHostComponent, never>;
|
|
192
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ComponentHostComponent, "a2ui-v09-component-host", never, { "componentKey": { "alias": "componentKey"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
/**
|
|
196
|
+
* High-level component for rendering an entire A2UI surface.
|
|
197
|
+
*
|
|
198
|
+
* This component handles the boilerplate of setting up a {@link ComponentHostComponent}
|
|
199
|
+
* for the 'root' component of a surface. It is the recommended way to embed an
|
|
200
|
+
* A2UI surface in an Angular application.
|
|
201
|
+
*/
|
|
202
|
+
declare class SurfaceComponent {
|
|
203
|
+
/** The unique identifier of the surface to render. */
|
|
204
|
+
surfaceId: _angular_core.InputSignal<string>;
|
|
205
|
+
/**
|
|
206
|
+
* The path within the surface's data model that represents the current state.
|
|
207
|
+
* Defaults to the root ('/').
|
|
208
|
+
*/
|
|
209
|
+
dataContextPath: _angular_core.InputSignal<string>;
|
|
210
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SurfaceComponent, never>;
|
|
211
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SurfaceComponent, "a2ui-v09-surface", never, { "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
/** Represents a reference to a child component. */
|
|
215
|
+
interface Child {
|
|
216
|
+
id: string;
|
|
217
|
+
basePath: string;
|
|
218
|
+
}
|
|
210
219
|
/**
|
|
211
220
|
* Binds A2UI ComponentModel properties to reactive Angular Signals.
|
|
212
221
|
*
|
|
@@ -259,6 +268,30 @@ declare function toAngularSignal<T>(preactSignal: Signal$1<T>, destroyRef: Destr
|
|
|
259
268
|
*/
|
|
260
269
|
declare function getNormalizedPath(path: string, dataContextPath: string, index: number): string;
|
|
261
270
|
|
|
271
|
+
interface MarkdownRendererOptions {
|
|
272
|
+
tagClassMap?: Record<string, string>;
|
|
273
|
+
}
|
|
274
|
+
declare abstract class MarkdownRenderer {
|
|
275
|
+
abstract render(markdown: string, options?: MarkdownRendererOptions): Promise<string>;
|
|
276
|
+
}
|
|
277
|
+
declare class DefaultMarkdownRenderer extends MarkdownRenderer {
|
|
278
|
+
private static warningLogged;
|
|
279
|
+
render(markdown: string, options?: MarkdownRendererOptions): Promise<string>;
|
|
280
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<DefaultMarkdownRenderer, never>;
|
|
281
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<DefaultMarkdownRenderer>;
|
|
282
|
+
}
|
|
283
|
+
declare function provideMarkdownRenderer(renderFn?: (markdown: string, options?: MarkdownRendererOptions) => Promise<string>): {
|
|
284
|
+
provide: typeof MarkdownRenderer;
|
|
285
|
+
useValue: {
|
|
286
|
+
render: (markdown: string, options?: MarkdownRendererOptions) => Promise<string>;
|
|
287
|
+
};
|
|
288
|
+
useClass?: undefined;
|
|
289
|
+
} | {
|
|
290
|
+
provide: typeof MarkdownRenderer;
|
|
291
|
+
useClass: typeof DefaultMarkdownRenderer;
|
|
292
|
+
useValue?: undefined;
|
|
293
|
+
};
|
|
294
|
+
|
|
262
295
|
/**
|
|
263
296
|
* The set of default Angular implementations for each component in the basic catalog.
|
|
264
297
|
*/
|
|
@@ -675,6 +708,11 @@ declare class ListComponent extends BasicCatalogComponent {
|
|
|
675
708
|
children: _angular_core.Signal<any[]>;
|
|
676
709
|
listTag: _angular_core.Signal<"ol" | "ul" | "div">;
|
|
677
710
|
styleType: _angular_core.Signal<"" | "none">;
|
|
711
|
+
/**
|
|
712
|
+
* Track-by function to ensure stable change detection for list items.
|
|
713
|
+
* Uses the full resolved path (`basePath/id`) to uniquely identify items.
|
|
714
|
+
*/
|
|
715
|
+
readonly trackBy: (index: number, item: Child) => string;
|
|
678
716
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ListComponent, never>;
|
|
679
717
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ListComponent, "a2ui-v09-list", never, { "props": { "alias": "props"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "componentId": { "alias": "componentId"; "required": false; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
680
718
|
}
|
|
@@ -960,5 +998,5 @@ declare class DateTimeInputComponent extends BasicCatalogComponent {
|
|
|
960
998
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<DateTimeInputComponent, "a2ui-v09-date-time-input", never, { "props": { "alias": "props"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "componentId": { "alias": "componentId"; "required": false; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
961
999
|
}
|
|
962
1000
|
|
|
963
|
-
export { A2UI_RENDERER_CONFIG, A2uiRendererService, AngularCatalog, AudioPlayerComponent, BASIC_COMPONENTS, BasicCatalog, BasicCatalogBase, ButtonComponent, CardComponent, CheckBoxComponent, ChoicePickerComponent, ColumnComponent, ComponentBinder, ComponentHostComponent, DateTimeInputComponent, DividerComponent, IconComponent, ImageComponent, ListComponent, ModalComponent, RowComponent, SliderComponent, SurfaceComponent, TabsComponent, TextComponent, TextFieldComponent, VideoComponent, getNormalizedPath, toAngularSignal };
|
|
964
|
-
export type { AngularComponentImplementation, BasicCatalogOptions, BoundProperty, RendererConfiguration };
|
|
1001
|
+
export { A2UI_RENDERER_CONFIG, A2uiRendererService, AngularCatalog, AudioPlayerComponent, BASIC_COMPONENTS, BasicCatalog, BasicCatalogBase, ButtonComponent, CardComponent, CheckBoxComponent, ChoicePickerComponent, ColumnComponent, ComponentBinder, ComponentHostComponent, DateTimeInputComponent, DefaultMarkdownRenderer, DividerComponent, IconComponent, ImageComponent, ListComponent, MarkdownRenderer, ModalComponent, RowComponent, SliderComponent, SurfaceComponent, TabsComponent, TextComponent, TextFieldComponent, VideoComponent, getNormalizedPath, provideMarkdownRenderer, toAngularSignal };
|
|
1002
|
+
export type { AngularComponentImplementation, BasicCatalogOptions, BoundProperty, Child, MarkdownRendererOptions, RendererConfiguration };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _angular_core from '@angular/core';
|
|
2
|
-
import { Type, InjectionToken, OnDestroy,
|
|
2
|
+
import { Type, InjectionToken, OnDestroy, Signal, OnInit, DestroyRef, NgZone } from '@angular/core';
|
|
3
3
|
import { Catalog, ComponentApi, A2uiClientAction, A2uiMessage, SurfaceGroupModel, ComponentContext, Signal as Signal$1, FunctionImplementation } from '@a2ui/web_core/v0_9';
|
|
4
4
|
export { signal as preactSignal } from '@a2ui/web_core/v0_9';
|
|
5
5
|
export { BASIC_FUNCTIONS } from '@a2ui/web_core/v0_9/basic_catalog';
|
|
@@ -108,56 +108,6 @@ declare class A2uiRendererService implements OnDestroy {
|
|
|
108
108
|
static ɵprov: _angular_core.ɵɵInjectableDeclaration<A2uiRendererService>;
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
/**
|
|
112
|
-
* Dynamically renders an A2UI component as defined in the current surface model.
|
|
113
|
-
*
|
|
114
|
-
* This component acts as a bridge between the A2UI surface model and Angular components.
|
|
115
|
-
* It resolves the appropriate component from the catalog based on the component's type,
|
|
116
|
-
* and uses {@link ComponentBinder} to create reactive property bindings.
|
|
117
|
-
*
|
|
118
|
-
* Usually, you'll use the higher-level {@link SurfaceComponent} which automatically
|
|
119
|
-
* sets up a host for the 'root' component.
|
|
120
|
-
*/
|
|
121
|
-
declare class ComponentHostComponent implements OnInit {
|
|
122
|
-
/** The key of the component to render, either an ID string or an object with ID and basePath. Defaults to 'root'. */
|
|
123
|
-
componentKey: _angular_core.InputSignal<string | {
|
|
124
|
-
id: string;
|
|
125
|
-
basePath: string;
|
|
126
|
-
}>;
|
|
127
|
-
/** The unique identifier of the surface this component belongs to. */
|
|
128
|
-
surfaceId: _angular_core.InputSignal<string>;
|
|
129
|
-
private rendererService;
|
|
130
|
-
private binder;
|
|
131
|
-
private destroyRef;
|
|
132
|
-
protected componentType: Type<any> | null;
|
|
133
|
-
protected props: any;
|
|
134
|
-
private context?;
|
|
135
|
-
protected resolvedComponentId: string;
|
|
136
|
-
protected resolvedDataContextPath: string;
|
|
137
|
-
ngOnInit(): void;
|
|
138
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ComponentHostComponent, never>;
|
|
139
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ComponentHostComponent, "a2ui-v09-component-host", never, { "componentKey": { "alias": "componentKey"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
/**
|
|
143
|
-
* High-level component for rendering an entire A2UI surface.
|
|
144
|
-
*
|
|
145
|
-
* This component handles the boilerplate of setting up a {@link ComponentHostComponent}
|
|
146
|
-
* for the 'root' component of a surface. It is the recommended way to embed an
|
|
147
|
-
* A2UI surface in an Angular application.
|
|
148
|
-
*/
|
|
149
|
-
declare class SurfaceComponent {
|
|
150
|
-
/** The unique identifier of the surface to render. */
|
|
151
|
-
surfaceId: _angular_core.InputSignal<string>;
|
|
152
|
-
/**
|
|
153
|
-
* The path within the surface's data model that represents the current state.
|
|
154
|
-
* Defaults to the root ('/').
|
|
155
|
-
*/
|
|
156
|
-
dataContextPath: _angular_core.InputSignal<string>;
|
|
157
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SurfaceComponent, never>;
|
|
158
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SurfaceComponent, "a2ui-v09-surface", never, { "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
111
|
/**
|
|
162
112
|
* Copyright 2026 Google LLC
|
|
163
113
|
*
|
|
@@ -207,6 +157,65 @@ interface BoundProperty<T = any> {
|
|
|
207
157
|
readonly onUpdate: (newValue: T) => void;
|
|
208
158
|
}
|
|
209
159
|
|
|
160
|
+
/**
|
|
161
|
+
* Dynamically renders an A2UI component as defined in the current surface model.
|
|
162
|
+
*
|
|
163
|
+
* This component acts as a bridge between the A2UI surface model and Angular components.
|
|
164
|
+
* It resolves the appropriate component from the catalog based on the component's type,
|
|
165
|
+
* and uses {@link ComponentBinder} to create reactive property bindings.
|
|
166
|
+
*
|
|
167
|
+
* Usually, you'll use the higher-level {@link SurfaceComponent} which automatically
|
|
168
|
+
* sets up a host for the 'root' component.
|
|
169
|
+
*/
|
|
170
|
+
declare class ComponentHostComponent implements OnInit {
|
|
171
|
+
/** The key of the component to render, either an ID string or an object with ID and basePath. Defaults to 'root'. */
|
|
172
|
+
componentKey: _angular_core.InputSignal<string | {
|
|
173
|
+
id: string;
|
|
174
|
+
basePath: string;
|
|
175
|
+
}>;
|
|
176
|
+
/** The unique identifier of the surface this component belongs to. */
|
|
177
|
+
surfaceId: _angular_core.InputSignal<string>;
|
|
178
|
+
private readonly rendererService;
|
|
179
|
+
private readonly binder;
|
|
180
|
+
private readonly destroyRef;
|
|
181
|
+
private readonly cdr;
|
|
182
|
+
protected componentType: Type<any> | null;
|
|
183
|
+
protected props: Record<string, BoundProperty>;
|
|
184
|
+
private context?;
|
|
185
|
+
protected weight: _angular_core.WritableSignal<string | number | null>;
|
|
186
|
+
get flexStyle(): string;
|
|
187
|
+
protected resolvedComponentId: string;
|
|
188
|
+
protected resolvedDataContextPath: string;
|
|
189
|
+
ngOnInit(): void;
|
|
190
|
+
private initializeComponent;
|
|
191
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ComponentHostComponent, never>;
|
|
192
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ComponentHostComponent, "a2ui-v09-component-host", never, { "componentKey": { "alias": "componentKey"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
/**
|
|
196
|
+
* High-level component for rendering an entire A2UI surface.
|
|
197
|
+
*
|
|
198
|
+
* This component handles the boilerplate of setting up a {@link ComponentHostComponent}
|
|
199
|
+
* for the 'root' component of a surface. It is the recommended way to embed an
|
|
200
|
+
* A2UI surface in an Angular application.
|
|
201
|
+
*/
|
|
202
|
+
declare class SurfaceComponent {
|
|
203
|
+
/** The unique identifier of the surface to render. */
|
|
204
|
+
surfaceId: _angular_core.InputSignal<string>;
|
|
205
|
+
/**
|
|
206
|
+
* The path within the surface's data model that represents the current state.
|
|
207
|
+
* Defaults to the root ('/').
|
|
208
|
+
*/
|
|
209
|
+
dataContextPath: _angular_core.InputSignal<string>;
|
|
210
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SurfaceComponent, never>;
|
|
211
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SurfaceComponent, "a2ui-v09-surface", never, { "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
/** Represents a reference to a child component. */
|
|
215
|
+
interface Child {
|
|
216
|
+
id: string;
|
|
217
|
+
basePath: string;
|
|
218
|
+
}
|
|
210
219
|
/**
|
|
211
220
|
* Binds A2UI ComponentModel properties to reactive Angular Signals.
|
|
212
221
|
*
|
|
@@ -259,6 +268,30 @@ declare function toAngularSignal<T>(preactSignal: Signal$1<T>, destroyRef: Destr
|
|
|
259
268
|
*/
|
|
260
269
|
declare function getNormalizedPath(path: string, dataContextPath: string, index: number): string;
|
|
261
270
|
|
|
271
|
+
interface MarkdownRendererOptions {
|
|
272
|
+
tagClassMap?: Record<string, string>;
|
|
273
|
+
}
|
|
274
|
+
declare abstract class MarkdownRenderer {
|
|
275
|
+
abstract render(markdown: string, options?: MarkdownRendererOptions): Promise<string>;
|
|
276
|
+
}
|
|
277
|
+
declare class DefaultMarkdownRenderer extends MarkdownRenderer {
|
|
278
|
+
private static warningLogged;
|
|
279
|
+
render(markdown: string, options?: MarkdownRendererOptions): Promise<string>;
|
|
280
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<DefaultMarkdownRenderer, never>;
|
|
281
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<DefaultMarkdownRenderer>;
|
|
282
|
+
}
|
|
283
|
+
declare function provideMarkdownRenderer(renderFn?: (markdown: string, options?: MarkdownRendererOptions) => Promise<string>): {
|
|
284
|
+
provide: typeof MarkdownRenderer;
|
|
285
|
+
useValue: {
|
|
286
|
+
render: (markdown: string, options?: MarkdownRendererOptions) => Promise<string>;
|
|
287
|
+
};
|
|
288
|
+
useClass?: undefined;
|
|
289
|
+
} | {
|
|
290
|
+
provide: typeof MarkdownRenderer;
|
|
291
|
+
useClass: typeof DefaultMarkdownRenderer;
|
|
292
|
+
useValue?: undefined;
|
|
293
|
+
};
|
|
294
|
+
|
|
262
295
|
/**
|
|
263
296
|
* The set of default Angular implementations for each component in the basic catalog.
|
|
264
297
|
*/
|
|
@@ -675,6 +708,11 @@ declare class ListComponent extends BasicCatalogComponent {
|
|
|
675
708
|
children: _angular_core.Signal<any[]>;
|
|
676
709
|
listTag: _angular_core.Signal<"ol" | "ul" | "div">;
|
|
677
710
|
styleType: _angular_core.Signal<"" | "none">;
|
|
711
|
+
/**
|
|
712
|
+
* Track-by function to ensure stable change detection for list items.
|
|
713
|
+
* Uses the full resolved path (`basePath/id`) to uniquely identify items.
|
|
714
|
+
*/
|
|
715
|
+
readonly trackBy: (index: number, item: Child) => string;
|
|
678
716
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ListComponent, never>;
|
|
679
717
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ListComponent, "a2ui-v09-list", never, { "props": { "alias": "props"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "componentId": { "alias": "componentId"; "required": false; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
680
718
|
}
|
|
@@ -960,5 +998,5 @@ declare class DateTimeInputComponent extends BasicCatalogComponent {
|
|
|
960
998
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<DateTimeInputComponent, "a2ui-v09-date-time-input", never, { "props": { "alias": "props"; "required": false; "isSignal": true; }; "surfaceId": { "alias": "surfaceId"; "required": true; "isSignal": true; }; "componentId": { "alias": "componentId"; "required": false; "isSignal": true; }; "dataContextPath": { "alias": "dataContextPath"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
961
999
|
}
|
|
962
1000
|
|
|
963
|
-
export { A2UI_RENDERER_CONFIG, A2uiRendererService, AngularCatalog, AudioPlayerComponent, BASIC_COMPONENTS, BasicCatalog, BasicCatalogBase, ButtonComponent, CardComponent, CheckBoxComponent, ChoicePickerComponent, ColumnComponent, ComponentBinder, ComponentHostComponent, DateTimeInputComponent, DividerComponent, IconComponent, ImageComponent, ListComponent, ModalComponent, RowComponent, SliderComponent, SurfaceComponent, TabsComponent, TextComponent, TextFieldComponent, VideoComponent, getNormalizedPath, toAngularSignal };
|
|
964
|
-
export type { AngularComponentImplementation, BasicCatalogOptions, BoundProperty, RendererConfiguration };
|
|
1001
|
+
export { A2UI_RENDERER_CONFIG, A2uiRendererService, AngularCatalog, AudioPlayerComponent, BASIC_COMPONENTS, BasicCatalog, BasicCatalogBase, ButtonComponent, CardComponent, CheckBoxComponent, ChoicePickerComponent, ColumnComponent, ComponentBinder, ComponentHostComponent, DateTimeInputComponent, DefaultMarkdownRenderer, DividerComponent, IconComponent, ImageComponent, ListComponent, MarkdownRenderer, ModalComponent, RowComponent, SliderComponent, SurfaceComponent, TabsComponent, TextComponent, TextFieldComponent, VideoComponent, getNormalizedPath, provideMarkdownRenderer, toAngularSignal };
|
|
1002
|
+
export type { AngularComponentImplementation, BasicCatalogOptions, BoundProperty, Child, MarkdownRendererOptions, RendererConfiguration };
|