@papyrus-sdk/ui-react-native 0.2.13-beta.0 → 0.2.15
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/README.md +2 -2
- package/dist/index.d.mts +23 -3
- package/dist/index.d.ts +23 -3
- package/dist/index.js +1511 -1280
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1501 -1274
- package/dist/index.mjs.map +1 -1
- package/package.json +11 -7
package/README.md
CHANGED
|
@@ -5,10 +5,10 @@ React Native UI components for Papyrus viewers.
|
|
|
5
5
|
## Install
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
npm install @papyrus-sdk/ui-react-native @papyrus-sdk/engine-native @papyrus-sdk/core @papyrus-sdk/types react-native-gesture-handler
|
|
8
|
+
npm install @papyrus-sdk/ui-react-native @papyrus-sdk/engine-native @papyrus-sdk/core @papyrus-sdk/types react-native-gesture-handler react-native-reanimated
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
`@papyrus-sdk/core`, `@papyrus-sdk/types`,
|
|
11
|
+
`@papyrus-sdk/core`, `@papyrus-sdk/types`, `react-native-gesture-handler`, and `react-native-reanimated` are required peer dependencies.
|
|
12
12
|
|
|
13
13
|
Wrap the app root with `GestureHandlerRootView` before rendering Papyrus components:
|
|
14
14
|
|
package/dist/index.d.mts
CHANGED
|
@@ -43,6 +43,7 @@ interface TopbarProps {
|
|
|
43
43
|
onLogoPress?: () => void;
|
|
44
44
|
logoAccessibilityLabel?: string;
|
|
45
45
|
showPageNavigationControls?: boolean;
|
|
46
|
+
onOpenPageJump?: () => void;
|
|
46
47
|
}
|
|
47
48
|
declare const Topbar: React.FC<TopbarProps>;
|
|
48
49
|
|
|
@@ -52,6 +53,7 @@ interface RightSheetProps {
|
|
|
52
53
|
engine: DocumentEngine;
|
|
53
54
|
documentType: DocumentType;
|
|
54
55
|
thumbsInitialCount?: number;
|
|
56
|
+
onOpenPageJump?: () => void;
|
|
55
57
|
}
|
|
56
58
|
declare const RightSheet: React.FC<RightSheetProps>;
|
|
57
59
|
|
|
@@ -61,7 +63,7 @@ type BottomBarProps = {
|
|
|
61
63
|
documentType: DocumentType;
|
|
62
64
|
onOpenInfo: () => void;
|
|
63
65
|
onOpenSettings: () => void;
|
|
64
|
-
onOpenDestination
|
|
66
|
+
onOpenDestination?: (destination: MobilePrimaryDestination) => void;
|
|
65
67
|
};
|
|
66
68
|
declare const BottomBar: React.FC<BottomBarProps>;
|
|
67
69
|
|
|
@@ -123,8 +125,9 @@ declare function DocumentActionsSheet({ visible, onClose, }: DocumentActionsShee
|
|
|
123
125
|
type ProgressPillProps = {
|
|
124
126
|
documentType: DocumentType;
|
|
125
127
|
onPress: () => void;
|
|
128
|
+
onOpenPageJump?: () => void;
|
|
126
129
|
};
|
|
127
|
-
declare function ProgressPill({ documentType, onPress }: ProgressPillProps): react_jsx_runtime.JSX.Element;
|
|
130
|
+
declare function ProgressPill({ documentType, onPress, onOpenPageJump, }: ProgressPillProps): react_jsx_runtime.JSX.Element;
|
|
128
131
|
|
|
129
132
|
type SearchOverlayProps = {
|
|
130
133
|
engine: DocumentEngine;
|
|
@@ -142,4 +145,21 @@ type SearchResultsSheetProps = {
|
|
|
142
145
|
};
|
|
143
146
|
declare function SearchResultsSheet({ documentType, visible, onClose, }: SearchResultsSheetProps): react_jsx_runtime.JSX.Element;
|
|
144
147
|
|
|
145
|
-
|
|
148
|
+
declare const MOBILE_CHROME_METRICS: {
|
|
149
|
+
readonly screenPadding: 16;
|
|
150
|
+
readonly maxFloatingWidth: 360;
|
|
151
|
+
readonly maxToolDockWidth: 420;
|
|
152
|
+
readonly toolDockPaddingTop: 4;
|
|
153
|
+
readonly toolDockHistoryIconSize: 18;
|
|
154
|
+
readonly toolDockHistoryGap: 2;
|
|
155
|
+
readonly toolDockDisabledIconColorDark: "#64748b";
|
|
156
|
+
readonly toolDockDisabledIconColorLight: "#6b7280";
|
|
157
|
+
readonly toolDockDisabledOpacity: 0.72;
|
|
158
|
+
readonly iconSize: 20;
|
|
159
|
+
readonly iconBoxSize: 28;
|
|
160
|
+
readonly topbarPageButtonSize: 30;
|
|
161
|
+
readonly bottomBarItemPaddingHorizontal: 5;
|
|
162
|
+
readonly bottomBarItemPaddingVertical: 3;
|
|
163
|
+
};
|
|
164
|
+
|
|
165
|
+
export { AnnotationEditor, BottomBar, CoverPreview, DocumentActionsSheet, InfoSheet, MOBILE_CHROME_METRICS, OverflowSheet, _default as PageRenderer, ProgressPill, ReadingShell, RightSheet, SearchOverlay, SearchResultsSheet, SettingsSheet, ToolDock, Topbar, Viewer };
|
package/dist/index.d.ts
CHANGED
|
@@ -43,6 +43,7 @@ interface TopbarProps {
|
|
|
43
43
|
onLogoPress?: () => void;
|
|
44
44
|
logoAccessibilityLabel?: string;
|
|
45
45
|
showPageNavigationControls?: boolean;
|
|
46
|
+
onOpenPageJump?: () => void;
|
|
46
47
|
}
|
|
47
48
|
declare const Topbar: React.FC<TopbarProps>;
|
|
48
49
|
|
|
@@ -52,6 +53,7 @@ interface RightSheetProps {
|
|
|
52
53
|
engine: DocumentEngine;
|
|
53
54
|
documentType: DocumentType;
|
|
54
55
|
thumbsInitialCount?: number;
|
|
56
|
+
onOpenPageJump?: () => void;
|
|
55
57
|
}
|
|
56
58
|
declare const RightSheet: React.FC<RightSheetProps>;
|
|
57
59
|
|
|
@@ -61,7 +63,7 @@ type BottomBarProps = {
|
|
|
61
63
|
documentType: DocumentType;
|
|
62
64
|
onOpenInfo: () => void;
|
|
63
65
|
onOpenSettings: () => void;
|
|
64
|
-
onOpenDestination
|
|
66
|
+
onOpenDestination?: (destination: MobilePrimaryDestination) => void;
|
|
65
67
|
};
|
|
66
68
|
declare const BottomBar: React.FC<BottomBarProps>;
|
|
67
69
|
|
|
@@ -123,8 +125,9 @@ declare function DocumentActionsSheet({ visible, onClose, }: DocumentActionsShee
|
|
|
123
125
|
type ProgressPillProps = {
|
|
124
126
|
documentType: DocumentType;
|
|
125
127
|
onPress: () => void;
|
|
128
|
+
onOpenPageJump?: () => void;
|
|
126
129
|
};
|
|
127
|
-
declare function ProgressPill({ documentType, onPress }: ProgressPillProps): react_jsx_runtime.JSX.Element;
|
|
130
|
+
declare function ProgressPill({ documentType, onPress, onOpenPageJump, }: ProgressPillProps): react_jsx_runtime.JSX.Element;
|
|
128
131
|
|
|
129
132
|
type SearchOverlayProps = {
|
|
130
133
|
engine: DocumentEngine;
|
|
@@ -142,4 +145,21 @@ type SearchResultsSheetProps = {
|
|
|
142
145
|
};
|
|
143
146
|
declare function SearchResultsSheet({ documentType, visible, onClose, }: SearchResultsSheetProps): react_jsx_runtime.JSX.Element;
|
|
144
147
|
|
|
145
|
-
|
|
148
|
+
declare const MOBILE_CHROME_METRICS: {
|
|
149
|
+
readonly screenPadding: 16;
|
|
150
|
+
readonly maxFloatingWidth: 360;
|
|
151
|
+
readonly maxToolDockWidth: 420;
|
|
152
|
+
readonly toolDockPaddingTop: 4;
|
|
153
|
+
readonly toolDockHistoryIconSize: 18;
|
|
154
|
+
readonly toolDockHistoryGap: 2;
|
|
155
|
+
readonly toolDockDisabledIconColorDark: "#64748b";
|
|
156
|
+
readonly toolDockDisabledIconColorLight: "#6b7280";
|
|
157
|
+
readonly toolDockDisabledOpacity: 0.72;
|
|
158
|
+
readonly iconSize: 20;
|
|
159
|
+
readonly iconBoxSize: 28;
|
|
160
|
+
readonly topbarPageButtonSize: 30;
|
|
161
|
+
readonly bottomBarItemPaddingHorizontal: 5;
|
|
162
|
+
readonly bottomBarItemPaddingVertical: 3;
|
|
163
|
+
};
|
|
164
|
+
|
|
165
|
+
export { AnnotationEditor, BottomBar, CoverPreview, DocumentActionsSheet, InfoSheet, MOBILE_CHROME_METRICS, OverflowSheet, _default as PageRenderer, ProgressPill, ReadingShell, RightSheet, SearchOverlay, SearchResultsSheet, SettingsSheet, ToolDock, Topbar, Viewer };
|