remoraid 2.7.2 → 2.10.7
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/core/index.cjs +645 -429
- package/dist/core/index.d.ts +257 -106
- package/dist/core/index.js +642 -420
- package/dist/server/index.d.ts +2 -2
- package/package.json +2 -1
package/dist/core/index.d.ts
CHANGED
@@ -1,34 +1,40 @@
|
|
1
|
-
import { PropsWithChildren as
|
2
|
-
import { AlertProps,
|
1
|
+
import { PropsWithChildren as PropsWithChildren5, ReactNode as ReactNode6 } from "react";
|
2
|
+
import { AlertProps, MantineBreakpoint, MantineColorScheme, MantineSize, MantineTheme, ScrollAreaProps } from "@mantine/core";
|
3
3
|
import { Icon, IconProps } from "@tabler/icons-react";
|
4
4
|
import { ImageProps } from "next/image";
|
5
|
-
import { ReactNode } from "react";
|
5
|
+
import { Dispatch, ReactNode, SetStateAction } from "react";
|
6
6
|
type RemoraidUser = {
|
7
7
|
name: string
|
8
8
|
} | null;
|
9
|
-
interface
|
9
|
+
interface RemoraidAuthContext {
|
10
|
+
user: RemoraidUser;
|
11
|
+
onLogout?: () => void;
|
12
|
+
}
|
13
|
+
type AppLogo = (props: Omit<ImageProps, "src" | "alt">) => ReactNode;
|
14
|
+
interface StaticRemoraidAppContext {
|
10
15
|
navigablePages: {
|
11
16
|
label: string
|
12
17
|
href: string
|
13
18
|
icon?: Icon
|
14
19
|
}[];
|
15
|
-
|
20
|
+
logo?: AppLogo;
|
21
|
+
auth?: RemoraidAuthContext;
|
16
22
|
}
|
23
|
+
type CustomAppVariables = { [K in Exclude<string, keyof StaticRemoraidAppContext>] : any };
|
24
|
+
type RemoraidAppContext<V extends CustomAppVariables> = StaticRemoraidAppContext & V;
|
25
|
+
type AppContextProps<V extends CustomAppVariables> = StaticRemoraidAppContext & V;
|
17
26
|
declare enum NavbarVariant {
|
18
27
|
Minimal = "minimal"
|
19
28
|
}
|
20
|
-
|
21
|
-
|
22
|
-
linkSize: string;
|
23
|
-
px: MantineSize | number;
|
24
|
-
py: MantineSize | number;
|
25
|
-
iconSize?: string | number;
|
29
|
+
declare enum FooterVariant {
|
30
|
+
Minimal = "minimal"
|
26
31
|
}
|
27
32
|
type UserExperience = Record<string, any>;
|
28
33
|
interface CoreUserExperience extends UserExperience {
|
29
|
-
navbarVariant: NavbarVariant;
|
30
|
-
navbarSettings: NavbarSettings;
|
31
34
|
showWelcomeMessage: boolean;
|
35
|
+
navbar: {
|
36
|
+
hiddenPages: string[]
|
37
|
+
};
|
32
38
|
}
|
33
39
|
type UserExperienceProviderProps<T extends UserExperience> = {
|
34
40
|
initialValue?: Partial<T>
|
@@ -75,14 +81,6 @@ interface RemoraidThemeDependencies {
|
|
75
81
|
colorScheme: MantineColorScheme;
|
76
82
|
}
|
77
83
|
type RemoraidThemeCallback = (dependencies: Partial<RemoraidThemeDependencies>) => Partial<RemoraidTheme>;
|
78
|
-
type AppShellLogo = (props: Omit<ImageProps, "src" | "alt">) => ReactNode;
|
79
|
-
interface NavbarProps {
|
80
|
-
settings?: Partial<NavbarSettings>;
|
81
|
-
variant?: NavbarVariant;
|
82
|
-
linkIndicator?: (isHovering: boolean) => IndicatorProps;
|
83
|
-
logoIndicator?: (isHovering: boolean) => IndicatorProps;
|
84
|
-
onLogout?: () => void;
|
85
|
-
}
|
86
84
|
interface WidgetConfiguration {
|
87
85
|
widgetId: string;
|
88
86
|
name: string;
|
@@ -105,6 +103,34 @@ interface HydrationStatus {
|
|
105
103
|
hasHydrated: boolean;
|
106
104
|
ensureHydration: <T>(v: T) => T | undefined;
|
107
105
|
}
|
106
|
+
declare enum LayoutType {
|
107
|
+
Frame = "frame"
|
108
|
+
}
|
109
|
+
declare enum FrameLayoutSection {
|
110
|
+
Top = "top",
|
111
|
+
Bottom = "bottom",
|
112
|
+
Left = "left",
|
113
|
+
Right = "right",
|
114
|
+
Content = "content"
|
115
|
+
}
|
116
|
+
type Layout<T extends LayoutType> = T extends LayoutType.Frame ? {
|
117
|
+
sections: Record<Exclude<FrameLayoutSection, FrameLayoutSection.Content>, HTMLDivElement | null>
|
118
|
+
} : never;
|
119
|
+
interface LayoutsContext {
|
120
|
+
layouts: Record<string, Layout<LayoutType>>;
|
121
|
+
setLayouts: Dispatch<SetStateAction<Record<string, Layout<LayoutType>>>>;
|
122
|
+
}
|
123
|
+
type FrameLayoutContext = {
|
124
|
+
layoutId: string | null
|
125
|
+
layout: Layout<LayoutType.Frame>
|
126
|
+
setLayout: Dispatch<SetStateAction<Layout<LayoutType.Frame>>>
|
127
|
+
};
|
128
|
+
declare enum FrameLayoutVariant {
|
129
|
+
Plain = "plain",
|
130
|
+
Sticky = "sticky"
|
131
|
+
}
|
132
|
+
type FrameLayoutNavbarPosition<T extends NavbarVariant> = T extends NavbarVariant.Minimal ? FrameLayoutSection.Left | FrameLayoutSection.Right : FrameLayoutSection;
|
133
|
+
type FrameLayoutFooterPosition<T extends FooterVariant> = T extends FooterVariant.Minimal ? FrameLayoutSection.Content | FrameLayoutSection.Bottom : FrameLayoutSection;
|
108
134
|
interface WidgetsContext {
|
109
135
|
widgets: {
|
110
136
|
[index: string]: {
|
@@ -143,6 +169,12 @@ declare const useHydratedMantineColorScheme: () => {
|
|
143
169
|
};
|
144
170
|
interface HydrationStatusProviderProps {}
|
145
171
|
declare function HydrationStatusProvider({ children }: PropsWithChildren3<HydrationStatusProviderProps>): ReactNode4;
|
172
|
+
declare const defaultLayoutsContext: {
|
173
|
+
layouts: {}
|
174
|
+
setLayouts: () => void
|
175
|
+
};
|
176
|
+
declare const useLayouts: () => LayoutsContext;
|
177
|
+
interface LayoutsProviderProps {}
|
146
178
|
interface RemoraidProviderProps {
|
147
179
|
theme?: ThemeProviderProps["theme"];
|
148
180
|
initialUserExperience?: UserExperienceProviderProps<CoreUserExperience>["initialValue"];
|
@@ -152,26 +184,155 @@ interface RemoraidProviderProps {
|
|
152
184
|
WidgetsProvider?: Partial<WidgetsProviderProps>
|
153
185
|
CookiesProvider?: Partial<ReactCookieProps>
|
154
186
|
HydrationStatusProviderProps?: Partial<HydrationStatusProviderProps>
|
187
|
+
LayoutsProviderProps?: Partial<LayoutsProviderProps>
|
155
188
|
};
|
156
189
|
}
|
157
|
-
declare function RemoraidProvider({ children, theme, initialUserExperience, componentsProps }:
|
158
|
-
import {
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
190
|
+
declare function RemoraidProvider({ children, theme, initialUserExperience, componentsProps }: PropsWithChildren5<RemoraidProviderProps>): ReactNode6;
|
191
|
+
import { BoxProps as BoxProps3 } from "@mantine/core";
|
192
|
+
import { IndicatorProps, PaperProps } from "@mantine/core";
|
193
|
+
import { Icon as Icon2 } from "@tabler/icons-react";
|
194
|
+
import { ReactNode as ReactNode7 } from "react";
|
195
|
+
interface NavbarLinkProps {
|
196
|
+
label: string;
|
197
|
+
linkSize: string;
|
198
|
+
iconSize: string;
|
199
|
+
icon?: Icon2;
|
200
|
+
indicator?: (isHovering: boolean) => IndicatorProps;
|
201
|
+
href?: string;
|
202
|
+
active?: boolean;
|
203
|
+
onClick?(): void;
|
204
|
+
}
|
205
|
+
interface NavbarMinimalProps {
|
206
|
+
linkSize?: string;
|
207
|
+
iconSize?: string;
|
208
|
+
linkIndicator?: (isHovering: boolean) => IndicatorProps;
|
209
|
+
logoIndicator?: (isHovering: boolean) => IndicatorProps;
|
210
|
+
componentsProps?: {
|
211
|
+
container?: Partial<PaperProps>
|
212
|
+
link?: Partial<NavbarLinkProps>
|
213
|
+
};
|
214
|
+
}
|
215
|
+
declare function NavbarMinimal({ linkSize, iconSize, linkIndicator, logoIndicator, componentsProps }: NavbarMinimalProps): ReactNode7;
|
216
|
+
import { GroupProps } from "@mantine/core";
|
217
|
+
import { IconProps as IconProps2 } from "@tabler/icons-react";
|
218
|
+
import { ReactNode as ReactNode8 } from "react";
|
219
|
+
interface FooterMinimalProps {
|
220
|
+
componentsProps?: {
|
221
|
+
container?: Partial<GroupProps>
|
222
|
+
icon?: Partial<IconProps2>
|
223
|
+
};
|
224
|
+
}
|
225
|
+
declare function FooterMinimal({ componentsProps }: FooterMinimalProps): ReactNode8;
|
226
|
+
import { PropsWithChildren as PropsWithChildren9, ReactNode as ReactNode12 } from "react";
|
227
|
+
import { PropsWithChildren as PropsWithChildren6, ReactNode as ReactNode9 } from "react";
|
228
|
+
declare const defaultAppContext: RemoraidAppContext<CustomAppVariables>;
|
229
|
+
declare const useRemoraidApp: () => RemoraidAppContext<CustomAppVariables>;
|
230
|
+
interface AppProviderProps<V extends CustomAppVariables = {}> {
|
231
|
+
appContext: AppContextProps<V>;
|
232
|
+
}
|
233
|
+
declare function AppProvider2<V extends CustomAppVariables = {}>({ appContext: appContextProps, children }: PropsWithChildren6<AppProviderProps<V>>): ReactNode9;
|
234
|
+
import { ReactElement } from "react";
|
235
|
+
type Common<
|
236
|
+
A,
|
237
|
+
B
|
238
|
+
> = Pick<A & B, keyof A & keyof B>;
|
239
|
+
type OnlyChildrenOf<
|
240
|
+
T extends (...args: any) => any,
|
241
|
+
P = any
|
242
|
+
> = ReactElement<P, T> | ReactElement<P, T>[];
|
243
|
+
type Optional<
|
244
|
+
T,
|
245
|
+
K extends keyof T
|
246
|
+
> = Omit<T, K> & Partial<Pick<T, K>>;
|
247
|
+
type OptionalIfExtends<
|
248
|
+
T,
|
249
|
+
K extends keyof T,
|
250
|
+
V1,
|
251
|
+
V2
|
252
|
+
> = [V1] extends [V2] ? Optional<T, K> : T;
|
253
|
+
import { BoxProps as BoxProps2, GroupProps as GroupProps2, ScrollAreaProps as ScrollAreaProps2, StackProps } from "@mantine/core";
|
254
|
+
import { PropsWithChildren as PropsWithChildren8, ReactNode as ReactNode11 } from "react";
|
255
|
+
import { PropsWithChildren as PropsWithChildren7, ReactNode as ReactNode10 } from "react";
|
256
|
+
import { BoxProps } from "@mantine/core";
|
257
|
+
interface FrameLayoutElementProps {
|
258
|
+
section: Exclude<FrameLayoutSection, FrameLayoutSection.Content>;
|
259
|
+
includeContainer?: boolean;
|
260
|
+
layoutId?: string;
|
261
|
+
componentsProps?: {
|
262
|
+
container?: Partial<BoxProps>
|
263
|
+
};
|
264
|
+
}
|
265
|
+
declare function Element2({ section, includeContainer, layoutId, componentsProps, children }: PropsWithChildren7<FrameLayoutElementProps>): ReactNode10;
|
266
|
+
declare const isFrameLayout: (layout: Layout<LayoutType>) => layout is Layout<LayoutType.Frame>;
|
267
|
+
type DefaultFrameLayoutVariant = FrameLayoutVariant.Sticky;
|
268
|
+
declare const defaultFrameLayoutContext: FrameLayoutContext;
|
269
|
+
declare const useFrameLayout: () => FrameLayoutContext;
|
270
|
+
interface FrameLayoutPropsWithExplicitVariant<T extends FrameLayoutVariant> {
|
271
|
+
variant: T;
|
272
|
+
layoutId: string;
|
273
|
+
componentsProps?: {
|
274
|
+
childrenContainer?: T extends FrameLayoutVariant.Plain ? Partial<BoxProps2> : T extends FrameLayoutVariant.Sticky ? Partial<ScrollAreaProps2> : never
|
275
|
+
horizontalContainer?: Partial<GroupProps2>
|
276
|
+
verticalContainer?: Partial<StackProps>
|
277
|
+
sectionContainers?: {
|
278
|
+
[FrameLayoutSection.Left]?: Partial<GroupProps2>
|
279
|
+
[FrameLayoutSection.Right]?: Partial<GroupProps2>
|
280
|
+
[FrameLayoutSection.Top]?: Partial<StackProps>
|
281
|
+
[FrameLayoutSection.Bottom]?: Partial<StackProps>
|
282
|
+
}
|
283
|
+
};
|
284
|
+
}
|
285
|
+
type FrameLayoutProps<T extends FrameLayoutVariant = DefaultFrameLayoutVariant> = T extends DefaultFrameLayoutVariant ? Optional<FrameLayoutPropsWithExplicitVariant<T>, "variant"> : FrameLayoutPropsWithExplicitVariant<T>;
|
286
|
+
declare function FrameLayout<T extends FrameLayoutVariant = DefaultFrameLayoutVariant>({ variant, layoutId, componentsProps, children }: PropsWithChildren8<FrameLayoutProps<T>>): ReactNode11;
|
287
|
+
interface FrameLayout {
|
288
|
+
<T extends FrameLayoutVariant = DefaultFrameLayoutVariant>(props: PropsWithChildren8<FrameLayoutProps<T>>): ReactNode11;
|
289
|
+
Element: typeof Element2;
|
290
|
+
}
|
291
|
+
declare const _default: FrameLayout;
|
292
|
+
declare const defaultAppShellLayoutId = "remoraidAppShell";
|
293
|
+
type AppShellNavbarVariant = NavbarVariant | null;
|
294
|
+
type AppShellFooterVariant = FooterVariant | null;
|
295
|
+
type DefaultNavbarVariant = null;
|
296
|
+
type DefaultFooterVariant = null;
|
297
|
+
interface ExplicitAppShellProps<
|
298
|
+
N extends AppShellNavbarVariant,
|
299
|
+
F extends AppShellFooterVariant,
|
300
|
+
V extends CustomAppVariables
|
301
|
+
> {
|
302
|
+
navbarVariant: N;
|
303
|
+
footerVariant: F;
|
304
|
+
navbarPosition: N extends NavbarVariant ? FrameLayoutNavbarPosition<N> : never;
|
305
|
+
footerPosition: F extends FooterVariant ? FrameLayoutFooterPosition<F> : never;
|
306
|
+
appContext: AppContextProps<V>;
|
307
|
+
componentsProps?: {
|
308
|
+
navbar?: N extends NavbarVariant.Minimal ? Partial<NavbarMinimalProps> : never
|
309
|
+
footer?: N extends FooterVariant.Minimal ? Partial<FooterMinimalProps> : never
|
310
|
+
layout?: Partial<FrameLayoutProps<FrameLayoutVariant.Sticky>>
|
311
|
+
childrenContainer?: Partial<BoxProps3>
|
312
|
+
AppProvider?: Partial<AppProviderProps>
|
313
|
+
};
|
314
|
+
}
|
315
|
+
type AppShellProps<
|
316
|
+
N extends AppShellNavbarVariant = DefaultNavbarVariant,
|
317
|
+
F extends AppShellFooterVariant = DefaultFooterVariant,
|
318
|
+
V extends CustomAppVariables = {}
|
319
|
+
> = OptionalIfExtends<OptionalIfExtends<ExplicitAppShellProps<N, F, V>, "footerVariant", F, DefaultFooterVariant>, "navbarVariant", N, DefaultNavbarVariant>;
|
320
|
+
declare function AppShell<
|
321
|
+
N extends AppShellNavbarVariant = DefaultNavbarVariant,
|
322
|
+
F extends AppShellFooterVariant = DefaultFooterVariant,
|
323
|
+
V extends CustomAppVariables = {}
|
324
|
+
>(props: PropsWithChildren9<AppShellProps<N, F, V>>): ReactNode12;
|
325
|
+
interface AppShell {
|
326
|
+
<
|
327
|
+
N extends AppShellNavbarVariant = DefaultNavbarVariant,
|
328
|
+
F extends AppShellFooterVariant = DefaultFooterVariant,
|
329
|
+
V extends CustomAppVariables = {}
|
330
|
+
>(props: PropsWithChildren9<AppShellProps<N, F, V>>): ReactNode12;
|
331
|
+
NavbarMinimal: typeof NavbarMinimal;
|
332
|
+
FooterMinimal: typeof FooterMinimal;
|
333
|
+
}
|
334
|
+
declare const _default2: AppShell;
|
335
|
+
import { Context, PropsWithChildren as PropsWithChildren10, ReactNode as ReactNode13 } from "react";
|
175
336
|
declare const createUserExperienceContext: <T extends UserExperience>(defaultUserExperience: T) => Context<UserExperienceContext<T>>;
|
176
337
|
interface UserExperienceProviderWrapperProps<T extends UserExperience> {
|
177
338
|
context: Context<UserExperienceContext<T>>;
|
@@ -180,28 +341,27 @@ interface UserExperienceProviderWrapperProps<T extends UserExperience> {
|
|
180
341
|
isValidUserExperience: (x: unknown) => x is T;
|
181
342
|
initialValue?: Partial<T>;
|
182
343
|
}
|
183
|
-
declare function UserExperienceProviderWrapper<T extends UserExperience>({ children, context, cookieName, defaultUserExperience, isValidUserExperience, initialValue }:
|
184
|
-
declare const defaultNavbarSettings: Record<NavbarVariant, NavbarSettings>;
|
344
|
+
declare function UserExperienceProviderWrapper<T extends UserExperience>({ children, context, cookieName, defaultUserExperience, isValidUserExperience, initialValue }: PropsWithChildren10<UserExperienceProviderWrapperProps<T>>): ReactNode13;
|
185
345
|
declare const defaultUserExperience: CoreUserExperience;
|
186
346
|
declare const defaultUserExperienceCookieName = "remoraid-core-user-experience";
|
187
347
|
declare const useRemoraidUserExperience: () => UserExperienceContext<CoreUserExperience>;
|
188
348
|
import { MantineSize as MantineSize2 } from "@mantine/core";
|
189
|
-
import { ReactNode as
|
349
|
+
import { ReactNode as ReactNode15 } from "react";
|
190
350
|
interface WidgetSelectionHeaderProps {
|
191
351
|
title?: string;
|
192
352
|
disabledWidgets?: string[];
|
193
353
|
mt?: MantineSize2 | number;
|
194
354
|
}
|
195
|
-
declare function WidgetSelectionHeader({ title, disabledWidgets, mt }: WidgetSelectionHeaderProps):
|
196
|
-
import { ReactNode as
|
355
|
+
declare function WidgetSelectionHeader({ title, disabledWidgets, mt }: WidgetSelectionHeaderProps): ReactNode15;
|
356
|
+
import { ReactNode as ReactNode16 } from "react";
|
197
357
|
interface CloseButtonProps {
|
198
358
|
widgetId: string;
|
199
359
|
}
|
200
|
-
declare function CloseButton2({ widgetId }: CloseButtonProps):
|
360
|
+
declare function CloseButton2({ widgetId }: CloseButtonProps): ReactNode16;
|
201
361
|
import { BadgeProps as BadgeProps2, MantineBreakpoint as MantineBreakpoint2, MantineSize as MantineSize3, TooltipProps as TooltipProps2 } from "@mantine/core";
|
202
|
-
import { ReactNode as
|
362
|
+
import { ReactNode as ReactNode18 } from "react";
|
203
363
|
import { BadgeProps, TooltipProps, TransitionProps } from "@mantine/core";
|
204
|
-
import { ReactNode as
|
364
|
+
import { ReactNode as ReactNode17 } from "react";
|
205
365
|
interface BadgeMinimalProps {
|
206
366
|
label: string;
|
207
367
|
tooltip?: string;
|
@@ -212,9 +372,9 @@ interface BadgeMinimalProps {
|
|
212
372
|
tooltip?: TooltipProps
|
213
373
|
};
|
214
374
|
}
|
215
|
-
declare function BadgeMinimal(props: BadgeMinimalProps):
|
375
|
+
declare function BadgeMinimal(props: BadgeMinimalProps): ReactNode17;
|
216
376
|
interface BadgeGroupProps {
|
217
|
-
badges: (BadgeMinimalProps |
|
377
|
+
badges: (BadgeMinimalProps | ReactNode18)[];
|
218
378
|
gap?: MantineSize3 | number;
|
219
379
|
breakpoint?: MantineBreakpoint2;
|
220
380
|
componentsProps?: {
|
@@ -222,9 +382,9 @@ interface BadgeGroupProps {
|
|
222
382
|
cumulativeBadge?: Partial<Omit<BadgeProps2, "hiddenFrom" | "circle">>
|
223
383
|
};
|
224
384
|
}
|
225
|
-
declare function BadgeGroup({ badges, gap, breakpoint, componentsProps }: BadgeGroupProps):
|
385
|
+
declare function BadgeGroup({ badges, gap, breakpoint, componentsProps }: BadgeGroupProps): ReactNode18;
|
226
386
|
import { AlertProps as AlertProps2, MantineSize as MantineSize4, TransitionProps as TransitionProps2 } from "@mantine/core";
|
227
|
-
import { PropsWithChildren as
|
387
|
+
import { PropsWithChildren as PropsWithChildren12, ReactNode as ReactNode19 } from "react";
|
228
388
|
interface AlertMinimalProps {
|
229
389
|
category: AlertCategory;
|
230
390
|
title?: string;
|
@@ -238,19 +398,10 @@ interface AlertMinimalProps {
|
|
238
398
|
transition?: Omit<TransitionProps2, "mounted">
|
239
399
|
};
|
240
400
|
}
|
241
|
-
declare function AlertMinimal({ children, title, category, text, onClose, mounted, mt, mb, componentsProps }:
|
401
|
+
declare function AlertMinimal({ children, title, category, text, onClose, mounted, mt, mb, componentsProps }: PropsWithChildren12<AlertMinimalProps>): ReactNode19;
|
242
402
|
import { ActionIconProps, ActionIconVariant, ButtonProps, ButtonVariant, MantineBreakpoint as MantineBreakpoint3, MantineColor, MantineSize as MantineSize5, TooltipProps as TooltipProps3 } from "@mantine/core";
|
243
|
-
import { Icon as
|
244
|
-
import { ReactNode as
|
245
|
-
import { ReactElement } from "react";
|
246
|
-
type Common<
|
247
|
-
A,
|
248
|
-
B
|
249
|
-
> = Pick<A & B, keyof A & keyof B>;
|
250
|
-
type OnlyChildrenOf<
|
251
|
-
T extends (...args: any) => any,
|
252
|
-
P = any
|
253
|
-
> = ReactElement<P, T> | ReactElement<P, T>[];
|
403
|
+
import { Icon as Icon3, IconProps as IconProps3 } from "@tabler/icons-react";
|
404
|
+
import { ReactNode as ReactNode20 } from "react";
|
254
405
|
interface RemoraidButtonProps {
|
255
406
|
label: string;
|
256
407
|
responsive?: boolean;
|
@@ -258,23 +409,23 @@ interface RemoraidButtonProps {
|
|
258
409
|
collapsed?: boolean;
|
259
410
|
size?: MantineSize5;
|
260
411
|
color?: MantineColor;
|
261
|
-
icon?:
|
412
|
+
icon?: Icon3;
|
262
413
|
onClick?: () => void;
|
263
414
|
loading?: boolean;
|
264
415
|
variant?: Extract<ButtonVariant, ActionIconVariant>;
|
265
416
|
componentsProps?: {
|
266
417
|
tooltip?: Partial<TooltipProps3>
|
267
|
-
icon?: Partial<
|
418
|
+
icon?: Partial<IconProps3>
|
268
419
|
button?: Omit<Partial<Common<ButtonProps, ActionIconProps>>, "variant" | "onClick" | "size" | "color" | "loading">
|
269
420
|
Button?: Partial<ButtonProps>
|
270
421
|
ActionIcon?: Partial<ActionIconProps>
|
271
422
|
};
|
272
423
|
}
|
273
|
-
declare function RemoraidButton({ label, responsive, breakpoint, collapsed, size, color, onClick, loading, variant, componentsProps,...props }: RemoraidButtonProps):
|
274
|
-
import { MantineSize as MantineSize6, PaperProps, TransitionProps as TransitionProps3 } from "@mantine/core";
|
275
|
-
import { PropsWithChildren as
|
424
|
+
declare function RemoraidButton({ label, responsive, breakpoint, collapsed, size, color, onClick, loading, variant, componentsProps,...props }: RemoraidButtonProps): ReactNode20;
|
425
|
+
import { MantineSize as MantineSize6, PaperProps as PaperProps2, TransitionProps as TransitionProps3 } from "@mantine/core";
|
426
|
+
import { PropsWithChildren as PropsWithChildren13, ReactNode as ReactNode21 } from "react";
|
276
427
|
interface WidgetWrapperComponentsProps {
|
277
|
-
container?: Partial<
|
428
|
+
container?: Partial<PaperProps2>;
|
278
429
|
transition?: Partial<Omit<TransitionProps3, "mounted">>;
|
279
430
|
}
|
280
431
|
interface WidgetWrapperProps {
|
@@ -283,13 +434,13 @@ interface WidgetWrapperProps {
|
|
283
434
|
withCloseButton?: boolean;
|
284
435
|
componentsProps?: WidgetWrapperComponentsProps;
|
285
436
|
}
|
286
|
-
declare function WidgetWrapper({ children, config, mt, withCloseButton, componentsProps }:
|
287
|
-
interface WidgetWrapper extends React.FC<
|
437
|
+
declare function WidgetWrapper({ children, config, mt, withCloseButton, componentsProps }: PropsWithChildren13<WidgetWrapperProps>): ReactNode21;
|
438
|
+
interface WidgetWrapper extends React.FC<PropsWithChildren13<WidgetWrapperProps>> {
|
288
439
|
CloseButton: typeof CloseButton2;
|
289
440
|
}
|
290
|
-
declare const
|
441
|
+
declare const _default3: WidgetWrapper;
|
291
442
|
import { MantineSize as MantineSize7, LoaderProps } from "@mantine/core";
|
292
|
-
import { PropsWithChildren as
|
443
|
+
import { PropsWithChildren as PropsWithChildren14, ReactNode as ReactNode22 } from "react";
|
293
444
|
interface WidgetComponentsProps extends WidgetWrapperComponentsProps {
|
294
445
|
wrapper?: Partial<Omit<WidgetWrapperProps, "widgetId">>;
|
295
446
|
loader?: Partial<LoaderProps>;
|
@@ -299,9 +450,9 @@ interface WidgetProps {
|
|
299
450
|
id: string;
|
300
451
|
title: string;
|
301
452
|
config?: Partial<Omit<WidgetConfiguration, "widgetId">>;
|
302
|
-
badges?: (BadgeMinimalProps |
|
303
|
-
buttons?: (RemoraidButtonProps |
|
304
|
-
alerts?: (AlertMinimalProps |
|
453
|
+
badges?: (BadgeMinimalProps | ReactNode22)[];
|
454
|
+
buttons?: (RemoraidButtonProps | ReactNode22)[];
|
455
|
+
alerts?: (AlertMinimalProps | ReactNode22)[];
|
305
456
|
gaps?: MantineSize7 | number | {
|
306
457
|
badges?: MantineSize7 | number
|
307
458
|
buttons?: MantineSize7 | number
|
@@ -311,9 +462,9 @@ interface WidgetProps {
|
|
311
462
|
mt?: MantineSize7 | number;
|
312
463
|
componentsProps?: WidgetComponentsProps;
|
313
464
|
}
|
314
|
-
declare function Widget({ children, id, config, title, badges, buttons, alerts, gaps, loading, mt, componentsProps }:
|
465
|
+
declare function Widget({ children, id, config, title, badges, buttons, alerts, gaps, loading, mt, componentsProps }: PropsWithChildren14<WidgetProps>): ReactNode22;
|
315
466
|
import { ContainerProps, MantineSize as MantineSize8 } from "@mantine/core";
|
316
|
-
import { PropsWithChildren as
|
467
|
+
import { PropsWithChildren as PropsWithChildren15, ReactNode as ReactNode23 } from "react";
|
317
468
|
declare const usePage: () => PageConfiguration | null;
|
318
469
|
interface PageProps {
|
319
470
|
name?: string;
|
@@ -323,26 +474,26 @@ interface PageProps {
|
|
323
474
|
container?: ContainerProps
|
324
475
|
};
|
325
476
|
}
|
326
|
-
declare function Page({ children, name, config, pt, componentsProps }:
|
477
|
+
declare function Page({ children, name, config, pt, componentsProps }: PropsWithChildren15<PageProps>): ReactNode23;
|
327
478
|
import { ContainerProps as ContainerProps2, MantineSize as MantineSize9 } from "@mantine/core";
|
328
|
-
import { PropsWithChildren as
|
479
|
+
import { PropsWithChildren as PropsWithChildren16, ReactNode as ReactNode24 } from "react";
|
329
480
|
interface PageContainerProps {
|
330
481
|
pt?: MantineSize9 | number;
|
331
482
|
componentsProps?: {
|
332
483
|
container?: ContainerProps2
|
333
484
|
};
|
334
485
|
}
|
335
|
-
declare function PageContainer({ children, pt, componentsProps }:
|
336
|
-
import { PropsWithChildren as
|
486
|
+
declare function PageContainer({ children, pt, componentsProps }: PropsWithChildren16<PageContainerProps>): ReactNode24;
|
487
|
+
import { PropsWithChildren as PropsWithChildren17, ReactNode as ReactNode25 } from "react";
|
337
488
|
interface NotFoundPageProps {
|
338
489
|
message?: string;
|
339
490
|
componentsProps?: {
|
340
491
|
page?: PageProps
|
341
492
|
};
|
342
493
|
}
|
343
|
-
declare function NotFoundPage({ children, message, componentsProps }:
|
494
|
+
declare function NotFoundPage({ children, message, componentsProps }: PropsWithChildren17<NotFoundPageProps>): ReactNode25;
|
344
495
|
import { ContainerProps as ContainerProps3, MantineSize as MantineSize10 } from "@mantine/core";
|
345
|
-
import { PropsWithChildren as
|
496
|
+
import { PropsWithChildren as PropsWithChildren18, ReactNode as ReactNode26 } from "react";
|
346
497
|
interface EnvironmentShellProps {
|
347
498
|
environment: Record<string, string | undefined>;
|
348
499
|
message?: string;
|
@@ -353,19 +504,19 @@ interface EnvironmentShellProps {
|
|
353
504
|
container?: ContainerProps3
|
354
505
|
};
|
355
506
|
}
|
356
|
-
declare function EnvironmentShell({ children, environment, message, m, mt, withContainer, componentsProps }:
|
357
|
-
import { PropsWithChildren as
|
358
|
-
import { ReactNode as
|
359
|
-
import { GroupProps } from "@mantine/core";
|
507
|
+
declare function EnvironmentShell({ children, environment, message, m, mt, withContainer, componentsProps }: PropsWithChildren18<EnvironmentShellProps>): ReactNode26;
|
508
|
+
import { PropsWithChildren as PropsWithChildren19, ReactNode as ReactNode28 } from "react";
|
509
|
+
import { ReactNode as ReactNode27 } from "react";
|
510
|
+
import { GroupProps as GroupProps3 } from "@mantine/core";
|
360
511
|
interface SettingsWidgetSaveButtonProps {
|
361
512
|
onSaveChanges: () => void;
|
362
513
|
insideContainer?: boolean;
|
363
514
|
componentsProps?: {
|
364
|
-
container?: Partial<
|
515
|
+
container?: Partial<GroupProps3>
|
365
516
|
button?: Partial<RemoraidButtonProps>
|
366
517
|
};
|
367
518
|
}
|
368
|
-
declare function SaveButton2({ onSaveChanges, insideContainer, componentsProps }: SettingsWidgetSaveButtonProps):
|
519
|
+
declare function SaveButton2({ onSaveChanges, insideContainer, componentsProps }: SettingsWidgetSaveButtonProps): ReactNode27;
|
369
520
|
declare const defaultSettingsWidgetContext: {};
|
370
521
|
declare const useSettingsWidgetContext: () => SettingsWidgetContext;
|
371
522
|
interface SettingsWidgetProps {
|
@@ -374,17 +525,17 @@ interface SettingsWidgetProps {
|
|
374
525
|
custom?: boolean;
|
375
526
|
widgetProps?: Partial<WidgetProps>;
|
376
527
|
}
|
377
|
-
declare function SettingsWidget({ children, onRestoreDefaultValues, unsavedChanges, custom, widgetProps }:
|
378
|
-
interface SettingsWidget extends React.FC<
|
528
|
+
declare function SettingsWidget({ children, onRestoreDefaultValues, unsavedChanges, custom, widgetProps }: PropsWithChildren19<SettingsWidgetProps>): ReactNode28;
|
529
|
+
interface SettingsWidget extends React.FC<PropsWithChildren19<SettingsWidgetProps>> {
|
379
530
|
SaveButton: typeof SaveButton2;
|
380
531
|
}
|
381
|
-
declare const
|
382
|
-
import { ReactNode as
|
383
|
-
import { PropsWithChildren as
|
532
|
+
declare const _default4: SettingsWidget;
|
533
|
+
import { ReactNode as ReactNode30 } from "react";
|
534
|
+
import { PropsWithChildren as PropsWithChildren20, ReactNode as ReactNode29 } from "react";
|
384
535
|
interface SettingsTableRowProps {
|
385
536
|
label: string;
|
386
537
|
}
|
387
|
-
declare function Row2({ children, label }:
|
538
|
+
declare function Row2({ children, label }: PropsWithChildren20<SettingsTableRowProps>): ReactNode29;
|
388
539
|
declare const defaultSettingsTableOptions: {
|
389
540
|
leftColumnWidth: string
|
390
541
|
};
|
@@ -393,33 +544,33 @@ interface SettingsTableProps {
|
|
393
544
|
children: OnlyChildrenOf<typeof Row2, SettingsTableRowProps>;
|
394
545
|
leftColumnWidth?: string | number;
|
395
546
|
}
|
396
|
-
declare function SettingsTable({ children, leftColumnWidth }: SettingsTableProps):
|
547
|
+
declare function SettingsTable({ children, leftColumnWidth }: SettingsTableProps): ReactNode30;
|
397
548
|
interface SettingsTable extends React.FC<SettingsTableProps> {
|
398
549
|
Row: typeof Row2;
|
399
550
|
}
|
400
|
-
declare const
|
401
|
-
import { ReactElement as ReactElement2, ReactNode as
|
551
|
+
declare const _default5: SettingsTable;
|
552
|
+
import { ReactElement as ReactElement2, ReactNode as ReactNode31 } from "react";
|
402
553
|
declare const defaultNavbarSettingsWidgetId = "navbar-settings";
|
403
554
|
interface NavbarSettingsWidgetProps {
|
404
|
-
additionalRows?: ReactElement2<SettingsTableRowProps, typeof
|
555
|
+
additionalRows?: ReactElement2<SettingsTableRowProps, typeof _default5.Row>[];
|
405
556
|
widgetProps?: Partial<WidgetProps>;
|
406
557
|
componentsProps?: {
|
407
558
|
table: Partial<Omit<SettingsTableProps, "children">>
|
408
559
|
};
|
409
560
|
}
|
410
|
-
declare function NavbarSettingsWidget({ additionalRows, widgetProps, componentsProps }: NavbarSettingsWidgetProps):
|
411
|
-
import { Chip, ChipGroupProps, ChipProps, FlexProps, MantineSize as MantineSize11, ScrollAreaProps as
|
412
|
-
import { ReactNode as
|
561
|
+
declare function NavbarSettingsWidget({ additionalRows, widgetProps, componentsProps }: NavbarSettingsWidgetProps): ReactNode31;
|
562
|
+
import { Chip, ChipGroupProps, ChipProps, FlexProps, MantineSize as MantineSize11, ScrollAreaProps as ScrollAreaProps3 } from "@mantine/core";
|
563
|
+
import { ReactNode as ReactNode32 } from "react";
|
413
564
|
interface ScrollbleChipGroupProps {
|
414
565
|
value: string[];
|
415
566
|
onChange?: (value: string[]) => void;
|
416
567
|
gap?: MantineSize11 | number;
|
417
568
|
componentsProps?: {
|
418
569
|
chipGroup?: Partial<ChipGroupProps<true>>
|
419
|
-
scrollArea?: Partial<
|
570
|
+
scrollArea?: Partial<ScrollAreaProps3>
|
420
571
|
container?: Partial<FlexProps>
|
421
572
|
};
|
422
573
|
children?: OnlyChildrenOf<typeof Chip, ChipProps>;
|
423
574
|
}
|
424
|
-
declare function ScrollableChipGroup({ value, onChange, gap, componentsProps, children }: ScrollbleChipGroupProps):
|
425
|
-
export { useWidgets, useSettingsWidgetContext as useSettingsWidgetOptions, useSettingsTableOptions, useRemoraidUserExperience, useRemoraidTheme, useRemoraidApp, usePage, useHydrationStatus, useHydratedMantineColorScheme, defaultUserExperienceCookieName, defaultUserExperience, defaultSettingsWidgetContext as defaultSettingsWidgetOptions, defaultSettingsTableOptions, defaultNavbarSettingsWidgetId,
|
575
|
+
declare function ScrollableChipGroup({ value, onChange, gap, componentsProps, children }: ScrollbleChipGroupProps): ReactNode32;
|
576
|
+
export { useWidgets, useSettingsWidgetContext as useSettingsWidgetOptions, useSettingsTableOptions, useRemoraidUserExperience, useRemoraidTheme, useRemoraidApp, usePage, useLayouts, useHydrationStatus, useHydratedMantineColorScheme, useFrameLayout, isFrameLayout, defaultUserExperienceCookieName, defaultUserExperience, defaultSettingsWidgetContext as defaultSettingsWidgetOptions, defaultSettingsTableOptions, defaultNavbarSettingsWidgetId, defaultLayoutsContext, defaultFrameLayoutContext, defaultAppShellLayoutId, defaultAppContext, createUserExperienceContext, createRemoraidTheme, WidgetsProviderProps, WidgetWrapperProps, _default3 as WidgetWrapper, WidgetSelectionHeaderProps, WidgetSelectionHeader, WidgetProps, WidgetConfiguration, Widget, UserExperienceProviderWrapperProps, UserExperienceProviderWrapper, UserExperienceProviderProps, UserExperienceContext, UserExperience, TransitionDuration, ThemeProviderProps, StaticRemoraidAppContext, SettingsWidgetSaveButtonProps, SettingsWidgetProps, SettingsWidgetContext, _default4 as SettingsWidget, SettingsTableRowProps, SettingsTableOptions, _default5 as SettingsTable, ScrollbleChipGroupProps, ScrollableChipGroup, RemoraidUser, RemoraidThemeDependencies, RemoraidThemeCallback, RemoraidTheme, RemoraidProviderProps, RemoraidProvider, RemoraidIconSize, RemoraidButtonProps, RemoraidButton, RemoraidBreakpoint, RemoraidAuthContext, RemoraidAppContext, PageProps, PageContainerProps, PageContainer, PageConfiguration, Page, NotFoundPageProps, NotFoundPage, NavbarVariant, NavbarSettingsWidgetProps, NavbarSettingsWidget, NavbarMinimalProps, LayoutsProviderProps, LayoutsContext, LayoutType, Layout, HydrationStatusProviderProps, HydrationStatusProvider, HydrationStatus, FrameLayoutVariant, FrameLayoutSection, FrameLayoutProps, FrameLayoutNavbarPosition, FrameLayoutFooterPosition, FrameLayoutElementProps, FrameLayoutContext, _default as FrameLayout, FooterVariant, FooterMinimalProps, EnvironmentShellProps, EnvironmentShell, DefaultNavbarVariant, DefaultFrameLayoutVariant, DefaultFooterVariant, CustomAppVariables, CoreUserExperience, CloseButtonProps, BadgeMinimalProps, BadgeMinimal, BadgeGroupProps, BadgeGroup, AppShellProps, AppShellNavbarVariant, AppShellFooterVariant, _default2 as AppShell, AppProviderProps, AppProvider2 as AppProvider, AppLogo, AppContextProps, AlertMinimalProps, AlertMinimal, AlertCategory };
|