@monster-orange/den-ui 0.7.4 → 0.7.6
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 +96 -0
- package/package.json +11 -1
- package/src/kit.d.ts +7 -0
- package/src/kit.js +10 -0
- package/src/markdown-editor.css +230 -0
- package/src/markdown-editor.d.ts +187 -0
- package/src/markdown-editor.js +1122 -0
- package/src/report.d.ts +7 -1
- package/src/report.js +32 -2
- package/src/savestate.css +75 -0
- package/src/savestate.d.ts +73 -0
- package/src/savestate.js +294 -0
- package/src/shell-html.d.ts +5 -0
- package/src/shell-html.js +43 -2
- package/src/shell.css +16 -0
- package/src/strings.js +74 -0
- package/src/whatsnew.js +13 -2
package/src/strings.js
CHANGED
|
@@ -27,6 +27,9 @@ export const en = {
|
|
|
27
27
|
"kit.bell": "Notifications",
|
|
28
28
|
"kit.bell.n": "Notifications: {n} unread",
|
|
29
29
|
"kit.bell.empty": "Nothing new.",
|
|
30
|
+
"kit.bell.needs": "Needs you",
|
|
31
|
+
"kit.bell.earlier": "Earlier",
|
|
32
|
+
"kit.bell.needsNone": "Nothing needs you now.",
|
|
30
33
|
"kit.settings": "Settings",
|
|
31
34
|
"kit.appearance": "Appearance",
|
|
32
35
|
"kit.appearance.title": "Appearance and theme",
|
|
@@ -117,6 +120,11 @@ export const en = {
|
|
|
117
120
|
"kit.report.cancel": "Cancel",
|
|
118
121
|
"kit.report.dest": "Goes to",
|
|
119
122
|
"kit.report.pub": "Public repository",
|
|
123
|
+
"kit.report.priv": "Private repository",
|
|
124
|
+
"kit.report.int": "Internal repository",
|
|
125
|
+
"kit.report.privN": "Only people with access to this repository can see it.",
|
|
126
|
+
"kit.report.privW":
|
|
127
|
+
"Only people with access to this repository can see it: {who}.",
|
|
120
128
|
"kit.report.pubW":
|
|
121
129
|
"Screenshots and text are visible to everyone. Mask anything private.",
|
|
122
130
|
"kit.report.incH": "What goes with your report",
|
|
@@ -179,6 +187,24 @@ export const en = {
|
|
|
179
187
|
"kit.report.copyFailed":
|
|
180
188
|
"Could not copy. Select the text and copy it yourself.",
|
|
181
189
|
"kit.report.copyH": "Copy the report",
|
|
190
|
+
// The Markdown editor (markdown-editor.js, 0.7.5): its toolbar.
|
|
191
|
+
"kit.md.toolbar": "Formatting",
|
|
192
|
+
"kit.md.toolKey": "{name} ({key})",
|
|
193
|
+
"kit.md.bold": "Bold",
|
|
194
|
+
"kit.md.italic": "Italic",
|
|
195
|
+
"kit.md.code": "Code",
|
|
196
|
+
"kit.md.link": "Link",
|
|
197
|
+
"kit.md.heading": "Heading",
|
|
198
|
+
"kit.md.bulleted": "Bulleted list",
|
|
199
|
+
"kit.md.numbered": "Numbered list",
|
|
200
|
+
"kit.md.quote": "Quote",
|
|
201
|
+
"kit.md.linkText": "text",
|
|
202
|
+
// The save-state line (savestate.js). "Saved" has no closing stop.
|
|
203
|
+
"kit.savestate.saving": "Saving…",
|
|
204
|
+
"kit.savestate.saved": "Saved",
|
|
205
|
+
"kit.savestate.error": "Not saved. Retrying…",
|
|
206
|
+
"kit.savestate.copy": "Copy text",
|
|
207
|
+
"kit.savestate.savedAt": "Saved at {time}",
|
|
182
208
|
};
|
|
183
209
|
|
|
184
210
|
export const es = {
|
|
@@ -198,6 +224,9 @@ export const es = {
|
|
|
198
224
|
"kit.bell": "Notificaciones",
|
|
199
225
|
"kit.bell.n": "Notificaciones: {n} sin leer",
|
|
200
226
|
"kit.bell.empty": "Nada nuevo.",
|
|
227
|
+
"kit.bell.needs": "Te necesitan",
|
|
228
|
+
"kit.bell.earlier": "Antes",
|
|
229
|
+
"kit.bell.needsNone": "Nada te necesita ahora.",
|
|
201
230
|
"kit.settings": "Ajustes",
|
|
202
231
|
"kit.appearance": "Apariencia",
|
|
203
232
|
"kit.appearance.title": "Apariencia y tema",
|
|
@@ -290,6 +319,11 @@ export const es = {
|
|
|
290
319
|
"kit.report.cancel": "Cancelar",
|
|
291
320
|
"kit.report.dest": "Va a",
|
|
292
321
|
"kit.report.pub": "Repositorio público",
|
|
322
|
+
"kit.report.priv": "Repositorio privado",
|
|
323
|
+
"kit.report.int": "Repositorio interno",
|
|
324
|
+
"kit.report.privN": "Solo lo ve quien tiene acceso a este repositorio.",
|
|
325
|
+
"kit.report.privW":
|
|
326
|
+
"Solo lo ve quien tiene acceso a este repositorio: {who}.",
|
|
293
327
|
"kit.report.pubW":
|
|
294
328
|
"Las capturas y el texto los ve todo el mundo. Tapa lo que sea privado.",
|
|
295
329
|
"kit.report.incH": "Qué va con tu informe",
|
|
@@ -356,6 +390,22 @@ export const es = {
|
|
|
356
390
|
"kit.report.copyFailed":
|
|
357
391
|
"No se pudo copiar. Selecciona el texto y cópialo tú.",
|
|
358
392
|
"kit.report.copyH": "Copia el informe",
|
|
393
|
+
"kit.md.toolbar": "Formato",
|
|
394
|
+
"kit.md.toolKey": "{name} ({key})",
|
|
395
|
+
"kit.md.bold": "Negrita",
|
|
396
|
+
"kit.md.italic": "Cursiva",
|
|
397
|
+
"kit.md.code": "Código",
|
|
398
|
+
"kit.md.link": "Enlace",
|
|
399
|
+
"kit.md.heading": "Encabezado",
|
|
400
|
+
"kit.md.bulleted": "Lista con viñetas",
|
|
401
|
+
"kit.md.numbered": "Lista numerada",
|
|
402
|
+
"kit.md.quote": "Cita",
|
|
403
|
+
"kit.md.linkText": "texto",
|
|
404
|
+
"kit.savestate.saving": "Guardando…",
|
|
405
|
+
"kit.savestate.saved": "Guardado",
|
|
406
|
+
"kit.savestate.error": "No se guardó. Reintentando…",
|
|
407
|
+
"kit.savestate.copy": "Copiar texto",
|
|
408
|
+
"kit.savestate.savedAt": "Guardado a las {time}",
|
|
359
409
|
};
|
|
360
410
|
|
|
361
411
|
export const ja = {
|
|
@@ -375,6 +425,9 @@ export const ja = {
|
|
|
375
425
|
"kit.bell": "通知",
|
|
376
426
|
"kit.bell.n": "通知: 未読 {n} 件",
|
|
377
427
|
"kit.bell.empty": "新しいものはありません。",
|
|
428
|
+
"kit.bell.needs": "対応が必要",
|
|
429
|
+
"kit.bell.earlier": "以前",
|
|
430
|
+
"kit.bell.needsNone": "今、対応が必要なものはありません。",
|
|
378
431
|
"kit.settings": "設定",
|
|
379
432
|
"kit.appearance": "外観",
|
|
380
433
|
"kit.appearance.title": "外観とテーマ",
|
|
@@ -462,6 +515,11 @@ export const ja = {
|
|
|
462
515
|
"kit.report.cancel": "キャンセル",
|
|
463
516
|
"kit.report.dest": "送り先",
|
|
464
517
|
"kit.report.pub": "公開リポジトリ",
|
|
518
|
+
"kit.report.priv": "非公開リポジトリ",
|
|
519
|
+
"kit.report.int": "内部リポジトリ",
|
|
520
|
+
"kit.report.privN": "このリポジトリにアクセスできる人だけが見られます。",
|
|
521
|
+
"kit.report.privW":
|
|
522
|
+
"このリポジトリにアクセスできる人だけが見られます({who})。",
|
|
465
523
|
"kit.report.pubW":
|
|
466
524
|
"スクリーンショットとテキストは誰でも見られます。見せたくない部分は隠してください。",
|
|
467
525
|
"kit.report.incH": "報告に添えるもの",
|
|
@@ -528,6 +586,22 @@ export const ja = {
|
|
|
528
586
|
"kit.report.copyFailed":
|
|
529
587
|
"コピーできませんでした。テキストを選んでコピーしてください。",
|
|
530
588
|
"kit.report.copyH": "報告をコピー",
|
|
589
|
+
"kit.md.toolbar": "書式",
|
|
590
|
+
"kit.md.toolKey": "{name}({key})",
|
|
591
|
+
"kit.md.bold": "太字",
|
|
592
|
+
"kit.md.italic": "斜体",
|
|
593
|
+
"kit.md.code": "コード",
|
|
594
|
+
"kit.md.link": "リンク",
|
|
595
|
+
"kit.md.heading": "見出し",
|
|
596
|
+
"kit.md.bulleted": "箇条書き",
|
|
597
|
+
"kit.md.numbered": "番号付きリスト",
|
|
598
|
+
"kit.md.quote": "引用",
|
|
599
|
+
"kit.md.linkText": "テキスト",
|
|
600
|
+
"kit.savestate.saving": "保存しています…",
|
|
601
|
+
"kit.savestate.saved": "保存しました",
|
|
602
|
+
"kit.savestate.error": "保存できていません。再試行しています…",
|
|
603
|
+
"kit.savestate.copy": "テキストをコピー",
|
|
604
|
+
"kit.savestate.savedAt": "{time} に保存しました",
|
|
531
605
|
};
|
|
532
606
|
|
|
533
607
|
/** The kit's tables, by language (en is the fallback for any key). */
|
package/src/whatsnew.js
CHANGED
|
@@ -14,7 +14,8 @@
|
|
|
14
14
|
* loadWhatsNew() asks changelog() and keeps the entries
|
|
15
15
|
* setEntries(list) or gives them directly
|
|
16
16
|
* openWhatsNew() opens it at the newest release; focus on its heading
|
|
17
|
-
* closeWhatsNew() closes it; focus back where it was (else the chip)
|
|
17
|
+
* closeWhatsNew() closes it; focus back where it was (else the chip),
|
|
18
|
+
* unless the page put it in a control of its own meanwhile
|
|
18
19
|
* changelogView(entries, showAll) what it shows (pure)
|
|
19
20
|
*
|
|
20
21
|
* It is an aria-modal dialog: Tab stays in it, Escape and a click on the
|
|
@@ -399,11 +400,21 @@ export function openWhatsNew() {
|
|
|
399
400
|
export function closeWhatsNew() {
|
|
400
401
|
const overlay = document.getElementById("cl-overlay");
|
|
401
402
|
const wasOpen = !!overlay?.classList.contains("open");
|
|
403
|
+
// Issue 143: where the keyboard is now. The page may have given it to a
|
|
404
|
+
// field of its own while this was open (a deep link's composer, which
|
|
405
|
+
// came after What's new): that field keeps it.
|
|
406
|
+
const at = document.activeElement;
|
|
407
|
+
const elsewhere =
|
|
408
|
+
!!at &&
|
|
409
|
+
at !== document.body &&
|
|
410
|
+
at !== document.documentElement &&
|
|
411
|
+
!overlay?.contains(at);
|
|
402
412
|
if (overlay) overlay.classList.remove("open");
|
|
403
413
|
if (wasOpen) {
|
|
404
414
|
const back = returnFocus;
|
|
405
415
|
returnFocus = null;
|
|
406
|
-
if (!focusBack(back))
|
|
416
|
+
if (!elsewhere && !focusBack(back))
|
|
417
|
+
focusBack(document.getElementById("version-pill"));
|
|
407
418
|
}
|
|
408
419
|
if (cfg.onClose) cfg.onClose(entries[0]?.version ?? null);
|
|
409
420
|
const pip = document.getElementById("v-pip");
|