@strands.gg/accui 2.8.0 → 2.9.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.
Files changed (70) hide show
  1. package/dist/index.d.ts +3 -17
  2. package/dist/nuxt/module.d.ts +4 -5
  3. package/dist/nuxt/runtime/composables/useAuthenticatedFetch.d.ts +20 -0
  4. package/dist/nuxt/runtime/composables/useStrandsAuth.d.ts +65 -0
  5. package/dist/nuxt/runtime/middleware/auth.d.ts +6 -0
  6. package/dist/nuxt/runtime/middleware/auth.global.d.ts +2 -0
  7. package/dist/nuxt/runtime/middleware/guest.d.ts +6 -0
  8. package/dist/nuxt/runtime/plugin.client.d.ts +2 -0
  9. package/dist/nuxt/runtime/plugin.server.d.ts +2 -0
  10. package/dist/nuxt/runtime/plugins/auth-interceptor.client.d.ts +2 -0
  11. package/dist/nuxt/types.d.ts +45 -0
  12. package/dist/nuxt.d.ts +3 -1
  13. package/dist/shared/defaults.d.ts +2 -0
  14. package/dist/types/composables.d.ts +96 -0
  15. package/dist/types/index.d.ts +210 -260
  16. package/dist/utils/colors.d.ts +10 -0
  17. package/dist/utils/index.d.ts +2 -0
  18. package/dist/utils/slots.d.ts +1 -0
  19. package/dist/utils/validation.d.ts +12 -0
  20. package/dist/vue/components/StrandsNav/index.d.ts +8 -0
  21. package/dist/vue/components/StrandsNav/types.d.ts +12 -0
  22. package/dist/vue/components/icons/index.d.ts +2 -0
  23. package/dist/vue/components/index.d.ts +27 -0
  24. package/dist/vue/composables/useAuthenticatedFetch.d.ts +20 -0
  25. package/dist/vue/composables/useDarkMode.d.ts +48 -0
  26. package/dist/vue/composables/useFloatingPosition.d.ts +22 -0
  27. package/dist/vue/composables/useModalStack.d.ts +86 -0
  28. package/dist/vue/composables/useOAuthProviders.d.ts +73 -0
  29. package/dist/vue/composables/useStrandsAuth.d.ts +2 -0
  30. package/dist/vue/composables/useStrandsConfig.d.ts +5 -0
  31. package/dist/vue/composables/useStrandsMfa.d.ts +36 -0
  32. package/dist/vue/composables/useTheme.d.ts +18 -0
  33. package/dist/vue/index.d.ts +16 -0
  34. package/dist/vue/plugins/StrandsUIPlugin.d.ts +20 -0
  35. package/dist/vue/ui/UiButton/index.d.ts +13 -0
  36. package/dist/vue/ui/index.d.ts +54 -0
  37. package/dist/vue/utils/contrast.d.ts +75 -0
  38. package/dist/vue/utils/debounce.d.ts +12 -0
  39. package/dist/vue/utils/fontPreloader.d.ts +11 -0
  40. package/dist/vue/utils/iconProps.d.ts +9 -0
  41. package/dist/vue/utils/lazyComponents.d.ts +4 -0
  42. package/dist/vue/utils/levels.d.ts +27 -0
  43. package/dist/vue/utils/modalStack.d.ts +31 -0
  44. package/dist/vue/utils/performanceInit.d.ts +40 -0
  45. package/dist/vue/utils/requestCache.d.ts +49 -0
  46. package/dist/vue/utils/sounds.d.ts +57 -0
  47. package/package.json +2 -3
  48. package/dist/accui.css +0 -1
  49. package/dist/index.cjs.js +0 -1
  50. package/dist/index.es.js +0 -40821
  51. package/dist/nuxt/module.cjs.js +0 -1
  52. package/dist/nuxt/module.es.js +0 -193
  53. package/dist/nuxt/runtime/composables/useAuthenticatedFetch.cjs.js +0 -1
  54. package/dist/nuxt/runtime/composables/useAuthenticatedFetch.es.js +0 -134
  55. package/dist/nuxt/runtime/composables/useStrandsAuth.cjs.js +0 -1
  56. package/dist/nuxt/runtime/composables/useStrandsAuth.es.js +0 -56
  57. package/dist/nuxt/runtime/middleware/auth.global.cjs.js +0 -1
  58. package/dist/nuxt/runtime/middleware/auth.global.es.js +0 -54
  59. package/dist/nuxt/runtime/plugin.client.cjs.js +0 -1
  60. package/dist/nuxt/runtime/plugin.client.es.js +0 -26
  61. package/dist/nuxt/runtime/plugin.server.cjs.js +0 -1
  62. package/dist/nuxt/runtime/plugin.server.es.js +0 -17
  63. package/dist/nuxt/runtime/plugins/auth-interceptor.client.cjs.js +0 -1
  64. package/dist/nuxt/runtime/plugins/auth-interceptor.client.es.js +0 -77
  65. package/dist/nuxt.cjs.js +0 -1
  66. package/dist/nuxt.es.js +0 -11
  67. package/dist/useStrandsAuth-Ca9Zqmfy.cjs.js +0 -1
  68. package/dist/useStrandsAuth-jI_X_wiK.es.js +0 -916
  69. package/dist/useStrandsConfig-CLSzvTvE.cjs.js +0 -1
  70. package/dist/useStrandsConfig-XmPqJn_B.es.js +0 -241
