dsh-diff-approval 0.9.0 → 0.10.0
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 +4 -3
- package/README.zh.md +4 -3
- package/docs/images/pending-panel.png +0 -0
- package/docs/images/pending-panel.zh.png +0 -0
- package/lib/client.js +685 -159
- package/lib/types/client/PendingPanel.d.ts +1 -0
- package/lib/types/client/SettingsTab.d.ts +5 -4
- package/lib/types/client/locales.d.ts +10 -0
- package/lib/types/client/settings.d.ts +19 -0
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/** Sidebar-foot pending-edit review action and the split review panel it opens. */
|
|
2
2
|
import type { InjectFace, PropsLocale, PropsRuntime } from '@deepseek-ai/dsh-client-ui-slots';
|
|
3
3
|
import type { PendingPanelFace } from './slots.ts';
|
|
4
|
+
export declare function wrapInto(text: string, widthPx: number, measure: (t: string) => number, tabPx: number): string[];
|
|
4
5
|
/** Full panel props composed by the sidebar footer-action slot. */
|
|
5
6
|
export type PendingPanelProps = PropsRuntime<'sidebar.footer.action'> & InjectFace<PendingPanelFace> & PropsLocale<'diff-approval'>;
|
|
6
7
|
/**
|
|
@@ -3,9 +3,10 @@ import type { PropsLocale, PropsRuntime } from '@deepseek-ai/dsh-client-ui-slots
|
|
|
3
3
|
/** Full component props assembled by the Settings slot renderer. */
|
|
4
4
|
export type DiffApprovalSettingsTabProps = PropsRuntime<'settings.section'> & PropsLocale<'diff-approval'>;
|
|
5
5
|
/**
|
|
6
|
-
* The plugin's preferences: auto-paste a copied reference into the input,
|
|
7
|
-
* whether importing workspace VCS changes includes untracked files
|
|
8
|
-
* mirrors the harness's Agent-preset row (title +
|
|
9
|
-
* pill picker on the right)
|
|
6
|
+
* The plugin's preferences: auto-paste a copied reference into the input,
|
|
7
|
+
* whether importing workspace VCS changes includes untracked files, and the
|
|
8
|
+
* diff's tab width. Each row mirrors the harness's Agent-preset row (title +
|
|
9
|
+
* description on the left, a pill picker on the right); the tab-width row
|
|
10
|
+
* offers 2 / 4 / 8 spaces.
|
|
10
11
|
*/
|
|
11
12
|
export declare function DiffApprovalSettingsTab({ t }: DiffApprovalSettingsTabProps): import("react").JSX.Element;
|
|
@@ -22,6 +22,8 @@ export declare const zh: {
|
|
|
22
22
|
'panel.pasteOnCopyDesc': string;
|
|
23
23
|
'panel.importUntracked': string;
|
|
24
24
|
'panel.importUntrackedDesc': string;
|
|
25
|
+
'panel.tabWidth': string;
|
|
26
|
+
'panel.tabWidthDesc': string;
|
|
25
27
|
'settings.tabLabel': string;
|
|
26
28
|
'row.create': string;
|
|
27
29
|
'row.failed': string;
|
|
@@ -36,11 +38,14 @@ export declare const zh: {
|
|
|
36
38
|
'action.busy': string;
|
|
37
39
|
'action.prevDiff': string;
|
|
38
40
|
'action.nextDiff': string;
|
|
41
|
+
'action.showFileList': string;
|
|
42
|
+
'action.hideFileList': string;
|
|
39
43
|
'action.copyHint': string;
|
|
40
44
|
'action.copied': string;
|
|
41
45
|
'action.langAuto': string;
|
|
42
46
|
'action.langAutoDetected': string;
|
|
43
47
|
'action.langSelect': string;
|
|
48
|
+
'action.wrap': string;
|
|
44
49
|
'action.toggleOn': string;
|
|
45
50
|
'action.toggleOff': string;
|
|
46
51
|
'action.importVcs': string;
|
|
@@ -88,6 +93,8 @@ export declare const en: {
|
|
|
88
93
|
'panel.pasteOnCopyDesc': string;
|
|
89
94
|
'panel.importUntracked': string;
|
|
90
95
|
'panel.importUntrackedDesc': string;
|
|
96
|
+
'panel.tabWidth': string;
|
|
97
|
+
'panel.tabWidthDesc': string;
|
|
91
98
|
'settings.tabLabel': string;
|
|
92
99
|
'row.create': string;
|
|
93
100
|
'row.failed': string;
|
|
@@ -102,11 +109,14 @@ export declare const en: {
|
|
|
102
109
|
'action.busy': string;
|
|
103
110
|
'action.prevDiff': string;
|
|
104
111
|
'action.nextDiff': string;
|
|
112
|
+
'action.showFileList': string;
|
|
113
|
+
'action.hideFileList': string;
|
|
105
114
|
'action.copyHint': string;
|
|
106
115
|
'action.copied': string;
|
|
107
116
|
'action.langAuto': string;
|
|
108
117
|
'action.langAutoDetected': string;
|
|
109
118
|
'action.langSelect': string;
|
|
119
|
+
'action.wrap': string;
|
|
110
120
|
'action.toggleOn': string;
|
|
111
121
|
'action.toggleOff': string;
|
|
112
122
|
'action.importVcs': string;
|
|
@@ -17,3 +17,22 @@ export declare function setPasteOnCopyEnabled(value: boolean): void;
|
|
|
17
17
|
export declare function includeUntrackedEnabled(): boolean;
|
|
18
18
|
/** Persist the import-untracked preference. */
|
|
19
19
|
export declare function setIncludeUntrackedEnabled(value: boolean): void;
|
|
20
|
+
/**
|
|
21
|
+
* Whether lines wrap (auto-wrap) in the diff for one highlight language.
|
|
22
|
+
* Defaults to off; only an explicit `'1'` enables it. Stored per language, so
|
|
23
|
+
* a language's preference never leaks into another's.
|
|
24
|
+
* @param lang - the highlight language (or `''` for the auto/default bucket).
|
|
25
|
+
* @returns whether lines wrap.
|
|
26
|
+
*/
|
|
27
|
+
export declare function wrapEnabled(lang: string): boolean;
|
|
28
|
+
/** Persist the per-language auto-wrap preference. */
|
|
29
|
+
export declare function setWrapEnabled(lang: string, value: boolean): void;
|
|
30
|
+
/**
|
|
31
|
+
* The diff's tab width in spaces. Defaults to 4; the settings UI offers 2/4/8,
|
|
32
|
+
* but any positive integer is accepted. This drives both the rendered
|
|
33
|
+
* `tab-size` and the wrapped-line tab measurement, so they always agree.
|
|
34
|
+
* @returns the number of spaces one tab advances.
|
|
35
|
+
*/
|
|
36
|
+
export declare function tabWidth(): number;
|
|
37
|
+
/** Persist the diff's tab width (in spaces). */
|
|
38
|
+
export declare function setTabWidth(value: number): void;
|
package/package.json
CHANGED