@eintrek/erp-shell 0.1.72 → 0.1.74

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 CHANGED
@@ -176,6 +176,60 @@ progress API: `API.md` next to it.
176
176
  shell's adapters), `guide-ui.tsx`, `guide-styles.ts`. Tests:
177
177
  `src/guide/*.test.ts`.
178
178
 
179
+ ### 0.1.74
180
+
181
+ Page guides ("คู่มือหน้านี้", guides round 4; authors:
182
+ `_claude-work/guides-r4/GUIDE-PAGES.md`).
183
+
184
+ - `GuideSuite.pages?: GuidePage[]`: a read-only walk through one page,
185
+ `view` and `click` steps only (a page guide with a `commit`, `input` or
186
+ `select` step is dropped, with a warning in development). It runs as a
187
+ replay of a synthetic mission `page:<key>`, so it never writes tour
188
+ progress. `when` names an anchor that must be on screen (sub-screens on
189
+ one URL); the most specific match wins (`when`, then `?k=v` constraints,
190
+ then static segments), and only if it is this person's (`visible`,
191
+ `requires`).
192
+ - Progress: one row per page per user, `<app>.page.<key>`, written once —
193
+ when the first-visit offer is answered or ignored, or when the guide
194
+ ends (finished: completed; not now, exited, left: skipped). Opened again
195
+ from "?", it writes nothing. Read from the same `GET …/guides/me` answer.
196
+ - Switch: platform-api's `pages_mode` (`guides.<app>.pages` = off | menu |
197
+ offer, default off) and `page_audience` (every member while not off). In
198
+ `menu` mode nothing is offered by itself; in `offer` mode a small card
199
+ ("คู่มือหน้านี้ · <title> · n ขั้น", เริ่ม / ไม่ตอนนี้) appears once on a
200
+ first visit, when nothing else is up and the welcome is not due there. An
201
+ API without the fields means off.
202
+ - The "?" menu: "คู่มือหน้านี้", "ไกด์เริ่มต้น n/N", "คู่มือทุกหน้า",
203
+ "ติดต่อทีมช่วยเหลือ", each only when it has something
204
+ (`guideMenuItems`). The panel gains a second section, "คู่มือแต่ละหน้า"
205
+ (ดูแล้ว / ใหม่), and shows it alone when the person has no missions.
206
+ - A page guide's bubble: "คู่มือหน้านี้ · <title>", ย้อนกลับ on read steps,
207
+ "เสร็จ" on the last, "ปิดคู่มือ" to leave (silently, as leaving the page
208
+ does). Finishing says "จบคู่มือหน้านี้".
209
+ - Missions keep precedence: a mission start ends a page guide, the welcome
210
+ replaces an offer (unrecorded), a page guide never starts over a step.
211
+ - `config.pagesReady` holds page guides apart from the missions' `ready`.
212
+ - For apps with their own "?" (LIFF): `usePageGuideEntry()` →
213
+ `{ title, open } | null`, `openPageGuide()`, `openPagesPanel()`,
214
+ `usePageGuides()`, from both entries.
215
+ - `guideMenuShown(entry, pages?)` is no longer a type guard.
216
+
217
+ ### 0.1.73
218
+
219
+ - `GuideStep.status`: a short status line in the bubble while it returns
220
+ text, read again on every page change. A select step names a wrong pick
221
+ ("ยังไม่ใช่ชื่อคุณ") instead of waiting in silence (owner, 3 Nov 2026:
222
+ Plannex's managers step, someone else picked, nothing moved).
223
+ - In a replay (ทบทวน), a select step offers ถัดไป when the next step's target
224
+ is already on the page (a form's save button), so a review never has to
225
+ change a real record to go on. Not while the next target needs the pick
226
+ (Plannex's save shows only once the user is a manager). First runs are
227
+ unchanged.
228
+ - The "?" button opens the help dialog straight away, without the
229
+ "ไกด์เริ่มต้น 0/0" row, when every mission is hidden for this user
230
+ (`guideMenuShown`). `useGuideEntry()` still answers `{ done, total }`;
231
+ an app's own entry row should hide at `total === 0` too.
232
+
179
233
  ### 0.1.72
180
234
 
181
235
  - "ขั้นที่ x/y" counts only the steps this person will see: a step whose