@@ -1,292 +1,242 @@
1
- // Re-export types from shared-types when available
2
- // export * from '@strands.gg/auth-types'
3
-
4
- // Core authentication types
5
1
  export interface User {
6
- id: string
7
- email: string
8
- firstName: string
9
- lastName: string
10
- avatar?: string
11
- mfaEnabled: boolean
12
- emailVerified: boolean
13
- passwordUpdatedAt?: string | Date
14
- settings?: any
15
- xp: number
16
- level: number
17
- next_level_xp: number
18
- username?: string
19
- usernameLastChangedAt?: string | Date
20
- createdAt: string | Date
21
- updatedAt: string | Date
2
+ id: string;
3
+ email: string;
4
+ firstName: string;
5
+ lastName: string;
6
+ avatar?: string;
7
+ mfaEnabled: boolean;
8
+ emailVerified: boolean;
9
+ passwordUpdatedAt?: string | Date;
10
+ settings?: any;
11
+ xp: number;
12
+ level: number;
13
+ next_level_xp: number;
14
+ username?: string;
15
+ usernameLastChangedAt?: string | Date;
16
+ createdAt: string | Date;
17
+ updatedAt: string | Date;
22
18
  }
23
-
24
- // Authenticated fetch types
25
19
  export interface AuthenticatedFetchOptions extends RequestInit {
26
- /**
27
- * Whether to automatically refresh token if the request fails with 401
28
- * @default true
29
- */
30
- autoRefresh?: boolean
31
-
32
- /**
33
- * Whether to throw an error if user is not authenticated
34
- * @default true
35
- */
36
- requireAuth?: boolean
37
-
38
- /**
39
- * Base URL for the API requests
40
- * If not provided, will use the current origin
41
- */
42
- baseURL?: string
20
+ /**
21
+ * Whether to automatically refresh token if the request fails with 401
22
+ * @default true
23
+ */
24
+ autoRefresh?: boolean;
25
+ /**
26
+ * Whether to throw an error if user is not authenticated
27
+ * @default true
28
+ */
29
+ requireAuth?: boolean;
30
+ /**
31
+ * Base URL for the API requests
32
+ * If not provided, will use the current origin
33
+ */
34
+ baseURL?: string;
43
35
  }
44
-
45
36
  export interface Session {
46
- id?: string
47
- userId?: string
48
- accessToken: string
49
- refreshToken: string
50
- expiresAt: Date
51
- createdAt?: Date
37
+ id?: string;
38
+ userId?: string;
39
+ accessToken: string;
40
+ refreshToken: string;
41
+ expiresAt: Date;
42
+ createdAt?: Date;
52
43
  }
