fix(sw): 2026-10-21 SW design review and responsive header without More from 760px
User-approved design review (2026-10-21): - SW Header: from 760px up nothing moves into More; the five menus stay with their titles (titles and values ellipsize), file name shrinks to 96px. Open next to the logo no longer blocks field shrinking above 760px (760/768 overflow fixed, also for configured `controls` headers). Dropdown yellow ring inside the button, black seam. - Property Bar values as read-only red text; property popup "=" labels, read-only black values, per-entry hover with pointer. - Home Menu recent files (3 rows, path + name caption, empty preview), Footer + slot guide off by default, Viewer file list without icons, Storybook widths 1920-760. - Tests: old More expectations (integrated-improvement, keyboard-dismiss, footer-popup-viewer-refinement, storybook-cleanup-stage1) moved to the new rule; functional checks kept.
This commit is contained in:
1 parent
a25d2b31c5
commit
2fc1b3e108
37 files changed
+447
-211
No files matched your search
@@ -140,14 +140,18 @@ try {
|
||||
const pickBox = await pick.boundingBox()
|
||||
await pick.click()
|
||||
check('Overview: btn_colorize 24 × 24 calls onColorPick and closes (former Colorize page)', pickBox.width === 24 && pickBox.height === 24 && (await callback()).includes('onColorPick') && await header.locator('.hm-sw-header__color-menu').count() === 0, pickBox)
|
||||
const bar = page.locator('.hm-sw-property-bar [data-property-id="radius"] input')
|
||||
await bar.fill('6.25'); await bar.press('Enter')
|
||||
check('Overview: property Bar Enter commits through callback', await bar.inputValue() === '6.25' && (await callback()).includes('onPropertyChange(radius, 6.25)'))
|
||||
await bar.fill('-1'); await bar.press('Enter')
|
||||
check('Overview: property Bar validation keeps min=0', await bar.inputValue() === '6.25')
|
||||
// 2026-10-21 (user decision): the Bar values are read-only red text (<output>), never focused; the panel edits them.
|
||||
const bar = page.locator('.hm-sw-property-bar [data-property-id="radius"] output')
|
||||
check('Overview: property Bar value is read-only text (no input, no focus stop)', await bar.count() === 1 && await page.locator('.hm-sw-property-bar input').count() === 0 && await bar.evaluate(e => e.tabIndex < 0))
|
||||
const trigger = header.locator('[data-property-panel-trigger]')
|
||||
await trigger.click(); await page.locator('.hm-sw-property').waitFor()
|
||||
check('Overview: panel opens with the shared Bar value', await page.locator('.hm-sw-property [data-property-id="radius"] input').first().inputValue() === '6.25')
|
||||
const panelRadius = page.locator('.hm-sw-property [data-property-id="radius"] input').first()
|
||||
check('Overview: panel opens with the shared Bar value', await panelRadius.inputValue() === await bar.textContent())
|
||||
await panelRadius.fill('6.25'); await panelRadius.press('Enter')
|
||||
await page.waitForFunction(() => document.querySelector('.hm-sw-property-bar [data-property-id="radius"] output')?.textContent === '6.25')
|
||||
check('Overview: panel edit commits through callback and updates the Bar', await bar.textContent() === '6.25' && (await callback()).includes('onPropertyChange(radius, 6.25)'))
|
||||
await panelRadius.fill('-1'); await panelRadius.press('Enter')
|
||||
check('Overview: panel validation keeps min=0', await panelRadius.inputValue() === '6.25' && await bar.textContent() === '6.25')
|
||||
await page.keyboard.press('Escape'); await page.keyboard.press('Escape')
|
||||
check('Overview: Escape closes panel and returns focus to its trigger', await page.locator('.hm-sw-property').count() === 0 && await trigger.evaluate(e => e === document.activeElement))
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user