@operato/context 10.29.27 → 10.29.28
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/CHANGELOG.md +10 -0
- package/coverage/lcov-report/base.css +224 -0
- package/coverage/lcov-report/block-navigation.js +87 -0
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +521 -0
- package/coverage/lcov-report/prettify.css +1 -0
- package/coverage/lcov-report/prettify.js +2 -0
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +210 -0
- package/coverage/lcov.info +19362 -0
- package/dist/src/tools/ox-page-title-bar.d.ts +0 -1
- package/dist/src/tools/ox-page-title-bar.js +9 -7
- package/dist/src/tools/ox-page-title-bar.js.map +1 -1
- package/dist/test/page-title-description.test.js +39 -0
- package/dist/test/page-title-description.test.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +4 -4
- package/test/page-title-description.test.ts +44 -0
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@operato/context",
|
|
3
3
|
"description": "Webcomponent context following open-wc recommendations",
|
|
4
4
|
"author": "heartyoh",
|
|
5
|
-
"version": "10.29.
|
|
5
|
+
"version": "10.29.28",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "dist/src/index.js",
|
|
8
8
|
"module": "dist/src/index.js",
|
|
@@ -67,8 +67,8 @@
|
|
|
67
67
|
},
|
|
68
68
|
"dependencies": {
|
|
69
69
|
"@material/web": "^2.0.0",
|
|
70
|
-
"@operato/help": "^10.29.
|
|
71
|
-
"@operato/input": "^10.29.
|
|
70
|
+
"@operato/help": "^10.29.28",
|
|
71
|
+
"@operato/input": "^10.29.28",
|
|
72
72
|
"@operato/layout": "^10.29.27",
|
|
73
73
|
"@operato/shell": "^10.29.27",
|
|
74
74
|
"@operato/styles": "^10.29.23",
|
|
@@ -108,5 +108,5 @@
|
|
|
108
108
|
"prettier --write"
|
|
109
109
|
]
|
|
110
110
|
},
|
|
111
|
-
"gitHead": "
|
|
111
|
+
"gitHead": "cf6d84547fbf6a32a315c08f85c4dfc35a30d4a5"
|
|
112
112
|
}
|
|
@@ -60,3 +60,47 @@ describe('ox-page-title-bar gutter', () => {
|
|
|
60
60
|
expect(Math.round(offset)).to.equal(16)
|
|
61
61
|
})
|
|
62
62
|
})
|
|
63
|
+
|
|
64
|
+
describe('ox-page-title-bar narrow window', () => {
|
|
65
|
+
/*
|
|
66
|
+
* The screen's name always shows. A narrow window used to drop the title for the search pill
|
|
67
|
+
* (2026-10-12, operato-board); now the pill moves under the title.
|
|
68
|
+
*/
|
|
69
|
+
it('★ keeps the title and puts the search pill on the next line', async () => {
|
|
70
|
+
const host = await fixture<HTMLElement>(html`<div style="width: 240px"><ox-page-title-bar></ox-page-title-bar></div>`)
|
|
71
|
+
store.dispatch({
|
|
72
|
+
type: 'UPDATE_CONTEXT',
|
|
73
|
+
context: { title: 'scenario list', search: { handler: () => {}, placeholder: 'search scenarios by name' } }
|
|
74
|
+
} as any)
|
|
75
|
+
const el = host.querySelector('ox-page-title-bar') as HTMLElement & { updateComplete: Promise<unknown> }
|
|
76
|
+
await el.updateComplete
|
|
77
|
+
await el.updateComplete
|
|
78
|
+
const titler = el.shadowRoot!.querySelector('[titler]') as HTMLElement
|
|
79
|
+
const search = el.shadowRoot!.querySelector('[search]') as HTMLElement
|
|
80
|
+
|
|
81
|
+
expect(titler?.textContent?.trim()).to.equal('scenario list')
|
|
82
|
+
expect(search.getBoundingClientRect().top).to.be.at.least(titler.getBoundingClientRect().bottom - 1)
|
|
83
|
+
expect(search.getBoundingClientRect().right).to.be.at.most(el.getBoundingClientRect().right + 1)
|
|
84
|
+
})
|
|
85
|
+
})
|
|
86
|
+
|
|
87
|
+
describe('ox-page-title-bar title style', () => {
|
|
88
|
+
/*
|
|
89
|
+
* The screen title reads like the New Board page's heading (2026-10-12): the theme gives the font
|
|
90
|
+
* (--context-toolbar-title) and the colour (--context-toolbar-title-color).
|
|
91
|
+
*/
|
|
92
|
+
it('★ takes its font and colour from the title variables', async () => {
|
|
93
|
+
const host = await fixture<HTMLElement>(
|
|
94
|
+
html`<div style="--context-toolbar-title: 600 20px sans-serif; --context-toolbar-title-color: rgb(27, 27, 27); --title-text-color: rgb(100, 85, 80)"><ox-page-title-bar></ox-page-title-bar></div>`
|
|
95
|
+
)
|
|
96
|
+
store.dispatch({ type: 'UPDATE_CONTEXT', context: { title: 'board list' } } as any)
|
|
97
|
+
const el = host.querySelector('ox-page-title-bar') as HTMLElement & { updateComplete: Promise<unknown> }
|
|
98
|
+
await el.updateComplete
|
|
99
|
+
await el.updateComplete
|
|
100
|
+
const style = getComputedStyle(el.shadowRoot!.querySelector('[titler]') as HTMLElement)
|
|
101
|
+
|
|
102
|
+
expect(style.fontWeight).to.equal('600')
|
|
103
|
+
expect(style.fontSize).to.equal('20px')
|
|
104
|
+
expect(style.color).to.equal('rgb(27, 27, 27)')
|
|
105
|
+
})
|
|
106
|
+
})
|