53
-
54
- // Enhanced session response type for session management
55
44
  export interface SessionInfo {
56
- id: string
57
- device_name?: string
58
- device_type?: string
59
- ip_address?: string
60
- country?: string
61
- city?: string
62
- application_domain?: string
63
- application_name?: string
64
- created_at: string | Date
65
- last_activity_at?: string | Date
66
- is_current: boolean
45
+ id: string;
46
+ device_name?: string;
47
+ device_type?: string;
48
+ ip_address?: string;
49
+ country?: string;
50
+ city?: string;
51
+ application_domain?: string;
52
+ application_name?: string;
53
+ created_at: string | Date;
54
+ last_activity_at?: string | Date;
55
+ is_current: boolean;
67
56
  }
68
-
69
57
  export interface SessionStats {
70
- total_sessions: number
71
- active_sessions: number
72
- devices_by_type: Record<string, number>
73
- unique_locations: string[]
58
+ total_sessions: number;
59
+ active_sessions: number;
60
+ devices_by_type: Record<string, number>;
61
+ unique_locations: string[];
74
62
  }
75
-
76
63
  export interface AuthConfig {
77
- apiUrl: string
78
- applicationId: string
79
- publicKey: string
80
- autoRefresh?: boolean
81
- redirectUrl?: string
64
+ apiUrl: string;
65
+ applicationId: string;
66
+ publicKey: string;
67
+ autoRefresh?: boolean;
68
+ redirectUrl?: string;
82
69
  }
83
-
84
- // Component prop types
85
70
  export interface SignInCredentials {
86
- email: string
87
- password: string
71
+ email: string;
72
+ password: string;
88
73
  }
89
-
90
74
  export interface SignUpData {
91
- email: string
92
- password: string
93
- firstName: string
94
- lastName: string
75
+ email: string;
76
+ password: string;
77
+ firstName: string;
78
+ lastName: string;
95
79
  }
96
-
97
- // OAuth provider types
98
80
  export interface OAuthProvider {
99
- id: string
100
- name: string
101
- enabled: boolean
102
- clientId?: string // Optional - may still be used for OAuth provider configuration
103
- scopes?: string[]
81
+ id: string;
82
+ name: string;
83
+ enabled: boolean;
84
+ clientId?: string;
85
+ scopes?: string[];
104
86
  }
