canvu-react 0.4.42 → 0.4.44
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/native.cjs +480 -63
- package/dist/native.cjs.map +1 -1
- package/dist/native.d.cts +46 -3
- package/dist/native.d.ts +46 -3
- package/dist/native.js +480 -64
- package/dist/native.js.map +1 -1
- package/dist/realtime.cjs +82 -12
- package/dist/realtime.cjs.map +1 -1
- package/dist/realtime.js +82 -12
- package/dist/realtime.js.map +1 -1
- package/dist/realtimeNative.cjs +85 -15
- package/dist/realtimeNative.cjs.map +1 -1
- package/dist/realtimeNative.js +85 -15
- package/dist/realtimeNative.js.map +1 -1
- package/package.json +1 -1
package/dist/native.d.cts
CHANGED
|
@@ -4,10 +4,53 @@ import { C as Camera2D, S as StrokeStyle } from './shape-builders-CKEMjivV.cjs';
|
|
|
4
4
|
export { o as createFreehandStrokeItem, q as createImageItem, t as createShapeId } from './shape-builders-CKEMjivV.cjs';
|
|
5
5
|
import { V as VectorSceneItem, R as Rect } from './types-BCCvY6ie.cjs';
|
|
6
6
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
7
|
-
import { R as RemotePresencePeer } from './types-BQUbxMgz.cjs';
|
|
8
|
-
import { StyleProp, ViewStyle, TextStyle } from 'react-native';
|
|
9
7
|
import * as react from 'react';
|
|
10
8
|
import { ReactNode } from 'react';
|
|
9
|
+
import { StyleProp, ViewStyle, TextStyle } from 'react-native';
|
|
10
|
+
import { R as RemotePresencePeer } from './types-BQUbxMgz.cjs';
|
|
11
|
+
|
|
12
|
+
type NativeImagesMenuLabels = {
|
|
13
|
+
title?: string;
|
|
14
|
+
focus?: string;
|
|
15
|
+
duplicate?: string;
|
|
16
|
+
copy?: string;
|
|
17
|
+
rotate?: string;
|
|
18
|
+
delete?: string;
|
|
19
|
+
collapse?: string;
|
|
20
|
+
expand?: string;
|
|
21
|
+
};
|
|
22
|
+
type NativeImagesMenuProps = {
|
|
23
|
+
readonly items: readonly VectorSceneItem[];
|
|
24
|
+
readonly onItemsChange: (items: VectorSceneItem[]) => void;
|
|
25
|
+
readonly onFocusItem?: (item: VectorSceneItem) => void;
|
|
26
|
+
readonly labels?: NativeImagesMenuLabels;
|
|
27
|
+
readonly defaultOpen?: boolean;
|
|
28
|
+
readonly style?: StyleProp<ViewStyle>;
|
|
29
|
+
readonly panelStyle?: StyleProp<ViewStyle>;
|
|
30
|
+
readonly collapsedButtonStyle?: StyleProp<ViewStyle>;
|
|
31
|
+
readonly rowStyle?: StyleProp<ViewStyle>;
|
|
32
|
+
readonly actionButtonStyle?: StyleProp<ViewStyle>;
|
|
33
|
+
readonly getImageUri?: (item: VectorSceneItem) => string | null | undefined;
|
|
34
|
+
readonly renderThumbnail?: (item: VectorSceneItem) => ReactNode;
|
|
35
|
+
};
|
|
36
|
+
/**
|
|
37
|
+
* React Native companion to the web `ImagesMenu` component.
|
|
38
|
+
*
|
|
39
|
+
* Use this for floating mobile page/image management controls that should look
|
|
40
|
+
* and behave like the web `ImagesMenu`: a compact button when collapsed and a
|
|
41
|
+
* small anchored panel with managed image thumbnails plus duplicate, rotate,
|
|
42
|
+
* delete, and focus actions when expanded.
|
|
43
|
+
*
|
|
44
|
+
* @example
|
|
45
|
+
* ```tsx
|
|
46
|
+
* <NativeImagesMenu
|
|
47
|
+
* items={items}
|
|
48
|
+
* onItemsChange={setItems}
|
|
49
|
+
* onFocusItem={(item) => viewportRef.current?.fitWorldRect(item.bounds)}
|
|
50
|
+
* />
|
|
51
|
+
* ```
|
|
52
|
+
*/
|
|
53
|
+
declare function NativeImagesMenu({ items, onItemsChange, onFocusItem, labels, defaultOpen, style, panelStyle, collapsedButtonStyle, rowStyle, actionButtonStyle, getImageUri, renderThumbnail, }: NativeImagesMenuProps): react_jsx_runtime.JSX.Element | null;
|
|
11
54
|
|
|
12
55
|
type TimedTrailPoint = {
|
|
13
56
|
readonly x: number;
|
|
@@ -457,4 +500,4 @@ type SvgNode = SvgRectNode | SvgEllipseNode | SvgCircleNode | SvgLineNode | SvgP
|
|
|
457
500
|
*/
|
|
458
501
|
declare function parseSvgFragment(xml: string): SvgNode[];
|
|
459
502
|
|
|
460
|
-
export { CanvuLinkData, DEFAULT_NATIVE_OVERFLOW_TOOL_IDS, DEFAULT_NATIVE_VECTOR_TOOLS, NATIVE_STYLE_PALETTE, type NativeCustomShapePlacementOptions, NativeInteractionOverlay, type NativeInteractionOverlayProps, type NativeLinkToolDialogLabels, type NativeLinkToolInsertOptions, type NativeLinkToolRequestDetail, type NativeRemotePresencePressDetail, NativeSceneRenderer, type NativeSceneRendererProps, NativeShapeRenderer, type NativeShapeRendererProps, type NativeStyleColor, NativeVectorStyleInspector, type NativeVectorStyleInspectorProps, type NativeVectorStyleToolId, type NativeVectorToolDefinition, NativeVectorToolbar, type NativeVectorToolbarDensity, type NativeVectorToolbarProps, type NativeVectorToolbarRenderOverflowInput, type NativeVectorToolbarRenderToolInput, type NativeVectorToolbarRenderToolLockInput, NativeVectorViewport, type NativeVectorViewportHandle, type NativeVectorViewportProps, type NativeWorldPointerDownDetail, type PlacementPreview, type SvgNode, VectorSceneItem, nativeStyleColorWithOpacity, normalizeNativeStyleHex, parseSvgFragment };
|
|
503
|
+
export { CanvuLinkData, DEFAULT_NATIVE_OVERFLOW_TOOL_IDS, DEFAULT_NATIVE_VECTOR_TOOLS, NATIVE_STYLE_PALETTE, type NativeCustomShapePlacementOptions, NativeImagesMenu, type NativeImagesMenuLabels, type NativeImagesMenuProps, NativeInteractionOverlay, type NativeInteractionOverlayProps, type NativeLinkToolDialogLabels, type NativeLinkToolInsertOptions, type NativeLinkToolRequestDetail, type NativeRemotePresencePressDetail, NativeSceneRenderer, type NativeSceneRendererProps, NativeShapeRenderer, type NativeShapeRendererProps, type NativeStyleColor, NativeVectorStyleInspector, type NativeVectorStyleInspectorProps, type NativeVectorStyleToolId, type NativeVectorToolDefinition, NativeVectorToolbar, type NativeVectorToolbarDensity, type NativeVectorToolbarProps, type NativeVectorToolbarRenderOverflowInput, type NativeVectorToolbarRenderToolInput, type NativeVectorToolbarRenderToolLockInput, NativeVectorViewport, type NativeVectorViewportHandle, type NativeVectorViewportProps, type NativeWorldPointerDownDetail, type PlacementPreview, type SvgNode, VectorSceneItem, nativeStyleColorWithOpacity, normalizeNativeStyleHex, parseSvgFragment };
|
package/dist/native.d.ts
CHANGED
|
@@ -4,10 +4,53 @@ import { C as Camera2D, S as StrokeStyle } from './shape-builders-Cyh8zvDG.js';
|
|
|
4
4
|
export { o as createFreehandStrokeItem, q as createImageItem, t as createShapeId } from './shape-builders-Cyh8zvDG.js';
|
|
5
5
|
import { V as VectorSceneItem, R as Rect } from './types-BCCvY6ie.js';
|
|
6
6
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
7
|
-
import { R as RemotePresencePeer } from './types-B82WiQQh.js';
|
|
8
|
-
import { StyleProp, ViewStyle, TextStyle } from 'react-native';
|
|
9
7
|
import * as react from 'react';
|
|
10
8
|
import { ReactNode } from 'react';
|
|
9
|
+
import { StyleProp, ViewStyle, TextStyle } from 'react-native';
|
|
10
|
+
import { R as RemotePresencePeer } from './types-B82WiQQh.js';
|
|
11
|
+
|
|
12
|
+
type NativeImagesMenuLabels = {
|
|
13
|
+
title?: string;
|
|
14
|
+
focus?: string;
|
|
15
|
+
duplicate?: string;
|
|
16
|
+
copy?: string;
|
|
17
|
+
rotate?: string;
|
|
18
|
+
delete?: string;
|
|
19
|
+
collapse?: string;
|
|
20
|
+
expand?: string;
|
|
21
|
+
};
|
|
22
|
+
type NativeImagesMenuProps = {
|
|
23
|
+
readonly items: readonly VectorSceneItem[];
|
|
24
|
+
readonly onItemsChange: (items: VectorSceneItem[]) => void;
|
|
25
|
+
readonly onFocusItem?: (item: VectorSceneItem) => void;
|
|
26
|
+
readonly labels?: NativeImagesMenuLabels;
|
|
27
|
+
readonly defaultOpen?: boolean;
|
|
28
|
+
readonly style?: StyleProp<ViewStyle>;
|
|
29
|
+
readonly panelStyle?: StyleProp<ViewStyle>;
|
|
30
|
+
readonly collapsedButtonStyle?: StyleProp<ViewStyle>;
|
|
31
|
+
readonly rowStyle?: StyleProp<ViewStyle>;
|
|
32
|
+
readonly actionButtonStyle?: StyleProp<ViewStyle>;
|
|
33
|
+
readonly getImageUri?: (item: VectorSceneItem) => string | null | undefined;
|
|
34
|
+
readonly renderThumbnail?: (item: VectorSceneItem) => ReactNode;
|
|
35
|
+
};
|
|
36
|
+
/**
|
|
37
|
+
* React Native companion to the web `ImagesMenu` component.
|
|
38
|
+
*
|
|
39
|
+
* Use this for floating mobile page/image management controls that should look
|
|
40
|
+
* and behave like the web `ImagesMenu`: a compact button when collapsed and a
|
|
41
|
+
* small anchored panel with managed image thumbnails plus duplicate, rotate,
|
|
42
|
+
* delete, and focus actions when expanded.
|
|
43
|
+
*
|
|
44
|
+
* @example
|
|
45
|
+
* ```tsx
|
|
46
|
+
* <NativeImagesMenu
|
|
47
|
+
* items={items}
|
|
48
|
+
* onItemsChange={setItems}
|
|
49
|
+
* onFocusItem={(item) => viewportRef.current?.fitWorldRect(item.bounds)}
|
|
50
|
+
* />
|
|
51
|
+
* ```
|
|
52
|
+
*/
|
|
53
|
+
declare function NativeImagesMenu({ items, onItemsChange, onFocusItem, labels, defaultOpen, style, panelStyle, collapsedButtonStyle, rowStyle, actionButtonStyle, getImageUri, renderThumbnail, }: NativeImagesMenuProps): react_jsx_runtime.JSX.Element | null;
|
|
11
54
|
|
|
12
55
|
type TimedTrailPoint = {
|
|
13
56
|
readonly x: number;
|
|
@@ -457,4 +500,4 @@ type SvgNode = SvgRectNode | SvgEllipseNode | SvgCircleNode | SvgLineNode | SvgP
|
|
|
457
500
|
*/
|
|
458
501
|
declare function parseSvgFragment(xml: string): SvgNode[];
|
|
459
502
|
|
|
460
|
-
export { CanvuLinkData, DEFAULT_NATIVE_OVERFLOW_TOOL_IDS, DEFAULT_NATIVE_VECTOR_TOOLS, NATIVE_STYLE_PALETTE, type NativeCustomShapePlacementOptions, NativeInteractionOverlay, type NativeInteractionOverlayProps, type NativeLinkToolDialogLabels, type NativeLinkToolInsertOptions, type NativeLinkToolRequestDetail, type NativeRemotePresencePressDetail, NativeSceneRenderer, type NativeSceneRendererProps, NativeShapeRenderer, type NativeShapeRendererProps, type NativeStyleColor, NativeVectorStyleInspector, type NativeVectorStyleInspectorProps, type NativeVectorStyleToolId, type NativeVectorToolDefinition, NativeVectorToolbar, type NativeVectorToolbarDensity, type NativeVectorToolbarProps, type NativeVectorToolbarRenderOverflowInput, type NativeVectorToolbarRenderToolInput, type NativeVectorToolbarRenderToolLockInput, NativeVectorViewport, type NativeVectorViewportHandle, type NativeVectorViewportProps, type NativeWorldPointerDownDetail, type PlacementPreview, type SvgNode, VectorSceneItem, nativeStyleColorWithOpacity, normalizeNativeStyleHex, parseSvgFragment };
|
|
503
|
+
export { CanvuLinkData, DEFAULT_NATIVE_OVERFLOW_TOOL_IDS, DEFAULT_NATIVE_VECTOR_TOOLS, NATIVE_STYLE_PALETTE, type NativeCustomShapePlacementOptions, NativeImagesMenu, type NativeImagesMenuLabels, type NativeImagesMenuProps, NativeInteractionOverlay, type NativeInteractionOverlayProps, type NativeLinkToolDialogLabels, type NativeLinkToolInsertOptions, type NativeLinkToolRequestDetail, type NativeRemotePresencePressDetail, NativeSceneRenderer, type NativeSceneRendererProps, NativeShapeRenderer, type NativeShapeRendererProps, type NativeStyleColor, NativeVectorStyleInspector, type NativeVectorStyleInspectorProps, type NativeVectorStyleToolId, type NativeVectorToolDefinition, NativeVectorToolbar, type NativeVectorToolbarDensity, type NativeVectorToolbarProps, type NativeVectorToolbarRenderOverflowInput, type NativeVectorToolbarRenderToolInput, type NativeVectorToolbarRenderToolLockInput, NativeVectorViewport, type NativeVectorViewportHandle, type NativeVectorViewportProps, type NativeWorldPointerDownDetail, type PlacementPreview, type SvgNode, VectorSceneItem, nativeStyleColorWithOpacity, normalizeNativeStyleHex, parseSvgFragment };
|