@mushi-mushi/web 1.39.1 → 1.40.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/dist/index.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { MushiInitConfig, MushiSDKInstance, MushiDiagnosticsResult, MushiReportCategory, MushiReporterReport, MushiReporterComment, MushiReporterTimelineItem, MushiAssistantReply, MushiWidgetConfig, MushiLeaderboardEntry, MushiCrossAppReport, MushiTesterReputation, MushiReporterUpdates, MushiApiCascadeConfig, MushiErrorFilter } from '@mushi-mushi/core';
1
+ import { MushiInitConfig, MushiSDKInstance, MushiDiagnosticsResult, MushiReportCategory, MushiReporterReport, MushiReporterComment, MushiReporterTimelineItem, MushiAssistantReply, MushiWidgetConfig, MushiLeaderboardEntry, MushiCrossAppReport, MushiTesterReputation, MushiReporterUpdates, MushiReportTypeId, MushiReportTypeTone, MushiApiCascadeConfig, MushiErrorFilter } from '@mushi-mushi/core';
2
2
  export { MushiApiCascadeConfig, MushiConfig, MushiConsoleEntry, MushiDiagnosticsResult, MushiEnvironment, MushiEventHandler, MushiEventType, MushiInitConfig, MushiNetworkEntry, MushiPerformanceMetrics, MushiReport, MushiReportCategory, MushiSDKInstance, MushiTimelineEntry, MushiTimelineKind, MushiUrlMatcher, MushiWidgetConfig } from '@mushi-mushi/core';
3
3
  import { g as ScreenshotFailureReason } from './timeline-DoBCj4dt.cjs';
4
4
  export { C as ConsoleCapture, E as ElementSelector, N as NetworkCapture, P as PerformanceCapture, S as ScreenshotCapture, T as TimelineCapture, c as createConsoleCapture, a as createElementSelector, b as createNetworkCapture, d as createPerformanceCapture, e as createScreenshotCapture, f as createTimelineCapture } from './timeline-DoBCj4dt.cjs';
