xterm-input-panel 1.2.0 → 1.2.2
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/.storybook/vitest.setup.ts +2 -2
- package/CHANGELOG.md +18 -0
- package/LICENSE +21 -0
- package/package.json +3 -3
- package/src/input-method-tab.stories.ts +12 -8
- package/src/input-method-tab.ts +1 -1
- package/src/input-panel.stories.ts +14 -0
- package/src/input-panel.ts +3 -12
- package/src/pixi-theme.test.ts +2 -2
- package/src/platform.ts +3 -3
- package/src/shortcut-pages.ts +431 -61
- package/src/shortcut-tab.ts +45 -24
- package/src/storage-namespace.test.ts +22 -0
- package/src/storage-namespace.ts +17 -0
- package/src/virtual-keyboard-tab.stories.ts +10 -8
- package/src/virtual-trackpad-tab.stories.ts +51 -40
- package/src/xterm-addon.stories.ts +45 -0
- package/src/xterm-addon.ts +56 -11
- package/vitest.storybook.config.ts +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { beforeAll } from 'vitest'
|
|
2
|
-
import { setProjectAnnotations } from 'storybook/preview-api'
|
|
3
1
|
import * as rendererAnnotations from '@storybook/web-components/entry-preview'
|
|
2
|
+
import { setProjectAnnotations } from 'storybook/preview-api'
|
|
3
|
+
import { beforeAll } from 'vitest'
|
|
4
4
|
import * as previewAnnotations from './preview'
|
|
5
5
|
|
|
6
6
|
const annotations = setProjectAnnotations([rendererAnnotations, previewAnnotations])
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# xterm-input-panel
|
|
2
2
|
|
|
3
|
+
## 1.2.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 143b916: Add hosted app distribution support across the CLI, server, and web runtime.
|
|
8
|
+
- add `openspecui --app` with configurable hosted app base URLs and local hosted-app dev mode
|
|
9
|
+
- expose hosted session/bootstrap helpers so versioned frontend entries can reconnect to the correct backend
|
|
10
|
+
- include hosted-app settings and faster dashboard overview loading for the web UI
|
|
11
|
+
- scope xterm input-panel persisted state by hosted session to avoid cross-tab leakage
|
|
12
|
+
|
|
13
|
+
## 1.2.1
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- fcfb701: Move terminal InputPanel entry from floating FAB to the terminal toolbar, harden InputPanel remount lifecycle recovery, and improve schema-driven workflow compatibility by removing proposal/tasks/design hard assumptions from dashboard metadata paths.
|
|
18
|
+
|
|
19
|
+
Also evolve `opsx-collab-pr-loop` into dedicated loop artifacts under `loop/*` (intake, research-plan, implementation, checkpoints) with apply tracking on `loop/checkpoints.md`.
|
|
20
|
+
|
|
3
21
|
## 1.2.0
|
|
4
22
|
|
|
5
23
|
### Minor Changes
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 OpenSpecUI Contributors
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "xterm-input-panel",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "src/index.ts",
|
|
6
6
|
"dependencies": {
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"@storybook/web-components-vite": "^10.2.8",
|
|
23
23
|
"@vitest/browser": "^4.0.18",
|
|
24
24
|
"@vitest/browser-playwright": "^4.0.18",
|
|
25
|
-
"@xterm/xterm": "6.1.0-beta.
|
|
25
|
+
"@xterm/xterm": "6.1.0-beta.167",
|
|
26
26
|
"playwright": "^1.58.2",
|
|
27
27
|
"storybook": "^10.2.8",
|
|
28
28
|
"typescript": "^5.7.2",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
},
|
|
32
32
|
"scripts": {
|
|
33
33
|
"dev": "storybook dev -p 6007",
|
|
34
|
-
"test:browser": "vitest run --config vitest.storybook.config.ts",
|
|
34
|
+
"test:browser": "vitest run --retry 2 --config vitest.storybook.config.ts",
|
|
35
35
|
"typecheck": "tsc --noEmit"
|
|
36
36
|
}
|
|
37
37
|
}
|
|
@@ -16,7 +16,9 @@ const meta: Meta = {
|
|
|
16
16
|
tags: ['autodocs'],
|
|
17
17
|
decorators: [
|
|
18
18
|
(story) => html`
|
|
19
|
-
<div
|
|
19
|
+
<div
|
|
20
|
+
style="width: 400px; height: 250px; background: #1a1a1a; color: #fff; font-family: monospace;"
|
|
21
|
+
>
|
|
20
22
|
${story()}
|
|
21
23
|
</div>
|
|
22
24
|
`,
|
|
@@ -56,7 +58,7 @@ export const SendInput: StoryObj = {
|
|
|
56
58
|
sendBtn.click()
|
|
57
59
|
|
|
58
60
|
// Wait for _send to complete
|
|
59
|
-
await new Promise(resolve => setTimeout(resolve, 100))
|
|
61
|
+
await new Promise((resolve) => setTimeout(resolve, 100))
|
|
60
62
|
|
|
61
63
|
expect(sendHandler).toHaveBeenCalledTimes(1)
|
|
62
64
|
const detail = (sendHandler.mock.calls[0] as unknown[])[0] as CustomEvent
|
|
@@ -85,13 +87,15 @@ export const CtrlEnterSend: StoryObj = {
|
|
|
85
87
|
textarea.dispatchEvent(new Event('input', { bubbles: true }))
|
|
86
88
|
await tab.updateComplete
|
|
87
89
|
|
|
88
|
-
textarea.dispatchEvent(
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
90
|
+
textarea.dispatchEvent(
|
|
91
|
+
new KeyboardEvent('keydown', {
|
|
92
|
+
key: 'Enter',
|
|
93
|
+
ctrlKey: true,
|
|
94
|
+
bubbles: true,
|
|
95
|
+
})
|
|
96
|
+
)
|
|
93
97
|
|
|
94
|
-
await new Promise(resolve => setTimeout(resolve, 100))
|
|
98
|
+
await new Promise((resolve) => setTimeout(resolve, 100))
|
|
95
99
|
|
|
96
100
|
expect(sendHandler).toHaveBeenCalledTimes(1)
|
|
97
101
|
const detail = (sendHandler.mock.calls[0] as unknown[])[0] as CustomEvent
|
package/src/input-method-tab.ts
CHANGED
|
@@ -56,6 +56,20 @@ export const FloatingLayout: StoryObj = {
|
|
|
56
56
|
<virtual-trackpad-tab slot="trackpad" floating></virtual-trackpad-tab>
|
|
57
57
|
</input-panel>
|
|
58
58
|
`,
|
|
59
|
+
play: async ({ canvasElement }) => {
|
|
60
|
+
const panel = await getLitElement(canvasElement, 'input-panel')
|
|
61
|
+
const dialog = panel.shadowRoot?.querySelector('.panel-dialog') as HTMLElement
|
|
62
|
+
expect(dialog).toBeTruthy()
|
|
63
|
+
|
|
64
|
+
const styles = getComputedStyle(dialog) as CSSStyleDeclaration & {
|
|
65
|
+
webkitBackdropFilter?: string
|
|
66
|
+
}
|
|
67
|
+
expect(styles.mixBlendMode).toBe('exclusion')
|
|
68
|
+
expect(
|
|
69
|
+
styles.backdropFilter.includes('blur(1px)') ||
|
|
70
|
+
styles.webkitBackdropFilter?.includes('blur(1px)')
|
|
71
|
+
).toBe(true)
|
|
72
|
+
},
|
|
59
73
|
}
|
|
60
74
|
|
|
61
75
|
/**
|
package/src/input-panel.ts
CHANGED
|
@@ -200,19 +200,10 @@ export class InputPanel extends LitElement {
|
|
|
200
200
|
position: relative;
|
|
201
201
|
}
|
|
202
202
|
|
|
203
|
-
@keyframes breathing {
|
|
204
|
-
0%,
|
|
205
|
-
100% {
|
|
206
|
-
opacity: 0.5;
|
|
207
|
-
}
|
|
208
|
-
50% {
|
|
209
|
-
opacity: 0.05;
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
/* Fix 7: breathing animation on entire panel (including toolbar) */
|
|
214
203
|
:host([layout='floating']) .panel-dialog {
|
|
215
|
-
|
|
204
|
+
mix-blend-mode: exclusion;
|
|
205
|
+
backdrop-filter: blur(1px);
|
|
206
|
+
-webkit-backdrop-filter: blur(1px);
|
|
216
207
|
}
|
|
217
208
|
|
|
218
209
|
.panel-dialog {
|
package/src/pixi-theme.test.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { describe,
|
|
2
|
-
import {
|
|
1
|
+
import { describe, expect, it } from 'vitest'
|
|
2
|
+
import { blendHex, cssColorToHex, resolvePixiTheme } from './pixi-theme.js'
|
|
3
3
|
|
|
4
4
|
describe('pixi-theme', () => {
|
|
5
5
|
describe('resolvePixiTheme', () => {
|
package/src/platform.ts
CHANGED
|
@@ -3,9 +3,9 @@ export type PlatformMode = HostPlatform | 'auto'
|
|
|
3
3
|
|
|
4
4
|
export function detectHostPlatform(): HostPlatform {
|
|
5
5
|
const platformSource = (
|
|
6
|
-
(navigator as Navigator & { userAgentData?: { platform?: string } }).userAgentData?.platform
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
(navigator as Navigator & { userAgentData?: { platform?: string } }).userAgentData?.platform ??
|
|
7
|
+
navigator.platform ??
|
|
8
|
+
navigator.userAgent
|
|
9
9
|
).toLowerCase()
|
|
10
10
|
|
|
11
11
|
if (platformSource.includes('mac')) return 'macos'
|