@vezham/react 26.0.0-alpha.8 → 26.0.0-beta.1
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/lib/components/command/index.js +2 -2
- package/dist/lib/components/menu/index.js +2 -2
- package/dist/lib/components/panel/footer/ai/message-actions.js +2 -2
- package/dist/lib/components/panel/footer/ai/mock-result.js +2 -2
- package/dist/lib/components/panel/footer/control-center/appearance.d.ts +2 -1
- package/dist/lib/components/panel/footer/control-center/appearance.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/control-center/appearance.js +4 -3
- package/dist/lib/components/panel/footer/control-center/control-center.js +11 -8
- package/dist/lib/components/panel/footer/control-center/direction.d.ts +2 -1
- package/dist/lib/components/panel/footer/control-center/direction.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/control-center/direction.js +6 -4
- package/dist/lib/components/panel/footer/control-center/editor.d.ts +3 -1
- package/dist/lib/components/panel/footer/control-center/editor.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/control-center/editor.js +24 -6
- package/dist/lib/components/panel/footer/control-center/preview.d.ts +4 -2
- package/dist/lib/components/panel/footer/control-center/preview.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/control-center/preview.js +4 -2
- package/dist/lib/components/panel/footer/control-center/tile.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/control-center/tile.js +12 -7
- package/dist/lib/components/panel/footer/control-center/variant.d.ts +27 -0
- package/dist/lib/components/panel/footer/control-center/variant.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/control-center/variant.js +30 -9
- package/dist/lib/components/panel/footer/index.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/index.js +17 -11
- package/dist/lib/components/panel/footer/notification-center/index.js +2 -2
- package/dist/lib/components/panel/footer/notification-center/widget-tiles.d.ts +88 -3
- package/dist/lib/components/panel/footer/notification-center/widget-tiles.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/notification-center/widget-tiles.js +63 -25
- package/dist/lib/components/panel/footer/user-menu.d.ts +8 -1
- package/dist/lib/components/panel/footer/user-menu.d.ts.map +1 -1
- package/dist/lib/components/panel/footer/user-menu.js +252 -142
- package/dist/lib/components/panel/header/application-menu-sheet.js +5 -5
- package/dist/lib/components/panel/header/bookmarks/bookmark-file-tree/index.js +1 -1
- package/dist/lib/components/panel/header/bookmarks/bookmark-file-tree/variants.js +1 -1
- package/dist/lib/components/panel/header/bookmarks/favorites/grid-list.js +2 -2
- package/dist/lib/components/panel/header/bookmarks/index.js +2 -1
- package/dist/lib/components/panel/header/bookmarks/shortcut-context-menu.js +2 -1
- package/dist/lib/components/panel/header/bookmarks/tree-data.js +2 -1
- package/dist/lib/components/panel/header/index.js +5 -5
- package/dist/lib/components/panel/header/storage/types.d.ts +1 -1
- package/dist/lib/components/panel/info-panel/container.module.js +4 -2
- package/dist/lib/components/panel/menu/index.js +2 -2
- package/dist/lib/components/panel/menu/types.d.ts +1 -1
- package/dist/lib/layouts/menu-layout/index-md.js +3 -3
- package/dist/lib/layouts/menu-layout/index-sm.js +2 -2
- package/dist/lib/layouts/section/index.d.ts.map +1 -1
- package/dist/lib/layouts/section/index.js +7 -7
- package/dist/lib/layouts/section/sidebar.js +2 -2
- package/dist/lib/layouts/section/toolbar-more-sheet.js +3 -3
- package/dist/lib/layouts/section/toolbar.js +4 -4
- package/dist/lib/pages/settings/index.d.ts.map +1 -1
- package/dist/lib/pages/settings/index.js +72 -27
- package/dist/lib/pages/settings/navigation.d.ts +1 -1
- package/dist/lib/pages/settings/navigation.d.ts.map +1 -1
- package/dist/lib/pages/settings/settings-content.js +1 -1
- package/dist/lib/pages/settings/tile-gallery.d.ts +6 -1
- package/dist/lib/pages/settings/tile-gallery.d.ts.map +1 -1
- package/dist/lib/pages/settings/tile-gallery.js +175 -100
- package/dist/lib/store/useBookmarks/index.js +2 -2
- package/dist/lib/store/useStorage/index.js +1 -1
- package/package.json +2 -2
|
@@ -5,7 +5,7 @@ import { DefaultControlCenter } from "./control-center/default.js";
|
|
|
5
5
|
import { UserMenu } from "./user-menu.js";
|
|
6
6
|
import { useMemo, useState } from "react";
|
|
7
7
|
import { Badge, Button, Dropdown, Separator, Surface, Tooltip, useMediaQuery } from "@vezham/react-v3";
|
|
8
|
-
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
8
|
+
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
9
9
|
import { Bell, MenuDots, Settings, VezhamTamizhi } from "@vezham/icons-react";
|
|
10
10
|
//#region src/lib/components/panel/footer/index.tsx
|
|
11
11
|
var footerActionClassName = "text-muted hover:text-foreground h-5 w-5 min-w-0 p-0 [&_svg]:size-5";
|
|
@@ -29,7 +29,7 @@ var FooterAction = ({ children, label, onPress }) => {
|
|
|
29
29
|
})]
|
|
30
30
|
});
|
|
31
31
|
};
|
|
32
|
-
var CompactActions = ({ showAI, showControlCenter, onControlCenter, showNotifications, notificationCount, onAI, onNotificationsClick }) => {
|
|
32
|
+
var CompactActions = ({ showAI, showControlCenter, onControlCenter, showNotifications, notificationCount = 0, onAI, onNotificationsClick }) => {
|
|
33
33
|
if (!showAI && !showNotifications && !showControlCenter) return null;
|
|
34
34
|
return /* @__PURE__ */ jsxs(Dropdown, { children: [/* @__PURE__ */ jsx(Dropdown.Trigger, {
|
|
35
35
|
"aria-label": "Open footer actions",
|
|
@@ -59,7 +59,7 @@ var CompactActions = ({ showAI, showControlCenter, onControlCenter, showNotifica
|
|
|
59
59
|
className: "flex-1",
|
|
60
60
|
children: "Notifications"
|
|
61
61
|
}),
|
|
62
|
-
notificationCount
|
|
62
|
+
notificationCount > 0 ? /* @__PURE__ */ jsx(Badge, {
|
|
63
63
|
content: String(notificationCount),
|
|
64
64
|
color: "danger",
|
|
65
65
|
size: "sm"
|
|
@@ -85,7 +85,7 @@ var Footer = ({ user, showAI = false, showControlCenter = false, controlCenter,
|
|
|
85
85
|
isOpen: controlCenterOpen,
|
|
86
86
|
onOpenChange: setControlCenterOpen
|
|
87
87
|
}), [compact, controlCenterOpen]);
|
|
88
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(Separator, { className: "hidden md:block" }), /* @__PURE__ */ jsxs(Surface, {
|
|
88
|
+
return /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(Separator, { className: "hidden md:block" }), /* @__PURE__ */ jsxs(Surface, {
|
|
89
89
|
variant: "transparent",
|
|
90
90
|
className: `flex items-center justify-center gap-2 md:flex-col md:gap-3 ${className ?? ""}`,
|
|
91
91
|
children: [
|
|
@@ -117,7 +117,19 @@ var Footer = ({ user, showAI = false, showControlCenter = false, controlCenter,
|
|
|
117
117
|
value: controlCenterContext,
|
|
118
118
|
children: controlCenter ?? /* @__PURE__ */ jsx(DefaultControlCenter, { placement: "right bottom" })
|
|
119
119
|
}),
|
|
120
|
-
/* @__PURE__ */ jsx(
|
|
120
|
+
showUserInfo ? /* @__PURE__ */ jsx(UserMenu, {
|
|
121
|
+
user,
|
|
122
|
+
showAI,
|
|
123
|
+
showControlCenter,
|
|
124
|
+
showNotifications,
|
|
125
|
+
notificationCount,
|
|
126
|
+
onAI,
|
|
127
|
+
onControlCenter: () => setControlCenterOpen(true),
|
|
128
|
+
onNotifications: onNotificationsClick,
|
|
129
|
+
onProfile: () => onUserClick?.(user, "profiles"),
|
|
130
|
+
onPreferences: () => onUserClick?.(user, "account"),
|
|
131
|
+
onLogout: clearUser
|
|
132
|
+
}) : /* @__PURE__ */ jsx("div", {
|
|
121
133
|
className: "md:hidden",
|
|
122
134
|
children: /* @__PURE__ */ jsx(CompactActions, {
|
|
123
135
|
showControlCenter,
|
|
@@ -129,12 +141,6 @@ var Footer = ({ user, showAI = false, showControlCenter = false, controlCenter,
|
|
|
129
141
|
onNotificationsClick
|
|
130
142
|
})
|
|
131
143
|
}),
|
|
132
|
-
showUserInfo ? /* @__PURE__ */ jsx(UserMenu, {
|
|
133
|
-
user,
|
|
134
|
-
onProfile: () => onUserClick?.(user, "profiles"),
|
|
135
|
-
onPreferences: () => onUserClick?.(user, "account"),
|
|
136
|
-
onLogout: clearUser
|
|
137
|
-
}) : null,
|
|
138
144
|
toolbarAction && /* @__PURE__ */ jsx(Surface, {
|
|
139
145
|
variant: "transparent",
|
|
140
146
|
className: "md:hidden",
|
|
@@ -32,7 +32,7 @@ var NotificationDrawer = forwardRef((props, ref) => {
|
|
|
32
32
|
const handleEdit = () => {
|
|
33
33
|
if (openSettings) {
|
|
34
34
|
onClose();
|
|
35
|
-
openSettings("
|
|
35
|
+
openSettings("Widget Center");
|
|
36
36
|
} else if (onEdit) onEdit();
|
|
37
37
|
else {
|
|
38
38
|
onClose();
|
|
@@ -44,7 +44,7 @@ var NotificationDrawer = forwardRef((props, ref) => {
|
|
|
44
44
|
size: "sm",
|
|
45
45
|
...getEditButtonProps(),
|
|
46
46
|
onPress: handleEdit,
|
|
47
|
-
children: "
|
|
47
|
+
children: "Widget Center"
|
|
48
48
|
});
|
|
49
49
|
if (compact) return /* @__PURE__ */ jsx(InfoPanelSheet, {
|
|
50
50
|
isOpen,
|
|
@@ -1,12 +1,92 @@
|
|
|
1
|
-
|
|
1
|
+
export declare const widgetSizes: readonly ["small", "medium", "large"];
|
|
2
|
+
export type WidgetSize = (typeof widgetSizes)[number];
|
|
3
|
+
export declare const notificationCenterWidgetVariants: import('tailwind-variants').TVReturnType<{
|
|
4
|
+
size: {
|
|
5
|
+
small: {
|
|
6
|
+
gallerySuggestion: string;
|
|
7
|
+
preview: string;
|
|
8
|
+
};
|
|
9
|
+
medium: {
|
|
10
|
+
tile: string;
|
|
11
|
+
gallerySuggestion: string;
|
|
12
|
+
preview: string;
|
|
13
|
+
};
|
|
14
|
+
large: {
|
|
15
|
+
tile: string;
|
|
16
|
+
gallerySuggestion: string;
|
|
17
|
+
preview: string;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
}, {
|
|
21
|
+
container: string;
|
|
22
|
+
grid: string;
|
|
23
|
+
tile: string;
|
|
24
|
+
preview: string;
|
|
25
|
+
galleryPreview: string;
|
|
26
|
+
gallerySuggestion: string;
|
|
27
|
+
}, undefined, {
|
|
28
|
+
size: {
|
|
29
|
+
small: {
|
|
30
|
+
gallerySuggestion: string;
|
|
31
|
+
preview: string;
|
|
32
|
+
};
|
|
33
|
+
medium: {
|
|
34
|
+
tile: string;
|
|
35
|
+
gallerySuggestion: string;
|
|
36
|
+
preview: string;
|
|
37
|
+
};
|
|
38
|
+
large: {
|
|
39
|
+
tile: string;
|
|
40
|
+
gallerySuggestion: string;
|
|
41
|
+
preview: string;
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
}, {
|
|
45
|
+
container: string;
|
|
46
|
+
grid: string;
|
|
47
|
+
tile: string;
|
|
48
|
+
preview: string;
|
|
49
|
+
galleryPreview: string;
|
|
50
|
+
gallerySuggestion: string;
|
|
51
|
+
}, import('tailwind-variants').TVReturnTypeLike<{
|
|
52
|
+
size: {
|
|
53
|
+
small: {
|
|
54
|
+
gallerySuggestion: string;
|
|
55
|
+
preview: string;
|
|
56
|
+
};
|
|
57
|
+
medium: {
|
|
58
|
+
tile: string;
|
|
59
|
+
gallerySuggestion: string;
|
|
60
|
+
preview: string;
|
|
61
|
+
};
|
|
62
|
+
large: {
|
|
63
|
+
tile: string;
|
|
64
|
+
gallerySuggestion: string;
|
|
65
|
+
preview: string;
|
|
66
|
+
};
|
|
67
|
+
};
|
|
68
|
+
}, {
|
|
69
|
+
container: string;
|
|
70
|
+
grid: string;
|
|
71
|
+
tile: string;
|
|
72
|
+
preview: string;
|
|
73
|
+
galleryPreview: string;
|
|
74
|
+
gallerySuggestion: string;
|
|
75
|
+
}>>;
|
|
2
76
|
export type WidgetTileDefinition = {
|
|
3
77
|
id: string;
|
|
4
78
|
label: string;
|
|
79
|
+
description: string;
|
|
5
80
|
category: string;
|
|
6
81
|
size: WidgetSize;
|
|
7
82
|
};
|
|
83
|
+
export declare const getWidgetSize: (tile: WidgetTileDefinition & {
|
|
84
|
+
span?: string;
|
|
85
|
+
}) => WidgetSize;
|
|
8
86
|
export declare const WidgetPreview: ({ tile, className }: {
|
|
9
|
-
tile: WidgetTileDefinition
|
|
87
|
+
tile: WidgetTileDefinition & {
|
|
88
|
+
span?: string;
|
|
89
|
+
};
|
|
10
90
|
className?: string;
|
|
11
91
|
}) => import("react").JSX.Element;
|
|
12
92
|
export declare const useWidgetTiles: () => {
|
|
@@ -14,36 +94,41 @@ export declare const useWidgetTiles: () => {
|
|
|
14
94
|
orderedTiles: ({
|
|
15
95
|
id: string;
|
|
16
96
|
label: string;
|
|
97
|
+
description: string;
|
|
17
98
|
category: string;
|
|
18
99
|
size: "small";
|
|
19
100
|
} | {
|
|
20
101
|
id: string;
|
|
21
102
|
label: string;
|
|
103
|
+
description: string;
|
|
22
104
|
category: string;
|
|
23
105
|
size: "medium";
|
|
24
106
|
} | {
|
|
25
107
|
id: string;
|
|
26
108
|
label: string;
|
|
109
|
+
description: string;
|
|
27
110
|
category: string;
|
|
28
111
|
size: "large";
|
|
29
112
|
})[];
|
|
30
113
|
visibleTiles: ({
|
|
31
114
|
id: string;
|
|
32
115
|
label: string;
|
|
116
|
+
description: string;
|
|
33
117
|
category: string;
|
|
34
118
|
size: "small";
|
|
35
119
|
} | {
|
|
36
120
|
id: string;
|
|
37
121
|
label: string;
|
|
122
|
+
description: string;
|
|
38
123
|
category: string;
|
|
39
124
|
size: "medium";
|
|
40
125
|
} | {
|
|
41
126
|
id: string;
|
|
42
127
|
label: string;
|
|
128
|
+
description: string;
|
|
43
129
|
category: string;
|
|
44
130
|
size: "large";
|
|
45
131
|
})[];
|
|
46
132
|
};
|
|
47
133
|
export declare const WidgetTiles: () => import("react").JSX.Element;
|
|
48
|
-
export {};
|
|
49
134
|
//# sourceMappingURL=widget-tiles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"widget-tiles.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/components/panel/footer/notification-center/widget-tiles.tsx"],"names":[],"mappings":"AAYA,
|
|
1
|
+
{"version":3,"file":"widget-tiles.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/components/panel/footer/notification-center/widget-tiles.tsx"],"names":[],"mappings":"AAYA,eAAO,MAAM,WAAW,uCAAwC,CAAA;AAChE,MAAM,MAAM,UAAU,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,CAAC,CAAA;AAErD,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4B3C,CAAA;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,EAAE,MAAM,CAAA;IACb,WAAW,EAAE,MAAM,CAAA;IACnB,QAAQ,EAAE,MAAM,CAAA;IAChB,IAAI,EAAE,UAAU,CAAA;CACjB,CAAA;AAwDD,eAAO,MAAM,aAAa,GACxB,MAAM,oBAAoB,GAAG;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,KAC7C,UAGY,CAAA;AAwFf,eAAO,MAAM,aAAa,GAAI,qBAG3B;IACD,IAAI,EAAE,oBAAoB,GAAG;QAAE,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,CAAA;IAC9C,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,gCAWA,CAAA;AAED,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACqB,CAAA;AAEhD,eAAO,MAAM,WAAW,mCAWvB,CAAA"}
|
|
@@ -1,57 +1,92 @@
|
|
|
1
1
|
import { useTileEditor } from "../control-center/editor.js";
|
|
2
|
-
import { Surface } from "@vezham/react-v3";
|
|
2
|
+
import { Surface, tv } from "@vezham/react-v3";
|
|
3
3
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
4
4
|
import { CalendarDate, ClipboardList, ClockCircle, Moon, NotebookBookmark, Sun } from "@vezham/icons-react";
|
|
5
5
|
//#region src/lib/components/panel/footer/notification-center/widget-tiles.tsx
|
|
6
|
+
var widgetSizes = [
|
|
7
|
+
"small",
|
|
8
|
+
"medium",
|
|
9
|
+
"large"
|
|
10
|
+
];
|
|
11
|
+
var notificationCenterWidgetVariants = tv({
|
|
12
|
+
slots: {
|
|
13
|
+
container: "@container mx-auto w-full max-w-[252px]",
|
|
14
|
+
grid: "grid auto-rows-[calc((100cqw-1rem)/2)] grid-cols-2 gap-4 pb-4",
|
|
15
|
+
tile: "min-w-0",
|
|
16
|
+
preview: "aspect-square",
|
|
17
|
+
galleryPreview: "@container mx-auto min-h-0 w-full max-w-[260px] flex-1 overflow-y-auto p-1",
|
|
18
|
+
gallerySuggestion: "shrink-0"
|
|
19
|
+
},
|
|
20
|
+
variants: { size: {
|
|
21
|
+
small: {
|
|
22
|
+
gallerySuggestion: "w-[7.375rem]",
|
|
23
|
+
preview: "aspect-square"
|
|
24
|
+
},
|
|
25
|
+
medium: {
|
|
26
|
+
tile: "col-span-2",
|
|
27
|
+
gallerySuggestion: "w-[15.75rem] max-w-full",
|
|
28
|
+
preview: "aspect-[2/1]"
|
|
29
|
+
},
|
|
30
|
+
large: {
|
|
31
|
+
tile: "col-span-2 row-span-2",
|
|
32
|
+
gallerySuggestion: "w-[15.75rem] max-w-full",
|
|
33
|
+
preview: "aspect-square"
|
|
34
|
+
}
|
|
35
|
+
} }
|
|
36
|
+
});
|
|
6
37
|
var widgetDefinitions = [
|
|
7
38
|
{
|
|
8
39
|
id: "calendar-month",
|
|
9
40
|
label: "Calendar",
|
|
41
|
+
description: "See your upcoming events.",
|
|
10
42
|
category: "Calendar",
|
|
11
43
|
size: "small"
|
|
12
44
|
},
|
|
13
45
|
{
|
|
14
46
|
id: "world-clock",
|
|
15
47
|
label: "World Clock",
|
|
48
|
+
description: "Check the time in New Delhi.",
|
|
16
49
|
category: "Clock",
|
|
17
50
|
size: "small"
|
|
18
51
|
},
|
|
19
52
|
{
|
|
20
53
|
id: "weather-forecast",
|
|
21
54
|
label: "Weather",
|
|
55
|
+
description: "View the current forecast.",
|
|
22
56
|
category: "Weather",
|
|
23
57
|
size: "medium"
|
|
24
58
|
},
|
|
25
59
|
{
|
|
26
60
|
id: "reminders-list",
|
|
27
61
|
label: "Reminders",
|
|
62
|
+
description: "Keep track of today’s tasks.",
|
|
28
63
|
category: "Reminders",
|
|
29
64
|
size: "medium"
|
|
30
65
|
},
|
|
31
66
|
{
|
|
32
67
|
id: "notes-summary",
|
|
33
68
|
label: "Notes",
|
|
69
|
+
description: "View your latest notes.",
|
|
34
70
|
category: "Notes",
|
|
35
71
|
size: "medium"
|
|
36
72
|
},
|
|
37
73
|
{
|
|
38
74
|
id: "focus-status",
|
|
39
75
|
label: "Focus",
|
|
76
|
+
description: "See your current Focus status.",
|
|
40
77
|
category: "Focus",
|
|
41
78
|
size: "small"
|
|
42
79
|
},
|
|
43
80
|
{
|
|
44
81
|
id: "daily-summary",
|
|
45
82
|
label: "Daily Summary",
|
|
83
|
+
description: "Review your day at a glance.",
|
|
46
84
|
category: "Calendar",
|
|
47
85
|
size: "large"
|
|
48
86
|
}
|
|
49
87
|
];
|
|
50
|
-
var
|
|
51
|
-
|
|
52
|
-
medium: "aspect-[2/1]",
|
|
53
|
-
large: "aspect-square"
|
|
54
|
-
};
|
|
88
|
+
var widgetStyles = notificationCenterWidgetVariants();
|
|
89
|
+
var getWidgetSize = (tile) => widgetSizes.includes(tile.span) ? tile.span : tile.size;
|
|
55
90
|
var WidgetPreviewContent = ({ id }) => {
|
|
56
91
|
switch (id) {
|
|
57
92
|
case "calendar-month": return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
@@ -83,13 +118,13 @@ var WidgetPreviewContent = ({ id }) => {
|
|
|
83
118
|
})
|
|
84
119
|
] });
|
|
85
120
|
case "weather-forecast": return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs("div", {
|
|
86
|
-
className: "flex items-center justify-between",
|
|
121
|
+
className: "flex min-w-0 items-center justify-between gap-2",
|
|
87
122
|
children: [/* @__PURE__ */ jsx("span", {
|
|
88
|
-
className: "text-sm font-semibold",
|
|
123
|
+
className: "min-w-0 truncate text-sm font-semibold",
|
|
89
124
|
children: "New Delhi"
|
|
90
125
|
}), /* @__PURE__ */ jsx(Sun, {
|
|
91
126
|
"aria-hidden": "true",
|
|
92
|
-
className: "text-warning size-5"
|
|
127
|
+
className: "text-warning size-5 shrink-0"
|
|
93
128
|
})]
|
|
94
129
|
}), /* @__PURE__ */ jsxs("div", {
|
|
95
130
|
className: "mt-auto flex items-end justify-between",
|
|
@@ -102,12 +137,12 @@ var WidgetPreviewContent = ({ id }) => {
|
|
|
102
137
|
})]
|
|
103
138
|
})] });
|
|
104
139
|
case "reminders-list": return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs("div", {
|
|
105
|
-
className: "flex items-center gap-2",
|
|
140
|
+
className: "flex min-w-0 items-center gap-2",
|
|
106
141
|
children: [/* @__PURE__ */ jsx(ClipboardList, {
|
|
107
142
|
"aria-hidden": "true",
|
|
108
|
-
className: "text-accent size-5"
|
|
143
|
+
className: "text-accent size-5 shrink-0"
|
|
109
144
|
}), /* @__PURE__ */ jsx("span", {
|
|
110
|
-
className: "text-sm font-semibold",
|
|
145
|
+
className: "min-w-0 truncate text-sm font-semibold",
|
|
111
146
|
children: "Reminders"
|
|
112
147
|
})]
|
|
113
148
|
}), /* @__PURE__ */ jsx("span", {
|
|
@@ -115,12 +150,12 @@ var WidgetPreviewContent = ({ id }) => {
|
|
|
115
150
|
children: "No reminders today"
|
|
116
151
|
})] });
|
|
117
152
|
case "notes-summary": return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsxs("div", {
|
|
118
|
-
className: "flex items-center gap-2",
|
|
153
|
+
className: "flex min-w-0 items-center gap-2",
|
|
119
154
|
children: [/* @__PURE__ */ jsx(NotebookBookmark, {
|
|
120
155
|
"aria-hidden": "true",
|
|
121
|
-
className: "text-warning size-5"
|
|
156
|
+
className: "text-warning size-5 shrink-0"
|
|
122
157
|
}), /* @__PURE__ */ jsx("span", {
|
|
123
|
-
className: "text-sm font-semibold",
|
|
158
|
+
className: "min-w-0 truncate text-sm font-semibold",
|
|
124
159
|
children: "Notes"
|
|
125
160
|
})]
|
|
126
161
|
}), /* @__PURE__ */ jsx("span", {
|
|
@@ -157,20 +192,23 @@ var WidgetPreviewContent = ({ id }) => {
|
|
|
157
192
|
] });
|
|
158
193
|
}
|
|
159
194
|
};
|
|
160
|
-
var WidgetPreview = ({ tile, className = "" }) =>
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
})
|
|
195
|
+
var WidgetPreview = ({ tile, className = "" }) => {
|
|
196
|
+
const size = getWidgetSize(tile);
|
|
197
|
+
return /* @__PURE__ */ jsx(Surface, {
|
|
198
|
+
variant: "transparent",
|
|
199
|
+
"data-widget-size": size,
|
|
200
|
+
"aria-label": tile.label,
|
|
201
|
+
className: `bg-surface-secondary flex min-w-0 flex-col rounded-2xl p-3 shadow-sm ${widgetStyles.tile({ size })} ${widgetStyles.preview({ size })} ${className}`,
|
|
202
|
+
children: /* @__PURE__ */ jsx(WidgetPreviewContent, { id: tile.id })
|
|
203
|
+
});
|
|
204
|
+
};
|
|
167
205
|
var useWidgetTiles = () => useTileEditor(widgetDefinitions, "vx:widgets");
|
|
168
206
|
var WidgetTiles = () => {
|
|
169
207
|
const { visibleTiles } = useWidgetTiles();
|
|
170
208
|
return /* @__PURE__ */ jsx("div", {
|
|
171
|
-
className:
|
|
209
|
+
className: widgetStyles.container(),
|
|
172
210
|
children: /* @__PURE__ */ jsx("div", {
|
|
173
|
-
className:
|
|
211
|
+
className: widgetStyles.grid(),
|
|
174
212
|
children: visibleTiles.map((tile) => /* @__PURE__ */ jsx(WidgetPreview, {
|
|
175
213
|
tile,
|
|
176
214
|
className: "h-full"
|
|
@@ -179,4 +217,4 @@ var WidgetTiles = () => {
|
|
|
179
217
|
});
|
|
180
218
|
};
|
|
181
219
|
//#endregion
|
|
182
|
-
export { WidgetPreview, WidgetTiles, useWidgetTiles };
|
|
220
|
+
export { WidgetPreview, WidgetTiles, getWidgetSize, notificationCenterWidgetVariants, useWidgetTiles, widgetSizes };
|
|
@@ -4,7 +4,14 @@ type Props = {
|
|
|
4
4
|
onLogout: () => void;
|
|
5
5
|
onProfile?: () => void;
|
|
6
6
|
onPreferences?: () => void;
|
|
7
|
+
showAI?: boolean;
|
|
8
|
+
showControlCenter?: boolean;
|
|
9
|
+
showNotifications?: boolean;
|
|
10
|
+
notificationCount?: number;
|
|
11
|
+
onAI?: () => void;
|
|
12
|
+
onControlCenter?: () => void;
|
|
13
|
+
onNotifications?: () => void;
|
|
7
14
|
};
|
|
8
|
-
declare const UserMenu: ({ user, onLogout, onProfile, onPreferences }: Props) => import("react").JSX.Element;
|
|
15
|
+
declare const UserMenu: ({ user, onLogout, onProfile, onPreferences, showAI, showControlCenter, showNotifications, notificationCount, onAI, onControlCenter, onNotifications }: Props) => import("react").JSX.Element;
|
|
9
16
|
export { UserMenu };
|
|
10
17
|
//# sourceMappingURL=user-menu.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-menu.d.ts","sourceRoot":"","sources":["../../../../../src/lib/components/panel/footer/user-menu.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"user-menu.d.ts","sourceRoot":"","sources":["../../../../../src/lib/components/panel/footer/user-menu.tsx"],"names":[],"mappings":"AAiCA,OAAO,KAAK,EAGV,QAAQ,EAGT,MAAM,SAAS,CAAA;AAEhB,KAAK,KAAK,GAAG;IACX,IAAI,EAAE,QAAQ,CAAA;IACd,QAAQ,EAAE,MAAM,IAAI,CAAA;IACpB,SAAS,CAAC,EAAE,MAAM,IAAI,CAAA;IACtB,aAAa,CAAC,EAAE,MAAM,IAAI,CAAA;IAC1B,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,IAAI,CAAC,EAAE,MAAM,IAAI,CAAA;IACjB,eAAe,CAAC,EAAE,MAAM,IAAI,CAAA;IAC5B,eAAe,CAAC,EAAE,MAAM,IAAI,CAAA;CAC7B,CAAA;AA4XD,QAAA,MAAM,QAAQ,GAAI,uJAYf,KAAK,gCA6GP,CAAA;AAED,OAAO,EAAE,QAAQ,EAAE,CAAA"}
|