pi-apexlang 0.2.2 → 0.4.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 (239) hide show
  1. package/README.md +22 -5
  2. package/THIRD_PARTY_NOTICES.md +2 -2
  3. package/UPSTREAM.json +2 -2
  4. package/docs/assets/overview.en.png +0 -0
  5. package/docs/assets/overview.en.svg +89 -0
  6. package/docs/assets/overview.uk.png +0 -0
  7. package/docs/assets/overview.uk.svg +89 -0
  8. package/docs/en/README.md +41 -0
  9. package/docs/en/architecture.md +73 -0
  10. package/docs/en/getting-started.md +77 -0
  11. package/docs/en/maintenance.md +83 -0
  12. package/docs/en/tool-reference.md +85 -0
  13. package/docs/uk/README.md +41 -0
  14. package/docs/uk/architecture.md +73 -0
  15. package/docs/uk/getting-started.md +77 -0
  16. package/docs/uk/maintenance.md +83 -0
  17. package/docs/uk/tool-reference.md +85 -0
  18. package/extensions/apexlang/index.ts +19 -10
  19. package/extensions/lib/apexlang-cli.d.mts +1 -2
  20. package/extensions/lib/apexlang-cli.mjs +18 -13
  21. package/extensions/lib/apexlang-local-validate.mjs +83 -0
  22. package/extensions/lib/apexlang-local-validator.py +116 -0
  23. package/extensions/lib/apexlang-runtime-validate.mjs +76 -0
  24. package/package.json +2 -1
  25. package/skills/apexlang/APEXlang Skills and Workflows.md +325 -0
  26. package/skills/apexlang/README.md +6 -6
  27. package/skills/apexlang/RELEASE-NOTES.md +2 -2
  28. package/skills/apexlang/SKILL.md +24 -19
  29. package/skills/apexlang/agents/openai.yaml +4 -3
  30. package/skills/apexlang/assets/apex-generation/components.registry.json +1001 -16
  31. package/skills/apexlang/assets/apexlang/domains-catalog.json +6 -1
  32. package/skills/apexlang/assets/component-attributes.json +1924 -180
  33. package/skills/apexlang/assets/component-policies.json +19 -10
  34. package/skills/apexlang/assets/contracts/grammar-semantic-rules.json +134 -0
  35. package/skills/apexlang/assets/contracts/package-layers.json +56 -0
  36. package/skills/apexlang/assets/contracts/page-construction-packs.json +154 -0
  37. package/skills/apexlang/assets/contracts/page-patterns.json +119 -0
  38. package/skills/apexlang/assets/grammar/apexlang.ebnf +11743 -0
  39. package/skills/apexlang/assets/indexes/font-apex-icon-index.json +1699 -0
  40. package/skills/apexlang/assets/routing-catalog-main.json +11 -10
  41. package/skills/apexlang/assets/routing-load-policy.json +35 -9
  42. package/skills/apexlang/assets/rules-mapping.json +110 -2
  43. package/skills/apexlang/assets/rules.catalog.json +1298 -0
  44. package/skills/apexlang/assets/validator-fix-recipes.json +372 -17
  45. package/skills/apexlang/assets/workspace-intelligence.json +7 -10
  46. package/skills/apexlang/manifest.json +268 -12
  47. package/skills/apexlang/references/domains/README.md +1 -1
  48. package/skills/apexlang/references/domains/page-components/buttons.md +2 -2
  49. package/skills/apexlang/references/domains/page-components/page-items.md +3 -3
  50. package/skills/apexlang/references/domains/page-components/regions/region-display-selector/workflow-region-display-selector.md +69 -0
  51. package/skills/apexlang/references/domains/page-components/regions.md +1 -0
  52. package/skills/apexlang/references/domains/template-components/comments.md +61 -0
  53. package/skills/apexlang/references/domains/template-components/registry.md +2 -0
  54. package/skills/apexlang/references/domains/template-components/templates.md +47 -0
  55. package/skills/apexlang/references/domains/template-components/timeline.md +51 -0
  56. package/skills/apexlang/references/ops/one-message-router-contract.md +2 -2
  57. package/skills/apexlang/references/ops/runtime-gates/01-direct-sqlcl-import.md +1 -1
  58. package/skills/apexlang/references/ops/runtime-gates/02-direct-sqlcl-validate-gate.md +1 -1
  59. package/skills/apexlang/references/ops/runtime-gates.md +17 -16
  60. package/skills/apexlang/references/ops/sqlcl-agents/00-connection-gate.md +7 -7
  61. package/skills/apexlang/references/ops/sqlcl.md +7 -8
  62. package/skills/apexlang/references/policies/compiler-prop-map.md +6 -4
  63. package/skills/apexlang/references/policies/governance/00-governance.md +2 -2
  64. package/skills/apexlang/references/policies/memory-bank/00-guard/ai.guard.md +126 -922
  65. package/skills/apexlang/references/policies/memory-bank/20-data/apex.logic.md +3 -3
  66. package/skills/apexlang/references/policies/memory-bank/20-data/db.connection.md +9 -11
  67. package/skills/apexlang/references/policies/memory-bank/30-pages/apex.cards-page.md +95 -0
  68. package/skills/apexlang/references/policies/memory-bank/30-pages/apex.page.md +2 -2
  69. package/skills/apexlang/references/policies/memory-bank/30-pages/apex.smart-filter-search.md +145 -74
  70. package/skills/apexlang/references/policies/memory-bank/40-components/apex.region-interactions.md +9 -2
  71. package/skills/apexlang/references/policies/memory-bank/40-components/apex.region-media.md +6 -5
  72. package/skills/apexlang/references/policies/memory-bank/systemPatterns.md +9 -1
  73. package/skills/apexlang/references/workflows/apex-generation/agents/20-agent-draft.md +51 -232
  74. package/skills/apexlang/references/workflows/apex-generation/agents/30-agent-critique.md +49 -449
  75. package/skills/apexlang/references/workflows/apex-generation/agents/40-agent-revision.md +38 -238
  76. package/skills/apexlang/references/workflows/apex-generation/nlu/nlu-routing-test-matrix.md +8 -2
  77. package/skills/apexlang/references/workflows/apex-generation/nlu/nlu-routing-validation-notes.md +19 -3
  78. package/skills/apexlang/references/workflows/apex-generation/registry.md +15 -1
  79. package/skills/apexlang/references/workflows/apex-generation/templates.md +1 -1
  80. package/skills/apexlang/references/workflows/apex-generation.md +1 -1
  81. package/skills/apexlang/references/workflows/apexlang/apexlang-execution-model.md +5 -5
  82. package/skills/apexlang/references/workflows/apexlang/prompt-contracts.md +81 -10
  83. package/skills/apexlang/references/workflows/apexlang/workflow-create-app-from-fr-and-model.md +18 -7
  84. package/skills/apexlang/release-notes.json +156 -0
  85. package/skills/apexlang/runtime/grammar_contract.mjs +1166 -0
  86. package/skills/apexlang/runtime/internal/python/format_apexlang.py +210 -0
  87. package/skills/apexlang/runtime/internal/python/validate_apexlang.py +14142 -5843
  88. package/skills/apexlang/runtime/internal/python/validator_common.py +2 -0
  89. package/skills/apexlang/runtime/lib/catalogs.mjs +1026 -0
  90. package/skills/apexlang/runtime/lib/common.mjs +35 -0
  91. package/skills/apexlang/runtime/runtime.bundle.mjs +457 -57
  92. package/skills/apexlang/templates/items/combobox/combobox.explicit-defaults.md +1 -1
  93. package/skills/apexlang/templates/items/date-picker/date-picker._common.md +1 -1
  94. package/skills/apexlang/templates/items/date-picker/date-picker.explicit-defaults.md +1 -1
  95. package/skills/apexlang/templates/items/file-upload/file-upload._common.md +30 -24
  96. package/skills/apexlang/templates/items/file-upload/file-upload.compact-template.md +6 -0
  97. package/skills/apexlang/templates/items/file-upload/file-upload.explicit-defaults.md +23 -8
  98. package/skills/apexlang/templates/items/file-upload/file-upload.minimal.md +6 -0
  99. package/skills/apexlang/templates/items/hidden-item/hidden-item._common.md +1 -1
  100. package/skills/apexlang/templates/items/hidden-item/hidden-item.explicit-defaults.md +1 -1
  101. package/skills/apexlang/templates/items/items._common.md +3 -2
  102. package/skills/apexlang/templates/items/list-manager/list-manager.explicit-defaults.md +1 -1
  103. package/skills/apexlang/templates/items/markdown-editor/markdown-editor._common.md +1 -1
  104. package/skills/apexlang/templates/items/markdown-editor/markdown-editor.explicit-defaults.md +1 -1
  105. package/skills/apexlang/templates/items/number-field/number-field._common.md +8 -6
  106. package/skills/apexlang/templates/items/number-field/number-field.explicit-defaults.md +12 -2
  107. package/skills/apexlang/templates/items/popup-lov/popup-lov.explicit-defaults.md +1 -1
  108. package/skills/apexlang/templates/items/rich-text-editor/rich-text-editor._common.md +1 -1
  109. package/skills/apexlang/templates/items/rich-text-editor/rich-text-editor.explicit-defaults.md +1 -1
  110. package/skills/apexlang/templates/items/select-many/standard.md +1 -1
  111. package/skills/apexlang/templates/items/shuttle/shuttle.explicit-defaults.md +1 -1
  112. package/skills/apexlang/templates/items/switch/switch._common.md +8 -8
  113. package/skills/apexlang/templates/items/switch/switch.explicit-defaults.md +1 -1
  114. package/skills/apexlang/templates/items/text-area/text-area._common.md +2 -3
  115. package/skills/apexlang/templates/items/text-area/text-area.explicit-defaults.md +1 -1
  116. package/skills/apexlang/templates/items/text-area/text-area.required-length.md +1 -3
  117. package/skills/apexlang/templates/items/text-autocomplete/text-autocomplete.explicit-defaults.md +1 -1
  118. package/skills/apexlang/templates/items/text-autocomplete/text-autocomplete.required-length.md +1 -3
  119. package/skills/apexlang/templates/items/text-field/text-field._common.md +2 -3
  120. package/skills/apexlang/templates/items/text-field/text-field.explicit-defaults.md +1 -1
  121. package/skills/apexlang/templates/items/text-field/text-field.required-length.md +1 -3
  122. package/skills/apexlang/templates/page-examples/faceted-search/faceted-search.example.md +0 -5
  123. package/skills/apexlang/templates/page-examples/form-page/form-page.example.md +0 -9
  124. package/skills/apexlang/templates/page-examples/interactive-report-page/interactive-report-page.example.md +2 -2
  125. package/skills/apexlang/templates/page-examples/login-page/login-page.example.md +0 -8
  126. package/skills/apexlang/templates/page-examples/task-definition-initiated-tasks-page/task-definition-initiated-tasks-page.example.md +7 -17
  127. package/skills/apexlang/templates/page-examples/task-definition-my-tasks-page/task-definition-my-tasks-page.example.md +7 -65
  128. package/skills/apexlang/templates/page-examples/task-definition-task-details/task-definition-task-details.example.md +38 -201
  129. package/skills/apexlang/templates/region-components/calendar/calendar.custom-styling.md +3 -1
  130. package/skills/apexlang/templates/region-components/calendar/calendar.faceted-search.md +3 -2
  131. package/skills/apexlang/templates/region-components/cards/README.md +12 -4
  132. package/skills/apexlang/templates/region-components/cards/cards._common.md +176 -37
  133. package/skills/apexlang/templates/region-components/cards/cards._index.md +2 -1
  134. package/skills/apexlang/templates/region-components/cards/cards.refresh-after-dialog.md +46 -0
  135. package/skills/apexlang/templates/region-components/cards/cards.refresh-on-change.md +58 -0
  136. package/skills/apexlang/templates/region-components/cards/cards.rest-source.md +54 -18
  137. package/skills/apexlang/templates/region-components/cards/cards.standard.md +37 -21
  138. package/skills/apexlang/templates/region-components/chart/chart._series._common.md +1 -4
  139. package/skills/apexlang/templates/region-components/chart/chart.pie.md +6 -2
  140. package/skills/apexlang/templates/region-components/chart/chart.status-meter-gauge.md +1 -1
  141. package/skills/apexlang/templates/region-components/chart/chart.stock.md +2 -0
  142. package/skills/apexlang/templates/region-components/chart/features/chart.feature-chart-links.md +9 -7
  143. package/skills/apexlang/templates/region-components/faceted-search/faceted-search._common.md +1 -14
  144. package/skills/apexlang/templates/region-components/form/form._items._common.md +1 -5
  145. package/skills/apexlang/templates/region-components/interactive-report/interactive-report._columns._common.md +2 -6
  146. package/skills/apexlang/templates/region-components/interactive-report/interactive-report.page-header-actions.md +1 -7
  147. package/skills/apexlang/templates/region-components/list/README.md +1 -1
  148. package/skills/apexlang/templates/region-components/list/list._common.md +1 -1
  149. package/skills/apexlang/templates/region-components/map/map.backgrounds.md +12 -10
  150. package/skills/apexlang/templates/region-components/map/map.layer.extruded-polygons.md +16 -12
  151. package/skills/apexlang/templates/region-components/map/map.layer.heat-map.md +10 -7
  152. package/skills/apexlang/templates/region-components/map/map.layer.lines.md +10 -8
  153. package/skills/apexlang/templates/region-components/map/map.layer.polygons.md +21 -18
  154. package/skills/apexlang/templates/region-components/map/map.region.background-custom.md +25 -19
  155. package/skills/apexlang/templates/region-components/map/map.region.background-shared.md +19 -13
  156. package/skills/apexlang/templates/region-components/map/map.region.bbox-sql.md +13 -13
  157. package/skills/apexlang/templates/region-components/map/map.region.bbox-static.md +2 -2
  158. package/skills/apexlang/templates/region-components/map/map.region.browser-location.md +3 -7
  159. package/skills/apexlang/templates/region-components/map/map.region.init-position-sql.md +7 -7
  160. package/skills/apexlang/templates/region-components/region-display-selector/README.md +5 -2
  161. package/skills/apexlang/templates/region-components/region-display-selector/region-display-selector._common.md +60 -7
  162. package/skills/apexlang/templates/region-components/region-display-selector/region-display-selector._index.md +4 -1
  163. package/skills/apexlang/templates/region-components/region-display-selector/region-display-selector.permutations.md +55 -0
  164. package/skills/apexlang/templates/region-components/region-display-selector/region-display-selector.standard.md +91 -5
  165. package/skills/apexlang/templates/region-components/smart-filter-search/README.md +6 -2
  166. package/skills/apexlang/templates/region-components/smart-filter-search/smart-filter-search._common.md +107 -46
  167. package/skills/apexlang/templates/region-components/smart-filter-search/smart-filter-search._index.md +4 -3
  168. package/skills/apexlang/templates/region-components/smart-filter-search/smart-filter-search.standard.md +33 -17
  169. package/skills/apexlang/templates/shared-components/component-settings/component-settings._common.md +1 -0
  170. package/skills/apexlang/templates/shared-components/component-settings.example.md +1 -0
  171. package/skills/apexlang/templates/shared-components/email-templates.example.md +1 -1
  172. package/skills/apexlang/templates/shared-components/rest-data-sources/example_rest_data_source.example.md +40 -46
  173. package/skills/apexlang/templates/shared-components/task-definitions/action-task.example.md +2 -30
  174. package/skills/apexlang/templates/shared-components/task-definitions/approve-request.example.md +3 -31
  175. package/skills/apexlang/templates/template-components/README.md +27 -15
  176. package/skills/apexlang/templates/template-components/avatar/README.md +56 -0
  177. package/skills/apexlang/templates/template-components/avatar/avatar._common.md +149 -0
  178. package/skills/apexlang/templates/template-components/avatar/avatar._index.md +42 -0
  179. package/skills/apexlang/templates/template-components/{avatar._template_options.md → avatar/avatar._template_options.md} +1 -1
  180. package/skills/apexlang/templates/template-components/avatar/avatar.report-icon.md +48 -0
  181. package/skills/apexlang/templates/template-components/avatar/avatar.report-image-url-column.md +62 -0
  182. package/skills/apexlang/templates/template-components/avatar/avatar.report-initials.md +54 -0
  183. package/skills/apexlang/templates/template-components/badge/README.md +38 -0
  184. package/skills/apexlang/templates/template-components/badge/badge._common.md +183 -0
  185. package/skills/apexlang/templates/template-components/badge/badge._index.md +20 -0
  186. package/skills/apexlang/templates/template-components/badge/badge.report-link.md +66 -0
  187. package/skills/apexlang/templates/template-components/badge/badge.report-minimal.md +76 -0
  188. package/skills/apexlang/templates/template-components/comments/README.md +20 -0
  189. package/skills/apexlang/templates/template-components/comments/comments._common.md +43 -0
  190. package/skills/apexlang/templates/template-components/comments/comments._index.md +25 -0
  191. package/skills/apexlang/templates/template-components/{comments._template_options.md → comments/comments._template_options.md} +2 -1
  192. package/skills/apexlang/templates/template-components/comments/comments.apex-task-comments.md +77 -0
  193. package/skills/apexlang/templates/template-components/comments/comments.partial-column.md +120 -0
  194. package/skills/apexlang/templates/template-components/comments/comments.permutations.md +425 -0
  195. package/skills/apexlang/templates/template-components/content-row/README.md +1 -1
  196. package/skills/apexlang/templates/template-components/content-row/content-row._common.md +1 -1
  197. package/skills/apexlang/templates/template-components/content-row/content-row._index.md +1 -1
  198. package/skills/apexlang/templates/template-components/content-row/content-row._template_options.md +1 -1
  199. package/skills/apexlang/templates/template-components/flexbox-container/README.md +9 -0
  200. package/skills/apexlang/templates/template-components/flexbox-container/flexbox-container._index.md +13 -0
  201. package/skills/apexlang/templates/template-components/media-list/README.md +100 -0
  202. package/skills/apexlang/templates/template-components/media-list/media-list._common.md +174 -0
  203. package/skills/apexlang/templates/template-components/media-list/media-list._index.md +50 -0
  204. package/skills/apexlang/templates/template-components/{media-list._template_options.md → media-list/media-list._template_options.md} +8 -2
  205. package/skills/apexlang/templates/template-components/media-list/media-list.partial.md +50 -0
  206. package/skills/apexlang/templates/template-components/media-list/media-list.report-avatar-badge.md +76 -0
  207. package/skills/apexlang/templates/template-components/media-list/media-list.report-base.md +71 -0
  208. package/skills/apexlang/templates/template-components/media-list/media-list.report-grouped.md +40 -0
  209. package/skills/apexlang/templates/template-components/media-list/media-list.report-layouts.md +50 -0
  210. package/skills/apexlang/templates/template-components/media-list/media-list.report-link.md +53 -0
  211. package/skills/apexlang/templates/template-components/metric-card/README.md +19 -4
  212. package/skills/apexlang/templates/template-components/metric-card/metric-card._common.md +122 -29
  213. package/skills/apexlang/templates/template-components/metric-card/metric-card._index.md +6 -0
  214. package/skills/apexlang/templates/template-components/metric-card/metric-card._template_options.md +47 -2
  215. package/skills/apexlang/templates/template-components/metric-card/metric-card.partial-minimal.md +51 -0
  216. package/skills/apexlang/templates/template-components/metric-card/metric-card.permutations.md +56 -0
  217. package/skills/apexlang/templates/template-components/metric-card/metric-card.report-avatar-badge.md +98 -0
  218. package/skills/apexlang/templates/template-components/metric-card/metric-card.report-grouping-selection.md +131 -0
  219. package/skills/apexlang/templates/template-components/metric-card/metric-card.report-link.md +66 -0
  220. package/skills/apexlang/templates/template-components/metric-card/metric-card.report-minimal.md +97 -0
  221. package/skills/apexlang/templates/template-components/template-components.registry.json +90 -1
  222. package/skills/apexlang/templates/template-components/timeline/README.md +19 -0
  223. package/skills/apexlang/templates/template-components/timeline/timeline._common.md +43 -0
  224. package/skills/apexlang/templates/template-components/timeline/timeline._index.md +24 -0
  225. package/skills/apexlang/templates/template-components/{timeline._template_options.md → timeline/timeline._template_options.md} +2 -1
  226. package/skills/apexlang/templates/template-components/timeline/timeline.permutations.md +399 -0
  227. package/skills/apexlang/templates/template-components/timeline/timeline.report-sample-data.md +168 -0
  228. package/skills/apexlang/templates/workspace-components/credentials/credentials-for-open-ai.example.md +1 -1
  229. package/skills/apexlang/templates/workspace-components/generative-ai-services/open-ai.example.md +8 -6
  230. package/skills/apexlang/tools/apexctl.mjs +167 -4
  231. package/skills/apexlang/tools/compiler-truth-audit.mjs +95 -63
  232. package/skills/apexlang/tools/query-valid-props-context.mjs +30 -0
  233. package/skills/apexlang/tools/query-valid-props-normalize.mjs +1 -0
  234. package/skills/apexlang/tools/query-valid-props-runtime.mjs +13 -8
  235. package/skills/apexlang/tools/query-valid-props-semantics.mjs +391 -0
  236. package/skills/apexlang/tools/query-valid-props-template-components.mjs +15 -1
  237. package/skills/apexlang/tools/query-valid-props.mjs +198 -216
  238. /package/skills/apexlang/templates/template-components/{badge._template_options.md → badge/badge._template_options.md} +0 -0
  239. /package/skills/apexlang/templates/template-components/{flexbox-container._template_options.md → flexbox-container/flexbox-container._template_options.md} +0 -0
