@weaverse/react 0.7.57 → 0.7.58
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/index.d.ts +40 -4
- package/dist/index.js +609 -391
- package/dist/index.mjs +601 -383
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { WeaverseType, Weaverse, ElementCSS, WeaverseItemStore, WeaverseElement } from '@weaverse/core';
|
|
2
2
|
export * from '@weaverse/core';
|
|
3
3
|
import * as React$1 from 'react';
|
|
4
|
-
import React__default, { HTMLAttributes, ReactElement, ReactNode
|
|
4
|
+
import React__default, { HTMLAttributes, CSSProperties, ReactElement, ReactNode } from 'react';
|
|
5
5
|
import * as _radix_ui_react_dialog from '@radix-ui/react-dialog';
|
|
6
6
|
import { DialogContentProps, DialogProps, DialogTitleProps, DialogCloseProps } from '@radix-ui/react-dialog';
|
|
7
7
|
import { KeenSliderInstance } from 'keen-slider';
|
|
@@ -65,6 +65,23 @@ interface SliderArrowsProps {
|
|
|
65
65
|
instanceRef: React.MutableRefObject<KeenSliderInstance | null>;
|
|
66
66
|
className?: string;
|
|
67
67
|
}
|
|
68
|
+
interface SliderDotsProps {
|
|
69
|
+
currentSlide: number;
|
|
70
|
+
instanceRef: React.MutableRefObject<KeenSliderInstance | null>;
|
|
71
|
+
className?: string;
|
|
72
|
+
}
|
|
73
|
+
interface OverlayProps {
|
|
74
|
+
enableOverlay: boolean;
|
|
75
|
+
overlayOpacity: number;
|
|
76
|
+
className?: string;
|
|
77
|
+
}
|
|
78
|
+
interface BackgroundProps {
|
|
79
|
+
backgroundColor?: string;
|
|
80
|
+
backgroundImage?: string;
|
|
81
|
+
backgroundFit?: CSSProperties['objectFit'];
|
|
82
|
+
backgroundPosition?: CSSProperties['objectPosition'];
|
|
83
|
+
className?: string;
|
|
84
|
+
}
|
|
68
85
|
|
|
69
86
|
interface WeaverseElementProps extends Partial<ReactElement> {
|
|
70
87
|
css?: ElementCSS;
|
|
@@ -184,6 +201,19 @@ type InstagramMedia = {
|
|
|
184
201
|
caption: string;
|
|
185
202
|
thumbnail_url: string;
|
|
186
203
|
};
|
|
204
|
+
interface SlideshowProps extends WeaverseElementProps {
|
|
205
|
+
animation: 'slide' | 'fade';
|
|
206
|
+
slidesPerView: number;
|
|
207
|
+
spacing: number;
|
|
208
|
+
showArrows: boolean;
|
|
209
|
+
showDots: boolean;
|
|
210
|
+
dotsPosition: 'top' | 'bottom' | 'left' | 'right';
|
|
211
|
+
autoRotate: boolean;
|
|
212
|
+
changeSlidesEvery: number;
|
|
213
|
+
}
|
|
214
|
+
interface SlideProps extends WeaverseElementProps, BackgroundProps, OverlayProps {
|
|
215
|
+
contentPosition: string;
|
|
216
|
+
}
|
|
187
217
|
|
|
188
218
|
declare let Modal: (props: DialogProps) => JSX.Element;
|
|
189
219
|
declare let ModalTrigger: React__default.ForwardRefExoticComponent<_radix_ui_react_dialog.DialogTriggerProps & React__default.RefAttributes<HTMLButtonElement>>;
|
|
@@ -214,11 +244,17 @@ declare function Tooltip({ children }: TooltipProps): JSX.Element;
|
|
|
214
244
|
|
|
215
245
|
declare function Slider({ children, className, gap }: SliderProps): JSX.Element;
|
|
216
246
|
|
|
247
|
+
declare function Background(props: BackgroundProps): JSX.Element | null;
|
|
248
|
+
|
|
249
|
+
declare function Overlay(props: OverlayProps): JSX.Element | null;
|
|
250
|
+
|
|
217
251
|
declare let Components: {
|
|
252
|
+
Background: typeof Background;
|
|
253
|
+
Icon: typeof Icon;
|
|
254
|
+
ModalComponents: typeof ModalComponents;
|
|
255
|
+
Overlay: typeof Overlay;
|
|
218
256
|
Placeholder: React$1.ForwardRefExoticComponent<PlaceholderProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
219
257
|
Spinner: typeof Spinner;
|
|
220
|
-
ModalComponents: typeof ModalComponents;
|
|
221
|
-
Icon: typeof Icon;
|
|
222
258
|
Slider: typeof Slider;
|
|
223
259
|
Tooltip: typeof Tooltip;
|
|
224
260
|
};
|
|
@@ -227,4 +263,4 @@ declare const Elements: Record<string, WeaverseElement>;
|
|
|
227
263
|
|
|
228
264
|
declare let WeaverseRoot: ({ context }: WeaverseRootPropsType) => JSX.Element | null;
|
|
229
265
|
|
|
230
|
-
export { ButtonElementProps, Components, ContainerElementProps, CountdownElementProps, CountdownTimeKey, CountdownTimerType, Elements, GridContentElementProps, ImageElementProps, InstagramElementProps, InstagramMedia, ItemComponentProps, LayoutBackgroundProps, LayoutElementProps, MapElementProps, ModalContentProps, PlaceholderProps, SliderArrowsProps, SliderProps, TextElementProps, TimerBlockProps, TooltipProps, VideoCommonProps, VideoElementProps, VimeoElementProps, WeaverseContext, WeaverseContextConsumer, WeaverseContextProvider, WeaverseElementProps, WeaverseIcon, WeaverseIconProps, WeaverseRoot, WeaverseRootPropsType, YoutubeElementProps, createRootContext };
|
|
266
|
+
export { BackgroundProps, ButtonElementProps, Components, ContainerElementProps, CountdownElementProps, CountdownTimeKey, CountdownTimerType, Elements, GridContentElementProps, ImageElementProps, InstagramElementProps, InstagramMedia, ItemComponentProps, LayoutBackgroundProps, LayoutElementProps, MapElementProps, ModalContentProps, OverlayProps, PlaceholderProps, SlideProps, SliderArrowsProps, SliderDotsProps, SliderProps, SlideshowProps, TextElementProps, TimerBlockProps, TooltipProps, VideoCommonProps, VideoElementProps, VimeoElementProps, WeaverseContext, WeaverseContextConsumer, WeaverseContextProvider, WeaverseElementProps, WeaverseIcon, WeaverseIconProps, WeaverseRoot, WeaverseRootPropsType, YoutubeElementProps, createRootContext };
|