@praxisui/list 9.0.0-beta.3 → 9.0.0-beta.5
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/README.md +1 -41
- package/docs/2026-03-executive-list-platform-backlog.md +13 -12
- package/docs/2026-03-executive-list-reference-checklist.md +3 -2
- package/docs/adr/2026-03-list-inline-expansion-v1.md +101 -7
- package/fesm2022/praxisui-list.mjs +177 -29
- package/package.json +6 -6
- package/src/lib/editors/praxis-list-config-editor.json-api.md +5 -4
- package/src/lib/praxis-list.json-api.md +13 -6
- package/types/praxisui-list.d.ts +20 -8
package/package.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@praxisui/list",
|
|
3
|
-
"version": "9.0.0-beta.
|
|
3
|
+
"version": "9.0.0-beta.5",
|
|
4
4
|
"description": "List components and helpers for Praxis UI.",
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "^21.0.0",
|
|
7
7
|
"@angular/core": "^21.0.0",
|
|
8
8
|
"@angular/material": "^21.0.0",
|
|
9
|
-
"@praxisui/dynamic-fields": "^9.0.0-beta.
|
|
9
|
+
"@praxisui/dynamic-fields": "^9.0.0-beta.5",
|
|
10
10
|
"rxjs": ">=7 <9",
|
|
11
11
|
"@angular/forms": "^21.0.0",
|
|
12
12
|
"@angular/router": "^21.0.0",
|
|
13
|
-
"@praxisui/ai": "^9.0.0-beta.
|
|
14
|
-
"@praxisui/core": "^9.0.0-beta.
|
|
15
|
-
"@praxisui/rich-content": "^9.0.0-beta.
|
|
16
|
-
"@praxisui/settings-panel": "^9.0.0-beta.
|
|
13
|
+
"@praxisui/ai": "^9.0.0-beta.5",
|
|
14
|
+
"@praxisui/core": "^9.0.0-beta.5",
|
|
15
|
+
"@praxisui/rich-content": "^9.0.0-beta.5",
|
|
16
|
+
"@praxisui/settings-panel": "^9.0.0-beta.5"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"tslib": "^2.3.0",
|
|
@@ -327,9 +327,10 @@ A integracao com host ocorre por `SettingsValueProvider`:
|
|
|
327
327
|
| `templating.features*` | Active | CRUD de features + modo de exibicao. |
|
|
328
328
|
| `templating.iconColorMap/chipColorMap/chipLabelMap` | Active | Editor de pares chave/valor com normalizacao. |
|
|
329
329
|
| `templating.skeleton.count` | Active | Controle numerico (>=0). |
|
|
330
|
-
| `actions[].id/icon/label/color/kind/buttonVariant/showIf` | Active | Authoring completo de
|
|
331
|
-
| `actions[].globalAction/emitLocal/showLoading/confirmation` | Active | Suporte a acoes globais estruturadas,
|
|
332
|
-
| `actions[].
|
|
330
|
+
| `actions[].id/icon/label/color/kind/buttonVariant/showIf/placement` | Active | Authoring completo de acoes por item; `showIf` usa Json Logic serializavel e `placement` controla a regiao visual da acao. |
|
|
331
|
+
| `actions[].globalAction/emitLocal/showLoading/confirmation` | Active | Suporte a acoes globais estruturadas, confirmacao para acoes locais e globais, loading por acao e emissao local opcional. |
|
|
332
|
+
| `actions[].globalAction.payload/payloadExpr` | Active | `payload` estruturado e `payloadExpr` avancado sao editaveis; ao definir um deles, o editor remove o outro para manter semantica canonica de execucao. |
|
|
333
|
+
| `actions[].emitPayload` | Declared-only | Preservado em JSON/config round-trip; nao aparece no editor visual de Ações porque nao altera o payload nativo da lista. |
|
|
333
334
|
| `ui.showSearch/searchField/searchPlaceholder` | Active | Bloco de busca. |
|
|
334
335
|
| `ui.showSort/sortOptions` | Active | Editor visual com deteccao de duplicatas. |
|
|
335
336
|
| `ui.showRange` | Active | Toggle dedicado. |
|
|
@@ -428,7 +429,7 @@ ref.saved$.subscribe((payload) => {
|
|
|
428
429
|
### Known limitations and pending investigation
|
|
429
430
|
|
|
430
431
|
1. Nao existe editor dedicado para `dataSource.data` (dataset local grande).
|
|
431
|
-
2. O editor
|
|
432
|
+
2. O editor preserva em JSON/config campos declared-only que podem nao ter efeito no runtime final, mas nao deve promove-los como controles visuais ativos.
|
|
432
433
|
3. `isDirty$` usa comparacao por snapshot JSON; mudancas de ordenacao de chaves/objetos podem gerar ruido em cenarios extremos.
|
|
433
434
|
4. Conversao automatica de `globalAction.payload` string para JSON e heuristica (so quando formato parece objeto/array).
|
|
434
435
|
|
|
@@ -30,8 +30,8 @@ source_of_truth:
|
|
|
30
30
|
- "projects/praxis-list/src/lib/ai/list-ai.adapter.ts"
|
|
31
31
|
- "projects/praxis-list/src/lib/ai/list-ai-capabilities.ts"
|
|
32
32
|
- "projects/praxis-list/src/lib/ai/list-context-pack.ts"
|
|
33
|
-
source_of_truth_last_verified: "2026-06-
|
|
34
|
-
last_updated: "2026-06-
|
|
33
|
+
source_of_truth_last_verified: "2026-06-16"
|
|
34
|
+
last_updated: "2026-06-16"
|
|
35
35
|
toc: true
|
|
36
36
|
sidebar: true
|
|
37
37
|
tags:
|
|
@@ -181,7 +181,7 @@ Este arquivo foi adaptado para o padrao canonico atual sem remover conteudo tecn
|
|
|
181
181
|
| Event | Payload | Trigger | Stability | Notes |
|
|
182
182
|
| ----------------- | -------------------- | --------------------------------------------------- | --------- | ------------------------------------ |
|
|
183
183
|
| `itemClick` | `ListItemEvent` | clique (mouse/teclado) em item | Partial | Preservado da documentação anterior. |
|
|
184
|
-
| `actionClick` | `ListActionEvent` | acao local de item
|
|
184
|
+
| `actionClick` | `ListActionEvent` | acao local de item, global com `emitLocal=true` ou acao de `rich-content` hospedado | Partial | `rich-content` inclui `payload?` e `source='rich-content'`. |
|
|
185
185
|
| `selectionChange` | `ListSelectionEvent` | alteracao de selecao em `mat-selection-list` | Partial | Preservado da documentação anterior. |
|
|
186
186
|
| `exportAction` | `any` | resultado ou erro de exportacao de colecao | Active | Usa `PraxisCollectionExportService`. |
|
|
187
187
|
|
|
@@ -658,14 +658,19 @@ Tipo declarado sem renderer dedicado:
|
|
|
658
658
|
| `expansion.sections` | Active | array de secoes da detail row |
|
|
659
659
|
| `expansion.sections[].id` | Active | identidade da secao |
|
|
660
660
|
| `expansion.sections[].title` | Active | titulo visivel da secao |
|
|
661
|
-
| `expansion.sections[].type` | Active | `info-list/chip-list/timeline/key-value` |
|
|
661
|
+
| `expansion.sections[].type` | Active | `info-list/chip-list/timeline/key-value/metadata/component/rich-content` |
|
|
662
662
|
| `expansion.sections[].itemsExpr` | Active | expr de colecao/objeto por item |
|
|
663
|
+
| `expansion.sections[].document` | Active | `RichContentDocument` canonico para secoes `rich-content` |
|
|
664
|
+
| `expansion.sections[].documentExpr` | Active | expr que resolve um `RichContentDocument` por item |
|
|
663
665
|
| `expansion.sections[].emptyLabel` | Active | mensagem vazia por secao |
|
|
664
666
|
|
|
665
667
|
Notas de UX/WCAG:
|
|
666
668
|
|
|
667
669
|
- `aria-expanded` e `aria-controls` ficam no owner real do trigger (`row` ou `icon`);
|
|
668
670
|
- com `selection.mode !== 'none'`, a selecao continua dona da linha e a expansao passa a ser acionada apenas pelo icone;
|
|
671
|
+
- `expansion.sections[].itemsExpr` pode resolver arrays/objetos JSON com placeholders; o runtime materializa a estrutura em vez de exibir JSON cru;
|
|
672
|
+
- para detalhes editoriais avancados, use `type='rich-content'` com `document`/`documentExpr`; a lista hospeda o contrato canonico `RichContentDocument` em vez de criar DSL visual paralela;
|
|
673
|
+
- ações dentro de seções `rich-content` são mediadas por `hostCapabilities` da própria lista, reemitidas em `actionClick` com `payload?` e `source='rich-content'`, e `confirmMessage` usa o mesmo `GLOBAL_DIALOG_SERVICE` das ações nativas;
|
|
669
674
|
- a V1 nao suporta markup arbitrario nem detail builders livres;
|
|
670
675
|
- `cards` e `tiles` permanecem fora de escopo.
|
|
671
676
|
- o scenario `executive-expansion` da doc page e uma composicao editorial canonica de validacao visual; campos como `balanceDisplay`, `limitDisplay`, `usageLabel`, `riskDisplay` e `riskLabel` pertencem ao dataset de exemplo, nao ao contrato base de `PraxisListConfig`.
|
|
@@ -681,7 +686,7 @@ Notas de UX/WCAG:
|
|
|
681
686
|
| `actions[].kind` | Active | `icon` ou `button` |
|
|
682
687
|
| `actions[].buttonVariant` | Active | `stroked/raised/flat` |
|
|
683
688
|
| `actions[].showIf` | Active | condição Json Logic avaliada no contexto `row` |
|
|
684
|
-
| `actions[].emitPayload` | Declared-only | sem uso no payload de `
|
|
689
|
+
| `actions[].emitPayload` | Declared-only | sem uso no payload de ações nativas; ações `rich-content` hospedadas podem emitir `payload?` próprio |
|
|
685
690
|
| `actions[].globalAction` | Active | integra com `GlobalActionService.executeRef`; suporta `navigation.openRoute` para navegação interna canônica |
|
|
686
691
|
| `actions[].globalAction.actionId` | Active | identificador canonico da acao global |
|
|
687
692
|
| `actions[].globalAction.payload` | Active | template/JSON resolvido recursivamente, inclusive `item.id` em rotas internas |
|
|
@@ -849,8 +854,10 @@ AI:
|
|
|
849
854
|
| `expansion.sections` | Active | secoes do detail row |
|
|
850
855
|
| `expansion.sections[].id` | Active | id |
|
|
851
856
|
| `expansion.sections[].title` | Active | title |
|
|
852
|
-
| `expansion.sections[].type` | Active | info-list/chip-list/timeline/key-value |
|
|
857
|
+
| `expansion.sections[].type` | Active | info-list/chip-list/timeline/key-value/metadata/component/rich-content |
|
|
853
858
|
| `expansion.sections[].itemsExpr` | Active | expr |
|
|
859
|
+
| `expansion.sections[].document` | Active | `RichContentDocument` para `rich-content` |
|
|
860
|
+
| `expansion.sections[].documentExpr` | Active | expr que resolve `RichContentDocument` |
|
|
854
861
|
| `expansion.sections[].emptyLabel` | Active | empty state da secao |
|
|
855
862
|
| `actions` | Partial | bloco de acoes |
|
|
856
863
|
| `actions[].id` | Active | id |
|
package/types/praxisui-list.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ import { MatSelectionListChange } from '@angular/material/list';
|
|
|
6
6
|
import { MatPaginatorSelectConfig, PageEvent } from '@angular/material/paginator';
|
|
7
7
|
import { FormGroup, FormControl } from '@angular/forms';
|
|
8
8
|
import * as _praxisui_core from '@praxisui/core';
|
|
9
|
-
import { PraxisExportFormat, PraxisExportScope, PraxisRuntimeConditionalEffectRule, JsonLogicExpression, GlobalActionRef, LocalizationConfig, AiCapability, PraxisDataQueryContext, RichBlockNode, GlobalActionCatalogEntry, SurfaceOpenPayload, SettingsValueProvider as SettingsValueProvider$1, RichPresenterNode, RichComposeNode, ComponentDocMeta, AiCapabilityCategory, AiCapabilityCatalog, AiValueKind, ComponentAuthoringManifest } from '@praxisui/core';
|
|
9
|
+
import { PraxisExportFormat, PraxisExportScope, PraxisRuntimeConditionalEffectRule, JsonLogicExpression, RichContentDocument, GlobalActionRef, LocalizationConfig, AiCapability, PraxisDataQueryContext, RichBlockNode, RichBlockHostCapabilities, GlobalActionCatalogEntry, SurfaceOpenPayload, SettingsValueProvider as SettingsValueProvider$1, RichPresenterNode, RichComposeNode, ComponentDocMeta, AiCapabilityCategory, AiCapabilityCatalog, AiValueKind, ComponentAuthoringManifest } from '@praxisui/core';
|
|
10
10
|
import { BaseAiAdapter, AiResponseCompileResult, PatchResult, PraxisAssistantTurnViewState, PraxisAssistantShellLayout, PraxisAssistantShellLabels, PraxisAssistantSessionSnapshot, PraxisAssistantShellQuickReply, PraxisAssistantShellMessage } from '@praxisui/ai';
|
|
11
11
|
import { SettingsValueProvider } from '@praxisui/settings-panel';
|
|
12
12
|
import * as _praxisui_list from '@praxisui/list';
|
|
@@ -91,12 +91,16 @@ interface TemplateFeatureDef extends TemplateDef {
|
|
|
91
91
|
icon?: string;
|
|
92
92
|
}
|
|
93
93
|
type TemplatingFeatureDef = ListFeatureDef | TemplateFeatureDef;
|
|
94
|
-
type ListExpansionSectionType = 'info-list' | 'chip-list' | 'timeline' | 'key-value' | 'metadata' | 'component';
|
|
94
|
+
type ListExpansionSectionType = 'info-list' | 'chip-list' | 'timeline' | 'key-value' | 'metadata' | 'component' | 'rich-content';
|
|
95
95
|
interface ListExpansionSectionDef {
|
|
96
96
|
id: string;
|
|
97
97
|
title?: string;
|
|
98
98
|
type: ListExpansionSectionType;
|
|
99
99
|
itemsExpr?: string;
|
|
100
|
+
/** Canonical rich-content document rendered by @praxisui/rich-content. */
|
|
101
|
+
document?: RichContentDocument;
|
|
102
|
+
/** Expression resolving to a RichContentDocument, including JSON strings from row data. */
|
|
103
|
+
documentExpr?: string;
|
|
100
104
|
emptyLabel?: string;
|
|
101
105
|
metadata?: {
|
|
102
106
|
orientation?: 'horizontal' | 'vertical';
|
|
@@ -265,7 +269,7 @@ interface PraxisListConfig {
|
|
|
265
269
|
schemaContract?: {
|
|
266
270
|
kind: 'praxis.detail.schema';
|
|
267
271
|
version: string;
|
|
268
|
-
allowedNodes?: Array<'info-list' | 'chip-list' | 'timeline' | 'key-value' | 'metadata' | 'component'>;
|
|
272
|
+
allowedNodes?: Array<'info-list' | 'chip-list' | 'timeline' | 'key-value' | 'metadata' | 'component' | 'rich-content'>;
|
|
269
273
|
maxSections?: number;
|
|
270
274
|
maxItemsPerSection?: number;
|
|
271
275
|
requireSectionIds?: boolean;
|
|
@@ -347,6 +351,8 @@ interface ListActionEvent {
|
|
|
347
351
|
actionId: string;
|
|
348
352
|
item: any;
|
|
349
353
|
index: number;
|
|
354
|
+
payload?: unknown;
|
|
355
|
+
source?: 'rich-content';
|
|
350
356
|
}
|
|
351
357
|
interface ListSelectionEvent {
|
|
352
358
|
mode: 'single' | 'multiple';
|
|
@@ -773,6 +779,10 @@ declare class PraxisList implements OnInit, OnChanges, AfterViewInit, OnDestroy
|
|
|
773
779
|
expansionSections(item: any): ListExpansionSectionDef[];
|
|
774
780
|
expansionSectionItems(item: any, section: ListExpansionSectionDef, index?: number): any[];
|
|
775
781
|
expansionSectionHasContent(item: any, section: ListExpansionSectionDef, index?: number): boolean;
|
|
782
|
+
expansionRichContentDocument(item: any, section: ListExpansionSectionDef, index?: number): RichContentDocument | null;
|
|
783
|
+
expansionRichContentContext(item: any, _section: ListExpansionSectionDef, index?: number): Record<string, any>;
|
|
784
|
+
expansionRichContentHostCapabilities(item: any, _section: ListExpansionSectionDef, index?: number): RichBlockHostCapabilities;
|
|
785
|
+
private isRichContentDocument;
|
|
776
786
|
expansionItemLabel(value: any): string;
|
|
777
787
|
expansionInfoTitle(value: any): string;
|
|
778
788
|
expansionInfoValue(value: any): string;
|
|
@@ -813,6 +823,7 @@ declare class PraxisList implements OnInit, OnChanges, AfterViewInit, OnDestroy
|
|
|
813
823
|
private toggleExpanded;
|
|
814
824
|
private syncExpansionState;
|
|
815
825
|
private itemExpansionKey;
|
|
826
|
+
private itemRenderKey;
|
|
816
827
|
private itemStableKey;
|
|
817
828
|
private isStablePrimitiveKey;
|
|
818
829
|
t(key: string, fallback: string): string;
|
|
@@ -820,6 +831,7 @@ declare class PraxisList implements OnInit, OnChanges, AfterViewInit, OnDestroy
|
|
|
820
831
|
private ensureExpansionItemObjectId;
|
|
821
832
|
private sanitizeDomId;
|
|
822
833
|
private evaluateExpansionExpr;
|
|
834
|
+
private parseStructuredExpansionValue;
|
|
823
835
|
private normalizeExpansionItems;
|
|
824
836
|
private normalizeKeyValueItems;
|
|
825
837
|
static ɵfac: i0.ɵɵFactoryDeclaration<PraxisList, never>;
|
|
@@ -1444,6 +1456,10 @@ declare class PraxisListConfigEditor implements SettingsValueProvider, DoCheck {
|
|
|
1444
1456
|
globalAction?: GlobalActionRef;
|
|
1445
1457
|
}): string;
|
|
1446
1458
|
onGlobalActionPayloadTextChange(action: any, value: string): void;
|
|
1459
|
+
getGlobalActionPayloadExprText(action: {
|
|
1460
|
+
globalAction?: GlobalActionRef;
|
|
1461
|
+
}): string;
|
|
1462
|
+
onGlobalActionPayloadExprTextChange(action: any, value: string): void;
|
|
1447
1463
|
isGlobalActionPayloadInvalid(action: {
|
|
1448
1464
|
globalAction?: GlobalActionRef;
|
|
1449
1465
|
}): boolean;
|
|
@@ -1894,7 +1910,7 @@ declare class PraxisListDocPageComponent {
|
|
|
1894
1910
|
schemaContract?: {
|
|
1895
1911
|
kind: "praxis.detail.schema";
|
|
1896
1912
|
version: string;
|
|
1897
|
-
allowedNodes?: Array<"info-list" | "chip-list" | "timeline" | "key-value" | "metadata" | "component">;
|
|
1913
|
+
allowedNodes?: Array<"info-list" | "chip-list" | "timeline" | "key-value" | "metadata" | "component" | "rich-content">;
|
|
1898
1914
|
maxSections?: number;
|
|
1899
1915
|
maxItemsPerSection?: number;
|
|
1900
1916
|
requireSectionIds?: boolean;
|
|
@@ -2039,7 +2055,6 @@ declare const PRAXIS_LIST_EN_US: {
|
|
|
2039
2055
|
readonly 'Action color': "Action color";
|
|
2040
2056
|
readonly 'Custom color': "Custom color";
|
|
2041
2057
|
readonly 'Use custom color': "Use custom color";
|
|
2042
|
-
readonly 'Action payload': "Action payload";
|
|
2043
2058
|
readonly Default: "Default";
|
|
2044
2059
|
readonly "Show when (e.g.: ${item.status} == 'done')": "Show when (e.g.: ${item.status} == 'done')";
|
|
2045
2060
|
readonly "Supported syntax: \"${item.field} == 'value'\". Advanced expressions are not evaluated.": "Supported syntax: \"${item.field} == 'value'\". Advanced expressions are not evaluated.";
|
|
@@ -2082,7 +2097,6 @@ declare const PRAXIS_LIST_EN_US: {
|
|
|
2082
2097
|
readonly 'Example:': "Example:";
|
|
2083
2098
|
readonly Item: "Item";
|
|
2084
2099
|
readonly Value: "Value";
|
|
2085
|
-
readonly 'Payload emitted by the action.': "Payload emitted by the action.";
|
|
2086
2100
|
readonly 'Modern tiles preset': "Modern tiles preset";
|
|
2087
2101
|
readonly List: "List";
|
|
2088
2102
|
readonly Lines: "Lines";
|
|
@@ -2280,7 +2294,6 @@ declare const PRAXIS_LIST_PT_BR: {
|
|
|
2280
2294
|
readonly 'Action color': "Cor da ação";
|
|
2281
2295
|
readonly 'Custom color': "Cor personalizada";
|
|
2282
2296
|
readonly 'Use custom color': "Usar cor personalizada";
|
|
2283
|
-
readonly 'Action payload': "Dados da ação (Payload)";
|
|
2284
2297
|
readonly Default: "Padrão";
|
|
2285
2298
|
readonly "Show when (e.g.: ${item.status} == 'done')": "Exibir quando (ex.: ${item.status} == 'concluído')";
|
|
2286
2299
|
readonly "Supported syntax: \"${item.field} == 'value'\". Advanced expressions are not evaluated.": "Sintaxe suportada: \"${item.field} == 'valor'\". Expressões avançadas não são avaliadas.";
|
|
@@ -2323,7 +2336,6 @@ declare const PRAXIS_LIST_PT_BR: {
|
|
|
2323
2336
|
readonly 'Example:': "Exemplo:";
|
|
2324
2337
|
readonly Item: "Item";
|
|
2325
2338
|
readonly Value: "Valor";
|
|
2326
|
-
readonly 'Payload emitted by the action.': "Dados (payload) emitidos pela ação.";
|
|
2327
2339
|
readonly 'Modern tiles preset': "Predefinição de blocos modernos";
|
|
2328
2340
|
readonly List: "Lista";
|
|
2329
2341
|
readonly Lines: "Linhas";
|