@@ -0,0 +1,174 @@
1
+ ---
2
+ templateId: region.media-list.common
3
+ componentType: region
4
+ version: 2.0
5
+ description: Composite compiler-column and curated-policy contract for standalone Media List partial and report regions.
6
+ ---
7
+
8
+ # Purpose
9
+
10
+ Define `themeTemplateComponent/mediaList` using target-build-resolved report columns plus curated Universal Theme policy for settings, nested Avatar/Badge composition, interactions, grouping, responsive layouts, accessibility, security, and edge-case behavior.
11
+
12
+ # Compiler and Theme Evidence
13
+
14
+ - The Universal Theme export supplies an option inventory; it is not structural compiler evidence.
15
+ - The export inventory supports `partial` and `report`, one `link` action position, and no action templates.
16
+ - Resolve the active target build's task-scoped grammar contract before choosing report-column syntax.
17
+ - Settings, Avatar/Badge properties, actions, and grouping come from the curated Media List component policy, not from compiler report-column grammar. The generated contract identifies each authority in `capability_provenance`.
18
+ - The current compiler target resolves named report columns, while the current curated policy exposes no grouping/nested-size surface. A compiler change alone does not enable policy-owned features.
19
+ - Media List settings and values: `media-list._template_options.md`.
20
+ - Nested Avatar and Badge settings: `../avatar/avatar._template_options.md` and `../badge/badge._template_options.md`.
21
+
22
+ # Capability Resolution Gate (MANDATORY)
23
+
24
+ 1. Load `component-contracts/<build>.json` for the selected runtime target. Use repository `assets/component-attributes.json` only as the documented fallback for its recorded build.
25
+ 2. Resolve `region.column` under `region.type=themeTemplateComponent/mediaList` and the report's concrete non-null `region.source.location` through the task-scoped grammar contract.
26
+ 3. Select exactly one resolved column variant. A named variant uses its declaration identifier and accepted source properties; an unnamed variant uses only its accepted direct/source properties. Never merge the two.
27
+ 4. Resolve settings, Avatar/Badge properties, actions, and grouping from the selected curated component policy. Theme-export rows are inventory evidence until incorporated into that policy.
28
+ 5. When grouping, nested size, or another policy-owned capability is requested but absent from the curated policy, stop with an unsupported-capability result. Do not infer it from compiler column metadata.
29
+ 6. When the report-column contract is missing or resolves multiple structural alternatives, or the applicable curated policy is unknown, stop with Missing Inputs.
30
+ 7. Run local validation against the generated composite `component-contracts/<build>.json`. Verify its `capability_provenance` before treating a capability as compiler-derived.
31
+
32
+ # Generation Rules (MANDATORY)
33
+
34
+ 1. Emit `type: themeTemplateComponent/mediaList` and select exactly one `componentAppearance.display`: `partial` or `report`.
35
+ 2. Emit native page-region `layout {}` and `appearance {}` blocks. Top-level regions use `slot: body`; nested regions require a verified `parentRegion` and use `regionBody` by default (or explicitly supported `subRegions`) under an existing `@/standard` or `@/content-block` parent. Never create or infer a parent.
36
+ 3. Require `settings.title`. In report mode, map `title` and optional `description` with bare source aliases because their metadata type is `sessionStateValue`; do not use `&COLUMN_NAME.` syntax for these selectors.
37
+ 4. In report mode, require a verified data source and one compiler-resolved child column for every delivered projection. Emit exactly the declaration, required properties, blocks, and datatypes selected by the active grammar contract.
38
+ 5. For a named variant, keep the declaration identifier and accepted database-column mapping synchronized. For an unnamed variant, use the accepted column-name/visibility properties. Apply a primary-key or identity property only when the active column contract exposes it.
39
+ 6. For SQL-backed reports, keep `source.sqlQuery` free of `ORDER BY` and emit deterministic top-level `orderBy {}`. Use projected aliases only. The supported report adapter is `location: localDatabase` plus `type: sqlQuery`; unsupported source requests stop with Missing Inputs.
40
+ 7. Preserve the full compiler-supported source contract selected by the owning data-source workflow. Require authoritative evidence for every object and field before object-specific generation.
41
+ 8. Keep SQL and other sources data-only. Do not generate HTML, links, icons, Badge markup, or Avatar markup in source expressions.
42
+ 9. Enable Avatar with `settings.displayAvatar: true` and configure it in `plugin-avatar`. Omit both when Avatar is not requested.
43
+ 10. Enable Badge with `settings.displayBadge: true` and configure it in `plugin-badge`. Omit both when Badge is not requested.
44
+ 11. Apply the shared Avatar accessibility, URL, icon, and type/payload rules. Canonical Media List image generation is limited to the proven application-managed URL-column scenario; do not infer BLOB contracts.
45
+ 12. Apply the shared Badge static-label, value datatype, semantic-state, icon, and color-independent meaning rules.
46
+ 13. Emit grouping only in report mode and only when the curated component policy exposes a report-group block. Use its exact title/icon property names, require a safe title, and put a dynamic group-title alias first in ordering so groups remain contiguous.
47
+ 14. Emit at most one `action`, with `position: link`, numeric `layout.sequence`, and no `template`. Allow only a reviewed structured `redirectThisApp` target; reject `triggerAction` until validator-visible ownership by a dynamic action is available.
48
+ 15. Reject arbitrary URL navigation, `targetUrl`, `linkAttributes`, inline event handlers, invented focus behavior, and unresolved row-context mappings.
49
+ 16. Apply region authorization with an existing shared scheme when visibility is restricted. A navigation target or triggered behavior must enforce the same or stricter authorization independently.
50
+ 17. Keep native Universal Theme responsiveness. Omit `settings.layout` for the normal single-column flow; select a grid or horizontal layout only from the accepted inventory and only when the owning container width supports it.
51
+ 18. Omit `settings.applyThemeColors` to inherit its `true` default. Emit `false` only when the requested design intentionally disables Universal Theme row colors.
52
+ 19. Do not emit unsupported row selection, pagination, action templates, nested properties, custom structural CSS, or custom HTML rendering. Optional nested Avatar/Badge properties must be present in the curated Media List policy, not merely in their standalone owner contracts.
53
+ 20. Do not synthesize an empty row for a zero-row result. Route a required empty state to an independently supported page/region pattern.
54
+
55
+ # Variable Contract
56
+
57
+ | Name | Required | Type | Notes |
58
+ |------|----------|------|-------|
59
+ | `regionStaticId` | yes | identifier | Stable region identifier. |
60
+ | `name` | yes | string | Useful visible heading/landmark name. |
61
+ | `componentAppearance.display` | yes | enum | `partial` or `report`. |
62
+ | `source` | report | block | Verified compiler-supported data source. |
63
+ | `layout.parentRegion` | nested only | reference | Existing parent resolved by static ID or normalized reference. |
64
+ | `layout.slot` | yes | enum | `body` at page level; `regionBody` by default or explicitly supported `subRegions` when nested. |
65
+ | `orderBy` | SQL report | block | Deterministic static or item-controlled ordering. |
66
+ | `settings.title` | yes | session-state selector | Bare report source alias or existing partial-mode session-state value. |
67
+ | `settings.description` | no | session-state selector | Bare report source alias or existing partial-mode session-state value. |
68
+ | `settings.displayAvatar` | no | boolean | `true` only when `plugin-avatar` is emitted. |
69
+ | `settings.displayBadge` | no | boolean | `true` only when `plugin-badge` is emitted. |
70
+ | `settings.applyThemeColors` | report-only | boolean | Omit for the native `true` default; emit `false` only by explicit design intent. |
71
+ | `settings.layout` | report-only | enum | `2ColumnGrid`, `3ColumnGrid`, `4ColumnGrid`, `5ColumnGrid`, or `horizontalSpan`. |
72
+ | `settings.size` | report-only | enum | `large`. |
73
+ | `plugin-avatar` | conditional | block | Shared Avatar type/payload and only the nested properties exposed by the curated Media List policy. |
74
+ | `plugin-badge` | conditional | block | Static label, source value, and only the nested properties exposed by the curated Media List policy. |
75
+ | `plugin-grouping` | conditional capability | block | Report-only; exact title/icon properties come from the curated Media List policy. |
76
+ | `action` | no | child component | At most one `link` action with sequence and a structured same-app redirect. |
77
+ | `column variant` | report | compiler contract | Exact named or unnamed declaration selected for the active target. |
78
+ | `column source alias` | report | source alias | Uppercase projected alias represented through the selected variant's mapping property. |
79
+ | `column.layout.sequence` | report | number | Stable source-order sequence when required or allowed by the active column contract. |
80
+ | `column.source.dataType` | report | enum | Exact target-build-supported datatype. |
81
+ | `column identity` | conditional | compiler property | Apply only when the active variant exposes a primary-key/identity or visibility property. |
82
+ | `security.authorizationScheme` | conditional | reference | Existing region authorization scheme. |
83
+
84
+ # Output Template – Report Mode
85
+
86
+ ```apexlang
87
+ region {{regionStaticId}} (
88
+ name: {{name}}
89
+ type: themeTemplateComponent/mediaList
90
+ source {
91
+ location: {{sourceLocation}}
92
+ type: sqlQuery
93
+ sqlQuery:
94
+ ```sql
95
+ {{source.sqlQuery}}
96
+ ```
97
+ }
98
+ orderBy {
99
+ type: staticValue
100
+ orderByClause: {{orderBy.orderByClause}}
101
+ }
102
+ layout {
103
+ {{parentRegionProperty}}
104
+ sequence: {{layout.sequence}}
105
+ slot: {{layout.slot}}
106
+ }
107
+ appearance {
108
+ template: @/standard
109
+ templateOptions: #DEFAULT#
110
+ }
111
+ componentAppearance {
112
+ display: report
113
+ }
114
+ settings {
115
+ title: {{settings.titleColumn}}
116
+ {{descriptionProperty}}
117
+ {{displayAvatarProperty}}
118
+ {{displayBadgeProperty}}
119
+ {{applyThemeColorsProperty}}
120
+ {{layoutProperty}}
121
+ {{sizeProperty}}
122
+ }
123
+ {{pluginAvatarBlock}}
124
+ {{pluginBadgeBlock}}
125
+ {{policyApprovedGroupingBlock}}
126
+ {{securityBlock}}
127
+ {{compilerResolvedColumnBlocks}}
128
+ {{linkAction}}
129
+ )
130
+ ```
131
+
132
+ # Conditional Rendering Rules
133
+
134
+ - In partial mode, omit report-only `source`, `orderBy`, child columns, layout, size, and theme-color settings unless a future curated policy explicitly enables them.
135
+ - In report mode, require source coverage and include every projection once through the single active compiler-selected column shape.
136
+ - Use bare aliases for `settings.title`, `settings.description`, `plugin-avatar.initials`, `plugin-avatar.image.urlColumn`, `plugin-badge.value`, and `plugin-badge.state` when they select report columns.
137
+ - Use `&COLUMN_NAME.` only for free-text properties that support substitution, such as dynamic Avatar descriptions.
138
+ - Emit exactly one Avatar type payload. Meaningful Avatars require a description; decorative Avatars omit it and add `AVATAR_PURPOSE_DECORATIVE` to region comments.
139
+ - Omit Badge state unless semantic state was explicitly requested and proven to return exact lowercase `danger`, `warning`, `success`, or `info` values.
140
+ - Omit grouping and optional nested properties unless requested and exposed by the selected curated policy.
141
+ - Omit the action when items are informational. Never emit more than one action.
142
+ - Omit optional layout/appearance attributes instead of serializing empty placeholders or guessed defaults.
143
+
144
+ # Responsive and Accessibility Contract
145
+
146
+ - The region name and native Standard region header provide the section heading and landmark context.
147
+ - Default/no-layout output follows the native one-column Media List flow and is the safest narrow-container choice.
148
+ - Use two or three columns for normal body widths. Use four or five only in verified wide containers. `horizontalSpan` intentionally keeps one horizontal row and therefore requires explicit wide-layout intent.
149
+ - Do not solve wrapping, spacing, alignment, or visibility with invented CSS. Native Universal Theme handles item wrapping and focus indication.
150
+ - Meaningful Avatar content has human-readable alternative text. Decorative Avatar content is hidden from assistive technology while text remains available.
151
+ - Badge state color never carries the only meaning; retain a meaningful value and, when context requires it, `displayLabel: true` with a concise static label.
152
+ - Native link behavior remains keyboard operable and gets its accessible name from the Media List item content. Do not replace it with an inline handler.
153
+
154
+ # Security and Edge Cases
155
+
156
+ - Keep output raw-data-only and declaratively rendered. Do not disable escaping or pass HTML through title, description, Badge, or icon fields.
157
+ - Validate every source object, projected field, action target, target item, authorization alias, icon, and state mapping.
158
+ - Treat null optional descriptions and badges as data concerns; do not generate conditional DSL structure per row.
159
+ - Keep stable deterministic ordering for duplicate titles, normally by appending a verified identity alias as a tie-breaker.
160
+ - For action context, project the key through the active Media List column variant, apply its supported identity/visibility property, and use it only in the structured target mapping.
161
+ - If a dynamic Avatar description cannot be proven plain-text and meaningful, stop with Missing Inputs.
162
+
163
+ # Validation Checklist
164
+
165
+ - Region type and display mode are exact and supported.
166
+ - Required title mapping exists and report mappings use bare aliases.
167
+ - SQL has no embedded `ORDER BY`; top-level ordering references projected aliases.
168
+ - Every report projection has one column using the exact declaration and mappings selected by the active target-build grammar contract.
169
+ - Named and unnamed column variants are never mixed; identity/visibility properties are emitted only when exposed by the selected variant.
170
+ - Avatar and Badge toggles match their plugin blocks and satisfy their owning contracts.
171
+ - Layout, region size, nested size, shape, style, state, grouping, and icon values exist in both theme inventory and the selected curated component policy.
172
+ - A requested policy-owned capability absent from the selected curated policy is reported as unsupported rather than inferred from compiler column metadata.
173
+ - At most one `link` action exists; it has numeric sequence, no template, no unsafe URL/attributes, and verified authorization/row mappings.
174
+ - Unsupported row selection, pagination, HTML rendering, BLOB Avatar, and structural CSS are absent.
@@ -0,0 +1,50 @@
1
+ ---
2
+ templateId: region.media-list.index
3
+ componentType: region
4
+ version: 2.0
5
+ imports:
6
+ - media-list._common.md
7
+ description: Routing entrypoint for complete standalone Media List partial and report generation.
8
+ ---
9
+
10
+ # Purpose
11
+
12
+ Select the narrowest composite-contract Media List scenario without confusing the native template component with a shared-list region using `listTemplate: @/media-list`.
13
+
14
+ `create a Media List template` selects this direct component, including case and hyphen variations. Explicit List-region or Classic Report wording selects that host owner instead. Generic `list template` wording without the Media List alias selects the shared-list region.
15
+
16
+ # Load Order
17
+
18
+ 1. Load `media-list._common.md`.
19
+ 2. Load exactly one primary scenario.
20
+ 3. Add `media-list.report-avatar-badge.md` only when Avatar or Badge content is requested.
21
+ 4. Add `media-list.report-link.md` or `media-list.report-layouts.md` only for the corresponding explicit feature.
22
+ 5. Add `media-list.report-grouped.md` only after the selected curated component policy proves grouping support.
23
+ 6. Load the owning option inventories only for emitted attributes.
24
+
25
+ # Scenario Routing
26
+
27
+ - One non-report item: `media-list.partial.md`
28
+ - Base multi-row report: `media-list.report-base.md`
29
+ - Avatar and/or Badge rows: `media-list.report-avatar-badge.md`
30
+ - Row navigation or verified trigger interaction: `media-list.report-link.md`
31
+ - Native report grouping: `media-list.report-grouped.md`, only after its capability gate passes
32
+ - Multi-column, horizontal, large, or theme-color variants: `media-list.report-layouts.md`
33
+
34
+ # Composition Routing
35
+
36
+ - Combine feature scenario fragments only with the shared block order in `media-list._common.md`.
37
+ - Avatar visibility belongs in `settings.displayAvatar`; Avatar configuration belongs in `plugin-avatar`.
38
+ - Badge visibility belongs in `settings.displayBadge`; Badge configuration belongs in `plugin-badge`.
39
+ - Media List layout, size, and `applyThemeColors` belong in `settings` and are report-only.
40
+
41
+ # Unsupported Routing
42
+
43
+ - Do not route custom HTML rendering, custom CSS structure, arbitrary external URLs, multiple actions, action templates, row selection, pagination, or BLOB Avatar images to this pack.
44
+ - Do not emit report grouping or nested properties merely because theme metadata advertises them; require the selected curated component policy. Require the active target-build grammar contract only for the report-column variant.
45
+ - Use the exact Media List column declaration selected for the active target. Never mix named `source.databaseColumn` columns with unnamed `columnName`/`show` columns.
46
+ - Route shared-list navigation to `region-components/list`, not this standalone data-backed component.
47
+
48
+ # Authorization Routing
49
+
50
+ When the owning page restricts visibility, require the exact existing shared authorization scheme. A navigable target must enforce the same or stricter access independently. Stop with Missing Inputs rather than guessing either contract.
@@ -2,10 +2,14 @@
2
2
 
