@lightworkai.official/debug-capture 0.12.8 → 0.14.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 +17 -0
- package/dist/debug-capture.js +25 -5
- package/dist/index.d.ts +2 -0
- package/dist/index.mjs +36 -16
- package/dist/requests.d.ts +30 -0
- package/dist/submit.d.ts +11 -0
- package/dist/ui/strings.d.ts +26 -0
- package/dist/ui/styles.d.ts +1 -1
- package/package.json +1 -1
- package/src/embed.ts +7 -1
- package/src/index.ts +2 -0
- package/src/install.ts +10 -0
- package/src/requests.ts +109 -0
- package/src/submit.ts +19 -16
- package/src/ui/annotator.ts +2 -0
- package/src/ui/element.ts +242 -52
- package/src/ui/strings.ts +73 -0
- package/src/ui/styles.ts +22 -2
package/src/ui/strings.ts
CHANGED
|
@@ -64,6 +64,37 @@ export interface Strings {
|
|
|
64
64
|
handoffFailed: string;
|
|
65
65
|
handoffBlocked: string;
|
|
66
66
|
handoffOpen: string;
|
|
67
|
+
/*
|
|
68
|
+
* ขอให้ทีมดำเนินการ — the same dialog turned into a request, where the desk
|
|
69
|
+
* opens request types to its reporters (docs/WIDGET-ASK-PLAN.md): the door
|
|
70
|
+
* is a line in the report form, and back.
|
|
71
|
+
*/
|
|
72
|
+
askInstead: string;
|
|
73
|
+
askInsteadAction: string;
|
|
74
|
+
problemInstead: string;
|
|
75
|
+
problemInsteadAction: string;
|
|
76
|
+
requestTitle: string;
|
|
77
|
+
requestTypeLabel: string;
|
|
78
|
+
/** Carries `{time}`. */
|
|
79
|
+
requestTarget: string;
|
|
80
|
+
requestSummaryLabel: string;
|
|
81
|
+
requestSummaryPlaceholder: string;
|
|
82
|
+
requestDetailLabel: string;
|
|
83
|
+
requestDetailPlaceholder: string;
|
|
84
|
+
requestSubmit: string;
|
|
85
|
+
requestSubmitted: string;
|
|
86
|
+
/** The picture, a request's to keep or take off. */
|
|
87
|
+
requestWithShot: string;
|
|
88
|
+
requestAnnotateHint: string;
|
|
89
|
+
/** What was typed last time and not sent, back in the form — and the way to clear it. */
|
|
90
|
+
draftRestored: string;
|
|
91
|
+
draftClear: string;
|
|
92
|
+
/** In the captured row, turned: what a request does NOT send. */
|
|
93
|
+
requestLeaves: string;
|
|
94
|
+
requestLeavesWhat: string;
|
|
95
|
+
/** Carry `{n}`. */
|
|
96
|
+
days: string;
|
|
97
|
+
hours: string;
|
|
67
98
|
}
|
|
68
99
|
|
|
69
100
|
const th: Strings = {
|
|
@@ -109,6 +140,27 @@ const th: Strings = {
|
|
|
109
140
|
handoffFailed: "เปิดรายการที่แจ้งไว้ไม่สำเร็จ",
|
|
110
141
|
handoffBlocked: "เบราว์เซอร์บล็อกการเปิดแท็บใหม่",
|
|
111
142
|
handoffOpen: "เปิดในแท็บใหม่",
|
|
143
|
+
askInstead: "เป็นคำขอ?",
|
|
144
|
+
askInsteadAction: "เลือกเรื่องที่ขอ",
|
|
145
|
+
problemInstead: "เป็นปัญหาที่ต้องแก้?",
|
|
146
|
+
problemInsteadAction: "แจ้งปัญหาแทน",
|
|
147
|
+
requestTitle: "ขอให้ทีมดำเนินการ",
|
|
148
|
+
requestTypeLabel: "เรื่องที่ขอ",
|
|
149
|
+
requestTarget: "ทีมตั้งใจให้เสร็จภายใน {time}",
|
|
150
|
+
requestSummaryLabel: "หัวข้อ",
|
|
151
|
+
requestSummaryPlaceholder: "ขออะไร — สั้น ๆ",
|
|
152
|
+
requestDetailLabel: "รายละเอียด (ไม่บังคับ)",
|
|
153
|
+
requestDetailPlaceholder: "สิ่งที่ทีมต้องรู้เพื่อดำเนินการ",
|
|
154
|
+
requestSubmit: "ส่งคำขอ",
|
|
155
|
+
requestSubmitted: "ส่งคำขอแล้ว",
|
|
156
|
+
requestWithShot: "แนบภาพหน้าจอนี้ไปกับคำขอ",
|
|
157
|
+
requestAnnotateHint: "ทำเครื่องหมายสิ่งที่ขอบนภาพ — วงกรอบ ชี้ลูกศร ไฮไลต์ หรือพิมพ์ข้อความ",
|
|
158
|
+
draftRestored: "ข้อความที่พิมพ์ไว้ครั้งก่อน ยังไม่ได้ส่ง",
|
|
159
|
+
draftClear: "ล้าง",
|
|
160
|
+
requestLeaves: "ไม่ส่งไปกับคำขอ",
|
|
161
|
+
requestLeavesWhat: "บันทึกการใช้งานของหน้านี้ — ใช้กับการแจ้งปัญหาเท่านั้น",
|
|
162
|
+
days: "{n} วัน",
|
|
163
|
+
hours: "{n} ชั่วโมง",
|
|
112
164
|
};
|
|
113
165
|
|
|
114
166
|
const en: Strings = {
|
|
@@ -154,6 +206,27 @@ const en: Strings = {
|
|
|
154
206
|
handoffFailed: "Could not open your reports",
|
|
155
207
|
handoffBlocked: "Your browser blocked the new tab",
|
|
156
208
|
handoffOpen: "Open in a new tab",
|
|
209
|
+
askInstead: "Asking for something?",
|
|
210
|
+
askInsteadAction: "Choose what you need",
|
|
211
|
+
problemInstead: "Something broken?",
|
|
212
|
+
problemInsteadAction: "Report a problem instead",
|
|
213
|
+
requestTitle: "Ask the team",
|
|
214
|
+
requestTypeLabel: "What you need",
|
|
215
|
+
requestTarget: "The team aims to finish within {time}",
|
|
216
|
+
requestSummaryLabel: "Subject",
|
|
217
|
+
requestSummaryPlaceholder: "What do you need — briefly",
|
|
218
|
+
requestDetailLabel: "Details (optional)",
|
|
219
|
+
requestDetailPlaceholder: "What the team needs to know to do it",
|
|
220
|
+
requestSubmit: "Send request",
|
|
221
|
+
requestSubmitted: "Request sent",
|
|
222
|
+
requestWithShot: "Attach this screenshot to the request",
|
|
223
|
+
requestAnnotateHint: "Mark what you are asking about — box it, point at it, highlight it, or type on it",
|
|
224
|
+
draftRestored: "What you typed last time, not sent yet",
|
|
225
|
+
draftClear: "Clear",
|
|
226
|
+
requestLeaves: "Not sent with a request",
|
|
227
|
+
requestLeavesWhat: "this page's activity log — it is for problem reports only",
|
|
228
|
+
days: "{n} days",
|
|
229
|
+
hours: "{n} hours",
|
|
157
230
|
};
|
|
158
231
|
|
|
159
232
|
export function strings(locale: "th" | "en" | undefined): Strings {
|
package/src/ui/styles.ts
CHANGED
|
@@ -34,11 +34,11 @@ h2 { margin: 0; font-size: 20px; font-weight: 700; flex: 1; }
|
|
|
34
34
|
label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
|
|
35
35
|
.req { color: #dc2626; }
|
|
36
36
|
.hint { font-weight: 400; color: #64748b; }
|
|
37
|
-
input[type="text"], textarea {
|
|
37
|
+
input[type="text"], textarea, select {
|
|
38
38
|
width: 100%; padding: 10px 12px; font: inherit; font-size: 14px;
|
|
39
39
|
border: 1px solid #cbd5e1; border-radius: 10px; background: #fff; color: inherit;
|
|
40
40
|
}
|
|
41
|
-
input[type="text"]:focus, textarea:focus {
|
|
41
|
+
input[type="text"]:focus, textarea:focus, select:focus {
|
|
42
42
|
outline: none; border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
|
|
43
43
|
}
|
|
44
44
|
textarea { min-height: 88px; resize: vertical; }
|
|
@@ -93,4 +93,24 @@ canvas { width: 100%; height: auto; display: block; border: 1px solid #e2e8f0; b
|
|
|
93
93
|
border-radius: 0 0 16px 16px;
|
|
94
94
|
}
|
|
95
95
|
.foot .grow { flex: 1; }
|
|
96
|
+
|
|
97
|
+
/* ขอให้ทีมดำเนินการ — the same dialog turned into a request (docs/WIDGET-ASK-PLAN.md).
|
|
98
|
+
The door is a quiet line under the heading: read by the one who asks,
|
|
99
|
+
costing nothing to the many who report. */
|
|
100
|
+
[hidden] { display: none !important; }
|
|
101
|
+
.door { margin: -8px 0 0; font-size: 13px; color: #64748b; }
|
|
102
|
+
button.link {
|
|
103
|
+
display: inline; padding: 0; border: 0; border-radius: 4px; background: none;
|
|
104
|
+
font-size: 13px; font-weight: 600; color: #2563eb;
|
|
105
|
+
text-decoration: underline; text-underline-offset: 3px;
|
|
106
|
+
}
|
|
107
|
+
button.link:hover:not(:disabled) { background: none; color: #1d4ed8; }
|
|
108
|
+
button.link:focus-visible { outline: 2px solid #2563eb; outline-offset: 2px; }
|
|
109
|
+
.ask p { margin: 0; }
|
|
110
|
+
.draft { margin: -8px 0 0; padding: 8px 12px; border-radius: 10px; background: #eff6ff; font-size: 13px; color: #1e3a8a; }
|
|
111
|
+
.ask .status { margin-top: 6px; }
|
|
112
|
+
.ask-type { font-size: 14px; font-weight: 600; }
|
|
113
|
+
.shot-choice { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 500; }
|
|
114
|
+
.shot-choice input { width: 16px; height: 16px; margin: 0; accent-color: #2563eb; }
|
|
115
|
+
.dropped { opacity: 0.35; pointer-events: none; }
|
|
96
116
|
`;
|