react-os-shell 0.13.1 → 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/dist/{Browser-W63A4RUT.js → Browser-M5Y3ENA7.js} +3 -3
- package/dist/{Browser-W63A4RUT.js.map → Browser-M5Y3ENA7.js.map} +1 -1
- package/dist/{Calculator-Z2DAZD6K.js → Calculator-DJYKVGOK.js} +4 -4
- package/dist/{Calculator-Z2DAZD6K.js.map → Calculator-DJYKVGOK.js.map} +1 -1
- package/dist/{CurrencyConverter-S6RQB3OJ.js → CurrencyConverter-ZJWZCO5U.js} +4 -4
- package/dist/{CurrencyConverter-S6RQB3OJ.js.map → CurrencyConverter-ZJWZCO5U.js.map} +1 -1
- package/dist/{Documents-VE5Z7DRX.js → Documents-2S4QPAI3.js} +3 -3
- package/dist/{Documents-VE5Z7DRX.js.map → Documents-2S4QPAI3.js.map} +1 -1
- package/dist/Files-5N64E375.js +11 -0
- package/dist/{Files-5IXGRZKM.js.map → Files-5N64E375.js.map} +1 -1
- package/dist/{Minesweeper-WVAFWKCZ.js → Minesweeper-YNXOWMIP.js} +3 -3
- package/dist/{Minesweeper-WVAFWKCZ.js.map → Minesweeper-YNXOWMIP.js.map} +1 -1
- package/dist/{Notepad-OLNPHKTT.js → Notepad-AFAUA4KJ.js} +3 -3
- package/dist/{Notepad-OLNPHKTT.js.map → Notepad-AFAUA4KJ.js.map} +1 -1
- package/dist/{PomodoroTimer-ZJYDPFCT.js → PomodoroTimer-SBBPQMYB.js} +4 -4
- package/dist/{PomodoroTimer-ZJYDPFCT.js.map → PomodoroTimer-SBBPQMYB.js.map} +1 -1
- package/dist/Preview-KUAQIPBY.js +8 -0
- package/dist/{Preview-LTZOUTQ7.js.map → Preview-KUAQIPBY.js.map} +1 -1
- package/dist/Spreadsheet-TVP3SXT6.js +6 -0
- package/dist/{Spreadsheet-VT3ZISIN.js.map → Spreadsheet-TVP3SXT6.js.map} +1 -1
- package/dist/{Stock-DWESS6UC.js → Stock-ICDNFM7U.js} +4 -4
- package/dist/{Stock-DWESS6UC.js.map → Stock-ICDNFM7U.js.map} +1 -1
- package/dist/{Weather-NJHYEKH3.js → Weather-WH3URRSL.js} +4 -4
- package/dist/{Weather-NJHYEKH3.js.map → Weather-WH3URRSL.js.map} +1 -1
- package/dist/{WorldClock-UJKD253K.js → WorldClock-LJRWPGJW.js} +4 -4
- package/dist/{WorldClock-UJKD253K.js.map → WorldClock-LJRWPGJW.js.map} +1 -1
- package/dist/apps/index.js +18 -18
- package/dist/{chunk-IMFUTSYY.js → chunk-4RXDOSKZ.js} +22 -5
- package/dist/chunk-4RXDOSKZ.js.map +1 -0
- package/dist/{chunk-66GIT3PM.js → chunk-6DDVFASF.js} +3 -3
- package/dist/{chunk-66GIT3PM.js.map → chunk-6DDVFASF.js.map} +1 -1
- package/dist/{chunk-BS7EHYBT.js → chunk-7TG7VNJS.js} +3 -3
- package/dist/{chunk-BS7EHYBT.js.map → chunk-7TG7VNJS.js.map} +1 -1
- package/dist/{chunk-EFNKEBDB.js → chunk-D4ZM3K2S.js} +4 -4
- package/dist/{chunk-EFNKEBDB.js.map → chunk-D4ZM3K2S.js.map} +1 -1
- package/dist/{chunk-DMSHU2HJ.js → chunk-K354WXU5.js} +3 -3
- package/dist/{chunk-DMSHU2HJ.js.map → chunk-K354WXU5.js.map} +1 -1
- package/dist/{chunk-3SIZAHR6.js → chunk-OB7T3Q5C.js} +4 -4
- package/dist/{chunk-3SIZAHR6.js.map → chunk-OB7T3Q5C.js.map} +1 -1
- package/dist/index.d.ts +69 -2
- package/dist/index.js +353 -265
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/Files-5IXGRZKM.js +0 -11
- package/dist/Preview-LTZOUTQ7.js +0 -8
- package/dist/Spreadsheet-VT3ZISIN.js +0 -6
- package/dist/chunk-IMFUTSYY.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -4,22 +4,22 @@ import { subscribePomo, getPomoSnapshot } from './chunk-MK3HLUO4.js';
|
|
|
4
4
|
export { setShellTodoProvider } from './chunk-QTJ2CHJX.js';
|
|
5
5
|
import { useShellPrefs } from './chunk-36VM54SC.js';
|
|
6
6
|
export { ShellPrefsProvider, useLocalStoragePrefs, useShellPrefs } from './chunk-36VM54SC.js';
|
|
7
|
-
import { PREVIEW_OPENED_EVENT, openPreviewFile } from './chunk-
|
|
7
|
+
import { PREVIEW_OPENED_EVENT, openPreviewFile } from './chunk-OB7T3Q5C.js';
|
|
8
8
|
import { playNotification, playStartup, soundsEnabled, getSoundConfig, SOUND_PACK_KEYS, SOUND_PACKS, SOUND_TYPES, SOUND_TYPE_LABELS, setSoundForType, previewSound, setAllSounds, playLogout } from './chunk-D7PYW2QS.js';
|
|
9
|
-
import { setPdfPreview } from './chunk-
|
|
9
|
+
import { setPdfPreview } from './chunk-K354WXU5.js';
|
|
10
10
|
import './chunk-KUIPWCTJ.js';
|
|
11
11
|
import { toast_default } from './chunk-WIJ45SYD.js';
|
|
12
12
|
export { toast_default as toast } from './chunk-WIJ45SYD.js';
|
|
13
|
-
export { EditableGrid } from './chunk-
|
|
14
|
-
import { useWindowManager, PopupMenu, PopupMenuLabel, PopupMenuDivider, PopupMenuItem, Modal, WINDOW_REGISTRY, isPageEntry, useIsMobile, ModalActions, useModalActive, client_default, LoadingSpinner, setWindowPosition, ThumbCard, activateModal } from './chunk-
|
|
15
|
-
export { CancelButton, CopyButton, DocFavStar, Modal, ModalActions, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, WindowManagerProvider, WindowTitle, commitExposeHighlight, exitExposeMode, getActiveWindowRoute, getExposeHighlight, getWindowPosition, isEntityEntry, isPageEntry, setExposeHighlight, setShellApiClient, setShellWindowRegistry, setWindowDefaultPosition, setWindowPosition, subscribeExposeHighlight, toggleExposeMode, useModalActive, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle } from './chunk-
|
|
13
|
+
export { EditableGrid } from './chunk-6DDVFASF.js';
|
|
14
|
+
import { useWindowManager, PopupMenu, PopupMenuLabel, PopupMenuDivider, PopupMenuItem, Modal, WINDOW_REGISTRY, isPageEntry, useIsMobile, ModalActions, useModalActive, client_default, LoadingSpinner, setWindowPosition, ThumbCard, activateModal } from './chunk-4RXDOSKZ.js';
|
|
15
|
+
export { CancelButton, CopyButton, DocFavStar, Modal, ModalActions, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, WindowManagerProvider, WindowTitle, commitExposeHighlight, exitExposeMode, getActiveWindowRoute, getExposeHighlight, getWindowPosition, isEntityEntry, isPageEntry, setExposeHighlight, setShellApiClient, setShellWindowRegistry, setWindowDefaultPosition, setWindowPosition, subscribeExposeHighlight, toggleExposeMode, useModalActive, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle } from './chunk-4RXDOSKZ.js';
|
|
16
16
|
import { confirm } from './chunk-UBN4IUDE.js';
|
|
17
17
|
export { ConfirmProvider, confirm, confirmDestructive, prompt } from './chunk-UBN4IUDE.js';
|
|
18
18
|
import { useAuth, useShellAuth } from './chunk-ADJ3CERD.js';
|
|
19
19
|
export { ShellAuthProvider, setShellAuthBridge, useShellAuth } from './chunk-ADJ3CERD.js';
|
|
20
20
|
import { glassStyle, startMenuCategories, navSections, isSection, GLASS_INPUT_BG, navIcons, sectionIcons } from './chunk-ZF6AYO4G.js';
|
|
21
21
|
export { GLASS_DIVIDER, GLASS_INPUT_BG, glassStyle, setShellNavIcons } from './chunk-ZF6AYO4G.js';
|
|
22
|
-
import { createContext, lazy, useState, useRef, useEffect, useCallback, useMemo, useLayoutEffect, useContext, Suspense, isValidElement, cloneElement,
|
|
22
|
+
import { createContext, lazy, useState, useRef, useEffect, useCallback, useMemo, Fragment as Fragment$1, useLayoutEffect, useContext, Suspense, isValidElement, cloneElement, useSyncExternalStore } from 'react';
|
|
23
23
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
24
24
|
import { Dialog, DialogBackdrop, DialogPanel, DialogTitle } from '@headlessui/react';
|
|
25
25
|
import { createPortal } from 'react-dom';
|
|
@@ -641,6 +641,87 @@ function SidebarLayout({
|
|
|
641
641
|
contentPane
|
|
642
642
|
] }) });
|
|
643
643
|
}
|
|
644
|
+
function TopNav({ items, activeKey, onSelect, brand, actions, className }) {
|
|
645
|
+
return /* @__PURE__ */ jsxs(
|
|
646
|
+
"div",
|
|
647
|
+
{
|
|
648
|
+
className: `flex h-12 shrink-0 items-stretch gap-1 border-b border-gray-200 bg-white px-3 ${className ?? ""}`,
|
|
649
|
+
children: [
|
|
650
|
+
brand && /* @__PURE__ */ jsx("div", { className: "mr-1 flex items-center gap-2 pr-3 font-semibold text-gray-900", children: brand }),
|
|
651
|
+
/* @__PURE__ */ jsx("nav", { className: "flex items-stretch gap-0.5", children: items.map((item) => {
|
|
652
|
+
const active = item.key === activeKey;
|
|
653
|
+
return /* @__PURE__ */ jsxs(
|
|
654
|
+
"button",
|
|
655
|
+
{
|
|
656
|
+
type: "button",
|
|
657
|
+
disabled: item.disabled,
|
|
658
|
+
"aria-current": active ? "page" : void 0,
|
|
659
|
+
onClick: () => !item.disabled && onSelect?.(item.key),
|
|
660
|
+
className: `relative inline-flex items-center gap-1.5 px-3 text-sm font-medium transition-colors disabled:cursor-not-allowed disabled:opacity-40 ${active ? "text-blue-600" : "text-gray-600 hover:text-gray-900"}`,
|
|
661
|
+
children: [
|
|
662
|
+
item.icon && /* @__PURE__ */ jsx("span", { className: "h-4 w-4 shrink-0", children: item.icon }),
|
|
663
|
+
/* @__PURE__ */ jsx("span", { className: "whitespace-nowrap", children: item.label }),
|
|
664
|
+
item.badge != null && /* @__PURE__ */ jsx("span", { className: "ml-0.5 inline-flex min-w-[1.25rem] items-center justify-center rounded-full bg-gray-100 px-1.5 text-[11px] font-semibold leading-5 text-gray-600", children: item.badge }),
|
|
665
|
+
active && /* @__PURE__ */ jsx("span", { className: "absolute inset-x-2 -bottom-px h-0.5 rounded-full bg-blue-600", "aria-hidden": true })
|
|
666
|
+
]
|
|
667
|
+
},
|
|
668
|
+
item.key
|
|
669
|
+
);
|
|
670
|
+
}) }),
|
|
671
|
+
actions && /* @__PURE__ */ jsx("div", { className: "ml-auto flex items-center gap-2", children: actions })
|
|
672
|
+
]
|
|
673
|
+
}
|
|
674
|
+
);
|
|
675
|
+
}
|
|
676
|
+
var DEFAULT_SEPARATOR = /* @__PURE__ */ jsx("svg", { className: "h-3.5 w-3.5 shrink-0 text-gray-300", viewBox: "0 0 20 20", fill: "currentColor", "aria-hidden": true, children: /* @__PURE__ */ jsx(
|
|
677
|
+
"path",
|
|
678
|
+
{
|
|
679
|
+
fillRule: "evenodd",
|
|
680
|
+
d: "M7.21 14.77a.75.75 0 0 1 .02-1.06L11.168 10 7.23 6.29a.75.75 0 1 1 1.04-1.08l4.5 4.25a.75.75 0 0 1 0 1.08l-4.5 4.25a.75.75 0 0 1-1.06-.02Z",
|
|
681
|
+
clipRule: "evenodd"
|
|
682
|
+
}
|
|
683
|
+
) });
|
|
684
|
+
function Breadcrumbs({ items, separator, maxItems = 0, className }) {
|
|
685
|
+
if (items.length === 0) return null;
|
|
686
|
+
const sep = separator ?? DEFAULT_SEPARATOR;
|
|
687
|
+
const crumbs = [];
|
|
688
|
+
const lastIndex = items.length - 1;
|
|
689
|
+
if (maxItems > 0 && items.length > maxItems && maxItems >= 2) {
|
|
690
|
+
const tailCount = Math.max(1, maxItems - 1);
|
|
691
|
+
crumbs.push({ kind: "item", item: items[0], isLast: false });
|
|
692
|
+
crumbs.push({ kind: "ellipsis" });
|
|
693
|
+
for (let i = items.length - tailCount; i <= lastIndex; i++) {
|
|
694
|
+
crumbs.push({ kind: "item", item: items[i], isLast: i === lastIndex });
|
|
695
|
+
}
|
|
696
|
+
} else {
|
|
697
|
+
items.forEach((item, i) => crumbs.push({ kind: "item", item, isLast: i === lastIndex }));
|
|
698
|
+
}
|
|
699
|
+
return /* @__PURE__ */ jsx("nav", { "aria-label": "Breadcrumb", className: `min-w-0 ${className ?? ""}`, children: /* @__PURE__ */ jsx("ol", { className: "flex items-center gap-1.5 text-sm", children: crumbs.map((crumb, i) => /* @__PURE__ */ jsxs(Fragment$1, { children: [
|
|
700
|
+
i > 0 && /* @__PURE__ */ jsx("li", { "aria-hidden": true, className: "flex items-center", children: sep }),
|
|
701
|
+
/* @__PURE__ */ jsx("li", { className: "flex min-w-0 items-center", children: crumb.kind === "ellipsis" ? /* @__PURE__ */ jsx("span", { className: "px-0.5 text-gray-400 select-none", "aria-label": "Hidden crumbs", children: "\u2026" }) : crumb.isLast || !crumb.item.onClick ? /* @__PURE__ */ jsxs(
|
|
702
|
+
"span",
|
|
703
|
+
{
|
|
704
|
+
"aria-current": crumb.isLast ? "page" : void 0,
|
|
705
|
+
className: `inline-flex min-w-0 items-center gap-1 truncate ${crumb.isLast ? "font-medium text-gray-900" : "text-gray-500"}`,
|
|
706
|
+
children: [
|
|
707
|
+
crumb.item.icon,
|
|
708
|
+
/* @__PURE__ */ jsx("span", { className: "truncate", children: crumb.item.label })
|
|
709
|
+
]
|
|
710
|
+
}
|
|
711
|
+
) : /* @__PURE__ */ jsxs(
|
|
712
|
+
"button",
|
|
713
|
+
{
|
|
714
|
+
type: "button",
|
|
715
|
+
onClick: crumb.item.onClick,
|
|
716
|
+
className: "inline-flex min-w-0 items-center gap-1 truncate rounded px-1 -mx-1 text-gray-500 transition-colors hover:text-gray-900 hover:underline focus:outline-none focus-visible:ring-2 focus-visible:ring-blue-400",
|
|
717
|
+
children: [
|
|
718
|
+
crumb.item.icon,
|
|
719
|
+
/* @__PURE__ */ jsx("span", { className: "truncate", children: crumb.item.label })
|
|
720
|
+
]
|
|
721
|
+
}
|
|
722
|
+
) })
|
|
723
|
+
] }, i)) }) });
|
|
724
|
+
}
|
|
644
725
|
function timeAgo(dateStr) {
|
|
645
726
|
const diff = Date.now() - new Date(dateStr).getTime();
|
|
646
727
|
const mins = Math.floor(diff / 6e4);
|
|
@@ -1481,7 +1562,7 @@ function WidgetManager({ open, onClose }) {
|
|
|
1481
1562
|
}
|
|
1482
1563
|
|
|
1483
1564
|
// src/version.ts
|
|
1484
|
-
var VERSION = "0.
|
|
1565
|
+
var VERSION = "0.14.0" ;
|
|
1485
1566
|
var APP_VERSION = VERSION;
|
|
1486
1567
|
|
|
1487
1568
|
// src/changelog.ts
|
|
@@ -5070,8 +5151,9 @@ function previewColor(resolved, light, dark, pink, green, grey, blue) {
|
|
|
5070
5151
|
if (resolved === "blue") return blue ?? light;
|
|
5071
5152
|
return light;
|
|
5072
5153
|
}
|
|
5073
|
-
function Customization({ omit } = {}) {
|
|
5154
|
+
function Customization({ omit, section } = {}) {
|
|
5074
5155
|
const omitSet = new Set(omit ?? []);
|
|
5156
|
+
const inSection = (group) => section === void 0 || section === group;
|
|
5075
5157
|
const host = useDesktopHost();
|
|
5076
5158
|
const WALLPAPERS = host.wallpapers && host.wallpapers.length > 0 ? host.wallpapers : DEFAULT_WALLPAPERS;
|
|
5077
5159
|
const { prefs, save } = useShellPrefs();
|
|
@@ -5123,292 +5205,296 @@ function Customization({ omit } = {}) {
|
|
|
5123
5205
|
const headerBg = previewColor(resolved, "bg-gray-100", "bg-[#313244]", "bg-pink-50", "bg-green-50", "bg-gray-300", "bg-blue-100");
|
|
5124
5206
|
const accentBg = previewColor(resolved, "bg-blue-600", "bg-blue-500", "bg-pink-600", "bg-green-600", "bg-gray-700", "bg-blue-700");
|
|
5125
5207
|
return /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
|
|
5126
|
-
|
|
5127
|
-
|
|
5128
|
-
|
|
5129
|
-
/* @__PURE__ */
|
|
5130
|
-
|
|
5131
|
-
|
|
5132
|
-
/* @__PURE__ */ jsx("div", { className: "absolute left-4 top-4 flex gap-4", children: [
|
|
5133
|
-
{ icon: "\u{1F4CB}", label: "Orders" },
|
|
5134
|
-
{ icon: "\u{1F4E6}", label: "Products" },
|
|
5135
|
-
{ icon: "\u{1F4CA}", label: "Reports" }
|
|
5136
|
-
].map((d) => /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-0.5 w-8", children: [
|
|
5137
|
-
/* @__PURE__ */ jsx("div", { className: "text-sm drop-shadow", children: d.icon }),
|
|
5138
|
-
/* @__PURE__ */ jsx("span", { className: "text-[5px] text-white font-medium drop-shadow-[0_1px_1px_rgba(0,0,0,0.8)] leading-tight", children: d.label })
|
|
5139
|
-
] }, d.label)) }),
|
|
5140
|
-
/* @__PURE__ */ jsxs("div", { className: `absolute rounded shadow-md ${winBg}`, style: { left: "35%", top: "20%", width: "55%", height: "55%" }, children: [
|
|
5141
|
-
/* @__PURE__ */ jsxs("div", { className: `h-3 rounded-t ${headerBg} flex items-center px-1.5 gap-0.5`, style: { opacity: prevActiveHeaderOpacity }, children: [
|
|
5142
|
-
/* @__PURE__ */ jsx("div", { className: "w-1 h-1 rounded-full bg-red-400" }),
|
|
5143
|
-
/* @__PURE__ */ jsx("div", { className: "w-1 h-1 rounded-full bg-yellow-400" }),
|
|
5144
|
-
/* @__PURE__ */ jsx("div", { className: "w-1 h-1 rounded-full bg-green-400" })
|
|
5208
|
+
inSection("appearance") && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
5209
|
+
/* @__PURE__ */ jsx("div", { className: "flex justify-center", children: /* @__PURE__ */ jsx("div", { className: "rounded-lg border border-gray-200 overflow-hidden", style: { width: 480 }, children: /* @__PURE__ */ jsxs("div", { className: "relative", style: { height: 300 }, children: [
|
|
5210
|
+
isColor ? /* @__PURE__ */ jsx("div", { className: "absolute inset-0", style: { backgroundColor: desktopBg } }) : /* @__PURE__ */ jsx("img", { src: desktopBg, alt: "", className: "absolute inset-0 w-full h-full object-cover" }),
|
|
5211
|
+
/* @__PURE__ */ jsxs("div", { className: `absolute left-0 right-0 bottom-0 h-4 ${taskbarBg} border-t border-gray-200/50 flex items-center px-2 gap-1`, style: { opacity: prevTaskbarOpacity }, children: [
|
|
5212
|
+
/* @__PURE__ */ jsx("div", { className: `h-2 w-8 rounded-sm ${accentBg}` }),
|
|
5213
|
+
/* @__PURE__ */ jsx("div", { className: `h-2 w-6 rounded-sm ${iconBg}` })
|
|
5145
5214
|
] }),
|
|
5146
|
-
/* @__PURE__ */
|
|
5147
|
-
|
|
5148
|
-
|
|
5215
|
+
/* @__PURE__ */ jsx("div", { className: "absolute left-4 top-4 flex gap-4", children: [
|
|
5216
|
+
{ icon: "\u{1F4CB}", label: "Orders" },
|
|
5217
|
+
{ icon: "\u{1F4E6}", label: "Products" },
|
|
5218
|
+
{ icon: "\u{1F4CA}", label: "Reports" }
|
|
5219
|
+
].map((d) => /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-0.5 w-8", children: [
|
|
5220
|
+
/* @__PURE__ */ jsx("div", { className: "text-sm drop-shadow", children: d.icon }),
|
|
5221
|
+
/* @__PURE__ */ jsx("span", { className: "text-[5px] text-white font-medium drop-shadow-[0_1px_1px_rgba(0,0,0,0.8)] leading-tight", children: d.label })
|
|
5222
|
+
] }, d.label)) }),
|
|
5223
|
+
/* @__PURE__ */ jsxs("div", { className: `absolute rounded shadow-md ${winBg}`, style: { left: "35%", top: "20%", width: "55%", height: "55%" }, children: [
|
|
5224
|
+
/* @__PURE__ */ jsxs("div", { className: `h-3 rounded-t ${headerBg} flex items-center px-1.5 gap-0.5`, style: { opacity: prevActiveHeaderOpacity }, children: [
|
|
5225
|
+
/* @__PURE__ */ jsx("div", { className: "w-1 h-1 rounded-full bg-red-400" }),
|
|
5226
|
+
/* @__PURE__ */ jsx("div", { className: "w-1 h-1 rounded-full bg-yellow-400" }),
|
|
5227
|
+
/* @__PURE__ */ jsx("div", { className: "w-1 h-1 rounded-full bg-green-400" })
|
|
5228
|
+
] }),
|
|
5229
|
+
/* @__PURE__ */ jsxs("div", { className: "p-1.5 space-y-1", style: { opacity: prevActiveContentOpacity }, children: [
|
|
5230
|
+
/* @__PURE__ */ jsx("div", { className: `h-1 rounded w-3/4 ${iconBg}` }),
|
|
5231
|
+
/* @__PURE__ */ jsx("div", { className: `h-1 rounded w-1/2 ${iconBg}` })
|
|
5232
|
+
] })
|
|
5149
5233
|
] })
|
|
5150
|
-
] })
|
|
5151
|
-
|
|
5152
|
-
|
|
5153
|
-
|
|
5154
|
-
|
|
5155
|
-
|
|
5156
|
-
|
|
5157
|
-
|
|
5158
|
-
|
|
5159
|
-
|
|
5160
|
-
|
|
5161
|
-
|
|
5162
|
-
|
|
5163
|
-
|
|
5164
|
-
|
|
5165
|
-
|
|
5166
|
-
|
|
5167
|
-
|
|
5168
|
-
|
|
5169
|
-
|
|
5170
|
-
}
|
|
5171
|
-
|
|
5172
|
-
|
|
5173
|
-
|
|
5174
|
-
|
|
5175
|
-
|
|
5176
|
-
|
|
5177
|
-
|
|
5178
|
-
|
|
5179
|
-
|
|
5180
|
-
|
|
5181
|
-
|
|
5234
|
+
] }) }) }),
|
|
5235
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
5236
|
+
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Theme" }),
|
|
5237
|
+
/* @__PURE__ */ jsx("div", { className: "flex gap-3 flex-wrap", children: [...THEMES, { key: "custom", label: "Custom", bar1: "bg-gray-200", bar2: "bg-gray-200" }].map((t) => {
|
|
5238
|
+
const isCustom2 = t.key === "custom";
|
|
5239
|
+
const r = isCustom2 ? "light" : resolveTheme(t.key);
|
|
5240
|
+
const customColor = prefs.accent_color || "#8b5cf6";
|
|
5241
|
+
const tAccent = isCustom2 ? "" : previewColor(r, "bg-[#2563eb]", "bg-[#3b82f6]", "bg-[#db2777]", "bg-[#16a34a]", "bg-[#374151]", "bg-[#1d4ed8]");
|
|
5242
|
+
const tBg = isCustom2 ? "bg-[#ffffff] border-[#d1d5db]" : previewColor(r, "bg-[#ffffff] border-[#d1d5db]", "bg-[#1e1e2e] border-[#45475a]", "bg-[#fdf2f8] border-[#f9a8d4]", "bg-[#f0fdf4] border-[#86efac]", "bg-[#e5e7eb] border-[#9ca3af]", "bg-[#eff6ff] border-[#93c5fd]");
|
|
5243
|
+
return /* @__PURE__ */ jsxs(
|
|
5244
|
+
"button",
|
|
5245
|
+
{
|
|
5246
|
+
onClick: () => {
|
|
5247
|
+
if (isCustom2) {
|
|
5248
|
+
savePref("theme", "light");
|
|
5249
|
+
if (!prefs.accent_color) savePref("accent_color", "#8b5cf6");
|
|
5250
|
+
} else {
|
|
5251
|
+
savePref("theme", t.key);
|
|
5252
|
+
savePref("accent_color", null);
|
|
5253
|
+
}
|
|
5254
|
+
},
|
|
5255
|
+
className: `flex flex-col items-center gap-1.5 rounded-lg border-2 p-3 transition-all ${(isCustom2 ? !!prefs.accent_color : currentTheme === t.key && !prefs.accent_color) ? "border-blue-500 shadow-md" : "border-gray-200 hover:border-gray-300"}`,
|
|
5256
|
+
children: [
|
|
5257
|
+
/* @__PURE__ */ jsx("div", { className: `w-20 h-14 rounded ${tBg} border overflow-hidden flex flex-col`, children: t.key === "system" ? /* @__PURE__ */ jsxs("div", { className: "flex-1 flex", children: [
|
|
5258
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col bg-[#ffffff]", children: [
|
|
5259
|
+
/* @__PURE__ */ jsx("div", { className: "h-2 bg-[#2563eb] w-full" }),
|
|
5260
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex gap-0.5 p-0.5", children: [
|
|
5261
|
+
/* @__PURE__ */ jsx("div", { className: "w-3 rounded-sm bg-[#f3f4f6]" }),
|
|
5262
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col gap-0.5", children: [
|
|
5263
|
+
/* @__PURE__ */ jsx("div", { className: "h-1 rounded-sm w-3/4 bg-[#e5e7eb]" }),
|
|
5264
|
+
/* @__PURE__ */ jsx("div", { className: "h-1 rounded-sm w-1/2 bg-[#e5e7eb]" })
|
|
5265
|
+
] })
|
|
5266
|
+
] })
|
|
5267
|
+
] }),
|
|
5268
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col bg-[#1e1e2e]", children: [
|
|
5269
|
+
/* @__PURE__ */ jsx("div", { className: "h-2 bg-[#3b82f6] w-full" }),
|
|
5270
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex gap-0.5 p-0.5", children: [
|
|
5271
|
+
/* @__PURE__ */ jsx("div", { className: "w-3 rounded-sm bg-[#313244]" }),
|
|
5272
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col gap-0.5", children: [
|
|
5273
|
+
/* @__PURE__ */ jsx("div", { className: "h-1 rounded-sm w-3/4 bg-[#45475a]" }),
|
|
5274
|
+
/* @__PURE__ */ jsx("div", { className: "h-1 rounded-sm w-1/2 bg-[#45475a]" })
|
|
5275
|
+
] })
|
|
5182
5276
|
] })
|
|
5183
5277
|
] })
|
|
5184
|
-
] }),
|
|
5185
|
-
|
|
5186
|
-
/* @__PURE__ */
|
|
5187
|
-
|
|
5188
|
-
/* @__PURE__ */ jsx("div", { className: "w-3 rounded-sm bg-[#313244]" }),
|
|
5278
|
+
] }) : isCustom2 ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
5279
|
+
/* @__PURE__ */ jsx("div", { className: "h-2 w-full", style: { backgroundColor: customColor } }),
|
|
5280
|
+
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex gap-0.5 p-1", children: [
|
|
5281
|
+
/* @__PURE__ */ jsx("div", { className: "w-4 rounded-sm bg-[#f3f4f6]" }),
|
|
5189
5282
|
/* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col gap-0.5", children: [
|
|
5190
|
-
/* @__PURE__ */ jsx("div", { className: "h-1 rounded-sm w-3/4 bg-[#
|
|
5191
|
-
/* @__PURE__ */ jsx("div", { className: "h-1 rounded-sm w-1/2 bg-[#
|
|
5283
|
+
/* @__PURE__ */ jsx("div", { className: "h-1.5 rounded-sm w-3/4 bg-[#e5e7eb]" }),
|
|
5284
|
+
/* @__PURE__ */ jsx("div", { className: "h-1.5 rounded-sm w-1/2 bg-[#e5e7eb]" })
|
|
5192
5285
|
] })
|
|
5193
5286
|
] })
|
|
5194
|
-
] })
|
|
5195
|
-
|
|
5196
|
-
|
|
5197
|
-
|
|
5198
|
-
|
|
5199
|
-
|
|
5200
|
-
|
|
5201
|
-
|
|
5202
|
-
|
|
5203
|
-
|
|
5204
|
-
|
|
5205
|
-
|
|
5206
|
-
|
|
5207
|
-
|
|
5208
|
-
|
|
5209
|
-
|
|
5210
|
-
|
|
5211
|
-
|
|
5212
|
-
|
|
5213
|
-
|
|
5214
|
-
|
|
5215
|
-
);
|
|
5216
|
-
}) }),
|
|
5217
|
-
prefs.accent_color && /* @__PURE__ */ jsx("div", { className: "mt-3 space-y-2", children: [
|
|
5218
|
-
{ key: "custom_bg_color", label: "Background Color", defaultVal: "#f3f4f6" },
|
|
5219
|
-
{ key: "custom_title_color", label: "Title Color", defaultVal: "#f9fafb" },
|
|
5220
|
-
{ key: "custom_window_color", label: "Windows Background", defaultVal: "#ffffff" },
|
|
5221
|
-
{ key: "custom_button_color", label: "Button Color", defaultVal: "#2563eb" },
|
|
5222
|
-
{ key: "accent_color", label: "Accent Color", defaultVal: "#8b5cf6" }
|
|
5223
|
-
].map((item) => /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5224
|
-
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-40 shrink-0", children: item.label }),
|
|
5225
|
-
/* @__PURE__ */ jsx(
|
|
5226
|
-
"label",
|
|
5227
|
-
{
|
|
5228
|
-
className: "w-8 h-8 rounded-lg border-2 border-gray-300 overflow-hidden cursor-pointer flex items-center justify-center shrink-0",
|
|
5229
|
-
style: { backgroundColor: prefs[item.key] || item.defaultVal },
|
|
5230
|
-
children: /* @__PURE__ */ jsx(
|
|
5231
|
-
"input",
|
|
5232
|
-
{
|
|
5233
|
-
type: "color",
|
|
5234
|
-
value: prefs[item.key] || item.defaultVal,
|
|
5235
|
-
onChange: (e) => savePref(item.key, e.target.value),
|
|
5236
|
-
className: "opacity-0 absolute w-0 h-0"
|
|
5237
|
-
}
|
|
5238
|
-
)
|
|
5239
|
-
}
|
|
5240
|
-
),
|
|
5241
|
-
/* @__PURE__ */ jsx("span", { className: "text-xs text-gray-500 font-mono", children: prefs[item.key] || item.defaultVal })
|
|
5242
|
-
] }, item.key)) })
|
|
5243
|
-
] }),
|
|
5244
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
5245
|
-
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Desktop Wallpaper" }),
|
|
5246
|
-
/* @__PURE__ */ jsxs("div", { className: "flex gap-2 flex-wrap items-center", children: [
|
|
5247
|
-
/* @__PURE__ */ jsx(
|
|
5248
|
-
"button",
|
|
5249
|
-
{
|
|
5250
|
-
onClick: () => savePref("desktop_bg", "none"),
|
|
5251
|
-
className: `w-28 h-20 rounded border-2 overflow-hidden flex items-center justify-center ${rawBg === "none" ? "border-blue-500" : "border-gray-300"}`,
|
|
5252
|
-
style: { backgroundColor: previewColor(resolved, "#f3f4f6", "#1e1e2e", "#fdf2f8", "#f0fdf4", "#d1d5db", "#eff6ff") },
|
|
5253
|
-
children: /* @__PURE__ */ jsx("span", { className: "text-[9px] text-gray-500", children: "None" })
|
|
5254
|
-
}
|
|
5255
|
-
),
|
|
5256
|
-
/* @__PURE__ */ jsx(
|
|
5257
|
-
"button",
|
|
5258
|
-
{
|
|
5259
|
-
onClick: () => savePref("desktop_bg", "random"),
|
|
5260
|
-
className: `w-28 h-20 rounded border-2 overflow-hidden flex items-center justify-center ${rawBg === "random" ? "border-blue-500" : "border-gray-300"}`,
|
|
5261
|
-
children: /* @__PURE__ */ jsx("div", { className: "grid grid-cols-2 grid-rows-2 w-full h-full", children: WALLPAPERS.slice(0, 4).map((wp) => /* @__PURE__ */ jsx("img", { src: wp.src, alt: "", loading: "lazy", className: "w-full h-full object-cover" }, wp.src)) })
|
|
5262
|
-
}
|
|
5263
|
-
),
|
|
5264
|
-
WALLPAPERS.map((wp) => /* @__PURE__ */ jsx(
|
|
5265
|
-
"button",
|
|
5266
|
-
{
|
|
5267
|
-
onClick: () => savePref("desktop_bg", wp.src),
|
|
5268
|
-
className: `w-28 h-20 rounded border-2 overflow-hidden ${rawBg === wp.src ? "border-blue-500" : "border-gray-300"}`,
|
|
5269
|
-
children: /* @__PURE__ */ jsx("img", { src: wp.src, alt: wp.label, loading: "lazy", className: "w-full h-full object-cover" })
|
|
5270
|
-
},
|
|
5271
|
-
wp.src
|
|
5272
|
-
)),
|
|
5273
|
-
(customBg || isCustom) && /* @__PURE__ */ jsxs("div", { className: "relative group", children: [
|
|
5287
|
+
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
5288
|
+
/* @__PURE__ */ jsx("div", { className: `h-2 ${tAccent} w-full` }),
|
|
5289
|
+
/* @__PURE__ */ jsx("div", { className: "flex-1 flex gap-0.5 p-1", children: /* @__PURE__ */ jsxs("div", { className: "flex-1 flex flex-col gap-0.5", children: [
|
|
5290
|
+
/* @__PURE__ */ jsx("div", { className: `h-1.5 rounded-sm w-3/4 ${t.bar1}` }),
|
|
5291
|
+
/* @__PURE__ */ jsx("div", { className: `h-1.5 rounded-sm w-1/2 ${t.bar2}` })
|
|
5292
|
+
] }) })
|
|
5293
|
+
] }) }),
|
|
5294
|
+
/* @__PURE__ */ jsx("span", { className: `text-xs font-medium ${(isCustom2 ? !!prefs.accent_color : currentTheme === t.key && !prefs.accent_color) ? "text-blue-600" : "text-gray-600"}`, children: t.label })
|
|
5295
|
+
]
|
|
5296
|
+
},
|
|
5297
|
+
t.key
|
|
5298
|
+
);
|
|
5299
|
+
}) }),
|
|
5300
|
+
prefs.accent_color && /* @__PURE__ */ jsx("div", { className: "mt-3 space-y-2", children: [
|
|
5301
|
+
{ key: "custom_bg_color", label: "Background Color", defaultVal: "#f3f4f6" },
|
|
5302
|
+
{ key: "custom_title_color", label: "Title Color", defaultVal: "#f9fafb" },
|
|
5303
|
+
{ key: "custom_window_color", label: "Windows Background", defaultVal: "#ffffff" },
|
|
5304
|
+
{ key: "custom_button_color", label: "Button Color", defaultVal: "#2563eb" },
|
|
5305
|
+
{ key: "accent_color", label: "Accent Color", defaultVal: "#8b5cf6" }
|
|
5306
|
+
].map((item) => /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5307
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-40 shrink-0", children: item.label }),
|
|
5274
5308
|
/* @__PURE__ */ jsx(
|
|
5275
|
-
"
|
|
5309
|
+
"label",
|
|
5276
5310
|
{
|
|
5277
|
-
|
|
5278
|
-
|
|
5279
|
-
children: /* @__PURE__ */ jsx(
|
|
5311
|
+
className: "w-8 h-8 rounded-lg border-2 border-gray-300 overflow-hidden cursor-pointer flex items-center justify-center shrink-0",
|
|
5312
|
+
style: { backgroundColor: prefs[item.key] || item.defaultVal },
|
|
5313
|
+
children: /* @__PURE__ */ jsx(
|
|
5314
|
+
"input",
|
|
5315
|
+
{
|
|
5316
|
+
type: "color",
|
|
5317
|
+
value: prefs[item.key] || item.defaultVal,
|
|
5318
|
+
onChange: (e) => savePref(item.key, e.target.value),
|
|
5319
|
+
className: "opacity-0 absolute w-0 h-0"
|
|
5320
|
+
}
|
|
5321
|
+
)
|
|
5280
5322
|
}
|
|
5281
5323
|
),
|
|
5324
|
+
/* @__PURE__ */ jsx("span", { className: "text-xs text-gray-500 font-mono", children: prefs[item.key] || item.defaultVal })
|
|
5325
|
+
] }, item.key)) })
|
|
5326
|
+
] }),
|
|
5327
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
5328
|
+
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Desktop Wallpaper" }),
|
|
5329
|
+
/* @__PURE__ */ jsxs("div", { className: "flex gap-2 flex-wrap items-center", children: [
|
|
5282
5330
|
/* @__PURE__ */ jsx(
|
|
5283
5331
|
"button",
|
|
5284
5332
|
{
|
|
5285
|
-
onClick: () =>
|
|
5286
|
-
className:
|
|
5287
|
-
|
|
5333
|
+
onClick: () => savePref("desktop_bg", "none"),
|
|
5334
|
+
className: `w-28 h-20 rounded border-2 overflow-hidden flex items-center justify-center ${rawBg === "none" ? "border-blue-500" : "border-gray-300"}`,
|
|
5335
|
+
style: { backgroundColor: previewColor(resolved, "#f3f4f6", "#1e1e2e", "#fdf2f8", "#f0fdf4", "#d1d5db", "#eff6ff") },
|
|
5336
|
+
children: /* @__PURE__ */ jsx("span", { className: "text-[9px] text-gray-500", children: "None" })
|
|
5288
5337
|
}
|
|
5289
|
-
)
|
|
5290
|
-
] }),
|
|
5291
|
-
/* @__PURE__ */ jsxs("label", { className: "w-28 h-20 rounded border-2 border-gray-300 border-dashed overflow-hidden cursor-pointer flex items-center justify-center text-gray-400 hover:text-gray-600", children: [
|
|
5292
|
-
/* @__PURE__ */ jsx("svg", { className: "h-5 w-5", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", strokeWidth: 1.5, children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M12 4.5v15m7.5-7.5h-15" }) }),
|
|
5293
|
-
/* @__PURE__ */ jsx("input", { type: "file", accept: "image/*", className: "hidden", onChange: (e) => {
|
|
5294
|
-
const file = e.target.files?.[0];
|
|
5295
|
-
if (!file) return;
|
|
5296
|
-
const reader = new FileReader();
|
|
5297
|
-
reader.onloadend = () => {
|
|
5298
|
-
if (reader.result) {
|
|
5299
|
-
save({ desktop_bg: reader.result, desktop_bg_custom: reader.result });
|
|
5300
|
-
}
|
|
5301
|
-
};
|
|
5302
|
-
reader.readAsDataURL(file);
|
|
5303
|
-
} })
|
|
5304
|
-
] })
|
|
5305
|
-
] })
|
|
5306
|
-
] }),
|
|
5307
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
5308
|
-
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Transparency" }),
|
|
5309
|
-
/* @__PURE__ */ jsx("div", { className: "space-y-3", children: [
|
|
5310
|
-
{ key: "transparency_taskbar", label: "Taskbar", defaultVal: 70 },
|
|
5311
|
-
{ key: "transparency_start_menu", label: "Start Menu", defaultVal: 70 },
|
|
5312
|
-
{ key: "transparency_inactive_header", label: "Inactive Windows Header / Footer", defaultVal: 70 },
|
|
5313
|
-
{ key: "transparency_inactive_content", label: "Inactive Windows Content", defaultVal: 80 },
|
|
5314
|
-
{ key: "transparency_active_header", label: "Active Windows Header / Footer", defaultVal: 80 },
|
|
5315
|
-
{ key: "transparency_active_content", label: "Active Windows Content", defaultVal: 90 }
|
|
5316
|
-
].map((item) => {
|
|
5317
|
-
const val = localSliders[item.key] ?? prefs[item.key] ?? item.defaultVal;
|
|
5318
|
-
return /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5319
|
-
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-64 shrink-0", children: item.label }),
|
|
5338
|
+
),
|
|
5320
5339
|
/* @__PURE__ */ jsx(
|
|
5321
|
-
"
|
|
5340
|
+
"button",
|
|
5322
5341
|
{
|
|
5323
|
-
|
|
5324
|
-
|
|
5325
|
-
|
|
5326
|
-
value: val,
|
|
5327
|
-
onChange: (e) => saveSlider(item.key, Number(e.target.value)),
|
|
5328
|
-
className: "flex-1 h-1.5 accent-blue-600 cursor-pointer"
|
|
5342
|
+
onClick: () => savePref("desktop_bg", "random"),
|
|
5343
|
+
className: `w-28 h-20 rounded border-2 overflow-hidden flex items-center justify-center ${rawBg === "random" ? "border-blue-500" : "border-gray-300"}`,
|
|
5344
|
+
children: /* @__PURE__ */ jsx("div", { className: "grid grid-cols-2 grid-rows-2 w-full h-full", children: WALLPAPERS.slice(0, 4).map((wp) => /* @__PURE__ */ jsx("img", { src: wp.src, alt: "", loading: "lazy", className: "w-full h-full object-cover" }, wp.src)) })
|
|
5329
5345
|
}
|
|
5330
5346
|
),
|
|
5331
|
-
/* @__PURE__ */
|
|
5332
|
-
|
|
5333
|
-
|
|
5347
|
+
WALLPAPERS.map((wp) => /* @__PURE__ */ jsx(
|
|
5348
|
+
"button",
|
|
5349
|
+
{
|
|
5350
|
+
onClick: () => savePref("desktop_bg", wp.src),
|
|
5351
|
+
className: `w-28 h-20 rounded border-2 overflow-hidden ${rawBg === wp.src ? "border-blue-500" : "border-gray-300"}`,
|
|
5352
|
+
children: /* @__PURE__ */ jsx("img", { src: wp.src, alt: wp.label, loading: "lazy", className: "w-full h-full object-cover" })
|
|
5353
|
+
},
|
|
5354
|
+
wp.src
|
|
5355
|
+
)),
|
|
5356
|
+
(customBg || isCustom) && /* @__PURE__ */ jsxs("div", { className: "relative group", children: [
|
|
5357
|
+
/* @__PURE__ */ jsx(
|
|
5358
|
+
"button",
|
|
5359
|
+
{
|
|
5360
|
+
onClick: () => savePref("desktop_bg", customBg || desktopBg),
|
|
5361
|
+
className: `w-28 h-20 rounded border-2 overflow-hidden ${isCustom ? "border-blue-500" : "border-gray-300"}`,
|
|
5362
|
+
children: /* @__PURE__ */ jsx("img", { src: customBg || desktopBg, alt: "Custom", loading: "lazy", className: "w-full h-full object-cover" })
|
|
5363
|
+
}
|
|
5364
|
+
),
|
|
5365
|
+
/* @__PURE__ */ jsx(
|
|
5366
|
+
"button",
|
|
5367
|
+
{
|
|
5368
|
+
onClick: () => save({ desktop_bg: "random", desktop_bg_custom: "" }),
|
|
5369
|
+
className: "absolute -top-1.5 -right-1.5 h-4 w-4 rounded-full bg-red-500 text-white flex items-center justify-center text-[10px] leading-none opacity-0 group-hover:opacity-100 transition-opacity hover:bg-red-600 shadow",
|
|
5370
|
+
children: "\xD7"
|
|
5371
|
+
}
|
|
5372
|
+
)
|
|
5373
|
+
] }),
|
|
5374
|
+
/* @__PURE__ */ jsxs("label", { className: "w-28 h-20 rounded border-2 border-gray-300 border-dashed overflow-hidden cursor-pointer flex items-center justify-center text-gray-400 hover:text-gray-600", children: [
|
|
5375
|
+
/* @__PURE__ */ jsx("svg", { className: "h-5 w-5", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", strokeWidth: 1.5, children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M12 4.5v15m7.5-7.5h-15" }) }),
|
|
5376
|
+
/* @__PURE__ */ jsx("input", { type: "file", accept: "image/*", className: "hidden", onChange: (e) => {
|
|
5377
|
+
const file = e.target.files?.[0];
|
|
5378
|
+
if (!file) return;
|
|
5379
|
+
const reader = new FileReader();
|
|
5380
|
+
reader.onloadend = () => {
|
|
5381
|
+
if (reader.result) {
|
|
5382
|
+
save({ desktop_bg: reader.result, desktop_bg_custom: reader.result });
|
|
5383
|
+
}
|
|
5384
|
+
};
|
|
5385
|
+
reader.readAsDataURL(file);
|
|
5386
|
+
} })
|
|
5334
5387
|
] })
|
|
5335
|
-
] }
|
|
5336
|
-
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5343
|
-
|
|
5344
|
-
|
|
5345
|
-
|
|
5346
|
-
{
|
|
5347
|
-
|
|
5348
|
-
|
|
5349
|
-
|
|
5350
|
-
|
|
5351
|
-
|
|
5352
|
-
|
|
5353
|
-
|
|
5354
|
-
|
|
5355
|
-
|
|
5388
|
+
] })
|
|
5389
|
+
] }),
|
|
5390
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
5391
|
+
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Transparency" }),
|
|
5392
|
+
/* @__PURE__ */ jsx("div", { className: "space-y-3", children: [
|
|
5393
|
+
{ key: "transparency_taskbar", label: "Taskbar", defaultVal: 70 },
|
|
5394
|
+
{ key: "transparency_start_menu", label: "Start Menu", defaultVal: 70 },
|
|
5395
|
+
{ key: "transparency_inactive_header", label: "Inactive Windows Header / Footer", defaultVal: 70 },
|
|
5396
|
+
{ key: "transparency_inactive_content", label: "Inactive Windows Content", defaultVal: 80 },
|
|
5397
|
+
{ key: "transparency_active_header", label: "Active Windows Header / Footer", defaultVal: 80 },
|
|
5398
|
+
{ key: "transparency_active_content", label: "Active Windows Content", defaultVal: 90 }
|
|
5399
|
+
].map((item) => {
|
|
5400
|
+
const val = localSliders[item.key] ?? prefs[item.key] ?? item.defaultVal;
|
|
5401
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5402
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-64 shrink-0", children: item.label }),
|
|
5403
|
+
/* @__PURE__ */ jsx(
|
|
5404
|
+
"input",
|
|
5405
|
+
{
|
|
5406
|
+
type: "range",
|
|
5407
|
+
min: 20,
|
|
5408
|
+
max: 100,
|
|
5409
|
+
value: val,
|
|
5410
|
+
onChange: (e) => saveSlider(item.key, Number(e.target.value)),
|
|
5411
|
+
className: "flex-1 h-1.5 accent-blue-600 cursor-pointer"
|
|
5412
|
+
}
|
|
5413
|
+
),
|
|
5414
|
+
/* @__PURE__ */ jsxs("span", { className: "text-xs text-gray-500 w-10 text-right font-mono", children: [
|
|
5415
|
+
val,
|
|
5416
|
+
"%"
|
|
5417
|
+
] })
|
|
5418
|
+
] }, item.key);
|
|
5419
|
+
}) })
|
|
5420
|
+
] })
|
|
5356
5421
|
] }),
|
|
5357
|
-
/* @__PURE__ */ jsxs(
|
|
5358
|
-
/* @__PURE__ */
|
|
5359
|
-
|
|
5360
|
-
/* @__PURE__ */ jsx("
|
|
5361
|
-
/* @__PURE__ */ jsx("div", { className: "flex gap-2", children: [
|
|
5422
|
+
inSection("layout") && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
5423
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
5424
|
+
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Layout Mode" }),
|
|
5425
|
+
/* @__PURE__ */ jsx("p", { className: "text-xs text-gray-500 mb-3", children: "Sidebar mode is designed for small screens \u2014 windows always run maximized and the start menu lives in a persistent left sidebar (sections expand inline instead of opening flyouts)." }),
|
|
5426
|
+
/* @__PURE__ */ jsx("div", { className: "flex gap-2", children: [
|
|
5427
|
+
{ key: "classic", label: "Classic" },
|
|
5428
|
+
{ key: "sidebar", label: "Sidebar" }
|
|
5429
|
+
].map((m) => /* @__PURE__ */ jsx(
|
|
5362
5430
|
"button",
|
|
5363
5431
|
{
|
|
5364
|
-
onClick: () =>
|
|
5365
|
-
|
|
5366
|
-
|
|
5367
|
-
|
|
5368
|
-
|
|
5432
|
+
onClick: () => {
|
|
5433
|
+
savePref("layout_mode", m.key);
|
|
5434
|
+
if (m.key === "sidebar") savePref("default_window_size", "maximized");
|
|
5435
|
+
},
|
|
5436
|
+
className: `px-3 py-1.5 text-xs font-medium rounded-lg border transition-colors ${(prefs.layout_mode || "classic") === m.key ? "bg-blue-600 text-white border-blue-600" : "bg-white text-gray-700 border-gray-300 hover:bg-gray-50"}`,
|
|
5437
|
+
children: m.label
|
|
5369
5438
|
},
|
|
5370
|
-
|
|
5439
|
+
m.key
|
|
5371
5440
|
)) })
|
|
5372
|
-
] })
|
|
5373
|
-
|
|
5374
|
-
|
|
5375
|
-
|
|
5376
|
-
|
|
5377
|
-
|
|
5378
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5379
|
-
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-24 shrink-0", children: "Size" }),
|
|
5380
|
-
/* @__PURE__ */ jsx("div", { className: "flex gap-2", children: [
|
|
5381
|
-
{ key: "small", label: "Small" },
|
|
5382
|
-
{ key: "medium", label: "Medium" },
|
|
5383
|
-
{ key: "large", label: "Large" }
|
|
5384
|
-
].map((s) => /* @__PURE__ */ jsx(
|
|
5385
|
-
"button",
|
|
5386
|
-
{
|
|
5387
|
-
onClick: () => savePref("start_menu_size", s.key),
|
|
5388
|
-
className: `px-3 py-1.5 text-xs font-medium rounded-lg border transition-colors ${(prefs.start_menu_size || "medium") === s.key ? "bg-blue-600 text-white border-blue-600" : "bg-white text-gray-700 border-gray-300 hover:bg-gray-50"}`,
|
|
5389
|
-
children: s.label
|
|
5390
|
-
},
|
|
5391
|
-
s.key
|
|
5392
|
-
)) })
|
|
5393
|
-
] }),
|
|
5394
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5395
|
-
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-24 shrink-0", children: "Density" }),
|
|
5396
|
-
/* @__PURE__ */ jsx("div", { className: "flex gap-2", children: [
|
|
5397
|
-
{ key: "tight", label: "Tight" },
|
|
5398
|
-
{ key: "normal", label: "Normal" }
|
|
5399
|
-
].map((s) => /* @__PURE__ */ jsx(
|
|
5441
|
+
] }),
|
|
5442
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
5443
|
+
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Taskbar" }),
|
|
5444
|
+
/* @__PURE__ */ jsx("div", { className: "space-y-3", children: /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5445
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-24 shrink-0", children: "Position" }),
|
|
5446
|
+
/* @__PURE__ */ jsx("div", { className: "flex gap-2", children: ["bottom", "top", "left", "right"].map((pos) => /* @__PURE__ */ jsx(
|
|
5400
5447
|
"button",
|
|
5401
5448
|
{
|
|
5402
|
-
onClick: () => savePref("
|
|
5403
|
-
|
|
5404
|
-
|
|
5449
|
+
onClick: () => savePref("taskbar_position", pos),
|
|
5450
|
+
disabled: prefs.layout_mode === "sidebar",
|
|
5451
|
+
title: prefs.layout_mode === "sidebar" ? "Sidebar mode forces a horizontal taskbar." : void 0,
|
|
5452
|
+
className: `px-3 py-1.5 text-xs font-medium rounded-lg border transition-colors disabled:opacity-40 disabled:cursor-not-allowed ${(prefs.taskbar_position || "bottom") === pos ? "bg-blue-600 text-white border-blue-600" : "bg-white text-gray-700 border-gray-300 hover:bg-gray-50"}`,
|
|
5453
|
+
children: pos.charAt(0).toUpperCase() + pos.slice(1)
|
|
5405
5454
|
},
|
|
5406
|
-
|
|
5455
|
+
pos
|
|
5407
5456
|
)) })
|
|
5457
|
+
] }) })
|
|
5458
|
+
] }),
|
|
5459
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
5460
|
+
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Menu" }),
|
|
5461
|
+
/* @__PURE__ */ jsx("p", { className: "text-xs text-gray-500 mb-3", children: "Controls font size, padding, taskbar height, and window button height across the Start Menu, context menus, dropdowns, and the notification popup." }),
|
|
5462
|
+
/* @__PURE__ */ jsxs("div", { className: "space-y-3", children: [
|
|
5463
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5464
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-24 shrink-0", children: "Size" }),
|
|
5465
|
+
/* @__PURE__ */ jsx("div", { className: "flex gap-2", children: [
|
|
5466
|
+
{ key: "small", label: "Small" },
|
|
5467
|
+
{ key: "medium", label: "Medium" },
|
|
5468
|
+
{ key: "large", label: "Large" }
|
|
5469
|
+
].map((s) => /* @__PURE__ */ jsx(
|
|
5470
|
+
"button",
|
|
5471
|
+
{
|
|
5472
|
+
onClick: () => savePref("start_menu_size", s.key),
|
|
5473
|
+
className: `px-3 py-1.5 text-xs font-medium rounded-lg border transition-colors ${(prefs.start_menu_size || "medium") === s.key ? "bg-blue-600 text-white border-blue-600" : "bg-white text-gray-700 border-gray-300 hover:bg-gray-50"}`,
|
|
5474
|
+
children: s.label
|
|
5475
|
+
},
|
|
5476
|
+
s.key
|
|
5477
|
+
)) })
|
|
5478
|
+
] }),
|
|
5479
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
5480
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm text-gray-700 w-24 shrink-0", children: "Density" }),
|
|
5481
|
+
/* @__PURE__ */ jsx("div", { className: "flex gap-2", children: [
|
|
5482
|
+
{ key: "tight", label: "Tight" },
|
|
5483
|
+
{ key: "normal", label: "Normal" }
|
|
5484
|
+
].map((s) => /* @__PURE__ */ jsx(
|
|
5485
|
+
"button",
|
|
5486
|
+
{
|
|
5487
|
+
onClick: () => savePref("menu_density", s.key),
|
|
5488
|
+
className: `px-3 py-1.5 text-xs font-medium rounded-lg border transition-colors ${(prefs.menu_density || "normal") === s.key ? "bg-blue-600 text-white border-blue-600" : "bg-white text-gray-700 border-gray-300 hover:bg-gray-50"}`,
|
|
5489
|
+
children: s.label
|
|
5490
|
+
},
|
|
5491
|
+
s.key
|
|
5492
|
+
)) })
|
|
5493
|
+
] })
|
|
5408
5494
|
] })
|
|
5409
5495
|
] })
|
|
5410
5496
|
] }),
|
|
5411
|
-
!omitSet.has("behavior") && /* @__PURE__ */ jsxs("div", { children: [
|
|
5497
|
+
inSection("behavior") && !omitSet.has("behavior") && /* @__PURE__ */ jsxs("div", { children: [
|
|
5412
5498
|
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Behavior" }),
|
|
5413
5499
|
/* @__PURE__ */ jsxs("div", { className: "space-y-3", children: [
|
|
5414
5500
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
|
|
@@ -5460,7 +5546,7 @@ function Customization({ omit } = {}) {
|
|
|
5460
5546
|
] })
|
|
5461
5547
|
] })
|
|
5462
5548
|
] }),
|
|
5463
|
-
!omitSet.has("desktop") && /* @__PURE__ */ jsxs("div", { children: [
|
|
5549
|
+
inSection("behavior") && !omitSet.has("desktop") && /* @__PURE__ */ jsxs("div", { children: [
|
|
5464
5550
|
/* @__PURE__ */ jsx("h3", { className: "text-sm font-semibold text-gray-900 mb-3", children: "Desktop" }),
|
|
5465
5551
|
/* @__PURE__ */ jsxs("label", { className: "flex items-center gap-2 cursor-pointer", children: [
|
|
5466
5552
|
/* @__PURE__ */ jsx(
|
|
@@ -6493,8 +6579,10 @@ function Kanban({
|
|
|
6493
6579
|
},
|
|
6494
6580
|
onDragEnter: (e) => {
|
|
6495
6581
|
e.stopPropagation();
|
|
6582
|
+
const draggedPos = dragId !== null ? colItems.findIndex((it) => getId(it) === dragId) : -1;
|
|
6583
|
+
const target = draggedPos !== -1 && draggedPos < index ? index + 1 : index;
|
|
6496
6584
|
setOver(
|
|
6497
|
-
(prev) => prev && prev.col === col.value && prev.index ===
|
|
6585
|
+
(prev) => prev && prev.col === col.value && prev.index === target ? prev : { col: col.value, index: target }
|
|
6498
6586
|
);
|
|
6499
6587
|
},
|
|
6500
6588
|
onDragEnd: reset,
|
|
@@ -6639,6 +6727,6 @@ function useEditHotkey(callback) {
|
|
|
6639
6727
|
}, [callback, isActive]);
|
|
6640
6728
|
}
|
|
6641
6729
|
|
|
6642
|
-
export { ALT, ALT_SHIFT_D, ALT_SHIFT_E, ALT_SHIFT_N, BehaviorPanel, BugReportConfigProvider, BugReportDetail, BugReportProvider, CMD_A, CMD_DOT, CMD_ENTER, CMD_K, CMD_S, Customization, DEV_BANNER_TEXT, Desktop, DesktopHostProvider, DevIndicator, ENTER, EntityList, GlobalSearch, HelpCenter, Kanban, Layout, ListFooter, MOD, Markdown, NotificationBell, ResizableTable, SHIFT, ShellEntityFetcherProvider, ShortcutHelp, SidebarLayout, SoundsPanel, StartMenu, StatusBadge, StatusBadgeProvider, SystemPreferences, VERSION, WidgetManager, applyDevTitle, createWindowRegistry, isDevEnv, isMac, openBugReportDialog, reportBug, useBugReport, useClickOutside, useColumnConfig, useDesktopHost, useEditHotkey, useInfiniteScroll, useNewHotkey, useShellEntityFetcher, useSort, useTableNav };
|
|
6730
|
+
export { ALT, ALT_SHIFT_D, ALT_SHIFT_E, ALT_SHIFT_N, BehaviorPanel, Breadcrumbs, BugReportConfigProvider, BugReportDetail, BugReportProvider, CMD_A, CMD_DOT, CMD_ENTER, CMD_K, CMD_S, Customization, DEV_BANNER_TEXT, Desktop, DesktopHostProvider, DevIndicator, ENTER, EntityList, GlobalSearch, HelpCenter, Kanban, Layout, ListFooter, MOD, Markdown, NotificationBell, ResizableTable, SHIFT, ShellEntityFetcherProvider, ShortcutHelp, SidebarLayout, SoundsPanel, StartMenu, StatusBadge, StatusBadgeProvider, SystemPreferences, TopNav, VERSION, WidgetManager, applyDevTitle, createWindowRegistry, isDevEnv, isMac, openBugReportDialog, reportBug, useBugReport, useClickOutside, useColumnConfig, useDesktopHost, useEditHotkey, useInfiniteScroll, useNewHotkey, useShellEntityFetcher, useSort, useTableNav };
|
|
6643
6731
|
//# sourceMappingURL=index.js.map
|
|
6644
6732
|
//# sourceMappingURL=index.js.map
|