3
3
  These entries come from `create_plugin_attribute` and `create_plugin_attr_value`, not from `wwv_flow_template_options`.
4
4
 
5
- Apply these values through the owning component's settings plus the shared avatar and badge owner files when those substructures are enabled.
6
- Load `avatar._template_options.md` and `badge._template_options.md` for the shared substructures used by Media List.
5
+ Apply component- and report-scope values through `settings`, Avatar values through `plugin-avatar`, and Badge values through `plugin-badge`. Treat this file as theme inventory only; emit a property only after it is represented in the selected curated Media List component policy.
6
+ Load `../avatar/avatar._template_options.md` and `../badge/badge._template_options.md` for the shared substructures used by Media List.
7
7
  Emit only exact accepted values from this inventory. Do not concatenate adjacent values into one token and do not substitute labels or implementation details.
8
8
 
9
+ `title`, `description`, `displayAvatar`, and `displayBadge` are valid in partial and report mode when accepted by the curated policy. `applyThemeColors`, `layout`, and `size` are report-only. Omit `applyThemeColors` to inherit its `true` default. Use the native default/no-layout flow for narrow containers; select a multi-column or horizontal layout only when the owning container width supports it. Emit nested Avatar/Badge `size` only if the curated Media List plugin block exposes it.
10
+
11
+ Every nested Avatar/Badge icon must resolve to the build-pinned Font APEX index. In report mode, Media List `title`, `description`, Avatar initials/URL-column image, and Badge value/state use bare projected aliases. In partial mode, page-item-shaped selectors must name declared session-state items, and Badge state must be a proven allowlisted static value.
12
+
9
13
  When a row includes `values=`, pass the left-hand side of each `name=>return_value` pair.
