@harborclient/sdk 1.6.0 → 1.6.1
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 +8 -0
- package/dist/components/SegmentedTabs/index.d.ts +7 -2
- package/dist/components/SegmentedTabs/index.d.ts.map +1 -1
- package/dist/components/SegmentedTabs/index.js +7 -2
- package/dist/components/SettingIdLabel/index.d.ts +8 -1
- package/dist/components/SettingIdLabel/index.d.ts.map +1 -1
- package/dist/components/SettingIdLabel/index.js +5 -2
- package/package.json +4 -2
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
|
|
|
4
4
|
|
|
5
5
|
## Unreleased
|
|
6
6
|
|
|
7
|
+
## 1.6.1 - 2026-08-03
|
|
8
|
+
|
|
9
|
+
- feat(docs): enhance SDK documentation and update API references. (`6331350c`)
|
|
10
|
+
- feat(docs): update SDK documentation and enhance plugin API guidelines. (`46a2a29e`)
|
|
11
|
+
- refactor(ResponseEditor): simplify split pane wrapping and adjust padding. (`4b480786`)
|
|
12
|
+
- feat(settings): enhance deep link handling for settings navigation. (`3d03652e`)
|
|
13
|
+
- feat(gui): add response editor split functionality. (`bd1aaaba`)
|
|
14
|
+
|
|
7
15
|
## 1.6.0 - 2026-08-03
|
|
8
16
|
|
|
9
17
|
- feat(sse): enhance import functionality for Server-Sent Events (SSE). (`e26fa155`)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ComponentPropsWithoutRef, JSX } from 'react';
|
|
1
|
+
import type { ComponentPropsWithoutRef, JSX, MouseEvent } from 'react';
|
|
2
2
|
import type { TabItem } from './types.js';
|
|
3
3
|
export { SegmentedTabsGroup } from './SegmentedTabsGroup.js';
|
|
4
4
|
export { SegmentedTabPanel } from './SegmentedTabPanel.js';
|
|
@@ -53,10 +53,15 @@ interface Props<T extends string> extends Omit<ComponentPropsWithoutRef<'div'>,
|
|
|
53
53
|
* `SegmentedTabsGroup`.
|
|
54
54
|
*/
|
|
55
55
|
ariaLabel?: string;
|
|
56
|
+
/**
|
|
57
|
+
* Called when the user right-clicks a tab button. The browser context menu is
|
|
58
|
+
* suppressed so hosts can show a custom menu.
|
|
59
|
+
*/
|
|
60
|
+
onTabContextMenu?: (value: T, event: MouseEvent<HTMLButtonElement>) => void;
|
|
56
61
|
}
|
|
57
62
|
/**
|
|
58
63
|
* macOS-style segmented tab control with WAI-ARIA tabs or radiogroup semantics.
|
|
59
64
|
* The tab strip wraps to additional rows when tabs exceed the container width.
|
|
60
65
|
*/
|
|
61
|
-
export declare function SegmentedTabs<T extends string>({ tabs, value: valueProp, onChange: onChangeProp, editable, visibleTabValues: visibleTabValuesProp, defaultVisibleTabValues, onVisibleTabValuesChange, fullWidth, className, pattern, ariaLabel: ariaLabelProp, ...props }: Props<T>): JSX.Element;
|
|
66
|
+
export declare function SegmentedTabs<T extends string>({ tabs, value: valueProp, onChange: onChangeProp, editable, visibleTabValues: visibleTabValuesProp, defaultVisibleTabValues, onVisibleTabValuesChange, fullWidth, className, pattern, ariaLabel: ariaLabelProp, onTabContextMenu, ...props }: Props<T>): JSX.Element;
|
|
62
67
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/SegmentedTabs/index.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,wBAAwB,EAAE,GAAG,EAAiB,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/SegmentedTabs/index.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,wBAAwB,EAAE,GAAG,EAAiB,UAAU,EAAE,MAAM,OAAO,CAAC;AAMtF,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAE1C,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,i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xB,SAAiB,EACjB,SAAS,EACT,OAAgB,EAChB,SAAS,EAAE,aAAa,EACxB,gBAAgB,EAChB,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,OAAO,CAqQxB"}
|
|
@@ -49,7 +49,7 @@ function focusFirstFocusableInPanel(panel) {
|
|
|
49
49
|
* macOS-style segmented tab control with WAI-ARIA tabs or radiogroup semantics.
|
|
50
50
|
* The tab strip wraps to additional rows when tabs exceed the container width.
|
|
51
51
|
*/
|
|
52
|
-
export function SegmentedTabs({ tabs, value: valueProp, onChange: onChangeProp, editable = true, visibleTabValues: visibleTabValuesProp, defaultVisibleTabValues, onVisibleTabValuesChange, fullWidth = false, className, pattern = 'tabs', ariaLabel: ariaLabelProp, ...props }) {
|
|
52
|
+
export function SegmentedTabs({ tabs, value: valueProp, onChange: onChangeProp, editable = true, visibleTabValues: visibleTabValuesProp, defaultVisibleTabValues, onVisibleTabValuesChange, fullWidth = false, className, pattern = 'tabs', ariaLabel: ariaLabelProp, onTabContextMenu, ...props }) {
|
|
53
53
|
const context = useContext(SegmentedTabsContext);
|
|
54
54
|
const standaloneId = useId();
|
|
55
55
|
const tabRefs = useRef(new Map());
|
|
@@ -197,7 +197,12 @@ export function SegmentedTabs({ tabs, value: valueProp, onChange: onChangeProp,
|
|
|
197
197
|
tabRefs.current.set(tab.value, element);
|
|
198
198
|
else
|
|
199
199
|
tabRefs.current.delete(tab.value);
|
|
200
|
-
}, type: "button", className: tabClassName, disabled: tab.disabled, tabIndex: tab.disabled ? -1 : 0, onClick: () => onChange(tab.value),
|
|
200
|
+
}, type: "button", className: tabClassName, disabled: tab.disabled, tabIndex: tab.disabled ? -1 : 0, "data-tab-value": tab.value, onClick: () => onChange(tab.value), onContextMenu: onTabContextMenu
|
|
201
|
+
? (event) => {
|
|
202
|
+
event.preventDefault();
|
|
203
|
+
onTabContextMenu(tab.value, event);
|
|
204
|
+
}
|
|
205
|
+
: undefined, ...(isRadiogroup
|
|
201
206
|
? { role: 'radio', 'aria-checked': selected }
|
|
202
207
|
: {
|
|
203
208
|
role: 'tab',
|
|
@@ -8,9 +8,16 @@ export interface Props {
|
|
|
8
8
|
* Stable setting id shown on hover and keyboard focus.
|
|
9
9
|
*/
|
|
10
10
|
settingId: string;
|
|
11
|
+
/**
|
|
12
|
+
* Optional content between the label and the setting id (e.g. a cog actions menu).
|
|
13
|
+
*/
|
|
14
|
+
afterLabel?: ReactNode;
|
|
11
15
|
}
|
|
12
16
|
/**
|
|
13
17
|
* Setting label with a VS Code-style id affordance revealed on hover and focus.
|
|
18
|
+
*
|
|
19
|
+
* Renders as `<label> [afterLabel] <setting id>` so actions sit after the title
|
|
20
|
+
* and before the hover-revealed id.
|
|
14
21
|
*/
|
|
15
|
-
export declare function SettingIdLabel({ children, settingId }: Props): JSX.Element;
|
|
22
|
+
export declare function SettingIdLabel({ children, settingId, afterLabel }: Props): JSX.Element;
|
|
16
23
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/SettingIdLabel/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAE5C,MAAM,WAAW,KAAK;IACpB;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;IAEpB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/SettingIdLabel/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAE5C,MAAM,WAAW,KAAK;IACpB;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;IAEpB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,EAAE,QAAQ,EAAE,SAAS,EAAE,UAAU,EAAE,EAAE,KAAK,GAAG,GAAG,CAAC,OAAO,CActF"}
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "@harborclient/sdk/jsx-runtime";
|
|
2
2
|
/**
|
|
3
3
|
* Setting label with a VS Code-style id affordance revealed on hover and focus.
|
|
4
|
+
*
|
|
5
|
+
* Renders as `<label> [afterLabel] <setting id>` so actions sit after the title
|
|
6
|
+
* and before the hover-revealed id.
|
|
4
7
|
*/
|
|
5
|
-
export function SettingIdLabel({ children, settingId }) {
|
|
6
|
-
return (_jsxs("span", { className: "group/setting-label inline-flex items-
|
|
8
|
+
export function SettingIdLabel({ children, settingId, afterLabel }) {
|
|
9
|
+
return (_jsxs("span", { className: "group/setting-label inline-flex min-w-0 items-center gap-2", children: [_jsx("span", { children: children }), afterLabel, _jsx("span", { className: "pointer-events-none font-mono text-[14px] text-muted opacity-0 transition-opacity select-none group-focus-within/setting-label:opacity-100 group-hover/setting-label:opacity-100", title: settingId, "aria-label": `Setting id: ${settingId}`, children: settingId })] }));
|
|
7
10
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@harborclient/sdk",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.1",
|
|
4
4
|
"description": "TypeScript SDK for HarborClient development.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"harborclient",
|
|
@@ -229,6 +229,7 @@
|
|
|
229
229
|
"debug": "^4.4.3",
|
|
230
230
|
"eslint": "^10.5.0",
|
|
231
231
|
"jsdom": "^26.1.0",
|
|
232
|
+
"markdown-it": "^15.0.0",
|
|
232
233
|
"mermaid": "^11.15.0",
|
|
233
234
|
"overlayscrollbars": "^2.16.0",
|
|
234
235
|
"overlayscrollbars-react": "^0.5.6",
|
|
@@ -238,6 +239,7 @@
|
|
|
238
239
|
"react-dom": "^19.2.7",
|
|
239
240
|
"react-markdown": "^10.1.0",
|
|
240
241
|
"remark-gfm": "^4.0.1",
|
|
242
|
+
"shiki": "^4.4.1",
|
|
241
243
|
"storybook": "^10.4.6",
|
|
242
244
|
"tailwindcss": "^4.3.1",
|
|
243
245
|
"typescript": "^5.8.3",
|
|
@@ -265,7 +267,7 @@
|
|
|
265
267
|
"storybook": "storybook dev -p 6006",
|
|
266
268
|
"build-storybook": "storybook build -o docs/.vitepress/static/storybook",
|
|
267
269
|
"docs:build": "pnpm docs:build:nav && pnpm build-storybook && vitepress build docs",
|
|
268
|
-
"docs:build:nav": "node scripts/build-docs-nav.mjs && node scripts/assert-docs-slugs.mjs",
|
|
270
|
+
"docs:build:nav": "node scripts/build-hc-api-docs.mjs && node scripts/build-docs-nav.mjs && node scripts/assert-docs-slugs.mjs",
|
|
269
271
|
"docs:preview": "pnpm docs:build && vitepress preview docs",
|
|
270
272
|
"docs:serve": "pnpm docs:build:nav && concurrently --kill-others --prefixColors=auto -n nav,vp \"node scripts/watch-docs-nav.mjs\" \"vitepress dev docs\"",
|
|
271
273
|
"plugin:sign": "pnpm build && node dist/signing/cli-sign.js",
|