rimelight-components 2.1.37 → 2.1.39

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.
Files changed (152) hide show
  1. package/dist/module.d.mts +9 -0
  2. package/dist/module.d.ts +9 -0
  3. package/dist/module.json +1 -1
  4. package/dist/module.mjs +15 -1
  5. package/dist/runtime/auth/index.d.ts +3 -0
  6. package/dist/runtime/auth/index.js +3 -0
  7. package/dist/runtime/auth/index.mjs +3 -0
  8. package/dist/runtime/auth/permissions.d.ts +201 -0
  9. package/dist/runtime/auth/permissions.js +32 -0
  10. package/dist/runtime/auth/permissions.mjs +32 -0
  11. package/dist/runtime/auth/restricted-usernames.d.ts +25 -0
  12. package/dist/runtime/auth/restricted-usernames.js +236 -0
  13. package/dist/runtime/auth/restricted-usernames.mjs +236 -0
  14. package/dist/runtime/auth/utils.d.ts +10 -0
  15. package/dist/runtime/auth/utils.js +20 -0
  16. package/dist/runtime/auth/utils.mjs +20 -0
  17. package/dist/runtime/components/FloatingToolsOverlay.d.vue.ts +3 -0
  18. package/dist/runtime/components/FloatingToolsOverlay.vue +74 -0
  19. package/dist/runtime/components/FloatingToolsOverlay.vue.d.ts +3 -0
  20. package/dist/runtime/components/app/Footer.vue +1 -1
  21. package/dist/runtime/components/app/Header.vue +1 -1
  22. package/dist/runtime/components/app/Image.vue +1 -1
  23. package/dist/runtime/components/app/Logo.vue +1 -1
  24. package/dist/runtime/components/app/NewsletterSignup.vue +1 -1
  25. package/dist/runtime/components/app/ScrollToTop.vue +1 -1
  26. package/dist/runtime/components/cards/TeamCard.vue +1 -1
  27. package/dist/runtime/components/content/Callout.vue +1 -1
  28. package/dist/runtime/components/content/Section.vue +1 -1
  29. package/dist/runtime/components/dashboard/NotificationsSlideover.d.vue.ts +3 -0
  30. package/dist/runtime/components/dashboard/NotificationsSlideover.vue +49 -0
  31. package/dist/runtime/components/dashboard/NotificationsSlideover.vue.d.ts +3 -0
  32. package/dist/runtime/components/dashboard/QuickActions.d.vue.ts +3 -0
  33. package/dist/runtime/components/dashboard/QuickActions.vue +36 -0
  34. package/dist/runtime/components/dashboard/QuickActions.vue.d.ts +3 -0
  35. package/dist/runtime/components/dashboard/TeamsMenu.d.vue.ts +6 -0
  36. package/dist/runtime/components/dashboard/TeamsMenu.vue +77 -0
  37. package/dist/runtime/components/dashboard/TeamsMenu.vue.d.ts +6 -0
  38. package/dist/runtime/components/dashboard/customers/AddModal.d.vue.ts +3 -0
  39. package/dist/runtime/components/dashboard/customers/AddModal.vue +45 -0
  40. package/dist/runtime/components/dashboard/customers/AddModal.vue.d.ts +3 -0
  41. package/dist/runtime/components/dashboard/customers/DeleteModal.d.vue.ts +16 -0
  42. package/dist/runtime/components/dashboard/customers/DeleteModal.vue +28 -0
  43. package/dist/runtime/components/dashboard/customers/DeleteModal.vue.d.ts +16 -0
  44. package/dist/runtime/components/dashboard/floating-tools/FocusTimerTool.d.vue.ts +3 -0
  45. package/dist/runtime/components/dashboard/floating-tools/FocusTimerTool.vue +37 -0
  46. package/dist/runtime/components/dashboard/floating-tools/FocusTimerTool.vue.d.ts +3 -0
  47. package/dist/runtime/components/headings/H1.d.vue.ts +13 -0
  48. package/dist/runtime/components/headings/H1.vue +9 -0
  49. package/dist/runtime/components/headings/H1.vue.d.ts +13 -0
  50. package/dist/runtime/components/headings/H2.d.vue.ts +13 -0
  51. package/dist/runtime/components/headings/H2.vue +9 -0
  52. package/dist/runtime/components/headings/H2.vue.d.ts +13 -0
  53. package/dist/runtime/components/headings/H3.d.vue.ts +13 -0
  54. package/dist/runtime/components/headings/H3.vue +9 -0
  55. package/dist/runtime/components/headings/H3.vue.d.ts +13 -0
  56. package/dist/runtime/components/headings/H4.d.vue.ts +13 -0
  57. package/dist/runtime/components/headings/H4.vue +9 -0
  58. package/dist/runtime/components/headings/H4.vue.d.ts +13 -0
  59. package/dist/runtime/components/headings/H5.d.vue.ts +13 -0
  60. package/dist/runtime/components/headings/H5.vue +9 -0
  61. package/dist/runtime/components/headings/H5.vue.d.ts +13 -0
  62. package/dist/runtime/components/headings/H6.d.vue.ts +13 -0
  63. package/dist/runtime/components/headings/H6.vue +9 -0
  64. package/dist/runtime/components/headings/H6.vue.d.ts +13 -0
  65. package/dist/runtime/components/modals/ConfirmModal.d.vue.ts +3 -0
  66. package/dist/runtime/components/modals/ConfirmModal.vue +36 -0
  67. package/dist/runtime/components/modals/ConfirmModal.vue.d.ts +3 -0
  68. package/dist/runtime/components/nodes/LinkNode.vue +1 -1
  69. package/dist/runtime/components/nodes/TextNode.vue +1 -1
  70. package/dist/runtime/components/notes/NoteCard.d.vue.ts +31 -0
  71. package/dist/runtime/components/notes/NoteCard.vue +86 -0
  72. package/dist/runtime/components/notes/NoteCard.vue.d.ts +31 -0
  73. package/dist/runtime/components/notes/NoteModal.d.vue.ts +35 -0
  74. package/dist/runtime/components/notes/NoteModal.vue +224 -0
  75. package/dist/runtime/components/notes/NoteModal.vue.d.ts +35 -0
  76. package/dist/runtime/components/page/PageMention.vue +1 -1
  77. package/dist/runtime/components/page/PageSurround.vue +1 -1
  78. package/dist/runtime/components/page/PageTOC.vue +1 -1
  79. package/dist/runtime/components/swatches/ColorSwatch.vue +1 -1
  80. package/dist/runtime/components/swatches/FontSwatch.vue +1 -1
  81. package/dist/runtime/components/swatches/ImageSwatch.vue +1 -1
  82. package/dist/runtime/components/utilities/Placeholder.vue +1 -1
  83. package/dist/runtime/composables/app/index.d.ts +4 -0
  84. package/dist/runtime/composables/app/index.js +4 -0
  85. package/dist/runtime/composables/app/index.mjs +4 -0
  86. package/dist/runtime/composables/app/useApi.d.ts +9 -0
  87. package/dist/runtime/composables/app/useApi.js +56 -0
  88. package/dist/runtime/composables/app/useApi.mjs +56 -0
  89. package/dist/runtime/composables/app/useConfirm.d.ts +18 -0
  90. package/dist/runtime/composables/app/useConfirm.js +56 -0
  91. package/dist/runtime/composables/app/useConfirm.mjs +56 -0
  92. package/dist/runtime/composables/components/index.d.ts +1 -0
  93. package/dist/runtime/composables/components/index.js +1 -0
  94. package/dist/runtime/composables/components/index.mjs +1 -0
  95. package/dist/runtime/composables/dashboard/index.d.ts +5 -0
  96. package/dist/runtime/composables/dashboard/index.js +5 -0
  97. package/dist/runtime/composables/dashboard/index.mjs +5 -0
  98. package/dist/runtime/composables/dashboard/useDashboard.d.ts +3 -0
  99. package/dist/runtime/composables/dashboard/useDashboard.js +18 -0
  100. package/dist/runtime/composables/dashboard/useDashboard.mjs +18 -0
  101. package/dist/runtime/composables/dashboard/useFloatingTools.d.ts +19 -0
  102. package/dist/runtime/composables/dashboard/useFloatingTools.js +44 -0
  103. package/dist/runtime/composables/dashboard/useFloatingTools.mjs +44 -0
  104. package/dist/runtime/composables/dashboard/useFocusTimer.d.ts +44 -0
  105. package/dist/runtime/composables/dashboard/useFocusTimer.js +141 -0
  106. package/dist/runtime/composables/dashboard/useFocusTimer.mjs +141 -0
  107. package/dist/runtime/composables/dashboard/useNotes.d.ts +9 -0
  108. package/dist/runtime/composables/dashboard/useNotes.js +57 -0
  109. package/dist/runtime/composables/dashboard/useNotes.mjs +57 -0
  110. package/dist/runtime/composables/dashboard/useQuickActions.d.ts +15 -0
  111. package/dist/runtime/composables/dashboard/useQuickActions.js +19 -0
  112. package/dist/runtime/composables/dashboard/useQuickActions.mjs +19 -0
  113. package/dist/runtime/composables/index.d.ts +4 -7
  114. package/dist/runtime/composables/index.js +4 -7
  115. package/dist/runtime/composables/index.mjs +4 -7
  116. package/dist/runtime/composables/pages/index.d.ts +4 -0
  117. package/dist/runtime/composables/pages/index.js +4 -0
  118. package/dist/runtime/composables/pages/index.mjs +4 -0
  119. package/dist/runtime/composables/{useBlockEditor.d.ts → pages/useBlockEditor.d.ts} +131 -131
  120. package/dist/runtime/composables/{useInfobox.d.ts → pages/useInfobox.d.ts} +1 -1
  121. package/dist/runtime/composables/{usePageEditor.d.ts → pages/usePageEditor.d.ts} +1 -1
  122. package/dist/runtime/composables/{usePageRegistry.d.ts → pages/usePageRegistry.d.ts} +2 -2
  123. package/dist/runtime/db/auth.d.ts +2096 -0
  124. package/dist/runtime/db/auth.js +268 -0
  125. package/dist/runtime/db/auth.mjs +268 -0
  126. package/dist/runtime/db/index.d.ts +1 -0
  127. package/dist/runtime/db/index.js +1 -0
  128. package/dist/runtime/db/index.mjs +1 -0
  129. package/dist/runtime/types/index.d.ts +1 -0
  130. package/dist/runtime/types/index.js +1 -0
  131. package/dist/runtime/types/index.mjs +1 -0
  132. package/dist/runtime/types/utils.d.ts +51 -0
  133. package/dist/runtime/types/utils.js +0 -0
  134. package/dist/runtime/types/utils.mjs +0 -0
  135. package/package.json +4 -2
  136. /package/dist/runtime/composables/{useDateRange.d.ts → app/useDateRange.d.ts} +0 -0
  137. /package/dist/runtime/composables/{useDateRange.js → app/useDateRange.js} +0 -0
  138. /package/dist/runtime/composables/{useDateRange.mjs → app/useDateRange.mjs} +0 -0
  139. /package/dist/runtime/composables/{useHeaderStack.d.ts → app/useHeaderStack.d.ts} +0 -0
  140. /package/dist/runtime/composables/{useHeaderStack.js → app/useHeaderStack.js} +0 -0
  141. /package/dist/runtime/composables/{useHeaderStack.mjs → app/useHeaderStack.mjs} +0 -0
  142. /package/dist/runtime/composables/{useRC.d.ts → components/useRC.d.ts} +0 -0
  143. /package/dist/runtime/composables/{useRC.js → components/useRC.js} +0 -0
  144. /package/dist/runtime/composables/{useRC.mjs → components/useRC.mjs} +0 -0
  145. /package/dist/runtime/composables/{useBlockEditor.js → pages/useBlockEditor.js} +0 -0
  146. /package/dist/runtime/composables/{useBlockEditor.mjs → pages/useBlockEditor.mjs} +0 -0
  147. /package/dist/runtime/composables/{useInfobox.js → pages/useInfobox.js} +0 -0
  148. /package/dist/runtime/composables/{useInfobox.mjs → pages/useInfobox.mjs} +0 -0
  149. /package/dist/runtime/composables/{usePageEditor.js → pages/usePageEditor.js} +0 -0
  150. /package/dist/runtime/composables/{usePageEditor.mjs → pages/usePageEditor.mjs} +0 -0
  151. /package/dist/runtime/composables/{usePageRegistry.js → pages/usePageRegistry.js} +0 -0
  152. /package/dist/runtime/composables/{usePageRegistry.mjs → pages/usePageRegistry.mjs} +0 -0