10
14
 
11
15
  ## Media List (`mediaList`)
@@ -20,3 +24,5 @@ Supported: `PARTIAL:REPORT`
20
24
  - `size` | prompt=`Size` | type=`SELECT LIST` | scope=`REPORT` | required=`false` | default=`--` | group=`--` | depends=`--` | values=`large=>t-MediaList--large force-fa-lg`
21
25
  - `groupIcon` | prompt=`Icon` | type=`ICON` | scope=`REPORT_GROUP` | required=`false` | default=`--` | group=`Grouping` | depends=`groupTitle NOT_NULL`
22
26
  - `groupTitle` | prompt=`Title` | type=`HTML` | scope=`REPORT_GROUP` | required=`false` | default=`--` | group=`Grouping` | depends=`--`
27
+
28
+ The two `REPORT_GROUP` rows above preserve the complete theme inventory. They become a generation surface only when the curated component policy exposes a compatible report-group block and exact property names.
@@ -0,0 +1,50 @@
1
+ ---
2
+ templateId: region.media-list.partial
3
+ componentType: region
4
+ version: 1.0
5
+ imports:
6
+ - media-list._common.md
7
+ description: Single-item Media List partial using existing session-state values.
8
+ ---
9
+
10
+ # Purpose
11
+
12
+ Render one Media List item without report-only source, grouping, layout, or column metadata.
13
+
14
+ # Output Template
15
+
16
+ ```apexlang
17
+ region {{regionStaticId}} (
18
+ name: {{name}}
19
+ type: themeTemplateComponent/mediaList
20
+ layout {
21
+ {{parentRegionProperty}}
22
+ sequence: {{layout.sequence}}
23
+ slot: {{layout.slot}}
24
+ }
25
+ appearance {
26
+ template: @/standard
27
+ templateOptions: #DEFAULT#
28
+ }
29
+ componentAppearance {
30
+ display: partial
31
+ }
32
+ settings {
33
+ title: {{titleSessionStateValue}}
34
+ {{descriptionProperty}}
35
+ }
36
+ {{securityBlock}}
37
+ )
38
+ ```
39
+
40
+ # Conditional Rendering Rules
41
+
42
+ - Bind title and optional description only to literal values or existing session-state values selected by the owning partial-mode contract.
43
+ - Omit `source`, `orderBy`, report columns, `plugin-grouping`, `applyThemeColors`, `layout`, and `size` settings.
44
+ - Avatar, Badge, and link behavior may be added only through their shared conditional blocks when their values and authorization are resolved.
45
+
46
+ # Validation Checklist
47
+
48
+ - Display mode is exactly `partial`.
49
+ - No report-only block or setting is present.
50
+ - The title is nonempty and its session-state source exists when dynamic.
@@ -0,0 +1,76 @@
1
+ ---
2
+ templateId: region.media-list.report-avatar-badge
3
+ componentType: region
4
+ version: 1.0
5
+ imports:
6
+ - media-list._common.md
7
+ description: Media List report with optional Avatar and Badge composition.
8
+ ---
9
+
10
+ # Purpose
11
+
12
+ Add native Avatar and/or Badge content without changing the base report source, ordering, appearance, or compiler-resolved column contract.
13
+
14
+ # Output Template
15
+
16
+ ```apexlang
17
+ settings {
18
+ title: {{titleColumn}}
19
+ {{descriptionProperty}}
20
+ {{displayAvatarProperty}}
21
+ {{displayBadgeProperty}}
22
+ }
23
+
24
+ {{#if displayAvatar}}
25
+ plugin-avatar {
26
+ type: {{avatar.type}}
27
+ {{avatarPayload}}
28
+ {{avatarDescriptionProperty}}
29
+ shape: {{avatar.shape}}
30
+ {{avatarSizeProperty}}
31
+ }
32
+ {{/if}}
33
+
34
+ {{#if displayBadge}}
35
+ plugin-badge {
36
+ label: {{badge.label}}
37
+ value: {{badge.valueColumn}}
38
+ {{badgeStateProperty}}
39
+ {{badgeIconProperty}}
40
+ {{badgeDisplayLabelProperty}}
41
+ {{badgeStyleProperty}}
42
+ {{badgeShapeProperty}}
43
+ {{badgeSizeProperty}}
44
+ }
45
+ {{/if}}
46
+ ```
47
+
48
+ # Avatar Variants
49
+
50
+ - Initials: `type: initials` plus bare projected `initials: {{avatarInitialsColumn}}`.
51
+ - Icon: `type: icon` plus one static allowlisted `icon: {{fontApexIcon}}`.
52
+ - Image: `type: image` plus `image: { type: urlColumn urlColumn: {{avatarUrlColumn}} }`, where the projected URL is built only from `:APP_FILES` or `:APEX_FILES` and a static relative path.
53
+ - Emit exactly one payload. Meaningful Avatars require a human-readable description; dynamic descriptions use `&{{avatarDescriptionColumn}}.` plus evidence in region comments. Decorative Avatars omit the description and use `AVATAR_PURPOSE_DECORATIVE`.
54
+
55
+ # Badge Variants
56
+
57
+ - Keep `label` concise, static, plain text, and meaningful because its metadata is raw-rendered.
58
+ - Map `value` with a bare projected alias. Supported value datatypes are `varchar2`, `number`, `date`, `intervalYearToMonth`, and `intervalDayToSecond`.
59
+ - Omit state by default. When explicitly requested, map a `varchar2` alias proven to return only `danger`, `warning`, `success`, or `info`.
60
+ - Use `displayLabel: true` when the surrounding title/description does not already explain the Badge value. Color must never be the only state cue.
61
+ - Icons are static Font APEX values; dynamic icon class strings are not supported.
62
+
63
+ # Conditional Rendering Rules
64
+
65
+ - `settings.displayAvatar: true` and `plugin-avatar` are emitted together or both omitted.
66
+ - `settings.displayBadge: true` and `plugin-badge` are emitted together or both omitted.
67
+ - Add one compiler-resolved Media List column for every Avatar/Badge mapping. Auxiliary Avatar URL/description and Badge state fields remain source mappings consumed only by their plugin properties.
68
+ - Emit `plugin-avatar.size` or `plugin-badge.size` only when the selected curated Media List policy exposes that nested property and accepts the selected value; otherwise omit it.
69
+ - Load and apply the shared Avatar and Badge owner contracts; do not copy their named child-column shape.
70
+
71
+ # Validation Checklist
72
+
73
+ - Toggle and plugin blocks are consistent.
74
+ - Avatar type/payload, description, URL, and icon values satisfy the shared Avatar rules.
75
+ - Badge label, value datatype, optional state, icon, and display semantics satisfy the shared Badge rules.
76
+ - Every nested mapping resolves to a projected Media List column in the active compiler-selected shape.
@@ -0,0 +1,71 @@
1
+ ---
2
+ templateId: region.media-list.report-base
3
+ componentType: region
4
+ version: 2.0
5
+ imports:
6
+ - media-list._common.md
7
+ description: Base standalone Media List report with title, optional description, deterministic ordering, and compiler-resolved report columns.
8
+ ---
9
+
10
+ # Purpose
11
+
12
+ Render a native multi-row Media List without Avatar, Badge, grouping, or interaction.
13
+
14
+ # Output Template
15
+
16
+ ```apexlang
17
+ region {{regionStaticId}} (
18
+ name: {{name}}
19
+ type: themeTemplateComponent/mediaList
20
+ source {
21
+ location: localDatabase
22
+ type: sqlQuery
23
+ sqlQuery:
24
+ ```sql
25
+ {{source.sqlQuery}}
26
+ ```
27
+ }
28
+ orderBy {
29
+ type: staticValue
30
+ orderByClause: {{orderBy.orderByClause}}
31
+ }
32
+ layout {
33
+ {{parentRegionProperty}}
34
+ sequence: {{layout.sequence}}
35
+ slot: {{layout.slot}}
36
+ }
37
+ appearance {
38
+ template: @/standard
39
+ templateOptions: #DEFAULT#
40
+ }
41
+ componentAppearance {
42
+ display: report
43
+ }
44
+ settings {
45
+ title: {{titleColumn}}
46
+ {{descriptionProperty}}
47
+ }
48
+ {{securityBlock}}
49
+ {{compilerResolvedIdentityColumnBlock}}
50
+ {{compilerResolvedTitleColumnBlock}}
51
+ {{compilerResolvedDescriptionColumnBlock}}
52
+ {{compilerResolvedRemainingColumnBlocks}}
53
+ )
54
+ ```
55
+
56
+ # Conditional Rendering Rules
57
+
58
+ - `settings.title` uses the bare projected alias and the matching title column is `varchar2`.
59
+ - When description is requested, set `descriptionProperty` to `description: {{descriptionColumn}}` and emit one matching `varchar2` column block.
60
+ - Omit the description setting and column together when the report has no description field.
61
+ - Keep the identity field source-backed and apply the active contract's identity/visibility property when one exists; it is an ordering/action-context tie-breaker, not a rendered template value.
62
+ - Emit `source.type: databaseColumn` when the active target-build column contract marks the property required. A compiler default value does not permit omission by itself; stop only for a genuine grammar-versus-requiredness mismatch.
63
+ - Add every remaining source projection once using the same compiler-resolved Media List column shape.
64
+ - Keep deterministic ordering stable for duplicate titles by including a verified identity alias as the final tie-breaker.
65
+
66
+ # Validation Checklist
67
+
68
+ - Title and optional description aliases are explicitly projected and declared.
69
+ - Every projected source field has one matching column using the active target-build declaration and required mappings.
70
+ - No Avatar, Badge, grouping, or action block is emitted.
71
+ - SQL contains raw data and no `ORDER BY` or presentation HTML.
@@ -0,0 +1,40 @@
1
+ ---
2
+ templateId: region.media-list.report-grouped
3
+ componentType: region
4
+ version: 3.0
5
+ imports:
6
+ - media-list._common.md
7
+ description: Capability-gated native Media List report grouping.
8
+ ---
9
+
10
+ # Purpose
11
+
12
+ Generate native Media List report grouping only when the selected curated component policy exposes a validated report-group structure.
13
+
14
+ # Capability Gate
15
+
16
+ - Confirm `plugin-grouping` is an allowed Media List block from `curated-component-policy` in `component-contracts/<build>.json`.
17
+ - Resolve the exact required/optional grouping property names from that policy; do not assume `groupTitle`, `title`, `groupIcon`, or `icon` across policy revisions.
18
+ - Confirm the selected title property accepts the required dynamic/plain-text mapping and live validation recognizes the emitted block.
19
+ - If any condition is unresolved, stop with an unsupported-capability result for the selected target. Do not synthesize grouping with HTML or CSS.
20
+
21
+ # Output Template
22
+
23
+ ```apexlang
24
+ {{policyApprovedGroupingBlock}}
25
+ ```
26
+
27
+ # Conditional Rendering Rules
28
+
29
+ - Use grouping only in report mode after the capability gate passes.
30
+ - Dynamic title mappings must reference a projected `varchar2` alias using the exact substitution/property contract selected for the target.
31
+ - Put the group-title alias first in deterministic static ordering so equal groups remain contiguous.
32
+ - An optional group icon must use the policy's accepted icon property and one static allowlisted Font APEX icon.
33
+ - Universal Theme supplies semantic group headings; do not place HTML in SQL or grouping values.
34
+
35
+ # Validation Checklist
36
+
37
+ - The curated component policy proves the grouping block and every emitted property.
38
+ - Group rows remain contiguous because ordering starts with the grouping alias.
39
+ - Group title data is safe plain text and the optional icon is static and allowlisted.
40
+ - A target without grouping support produces `MEDIA_LIST_CAPABILITY_UNSUPPORTED_001` rather than compiler-invalid APEXlang.
@@ -0,0 +1,50 @@
1
+ ---
2
+ templateId: region.media-list.report-layouts
3
+ componentType: region
4
+ version: 1.0
5
+ imports:
6
+ - media-list._common.md
7
+ description: Native Media List report layout, size, and theme-color choices.
8
+ ---
9
+
10
+ # Purpose
11
+
12
+ Apply curated Universal Theme presentation choices without custom CSS.
13
+
14
+ # Output Template
15
+
16
+ ```apexlang
17
+ settings {
18
+ title: {{titleColumn}}
19
+ {{descriptionProperty}}
20
+ {{layoutProperty}}
21
+ {{sizeProperty}}
22
+ {{applyThemeColorsProperty}}
23
+ }
24
+ ```
25
+
26
+ # Responsive Selection Matrix
27
+
28
+ | Intent/container | Setting |
29
+ |------------------|---------|
30
+ | Narrow region or unspecified width | Omit `layout` for the native single-column flow. |
31
+ | Normal body width with compact items | `layout: 2ColumnGrid` or `3ColumnGrid`. |
32
+ | Verified wide body/dashboard lane | `layout: 4ColumnGrid` or `5ColumnGrid`. |
33
+ | Explicit one-row, non-wrapping presentation in a wide container | `layout: horizontalSpan`. |
34
+ | Explicitly larger item treatment | `size: large`. |
35
+ | Native Avatar/Badge row colors | Omit `applyThemeColors` because its default is `true`. |
36
+ | Explicit neutral row colors | `applyThemeColors: false`. |
37
+
38
+ # Conditional Rendering Rules
39
+
40
+ - Layout, size, and theme colors are report-only.
41
+ - Emit exactly one layout token from the accepted inventory; never pass the underlying CSS return value.
42
+ - Do not combine multiple grid layouts or add custom breakpoint classes.
43
+ - Treat `horizontalSpan` as deliberate wide-layout intent because it keeps items in one horizontal row.
44
+ - Use Universal Theme defaults for wrapping, spacing, and focus behavior.
45
+
46
+ # Validation Checklist
47
+
48
+ - Every emitted value exists in `media-list._template_options.md`.
49
+ - The selected layout matches the verified owning container width.
50
+ - No custom structural CSS is introduced.
@@ -0,0 +1,53 @@
1
+ ---
2
+ templateId: region.media-list.report-link
3
+ componentType: region
4
+ version: 1.0
5
+ imports:
6
+ - media-list._common.md
7
+ description: Media List report with its single native link action.
8
+ ---
9
+
10
+ # Purpose
11
+
12
+ Make each Media List item navigable using the component's only action position.
13
+
14
+ # Output Template
15
+
16
+ ```apexlang
17
+ action {{actionId}} (
18
+ position: link
19
+ layout {
20
+ sequence: {{action.sequence}}
21
+ }
22
+ behavior {
23
+ type: redirectThisApp
24
+ target: {
25
+ page: {{targetPageId}}
26
+ items: {
27
+ {{targetItem}}: &{{sourceKeyColumn}}.
28
+ }
29
+ }
30
+ }
31
+ {{actionSecurityBlock}}
32
+ )
33
+ ```
34
+
35
+ # Interaction Contract
36
+
37
+ - Use `redirectThisApp` and a structured target whose page, item, and row-key mapping all exist.
38
+ - Do not emit `triggerAction`; the current validator cannot prove the required owning dynamic action.
39
+
40
+ # Conditional Rendering Rules
41
+
42
+ - Emit at most one action and keep `position: link`.
43
+ - Always emit numeric `layout.sequence`; the live compiler requires it.
44
+ - Omit `template`; Media List exposes no action templates.
45
+ - Do not emit `targetUrl`, `linkAttributes`, external destinations, inline handlers, or custom keyboard/focus code.
46
+ - Project the row key through the active compiler-selected column shape and apply its identity property when supported; the template renders only fields selected by its settings/plugin mappings.
47
+ - Apply the same or stricter authorization at the target/trigger boundary; region visibility is not access control.
48
+
49
+ # Validation Checklist
50
+
51
+ - Action position, cardinality, sequence, and behavior are valid.
52
+ - Target page/item and `&SOURCE_KEY.` mapping are resolved and authorized.
53
+ - Native item content supplies an understandable accessible link name.
@@ -6,32 +6,47 @@ Canonical Metric Card template pack for `themeTemplateComponent/metricCard`, usi
6
6
  ## Usage