105
-
106
- // Configuration types for Nuxt modules
107
87
  export interface StrandsAuthConfig {
108
- /**
109
- * Base URL for the Strands Auth API
110
- * @default 'https://your-api.example.com'
111
- */
112
- baseUrl?: string
113
-
114
- /**
115
- * Client ID for authentication (optional - authentication is now based on domain)
116
- */
117
- clientId?: string
118
-
119
- /**
120
- * Primary accent color for the auth components
121
- * @default '#EA00A8'
122
- */
123
- accentColor?: string
124
-
125
- /**
126
- * Default redirect URL after successful authentication
127
- * @default '/'
128
- */
129
- redirectUrl?: string
130
-
131
- /**
132
- * URL to redirect to after successful sign in
133
- * @default '/dashboard'
134
- */
135
- onSignInUrl?: string
136
-
137
- /**
138
- * URL to redirect to after successful sign out
139
- * @default '/'
140
- */
141
- onSignOutUrl?: string
142
-
143
- /**
144
- * Enable automatic token refresh
145
- * @default true
146
- */
147
- autoRefresh?: boolean
148
-
149
- /**
150
- * Token refresh interval in minutes
151
- * @default 4
152
- */
153
- refreshInterval?: number
154
-
155
- /**
156
- * Pages that should redirect to sign in if user is not authenticated
157
- * @default []
158
- */
159
- protectedRoutes?: string[]
160
-
161
- /**
162
- * Pages that should redirect away if user IS authenticated
163
- * @default ['/auth', '/login', '/register']
164
- */
165
- guestOnlyRoutes?: string[]
166
-
167
- /**
168
- * Enable development mode (shows debug info)
169
- * @default false
170
- */
171
- devMode?: boolean
172
-
173
- /**
174
- * Support email address for contact links
175
- * @optional
176
- */
177
- supportEmail?: string
178
-
179
- /**
180
- * OAuth2 redirect URL for OAuth providers
181
- * If not specified, will use {origin}/auth/callback
182
- * @optional
183
- */
184
- oauth2RedirectUrl?: string
185
-
186
- /**
187
- * Automatically import CSS styles
188
- * Set to false if you want to manually import styles or use custom styling
189
- * @default true
190
- */
191
- styles?: boolean
192
-
193
- /**
194
- * Custom API endpoints
195
- */
196
- endpoints?: Partial<StrandsAuthEndpoints>
197
-
198
- /**
199
- * Enable squircle corners for UI components
200
- * @default true
201
- */
202
- useSquircle?: boolean
88
+ /**
89
+ * Base URL for the Strands Auth API
90
+ * @default 'https://your-api.example.com'
91
+ */
92
+ baseUrl?: string;
93
+ /**
94
+ * Client ID for authentication (optional - authentication is now based on domain)
95
+ */
96
+ clientId?: string;
97
+ /**
98
+ * Primary accent color for the auth components
99
+ * @default '#EA00A8'
100
+ */
101
+ accentColor?: string;
102
+ /**
103
+ * Default redirect URL after successful authentication
104
+ * @default '/'
105
+ */
106
+ redirectUrl?: string;
107
+ /**
108
+ * URL to redirect to after successful sign in
109
+ * @default '/dashboard'
110
+ */
111
+ onSignInUrl?: string;
112
+ /**
113
+ * URL to redirect to after successful sign out
114
+ * @default '/'
115
+ */
116
+ onSignOutUrl?: string;
117
+ /**
118
+ * Enable automatic token refresh
119
+ * @default true
120
+ */
121
+ autoRefresh?: boolean;
122
+ /**
123
+ * Token refresh interval in minutes
124
+ * @default 4
125
+ */
126
+ refreshInterval?: number;
127
+ /**
128
+ * Pages that should redirect to sign in if user is not authenticated
129
+ * @default []
130
+ */
131
+ protectedRoutes?: string[];
132
+ /**
133
+ * Pages that should redirect away if user IS authenticated
134
+ * @default ['/auth', '/login', '/register']
135
+ */
136
+ guestOnlyRoutes?: string[];
137
+ /**
138
+ * Enable development mode (shows debug info)
139
+ * @default false
140
+ */
141
+ devMode?: boolean;
142
+ /**
143
+ * Support email address for contact links
144
+ * @optional
145
+ */
146
+ supportEmail?: string;
147
+ /**
148
+ * OAuth2 redirect URL for OAuth providers
149
+ * If not specified, will use {origin}/auth/callback
150
+ * @optional
151
+ */
152
+ oauth2RedirectUrl?: string;
153
+ /**
154
+ * Automatically import CSS styles
155
+ * Set to false if you want to manually import styles or use custom styling
156
+ * @default true
157
+ */
158
+ styles?: boolean;
159
+ /**
160
+ * Custom API endpoints
161
+ */
162
+ endpoints?: Partial<StrandsAuthEndpoints>;
163
+ /**
164
+ * Enable squircle corners for UI components
165
+ * @default true
166
+ */
167
+ useSquircle?: boolean;
203
168
  }