@@ -0,0 +1,236 @@
1
+ const HOMOGLYPH_MAP = {
2
+ "0": "o",
3
+ "1": "i",
4
+ "3": "e",
5
+ "4": "a",
6
+ "5": "s",
7
+ "7": "t",
8
+ "8": "b",
9
+ "9": "g",
10
+ "@": "a",
11
+ "!": "i",
12
+ $: "s",
13
+ "|": "i"
14
+ };
15
+ const SKELETON_MAP = {
16
+ // Leetspeak & Numbers
17
+ "0": "o",
18
+ "1": "i",
19
+ "3": "e",
20
+ "4": "a",
21
+ "5": "s",
22
+ "6": "g",
23
+ "7": "t",
24
+ "8": "b",
25
+ "9": "g",
26
+ // Special Characters
27
+ "@": "a",
28
+ $: "s",
29
+ "!": "i",
30
+ "|": "i",
31
+ "+": "t",
32
+ "(": "c",
33
+ "[": "c",
34
+ "{": "c",
35
+ // Cyrillic Homoglyphs
36
+ \u0430: "a",
37
+ \u0435: "e",
38
+ \u0456: "i",
39
+ \u0458: "j",
40
+ \u043E: "o",
41
+ \u0440: "p",
42
+ \u0441: "c",
43
+ \u0443: "y",
44
+ \u0445: "x",
45
+ // Greek Homoglyphs
46
+ \u03B1: "a",
47
+ \u03B5: "e",
48
+ \u03B9: "i",
49
+ \u03BF: "o",
50
+ \u03C1: "p",
51
+ \u03C5: "y",
52
+ \u03C7: "x"
53
+ };
54
+ export const generateUsernameSkeleton = (input) => {
55
+ const normalized = input.normalize("NFKD");
56
+ return normalized.toLowerCase().split("").map((char) => {
57
+ if (char.match(/[\u0300-\u036f]/)) return "";
58
+ return SKELETON_MAP[char] || char;
59
+ }).join("").replace(/[^a-z0-9]/g, "");
60
+ };
61
+ export const normalizeUsername = (input) => {
62
+ return input.toLowerCase().split("").map((char) => HOMOGLYPH_MAP[char] || char).join("").replace(/[^a-z0-9]/g, "");
63
+ };
64
+ export const STANDARD_RESTRICTED_GROUPS = {
65
+ STAFF_ROLES: [
66
+ "admin",
67
+ "administrator",
68
+ "moderator",
69
+ "mod",
70
+ "staff",
71
+ "support",
72
+ "help",
73
+ "official",
74
+ "verified",
75
+ "system",
76
+ "root",
77
+ "bot",
78
+ "security",
79
+ "community",
80
+ "manager",
81
+ "dev",
82
+ "developer",
83
+ "designer",
84
+ "gamemaster",
85
+ "gm",
86
+ "assistant",
87
+ "coordinator",
88
+ "representative",
89
+ "agent",
90
+ "supervisor",
91
+ "executive",
92
+ "ambassador",
93
+ "expert",
94
+ "specialist",
95
+ "advocate",
96
+ "internal",
97
+ "employee",
98
+ "associate",
99
+ "webmaster",
100
+ "sysop",
101
+ "operator",
102
+ "host",
103
+ "referee",
104
+ "council",
105
+ "ceo",
106
+ "founder",
107
+ "owner"
108
+ ],
109
+ LEGAL_FINANCIAL: [
110
+ "checkout",
111
+ "subscribe",
112
+ "subscription",
113
+ "premium",
114
+ "vip",
115
+ "store",
116
+ "shop",
117
+ "marketplace",
118
+ "wallet",
119
+ "refund",
120
+ "invoice",
121
+ "payout",
122
+ "rewards",
123
+ "prize",
124
+ "giveaway",
125
+ "claims",
126
+ "verification",
127
+ "billing",
128
+ "payment",
129
+ "sales",
130
+ "marketing",
131
+ "legal",
132
+ "compliance",
133
+ "privacy",
134
+ "tos",
135
+ "terms",
136
+ "copyright",
137
+ "trademark",
138
+ "dmca",
139
+ "abuse",
140
+ "report"
141
+ ],
142
+ TECHNICAL: [
143
+ "null",
144
+ "undefined",
145
+ "nan",
146
+ "none",
147
+ "everyone",
148
+ "all",
149
+ "guest",
150
+ "user",
151
+ "test",
152
+ "tester",
153
+ "account",
154
+ "api",
155
+ "webhook",
156
+ "index",
157
+ "config",
158
+ "settings",
159
+ "profile",
160
+ "auth",
161
+ "login",
162
+ "signup",
163
+ "signin",
164
+ "logout",
165
+ "signout",
166
+ "localhost",
167
+ "ftp",
168
+ "smtp",
169
+ "pop3",
170
+ "imap",
171
+ "dns",
172
+ "proxy",
173
+ "cdn",
174
+ "static",
175
+ "assets",
176
+ "media",
177
+ "upload",
178
+ "download",
179
+ "docs",
180
+ "manual",
181
+ "guide",
182
+ "tutorial",
183
+ "error",
184
+ "404",
185
+ "500",
186
+ "maintenance",
187
+ "update",
188
+ "patch",
189
+ "changelog",
190
+ "status",
191
+ "db",
192
+ "database",
193
+ "sql",
194
+ "query",
195
+ "health",
196
+ "ping",
197
+ "metrics",
198
+ "logs",
199
+ "no-reply",
200
+ "noreply",
201
+ "donotreply",
202
+ "security-alert",
203
+ "mail",
204
+ "email",
205
+ "postmaster"
206
+ ],
207
+ LEETSPEAK: [
208
+ "4dmin",
209
+ "@dmin",
210
+ "st4ff",
211
+ "m0d",
212
+ "m0derator",
213
+ "4dm1n",
214
+ "4dmin1strator",
215
+ "m0d3rator",
216
+ "st4f",
217
+ "5upport",
218
+ "0fficial",
219
+ "v3rified",
220
+ "5ystem",
221
+ "r00t",
222
+ "b0t",
223
+ "s3curity",
224
+ "d3v",
225
+ "d3veloper",
226
+ "@dministrator",
227
+ "adm1n",
228
+ "adm1nistrator"
229
+ ]
230
+ };
231
+ export const STANDARD_RESTRICTED_USERNAMES = Object.values(STANDARD_RESTRICTED_GROUPS).flat().map((name) => normalizeUsername(name));
232
+ export const createRestrictedSet = (appSpecificUsernames = []) => {
233
+ const normalizedAppSpecific = appSpecificUsernames.map((name) => normalizeUsername(name));
234
+ return /* @__PURE__ */ new Set([...STANDARD_RESTRICTED_USERNAMES, ...normalizedAppSpecific]);
235
+ };
236
+ export const RESTRICTED_SET = new Set(STANDARD_RESTRICTED_USERNAMES);
@@ -0,0 +1,10 @@
1
+ import type { user as userTable } from "../db/auth.js";
2
+ /**
3
+ * Creates a generateUniqueTag function bound to your database and user table.
4
+ * @param db Your drizzle database instance
5
+ * @param user The user table from your schema
6
+ * @returns A function that generates unique user tags
7
+ */
8
+ export declare const createGenerateUniqueTag: (db: {
9
+ select: any;
10
+ }, user: typeof userTable) => (userName: string) => Promise<string>;
@@ -0,0 +1,20 @@
1
+ import { eq, count, and } from "drizzle-orm";
2
+ const generateRandomTag = () => {
3
+ return Math.floor(Math.random() * 1e4).toString().padStart(4, "0");
4
+ };
5
+ export const createGenerateUniqueTag = (db, user) => {
6
+ return async (userName) => {
7
+ const MAX_RETRIES = 50;
8
+ for (let i = 0; i < MAX_RETRIES; i++) {
9
+ const newTag = generateRandomTag();
10
+ const result = await db.select({ count: count() }).from(user).where(and(eq(user.name, userName), eq(user.tag, newTag)));
11
+ const tagCount = result[0]?.count ?? 0;
12
+ if (tagCount === 0) {
13
+ return newTag;
14
+ }
15
+ }
16
+ throw new Error(
17
+ `Failed to generate a unique tag for user "${userName}" after ${MAX_RETRIES} attempts. Please retry the operation.`
18
+ );
19
+ };
20
+ };
@@ -0,0 +1,20 @@
1
+ import { eq, count, and } from "drizzle-orm";
2
+ const generateRandomTag = () => {
3
+ return Math.floor(Math.random() * 1e4).toString().padStart(4, "0");
4
+ };
5
+ export const createGenerateUniqueTag = (db, user) => {
6
+ return async (userName) => {
7
+ const MAX_RETRIES = 50;
8
+ for (let i = 0; i < MAX_RETRIES; i++) {
9
+ const newTag = generateRandomTag();
10
+ const result = await db.select({ count: count() }).from(user).where(and(eq(user.name, userName), eq(user.tag, newTag)));
11
+ const tagCount = result[0]?.count ?? 0;
12
+ if (tagCount === 0) {
13
+ return newTag;
14
+ }
15
+ }
16
+ throw new Error(
17
+ `Failed to generate a unique tag for user "${userName}" after ${MAX_RETRIES} attempts. Please retry the operation.`
18
+ );
19
+ };
20
+ };
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,74 @@
1
+ <script setup>
2
+ import { useFloatingTools } from "~/src/runtime/composables";
3
+ const {
4
+ activeToolIds,
5
+ registeredTools,
6
+ isVisible,
7
+ removeTool,
8
+ toggleExpanded,
9
+ isToolExpanded
10
+ } = useFloatingTools();
11
+ function getTool(id) {
12
+ return registeredTools.value.get(id);
13
+ }
14
+ </script>
15
+
16
+ <template>
17
+ <div
18
+ v-if="isVisible"
19
+ class="fixed top-[calc(var(--ui-header-height)+1.5rem)] right-6 z-9999 flex flex-col items-end gap-4 pointer-events-none"
20
+ >
21
+ <div
22
+ v-for="id in activeToolIds"
23
+ :key="id"
24
+ class="pointer-events-auto transition-all duration-300 ease-in-out"
25
+ >
26
+ <template v-if="getTool(id)">
27
+ <div
28
+ v-if="isToolExpanded(id)"
29
+ class="w-80 bg-dimmed border border-muted rounded-2xl overflow-hidden"
30
+ >
31
+ <div class="flex items-center justify-between p-sm bg-muted">
32
+ <div class="flex items-center gap-sm">
33
+ <UIcon :name="getTool(id).icon" class="w-4 h-4" />
34
+ <span class="text-md font-bold uppercase">
35
+ {{ getTool(id).title }}
36
+ </span>
37
+ </div>
38
+ <div class="flex items-center gap-sm">
39
+ <UButton
40
+ color="neutral"
41
+ icon="lucide:minus"
42
+ size="xs"
43
+ variant="ghost"
44
+ @click="toggleExpanded(id)"
45
+ />
46
+ <UButton
47
+ color="neutral"
48
+ icon="lucide:x"
49
+ size="xs"
50
+ variant="ghost"
51
+ @click="removeTool(id)"
52
+ />
53
+ </div>
54
+ </div>
55
+
56
+ <div class="p-sm">
57
+ <component :is="getTool(id).component" />
58
+ </div>
59
+ </div>
60
+
61
+ <UTooltip v-else :text="getTool(id).tooltip?.() || getTool(id).title">
62
+ <UButton
63
+ class="w-12 h-12 rounded-full flex items-center justify-center hover:scale-110 transition-transform shadow-lg"
64
+ color="primary"
65
+ variant="solid"
66
+ @click="toggleExpanded(id)"
67
+ >
68
+ <UIcon :name="getTool(id).icon" class="w-6 h-6" />
69
+ </UButton>
70
+ </UTooltip>
71
+ </template>
72
+ </div>
73
+ </div>
74
+ </template>
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -1,6 +1,6 @@
1
1
  <script setup>