7
7
  - Load `metric-card._common.md` first for variable contract and generation guardrails.
8
8
  - Use `metric-card._index.md` to confirm the routing entrypoint and load order.
9
- - Metric Card regions always emit `type: themeTemplateComponent/metricCard` with `componentAppearance.display: report`.
9
+ - Metric Card regions emit `type: themeTemplateComponent/metricCard` with `componentAppearance.display: partial` or `report`.
10
10
  - Metric Card regions should always emit a region `appearance {}` block.
11
11
  - Dashboard KPI strips default to `template: @/blank-with-attributes` so the Metric Card has no visible standard region chrome.
12
12
  - Use `template: @/standard` only when the design explicitly needs a titled or landmarked visible region wrapper.
13
13
  - Emit `advanced { htmlDomId: ... }` only when external page logic must target a known region DOM id; native runtime behavior does not require it.
14
- - Column source mappings use the `column-metric-card` child template.
14
+ - Column source mappings use the compiler-resolved `column-f` child production.
15
15
  - Metric Card child columns support the documented `column.source.dataType` inventory in `metric-card._common.md`; emit those tokens exactly.
16
16
  - Report-mode Metric Card requires explicit child `column (...)` metadata for every delivered source projection. Do not satisfy the compiler minimum by adding only one column when the source projects more than one field.
