Skip to content

Commit 743de96

Browse files
committed
docs: reframe AI page after removing app-building content from framework CLAUDE.md
- Source-repo CLAUDE.md files no longer needed for app builders; reframe section - Inline full Deprecated UI5 Controls list (was linked into removed CLAUDE.md section) - Drop broken anchor link to building-views section - Simplify ready-made prompt
1 parent 241c7ab commit 743de96

1 file changed

Lines changed: 48 additions & 26 deletions

File tree

docs/get_started/ai.md

Lines changed: 48 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -17,25 +17,14 @@ abap2UI5 lives in three repositories. Each carries information an AI assistant s
1717
| **[abap2UI5/samples](https://github.com/abap2UI5/samples)** | 250+ working demo apps + app-development guide | Canonical patterns and a copy-pastable example for almost every UI5 control and feature |
1818
| **[abap2UI5/docs](https://github.com/abap2UI5/docs)** | This documentation site | Conceptual background, lifecycle, cookbook recipes |
1919

20-
## Primary AI Briefings — The `CLAUDE.md` Files
20+
## Source-Repo Briefings (for Framework / Sample Contributors)
2121

22-
Two `CLAUDE.md` files in the source repositories are written specifically as briefings for AI assistants. They are the **first** thing to read:
22+
The two source repositories carry `CLAUDE.md` briefings aimed at AI tools that work **inside those repos** — they are not needed for building apps:
2323

24-
- **[abap2UI5/CLAUDE.md](https://github.com/abap2UI5/abap2UI5/blob/main/CLAUDE.md)** — framework-level briefing
25-
- Project overview, architecture, the request/response roundtrip
26-
- Repository layout (`src/00` utilities, `src/01` engine, `src/02` public API)
27-
- Coding rules, naming, style guide (Clean ABAP exceptions)
28-
- **Deprecated UI5 controls** to avoid
29-
- Important rules for AI assistants (do/don't list)
24+
- **[abap2UI5/CLAUDE.md](https://github.com/abap2UI5/abap2UI5/blob/main/CLAUDE.md)** — for AI assistants **modifying the framework itself**: layered architecture (`src/00` utilities, `src/01` engine, `src/02` public API), coding rules, naming, abaplint setup, Clean-ABAP exceptions, public-API stability contract.
25+
- **[samples/CLAUDE.md](https://github.com/abap2UI5/samples/blob/main/CLAUDE.md)** — for AI assistants **contributing sample apps**: formatting rules (blank lines, indentation), file/class conventions, abaplint setup.
3026

31-
- **[samples/CLAUDE.md](https://github.com/abap2UI5/samples/blob/main/CLAUDE.md)** — app-development briefing
32-
- Canonical app structure (`on_init`, `on_event`, `view_display`, `data_read`, `data_update`)
33-
- Formatting rules (blank lines, indentation, parameter alignment)
34-
- When to use inline vs. handler methods
35-
- Navigation patterns and event dispatching
36-
- `z2ui5_cl_xml_view` vs. `z2ui5_cl_util_xml` style rules
37-
38-
If an AI assistant only reads two files in this project, these are the two.
27+
If you only want to **build an abap2UI5 app**, this page is the single source — you do not need to read those files.
3928

4029
## Quick Briefing — The Mental Model
4130

@@ -129,7 +118,7 @@ Builder methods:
129118
Always pass `'true'` or `'false'` as **string literals** — never `abap_true` / `abap_false`. `abap_false` (space) is silently dropped; `abap_true` (`'X'`) produces an invalid XML attribute value.
130119
:::
131120

132-
Complete worked example: see [Quickstart](/get_started/quickstart), [Hello World](/get_started/hello_world), [Full Example](/get_started/full_example), and the `CLAUDE.md` in [abap2UI5](https://github.com/abap2UI5/abap2UI5/blob/main/CLAUDE.md#building-views--two-supported-apis).
121+
Complete worked example: see [Quickstart](/get_started/quickstart), [Hello World](/get_started/hello_world), and [Full Example](/get_started/full_example).
133122

134123
## Canonical App Template
135124

@@ -195,11 +184,49 @@ Before building a custom dialog, check whether one of the built-in popup classes
195184

196185
## Deprecated UI5 Controls — Do Not Generate
197186

198-
Whole libraries to **never** use: `sap.ui.commons.*`, legacy `sap.viz.ui5.*` charts.
187+
The authoritative list is at <https://ui5.sap.com/#/api/deprecated>. The most common pitfalls for generated code:
188+
189+
**Whole libraries — never use any control from these:**
199190

200-
Individual deprecated items: `sap.m.MultiEditField`, `sap.f.Avatar` (use `sap.m.Avatar`), `sap.ui.core.XMLComposite`, `HTMLView`, `JSONView`, `JSView`, `TemplateView`, `sap.ui.table.ColumnHeader`, `sap.f.routing.*`, deprecated `Avatar*` enums, Belize / Blue Crystal themes, …
191+
| Library | Deprecated since | Use instead |
192+
|---|---|---|
193+
| `sap.ui.commons.*` (Accordion, Button, CheckBox, ComboBox, DatePicker, Dialog, FileUploader, Label, Link, Menu, Panel, RadioButton, SearchField, Slider, TextArea, TextField, TextView, ToggleButton, Toolbar, Tree, Form, SimpleForm, AbsoluteLayout, BorderLayout, MatrixLayout, HorizontalLayout, VerticalLayout, … — entire library) | 1.38 | `sap.m` + `sap.ui.layout` |
194+
| `sap.viz.ui5.*` legacy charts (Bar, Bubble, Bullet, Column, Combination, Donut, Heatmap, Line, Pie, Scatter, StackedColumn, Treemap, Waterfall, …) | 1.32 | `sap.viz.ui5.controls.VizFrame` |
201195

202-
The authoritative list is at <https://ui5.sap.com/#/api/deprecated>. A condensed, AI-friendly version is in the [abap2UI5 CLAUDE.md → Deprecated UI5 Controls](https://github.com/abap2UI5/abap2UI5/blob/main/CLAUDE.md#deprecated-ui5-controls--do-not-use) section.
196+
**Individual deprecated controls:**
197+
198+
| Control | Deprecated since | Use instead |
199+
|---|---|---|
200+
| `sap.m.MultiEditField` | 1.120 ||
201+
| `sap.f.Avatar` | 1.73 | `sap.m.Avatar` |
202+
| `sap.ui.core.XMLComposite` | 1.88 | Custom controls |
203+
| `sap.ui.core.mvc.HTMLView` | 1.108 | `XMLView` |
204+
| `sap.ui.core.mvc.JSONView` | 1.120 | `XMLView` |
205+
| `sap.ui.core.mvc.JSView` | 1.90 | Typed views |
206+
| `sap.ui.core.mvc.TemplateView` | 1.56 | `XMLView` |
207+
| `sap.ui.core.tmpl.TemplateControl` | 1.56 ||
208+
| `sap.ui.table.ColumnHeader` | 1.120 | `sap.ui.table.Column` |
209+
| `sap.ui.table.TableHelper` | 1.118 ||
210+
| `sap.f.routing.Router` / `Target` / `TargetHandler` / `Targets` | 1.56 | `sap.m.routing.*` (async) |
211+
| `sap.tnt.IToolHeader` (interface) | 1.135 | Any control as `ToolPage` header |
212+
213+
**Deprecated enums/types to avoid:**
214+
215+
- `sap.m.ValueCSSColor`, `DateTimeInputType` (use `DatePicker` / `TimePicker`), `ListHeaderDesign`, `ListMode.SingleSelect` (1.143 → `SingleSelectLeft`), `FrameType.TwoThirds` / `Auto`, mis-spelled `PlacementType.*Prefered*` variants
216+
- `sap.f.AvatarShape` / `AvatarSize` / `AvatarType` / `AvatarColor` / `AvatarImageFitType` / `IllustratedMessageType` / `IllustratedMessageSize` / `DynamicPageTitleArea` (use the `sap.m.*` equivalents)
217+
- `sap.ui.layout.BlockBackgroundType.Mixed`, `form.GridElementCells`, `SimpleFormLayout.ResponsiveLayout`, `SimpleFormLayout.GridLayout`, `cssgrid.CSSGridGapShortHand`, `GridHelper`
218+
- `sap.ui.table.NavigationMode`, `SortOrder` (use `sap.ui.core.SortOrder`), `VisibleRowCountMode` (use `rowMode` aggregation), `TreeAutoExpandMode`, `ResetAllMode`
219+
- `sap.ui.core.MessageType` (use `module:sap/ui/core/message/MessageType`)
220+
- `sap.ui.unified.ContentSwitcherAnimation` (1.147 — concept discarded)
221+
222+
**Other deprecated framework items:**
223+
224+
- Analysis Path Framework (APF) — deprecated 1.140
225+
- `sap.m.PDFViewer.sourceValidationFailed()` — deprecated 1.141
226+
- Declarative `data-sap-ui-type` attribute — deprecated 1.120 (use XML views)
227+
- Belize, Blue Crystal, and Blue Crystal HCB themes — removed in 1.136 (use Horizon)
228+
229+
**Namespace caveat for `Avatar`:** when using `z2ui5_cl_xml_view->avatar( )`, leave `ns` empty so the element resolves to `sap.m.Avatar` via the View's default xmlns. **Never pass `ns = 'f'`** — that produces `<f:Avatar>`, which is the deprecated `sap.f.Avatar`. (`avatar_group` and `avatar_group_item` correctly use `ns = 'f'` because those controls still live in `sap.f`.)
203230

204231
## Documentation Map — What to Read When
205232

@@ -225,12 +252,7 @@ When an AI needs deeper information than this page provides:
225252

226253
A prompt that gives an AI assistant enough context to produce a working app:
227254

228-
> You are building an abap2UI5 app. Before writing any code, read these two briefings:
229-
>
230-
> 1. <https://github.com/abap2UI5/abap2UI5/blob/main/CLAUDE.md> — framework, API, rules
231-
> 2. <https://github.com/abap2UI5/samples/blob/main/CLAUDE.md> — app structure, formatting
232-
>
233-
> Then consult <https://abap2ui5.github.io/docs/get_started/ai.html> for the documentation map and <https://github.com/abap2UI5/samples/tree/main/src> for 250+ working examples. Use `z2ui5_cl_util_xml` as the view builder. Look up any UI5 control at <https://ui5.sap.com/#/api> and translate the XML 1:1 to ABAP. Avoid any control listed in the "Deprecated UI5 Controls" section of the framework `CLAUDE.md`.
255+
> You are building an abap2UI5 app. Read <https://abap2ui5.github.io/docs/get_started/ai.html> first — it is the single source of truth for app-building (template, client API, lifecycle, view builder, deprecated controls, documentation map). For working examples, browse <https://github.com/abap2UI5/samples/tree/main/src> (250+ apps, one feature per app). Use `z2ui5_cl_util_xml` as the view builder. Look up any UI5 control at <https://ui5.sap.com/#/api> and translate the XML 1:1 to ABAP. Do not use any control listed in this page's "Deprecated UI5 Controls" section.
234256
235257
## Hard Rules (Cheat Sheet)
236258

0 commit comments

Comments
 (0)