204
-
205
169
  export interface StrandsAuthEndpoints {
206
- signIn: string
207
- signUp: string
208
- signOut: string
209
- refresh: string
210
- passwordReset: string
211
- passwordResetConfirm: string
212
- completeRegistration: string
213
- profile: string
214
- verifyEmail: string
215
- oauthProviders: string
216
- oauthProvider: string
217
- changeEmail: string
218
- avatar: string
219
- settings: string
220
- // Username endpoints
221
- changeUsername: string
222
- usernameCooldown: string
223
- checkUsernameAvailability: string
224
- // MFA endpoints
225
- mfaDevices: string
226
- mfaTotpSetup: string
227
- mfaTotpVerify: string
228
- mfaEmailSetup: string
229
- mfaEmailSend: string
230
- mfaEmailVerify: string
231
- mfaDeviceDisable: string
232
- mfaBackupCodes: string
233
- // Hardware key endpoints
234
- mfaHardwareStartRegistration: string
235
- mfaHardwareCompleteRegistration: string
236
- // MFA sign-in specific endpoints
237
- mfaSigninSendEmail: string
238
- mfaSigninVerify: string
239
- mfaBackupCodeVerify: string
240
- mfaWebAuthnChallenge: string
241
- // Session management endpoints
242
- sessions: string
243
- sessionsStats: string
244
- sessionRevoke: string
245
- sessionsRevokeAll: string
170
+ signIn: string;
171
+ signUp: string;
172
+ signOut: string;
173
+ refresh: string;
174
+ passwordReset: string;
175
+ passwordResetConfirm: string;
176
+ completeRegistration: string;
177
+ profile: string;
178
+ verifyEmail: string;
179
+ oauthProviders: string;
180
+ oauthProvider: string;
181
+ changeEmail: string;
182
+ avatar: string;
183
+ settings: string;
184
+ changeUsername: string;
185
+ usernameCooldown: string;
186
+ checkUsernameAvailability: string;
187
+ mfaDevices: string;
188
+ mfaTotpSetup: string;
189
+ mfaTotpVerify: string;
190
+ mfaEmailSetup: string;
191
+ mfaEmailSend: string;
192
+ mfaEmailVerify: string;
193
+ mfaDeviceDisable: string;
194
+ mfaBackupCodes: string;
195
+ mfaHardwareStartRegistration: string;
196
+ mfaHardwareCompleteRegistration: string;
197
+ mfaSigninSendEmail: string;
198
+ mfaSigninVerify: string;
199
+ mfaBackupCodeVerify: string;
200
+ mfaWebAuthnChallenge: string;
201
+ sessions: string;
202
+ sessionsStats: string;
203
+ sessionRevoke: string;
204
+ sessionsRevokeAll: string;
246
205
  }
247
-
248
- // API Response types
249
206
  export interface AuthResponse {
250
- access_token: string
251
- refresh_token: string
252
- user: User
253
- mfa_required?: boolean
254
- mfa_session_id?: string
255
- available_mfa_methods?: MfaDevice[]
256
- }
257
-
258
- // MFA Types
259
- export type MfaDeviceType = 'totp' | 'email' | 'hardware' | 'passkey'
260
-
207
+ access_token: string;
208
+ refresh_token: string;
209
+ user: User;
210
+ mfa_required?: boolean;
211
+ mfa_session_id?: string;
212
+ available_mfa_methods?: MfaDevice[];
213
+ }
214
+ export type MfaDeviceType = 'totp' | 'email' | 'hardware' | 'passkey';
261
215
  export interface MfaDevice {
262
- id: string
263
- device_type: MfaDeviceType
264
- device_name: string
265
- is_active: boolean
266
- last_used_at?: string | Date
267
- created_at: string | Date
216
+ id: string;
217
+ device_type: MfaDeviceType;
218
+ device_name: string;
219
+ is_active: boolean;
220
+ last_used_at?: string | Date;
221
+ created_at: string | Date;
268
222
  }
269
-
270
223
  export interface MfaDevicesResponse {
271
- devices: MfaDevice[]
272
- mfa_enabled: boolean
224
+ devices: MfaDevice[];
225
+ mfa_enabled: boolean;
273
226
  }
274
-
275
227
  export interface TotpSetupResponse {
276
- device_id: string
277
- secret: string
278
- qr_code_url: string
279
- backup_codes: string[]
228
+ device_id: string;
229
+ secret: string;
230
+ qr_code_url: string;
231
+ backup_codes: string[];
280
232
  }
281
-
282
233
  export interface BackupCodesResponse {
283
- backup_codes: string[]
234
+ backup_codes: string[];
284
235
  }