17
+ - Every emitted child column declares `source.databaseColumn` and `source.dataType`; emit `primaryKey: true` only for an identity column when row identity is needed.
17
18
  - Metric Card `settings` expose more than `title` and `metric`; use `meta`, the CSS-class hooks, and layout/item CSS properties from `metric-card._template_options.md` when the design needs them.
19
+ - `layout` and `itemCssClasses` are report-only. Partial mode also omits grouping, row selection, messages, and pagination.
20
+ - Metric Card `settings.metric` is required. Query-column-backed `title`, `metric`, and `meta` values use `&COLUMN_NAME.` substitution syntax.
18
21
  - Metric Card may also use `plugin-avatar`, `plugin-badge`, and `rowSelection` in accepted scenarios. Do not force those property names to mirror child-column names; they are value hooks, not a second column declaration system.
19
22
  - For Metric Card avatar rendering, use `plugin-avatar.displayAvatar` plus the typed avatar payload inside `plugin-avatar`.
23
+ - Metric Card owns its nested avatar position/alignment/style/shape/size values; do not substitute the standalone Avatar region settings inventory.
24
+ - Avatar `style: subtle` is accepted only for icon and initials types; image avatars omit style.
20
25
  - Do not emit `settings.displayAvatar` for Metric Card; use `plugin-avatar.displayAvatar` instead.
