react-os-shell 0.2.35 → 0.2.36
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.js +93 -84
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -516,91 +516,100 @@ function BugReportProvider({ children }) {
|
|
|
516
516
|
const isBug = reportType === "bug";
|
|
517
517
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
518
518
|
children,
|
|
519
|
-
/* @__PURE__ */ jsxs(
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
519
|
+
/* @__PURE__ */ jsxs(
|
|
520
|
+
Dialog,
|
|
521
|
+
{
|
|
522
|
+
open,
|
|
523
|
+
onClose: annotating ? () => {
|
|
524
|
+
} : handleCancel,
|
|
525
|
+
className: "relative z-[9999]",
|
|
526
|
+
children: [
|
|
527
|
+
/* @__PURE__ */ jsx(DialogBackdrop, { className: "fixed inset-0 bg-black/40" }),
|
|
528
|
+
/* @__PURE__ */ jsx("div", { className: "fixed inset-0 flex items-center justify-center p-4", children: /* @__PURE__ */ jsxs(DialogPanel, { className: "w-full max-w-2xl rounded-lg bg-white p-6 shadow-xl", children: [
|
|
529
|
+
/* @__PURE__ */ jsx(DialogTitle, { className: "text-base font-semibold text-gray-900", children: "Suggestion or Bug" }),
|
|
530
|
+
/* @__PURE__ */ jsx("p", { className: "mt-1 text-xs text-gray-500", children: "A screenshot of your current view will be sent to the admin team." }),
|
|
531
|
+
/* @__PURE__ */ jsxs("div", { className: "mt-4 inline-flex rounded-lg border border-gray-300 bg-gray-50 p-0.5", children: [
|
|
532
|
+
/* @__PURE__ */ jsx(
|
|
533
|
+
"button",
|
|
534
|
+
{
|
|
535
|
+
type: "button",
|
|
536
|
+
onClick: () => setReportType("bug"),
|
|
537
|
+
className: `px-3 py-1 text-sm font-medium rounded-md transition-colors ${isBug ? "bg-white text-gray-900 shadow-sm" : "text-gray-600 hover:text-gray-900"}`,
|
|
538
|
+
children: "Bug"
|
|
539
|
+
}
|
|
540
|
+
),
|
|
541
|
+
/* @__PURE__ */ jsx(
|
|
542
|
+
"button",
|
|
543
|
+
{
|
|
544
|
+
type: "button",
|
|
545
|
+
onClick: () => setReportType("suggestion"),
|
|
546
|
+
className: `px-3 py-1 text-sm font-medium rounded-md transition-colors ${!isBug ? "bg-white text-gray-900 shadow-sm" : "text-gray-600 hover:text-gray-900"}`,
|
|
547
|
+
children: "Suggestion"
|
|
548
|
+
}
|
|
549
|
+
)
|
|
550
|
+
] }),
|
|
551
|
+
previewUrl && /* @__PURE__ */ jsxs("div", { className: "mt-4", children: [
|
|
552
|
+
/* @__PURE__ */ jsxs("div", { className: "relative rounded-md border border-gray-200 overflow-hidden bg-gray-50 max-h-64", children: [
|
|
553
|
+
/* @__PURE__ */ jsx("img", { src: previewUrl, alt: "Screenshot preview", className: "w-full h-auto max-h-64 object-contain" }),
|
|
554
|
+
/* @__PURE__ */ jsxs(
|
|
555
|
+
"button",
|
|
556
|
+
{
|
|
557
|
+
type: "button",
|
|
558
|
+
onClick: () => setAnnotating(true),
|
|
559
|
+
className: "absolute top-2 right-2 inline-flex items-center gap-1 px-2.5 py-1 rounded-md bg-white/95 backdrop-blur border border-gray-200 shadow-sm text-xs font-medium text-gray-700 hover:bg-white",
|
|
560
|
+
title: "Mark up the screenshot \u2014 circle, arrow, mosaic, text\u2026",
|
|
561
|
+
children: [
|
|
562
|
+
/* @__PURE__ */ jsx("svg", { className: "h-3.5 w-3.5", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", strokeWidth: 1.7, children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M16.862 4.487l1.687-1.688a1.875 1.875 0 112.652 2.652L6.832 19.82a4.5 4.5 0 01-1.897 1.13l-2.685.8.8-2.685a4.5 4.5 0 011.13-1.897L16.863 4.487zm0 0L19.5 7.125" }) }),
|
|
563
|
+
"Annotate"
|
|
564
|
+
]
|
|
565
|
+
}
|
|
566
|
+
)
|
|
567
|
+
] }),
|
|
568
|
+
/* @__PURE__ */ jsx("p", { className: "mt-1 text-[11px] text-gray-400", children: "Click Annotate to mark up the screenshot before sending." })
|
|
569
|
+
] }),
|
|
570
|
+
!previewUrl && /* @__PURE__ */ jsx(UploadDropZone, { onSelect: (blob) => setScreenshot(blob) }),
|
|
571
|
+
/* @__PURE__ */ jsxs("label", { className: "mt-4 block text-sm font-medium text-gray-700", children: [
|
|
572
|
+
isBug ? "What went wrong?" : "What's your suggestion?",
|
|
573
|
+
/* @__PURE__ */ jsx("span", { className: "font-normal text-gray-400 ml-1", children: "(optional)" })
|
|
574
|
+
] }),
|
|
575
|
+
/* @__PURE__ */ jsx(
|
|
576
|
+
"textarea",
|
|
549
577
|
{
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
578
|
+
autoFocus: true,
|
|
579
|
+
value: description,
|
|
580
|
+
onChange: (e) => setDescription(e.target.value),
|
|
581
|
+
onKeyDown: (e) => {
|
|
582
|
+
if (e.key === "Enter" && (e.metaKey || e.ctrlKey)) handleSubmit();
|
|
583
|
+
},
|
|
584
|
+
placeholder: isBug ? "Briefly describe the issue, what you were doing, what you expected to happen\u2026" : "Briefly describe what would make this better\u2026",
|
|
585
|
+
rows: 3,
|
|
586
|
+
className: "mt-1 w-full rounded-md border border-gray-300 px-3 py-2 text-sm focus:border-blue-500 focus:ring-1 focus:ring-blue-500 focus:outline-none resize-none"
|
|
558
587
|
}
|
|
559
|
-
)
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
}
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
"button",
|
|
585
|
-
{
|
|
586
|
-
type: "button",
|
|
587
|
-
onClick: handleCancel,
|
|
588
|
-
className: "bg-white text-gray-700 border border-gray-300 px-4 py-2 text-sm font-medium rounded-lg hover:bg-gray-50",
|
|
589
|
-
children: "Cancel"
|
|
590
|
-
}
|
|
591
|
-
),
|
|
592
|
-
/* @__PURE__ */ jsx(
|
|
593
|
-
"button",
|
|
594
|
-
{
|
|
595
|
-
type: "button",
|
|
596
|
-
onClick: handleSubmit,
|
|
597
|
-
className: "bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 text-sm font-medium rounded-lg",
|
|
598
|
-
children: "Send"
|
|
599
|
-
}
|
|
600
|
-
)
|
|
601
|
-
] })
|
|
602
|
-
] }) })
|
|
603
|
-
] }),
|
|
588
|
+
),
|
|
589
|
+
/* @__PURE__ */ jsxs("div", { className: "mt-6 flex justify-end gap-3", children: [
|
|
590
|
+
/* @__PURE__ */ jsx(
|
|
591
|
+
"button",
|
|
592
|
+
{
|
|
593
|
+
type: "button",
|
|
594
|
+
onClick: handleCancel,
|
|
595
|
+
className: "bg-white text-gray-700 border border-gray-300 px-4 py-2 text-sm font-medium rounded-lg hover:bg-gray-50",
|
|
596
|
+
children: "Cancel"
|
|
597
|
+
}
|
|
598
|
+
),
|
|
599
|
+
/* @__PURE__ */ jsx(
|
|
600
|
+
"button",
|
|
601
|
+
{
|
|
602
|
+
type: "button",
|
|
603
|
+
onClick: handleSubmit,
|
|
604
|
+
className: "bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 text-sm font-medium rounded-lg",
|
|
605
|
+
children: "Send"
|
|
606
|
+
}
|
|
607
|
+
)
|
|
608
|
+
] })
|
|
609
|
+
] }) })
|
|
610
|
+
]
|
|
611
|
+
}
|
|
612
|
+
),
|
|
604
613
|
annotating && previewUrl && /* @__PURE__ */ jsx(
|
|
605
614
|
BugReportAnnotator,
|
|
606
615
|
{
|
|
@@ -849,7 +858,7 @@ function StatusBadge({ status }) {
|
|
|
849
858
|
}
|
|
850
859
|
|
|
851
860
|
// src/version.ts
|
|
852
|
-
var VERSION = "0.2.
|
|
861
|
+
var VERSION = "0.2.36" ;
|
|
853
862
|
var APP_VERSION = VERSION;
|
|
854
863
|
|
|
855
864
|
// src/changelog.ts
|