2
2
  import { tv } from "../../internal/tv";
3
- import { useRC } from "../../composables/useRC";
3
+ import { useRC } from "~/src/runtime/composables";
4
4
  const { contain = true, rc: rcProp } = defineProps({
5
5
  contain: { type: Boolean, required: false },
6
6
  rc: { type: Object, required: false }
@@ -1,6 +1,6 @@
1
1
  <script setup>
2
2
  import { tv } from "../../internal/tv";
3
- import { useRC } from "../../composables/useRC";
3
+ import { useRC } from "~/src/runtime/composables";
4
4
  const { contain = true, rc: rcProp } = defineProps({
5
5
  contain: { type: Boolean, required: false },
6
6
  rc: { type: Object, required: false }
@@ -1,7 +1,7 @@
1
1
  <script setup>
2
2
  import { ref, reactive, onMounted, useTemplateRef, watch, nextTick } from "vue";
3
3
  import { tv } from "../../internal/tv";
4
- import { useRC } from "../../composables/useRC";
4
+ import { useRC } from "~/src/runtime/composables";
5
5
  const {
6
6
  src,
7
7
  alt = "Image",
@@ -2,7 +2,7 @@
2
2
  import { useAppConfig } from "nuxt/app";
3
3
  import { computed } from "#imports";
4
4
  import { tv } from "../../internal/tv";
5
- import { useRC } from "../../composables/useRC";
5
+ import { useRC } from "~/src/runtime/composables";
6
6
  const { variant = "mark", rc: rcProp } = defineProps({
7
7
  variant: { type: String, required: false },
8
8
  rc: { type: Object, required: false }
@@ -1,6 +1,6 @@
1
1
  <script setup>
2
2
  import { tv } from "../../internal/tv";
3
- import { useRC } from "../../composables/useRC";
3
+ import { useRC } from "~/src/runtime/composables";
4
4
  const {
5
5
  fieldLabel = "Subscribe to our Newsletter",
6
6
  description = "Stay updated on new posts and updates. Unsubscribe at any time.",
@@ -1,7 +1,7 @@
1
1
  <script setup>
2
2
  import { computed, onMounted, onUnmounted, ref } from "vue";
3
3
  import { tv } from "../../internal/tv";
4
- import { useRC } from "../../composables/useRC";
4
+ import { useRC } from "~/src/runtime/composables";
5
5
  const {
6
6
  circleStrokeWidth = 4,
7
7
  duration = 0.1,
@@ -1,6 +1,6 @@
1
1
  <script setup>
2
2
  import { tv } from "../../internal/tv";
3
- import { useRC } from "../../composables/useRC";
3
+ import { useRC } from "~/src/runtime/composables";
4
4
  const { src, alt, name, role, description, rc: rcProp } = defineProps({
5
5
  src: { type: String, required: true },
6
6
  alt: { type: String, required: true },
@@ -3,7 +3,7 @@ import { useAppConfig } from "#imports";
3
3
  import { computed } from "#imports";
4
4
  import { useI18n } from "vue-i18n";
5
5
  import { tv } from "../../internal/tv";
6
- import { useRC } from "../../composables/useRC";
6
+ import { useRC } from "~/src/runtime/composables";
7
7
  const { variant, to, target, rc: rcProp } = defineProps({
8
8
  variant: { type: String, required: true },
9
9
  to: { type: String, required: false },
@@ -4,7 +4,7 @@ import { computed } from "vue";
4
4
  import { useClipboard } from "@vueuse/core";
5
5
  import { useToast } from "@nuxt/ui/composables";
6
6
  import { tv } from "../../internal/tv";
7
- import { useRC } from "../../composables/useRC";
7
+ import { useRC } from "~/src/runtime/composables";
8
8
  import { slugify } from "../../utils";
9
9
  defineOptions({
10
10
  name: "SectionComponent"
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,49 @@
1
+ <script setup>
2
+ import { formatTimeAgo } from "@vueuse/core";
3
+ import { useApi, useDashboard } from "~/src/runtime/composables";
4
+ const { isNotificationsSlideoverOpen } = useDashboard();
5
+ const { data: notifications } = await useApi("/api/notifications");
6
+ </script>
7
+
8
+ <template>
9
+ <USlideover
10
+ v-model:open="isNotificationsSlideoverOpen"
11
+ side="right"
12
+ title="Notifications"
13
+ :ui="{
14
+ header: 'flex items-center justify-between',
15
+ content: 'w-full max-w-4/5 lg:w-96 rounded-none'
16
+ }"
17
+ >
18
+ <template #body>
19
+ <NuxtLink
20
+ v-for="notification in notifications"
21
+ :key="notification.id"
22
+ :to="`/dashboard/inbox?id=${notification.id}`"
23
+ class="relative -mx-3 flex items-center gap-3 rounded-md px-3 py-2.5 first:-mt-3 last:-mb-3 hover:bg-elevated/50"
24
+ >
25
+ <UChip color="error" :show="!!notification.unread" inset>
26
+ <UAvatar v-bind="notification.sender.avatar" :alt="notification.sender.name" size="md" />
27
+ </UChip>
28
+
29
+ <div class="flex-1 text-sm">
30
+ <p class="flex items-center justify-between">
31
+ <span class="font-medium text-highlighted">{{
32
+ notification.sender.name
33
+ }}</span>
34
+
35
+ <time
36
+ :datetime="notification.date"
37
+ class="text-xs text-muted"
38
+ v-text="formatTimeAgo(new Date(notification.date))"
39
+ />
40
+ </p>
41
+
42
+ <p class="text-sm text-dimmed">
43
+ {{ notification.body }}
44
+ </p>
45
+ </div>
46
+ </NuxtLink>
47
+ </template>
48
+ </USlideover>
49
+ </template>
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,36 @@
1
+ <script setup>
2
+ import { useQuickActions } from "~/src/runtime/composables";
3
+ import { computed } from "vue";
4
+ const { registeredActions } = useQuickActions();
5
+ const menuItems = computed(() => {
6
+ const grouped = registeredActions.value.reduce((acc, action) => {
7
+ const groupId = action.group ?? 0;
8
+ if (!acc[groupId]) acc[groupId] = [];
9
+ acc[groupId].push({
10
+ label: action.label,
11
+ icon: action.icon,
12
+ onSelect: action.onSelect
13
+ });
14
+ return acc;
15
+ }, {});
16
+ return Object.values(grouped);
17
+ });
18
+ </script>
19
+
20
+ <template>
21
+ <div class="fixed bottom-6 right-6 z-10000">
22
+ <ClientOnly>
23
+ <UDropdownMenu v-if="menuItems.length > 0" :items="menuItems" :ui="{ content: 'w-48' }">
24
+ <UButton
25
+ icon="lucide:plus"
26
+ color="primary"
27
+ square
28
+ :ui="{
29
+ base: 'rounded-full size-16 lg:size-12 justify-center',
30
+ leadingIcon: 'size-6'
31
+ }"
32
+ />
33
+ </UDropdownMenu>
34
+ </ClientOnly>
35
+ </div>
36
+ </template>
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,6 @@
1
+ export interface TeamsMenuProps {
2
+ collapsed?: boolean;
3
+ }
4
+ declare const __VLS_export: import("vue").DefineComponent<TeamsMenuProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<TeamsMenuProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
5
+ declare const _default: typeof __VLS_export;
6
+ export default _default;
@@ -0,0 +1,77 @@
1
+ <script setup>
2
+ import { ref, computed } from "vue";
3
+ const { collapsed } = defineProps({
4
+ collapsed: { type: Boolean, required: false }
5
+ });
6
+ const teams = ref([
7
+ {
8
+ label: `Nuxt`,
9
+ avatar: {
10
+ src: `https://github.com/nuxt.png`,
11
+ alt: `Nuxt`
12
+ }
13
+ },
14
+ {
15
+ label: `NuxtHub`,
16
+ avatar: {
17
+ src: `https://github.com/nuxt-hub.png`,
18
+ alt: `NuxtHub`
19
+ }
20
+ },
21
+ {
22
+ label: `NuxtLabs`,
23
+ avatar: {
24
+ src: `https://github.com/nuxtlabs.png`,
25
+ alt: `NuxtLabs`
26
+ }
27
+ }
28
+ ]);
29
+ const selectedTeam = ref(teams.value[0]);
30
+ const items = computed(() => {
31
+ return [
32
+ teams.value.map((team) => ({
33
+ ...team,
34
+ onSelect() {
35
+ selectedTeam.value = team;
36
+ }
37
+ })),
38
+ [
39
+ {
40
+ label: `Create team`,
41
+ icon: `i-lucide-circle-plus`
42
+ },
43
+ {
44
+ label: `Manage teams`,
45
+ icon: `i-lucide-cog`
46
+ }
47
+ ]
48
+ ];
49
+ });
50
+ </script>
51
+
52
+ <template>
53
+ <UDropdownMenu
54
+ :content="{ align: 'center', collisionPadding: 12 }"
55
+ :items="items"
56
+ :ui="{
57
+ content: collapsed ? 'w-40' : 'w-(--reka-dropdown-menu-trigger-width)'
58
+ }"
59
+ >
60
+ <UButton
61
+ :class="[!collapsed && 'py-2']"
62
+ :square="collapsed"
63
+ :ui="{
64
+ trailingIcon: 'text-dimmed'
65
+ }"
66
+ block
67
+ class="data-[state=open]:bg-elevated"
68
+ color="neutral"
69
+ v-bind="{
70
+ ...selectedTeam,
71
+ label: collapsed ? void 0 : selectedTeam?.label,
72
+ trailingIcon: collapsed ? void 0 : 'i-lucide-chevrons-up-down'
73
+ }"
74
+ variant="ghost"
75
+ />
76
+ </UDropdownMenu>
77
+ </template>
@@ -0,0 +1,6 @@
1
+ export interface TeamsMenuProps {
2
+ collapsed?: boolean;
3
+ }
4
+ declare const __VLS_export: import("vue").DefineComponent<TeamsMenuProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<TeamsMenuProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
5
+ declare const _default: typeof __VLS_export;
6
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;