21
26
  - For Metric Card badge rendering, use `plugin-badge.displayBadge` plus badge fields inside `plugin-badge`.
27
+ - When a Metric Card Badge is emitted, include both `label` and `value`; source-backed selector attributes use bare projected aliases and optional states follow the Badge allowlist.
22
28
  - Do not emit `settings.displayBadge` for Metric Card; use `plugin-badge.displayBadge` instead.
23
29
  - Metric Card `rowSelection` can also be focus-only. Use `focusOnly` with no page-item bindings, `singleSelection` with `currentSelectionPageItem`, or `multipleSelection` with both `currentSelectionPageItem` and `selectAllPageItem`.
30
+ - Report mode supports no-data messages and `pagination.entitiesPerPage`; do not emit pagination `type` or `showTotalCount`.
24
31
  - When Metric Card uses any `rowSelection` mode, one child column must carry `source.primaryKey: true`.
32
+ - Metric Card exposes one row-level action position, `link`. Use a declarative target and do not emit an action template because the component defines no action templates.
33
+ - Keep the region authenticated through the page baseline. Add region/action authorization only when a stricter existing authorization scheme is required; never invent an authorization alias.
25
34
  - A single Metric Card region can render multiple cards from multiple source rows.
26
35
  - When one region must show several independent metrics, prefer a normalized multi-row SQL source. The default pattern is `UNION ALL` across one SELECT per metric so every row projects the same aliases in the same order.
27
36
  - Load `metric-card._template_options.md` for Metric Card-specific layout and grouping values.
28
- - Load `../avatar._template_options.md` for accepted Metric Card avatar value inventory.
29
- - Load `../badge._template_options.md` for accepted Metric Card badge value inventory.
37
+ - Load `metric-card.report-avatar-badge.md` for nested Avatar/Badge permutations and `metric-card._template_options.md` for their Metric Card-specific values.
38
+ - Load `metric-card.permutations.md` when generating a QA application that must cover every APEX 26.1 Metric Card branch and enum.
30
39
 
31
40
  ## Template Catalog
32
41
  - `metric-card._common.md`
33
42
  - `metric-card._index.md`
34
43
  - `metric-card._template_options.md`
44
+ - `metric-card.partial-minimal.md`
45
+ - `metric-card.report-minimal.md`
46
+ - `metric-card.report-avatar-badge.md`
47
+ - `metric-card.report-link.md`
48
+ - `metric-card.report-grouping-selection.md`
49
+ - `metric-card.permutations.md`
35
50
 
36
51
  ## Maintenance
37
52
  - Keep this README synchronized with actual files in this directory.