285
-
286
- // MFA Error Response types
287
236
  export interface MfaErrorResponse {
288
- code: string
289
- message: string
290
- mfa_session_id?: string
291
- available_methods?: string[]
292
- }
237
+ code: string;
238
+ message: string;
239
+ mfa_session_id?: string;
240
+ available_methods?: string[];
241
+ }
242
+ export type * from './composables';
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Complete Tailwind CSS color palette with shades
3
+ * Provides all 22 Tailwind colors with their full shade ranges (50-950)
4
+ */
5
+ interface SwatchConfig {
6
+ label?: string;
7
+ shades?: string[];
8
+ }
9
+ export declare const tailwindColors: Record<string, SwatchConfig>;
10
+ export type { SwatchConfig };
@@ -0,0 +1,2 @@
1
+ export * from './validation';
2
+ export * from './colors';
@@ -0,0 +1 @@
1
+ export declare const slotHasContent: (slotName: string, slots: any) => boolean;
@@ -0,0 +1,12 @@
1
+ export declare const isValidEmail: (email: string) => boolean;
2
+ export declare const validatePassword: (password: string) => {
3
+ isValid: boolean;
4
+ strength: "weak" | "medium" | "strong";
5
+ errors: string[];
6
+ };
7
+ export declare const isValidName: (name: string) => boolean;
8
+ export declare const isRequired: (value: string) => boolean;
9
+ export declare const passwordsMatch: (password: string, confirmation: string) => boolean;
10
+ export declare const getInitials: (firstName?: string, lastName?: string) => string;
11
+ export declare const formatDate: (date: string | Date) => string;
12
+ export declare const debounce: <T extends (...args: any[]) => any>(func: T, wait: number) => ((...args: Parameters<T>) => void);
@@ -0,0 +1,8 @@
1
+ import StrandsNavComponent from './StrandsNav.vue';
2
+ import StrandsNavItem from './StrandsNavItem.vue';
3
+ declare const StrandsNav: typeof StrandsNavComponent & {
4
+ Item: typeof StrandsNavItem;
5
+ };
6
+ export default StrandsNav;
7
+ export { StrandsNavItem };
8
+ export type { NavItem } from './types';
@@ -0,0 +1,12 @@
1
+ export interface NavItem {
2
+ id: string;
3
+ label: string;
4
+ to?: string;
5
+ href?: string;
6
+ icon?: string;
7
+ badge?: string | number;
8
+ active?: boolean;
9
+ disabled?: boolean;
10
+ children?: NavItem[];
11
+ [key: string]: any;
12
+ }
@@ -0,0 +1,2 @@
1
+ export { default as IconGoogle } from './IconGoogle.vue';
2
+ export { default as IconGithub } from './IconGithub.vue';
@@ -0,0 +1,27 @@
1
+ export { default as StrandsAuth } from './StrandsAuth.vue';
2
+ export { default as StrandsSignIn } from './StrandsSignIn.vue';
3
+ export { default as StrandsSignUp } from './StrandsSignUp.vue';
4
+ export { default as StrandsCompleteSignUp } from './StrandsCompleteSignUp.vue';
5
+ export { default as StrandsUserProfile } from './StrandsUserProfile.vue';
6
+ export { default as StrandsPasswordReset } from './StrandsPasswordReset.vue';
7
+ export { default as StrandsMfaVerification } from './StrandsMfaVerification.vue';
8
+ export { default as StrandsSessionsModal } from './StrandsSessionsModal.vue';
9
+ export { default as StrandsConfirmModal } from './StrandsConfirmModal.vue';
10
+ export { default as SignedIn } from './SignedIn.vue';
11
+ export { default as StrandsLogo } from './StrandsLogo.vue';
12
+ export { default as StrandsSecuredFooter } from './StrandsSecuredFooter.vue';
13
+ export { default as StrandsConfigProvider } from './StrandsConfigProvider.vue';
14
+ export { default as SvgIcon } from './SvgIcon.vue';
15
+ export { default as StrandsUserButton } from './StrandsUserButton.vue';
16
+ export { default as StrandsNav, StrandsNavItem } from './StrandsNav';
17
+ export type { NavItem } from './StrandsNav';
18
+ export { default as VirtualList } from './VirtualList.vue';
19
+ export * from './icons';
20
+ export { preloadCriticalComponents } from '../utils/lazyComponents';
21
+ export { default as StrandsMFASetup } from './StrandsMFASetup.vue';
22
+ export { default as StrandsMfaModal } from './StrandsMfaModal.vue';
23
+ export { default as StrandsTotpSetupModal } from './StrandsTotpSetupModal.vue';
24
+ export { default as StrandsEmailMfaSetupModal } from './StrandsEmailMfaSetupModal.vue';
25
+ export { default as StrandsHardwareKeySetupModal } from './StrandsHardwareKeySetupModal.vue';
26
+ export { default as StrandsBackupCodesModal } from './StrandsBackupCodesModal.vue';
27
+ export { default as StrandsSettingsModal } from './StrandsSettingsModal.vue';
@@ -0,0 +1,20 @@
1
+ import type { AuthenticatedFetchOptions } from '../../types';
2
+ /**
3
+ * Enhanced fetch composable that automatically includes auth headers
4
+ * and handles token refresh for API requests (Vue version)
5
+ */
6
+ export declare function useAuthenticatedFetch(): {
7
+ authenticatedFetch: (url: string | URL, options?: AuthenticatedFetchOptions) => Promise<Response>;
8
+ get: (url: string | URL, options?: AuthenticatedFetchOptions) => Promise<Response>;
9
+ post: (url: string | URL, body?: any, options?: AuthenticatedFetchOptions) => Promise<Response>;
10
+ put: (url: string | URL, body?: any, options?: AuthenticatedFetchOptions) => Promise<Response>;
11
+ delete: (url: string | URL, options?: AuthenticatedFetchOptions) => Promise<Response>;
12
+ patch: (url: string | URL, body?: any, options?: AuthenticatedFetchOptions) => Promise<Response>;
13
+ };
14
+ export declare const $authFetch: {
15
+ get: (url: string | URL, options?: AuthenticatedFetchOptions) => Promise<Response>;
16
+ post: (url: string | URL, body?: any, options?: AuthenticatedFetchOptions) => Promise<Response>;
17
+ put: (url: string | URL, body?: any, options?: AuthenticatedFetchOptions) => Promise<Response>;
18
+ delete: (url: string | URL, options?: AuthenticatedFetchOptions) => Promise<Response>;
19
+ patch: (url: string | URL, body?: any, options?: AuthenticatedFetchOptions) => Promise<Response>;
20
+ };
@@ -0,0 +1,48 @@
1
+ export type ThemeMode = 'light' | 'dark' | 'system';
2
+ /**
3
+ * Dark mode composable
4
+ */
5
+ export declare function useDarkMode(): {
6
+ currentTheme: import("vue").ComputedRef<ThemeMode>;
7
+ isDark: import("vue").ComputedRef<boolean>;
8
+ themeLabel: import("vue").ComputedRef<"Light" | "Dark" | "System">;
9
+ setTheme: (theme: ThemeMode) => void;
10
+ toggle: () => void;
11
+ cycleTheme: () => void;
12
+ initialize: () => void;
13
+ themeOptions: ({
14
+ value: "light";
15
+ label: string;
16
+ icon: string;
17
+ } | {
18
+ value: "dark";
19
+ label: string;
20
+ icon: string;
21
+ } | {
22
+ value: "system";
23
+ label: string;
24
+ icon: string;
25
+ })[];
26
+ };
27
+ export declare function useGlobalDarkMode(): {
28
+ currentTheme: import("vue").ComputedRef<ThemeMode>;
29
+ isDark: import("vue").ComputedRef<boolean>;
30
+ themeLabel: import("vue").ComputedRef<"Light" | "Dark" | "System">;
31
+ setTheme: (theme: ThemeMode) => void;
32
+ toggle: () => void;
33
+ cycleTheme: () => void;
34
+ initialize: () => void;
35
+ themeOptions: ({
36
+ value: "light";
37
+ label: string;
38
+ icon: string;
39
+ } | {
40
+ value: "dark";
41
+ label: string;
42
+ icon: string;
43
+ } | {
44
+ value: "system";
45
+ label: string;
46
+ icon: string;
47
+ })[];
48
+ };