@papyrus-sdk/ui-react-native 0.2.21 → 0.2.22
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.mts +16 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.js +57 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +141 -83
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -21617,6 +21617,7 @@ import {
|
|
|
21617
21617
|
} from "react";
|
|
21618
21618
|
import {
|
|
21619
21619
|
View,
|
|
21620
|
+
Text,
|
|
21620
21621
|
StyleSheet,
|
|
21621
21622
|
Pressable,
|
|
21622
21623
|
PanResponder,
|
|
@@ -21626,7 +21627,10 @@ import {
|
|
|
21626
21627
|
} from "react-native";
|
|
21627
21628
|
import { Gesture, GestureDetector } from "react-native-gesture-handler";
|
|
21628
21629
|
import Svg, { Path as SvgPath } from "react-native-svg";
|
|
21629
|
-
import { useViewerStore } from "@papyrus-sdk/core";
|
|
21630
|
+
import { papyrusEvents, useViewerStore } from "@papyrus-sdk/core";
|
|
21631
|
+
import {
|
|
21632
|
+
PapyrusEventType
|
|
21633
|
+
} from "@papyrus-sdk/types";
|
|
21630
21634
|
import {
|
|
21631
21635
|
PapyrusPageView
|
|
21632
21636
|
} from "@papyrus-sdk/engine-native";
|
|
@@ -21897,6 +21901,14 @@ var resolvePdfBasePageWidth = ({
|
|
|
21897
21901
|
horizontalPadding
|
|
21898
21902
|
}) => Math.max(0, viewportWidth - horizontalPadding * 2);
|
|
21899
21903
|
|
|
21904
|
+
// components/selectionEvent.ts
|
|
21905
|
+
var notifyTextSelection = (handler, payload) => {
|
|
21906
|
+
const text = payload.text.replace(/\s+/g, " ").trim();
|
|
21907
|
+
if (!text) return false;
|
|
21908
|
+
handler?.({ ...payload, text });
|
|
21909
|
+
return Boolean(handler);
|
|
21910
|
+
};
|
|
21911
|
+
|
|
21900
21912
|
// components/PageRenderer.tsx
|
|
21901
21913
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
21902
21914
|
var TEXT_MARKUP_TOOLS = /* @__PURE__ */ new Set([
|
|
@@ -21971,6 +21983,8 @@ var PageRenderer = ({
|
|
|
21971
21983
|
horizontalPadding = 16,
|
|
21972
21984
|
spacing = 24,
|
|
21973
21985
|
onSelectionDragActiveChange,
|
|
21986
|
+
onTextSelected,
|
|
21987
|
+
onDefineSelection,
|
|
21974
21988
|
gestureScrollLockActive = false,
|
|
21975
21989
|
lastPinchEndedAt = null,
|
|
21976
21990
|
requestSelectionVerticalAutoscroll
|
|
@@ -22316,6 +22330,17 @@ var PageRenderer = ({
|
|
|
22316
22330
|
return;
|
|
22317
22331
|
}
|
|
22318
22332
|
const selectedText = selection.text || "";
|
|
22333
|
+
const normalizedText = selectedText.replace(/\s+/g, " ").trim();
|
|
22334
|
+
if (normalizedText) {
|
|
22335
|
+
papyrusEvents.emit(PapyrusEventType.TEXT_SELECTED, {
|
|
22336
|
+
text: normalizedText,
|
|
22337
|
+
pageIndex
|
|
22338
|
+
});
|
|
22339
|
+
}
|
|
22340
|
+
notifyTextSelection(onTextSelected, {
|
|
22341
|
+
text: normalizedText,
|
|
22342
|
+
pageIndex
|
|
22343
|
+
});
|
|
22319
22344
|
logSelectionPerf("selection.ready", {
|
|
22320
22345
|
tool: activeTool,
|
|
22321
22346
|
sourceRectCount: selection.rects.length,
|
|
@@ -23251,6 +23276,20 @@ var PageRenderer = ({
|
|
|
23251
23276
|
}
|
|
23252
23277
|
],
|
|
23253
23278
|
children: [
|
|
23279
|
+
onDefineSelection ? /* @__PURE__ */ jsx(
|
|
23280
|
+
Pressable,
|
|
23281
|
+
{
|
|
23282
|
+
onPress: (event) => {
|
|
23283
|
+
stopPressPropagation(event);
|
|
23284
|
+
onDefineSelection({
|
|
23285
|
+
text: selectionText,
|
|
23286
|
+
pageIndex
|
|
23287
|
+
});
|
|
23288
|
+
},
|
|
23289
|
+
style: [styles.selectionAction, styles.defineSelectionAction],
|
|
23290
|
+
children: /* @__PURE__ */ jsx(Text, { style: styles.defineSelectionText, children: "Definir" })
|
|
23291
|
+
}
|
|
23292
|
+
) : null,
|
|
23254
23293
|
/* @__PURE__ */ jsx(
|
|
23255
23294
|
Pressable,
|
|
23256
23295
|
{
|
|
@@ -23550,6 +23589,15 @@ var styles = StyleSheet.create({
|
|
|
23550
23589
|
justifyContent: "center",
|
|
23551
23590
|
marginRight: 10
|
|
23552
23591
|
},
|
|
23592
|
+
defineSelectionAction: {
|
|
23593
|
+
width: 58,
|
|
23594
|
+
paddingHorizontal: 6
|
|
23595
|
+
},
|
|
23596
|
+
defineSelectionText: {
|
|
23597
|
+
color: "#FFFFFF",
|
|
23598
|
+
fontSize: 11,
|
|
23599
|
+
fontWeight: "700"
|
|
23600
|
+
},
|
|
23553
23601
|
selectionActionLast: {
|
|
23554
23602
|
marginRight: 0
|
|
23555
23603
|
},
|
|
@@ -23581,7 +23629,7 @@ var styles = StyleSheet.create({
|
|
|
23581
23629
|
borderRadius: 3
|
|
23582
23630
|
}
|
|
23583
23631
|
});
|
|
23584
|
-
var arePageRendererPropsEqual = (previous, next) => previous.engine === next.engine && previous.pageIndex === next.pageIndex && previous.scale === next.scale && previous.PageViewComponent === next.PageViewComponent && previous.availableWidth === next.availableWidth && previous.pageViewportWidth === next.pageViewportWidth && previous.horizontalPadding === next.horizontalPadding && previous.spacing === next.spacing && previous.onSelectionDragActiveChange === next.onSelectionDragActiveChange && previous.gestureScrollLockActive === next.gestureScrollLockActive && previous.lastPinchEndedAt === next.lastPinchEndedAt && previous.requestSelectionVerticalAutoscroll === next.requestSelectionVerticalAutoscroll;
|
|
23632
|
+
var arePageRendererPropsEqual = (previous, next) => previous.engine === next.engine && previous.pageIndex === next.pageIndex && previous.scale === next.scale && previous.PageViewComponent === next.PageViewComponent && previous.availableWidth === next.availableWidth && previous.pageViewportWidth === next.pageViewportWidth && previous.horizontalPadding === next.horizontalPadding && previous.spacing === next.spacing && previous.onSelectionDragActiveChange === next.onSelectionDragActiveChange && previous.onTextSelected === next.onTextSelected && previous.onDefineSelection === next.onDefineSelection && previous.gestureScrollLockActive === next.gestureScrollLockActive && previous.lastPinchEndedAt === next.lastPinchEndedAt && previous.requestSelectionVerticalAutoscroll === next.requestSelectionVerticalAutoscroll;
|
|
23585
23633
|
var PageRenderer_default = memo(PageRenderer, arePageRendererPropsEqual);
|
|
23586
23634
|
|
|
23587
23635
|
// components/WebViewViewer.tsx
|
|
@@ -24744,7 +24792,9 @@ var Viewer = ({
|
|
|
24744
24792
|
maxToRenderPerBatch,
|
|
24745
24793
|
removeClippedSubviews,
|
|
24746
24794
|
useDedicatedAndroidPdfViewer,
|
|
24747
|
-
viewerMode
|
|
24795
|
+
viewerMode,
|
|
24796
|
+
onTextSelected,
|
|
24797
|
+
onDefineSelection
|
|
24748
24798
|
}) => {
|
|
24749
24799
|
const pageCount = useViewerStore4((state) => state.pageCount);
|
|
24750
24800
|
const currentPage = useViewerStore4((state) => state.currentPage);
|
|
@@ -25880,6 +25930,8 @@ var Viewer = ({
|
|
|
25880
25930
|
pageViewportWidth: columnWidth,
|
|
25881
25931
|
spacing: DOUBLE_PAGE_SPACING,
|
|
25882
25932
|
onSelectionDragActiveChange: setSelectionDragActive,
|
|
25933
|
+
onTextSelected,
|
|
25934
|
+
onDefineSelection,
|
|
25883
25935
|
gestureScrollLockActive,
|
|
25884
25936
|
lastPinchEndedAt,
|
|
25885
25937
|
requestSelectionVerticalAutoscroll: handleSelectionVerticalAutoscroll
|
|
@@ -25896,6 +25948,8 @@ var Viewer = ({
|
|
|
25896
25948
|
pageViewportWidth: columnWidth,
|
|
25897
25949
|
spacing: DOUBLE_PAGE_SPACING,
|
|
25898
25950
|
onSelectionDragActiveChange: setSelectionDragActive,
|
|
25951
|
+
onTextSelected,
|
|
25952
|
+
onDefineSelection,
|
|
25899
25953
|
gestureScrollLockActive,
|
|
25900
25954
|
lastPinchEndedAt,
|
|
25901
25955
|
requestSelectionVerticalAutoscroll: handleSelectionVerticalAutoscroll
|
|
@@ -25915,6 +25969,8 @@ var Viewer = ({
|
|
|
25915
25969
|
pageViewportWidth: documentSurfaceWidth,
|
|
25916
25970
|
spacing: CONTINUOUS_PAGE_SPACING,
|
|
25917
25971
|
onSelectionDragActiveChange: setSelectionDragActive,
|
|
25972
|
+
onTextSelected,
|
|
25973
|
+
onDefineSelection,
|
|
25918
25974
|
gestureScrollLockActive,
|
|
25919
25975
|
lastPinchEndedAt,
|
|
25920
25976
|
requestSelectionVerticalAutoscroll: handleSelectionVerticalAutoscroll
|
|
@@ -26004,6 +26060,8 @@ var Viewer = ({
|
|
|
26004
26060
|
pageViewportWidth: documentSurfaceWidth,
|
|
26005
26061
|
spacing: 32,
|
|
26006
26062
|
onSelectionDragActiveChange: setSelectionDragActive,
|
|
26063
|
+
onTextSelected,
|
|
26064
|
+
onDefineSelection,
|
|
26007
26065
|
gestureScrollLockActive,
|
|
26008
26066
|
lastPinchEndedAt,
|
|
26009
26067
|
requestSelectionVerticalAutoscroll: handleSelectionVerticalAutoscroll
|
|
@@ -26141,7 +26199,7 @@ var Viewer_default = Viewer;
|
|
|
26141
26199
|
|
|
26142
26200
|
// components/Topbar.tsx
|
|
26143
26201
|
import { useState as useState6 } from "react";
|
|
26144
|
-
import { View as View6, Text as
|
|
26202
|
+
import { View as View6, Text as Text3, Pressable as Pressable4, StyleSheet as StyleSheet6, useWindowDimensions as useWindowDimensions3 } from "react-native";
|
|
26145
26203
|
import { useViewerStore as useViewerStore5 } from "@papyrus-sdk/core";
|
|
26146
26204
|
|
|
26147
26205
|
// components/mobileChromeMetrics.ts
|
|
@@ -26164,7 +26222,7 @@ var MOBILE_CHROME_METRICS = {
|
|
|
26164
26222
|
|
|
26165
26223
|
// components/PageJumpModal.tsx
|
|
26166
26224
|
import { useEffect as useEffect5, useState as useState5 } from "react";
|
|
26167
|
-
import { Modal, Pressable as Pressable3, StyleSheet as StyleSheet5, Text, TextInput, View as View5 } from "react-native";
|
|
26225
|
+
import { Modal, Pressable as Pressable3, StyleSheet as StyleSheet5, Text as Text2, TextInput, View as View5 } from "react-native";
|
|
26168
26226
|
|
|
26169
26227
|
// components/pageJumpModel.ts
|
|
26170
26228
|
var resolvePageJumpTarget = (value, pageCount) => {
|
|
@@ -26207,7 +26265,7 @@ function PageJumpModal({
|
|
|
26207
26265
|
style: [styles5.card, isDark && styles5.cardDark],
|
|
26208
26266
|
onPress: (event) => event.stopPropagation(),
|
|
26209
26267
|
children: [
|
|
26210
|
-
/* @__PURE__ */ jsx6(
|
|
26268
|
+
/* @__PURE__ */ jsx6(Text2, { style: [styles5.title, isDark && styles5.titleDark], children: "Ir para pagina" }),
|
|
26211
26269
|
/* @__PURE__ */ jsx6(
|
|
26212
26270
|
TextInput,
|
|
26213
26271
|
{
|
|
@@ -26234,7 +26292,7 @@ function PageJumpModal({
|
|
|
26234
26292
|
styles5.actionCancel,
|
|
26235
26293
|
isDark && styles5.actionCancelDark
|
|
26236
26294
|
],
|
|
26237
|
-
children: /* @__PURE__ */ jsx6(
|
|
26295
|
+
children: /* @__PURE__ */ jsx6(Text2, { style: [styles5.actionText, isDark && styles5.actionTextDark], children: "Cancelar" })
|
|
26238
26296
|
}
|
|
26239
26297
|
),
|
|
26240
26298
|
/* @__PURE__ */ jsx6(
|
|
@@ -26242,7 +26300,7 @@ function PageJumpModal({
|
|
|
26242
26300
|
{
|
|
26243
26301
|
onPress: confirmJump,
|
|
26244
26302
|
style: [styles5.actionButton, { backgroundColor: accentColor }],
|
|
26245
|
-
children: /* @__PURE__ */ jsx6(
|
|
26303
|
+
children: /* @__PURE__ */ jsx6(Text2, { style: [styles5.actionText, styles5.actionTextPrimary], children: "Ir" })
|
|
26246
26304
|
}
|
|
26247
26305
|
)
|
|
26248
26306
|
] })
|
|
@@ -26367,7 +26425,7 @@ var Topbar = ({
|
|
|
26367
26425
|
}
|
|
26368
26426
|
setJumpModalOpen(true);
|
|
26369
26427
|
};
|
|
26370
|
-
const defaultLogo = /* @__PURE__ */ jsx7(View6, { style: [styles6.logoBadge, { backgroundColor: accentColor }], children: /* @__PURE__ */ jsx7(
|
|
26428
|
+
const defaultLogo = /* @__PURE__ */ jsx7(View6, { style: [styles6.logoBadge, { backgroundColor: accentColor }], children: /* @__PURE__ */ jsx7(Text3, { style: styles6.logoText, children: "P" }) });
|
|
26371
26429
|
const logoElement = logo ?? defaultLogo;
|
|
26372
26430
|
if (!mobileChromeVisible) return null;
|
|
26373
26431
|
return /* @__PURE__ */ jsxs7(Fragment2, { children: [
|
|
@@ -26397,7 +26455,7 @@ var Topbar = ({
|
|
|
26397
26455
|
style: styles6.titleHit,
|
|
26398
26456
|
accessibilityLabel: "Open page jump",
|
|
26399
26457
|
children: /* @__PURE__ */ jsx7(
|
|
26400
|
-
|
|
26458
|
+
Text3,
|
|
26401
26459
|
{
|
|
26402
26460
|
numberOfLines: 1,
|
|
26403
26461
|
style: [styles6.brandText, isDark && styles6.brandTextDark],
|
|
@@ -26429,7 +26487,7 @@ var Topbar = ({
|
|
|
26429
26487
|
style: styles6.pageIndicatorHit,
|
|
26430
26488
|
accessibilityLabel: "Page jump",
|
|
26431
26489
|
children: /* @__PURE__ */ jsxs7(
|
|
26432
|
-
|
|
26490
|
+
Text3,
|
|
26433
26491
|
{
|
|
26434
26492
|
style: [
|
|
26435
26493
|
styles6.pageIndicator,
|
|
@@ -26652,7 +26710,7 @@ var Topbar_default = Topbar;
|
|
|
26652
26710
|
import React7, { useEffect as useEffect6, useMemo as useMemo4, useRef as useRef5, useState as useState7 } from "react";
|
|
26653
26711
|
import {
|
|
26654
26712
|
View as View7,
|
|
26655
|
-
Text as
|
|
26713
|
+
Text as Text4,
|
|
26656
26714
|
Pressable as Pressable5,
|
|
26657
26715
|
StyleSheet as StyleSheet7,
|
|
26658
26716
|
ScrollView as ScrollView2,
|
|
@@ -27306,7 +27364,7 @@ var ToolDock = () => {
|
|
|
27306
27364
|
}
|
|
27307
27365
|
],
|
|
27308
27366
|
children: /* @__PURE__ */ jsx8(
|
|
27309
|
-
|
|
27367
|
+
Text4,
|
|
27310
27368
|
{
|
|
27311
27369
|
style: [
|
|
27312
27370
|
styles7.utilityLabel,
|
|
@@ -27422,7 +27480,7 @@ var ToolDock = () => {
|
|
|
27422
27480
|
}
|
|
27423
27481
|
],
|
|
27424
27482
|
children: /* @__PURE__ */ jsx8(
|
|
27425
|
-
|
|
27483
|
+
Text4,
|
|
27426
27484
|
{
|
|
27427
27485
|
style: [
|
|
27428
27486
|
styles7.utilityLabel,
|
|
@@ -27728,7 +27786,7 @@ import {
|
|
|
27728
27786
|
Platform as Platform3,
|
|
27729
27787
|
Pressable as Pressable7,
|
|
27730
27788
|
StyleSheet as StyleSheet9,
|
|
27731
|
-
Text as
|
|
27789
|
+
Text as Text6,
|
|
27732
27790
|
UIManager,
|
|
27733
27791
|
View as View9,
|
|
27734
27792
|
findNodeHandle as findNodeHandle2
|
|
@@ -27749,7 +27807,7 @@ import {
|
|
|
27749
27807
|
Pressable as Pressable6,
|
|
27750
27808
|
ScrollView as ScrollView3,
|
|
27751
27809
|
StyleSheet as StyleSheet8,
|
|
27752
|
-
Text as
|
|
27810
|
+
Text as Text5,
|
|
27753
27811
|
View as View8
|
|
27754
27812
|
} from "react-native";
|
|
27755
27813
|
import { jsx as jsx9, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
@@ -27805,7 +27863,7 @@ function NativeSheet({
|
|
|
27805
27863
|
}
|
|
27806
27864
|
),
|
|
27807
27865
|
/* @__PURE__ */ jsx9(
|
|
27808
|
-
|
|
27866
|
+
Text5,
|
|
27809
27867
|
{
|
|
27810
27868
|
style: [styles8.title, isDark && styles8.titleDark],
|
|
27811
27869
|
numberOfLines: 1,
|
|
@@ -27985,7 +28043,7 @@ var PageThumbnail = ({
|
|
|
27985
28043
|
style: styles9.thumbImage
|
|
27986
28044
|
}
|
|
27987
28045
|
) : /* @__PURE__ */ jsx10(View9, { style: [styles9.thumbFallback, isDark && styles9.thumbFallbackDark], children: /* @__PURE__ */ jsx10(
|
|
27988
|
-
|
|
28046
|
+
Text6,
|
|
27989
28047
|
{
|
|
27990
28048
|
style: [
|
|
27991
28049
|
styles9.thumbFallbackText,
|
|
@@ -27996,7 +28054,7 @@ var PageThumbnail = ({
|
|
|
27996
28054
|
) })
|
|
27997
28055
|
}
|
|
27998
28056
|
),
|
|
27999
|
-
/* @__PURE__ */ jsx10(
|
|
28057
|
+
/* @__PURE__ */ jsx10(Text6, { style: [styles9.thumbLabel, isDark && styles9.thumbLabelDark], children: pageIndex + 1 })
|
|
28000
28058
|
]
|
|
28001
28059
|
}
|
|
28002
28060
|
);
|
|
@@ -28013,7 +28071,7 @@ var OutlineNode = ({ item, depth = 0, isDark, onSelect, untitledLabel }) => {
|
|
|
28013
28071
|
},
|
|
28014
28072
|
style: [styles9.outlineRow, { paddingLeft: 12 + depth * 12 }],
|
|
28015
28073
|
children: /* @__PURE__ */ jsx10(
|
|
28016
|
-
|
|
28074
|
+
Text6,
|
|
28017
28075
|
{
|
|
28018
28076
|
style: [
|
|
28019
28077
|
styles9.outlineText,
|
|
@@ -28289,7 +28347,7 @@ var RightSheet = ({
|
|
|
28289
28347
|
maxHeight: sheetHeight,
|
|
28290
28348
|
children: /* @__PURE__ */ jsxs10(View9, { style: styles9.sheet, children: [
|
|
28291
28349
|
/* @__PURE__ */ jsxs10(View9, { style: styles9.header, children: [
|
|
28292
|
-
/* @__PURE__ */ jsx10(
|
|
28350
|
+
/* @__PURE__ */ jsx10(Text6, { style: [styles9.sheetTitle, isDark && styles9.sheetTitleDark], children: showingNotes ? t.notes : navigationTitle }),
|
|
28293
28351
|
!showingNotes ? /* @__PURE__ */ jsx10(
|
|
28294
28352
|
Pressable7,
|
|
28295
28353
|
{
|
|
@@ -28297,7 +28355,7 @@ var RightSheet = ({
|
|
|
28297
28355
|
disabled: showingProgress || pageCount <= 0,
|
|
28298
28356
|
style: styles9.pageStatusHit,
|
|
28299
28357
|
accessibilityLabel: "Open page jump",
|
|
28300
|
-
children: /* @__PURE__ */ jsx10(
|
|
28358
|
+
children: /* @__PURE__ */ jsx10(Text6, { style: [styles9.pageStatus, isDark && styles9.pageStatusDark], children: showingProgress ? `${Math.round(currentPage / Math.max(pageCount, 1) * 100)}%` : `${currentPage}/${pageCount}` })
|
|
28301
28359
|
}
|
|
28302
28360
|
) : null
|
|
28303
28361
|
] }),
|
|
@@ -28315,7 +28373,7 @@ var RightSheet = ({
|
|
|
28315
28373
|
}
|
|
28316
28374
|
],
|
|
28317
28375
|
children: /* @__PURE__ */ jsx10(
|
|
28318
|
-
|
|
28376
|
+
Text6,
|
|
28319
28377
|
{
|
|
28320
28378
|
style: [
|
|
28321
28379
|
styles9.segmentText,
|
|
@@ -28339,7 +28397,7 @@ var RightSheet = ({
|
|
|
28339
28397
|
}
|
|
28340
28398
|
],
|
|
28341
28399
|
children: /* @__PURE__ */ jsx10(
|
|
28342
|
-
|
|
28400
|
+
Text6,
|
|
28343
28401
|
{
|
|
28344
28402
|
style: [
|
|
28345
28403
|
styles9.segmentText,
|
|
@@ -28388,7 +28446,7 @@ var RightSheet = ({
|
|
|
28388
28446
|
],
|
|
28389
28447
|
children: [
|
|
28390
28448
|
/* @__PURE__ */ jsxs10(
|
|
28391
|
-
|
|
28449
|
+
Text6,
|
|
28392
28450
|
{
|
|
28393
28451
|
style: [
|
|
28394
28452
|
styles9.progressLabel,
|
|
@@ -28401,7 +28459,7 @@ var RightSheet = ({
|
|
|
28401
28459
|
}
|
|
28402
28460
|
),
|
|
28403
28461
|
/* @__PURE__ */ jsxs10(
|
|
28404
|
-
|
|
28462
|
+
Text6,
|
|
28405
28463
|
{
|
|
28406
28464
|
style: [
|
|
28407
28465
|
styles9.progressMeta,
|
|
@@ -28425,7 +28483,7 @@ var RightSheet = ({
|
|
|
28425
28483
|
{
|
|
28426
28484
|
contentContainerStyle: styles9.summaryContent,
|
|
28427
28485
|
showsVerticalScrollIndicator: false,
|
|
28428
|
-
children: outline.length === 0 ? /* @__PURE__ */ jsx10(
|
|
28486
|
+
children: outline.length === 0 ? /* @__PURE__ */ jsx10(Text6, { style: [styles9.emptyText, isDark && styles9.emptyTextDark], children: t.noSummary }) : outline.map((item, index) => /* @__PURE__ */ jsx10(
|
|
28429
28487
|
OutlineNode,
|
|
28430
28488
|
{
|
|
28431
28489
|
item,
|
|
@@ -28442,7 +28500,7 @@ var RightSheet = ({
|
|
|
28442
28500
|
{
|
|
28443
28501
|
contentContainerStyle: styles9.content,
|
|
28444
28502
|
showsVerticalScrollIndicator: false,
|
|
28445
|
-
children: annotations.length === 0 ? /* @__PURE__ */ jsx10(
|
|
28503
|
+
children: annotations.length === 0 ? /* @__PURE__ */ jsx10(Text6, { style: [styles9.emptyText, isDark && styles9.emptyTextDark], children: t.noAnnotations }) : /* @__PURE__ */ jsx10(View9, { children: annotations.map((ann) => /* @__PURE__ */ jsxs10(
|
|
28446
28504
|
Pressable7,
|
|
28447
28505
|
{
|
|
28448
28506
|
onPress: () => {
|
|
@@ -28460,7 +28518,7 @@ var RightSheet = ({
|
|
|
28460
28518
|
}
|
|
28461
28519
|
),
|
|
28462
28520
|
/* @__PURE__ */ jsxs10(
|
|
28463
|
-
|
|
28521
|
+
Text6,
|
|
28464
28522
|
{
|
|
28465
28523
|
style: [styles9.noteTitle, isDark && styles9.noteTitleDark],
|
|
28466
28524
|
children: [
|
|
@@ -28472,7 +28530,7 @@ var RightSheet = ({
|
|
|
28472
28530
|
)
|
|
28473
28531
|
] }),
|
|
28474
28532
|
/* @__PURE__ */ jsx10(
|
|
28475
|
-
|
|
28533
|
+
Text6,
|
|
28476
28534
|
{
|
|
28477
28535
|
style: [
|
|
28478
28536
|
styles9.noteType,
|
|
@@ -28483,7 +28541,7 @@ var RightSheet = ({
|
|
|
28483
28541
|
}
|
|
28484
28542
|
),
|
|
28485
28543
|
ann.content ? /* @__PURE__ */ jsx10(
|
|
28486
|
-
|
|
28544
|
+
Text6,
|
|
28487
28545
|
{
|
|
28488
28546
|
style: [
|
|
28489
28547
|
styles9.noteContent,
|
|
@@ -28754,7 +28812,7 @@ import { useEffect as useEffect8, useState as useState9 } from "react";
|
|
|
28754
28812
|
import {
|
|
28755
28813
|
Modal as Modal3,
|
|
28756
28814
|
View as View10,
|
|
28757
|
-
Text as
|
|
28815
|
+
Text as Text7,
|
|
28758
28816
|
TextInput as TextInput2,
|
|
28759
28817
|
Pressable as Pressable8,
|
|
28760
28818
|
StyleSheet as StyleSheet10
|
|
@@ -28795,7 +28853,7 @@ var AnnotationEditor = () => {
|
|
|
28795
28853
|
animationType: "fade",
|
|
28796
28854
|
onRequestClose: handleClose,
|
|
28797
28855
|
children: /* @__PURE__ */ jsx11(View10, { style: styles10.overlay, children: /* @__PURE__ */ jsxs11(View10, { style: [styles10.card, isDark && styles10.cardDark], children: [
|
|
28798
|
-
/* @__PURE__ */ jsx11(
|
|
28856
|
+
/* @__PURE__ */ jsx11(Text7, { style: [styles10.title, isDark && styles10.titleDark], children: t.editNote }),
|
|
28799
28857
|
/* @__PURE__ */ jsx11(
|
|
28800
28858
|
TextInput2,
|
|
28801
28859
|
{
|
|
@@ -28813,7 +28871,7 @@ var AnnotationEditor = () => {
|
|
|
28813
28871
|
{
|
|
28814
28872
|
onPress: handleClose,
|
|
28815
28873
|
style: [styles10.actionButton, styles10.actionCancel],
|
|
28816
|
-
children: /* @__PURE__ */ jsx11(
|
|
28874
|
+
children: /* @__PURE__ */ jsx11(Text7, { style: styles10.actionText, children: t.cancel })
|
|
28817
28875
|
}
|
|
28818
28876
|
),
|
|
28819
28877
|
/* @__PURE__ */ jsx11(
|
|
@@ -28825,7 +28883,7 @@ var AnnotationEditor = () => {
|
|
|
28825
28883
|
styles10.actionSave,
|
|
28826
28884
|
{ backgroundColor: accentColor }
|
|
28827
28885
|
],
|
|
28828
|
-
children: /* @__PURE__ */ jsx11(
|
|
28886
|
+
children: /* @__PURE__ */ jsx11(Text7, { style: [styles10.actionText, styles10.actionTextLight], children: t.save })
|
|
28829
28887
|
}
|
|
28830
28888
|
)
|
|
28831
28889
|
] })
|
|
@@ -29191,7 +29249,7 @@ var styles11 = StyleSheet11.create({
|
|
|
29191
29249
|
var BottomBar_default = BottomBar;
|
|
29192
29250
|
|
|
29193
29251
|
// components/SettingsSheet.tsx
|
|
29194
|
-
import { Dimensions as Dimensions2, View as View12, Text as
|
|
29252
|
+
import { Dimensions as Dimensions2, View as View12, Text as Text8, Pressable as Pressable10, StyleSheet as StyleSheet12 } from "react-native";
|
|
29195
29253
|
import { useViewerStore as useViewerStore10 } from "@papyrus-sdk/core";
|
|
29196
29254
|
import { jsx as jsx13, jsxs as jsxs13 } from "react/jsx-runtime";
|
|
29197
29255
|
var PAGE_THEME_OPTIONS = [
|
|
@@ -29282,7 +29340,7 @@ var SettingsSheet = ({
|
|
|
29282
29340
|
children: [
|
|
29283
29341
|
/* @__PURE__ */ jsxs13(View12, { style: styles12.section, children: [
|
|
29284
29342
|
/* @__PURE__ */ jsx13(
|
|
29285
|
-
|
|
29343
|
+
Text8,
|
|
29286
29344
|
{
|
|
29287
29345
|
style: [styles12.sectionTitle, isDark && styles12.sectionTitleDark],
|
|
29288
29346
|
children: t.appearance
|
|
@@ -29300,7 +29358,7 @@ var SettingsSheet = ({
|
|
|
29300
29358
|
uiTheme === "light" && { backgroundColor: accentColor }
|
|
29301
29359
|
],
|
|
29302
29360
|
children: /* @__PURE__ */ jsx13(
|
|
29303
|
-
|
|
29361
|
+
Text8,
|
|
29304
29362
|
{
|
|
29305
29363
|
style: [
|
|
29306
29364
|
styles12.optionText,
|
|
@@ -29323,7 +29381,7 @@ var SettingsSheet = ({
|
|
|
29323
29381
|
uiTheme === "dark" && { backgroundColor: accentColor }
|
|
29324
29382
|
],
|
|
29325
29383
|
children: /* @__PURE__ */ jsx13(
|
|
29326
|
-
|
|
29384
|
+
Text8,
|
|
29327
29385
|
{
|
|
29328
29386
|
style: [
|
|
29329
29387
|
styles12.optionText,
|
|
@@ -29339,7 +29397,7 @@ var SettingsSheet = ({
|
|
|
29339
29397
|
] }),
|
|
29340
29398
|
/* @__PURE__ */ jsxs13(View12, { style: styles12.section, children: [
|
|
29341
29399
|
/* @__PURE__ */ jsx13(
|
|
29342
|
-
|
|
29400
|
+
Text8,
|
|
29343
29401
|
{
|
|
29344
29402
|
style: [styles12.sectionTitle, isDark && styles12.sectionTitleDark],
|
|
29345
29403
|
children: t.pageTheme
|
|
@@ -29360,7 +29418,7 @@ var SettingsSheet = ({
|
|
|
29360
29418
|
children: [
|
|
29361
29419
|
/* @__PURE__ */ jsx13(ThemeSwatch, { value: option.value }),
|
|
29362
29420
|
/* @__PURE__ */ jsx13(
|
|
29363
|
-
|
|
29421
|
+
Text8,
|
|
29364
29422
|
{
|
|
29365
29423
|
style: [
|
|
29366
29424
|
styles12.themeOptionLabel,
|
|
@@ -29378,7 +29436,7 @@ var SettingsSheet = ({
|
|
|
29378
29436
|
] }),
|
|
29379
29437
|
/* @__PURE__ */ jsxs13(View12, { style: styles12.section, children: [
|
|
29380
29438
|
/* @__PURE__ */ jsx13(
|
|
29381
|
-
|
|
29439
|
+
Text8,
|
|
29382
29440
|
{
|
|
29383
29441
|
style: [styles12.sectionTitle, isDark && styles12.sectionTitleDark],
|
|
29384
29442
|
children: t.pageTransition
|
|
@@ -29396,7 +29454,7 @@ var SettingsSheet = ({
|
|
|
29396
29454
|
(!isPaged || isDouble) && { backgroundColor: accentColor }
|
|
29397
29455
|
],
|
|
29398
29456
|
children: /* @__PURE__ */ jsx13(
|
|
29399
|
-
|
|
29457
|
+
Text8,
|
|
29400
29458
|
{
|
|
29401
29459
|
style: [
|
|
29402
29460
|
styles12.optionText,
|
|
@@ -29419,7 +29477,7 @@ var SettingsSheet = ({
|
|
|
29419
29477
|
isPaged && { backgroundColor: accentColor }
|
|
29420
29478
|
],
|
|
29421
29479
|
children: /* @__PURE__ */ jsx13(
|
|
29422
|
-
|
|
29480
|
+
Text8,
|
|
29423
29481
|
{
|
|
29424
29482
|
style: [
|
|
29425
29483
|
styles12.optionText,
|
|
@@ -29435,7 +29493,7 @@ var SettingsSheet = ({
|
|
|
29435
29493
|
] }),
|
|
29436
29494
|
/* @__PURE__ */ jsxs13(View12, { style: styles12.section, children: [
|
|
29437
29495
|
/* @__PURE__ */ jsx13(
|
|
29438
|
-
|
|
29496
|
+
Text8,
|
|
29439
29497
|
{
|
|
29440
29498
|
style: [styles12.sectionTitle, isDark && styles12.sectionTitleDark],
|
|
29441
29499
|
children: t.layout
|
|
@@ -29453,7 +29511,7 @@ var SettingsSheet = ({
|
|
|
29453
29511
|
!isDouble && { backgroundColor: accentColor }
|
|
29454
29512
|
],
|
|
29455
29513
|
children: /* @__PURE__ */ jsx13(
|
|
29456
|
-
|
|
29514
|
+
Text8,
|
|
29457
29515
|
{
|
|
29458
29516
|
style: [
|
|
29459
29517
|
styles12.optionText,
|
|
@@ -29476,7 +29534,7 @@ var SettingsSheet = ({
|
|
|
29476
29534
|
isDouble && { backgroundColor: accentColor }
|
|
29477
29535
|
],
|
|
29478
29536
|
children: /* @__PURE__ */ jsx13(
|
|
29479
|
-
|
|
29537
|
+
Text8,
|
|
29480
29538
|
{
|
|
29481
29539
|
style: [
|
|
29482
29540
|
styles12.optionText,
|
|
@@ -29492,7 +29550,7 @@ var SettingsSheet = ({
|
|
|
29492
29550
|
] }),
|
|
29493
29551
|
/* @__PURE__ */ jsxs13(View12, { style: styles12.section, children: [
|
|
29494
29552
|
/* @__PURE__ */ jsx13(
|
|
29495
|
-
|
|
29553
|
+
Text8,
|
|
29496
29554
|
{
|
|
29497
29555
|
style: [styles12.sectionTitle, isDark && styles12.sectionTitleDark],
|
|
29498
29556
|
children: t.rotate
|
|
@@ -29505,7 +29563,7 @@ var SettingsSheet = ({
|
|
|
29505
29563
|
onPress: () => handleRotate("counterclockwise"),
|
|
29506
29564
|
style: [styles12.optionButton, isDark && styles12.optionButtonDark],
|
|
29507
29565
|
children: /* @__PURE__ */ jsx13(
|
|
29508
|
-
|
|
29566
|
+
Text8,
|
|
29509
29567
|
{
|
|
29510
29568
|
style: [styles12.optionText, isDark && styles12.optionTextDark],
|
|
29511
29569
|
children: t.counterclockwise
|
|
@@ -29519,7 +29577,7 @@ var SettingsSheet = ({
|
|
|
29519
29577
|
onPress: () => handleRotate("clockwise"),
|
|
29520
29578
|
style: [styles12.optionButton, isDark && styles12.optionButtonDark],
|
|
29521
29579
|
children: /* @__PURE__ */ jsx13(
|
|
29522
|
-
|
|
29580
|
+
Text8,
|
|
29523
29581
|
{
|
|
29524
29582
|
style: [styles12.optionText, isDark && styles12.optionTextDark],
|
|
29525
29583
|
children: t.clockwise
|
|
@@ -29531,7 +29589,7 @@ var SettingsSheet = ({
|
|
|
29531
29589
|
] }),
|
|
29532
29590
|
/* @__PURE__ */ jsxs13(View12, { style: styles12.section, children: [
|
|
29533
29591
|
/* @__PURE__ */ jsx13(
|
|
29534
|
-
|
|
29592
|
+
Text8,
|
|
29535
29593
|
{
|
|
29536
29594
|
style: [styles12.sectionTitle, isDark && styles12.sectionTitleDark],
|
|
29537
29595
|
children: t.zoom
|
|
@@ -29546,7 +29604,7 @@ var SettingsSheet = ({
|
|
|
29546
29604
|
children: /* @__PURE__ */ jsx13(IconZoomOut, { size: 16, color: isDark ? "#e5e7eb" : "#111827" })
|
|
29547
29605
|
}
|
|
29548
29606
|
),
|
|
29549
|
-
/* @__PURE__ */ jsx13(View12, { style: styles12.zoomValue, children: /* @__PURE__ */ jsxs13(
|
|
29607
|
+
/* @__PURE__ */ jsx13(View12, { style: styles12.zoomValue, children: /* @__PURE__ */ jsxs13(Text8, { style: [styles12.zoomText, isDark && styles12.zoomTextDark], children: [
|
|
29550
29608
|
Math.round(zoom * 100),
|
|
29551
29609
|
"%"
|
|
29552
29610
|
] }) }),
|
|
@@ -29562,7 +29620,7 @@ var SettingsSheet = ({
|
|
|
29562
29620
|
] }),
|
|
29563
29621
|
/* @__PURE__ */ jsxs13(View12, { style: styles12.section, children: [
|
|
29564
29622
|
/* @__PURE__ */ jsx13(
|
|
29565
|
-
|
|
29623
|
+
Text8,
|
|
29566
29624
|
{
|
|
29567
29625
|
style: [styles12.sectionTitle, isDark && styles12.sectionTitleDark],
|
|
29568
29626
|
children: t.language
|
|
@@ -29580,7 +29638,7 @@ var SettingsSheet = ({
|
|
|
29580
29638
|
locale === "en" && { backgroundColor: accentColor }
|
|
29581
29639
|
],
|
|
29582
29640
|
children: /* @__PURE__ */ jsx13(
|
|
29583
|
-
|
|
29641
|
+
Text8,
|
|
29584
29642
|
{
|
|
29585
29643
|
style: [
|
|
29586
29644
|
styles12.optionText,
|
|
@@ -29603,7 +29661,7 @@ var SettingsSheet = ({
|
|
|
29603
29661
|
locale === "pt-BR" && { backgroundColor: accentColor }
|
|
29604
29662
|
],
|
|
29605
29663
|
children: /* @__PURE__ */ jsx13(
|
|
29606
|
-
|
|
29664
|
+
Text8,
|
|
29607
29665
|
{
|
|
29608
29666
|
style: [
|
|
29609
29667
|
styles12.optionText,
|
|
@@ -29760,7 +29818,7 @@ import { useEffect as useEffect9, useMemo as useMemo6, useRef as useRef7, useSta
|
|
|
29760
29818
|
import {
|
|
29761
29819
|
ActivityIndicator,
|
|
29762
29820
|
StyleSheet as StyleSheet13,
|
|
29763
|
-
Text as
|
|
29821
|
+
Text as Text9,
|
|
29764
29822
|
UIManager as UIManager2,
|
|
29765
29823
|
View as View13,
|
|
29766
29824
|
findNodeHandle as findNodeHandle3
|
|
@@ -29883,12 +29941,12 @@ var CoverPreview = ({
|
|
|
29883
29941
|
}
|
|
29884
29942
|
};
|
|
29885
29943
|
if (!shouldRender || !canRender) {
|
|
29886
|
-
return /* @__PURE__ */ jsx14(View13, { style: [styles13.container, style], children: placeholder ?? /* @__PURE__ */ jsx14(View13, { style: styles13.placeholder, children: /* @__PURE__ */ jsx14(
|
|
29944
|
+
return /* @__PURE__ */ jsx14(View13, { style: [styles13.container, style], children: placeholder ?? /* @__PURE__ */ jsx14(View13, { style: styles13.placeholder, children: /* @__PURE__ */ jsx14(Text9, { style: styles13.placeholderText, children: "Preview" }) }) });
|
|
29887
29945
|
}
|
|
29888
29946
|
return /* @__PURE__ */ jsxs14(View13, { style: [styles13.container, style], onLayout: handleLayout, children: [
|
|
29889
29947
|
/* @__PURE__ */ jsx14(View13, { style: styles13.previewFrame, pointerEvents: allowInteraction ? "auto" : "none", children: isPdf ? /* @__PURE__ */ jsx14(PapyrusPageView3, { ref: viewRef, style: styles13.pageView }) : engine && /* @__PURE__ */ jsx14(WebViewViewer_default, { engine }) }),
|
|
29890
29948
|
showLoading && loading && /* @__PURE__ */ jsx14(View13, { pointerEvents: "none", style: styles13.loadingOverlay, children: loadingIndicator ?? /* @__PURE__ */ jsx14(ActivityIndicator, { size: "small", color: "#2563eb" }) }),
|
|
29891
|
-
error && /* @__PURE__ */ jsx14(View13, { pointerEvents: "none", style: styles13.errorOverlay, children: /* @__PURE__ */ jsx14(
|
|
29949
|
+
error && /* @__PURE__ */ jsx14(View13, { pointerEvents: "none", style: styles13.errorOverlay, children: /* @__PURE__ */ jsx14(Text9, { style: styles13.errorText, children: "Preview unavailable" }) })
|
|
29892
29950
|
] });
|
|
29893
29951
|
};
|
|
29894
29952
|
var styles13 = StyleSheet13.create({
|
|
@@ -29947,7 +30005,7 @@ import {
|
|
|
29947
30005
|
Modal as Modal4,
|
|
29948
30006
|
Pressable as Pressable11,
|
|
29949
30007
|
StyleSheet as StyleSheet14,
|
|
29950
|
-
Text as
|
|
30008
|
+
Text as Text10,
|
|
29951
30009
|
View as View14
|
|
29952
30010
|
} from "react-native";
|
|
29953
30011
|
import { useViewerStore as useViewerStore11 } from "@papyrus-sdk/core";
|
|
@@ -29964,12 +30022,12 @@ function DocumentActionsSheet({
|
|
|
29964
30022
|
onPress: (event) => event.stopPropagation(),
|
|
29965
30023
|
style: [styles14.card, isDark && styles14.cardDark],
|
|
29966
30024
|
children: [
|
|
29967
|
-
/* @__PURE__ */ jsx15(
|
|
30025
|
+
/* @__PURE__ */ jsx15(Text10, { style: [styles14.eyebrow, isDark && styles14.eyebrowDark], children: "Document actions" }),
|
|
29968
30026
|
/* @__PURE__ */ jsxs15(View14, { style: styles14.actionList, children: [
|
|
29969
|
-
/* @__PURE__ */ jsx15(View14, { style: [styles14.actionItem, isDark && styles14.actionItemDark], children: /* @__PURE__ */ jsx15(
|
|
29970
|
-
/* @__PURE__ */ jsx15(View14, { style: [styles14.actionItem, isDark && styles14.actionItemDark], children: /* @__PURE__ */ jsx15(
|
|
30027
|
+
/* @__PURE__ */ jsx15(View14, { style: [styles14.actionItem, isDark && styles14.actionItemDark], children: /* @__PURE__ */ jsx15(Text10, { style: [styles14.actionText, isDark && styles14.actionTextDark], children: "Share" }) }),
|
|
30028
|
+
/* @__PURE__ */ jsx15(View14, { style: [styles14.actionItem, isDark && styles14.actionItemDark], children: /* @__PURE__ */ jsx15(Text10, { style: [styles14.actionText, isDark && styles14.actionTextDark], children: "Export" }) })
|
|
29971
30029
|
] }),
|
|
29972
|
-
/* @__PURE__ */ jsx15(Pressable11, { onPress: onClose, style: styles14.closeButton, accessibilityLabel: "Close actions sheet", children: /* @__PURE__ */ jsx15(
|
|
30030
|
+
/* @__PURE__ */ jsx15(Pressable11, { onPress: onClose, style: styles14.closeButton, accessibilityLabel: "Close actions sheet", children: /* @__PURE__ */ jsx15(Text10, { style: styles14.closeText, children: "Close" }) })
|
|
29973
30031
|
]
|
|
29974
30032
|
}
|
|
29975
30033
|
) }) });
|
|
@@ -30040,7 +30098,7 @@ import {
|
|
|
30040
30098
|
Pressable as Pressable12,
|
|
30041
30099
|
ScrollView as ScrollView4,
|
|
30042
30100
|
StyleSheet as StyleSheet15,
|
|
30043
|
-
Text as
|
|
30101
|
+
Text as Text11,
|
|
30044
30102
|
View as View15
|
|
30045
30103
|
} from "react-native";
|
|
30046
30104
|
import { useViewerStore as useViewerStore12 } from "@papyrus-sdk/core";
|
|
@@ -30199,7 +30257,7 @@ function InfoSheet({
|
|
|
30199
30257
|
}
|
|
30200
30258
|
),
|
|
30201
30259
|
/* @__PURE__ */ jsx16(
|
|
30202
|
-
|
|
30260
|
+
Text11,
|
|
30203
30261
|
{
|
|
30204
30262
|
style: [styles15.headerTitle, isDark && styles15.headerTitleDark],
|
|
30205
30263
|
numberOfLines: 1,
|
|
@@ -30216,7 +30274,7 @@ function InfoSheet({
|
|
|
30216
30274
|
showsVerticalScrollIndicator: false,
|
|
30217
30275
|
children: [
|
|
30218
30276
|
/* @__PURE__ */ jsx16(
|
|
30219
|
-
|
|
30277
|
+
Text11,
|
|
30220
30278
|
{
|
|
30221
30279
|
style: [styles15.sectionTitle, isDark && styles15.sectionTitleDark],
|
|
30222
30280
|
children: locale === "pt-BR" ? "Informa\xE7\xF5es" : "Information"
|
|
@@ -30227,9 +30285,9 @@ function InfoSheet({
|
|
|
30227
30285
|
{
|
|
30228
30286
|
style: [styles15.row, isDark && styles15.rowDark],
|
|
30229
30287
|
children: [
|
|
30230
|
-
/* @__PURE__ */ jsx16(
|
|
30288
|
+
/* @__PURE__ */ jsx16(Text11, { style: [styles15.label, isDark && styles15.labelDark], children: row.label }),
|
|
30231
30289
|
/* @__PURE__ */ jsx16(
|
|
30232
|
-
|
|
30290
|
+
Text11,
|
|
30233
30291
|
{
|
|
30234
30292
|
style: [styles15.value, isDark && styles15.valueDark],
|
|
30235
30293
|
selectable: true,
|
|
@@ -30352,7 +30410,7 @@ var styles15 = StyleSheet15.create({
|
|
|
30352
30410
|
});
|
|
30353
30411
|
|
|
30354
30412
|
// components/OverflowSheet.tsx
|
|
30355
|
-
import { Modal as Modal6, Pressable as Pressable13, StyleSheet as StyleSheet16, Text as
|
|
30413
|
+
import { Modal as Modal6, Pressable as Pressable13, StyleSheet as StyleSheet16, Text as Text12, View as View16 } from "react-native";
|
|
30356
30414
|
import { useViewerStore as useViewerStore13 } from "@papyrus-sdk/core";
|
|
30357
30415
|
import { jsx as jsx17, jsxs as jsxs17 } from "react/jsx-runtime";
|
|
30358
30416
|
var actionLabels = [{ key: "actions", label: "Document actions" }];
|
|
@@ -30387,7 +30445,7 @@ function OverflowSheet({
|
|
|
30387
30445
|
style: [styles16.actionButton, { borderColor: accentColor }],
|
|
30388
30446
|
accessibilityLabel: action.label,
|
|
30389
30447
|
children: /* @__PURE__ */ jsx17(
|
|
30390
|
-
|
|
30448
|
+
Text12,
|
|
30391
30449
|
{
|
|
30392
30450
|
style: [styles16.actionText, isDark && styles16.actionTextDark],
|
|
30393
30451
|
children: action.label
|
|
@@ -30444,7 +30502,7 @@ var styles16 = StyleSheet16.create({
|
|
|
30444
30502
|
|
|
30445
30503
|
// components/ProgressPill.tsx
|
|
30446
30504
|
import { useMemo as useMemo7 } from "react";
|
|
30447
|
-
import { Pressable as Pressable14, StyleSheet as StyleSheet17, Text as
|
|
30505
|
+
import { Pressable as Pressable14, StyleSheet as StyleSheet17, Text as Text13, View as View17 } from "react-native";
|
|
30448
30506
|
import { useViewerStore as useViewerStore14 } from "@papyrus-sdk/core";
|
|
30449
30507
|
import { jsx as jsx18, jsxs as jsxs18 } from "react/jsx-runtime";
|
|
30450
30508
|
var clampPercent = (value) => Math.max(0, Math.min(100, Math.round(value)));
|
|
@@ -30508,7 +30566,7 @@ function ProgressPill({
|
|
|
30508
30566
|
onLongPress: onOpenPageJump,
|
|
30509
30567
|
style: styles17.labelHit,
|
|
30510
30568
|
accessibilityLabel: "Open page jump",
|
|
30511
|
-
children: /* @__PURE__ */ jsx18(
|
|
30569
|
+
children: /* @__PURE__ */ jsx18(Text13, { style: [styles17.label, isDark && styles17.labelDark], children: label })
|
|
30512
30570
|
}
|
|
30513
30571
|
)
|
|
30514
30572
|
]
|
|
@@ -30568,7 +30626,7 @@ import {
|
|
|
30568
30626
|
Keyboard,
|
|
30569
30627
|
Pressable as Pressable15,
|
|
30570
30628
|
StyleSheet as StyleSheet18,
|
|
30571
|
-
Text as
|
|
30629
|
+
Text as Text14,
|
|
30572
30630
|
TextInput as TextInput3,
|
|
30573
30631
|
View as View18
|
|
30574
30632
|
} from "react-native";
|
|
@@ -30653,7 +30711,7 @@ function SearchOverlay({
|
|
|
30653
30711
|
onPress: handleClose,
|
|
30654
30712
|
style: [styles18.closeButton, isDark && styles18.closeButtonDark],
|
|
30655
30713
|
accessibilityLabel: "Close search",
|
|
30656
|
-
children: /* @__PURE__ */ jsx19(
|
|
30714
|
+
children: /* @__PURE__ */ jsx19(Text14, { style: [styles18.closeText, isDark && styles18.closeTextDark], children: t.cancel })
|
|
30657
30715
|
}
|
|
30658
30716
|
)
|
|
30659
30717
|
] }),
|
|
@@ -30672,7 +30730,7 @@ function SearchOverlay({
|
|
|
30672
30730
|
children: /* @__PURE__ */ jsx19(IconChevronLeft, { size: 16, color: isDark ? "#e5e7eb" : "#111827" })
|
|
30673
30731
|
}
|
|
30674
30732
|
),
|
|
30675
|
-
/* @__PURE__ */ jsx19(
|
|
30733
|
+
/* @__PURE__ */ jsx19(Text14, { style: [styles18.metaText, isDark && styles18.metaTextDark], children: isSearching ? t.searching : `${currentCount}/${searchResults.length} ${targetLabel}` }),
|
|
30676
30734
|
/* @__PURE__ */ jsx19(
|
|
30677
30735
|
Pressable15,
|
|
30678
30736
|
{
|
|
@@ -30695,7 +30753,7 @@ function SearchOverlay({
|
|
|
30695
30753
|
onPress: handleSubmit,
|
|
30696
30754
|
style: [styles18.primaryAction, { backgroundColor: accentColor }],
|
|
30697
30755
|
accessibilityLabel: "Run search",
|
|
30698
|
-
children: /* @__PURE__ */ jsx19(
|
|
30756
|
+
children: /* @__PURE__ */ jsx19(Text14, { style: styles18.primaryActionText, children: t.searchGo })
|
|
30699
30757
|
}
|
|
30700
30758
|
),
|
|
30701
30759
|
/* @__PURE__ */ jsx19(
|
|
@@ -30710,7 +30768,7 @@ function SearchOverlay({
|
|
|
30710
30768
|
],
|
|
30711
30769
|
accessibilityLabel: "Open all results",
|
|
30712
30770
|
children: /* @__PURE__ */ jsx19(
|
|
30713
|
-
|
|
30771
|
+
Text14,
|
|
30714
30772
|
{
|
|
30715
30773
|
style: [
|
|
30716
30774
|
styles18.secondaryActionText,
|
|
@@ -30872,7 +30930,7 @@ import {
|
|
|
30872
30930
|
Pressable as Pressable16,
|
|
30873
30931
|
ScrollView as ScrollView5,
|
|
30874
30932
|
StyleSheet as StyleSheet19,
|
|
30875
|
-
Text as
|
|
30933
|
+
Text as Text15,
|
|
30876
30934
|
View as View19
|
|
30877
30935
|
} from "react-native";
|
|
30878
30936
|
import { useViewerStore as useViewerStore16 } from "@papyrus-sdk/core";
|
|
@@ -30912,14 +30970,14 @@ function SearchResultsSheet({
|
|
|
30912
30970
|
/* @__PURE__ */ jsxs20(View19, { style: [styles19.sheet, isDark && styles19.sheetDark], children: [
|
|
30913
30971
|
/* @__PURE__ */ jsx20(View19, { style: [styles19.handle, isDark && styles19.handleDark] }),
|
|
30914
30972
|
/* @__PURE__ */ jsxs20(View19, { style: styles19.header, children: [
|
|
30915
|
-
/* @__PURE__ */ jsx20(
|
|
30916
|
-
/* @__PURE__ */ jsxs20(
|
|
30973
|
+
/* @__PURE__ */ jsx20(Text15, { style: [styles19.title, isDark && styles19.titleDark], children: t.allResults }),
|
|
30974
|
+
/* @__PURE__ */ jsxs20(Text15, { style: [styles19.meta, isDark && styles19.metaDark], children: [
|
|
30917
30975
|
searchResults.length,
|
|
30918
30976
|
" ",
|
|
30919
30977
|
t.results
|
|
30920
30978
|
] })
|
|
30921
30979
|
] }),
|
|
30922
|
-
/* @__PURE__ */ jsx20(ScrollView5, { contentContainerStyle: styles19.content, children: searchResults.length === 0 ? /* @__PURE__ */ jsx20(
|
|
30980
|
+
/* @__PURE__ */ jsx20(ScrollView5, { contentContainerStyle: styles19.content, children: searchResults.length === 0 ? /* @__PURE__ */ jsx20(Text15, { style: [styles19.emptyText, isDark && styles19.emptyTextDark], children: t.noResults }) : searchResults.map((result, index) => {
|
|
30923
30981
|
const isActive = index === activeSearchIndex;
|
|
30924
30982
|
return /* @__PURE__ */ jsxs20(
|
|
30925
30983
|
Pressable16,
|
|
@@ -30941,9 +30999,9 @@ function SearchResultsSheet({
|
|
|
30941
30999
|
}
|
|
30942
31000
|
],
|
|
30943
31001
|
children: [
|
|
30944
|
-
/* @__PURE__ */ jsx20(
|
|
31002
|
+
/* @__PURE__ */ jsx20(Text15, { style: [styles19.resultLabel, { color: accentColor }], children: getResultLabel(result.pageIndex) }),
|
|
30945
31003
|
/* @__PURE__ */ jsx20(
|
|
30946
|
-
|
|
31004
|
+
Text15,
|
|
30947
31005
|
{
|
|
30948
31006
|
style: [
|
|
30949
31007
|
styles19.resultText,
|