@@ -206,6 +206,14 @@ declare class MushiWidget {
206
206
  private showAllCategories;
207
207
  /** Header overflow menu. */
208
208
  private showMoreNav;
209
+ /** Send was pressed below the minimum; the meter stays red until the text is long enough. */
210
+ private lengthNudge;
211
+ /** Shake the meter on the next render only (not on every later keystroke). */
212
+ private nudgeShake;
213
+ /** The header BETA chip's disclosure (ADR 0070). */
214
+ private betaOpen;
215
+ /** A pointer tap picked a type: move focus to the textarea after the patch. */
216
+ private focusDescriptionNext;
209
217
  private screenshotAttached;
210
218
  private screenshotCapturing;
211
219
  private screenshotError;
@@ -478,7 +486,11 @@ declare class MushiWidget {
478
486
  private dragOptions;
479
487
  private render;
480
488
  private renderPanel;
481
- /** On a new surface: the report textarea, else the title, so screen readers announce where they are. */
489
+ /**
490
+ * On a new surface: the report screen's first step (the checked or first
491
+ * type tile; the textarea when a type was preset or text is drafted), else
492
+ * the textarea, else the title, so screen readers announce where they are.
493
+ */
482
494
  private focusView;
483
495
  /** Snapshot field values + caret from the live DOM before a patch. */
484
496
  private captureFormDrafts;
@@ -519,6 +531,8 @@ declare class MushiWidget {
519
531
  private effectiveMinLength;
520
532
  /** Enough words, or something the reporter attached on purpose. */
521
533
  private canSend;
534
+ /** Characters still needed for Send (0 once `canSend()`), for the meter. */
535
+ private charsNeeded;
522
536
  private unreadCount;
523
537
  /** Read-only snapshot + helper closures for the stateless view layer. */
524
538
  private renderCtx;
@@ -630,6 +644,7 @@ declare class MushiWidget {
630
644
  * Called only on hex values that already passed safeWidgetHex(), so the
631
645
  * regex-based extraction is always well-defined on valid 6-char inputs.
632
646
  */
647
+
633
648
  interface WidgetThemeVars {
634
649
  isDark: boolean;
635
650
  paper: string;
@@ -685,6 +700,13 @@ interface WidgetThemeVars {
685
700
  border: string;
686
701
  };
687
702
  statusClosedBg: string;
703
+ /** Report-type tile colours (core MUSHI_REPORT_TYPE_COLORS) for this mode. */
704
+ reportTypes: Record<MushiReportTypeId, MushiReportTypeTone>;
705
+ /** Tile fill: `solid` at these opacities (unpicked, picked). */
706
+ reportTypeWash: {
707
+ wash: number;
708
+ strong: number;
709
+ };
688
710
  fontDisplay: string;
689
711
  fontBody: string;
690
712
  fontMono: string;
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { MushiInitConfig, MushiSDKInstance, MushiDiagnosticsResult, MushiPrivacyConfig, MushiReportCategory, MushiReporterReport, MushiReporterComment, MushiReporterTimelineItem, MushiAssistantReply, MushiWidgetConfig, MushiLeaderboardEntry, MushiCrossAppReport, MushiTesterReputation, MushiReporterUpdates, MushiConsoleEntry, MushiNetworkEntry, MushiUrlMatcher, MushiTracePropagationConfig, MushiPerformanceMetrics, MushiSelectedElement, MushiTimelineEntry, MushiApiCascadeConfig, MushiErrorFilter } from '@mushi-mushi/core';
1
+ import { MushiInitConfig, MushiSDKInstance, MushiDiagnosticsResult, MushiPrivacyConfig, MushiReportCategory, MushiReporterReport, MushiReporterComment, MushiReporterTimelineItem, MushiAssistantReply, MushiWidgetConfig, MushiLeaderboardEntry, MushiCrossAppReport, MushiTesterReputation, MushiReporterUpdates, MushiConsoleEntry, MushiNetworkEntry, MushiUrlMatcher, MushiTracePropagationConfig, MushiPerformanceMetrics, MushiSelectedElement, MushiTimelineEntry, MushiReportTypeId, MushiReportTypeTone, MushiApiCascadeConfig, MushiErrorFilter } from '@mushi-mushi/core';
2
2
  export { MushiApiCascadeConfig, MushiConfig, MushiConsoleEntry, MushiDiagnosticsResult, MushiEnvironment, MushiEventHandler, MushiEventType, MushiInitConfig, MushiNetworkEntry, MushiPerformanceMetrics, MushiReport, MushiReportCategory, MushiSDKInstance, MushiTimelineEntry, MushiTimelineKind, MushiUrlMatcher, MushiWidgetConfig } from '@mushi-mushi/core';
3
3
 
4
4
  declare class Mushi {
@@ -228,6 +228,14 @@ declare class MushiWidget {
228
228
  private showAllCategories;
229
229
  /** Header overflow menu. */
230
230
  private showMoreNav;
231
+ /** Send was pressed below the minimum; the meter stays red until the text is long enough. */
232
+ private lengthNudge;
233
+ /** Shake the meter on the next render only (not on every later keystroke). */
234
+ private nudgeShake;
235
+ /** The header BETA chip's disclosure (ADR 0070). */
236
+ private betaOpen;
237
+ /** A pointer tap picked a type: move focus to the textarea after the patch. */
238
+ private focusDescriptionNext;
231
239
  private screenshotAttached;
232
240
  private screenshotCapturing;
233
241
  private screenshotError;
@@ -500,7 +508,11 @@ declare class MushiWidget {
500
508
  private dragOptions;
501
509
  private render;
502
510
  private renderPanel;
503
- /** On a new surface: the report textarea, else the title, so screen readers announce where they are. */
511
+ /**
512
+ * On a new surface: the report screen's first step (the checked or first
513
+ * type tile; the textarea when a type was preset or text is drafted), else
514
+ * the textarea, else the title, so screen readers announce where they are.
515
+ */
504
516
  private focusView;
505
517
  /** Snapshot field values + caret from the live DOM before a patch. */
506
518
  private captureFormDrafts;
@@ -541,6 +553,8 @@ declare class MushiWidget {
541
553
  private effectiveMinLength;
542
554
  /** Enough words, or something the reporter attached on purpose. */
543
555
  private canSend;
556
+ /** Characters still needed for Send (0 once `canSend()`), for the meter. */
557
+ private charsNeeded;
544
558
  private unreadCount;
545
559
  /** Read-only snapshot + helper closures for the stateless view layer. */
546
560
  private renderCtx;
@@ -806,8 +820,23 @@ interface MushiLocale {
806
820
  pointAt: string;
807
821
  remove: string;
808
822
  markUp: string;
809
- /** Privacy line under the attachments. */
823
+ /** Privacy sentence: the tooltip and screen-reader text of the footer 🔒 line. */
810
824
  privacy: string;
825
+ /**
826
+ * The footer 🔒 line itself, a few words (ADR 0070). Optional so a custom
827
+ * locale written before 1.40 still type-checks; English fills the gap.
828
+ */
829
+ privacyShort?: string;
830
+ /** Accessible name of the report-type tile group. */
831
+ typeQuestion?: string;
832
+ /** Textarea prompt per picked type; `other` is also the prompt before a pick. */
833
+ prompts?: Partial<Record<'bug' | 'slow' | 'visual' | 'confusing' | 'idea' | 'other', string>>;
834
+ /** Length meter under the textarea; `{n}` = characters still needed. */
835
+ charsLeft?: string;
836
+ /** Announced once when the description reaches the minimum. */
837
+ ready?: string;
838
+ /** Big line under the success check. */
839
+ delivered?: string;
811
840
  send: string;
812
841
  /** Header pill that opens "Your reports". */
813
842
  yourReports: string;
@@ -984,6 +1013,7 @@ declare function getAvailableLocales(): string[];
984
1013
  * Called only on hex values that already passed safeWidgetHex(), so the
985
1014
  * regex-based extraction is always well-defined on valid 6-char inputs.
986
1015
  */
1016
+
987
1017
  interface WidgetThemeVars {
988
1018
  isDark: boolean;
989
1019
  paper: string;
@@ -1039,6 +1069,13 @@ interface WidgetThemeVars {
1039
1069
  border: string;
1040
1070
  };
1041
1071
  statusClosedBg: string;
1072
+ /** Report-type tile colours (core MUSHI_REPORT_TYPE_COLORS) for this mode. */
1073
+ reportTypes: Record<MushiReportTypeId, MushiReportTypeTone>;
1074
+ /** Tile fill: `solid` at these opacities (unpicked, picked). */
1075
+ reportTypeWash: {
1076
+ wash: number;
1077
+ strong: number;
1078
+ };
1042
1079
  fontDisplay: string;
1043
1080
  fontBody: string;
1044
1081
  fontMono: string;