Skip to content

Commit fdf96b3

Browse files
authored
client: enable markdown rendering for other samples (google#902)
It integrates @a2ui/markdown-it as the markdown renderer for all samples. This resolves issues where markdown sytax (sch as `##` and `####` header) was displayed as plain text and ensures that links and button labels are correctly rendered as shown in the updated UI.
1 parent 8178322 commit fdf96b3

3 files changed

Lines changed: 8 additions & 2 deletions

File tree

samples/client/angular/angular.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -443,8 +443,8 @@
443443
"budgets": [
444444
{
445445
"type": "initial",
446-
"maximumWarning": "500KB",
447-
"maximumError": "1MB"
446+
"maximumWarning": "1.5MB",
447+
"maximumError": "2MB"
448448
},
449449
{
450450
"type": "anyComponentStyle",

samples/client/angular/projects/orchestrator/src/app/app.config.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ import { provideCharts, withDefaultRegisterables } from 'ng2-charts';
3131
import { DEMO_CATALOG } from '../a2ui-catalog/catalog';
3232
import { A2aServiceImpl } from '../services/a2a-service-impl';
3333
import { routes } from './app.routes';
34+
import { provideMarkdownRenderer } from '@a2ui/angular';
35+
import { renderMarkdown } from '@a2ui/markdown-it';
3436

3537
export const appConfig: ApplicationConfig = {
3638
providers: [
@@ -39,6 +41,7 @@ export const appConfig: ApplicationConfig = {
3941
provideRouter(routes),
4042
provideClientHydration(withEventReplay()),
4143
provideCharts(withDefaultRegisterables()),
44+
provideMarkdownRenderer(renderMarkdown),
4245
configureChatCanvasFeatures(
4346
usingA2aService(A2aServiceImpl),
4447
usingA2uiRenderers(DEMO_CATALOG),

samples/client/angular/projects/rizzcharts/src/app/app.config.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ import { theme } from './theme';
3434

3535
import { provideClientHydration, withEventReplay } from '@angular/platform-browser';
3636
import { routes } from './app.routes';
37+
import { provideMarkdownRenderer } from '@a2ui/angular';
38+
import { renderMarkdown } from '@a2ui/markdown-it';
3739

3840
export const appConfig: ApplicationConfig = {
3941
providers: [
@@ -42,6 +44,7 @@ export const appConfig: ApplicationConfig = {
4244
provideRouter(routes),
4345
provideClientHydration(withEventReplay()),
4446
provideCharts(withDefaultRegisterables()),
47+
provideMarkdownRenderer(renderMarkdown),
4548
configureChatCanvasFeatures(
4649
usingA2aService(A2aService),
4750
usingA2uiRenderers(RIZZ_CHARTS_CATALOG, theme),

0 commit comments

Comments
 (0)