@poolse/react-native 3.7.0 → 3.8.0
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/CHANGELOG.md +28 -0
- package/README.md +27 -0
- package/dist/index.cjs +690 -354
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +77 -4
- package/dist/index.d.ts +77 -4
- package/dist/index.js +688 -356
- package/dist/index.js.map +1 -1
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -7,6 +7,7 @@ var reactNativeSvg = require('react-native-svg');
|
|
|
7
7
|
var theme = require('@poolse/theme');
|
|
8
8
|
var jsxRuntime = require('react/jsx-runtime');
|
|
9
9
|
var reactNativeSafeAreaContext = require('react-native-safe-area-context');
|
|
10
|
+
var sdk = require('@poolse/sdk');
|
|
10
11
|
var ImagePicker = require('expo-image-picker');
|
|
11
12
|
var DocumentPicker = require('expo-document-picker');
|
|
12
13
|
var expoImageManipulator = require('expo-image-manipulator');
|
|
@@ -1321,7 +1322,17 @@ function ChatHeader({
|
|
|
1321
1322
|
}
|
|
1322
1323
|
],
|
|
1323
1324
|
children: [
|
|
1324
|
-
onBack ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1325
|
+
onBack ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1326
|
+
reactNative.Pressable,
|
|
1327
|
+
{
|
|
1328
|
+
onPress: onBack,
|
|
1329
|
+
hitSlop: 12,
|
|
1330
|
+
style: styles5.backBtn,
|
|
1331
|
+
accessibilityRole: "button",
|
|
1332
|
+
accessibilityLabel: "Back",
|
|
1333
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "reply", size: 20, color: theme.colors.text })
|
|
1334
|
+
}
|
|
1335
|
+
) : null,
|
|
1325
1336
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1326
1337
|
Avatar,
|
|
1327
1338
|
{
|
|
@@ -1352,6 +1363,7 @@ function ChatHeader({
|
|
|
1352
1363
|
onPress: onMembersPress,
|
|
1353
1364
|
hitSlop: 12,
|
|
1354
1365
|
style: styles5.actionBtn,
|
|
1366
|
+
accessibilityRole: "button",
|
|
1355
1367
|
accessibilityLabel: "Show members",
|
|
1356
1368
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "users", size: 20, color: theme.colors.textMuted })
|
|
1357
1369
|
}
|
|
@@ -1407,6 +1419,34 @@ var styles5 = reactNative.StyleSheet.create({
|
|
|
1407
1419
|
marginLeft: -6
|
|
1408
1420
|
}
|
|
1409
1421
|
});
|
|
1422
|
+
function EmptyState({ title, hint, action }) {
|
|
1423
|
+
const theme = useTheme();
|
|
1424
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles6.root, accessible: true, accessibilityRole: "text", children: [
|
|
1425
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1426
|
+
reactNative.Text,
|
|
1427
|
+
{
|
|
1428
|
+
style: [styles6.title, { color: theme.colors.text, fontFamily: theme.fonts.body }],
|
|
1429
|
+
maxFontSizeMultiplier: 2,
|
|
1430
|
+
children: title
|
|
1431
|
+
}
|
|
1432
|
+
),
|
|
1433
|
+
hint ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1434
|
+
reactNative.Text,
|
|
1435
|
+
{
|
|
1436
|
+
style: [styles6.hint, { color: theme.colors.textMuted, fontFamily: theme.fonts.body }],
|
|
1437
|
+
maxFontSizeMultiplier: 2,
|
|
1438
|
+
children: hint
|
|
1439
|
+
}
|
|
1440
|
+
) : null,
|
|
1441
|
+
action ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles6.action, children: action }) : null
|
|
1442
|
+
] });
|
|
1443
|
+
}
|
|
1444
|
+
var styles6 = reactNative.StyleSheet.create({
|
|
1445
|
+
root: { alignItems: "center", paddingHorizontal: 24, paddingVertical: 24, maxWidth: 360 },
|
|
1446
|
+
title: { fontSize: 16, fontWeight: "600", textAlign: "center" },
|
|
1447
|
+
hint: { fontSize: 14, lineHeight: 20, marginTop: 6, textAlign: "center" },
|
|
1448
|
+
action: { marginTop: 14 }
|
|
1449
|
+
});
|
|
1410
1450
|
|
|
1411
1451
|
// src/internal/conversationSections.ts
|
|
1412
1452
|
var TYPE_SECTIONS = [
|
|
@@ -1428,6 +1468,8 @@ function ConversationList({
|
|
|
1428
1468
|
onSelect,
|
|
1429
1469
|
renderItem,
|
|
1430
1470
|
emptyState,
|
|
1471
|
+
query = "",
|
|
1472
|
+
noResultsState,
|
|
1431
1473
|
conversations: controlled,
|
|
1432
1474
|
loading: controlledLoading,
|
|
1433
1475
|
error: controlledError,
|
|
@@ -1449,7 +1491,15 @@ function ConversationList({
|
|
|
1449
1491
|
const meExternalId = me?.external_id ?? null;
|
|
1450
1492
|
const meId = me?.id ?? null;
|
|
1451
1493
|
const isControlled = controlled !== void 0;
|
|
1452
|
-
const
|
|
1494
|
+
const allConversations = isControlled ? controlled : auto.conversations;
|
|
1495
|
+
const needle = query.trim();
|
|
1496
|
+
const conversations = react.useMemo(
|
|
1497
|
+
() => needle ? react$1.filterConversations(allConversations, needle, {
|
|
1498
|
+
meExternalId,
|
|
1499
|
+
...labelFor ? { labelFor } : {}
|
|
1500
|
+
}) : allConversations,
|
|
1501
|
+
[allConversations, needle, meExternalId, labelFor]
|
|
1502
|
+
);
|
|
1453
1503
|
const loading = isControlled ? controlledLoading ?? false : auto.loading;
|
|
1454
1504
|
const error = isControlled ? controlledError ?? null : auto.error;
|
|
1455
1505
|
const counts = unreadCounts ?? (isControlled ? void 0 : auto.unreadCounts);
|
|
@@ -1498,9 +1548,9 @@ function ConversationList({
|
|
|
1498
1548
|
onSelect
|
|
1499
1549
|
]
|
|
1500
1550
|
);
|
|
1501
|
-
const placeholder = (node) => /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
1551
|
+
const placeholder = (node) => /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles7.flex, { backgroundColor: theme.colors.background }], children: [
|
|
1502
1552
|
header,
|
|
1503
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
1553
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles7.placeholder, children: node })
|
|
1504
1554
|
] });
|
|
1505
1555
|
if (loading && conversations.length === 0) {
|
|
1506
1556
|
return placeholder(/* @__PURE__ */ jsxRuntime.jsx(reactNative.ActivityIndicator, { color: theme.colors.accent }));
|
|
@@ -1510,12 +1560,29 @@ function ConversationList({
|
|
|
1510
1560
|
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: { color: theme.colors.danger, fontFamily: theme.fonts.body }, children: "Failed to load conversations." })
|
|
1511
1561
|
);
|
|
1512
1562
|
}
|
|
1563
|
+
if (conversations.length === 0 && needle && allConversations.length > 0) {
|
|
1564
|
+
return placeholder(
|
|
1565
|
+
typeof noResultsState === "function" ? noResultsState(needle) : noResultsState !== void 0 ? noResultsState : /* @__PURE__ */ jsxRuntime.jsx(
|
|
1566
|
+
EmptyState,
|
|
1567
|
+
{
|
|
1568
|
+
title: `Nothing matches \u201C${needle}\u201D`,
|
|
1569
|
+
hint: "Check the spelling, or search by a person's or channel's name."
|
|
1570
|
+
}
|
|
1571
|
+
)
|
|
1572
|
+
);
|
|
1573
|
+
}
|
|
1513
1574
|
if (conversations.length === 0) {
|
|
1514
1575
|
return placeholder(
|
|
1515
|
-
|
|
1576
|
+
emptyState == null ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1577
|
+
EmptyState,
|
|
1578
|
+
{
|
|
1579
|
+
title: "No conversations yet",
|
|
1580
|
+
hint: "Start a chat with someone, or join a channel \u2014 it shows up here."
|
|
1581
|
+
}
|
|
1582
|
+
) : typeof emptyState === "string" ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: { color: theme.colors.textSubtle, fontFamily: theme.fonts.body }, children: emptyState }) : emptyState
|
|
1516
1583
|
);
|
|
1517
1584
|
}
|
|
1518
|
-
const footer = loadingMore ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.ActivityIndicator, { color: theme.colors.textSubtle, style:
|
|
1585
|
+
const footer = loadingMore ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.ActivityIndicator, { color: theme.colors.textSubtle, style: styles7.footerSpinner }) : null;
|
|
1519
1586
|
const common = {
|
|
1520
1587
|
style: { backgroundColor: theme.colors.background },
|
|
1521
1588
|
onEndReached: hasMore ? loadMore : void 0,
|
|
@@ -1536,8 +1603,8 @@ function ConversationList({
|
|
|
1536
1603
|
reactNative.Text,
|
|
1537
1604
|
{
|
|
1538
1605
|
style: [
|
|
1539
|
-
|
|
1540
|
-
density === "compact" ?
|
|
1606
|
+
styles7.sectionTitle,
|
|
1607
|
+
density === "compact" ? styles7.sectionTitleDense : null,
|
|
1541
1608
|
{ color: theme.colors.textMuted, fontFamily: theme.fonts.body }
|
|
1542
1609
|
],
|
|
1543
1610
|
accessibilityRole: "header",
|
|
@@ -1589,7 +1656,7 @@ function ConversationRow({
|
|
|
1589
1656
|
accessibilityState: { selected },
|
|
1590
1657
|
accessibilityLabel: unread > 0 ? `${title}, ${unread} unread` : title,
|
|
1591
1658
|
style: ({ pressed }) => [
|
|
1592
|
-
|
|
1659
|
+
styles7.row,
|
|
1593
1660
|
{
|
|
1594
1661
|
paddingHorizontal: theme.spacing.md,
|
|
1595
1662
|
paddingVertical: dense ? theme.spacing.xs + 2 : theme.spacing.sm + 2,
|
|
@@ -1608,14 +1675,14 @@ function ConversationRow({
|
|
|
1608
1675
|
...presence ? { presence: presence.state, doNotDisturb: !!presence.do_not_disturb } : {}
|
|
1609
1676
|
}
|
|
1610
1677
|
),
|
|
1611
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
1612
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
1678
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles7.body, children: [
|
|
1679
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles7.titleLine, children: [
|
|
1613
1680
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1614
1681
|
reactNative.Text,
|
|
1615
1682
|
{
|
|
1616
1683
|
style: [
|
|
1617
|
-
|
|
1618
|
-
dense ?
|
|
1684
|
+
styles7.name,
|
|
1685
|
+
dense ? styles7.nameDense : null,
|
|
1619
1686
|
{
|
|
1620
1687
|
color: theme.colors.text,
|
|
1621
1688
|
fontFamily: theme.fonts.body,
|
|
@@ -1630,7 +1697,7 @@ function ConversationRow({
|
|
|
1630
1697
|
reactNative.Text,
|
|
1631
1698
|
{
|
|
1632
1699
|
style: [
|
|
1633
|
-
|
|
1700
|
+
styles7.time,
|
|
1634
1701
|
{ color: bold ? theme.colors.accentStrong : theme.colors.textSubtle }
|
|
1635
1702
|
],
|
|
1636
1703
|
children: when
|
|
@@ -1641,7 +1708,7 @@ function ConversationRow({
|
|
|
1641
1708
|
reactNative.Text,
|
|
1642
1709
|
{
|
|
1643
1710
|
style: [
|
|
1644
|
-
|
|
1711
|
+
styles7.preview,
|
|
1645
1712
|
{ color: bold ? theme.colors.textMuted : theme.colors.textSubtle }
|
|
1646
1713
|
],
|
|
1647
1714
|
numberOfLines: 1,
|
|
@@ -1649,12 +1716,12 @@ function ConversationRow({
|
|
|
1649
1716
|
}
|
|
1650
1717
|
) : null
|
|
1651
1718
|
] }),
|
|
1652
|
-
unread > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
1719
|
+
unread > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles7.unreadPill, { backgroundColor: theme.colors.badge }], children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles7.unreadText, { color: theme.colors.badgeText }], children: unread > 99 ? "99+" : String(unread) }) }) : null
|
|
1653
1720
|
]
|
|
1654
1721
|
}
|
|
1655
1722
|
);
|
|
1656
1723
|
}
|
|
1657
|
-
var
|
|
1724
|
+
var styles7 = reactNative.StyleSheet.create({
|
|
1658
1725
|
flex: {
|
|
1659
1726
|
flex: 1
|
|
1660
1727
|
},
|
|
@@ -1859,11 +1926,11 @@ function AttachmentPicker({
|
|
|
1859
1926
|
animationType: "slide",
|
|
1860
1927
|
onRequestClose: onClose,
|
|
1861
1928
|
...EDGE_TO_EDGE_MODAL,
|
|
1862
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style:
|
|
1929
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style: styles8.backdrop, onPress: onClose, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1863
1930
|
reactNative.View,
|
|
1864
1931
|
{
|
|
1865
1932
|
style: [
|
|
1866
|
-
|
|
1933
|
+
styles8.sheet,
|
|
1867
1934
|
{
|
|
1868
1935
|
backgroundColor: theme.colors.surface,
|
|
1869
1936
|
borderTopLeftRadius: theme.radii.lg,
|
|
@@ -1876,19 +1943,19 @@ function AttachmentPicker({
|
|
|
1876
1943
|
theme.shadows.lg
|
|
1877
1944
|
],
|
|
1878
1945
|
children: [
|
|
1879
|
-
camera ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style:
|
|
1946
|
+
camera ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style: styles8.item, onPress: () => pickFromKind("camera"), children: [
|
|
1880
1947
|
/* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "camera", size: 20, color: theme.colors.textMuted }),
|
|
1881
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
1948
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles8.itemText, { color: theme.colors.text }], children: "Camera" })
|
|
1882
1949
|
] }) : null,
|
|
1883
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style:
|
|
1950
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style: styles8.item, onPress: () => pickFromKind("image"), children: [
|
|
1884
1951
|
/* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "image", size: 20, color: theme.colors.textMuted }),
|
|
1885
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
1952
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles8.itemText, { color: theme.colors.text }], children: "Photo library" })
|
|
1886
1953
|
] }),
|
|
1887
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style:
|
|
1954
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style: styles8.item, onPress: () => pickFromKind("document"), children: [
|
|
1888
1955
|
/* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "attachment", size: 20, color: theme.colors.textMuted }),
|
|
1889
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
1956
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles8.itemText, { color: theme.colors.text }], children: "File" })
|
|
1890
1957
|
] }),
|
|
1891
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style:
|
|
1958
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style: styles8.cancel, onPress: onClose, children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles8.itemText, { color: theme.colors.accent }], children: "Cancel" }) })
|
|
1892
1959
|
]
|
|
1893
1960
|
}
|
|
1894
1961
|
) })
|
|
@@ -2043,7 +2110,7 @@ async function defaultAdapter(kind, { multiple }) {
|
|
|
2043
2110
|
})
|
|
2044
2111
|
);
|
|
2045
2112
|
}
|
|
2046
|
-
var
|
|
2113
|
+
var styles8 = reactNative.StyleSheet.create({
|
|
2047
2114
|
backdrop: {
|
|
2048
2115
|
flex: 1,
|
|
2049
2116
|
backgroundColor: "rgba(0,0,0,0.35)",
|
|
@@ -2073,14 +2140,14 @@ var styles7 = reactNative.StyleSheet.create({
|
|
|
2073
2140
|
});
|
|
2074
2141
|
function DaySeparator({ label, variant = "pill" }) {
|
|
2075
2142
|
const theme = useTheme();
|
|
2076
|
-
const rule = variant === "rule" ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
2077
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
2143
|
+
const rule = variant === "rule" ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles9.rule, { backgroundColor: theme.colors.border }] }) : null;
|
|
2144
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles9.wrap, rule ? styles9.wrapRule : null], children: [
|
|
2078
2145
|
rule,
|
|
2079
2146
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2080
2147
|
reactNative.View,
|
|
2081
2148
|
{
|
|
2082
2149
|
style: [
|
|
2083
|
-
|
|
2150
|
+
styles9.chip,
|
|
2084
2151
|
{
|
|
2085
2152
|
backgroundColor: theme.colors.surfaceAlt,
|
|
2086
2153
|
borderColor: theme.colors.border
|
|
@@ -2090,7 +2157,7 @@ function DaySeparator({ label, variant = "pill" }) {
|
|
|
2090
2157
|
reactNative.Text,
|
|
2091
2158
|
{
|
|
2092
2159
|
style: [
|
|
2093
|
-
|
|
2160
|
+
styles9.label,
|
|
2094
2161
|
{
|
|
2095
2162
|
color: theme.colors.textMuted,
|
|
2096
2163
|
fontFamily: theme.fonts.body
|
|
@@ -2104,7 +2171,7 @@ function DaySeparator({ label, variant = "pill" }) {
|
|
|
2104
2171
|
rule
|
|
2105
2172
|
] });
|
|
2106
2173
|
}
|
|
2107
|
-
var
|
|
2174
|
+
var styles9 = reactNative.StyleSheet.create({
|
|
2108
2175
|
wrap: {
|
|
2109
2176
|
alignItems: "center",
|
|
2110
2177
|
marginVertical: 8
|
|
@@ -2137,7 +2204,7 @@ function LiveCallBanner({ call, inCall, onJoin }) {
|
|
|
2137
2204
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2138
2205
|
reactNative.View,
|
|
2139
2206
|
{
|
|
2140
|
-
style: [
|
|
2207
|
+
style: [styles10.bar, { backgroundColor: theme.colors.success }],
|
|
2141
2208
|
accessibilityRole: "summary",
|
|
2142
2209
|
accessibilityLabel: `${what}, ${who}`,
|
|
2143
2210
|
children: [
|
|
@@ -2150,9 +2217,9 @@ function LiveCallBanner({ call, inCall, onJoin }) {
|
|
|
2150
2217
|
label: null
|
|
2151
2218
|
}
|
|
2152
2219
|
),
|
|
2153
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
2154
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
2155
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
2220
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles10.text, children: [
|
|
2221
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles10.title, { fontFamily: theme.fonts.body }], numberOfLines: 1, children: what }),
|
|
2222
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles10.meta, { fontFamily: theme.fonts.body }], numberOfLines: 1, children: who })
|
|
2156
2223
|
] }),
|
|
2157
2224
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2158
2225
|
reactNative.Pressable,
|
|
@@ -2161,11 +2228,11 @@ function LiveCallBanner({ call, inCall, onJoin }) {
|
|
|
2161
2228
|
accessibilityRole: "button",
|
|
2162
2229
|
accessibilityLabel: "Join call",
|
|
2163
2230
|
hitSlop: 8,
|
|
2164
|
-
style: ({ pressed }) => [
|
|
2231
|
+
style: ({ pressed }) => [styles10.join, pressed && styles10.joinPressed],
|
|
2165
2232
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2166
2233
|
reactNative.Text,
|
|
2167
2234
|
{
|
|
2168
|
-
style: [
|
|
2235
|
+
style: [styles10.joinText, { color: theme.colors.success, fontFamily: theme.fonts.body }],
|
|
2169
2236
|
children: "Join"
|
|
2170
2237
|
}
|
|
2171
2238
|
)
|
|
@@ -2175,7 +2242,7 @@ function LiveCallBanner({ call, inCall, onJoin }) {
|
|
|
2175
2242
|
}
|
|
2176
2243
|
);
|
|
2177
2244
|
}
|
|
2178
|
-
var
|
|
2245
|
+
var styles10 = reactNative.StyleSheet.create({
|
|
2179
2246
|
bar: {
|
|
2180
2247
|
flexDirection: "row",
|
|
2181
2248
|
alignItems: "center",
|
|
@@ -2381,7 +2448,7 @@ function PickerSheet({
|
|
|
2381
2448
|
{
|
|
2382
2449
|
onPress: () => pick(emoji),
|
|
2383
2450
|
style: ({ pressed }) => [
|
|
2384
|
-
|
|
2451
|
+
styles11.cell,
|
|
2385
2452
|
{
|
|
2386
2453
|
borderRadius: theme.radii.sm,
|
|
2387
2454
|
backgroundColor: pressed ? theme.colors.surfaceAlt : void 0
|
|
@@ -2389,15 +2456,15 @@ function PickerSheet({
|
|
|
2389
2456
|
],
|
|
2390
2457
|
accessibilityRole: "button",
|
|
2391
2458
|
accessibilityLabel: emoji,
|
|
2392
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style:
|
|
2459
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: styles11.emoji, children: emoji })
|
|
2393
2460
|
},
|
|
2394
2461
|
emoji
|
|
2395
2462
|
);
|
|
2396
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.KeyboardAvoidingView, { style:
|
|
2463
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.KeyboardAvoidingView, { style: styles11.kav, behavior: "padding", children: [
|
|
2397
2464
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2398
2465
|
reactNative.Pressable,
|
|
2399
2466
|
{
|
|
2400
|
-
style: [
|
|
2467
|
+
style: [styles11.backdrop, { backgroundColor: theme.colors.overlay }],
|
|
2401
2468
|
onPress: onClose,
|
|
2402
2469
|
accessibilityLabel: "Close emoji picker"
|
|
2403
2470
|
}
|
|
@@ -2406,7 +2473,7 @@ function PickerSheet({
|
|
|
2406
2473
|
reactNative.View,
|
|
2407
2474
|
{
|
|
2408
2475
|
style: [
|
|
2409
|
-
|
|
2476
|
+
styles11.sheet,
|
|
2410
2477
|
{
|
|
2411
2478
|
height: Math.round(height * 0.55),
|
|
2412
2479
|
backgroundColor: theme.colors.surface,
|
|
@@ -2419,11 +2486,11 @@ function PickerSheet({
|
|
|
2419
2486
|
theme.shadows.lg
|
|
2420
2487
|
],
|
|
2421
2488
|
children: [
|
|
2422
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
2489
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles11.headRow, children: [
|
|
2423
2490
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2424
2491
|
reactNative.Text,
|
|
2425
2492
|
{
|
|
2426
|
-
style: [
|
|
2493
|
+
style: [styles11.title, { color: theme.colors.text, fontFamily: theme.fonts.display }],
|
|
2427
2494
|
accessibilityRole: "header",
|
|
2428
2495
|
children: title
|
|
2429
2496
|
}
|
|
@@ -2434,7 +2501,7 @@ function PickerSheet({
|
|
|
2434
2501
|
reactNative.View,
|
|
2435
2502
|
{
|
|
2436
2503
|
style: [
|
|
2437
|
-
|
|
2504
|
+
styles11.search,
|
|
2438
2505
|
{ backgroundColor: theme.colors.surfaceAlt, borderRadius: theme.radii.md }
|
|
2439
2506
|
],
|
|
2440
2507
|
children: [
|
|
@@ -2448,19 +2515,19 @@ function PickerSheet({
|
|
|
2448
2515
|
placeholderTextColor: theme.colors.textSubtle,
|
|
2449
2516
|
autoCorrect: false,
|
|
2450
2517
|
autoCapitalize: "none",
|
|
2451
|
-
style: [
|
|
2518
|
+
style: [styles11.searchInput, { color: theme.colors.text, fontFamily: theme.fonts.body }],
|
|
2452
2519
|
accessibilityLabel: "Search emoji"
|
|
2453
2520
|
}
|
|
2454
2521
|
)
|
|
2455
2522
|
]
|
|
2456
2523
|
}
|
|
2457
2524
|
),
|
|
2458
|
-
query.trim() ? results.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
2459
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
2525
|
+
query.trim() ? results.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles11.results, children: results.map((r) => cell(r.emoji)) }) : /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles11.empty, { color: theme.colors.textMuted }], children: "No emoji found." }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2526
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles11.tabs, { borderBottomColor: theme.colors.border }], children: sections.map((s, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2460
2527
|
reactNative.Pressable,
|
|
2461
2528
|
{
|
|
2462
2529
|
hitSlop: 4,
|
|
2463
|
-
style:
|
|
2530
|
+
style: styles11.tab,
|
|
2464
2531
|
onPress: () => listRef.current?.scrollToLocation({
|
|
2465
2532
|
sectionIndex: i,
|
|
2466
2533
|
itemIndex: 0,
|
|
@@ -2469,7 +2536,7 @@ function PickerSheet({
|
|
|
2469
2536
|
}),
|
|
2470
2537
|
accessibilityRole: "button",
|
|
2471
2538
|
accessibilityLabel: s.title,
|
|
2472
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style:
|
|
2539
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: styles11.tabEmoji, children: s.id === "recent" ? "\u{1F558}" : s.data[0]?.[0] })
|
|
2473
2540
|
},
|
|
2474
2541
|
s.id
|
|
2475
2542
|
)) }),
|
|
@@ -2483,8 +2550,8 @@ function PickerSheet({
|
|
|
2483
2550
|
stickySectionHeadersEnabled: false,
|
|
2484
2551
|
initialNumToRender: 8,
|
|
2485
2552
|
onScrollToIndexFailed: () => void 0,
|
|
2486
|
-
renderSectionHeader: ({ section }) => /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
2487
|
-
renderItem: ({ item }) => /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
2553
|
+
renderSectionHeader: ({ section }) => /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles11.sectionTitle, { color: theme.colors.textMuted }], children: section.title }),
|
|
2554
|
+
renderItem: ({ item }) => /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles11.gridRow, children: item.map(cell) })
|
|
2488
2555
|
}
|
|
2489
2556
|
)
|
|
2490
2557
|
] })
|
|
@@ -2498,7 +2565,7 @@ function chunk(list, size) {
|
|
|
2498
2565
|
for (let i = 0; i < list.length; i += size) out.push(list.slice(i, i + size));
|
|
2499
2566
|
return out;
|
|
2500
2567
|
}
|
|
2501
|
-
var
|
|
2568
|
+
var styles11 = reactNative.StyleSheet.create({
|
|
2502
2569
|
kav: {
|
|
2503
2570
|
flex: 1,
|
|
2504
2571
|
justifyContent: "flex-end"
|
|
@@ -2589,8 +2656,8 @@ function UploadQueueStrip() {
|
|
|
2589
2656
|
{
|
|
2590
2657
|
horizontal: true,
|
|
2591
2658
|
showsHorizontalScrollIndicator: false,
|
|
2592
|
-
contentContainerStyle:
|
|
2593
|
-
style: [
|
|
2659
|
+
contentContainerStyle: styles12.scroll,
|
|
2660
|
+
style: [styles12.scrollStyle, { marginBottom: 8 }],
|
|
2594
2661
|
children: upload.queue.map((item) => {
|
|
2595
2662
|
const isError = item.status === "error";
|
|
2596
2663
|
const isUploading = item.status === "uploading" || item.status === "pending";
|
|
@@ -2601,7 +2668,7 @@ function UploadQueueStrip() {
|
|
|
2601
2668
|
if (item.status === "ready" || isError) upload.remove(item.localId);
|
|
2602
2669
|
else upload.cancel(item.localId);
|
|
2603
2670
|
};
|
|
2604
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
2671
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles12.tileWrap, children: [
|
|
2605
2672
|
isImage && previewUri ? /* @__PURE__ */ jsxRuntime.jsx(ImageTile, { uri: previewUri, uploading: isUploading, error: isError }) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
2606
2673
|
FileTile,
|
|
2607
2674
|
{
|
|
@@ -2616,13 +2683,13 @@ function UploadQueueStrip() {
|
|
|
2616
2683
|
{
|
|
2617
2684
|
onPress: handleClose,
|
|
2618
2685
|
hitSlop: 8,
|
|
2619
|
-
style:
|
|
2686
|
+
style: styles12.closeBtn,
|
|
2620
2687
|
accessibilityLabel: isError ? "Remove failed upload" : "Cancel upload",
|
|
2621
2688
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "close", size: 11, color: "#fff" })
|
|
2622
2689
|
}
|
|
2623
2690
|
) : null,
|
|
2624
|
-
isUploading ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
2625
|
-
isError ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
2691
|
+
isUploading ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles12.progressOverlay, children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles12.spinner, { borderColor: theme.colors.accentText }] }) }) : null,
|
|
2692
|
+
isError ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles12.errorOverlay, { backgroundColor: "rgba(229,72,77,0.85)" }], children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles12.errorText, { color: "#fff" }], children: "Failed" }) }) : null
|
|
2626
2693
|
] }, item.localId);
|
|
2627
2694
|
})
|
|
2628
2695
|
}
|
|
@@ -2635,7 +2702,7 @@ function ImageTile({ uri, uploading, error }) {
|
|
|
2635
2702
|
{
|
|
2636
2703
|
source: { uri },
|
|
2637
2704
|
style: [
|
|
2638
|
-
|
|
2705
|
+
styles12.imageTile,
|
|
2639
2706
|
{
|
|
2640
2707
|
backgroundColor: theme.colors.surfaceAlt,
|
|
2641
2708
|
borderColor: error ? theme.colors.danger : "transparent",
|
|
@@ -2657,24 +2724,24 @@ function FileTile({
|
|
|
2657
2724
|
reactNative.View,
|
|
2658
2725
|
{
|
|
2659
2726
|
style: [
|
|
2660
|
-
|
|
2727
|
+
styles12.fileTile,
|
|
2661
2728
|
{
|
|
2662
2729
|
backgroundColor: theme.colors.surfaceAlt,
|
|
2663
2730
|
borderColor: error ? theme.colors.danger : uploading ? theme.colors.accent : theme.colors.border
|
|
2664
2731
|
}
|
|
2665
2732
|
],
|
|
2666
2733
|
children: [
|
|
2667
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
2668
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
2734
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles12.fileIconBox, { backgroundColor: theme.colors.accentSoft }], children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "attachment", size: 18, color: theme.colors.accent }) }),
|
|
2735
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles12.fileInfo, children: [
|
|
2669
2736
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2670
2737
|
reactNative.Text,
|
|
2671
2738
|
{
|
|
2672
|
-
style: [
|
|
2739
|
+
style: [styles12.fileName, { color: theme.colors.text, fontFamily: theme.fonts.body }],
|
|
2673
2740
|
numberOfLines: 1,
|
|
2674
2741
|
children: filename
|
|
2675
2742
|
}
|
|
2676
2743
|
),
|
|
2677
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
2744
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles12.fileSize, { color: theme.colors.textSubtle }], children: formatBytes2(size) })
|
|
2678
2745
|
] })
|
|
2679
2746
|
]
|
|
2680
2747
|
}
|
|
@@ -2688,7 +2755,7 @@ function formatBytes2(n) {
|
|
|
2688
2755
|
return `${(n / 1024 / 1024 / 1024).toFixed(1)} GB`;
|
|
2689
2756
|
}
|
|
2690
2757
|
var TILE = 64;
|
|
2691
|
-
var
|
|
2758
|
+
var styles12 = reactNative.StyleSheet.create({
|
|
2692
2759
|
scrollStyle: {
|
|
2693
2760
|
overflow: "visible"
|
|
2694
2761
|
},
|
|
@@ -2922,7 +2989,7 @@ var MessageComposer = react.forwardRef(
|
|
|
2922
2989
|
reactNative.View,
|
|
2923
2990
|
{
|
|
2924
2991
|
style: [
|
|
2925
|
-
|
|
2992
|
+
styles13.wrap,
|
|
2926
2993
|
{
|
|
2927
2994
|
backgroundColor: theme.colors.surface,
|
|
2928
2995
|
borderTopColor: theme.colors.border,
|
|
@@ -2946,13 +3013,14 @@ var MessageComposer = react.forwardRef(
|
|
|
2946
3013
|
) : null,
|
|
2947
3014
|
attachments && !isEditing ? /* @__PURE__ */ jsxRuntime.jsx(UploadQueueStrip, {}) : null,
|
|
2948
3015
|
isEditing ? null : accessory,
|
|
2949
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
3016
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles13.row, children: [
|
|
2950
3017
|
attachments && onAttachPress ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
2951
3018
|
reactNative.Pressable,
|
|
2952
3019
|
{
|
|
2953
3020
|
onPress: onAttachPress,
|
|
2954
3021
|
hitSlop: 8,
|
|
2955
|
-
style:
|
|
3022
|
+
style: styles13.iconBtn,
|
|
3023
|
+
accessibilityRole: "button",
|
|
2956
3024
|
accessibilityLabel: "Attach file",
|
|
2957
3025
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "attachment", size: 22, color: theme.colors.textMuted })
|
|
2958
3026
|
}
|
|
@@ -2962,7 +3030,7 @@ var MessageComposer = react.forwardRef(
|
|
|
2962
3030
|
{
|
|
2963
3031
|
onPress: () => setEmojiOpen(true),
|
|
2964
3032
|
hitSlop: 8,
|
|
2965
|
-
style:
|
|
3033
|
+
style: styles13.iconBtn,
|
|
2966
3034
|
accessibilityRole: "button",
|
|
2967
3035
|
accessibilityLabel: "Insert emoji",
|
|
2968
3036
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "emoji", size: 22, color: theme.colors.textMuted, label: null })
|
|
@@ -2982,11 +3050,12 @@ var MessageComposer = react.forwardRef(
|
|
|
2982
3050
|
if (!isEditing) onSelectionChange?.(e.nativeEvent.selection);
|
|
2983
3051
|
},
|
|
2984
3052
|
placeholder,
|
|
3053
|
+
accessibilityLabel: placeholder,
|
|
2985
3054
|
placeholderTextColor: theme.colors.textSubtle,
|
|
2986
3055
|
multiline: true,
|
|
2987
3056
|
editable: !disabled,
|
|
2988
3057
|
style: [
|
|
2989
|
-
|
|
3058
|
+
styles13.input,
|
|
2990
3059
|
{
|
|
2991
3060
|
color: theme.colors.text,
|
|
2992
3061
|
backgroundColor: theme.colors.surfaceAlt,
|
|
@@ -3003,12 +3072,13 @@ var MessageComposer = react.forwardRef(
|
|
|
3003
3072
|
onPress: handleSend,
|
|
3004
3073
|
disabled: submitDisabled,
|
|
3005
3074
|
style: [
|
|
3006
|
-
|
|
3075
|
+
styles13.sendBtn,
|
|
3007
3076
|
{
|
|
3008
3077
|
backgroundColor: submitDisabled ? theme.colors.textSubtle : theme.colors.accent,
|
|
3009
3078
|
opacity: submitDisabled ? 0.6 : 1
|
|
3010
3079
|
}
|
|
3011
3080
|
],
|
|
3081
|
+
accessibilityRole: "button",
|
|
3012
3082
|
accessibilityLabel: "Send message",
|
|
3013
3083
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "send", size: 18, color: theme.colors.accentText })
|
|
3014
3084
|
}
|
|
@@ -3046,7 +3116,7 @@ function EditChip({ message, onCancel }) {
|
|
|
3046
3116
|
reactNative.View,
|
|
3047
3117
|
{
|
|
3048
3118
|
style: [
|
|
3049
|
-
|
|
3119
|
+
styles13.replyChip,
|
|
3050
3120
|
{
|
|
3051
3121
|
backgroundColor: theme.colors.surfaceAlt,
|
|
3052
3122
|
borderLeftColor: theme.colors.accent
|
|
@@ -3054,10 +3124,10 @@ function EditChip({ message, onCancel }) {
|
|
|
3054
3124
|
],
|
|
3055
3125
|
children: [
|
|
3056
3126
|
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: { flex: 1 }, children: [
|
|
3057
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3058
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3127
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles13.replyName, { color: theme.colors.accent }], children: "Editing message" }),
|
|
3128
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles13.replyBody, { color: theme.colors.textMuted }], numberOfLines: 1, children: message.body ?? "\u2026" })
|
|
3059
3129
|
] }),
|
|
3060
|
-
onCancel ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { onPress: onCancel, hitSlop: 8, style:
|
|
3130
|
+
onCancel ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { onPress: onCancel, hitSlop: 8, style: styles13.replyCancel, children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "close", size: 16, color: theme.colors.textMuted }) }) : null
|
|
3061
3131
|
]
|
|
3062
3132
|
}
|
|
3063
3133
|
);
|
|
@@ -3074,7 +3144,7 @@ function ReplyChip({
|
|
|
3074
3144
|
reactNative.View,
|
|
3075
3145
|
{
|
|
3076
3146
|
style: [
|
|
3077
|
-
|
|
3147
|
+
styles13.replyChip,
|
|
3078
3148
|
{
|
|
3079
3149
|
backgroundColor: theme.colors.surfaceAlt,
|
|
3080
3150
|
borderLeftColor: theme.colors.accent
|
|
@@ -3082,18 +3152,18 @@ function ReplyChip({
|
|
|
3082
3152
|
],
|
|
3083
3153
|
children: [
|
|
3084
3154
|
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: { flex: 1 }, children: [
|
|
3085
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Text, { style: [
|
|
3155
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Text, { style: [styles13.replyName, { color: theme.colors.accent }], children: [
|
|
3086
3156
|
"Replying to ",
|
|
3087
3157
|
senderName
|
|
3088
3158
|
] }),
|
|
3089
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3159
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles13.replyBody, { color: theme.colors.textMuted }], numberOfLines: 1, children: message.body ?? "\u2026" })
|
|
3090
3160
|
] }),
|
|
3091
|
-
onCancel ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { onPress: onCancel, hitSlop: 8, style:
|
|
3161
|
+
onCancel ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { onPress: onCancel, hitSlop: 8, style: styles13.replyCancel, children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "close", size: 16, color: theme.colors.textMuted }) }) : null
|
|
3092
3162
|
]
|
|
3093
3163
|
}
|
|
3094
3164
|
);
|
|
3095
3165
|
}
|
|
3096
|
-
var
|
|
3166
|
+
var styles13 = reactNative.StyleSheet.create({
|
|
3097
3167
|
wrap: {
|
|
3098
3168
|
borderTopWidth: reactNative.StyleSheet.hairlineWidth,
|
|
3099
3169
|
paddingTop: 8,
|
|
@@ -3204,7 +3274,7 @@ function MentionInput({
|
|
|
3204
3274
|
reactNative.View,
|
|
3205
3275
|
{
|
|
3206
3276
|
style: [
|
|
3207
|
-
|
|
3277
|
+
styles14.suggestions,
|
|
3208
3278
|
{
|
|
3209
3279
|
backgroundColor: theme.colors.surface,
|
|
3210
3280
|
borderColor: theme.colors.border,
|
|
@@ -3215,7 +3285,7 @@ function MentionInput({
|
|
|
3215
3285
|
accessibilityRole: "menu",
|
|
3216
3286
|
accessibilityLabel: "Mention suggestions",
|
|
3217
3287
|
children: [
|
|
3218
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.ScrollView, { keyboardShouldPersistTaps: "always", style:
|
|
3288
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.ScrollView, { keyboardShouldPersistTaps: "always", style: styles14.suggestionScroll, children: candidates.map((c) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
3219
3289
|
MentionRow,
|
|
3220
3290
|
{
|
|
3221
3291
|
externalId: c.externalId,
|
|
@@ -3228,7 +3298,7 @@ function MentionInput({
|
|
|
3228
3298
|
reactNative.Pressable,
|
|
3229
3299
|
{
|
|
3230
3300
|
onPress: () => setDismissedAt(query.start),
|
|
3231
|
-
style:
|
|
3301
|
+
style: styles14.dismiss,
|
|
3232
3302
|
accessibilityRole: "button",
|
|
3233
3303
|
accessibilityLabel: "Dismiss suggestions",
|
|
3234
3304
|
hitSlop: 6,
|
|
@@ -3271,7 +3341,7 @@ function MentionRow({
|
|
|
3271
3341
|
{
|
|
3272
3342
|
onPress,
|
|
3273
3343
|
style: ({ pressed }) => [
|
|
3274
|
-
|
|
3344
|
+
styles14.row,
|
|
3275
3345
|
{ backgroundColor: pressed ? theme.colors.surfaceAlt : "transparent" }
|
|
3276
3346
|
],
|
|
3277
3347
|
accessibilityRole: "menuitem",
|
|
@@ -3281,17 +3351,16 @@ function MentionRow({
|
|
|
3281
3351
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3282
3352
|
reactNative.Text,
|
|
3283
3353
|
{
|
|
3284
|
-
style: [
|
|
3354
|
+
style: [styles14.rowText, { color: theme.colors.text, fontFamily: theme.fonts.body }],
|
|
3285
3355
|
numberOfLines: 1,
|
|
3286
3356
|
children: name
|
|
3287
3357
|
}
|
|
3288
|
-
)
|
|
3289
|
-
name !== externalId ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles13.rowId, { color: theme.colors.textSubtle }], numberOfLines: 1, children: externalId }) : null
|
|
3358
|
+
)
|
|
3290
3359
|
]
|
|
3291
3360
|
}
|
|
3292
3361
|
);
|
|
3293
3362
|
}
|
|
3294
|
-
var
|
|
3363
|
+
var styles14 = reactNative.StyleSheet.create({
|
|
3295
3364
|
suggestions: {
|
|
3296
3365
|
borderWidth: reactNative.StyleSheet.hairlineWidth,
|
|
3297
3366
|
marginBottom: 8,
|
|
@@ -3307,14 +3376,12 @@ var styles13 = reactNative.StyleSheet.create({
|
|
|
3307
3376
|
paddingVertical: 8,
|
|
3308
3377
|
gap: 10
|
|
3309
3378
|
},
|
|
3379
|
+
// The name alone, with the whole row's width: an id next to it only
|
|
3380
|
+
// pushed the name out.
|
|
3310
3381
|
rowText: {
|
|
3382
|
+
flex: 1,
|
|
3311
3383
|
fontSize: 14,
|
|
3312
|
-
fontWeight: "500"
|
|
3313
|
-
flexShrink: 1
|
|
3314
|
-
},
|
|
3315
|
-
rowId: {
|
|
3316
|
-
fontSize: 12,
|
|
3317
|
-
flexShrink: 1
|
|
3384
|
+
fontWeight: "500"
|
|
3318
3385
|
},
|
|
3319
3386
|
dismiss: {
|
|
3320
3387
|
position: "absolute",
|
|
@@ -3425,15 +3492,15 @@ function MessageList({
|
|
|
3425
3492
|
[renderItem, data.length]
|
|
3426
3493
|
);
|
|
3427
3494
|
if (loading && messages.length === 0) {
|
|
3428
|
-
return /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
3495
|
+
return /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles15.placeholder, { backgroundColor: theme.colors.background }], children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.ActivityIndicator, { color: theme.colors.accent }) });
|
|
3429
3496
|
}
|
|
3430
3497
|
if (messages.length === 0) {
|
|
3431
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
3432
|
-
ListHeader ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
3498
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles15.placeholder, { backgroundColor: theme.colors.background }], children: [
|
|
3499
|
+
ListHeader ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles15.emptyHeader, children: ListHeader }) : null,
|
|
3433
3500
|
typeof emptyState === "string" ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: { color: theme.colors.textSubtle, fontFamily: theme.fonts.body }, children: emptyState }) : emptyState ?? null
|
|
3434
3501
|
] });
|
|
3435
3502
|
}
|
|
3436
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
3503
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles15.root, children: [
|
|
3437
3504
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3438
3505
|
reactNative.FlatList,
|
|
3439
3506
|
{
|
|
@@ -3463,7 +3530,7 @@ function MessageList({
|
|
|
3463
3530
|
{
|
|
3464
3531
|
onPress: scrollToBottom,
|
|
3465
3532
|
style: [
|
|
3466
|
-
|
|
3533
|
+
styles15.jumpButton,
|
|
3467
3534
|
{
|
|
3468
3535
|
backgroundColor: theme.colors.accent
|
|
3469
3536
|
},
|
|
@@ -3472,7 +3539,7 @@ function MessageList({
|
|
|
3472
3539
|
accessibilityLabel: `${newCount} new ${newCount === 1 ? "message" : "messages"}, jump to latest`,
|
|
3473
3540
|
children: [
|
|
3474
3541
|
/* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "chevron-down", size: 14, color: theme.colors.accentText }),
|
|
3475
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Text, { style: [
|
|
3542
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.Text, { style: [styles15.jumpText, { color: theme.colors.accentText }], children: [
|
|
3476
3543
|
newCount,
|
|
3477
3544
|
" new ",
|
|
3478
3545
|
newCount === 1 ? "message" : "messages"
|
|
@@ -3483,7 +3550,7 @@ function MessageList({
|
|
|
3483
3550
|
] });
|
|
3484
3551
|
}
|
|
3485
3552
|
var VIEWABILITY = { itemVisiblePercentThreshold: 50 };
|
|
3486
|
-
var
|
|
3553
|
+
var styles15 = reactNative.StyleSheet.create({
|
|
3487
3554
|
root: {
|
|
3488
3555
|
flex: 1
|
|
3489
3556
|
},
|
|
@@ -3522,13 +3589,13 @@ function CallLogRow({ msg, meId, onCallBack }) {
|
|
|
3522
3589
|
const accent = display.missed ? theme.colors.danger : theme.colors.textSubtle;
|
|
3523
3590
|
const time = formatTime(msg.inserted_at);
|
|
3524
3591
|
const label = [display.title, display.detail, time].filter(Boolean).join(", ");
|
|
3525
|
-
const metaStyle = [
|
|
3526
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
3592
|
+
const metaStyle = [styles16.meta, { color: theme.colors.textSubtle, fontFamily: theme.fonts.body }];
|
|
3593
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles16.wrap, accessible: true, accessibilityLabel: label, children: [
|
|
3527
3594
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
3528
3595
|
reactNative.View,
|
|
3529
3596
|
{
|
|
3530
3597
|
style: [
|
|
3531
|
-
|
|
3598
|
+
styles16.chip,
|
|
3532
3599
|
{
|
|
3533
3600
|
backgroundColor: theme.colors.surfaceAlt,
|
|
3534
3601
|
borderColor: theme.colors.border
|
|
@@ -3540,7 +3607,7 @@ function CallLogRow({ msg, meId, onCallBack }) {
|
|
|
3540
3607
|
reactNative.Text,
|
|
3541
3608
|
{
|
|
3542
3609
|
style: [
|
|
3543
|
-
|
|
3610
|
+
styles16.title,
|
|
3544
3611
|
{
|
|
3545
3612
|
color: display.missed ? theme.colors.danger : theme.colors.textMuted,
|
|
3546
3613
|
fontFamily: theme.fonts.body
|
|
@@ -3568,12 +3635,12 @@ function CallLogRow({ msg, meId, onCallBack }) {
|
|
|
3568
3635
|
accessibilityRole: "button",
|
|
3569
3636
|
accessibilityLabel: display.media === "video" ? "Video call back" : "Call back",
|
|
3570
3637
|
hitSlop: 8,
|
|
3571
|
-
style: ({ pressed }) => [
|
|
3638
|
+
style: ({ pressed }) => [styles16.callBack, pressed && styles16.callBackPressed],
|
|
3572
3639
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3573
3640
|
reactNative.Text,
|
|
3574
3641
|
{
|
|
3575
3642
|
style: [
|
|
3576
|
-
|
|
3643
|
+
styles16.callBackText,
|
|
3577
3644
|
{ color: theme.colors.accent, fontFamily: theme.fonts.body }
|
|
3578
3645
|
],
|
|
3579
3646
|
children: "Call back"
|
|
@@ -3588,7 +3655,7 @@ function formatTime(iso) {
|
|
|
3588
3655
|
if (Number.isNaN(d.getTime())) return "";
|
|
3589
3656
|
return d.toLocaleTimeString([], { hour: "numeric", minute: "2-digit" });
|
|
3590
3657
|
}
|
|
3591
|
-
var
|
|
3658
|
+
var styles16 = reactNative.StyleSheet.create({
|
|
3592
3659
|
wrap: {
|
|
3593
3660
|
alignItems: "center",
|
|
3594
3661
|
alignSelf: "stretch",
|
|
@@ -3662,12 +3729,12 @@ function EditHistorySheet({
|
|
|
3662
3729
|
live = false;
|
|
3663
3730
|
};
|
|
3664
3731
|
}, [visible, messageId, chat]);
|
|
3665
|
-
const entry = (key, label, body, when) => /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
3666
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
3667
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3668
|
-
when ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3732
|
+
const entry = (key, label, body, when) => /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles17.entry, { borderBottomColor: theme.colors.border }], children: [
|
|
3733
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles17.entryHead, children: [
|
|
3734
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles17.entryLabel, { color: theme.colors.textMuted }], children: label }),
|
|
3735
|
+
when ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles17.entryTime, { color: theme.colors.textSubtle }], children: when }) : null
|
|
3669
3736
|
] }),
|
|
3670
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3737
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles17.entryBody, { color: theme.colors.text, fontFamily: theme.fonts.body }], children: body ?? "\u2014" })
|
|
3671
3738
|
] }, key);
|
|
3672
3739
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
3673
3740
|
reactNative.Modal,
|
|
@@ -3680,14 +3747,14 @@ function EditHistorySheet({
|
|
|
3680
3747
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3681
3748
|
reactNative.Pressable,
|
|
3682
3749
|
{
|
|
3683
|
-
style: [
|
|
3750
|
+
style: [styles17.backdrop, { backgroundColor: theme.colors.overlay }],
|
|
3684
3751
|
onPress: onClose,
|
|
3685
3752
|
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3686
3753
|
reactNative.Pressable,
|
|
3687
3754
|
{
|
|
3688
3755
|
onPress: () => void 0,
|
|
3689
3756
|
style: [
|
|
3690
|
-
|
|
3757
|
+
styles17.sheet,
|
|
3691
3758
|
{
|
|
3692
3759
|
backgroundColor: theme.colors.surface,
|
|
3693
3760
|
borderTopLeftRadius: theme.radii.lg,
|
|
@@ -3702,12 +3769,12 @@ function EditHistorySheet({
|
|
|
3702
3769
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3703
3770
|
reactNative.Text,
|
|
3704
3771
|
{
|
|
3705
|
-
style: [
|
|
3772
|
+
style: [styles17.title, { color: theme.colors.text, fontFamily: theme.fonts.display }],
|
|
3706
3773
|
accessibilityRole: "header",
|
|
3707
3774
|
children: "Edit history"
|
|
3708
3775
|
}
|
|
3709
3776
|
),
|
|
3710
|
-
failed ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3777
|
+
failed ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles17.status, { color: theme.colors.textMuted }], children: "Couldn't load the earlier versions." }) : edits === null ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.ActivityIndicator, { color: theme.colors.accent, style: styles17.spinner }) : /* @__PURE__ */ jsxRuntime.jsxs(reactNative.ScrollView, { style: styles17.scroll, children: [
|
|
3711
3778
|
currentBody !== void 0 ? entry("current", "Current", currentBody, "") : null,
|
|
3712
3779
|
edits.map(
|
|
3713
3780
|
(e) => entry(
|
|
@@ -3717,7 +3784,7 @@ function EditHistorySheet({
|
|
|
3717
3784
|
relativeTime(e.written_at)
|
|
3718
3785
|
)
|
|
3719
3786
|
),
|
|
3720
|
-
edits.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3787
|
+
edits.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles17.status, { color: theme.colors.textMuted }], children: "No earlier versions." }) : null
|
|
3721
3788
|
] })
|
|
3722
3789
|
]
|
|
3723
3790
|
}
|
|
@@ -3727,7 +3794,7 @@ function EditHistorySheet({
|
|
|
3727
3794
|
}
|
|
3728
3795
|
);
|
|
3729
3796
|
}
|
|
3730
|
-
var
|
|
3797
|
+
var styles17 = reactNative.StyleSheet.create({
|
|
3731
3798
|
backdrop: {
|
|
3732
3799
|
flex: 1,
|
|
3733
3800
|
justifyContent: "flex-end"
|
|
@@ -3805,7 +3872,7 @@ function AttachmentPreview({
|
|
|
3805
3872
|
reactNative.View,
|
|
3806
3873
|
{
|
|
3807
3874
|
style: [
|
|
3808
|
-
|
|
3875
|
+
styles18.imagePlaceholder,
|
|
3809
3876
|
{
|
|
3810
3877
|
width: maxWidth,
|
|
3811
3878
|
height: 200,
|
|
@@ -3825,7 +3892,7 @@ function AttachmentPreview({
|
|
|
3825
3892
|
onPress,
|
|
3826
3893
|
disabled: !onPress,
|
|
3827
3894
|
style: [
|
|
3828
|
-
|
|
3895
|
+
styles18.fileCard,
|
|
3829
3896
|
{
|
|
3830
3897
|
backgroundColor: onBrand ? "rgba(255,255,255,0.18)" : theme.colors.surfaceAlt,
|
|
3831
3898
|
borderColor: onBrand ? "transparent" : theme.colors.border,
|
|
@@ -3838,12 +3905,12 @@ function AttachmentPreview({
|
|
|
3838
3905
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3839
3906
|
reactNative.Text,
|
|
3840
3907
|
{
|
|
3841
|
-
style: [
|
|
3908
|
+
style: [styles18.fileName, { color: ink, fontFamily: theme.fonts.body }],
|
|
3842
3909
|
numberOfLines: 1,
|
|
3843
3910
|
children: attachment.original_filename ?? "file"
|
|
3844
3911
|
}
|
|
3845
3912
|
),
|
|
3846
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
3913
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles18.fileSize, { color: inkSoft, opacity: onBrand ? 0.8 : 1 }], children: formatBytes3(attachment.byte_size) })
|
|
3847
3914
|
] })
|
|
3848
3915
|
]
|
|
3849
3916
|
}
|
|
@@ -3855,7 +3922,7 @@ function formatBytes3(n) {
|
|
|
3855
3922
|
if (n < 1024 * 1024 * 1024) return `${(n / 1024 / 1024).toFixed(1)} MB`;
|
|
3856
3923
|
return `${(n / 1024 / 1024 / 1024).toFixed(1)} GB`;
|
|
3857
3924
|
}
|
|
3858
|
-
var
|
|
3925
|
+
var styles18 = reactNative.StyleSheet.create({
|
|
3859
3926
|
imagePlaceholder: {},
|
|
3860
3927
|
fileCard: {
|
|
3861
3928
|
flexDirection: "row",
|
|
@@ -3891,7 +3958,7 @@ function ImageMosaic({
|
|
|
3891
3958
|
reactNative.View,
|
|
3892
3959
|
{
|
|
3893
3960
|
style: [
|
|
3894
|
-
|
|
3961
|
+
styles19.root,
|
|
3895
3962
|
{
|
|
3896
3963
|
borderTopLeftRadius: r,
|
|
3897
3964
|
borderTopRightRadius: r,
|
|
@@ -3912,18 +3979,18 @@ function ImageMosaic({
|
|
|
3912
3979
|
{
|
|
3913
3980
|
onLongPress,
|
|
3914
3981
|
attachment: visible[0],
|
|
3915
|
-
style:
|
|
3982
|
+
style: styles19.tileFull,
|
|
3916
3983
|
onPress: () => setViewerIndex(0),
|
|
3917
3984
|
overlay: null
|
|
3918
3985
|
}
|
|
3919
3986
|
) : null,
|
|
3920
|
-
n === 2 ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
3987
|
+
n === 2 ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles19.rowEven, children: [
|
|
3921
3988
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3922
3989
|
Tile,
|
|
3923
3990
|
{
|
|
3924
3991
|
onLongPress,
|
|
3925
3992
|
attachment: visible[0],
|
|
3926
|
-
style:
|
|
3993
|
+
style: styles19.tileHalfSquare,
|
|
3927
3994
|
onPress: () => setViewerIndex(0),
|
|
3928
3995
|
overlay: null
|
|
3929
3996
|
}
|
|
@@ -3933,7 +4000,7 @@ function ImageMosaic({
|
|
|
3933
4000
|
{
|
|
3934
4001
|
onLongPress,
|
|
3935
4002
|
attachment: visible[1],
|
|
3936
|
-
style:
|
|
4003
|
+
style: styles19.tileHalfSquare,
|
|
3937
4004
|
onPress: () => setViewerIndex(1),
|
|
3938
4005
|
overlay: null
|
|
3939
4006
|
}
|
|
@@ -3945,18 +4012,18 @@ function ImageMosaic({
|
|
|
3945
4012
|
{
|
|
3946
4013
|
onLongPress,
|
|
3947
4014
|
attachment: visible[0],
|
|
3948
|
-
style:
|
|
4015
|
+
style: styles19.tileHero,
|
|
3949
4016
|
onPress: () => setViewerIndex(0),
|
|
3950
4017
|
overlay: null
|
|
3951
4018
|
}
|
|
3952
4019
|
),
|
|
3953
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
4020
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles19.rowEven, { marginTop: 2 }], children: [
|
|
3954
4021
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3955
4022
|
Tile,
|
|
3956
4023
|
{
|
|
3957
4024
|
onLongPress,
|
|
3958
4025
|
attachment: visible[1],
|
|
3959
|
-
style:
|
|
4026
|
+
style: styles19.tileHalfSquare,
|
|
3960
4027
|
onPress: () => setViewerIndex(1),
|
|
3961
4028
|
overlay: null
|
|
3962
4029
|
}
|
|
@@ -3966,7 +4033,7 @@ function ImageMosaic({
|
|
|
3966
4033
|
{
|
|
3967
4034
|
onLongPress,
|
|
3968
4035
|
attachment: visible[2],
|
|
3969
|
-
style:
|
|
4036
|
+
style: styles19.tileHalfSquare,
|
|
3970
4037
|
onPress: () => setViewerIndex(2),
|
|
3971
4038
|
overlay: null
|
|
3972
4039
|
}
|
|
@@ -3974,13 +4041,13 @@ function ImageMosaic({
|
|
|
3974
4041
|
] })
|
|
3975
4042
|
] }) : null,
|
|
3976
4043
|
n === 4 ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
3977
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
4044
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles19.rowEven, children: [
|
|
3978
4045
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3979
4046
|
Tile,
|
|
3980
4047
|
{
|
|
3981
4048
|
onLongPress,
|
|
3982
4049
|
attachment: visible[0],
|
|
3983
|
-
style:
|
|
4050
|
+
style: styles19.tileHalfSquare,
|
|
3984
4051
|
onPress: () => setViewerIndex(0),
|
|
3985
4052
|
overlay: null
|
|
3986
4053
|
}
|
|
@@ -3990,19 +4057,19 @@ function ImageMosaic({
|
|
|
3990
4057
|
{
|
|
3991
4058
|
onLongPress,
|
|
3992
4059
|
attachment: visible[1],
|
|
3993
|
-
style:
|
|
4060
|
+
style: styles19.tileHalfSquare,
|
|
3994
4061
|
onPress: () => setViewerIndex(1),
|
|
3995
4062
|
overlay: null
|
|
3996
4063
|
}
|
|
3997
4064
|
)
|
|
3998
4065
|
] }),
|
|
3999
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
4066
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles19.rowEven, { marginTop: 2 }], children: [
|
|
4000
4067
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4001
4068
|
Tile,
|
|
4002
4069
|
{
|
|
4003
4070
|
onLongPress,
|
|
4004
4071
|
attachment: visible[2],
|
|
4005
|
-
style:
|
|
4072
|
+
style: styles19.tileHalfSquare,
|
|
4006
4073
|
onPress: () => setViewerIndex(2),
|
|
4007
4074
|
overlay: null
|
|
4008
4075
|
}
|
|
@@ -4012,7 +4079,7 @@ function ImageMosaic({
|
|
|
4012
4079
|
{
|
|
4013
4080
|
onLongPress,
|
|
4014
4081
|
attachment: visible[3],
|
|
4015
|
-
style:
|
|
4082
|
+
style: styles19.tileHalfSquare,
|
|
4016
4083
|
onPress: () => setViewerIndex(3),
|
|
4017
4084
|
overlay: overflow > 0 ? `+${overflow}` : null
|
|
4018
4085
|
}
|
|
@@ -4050,18 +4117,18 @@ function Tile({
|
|
|
4050
4117
|
}) {
|
|
4051
4118
|
const theme = useTheme();
|
|
4052
4119
|
const { url } = react$1.useAttachmentUrl(attachment.id);
|
|
4053
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { onPress, onLongPress, style: [
|
|
4120
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { onPress, onLongPress, style: [styles19.tileBase, style], children: [
|
|
4054
4121
|
url ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
4055
4122
|
reactNative.Image,
|
|
4056
4123
|
{
|
|
4057
4124
|
source: { uri: url },
|
|
4058
|
-
style: [
|
|
4125
|
+
style: [styles19.tileImage, { backgroundColor: theme.colors.surfaceAlt }],
|
|
4059
4126
|
resizeMode: "cover",
|
|
4060
4127
|
accessible: true,
|
|
4061
4128
|
accessibilityLabel: attachment.original_filename ?? "image"
|
|
4062
4129
|
}
|
|
4063
|
-
) : /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
4064
|
-
overlay ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
4130
|
+
) : /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles19.tileImage, { backgroundColor: theme.colors.surfaceAlt }] }),
|
|
4131
|
+
overlay ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles19.overflow, children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: styles19.overflowText, children: overlay }) }) : null
|
|
4065
4132
|
] });
|
|
4066
4133
|
}
|
|
4067
4134
|
function FullScreenViewer({
|
|
@@ -4071,7 +4138,7 @@ function FullScreenViewer({
|
|
|
4071
4138
|
const { url } = react$1.useAttachmentUrl(attachment.id);
|
|
4072
4139
|
const { width, height } = reactNative.useWindowDimensions();
|
|
4073
4140
|
const insets = useSafeInsets();
|
|
4074
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style:
|
|
4141
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { style: styles19.viewer, onPress: onClose, children: [
|
|
4075
4142
|
url ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
4076
4143
|
reactNative.Image,
|
|
4077
4144
|
{
|
|
@@ -4087,14 +4154,14 @@ function FullScreenViewer({
|
|
|
4087
4154
|
{
|
|
4088
4155
|
onPress: onClose,
|
|
4089
4156
|
hitSlop: 12,
|
|
4090
|
-
style: [
|
|
4157
|
+
style: [styles19.closeBtn, { top: insets.top + 12, right: insets.right + 16 }],
|
|
4091
4158
|
accessibilityLabel: "Close viewer",
|
|
4092
4159
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "close", size: 20, color: "#ffffff" })
|
|
4093
4160
|
}
|
|
4094
4161
|
)
|
|
4095
4162
|
] });
|
|
4096
4163
|
}
|
|
4097
|
-
var
|
|
4164
|
+
var styles19 = reactNative.StyleSheet.create({
|
|
4098
4165
|
root: {
|
|
4099
4166
|
width: "100%",
|
|
4100
4167
|
overflow: "hidden",
|
|
@@ -4232,6 +4299,9 @@ function formatClock(date, format2) {
|
|
|
4232
4299
|
}
|
|
4233
4300
|
return date.toLocaleTimeString([], { hour: "numeric", minute: "2-digit" });
|
|
4234
4301
|
}
|
|
4302
|
+
function gutterTime(time) {
|
|
4303
|
+
return time.replace(/\s+(?=[AaPp]\.?[Mm]\.?$)/, "").replace(/\u202f/g, "");
|
|
4304
|
+
}
|
|
4235
4305
|
function formatMessageTime(iso, format2) {
|
|
4236
4306
|
if (!iso) return "";
|
|
4237
4307
|
const date = new Date(iso);
|
|
@@ -4264,7 +4334,7 @@ function LinkPreviewCard({
|
|
|
4264
4334
|
{
|
|
4265
4335
|
onPress: onRemove,
|
|
4266
4336
|
hitSlop: 8,
|
|
4267
|
-
style: [
|
|
4337
|
+
style: [styles20.remove, { backgroundColor: theme.colors.overlay }],
|
|
4268
4338
|
accessibilityRole: "button",
|
|
4269
4339
|
accessibilityLabel: "Remove preview",
|
|
4270
4340
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "close", size: 12, color: "#FFFFFF", label: null })
|
|
@@ -4280,13 +4350,13 @@ function LinkPreviewCard({
|
|
|
4280
4350
|
...onLongPress ? { onLongPress } : {},
|
|
4281
4351
|
accessibilityRole: "link",
|
|
4282
4352
|
accessibilityLabel: preview.title || "Image link",
|
|
4283
|
-
style: [
|
|
4353
|
+
style: [styles20.imageOnly, { maxWidth, borderRadius: theme.radii.md }],
|
|
4284
4354
|
children: [
|
|
4285
4355
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4286
4356
|
reactNative.Image,
|
|
4287
4357
|
{
|
|
4288
4358
|
source: { uri: src },
|
|
4289
|
-
style: [
|
|
4359
|
+
style: [styles20.inlineImage, { borderRadius: theme.radii.md }],
|
|
4290
4360
|
resizeMode: "cover",
|
|
4291
4361
|
onError: () => setImageFailed(true),
|
|
4292
4362
|
accessible: false
|
|
@@ -4306,7 +4376,7 @@ function LinkPreviewCard({
|
|
|
4306
4376
|
accessibilityRole: "link",
|
|
4307
4377
|
accessibilityLabel: [site, preview.title].filter(Boolean).join(": ") || preview.url,
|
|
4308
4378
|
style: ({ pressed }) => [
|
|
4309
|
-
|
|
4379
|
+
styles20.card,
|
|
4310
4380
|
{
|
|
4311
4381
|
maxWidth,
|
|
4312
4382
|
borderRadius: theme.radii.md,
|
|
@@ -4321,7 +4391,7 @@ function LinkPreviewCard({
|
|
|
4321
4391
|
{
|
|
4322
4392
|
source: { uri: preview.image_url },
|
|
4323
4393
|
style: [
|
|
4324
|
-
|
|
4394
|
+
styles20.cardImage,
|
|
4325
4395
|
{ borderTopLeftRadius: theme.radii.md, borderTopRightRadius: theme.radii.md }
|
|
4326
4396
|
],
|
|
4327
4397
|
resizeMode: "cover",
|
|
@@ -4329,13 +4399,13 @@ function LinkPreviewCard({
|
|
|
4329
4399
|
accessible: false
|
|
4330
4400
|
}
|
|
4331
4401
|
) : null,
|
|
4332
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
4333
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
4402
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles20.cardBody, { padding: theme.spacing.sm, gap: 2 }], children: [
|
|
4403
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles20.siteLine, children: [
|
|
4334
4404
|
preview.favicon_url && !faviconFailed ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
4335
4405
|
reactNative.Image,
|
|
4336
4406
|
{
|
|
4337
4407
|
source: { uri: preview.favicon_url },
|
|
4338
|
-
style:
|
|
4408
|
+
style: styles20.favicon,
|
|
4339
4409
|
onError: () => setFaviconFailed(true),
|
|
4340
4410
|
accessible: false
|
|
4341
4411
|
}
|
|
@@ -4343,7 +4413,7 @@ function LinkPreviewCard({
|
|
|
4343
4413
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4344
4414
|
reactNative.Text,
|
|
4345
4415
|
{
|
|
4346
|
-
style: [
|
|
4416
|
+
style: [styles20.site, { color: muted, fontFamily: theme.fonts.body }],
|
|
4347
4417
|
numberOfLines: 1,
|
|
4348
4418
|
children: site
|
|
4349
4419
|
}
|
|
@@ -4353,7 +4423,7 @@ function LinkPreviewCard({
|
|
|
4353
4423
|
reactNative.Text,
|
|
4354
4424
|
{
|
|
4355
4425
|
style: [
|
|
4356
|
-
|
|
4426
|
+
styles20.title,
|
|
4357
4427
|
{ color: onBrand ? text : theme.colors.link, fontFamily: theme.fonts.body }
|
|
4358
4428
|
],
|
|
4359
4429
|
numberOfLines: 2,
|
|
@@ -4363,7 +4433,7 @@ function LinkPreviewCard({
|
|
|
4363
4433
|
preview.description ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
4364
4434
|
reactNative.Text,
|
|
4365
4435
|
{
|
|
4366
|
-
style: [
|
|
4436
|
+
style: [styles20.description, { color: muted, fontFamily: theme.fonts.body }],
|
|
4367
4437
|
numberOfLines: 2,
|
|
4368
4438
|
children: preview.description
|
|
4369
4439
|
}
|
|
@@ -4378,7 +4448,7 @@ function hostOf(url) {
|
|
|
4378
4448
|
const m = /^[a-z][a-z0-9+.-]*:\/\/([^/?#]+)/i.exec(url);
|
|
4379
4449
|
return (m?.[1] ?? url).replace(/^www\./, "");
|
|
4380
4450
|
}
|
|
4381
|
-
var
|
|
4451
|
+
var styles20 = reactNative.StyleSheet.create({
|
|
4382
4452
|
card: {
|
|
4383
4453
|
alignSelf: "stretch",
|
|
4384
4454
|
borderLeftWidth: 3,
|
|
@@ -4504,16 +4574,16 @@ function MessageBubble({
|
|
|
4504
4574
|
reactNative.View,
|
|
4505
4575
|
{
|
|
4506
4576
|
style: [
|
|
4507
|
-
|
|
4508
|
-
variant === "inline" &&
|
|
4509
|
-
variant === "inline" && dense &&
|
|
4510
|
-
variant === "wrapped" &&
|
|
4511
|
-
variant === "overlay" &&
|
|
4512
|
-
variant === "block" &&
|
|
4577
|
+
styles21.metaRow,
|
|
4578
|
+
variant === "inline" && styles21.metaInline,
|
|
4579
|
+
variant === "inline" && dense && styles21.metaInlineDense,
|
|
4580
|
+
variant === "wrapped" && styles21.metaWrapped,
|
|
4581
|
+
variant === "overlay" && styles21.metaOverlay,
|
|
4582
|
+
variant === "block" && styles21.metaBlock,
|
|
4513
4583
|
// File-only bubble: the meta row follows the cards directly —
|
|
4514
4584
|
// give it air so the time doesn't sit glued to the card.
|
|
4515
|
-
variant === "block" && hasFiles && !hasBody &&
|
|
4516
|
-
variant === "jumbo" &&
|
|
4585
|
+
variant === "block" && hasFiles && !hasBody && styles21.metaBlockAfterFiles,
|
|
4586
|
+
variant === "jumbo" && styles21.metaJumbo
|
|
4517
4587
|
],
|
|
4518
4588
|
onLayout: variant === "inline" || variant === "wrapped" ? (e) => setMetaWidth(e.nativeEvent.layout.width) : void 0,
|
|
4519
4589
|
pointerEvents: isEdited && onEditedPress ? "box-none" : "none",
|
|
@@ -4521,7 +4591,7 @@ function MessageBubble({
|
|
|
4521
4591
|
isEdited ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
4522
4592
|
reactNative.Text,
|
|
4523
4593
|
{
|
|
4524
|
-
style: [
|
|
4594
|
+
style: [styles21.editedTag, { color, opacity: 0.8 }],
|
|
4525
4595
|
...onEditedPress ? {
|
|
4526
4596
|
onPress: onEditedPress,
|
|
4527
4597
|
suppressHighlighting: true,
|
|
@@ -4532,8 +4602,8 @@ function MessageBubble({
|
|
|
4532
4602
|
children: "edited"
|
|
4533
4603
|
}
|
|
4534
4604
|
) : null,
|
|
4535
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
4536
|
-
isSelf && readState ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
4605
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles21.meta, { color, opacity: variant === "overlay" ? 1 : 0.75 }], children: time }),
|
|
4606
|
+
isSelf && readState ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles21.readTick, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
4537
4607
|
PoolseIcon,
|
|
4538
4608
|
{
|
|
4539
4609
|
name: readState === "read" ? "check-double" : "check",
|
|
@@ -4549,7 +4619,7 @@ function MessageBubble({
|
|
|
4549
4619
|
reactNative.View,
|
|
4550
4620
|
{
|
|
4551
4621
|
style: [
|
|
4552
|
-
|
|
4622
|
+
styles21.wrap,
|
|
4553
4623
|
{ alignSelf: isSelf ? "flex-end" : "flex-start", maxWidth: bubbleMaxWidth }
|
|
4554
4624
|
],
|
|
4555
4625
|
children: [
|
|
@@ -4575,7 +4645,7 @@ function MessageBubble({
|
|
|
4575
4645
|
showSenderName && !isSelf && jumboCount === 0 && (groupPosition === "first" || groupPosition === "standalone") ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
4576
4646
|
reactNative.Text,
|
|
4577
4647
|
{
|
|
4578
|
-
style: [
|
|
4648
|
+
style: [styles21.senderName, { color: senderTint, fontFamily: theme.fonts.body }],
|
|
4579
4649
|
...onSenderPress ? {
|
|
4580
4650
|
onPress: onSenderPress,
|
|
4581
4651
|
accessibilityRole: "button",
|
|
@@ -4602,7 +4672,7 @@ function MessageBubble({
|
|
|
4602
4672
|
// 3px of bubble color framing the picture; the mosaic clips
|
|
4603
4673
|
// itself 3px tighter than the bubble so the curves stay
|
|
4604
4674
|
// concentric.
|
|
4605
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
4675
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles21.mediaFrame, children: [
|
|
4606
4676
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4607
4677
|
ImageMosaic,
|
|
4608
4678
|
{
|
|
@@ -4616,7 +4686,7 @@ function MessageBubble({
|
|
|
4616
4686
|
metaOverlay ? metaRow("overlay") : null
|
|
4617
4687
|
] })
|
|
4618
4688
|
) : null,
|
|
4619
|
-
hasFiles ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
4689
|
+
hasFiles ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles21.filesBlock, children: files.map((att) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
4620
4690
|
AttachmentPreview,
|
|
4621
4691
|
{
|
|
4622
4692
|
attachment: att,
|
|
@@ -4635,9 +4705,9 @@ function MessageBubble({
|
|
|
4635
4705
|
reactNative.View,
|
|
4636
4706
|
{
|
|
4637
4707
|
style: [
|
|
4638
|
-
|
|
4639
|
-
dense &&
|
|
4640
|
-
sectionAbove &&
|
|
4708
|
+
styles21.textBlock,
|
|
4709
|
+
dense && styles21.textBlockDense,
|
|
4710
|
+
sectionAbove && styles21.textBlockAfter
|
|
4641
4711
|
],
|
|
4642
4712
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
4643
4713
|
reactNative.Text,
|
|
@@ -4655,7 +4725,7 @@ function MessageBubble({
|
|
|
4655
4725
|
)
|
|
4656
4726
|
}
|
|
4657
4727
|
) : null,
|
|
4658
|
-
hasBody && jumboCount > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
4728
|
+
hasBody && jumboCount > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles21.jumboBlock, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
4659
4729
|
reactNative.Text,
|
|
4660
4730
|
{
|
|
4661
4731
|
style: {
|
|
@@ -4669,9 +4739,9 @@ function MessageBubble({
|
|
|
4669
4739
|
reactNative.View,
|
|
4670
4740
|
{
|
|
4671
4741
|
style: [
|
|
4672
|
-
|
|
4673
|
-
dense &&
|
|
4674
|
-
sectionAbove &&
|
|
4742
|
+
styles21.textBlock,
|
|
4743
|
+
dense && styles21.textBlockDense,
|
|
4744
|
+
sectionAbove && styles21.textBlockAfter
|
|
4675
4745
|
],
|
|
4676
4746
|
onLayout: inlineMeta ? (e) => setTextBoxWidth(e.nativeEvent.layout.width - 24) : void 0,
|
|
4677
4747
|
children: [
|
|
@@ -4706,7 +4776,7 @@ function MessageBubble({
|
|
|
4706
4776
|
reactNative.Text,
|
|
4707
4777
|
{
|
|
4708
4778
|
style: [
|
|
4709
|
-
|
|
4779
|
+
styles21.readMore,
|
|
4710
4780
|
{ color: isSelf ? theme.colors.ownBubbleText : theme.colors.link }
|
|
4711
4781
|
],
|
|
4712
4782
|
children: expanded ? "Show less" : "Read more"
|
|
@@ -4721,7 +4791,7 @@ function MessageBubble({
|
|
|
4721
4791
|
hasPreviews ? (
|
|
4722
4792
|
// A fixed width, like media: a card squeezed into the width of
|
|
4723
4793
|
// a one-word message would be unreadable.
|
|
4724
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
4794
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles21.previews, !hasBody && styles21.previewsAlone, { width: mediaWidth }], children: previews.map((p) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
4725
4795
|
LinkPreviewCard,
|
|
4726
4796
|
{
|
|
4727
4797
|
preview: p,
|
|
@@ -4733,7 +4803,7 @@ function MessageBubble({
|
|
|
4733
4803
|
)) })
|
|
4734
4804
|
) : null,
|
|
4735
4805
|
!inlineMeta && !metaOverlay && jumboCount === 0 ? metaRow("block") : null,
|
|
4736
|
-
actionsTrigger ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
4806
|
+
actionsTrigger ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles21.actionsSlot, children: actionsTrigger }) : null
|
|
4737
4807
|
]
|
|
4738
4808
|
}
|
|
4739
4809
|
),
|
|
@@ -4760,15 +4830,15 @@ function QuotedCard({
|
|
|
4760
4830
|
onPress,
|
|
4761
4831
|
disabled: !onPress,
|
|
4762
4832
|
style: [
|
|
4763
|
-
|
|
4833
|
+
styles21.quoted,
|
|
4764
4834
|
{
|
|
4765
4835
|
backgroundColor: bg,
|
|
4766
4836
|
borderLeftColor: accent
|
|
4767
4837
|
}
|
|
4768
4838
|
],
|
|
4769
4839
|
children: [
|
|
4770
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
4771
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
4840
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles21.quotedSender, { color: accent }], numberOfLines: 1, children: senderName }),
|
|
4841
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles21.quotedBody, { color: txt }], numberOfLines: 2, children: quoted.deleted_at ? "Original message deleted" : quoted.body ?? "\u2026" })
|
|
4772
4842
|
]
|
|
4773
4843
|
}
|
|
4774
4844
|
);
|
|
@@ -4801,7 +4871,7 @@ function formatTime2(iso, format2) {
|
|
|
4801
4871
|
function isSameDay(a, b) {
|
|
4802
4872
|
return a.getFullYear() === b.getFullYear() && a.getMonth() === b.getMonth() && a.getDate() === b.getDate();
|
|
4803
4873
|
}
|
|
4804
|
-
var
|
|
4874
|
+
var styles21 = reactNative.StyleSheet.create({
|
|
4805
4875
|
wrap: {
|
|
4806
4876
|
marginBottom: 2
|
|
4807
4877
|
},
|
|
@@ -4928,6 +4998,24 @@ var styles20 = reactNative.StyleSheet.create({
|
|
|
4928
4998
|
opacity: 0.8
|
|
4929
4999
|
}
|
|
4930
5000
|
});
|
|
5001
|
+
|
|
5002
|
+
// src/internal/a11y.ts
|
|
5003
|
+
function messageA11yLabel(msg, senderName, isSelf) {
|
|
5004
|
+
const who = isSelf ? "You" : senderName;
|
|
5005
|
+
if (msg.deleted_at) return `${who}: message deleted`;
|
|
5006
|
+
const parts = [];
|
|
5007
|
+
const body = (msg.body ?? "").trim();
|
|
5008
|
+
if (body) parts.push(body.length > 300 ? `${body.slice(0, 300)}\u2026` : body);
|
|
5009
|
+
const files = Array.isArray(msg.attachments) ? msg.attachments.length : 0;
|
|
5010
|
+
if (files > 0) parts.push(files === 1 ? "1 attachment" : `${files} attachments`);
|
|
5011
|
+
if (msg.edited_at) parts.push("edited");
|
|
5012
|
+
if (msg.local_status === "queued") parts.push("waiting for network");
|
|
5013
|
+
if (msg.local_status === "failed") parts.push("not sent");
|
|
5014
|
+
return `${who}: ${parts.join(", ") || "message"}`;
|
|
5015
|
+
}
|
|
5016
|
+
function reactionA11yLabel(emoji, count, mine) {
|
|
5017
|
+
return `${emoji} ${count}${mine ? ", you reacted" : ""}`;
|
|
5018
|
+
}
|
|
4931
5019
|
var DEFAULT_EMOJIS = ["\u{1F44D}", "\u2764\uFE0F", "\u{1F602}", "\u{1F389}", "\u{1F64F}", "\u{1F525}"];
|
|
4932
5020
|
function ReactionStrip({
|
|
4933
5021
|
messageId,
|
|
@@ -4944,7 +5032,7 @@ function ReactionStrip({
|
|
|
4944
5032
|
});
|
|
4945
5033
|
const entries = Object.entries(reactions);
|
|
4946
5034
|
if (entries.length === 0) return null;
|
|
4947
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
5035
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles22.strip, children: [
|
|
4948
5036
|
entries.map(([emoji, userIds]) => {
|
|
4949
5037
|
const userArr = Array.isArray(userIds) ? userIds : [];
|
|
4950
5038
|
const meReacted = meId !== null && userArr.includes(meId);
|
|
@@ -4952,8 +5040,12 @@ function ReactionStrip({
|
|
|
4952
5040
|
reactNative.Pressable,
|
|
4953
5041
|
{
|
|
4954
5042
|
onPress: () => meReacted ? removeReaction(emoji) : addReaction(emoji),
|
|
5043
|
+
accessibilityRole: "button",
|
|
5044
|
+
accessibilityLabel: reactionA11yLabel(emoji, userArr.length, meReacted),
|
|
5045
|
+
accessibilityState: { selected: meReacted },
|
|
5046
|
+
accessibilityHint: meReacted ? "Removes your reaction" : "Adds this reaction",
|
|
4955
5047
|
style: [
|
|
4956
|
-
|
|
5048
|
+
styles22.chip,
|
|
4957
5049
|
{
|
|
4958
5050
|
backgroundColor: meReacted ? theme.colors.accentSoft : theme.colors.surfaceAlt,
|
|
4959
5051
|
borderColor: meReacted ? theme.colors.accent : theme.colors.border,
|
|
@@ -4962,12 +5054,12 @@ function ReactionStrip({
|
|
|
4962
5054
|
}
|
|
4963
5055
|
],
|
|
4964
5056
|
children: [
|
|
4965
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style:
|
|
5057
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: styles22.emoji, children: emoji }),
|
|
4966
5058
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4967
5059
|
reactNative.Text,
|
|
4968
5060
|
{
|
|
4969
5061
|
style: [
|
|
4970
|
-
|
|
5062
|
+
styles22.count,
|
|
4971
5063
|
{
|
|
4972
5064
|
color: meReacted ? theme.colors.accent : theme.colors.textMuted,
|
|
4973
5065
|
fontWeight: meReacted ? "700" : "600"
|
|
@@ -4987,7 +5079,7 @@ function ReactionStrip({
|
|
|
4987
5079
|
onPress: onMorePress,
|
|
4988
5080
|
hitSlop: 4,
|
|
4989
5081
|
style: [
|
|
4990
|
-
|
|
5082
|
+
styles22.chip,
|
|
4991
5083
|
{
|
|
4992
5084
|
backgroundColor: theme.colors.surfaceAlt,
|
|
4993
5085
|
borderColor: theme.colors.border,
|
|
@@ -5020,13 +5112,13 @@ function ReactionPicker({
|
|
|
5020
5112
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5021
5113
|
reactNative.Pressable,
|
|
5022
5114
|
{
|
|
5023
|
-
style: [
|
|
5115
|
+
style: [styles22.backdrop, { paddingTop: insets.top, paddingBottom: insets.bottom }],
|
|
5024
5116
|
onPress: onClose,
|
|
5025
5117
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5026
5118
|
reactNative.View,
|
|
5027
5119
|
{
|
|
5028
5120
|
style: [
|
|
5029
|
-
|
|
5121
|
+
styles22.sheet,
|
|
5030
5122
|
{
|
|
5031
5123
|
backgroundColor: theme.colors.surface,
|
|
5032
5124
|
borderRadius: theme.radii.lg
|
|
@@ -5036,12 +5128,12 @@ function ReactionPicker({
|
|
|
5036
5128
|
children: emojis.map((emoji) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
5037
5129
|
reactNative.Pressable,
|
|
5038
5130
|
{
|
|
5039
|
-
style:
|
|
5131
|
+
style: styles22.emojiBtn,
|
|
5040
5132
|
onPress: () => {
|
|
5041
5133
|
onPick(emoji);
|
|
5042
5134
|
onClose();
|
|
5043
5135
|
},
|
|
5044
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style:
|
|
5136
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: styles22.bigEmoji, children: emoji })
|
|
5045
5137
|
},
|
|
5046
5138
|
emoji
|
|
5047
5139
|
))
|
|
@@ -5052,7 +5144,7 @@ function ReactionPicker({
|
|
|
5052
5144
|
}
|
|
5053
5145
|
);
|
|
5054
5146
|
}
|
|
5055
|
-
var
|
|
5147
|
+
var styles22 = reactNative.StyleSheet.create({
|
|
5056
5148
|
strip: {
|
|
5057
5149
|
flexDirection: "row",
|
|
5058
5150
|
flexWrap: "wrap",
|
|
@@ -5108,6 +5200,69 @@ var styles21 = reactNative.StyleSheet.create({
|
|
|
5108
5200
|
lineHeight: 38
|
|
5109
5201
|
}
|
|
5110
5202
|
});
|
|
5203
|
+
function SendStatus({ message, onRetry, onDiscard, alignEnd = true }) {
|
|
5204
|
+
const theme = useTheme();
|
|
5205
|
+
const status = message.local_status;
|
|
5206
|
+
if (status !== "queued" && status !== "failed") return null;
|
|
5207
|
+
const failed = status === "failed";
|
|
5208
|
+
const text = failed ? message.local_error ? `Not sent: ${message.local_error}` : "Not sent" : "Waiting for network\u2026";
|
|
5209
|
+
const button = (label, onPress, danger = false) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
5210
|
+
reactNative.Pressable,
|
|
5211
|
+
{
|
|
5212
|
+
onPress,
|
|
5213
|
+
accessibilityRole: "button",
|
|
5214
|
+
accessibilityLabel: `${label} message`,
|
|
5215
|
+
hitSlop: 8,
|
|
5216
|
+
style: styles23.button,
|
|
5217
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5218
|
+
reactNative.Text,
|
|
5219
|
+
{
|
|
5220
|
+
style: [
|
|
5221
|
+
styles23.buttonText,
|
|
5222
|
+
{ color: danger ? theme.colors.danger : theme.colors.accentStrong },
|
|
5223
|
+
{ fontFamily: theme.fonts.body }
|
|
5224
|
+
],
|
|
5225
|
+
children: label
|
|
5226
|
+
}
|
|
5227
|
+
)
|
|
5228
|
+
}
|
|
5229
|
+
);
|
|
5230
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5231
|
+
reactNative.View,
|
|
5232
|
+
{
|
|
5233
|
+
style: [styles23.root, { justifyContent: alignEnd ? "flex-end" : "flex-start" }],
|
|
5234
|
+
accessibilityLiveRegion: "polite",
|
|
5235
|
+
children: [
|
|
5236
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5237
|
+
reactNative.Text,
|
|
5238
|
+
{
|
|
5239
|
+
style: [
|
|
5240
|
+
styles23.text,
|
|
5241
|
+
{ color: failed ? theme.colors.danger : theme.colors.textMuted },
|
|
5242
|
+
{ fontFamily: theme.fonts.body }
|
|
5243
|
+
],
|
|
5244
|
+
children: text
|
|
5245
|
+
}
|
|
5246
|
+
),
|
|
5247
|
+
onRetry ? button(failed ? "Retry" : "Send now", onRetry) : null,
|
|
5248
|
+
failed && onDiscard ? button("Delete", onDiscard, true) : null
|
|
5249
|
+
]
|
|
5250
|
+
}
|
|
5251
|
+
);
|
|
5252
|
+
}
|
|
5253
|
+
var styles23 = reactNative.StyleSheet.create({
|
|
5254
|
+
root: {
|
|
5255
|
+
flexDirection: "row",
|
|
5256
|
+
flexWrap: "wrap",
|
|
5257
|
+
alignItems: "center",
|
|
5258
|
+
gap: 10,
|
|
5259
|
+
marginTop: 2,
|
|
5260
|
+
marginBottom: 4
|
|
5261
|
+
},
|
|
5262
|
+
text: { fontSize: 12, flexShrink: 1 },
|
|
5263
|
+
button: { paddingVertical: 2 },
|
|
5264
|
+
buttonText: { fontSize: 12, fontWeight: "700" }
|
|
5265
|
+
});
|
|
5111
5266
|
|
|
5112
5267
|
// src/internal/thread.ts
|
|
5113
5268
|
function threadSummaryText(replyCount, lastReplyAt, now = Date.now()) {
|
|
@@ -5148,7 +5303,7 @@ function ThreadSummary({
|
|
|
5148
5303
|
accessibilityLabel: `${label}. Open thread`,
|
|
5149
5304
|
hitSlop: 4,
|
|
5150
5305
|
style: ({ pressed }) => [
|
|
5151
|
-
|
|
5306
|
+
styles24.row,
|
|
5152
5307
|
{
|
|
5153
5308
|
alignSelf: alignEnd ? "flex-end" : "flex-start",
|
|
5154
5309
|
borderRadius: theme.radii.pill,
|
|
@@ -5156,11 +5311,11 @@ function ThreadSummary({
|
|
|
5156
5311
|
}
|
|
5157
5312
|
],
|
|
5158
5313
|
children: [
|
|
5159
|
-
people.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
5314
|
+
people.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles24.stack, children: people.map((p, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
5160
5315
|
reactNative.View,
|
|
5161
5316
|
{
|
|
5162
5317
|
style: [
|
|
5163
|
-
|
|
5318
|
+
styles24.stacked,
|
|
5164
5319
|
{
|
|
5165
5320
|
marginLeft: i === 0 ? 0 : -6,
|
|
5166
5321
|
borderColor: theme.colors.background,
|
|
@@ -5182,7 +5337,7 @@ function ThreadSummary({
|
|
|
5182
5337
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5183
5338
|
reactNative.Text,
|
|
5184
5339
|
{
|
|
5185
|
-
style: [
|
|
5340
|
+
style: [styles24.text, { color: theme.colors.link, fontFamily: theme.fonts.body }],
|
|
5186
5341
|
numberOfLines: 1,
|
|
5187
5342
|
children: label
|
|
5188
5343
|
}
|
|
@@ -5202,7 +5357,7 @@ function Participant({
|
|
|
5202
5357
|
const src = externalId ? avatarFor?.(externalId) ?? resolved.profile?.avatarUrl ?? null : null;
|
|
5203
5358
|
return /* @__PURE__ */ jsxRuntime.jsx(Avatar, { src, name, seed: externalId ?? fallback, size: "xs" });
|
|
5204
5359
|
}
|
|
5205
|
-
var
|
|
5360
|
+
var styles24 = reactNative.StyleSheet.create({
|
|
5206
5361
|
row: {
|
|
5207
5362
|
flexDirection: "row",
|
|
5208
5363
|
alignItems: "center",
|
|
@@ -5257,7 +5412,9 @@ function FlatMessageRow({
|
|
|
5257
5412
|
linkPreviews = true,
|
|
5258
5413
|
onRemoveLinkPreview,
|
|
5259
5414
|
onMarkUnread,
|
|
5260
|
-
editHistory = true
|
|
5415
|
+
editHistory = true,
|
|
5416
|
+
onRetrySend,
|
|
5417
|
+
onDiscardSend
|
|
5261
5418
|
}) {
|
|
5262
5419
|
const theme = useTheme();
|
|
5263
5420
|
const { width: screenWidth } = reactNative.useWindowDimensions();
|
|
@@ -5286,9 +5443,10 @@ function FlatMessageRow({
|
|
|
5286
5443
|
const isRunStart = compact || groupPosition === "first" || groupPosition === "standalone";
|
|
5287
5444
|
const ctx = { message: msg, isSelf, sender, layout, isRunStart };
|
|
5288
5445
|
const deleted = react$1.isTombstone(msg);
|
|
5446
|
+
const inert = deleted || !!msg.local_status;
|
|
5289
5447
|
const time = formatMessageTime(msg.inserted_at, timeFormat);
|
|
5290
5448
|
const openActions = () => {
|
|
5291
|
-
if (actions && !
|
|
5449
|
+
if (actions && !inert) setActionsOpen(true);
|
|
5292
5450
|
};
|
|
5293
5451
|
const text = { fontFamily: theme.fonts.body, color: theme.colors.text };
|
|
5294
5452
|
const avatarEl = showAvatar ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -5315,10 +5473,10 @@ function FlatMessageRow({
|
|
|
5315
5473
|
reactNative.Text,
|
|
5316
5474
|
{
|
|
5317
5475
|
style: [
|
|
5318
|
-
|
|
5476
|
+
styles25.name,
|
|
5319
5477
|
text,
|
|
5320
5478
|
compact ? { color: userColor(ext ?? msg.sender_id ?? msg.id) } : null,
|
|
5321
|
-
compact ?
|
|
5479
|
+
compact ? styles25.nameCompact : null
|
|
5322
5480
|
],
|
|
5323
5481
|
numberOfLines: 1,
|
|
5324
5482
|
...onSenderPress && !isSelf ? {
|
|
@@ -5333,21 +5491,22 @@ function FlatMessageRow({
|
|
|
5333
5491
|
reactNative.Text,
|
|
5334
5492
|
{
|
|
5335
5493
|
style: [
|
|
5336
|
-
|
|
5494
|
+
styles25.time,
|
|
5337
5495
|
{ color: theme.colors.textSubtle, fontFamily: theme.fonts.body },
|
|
5338
|
-
dim ?
|
|
5496
|
+
dim ? styles25.timeDim : null
|
|
5339
5497
|
],
|
|
5340
|
-
|
|
5498
|
+
...dim ? { numberOfLines: 1, adjustsFontSizeToFit: true, minimumFontScale: 0.6 } : {},
|
|
5499
|
+
children: dim ? gutterTime(time) : time
|
|
5341
5500
|
}
|
|
5342
5501
|
);
|
|
5343
|
-
const header = compact ? name : isRunStart ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
5502
|
+
const header = compact ? name : isRunStart ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles25.header, children: [
|
|
5344
5503
|
name,
|
|
5345
5504
|
timeText(false)
|
|
5346
5505
|
] }) : null;
|
|
5347
5506
|
const images = attachments && !deleted ? (msg.attachments ?? []).filter((a) => isImageContentType(a.content_type)) : [];
|
|
5348
5507
|
const files = attachments && !deleted ? (msg.attachments ?? []).filter((a) => !isImageContentType(a.content_type)) : [];
|
|
5349
5508
|
const mediaWidth = Math.min(screenWidth - GUTTER - 48, 320);
|
|
5350
|
-
const attachmentsEl = images.length > 0 || files.length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
5509
|
+
const attachmentsEl = images.length > 0 || files.length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles25.attachments, children: [
|
|
5351
5510
|
images.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
5352
5511
|
ImageMosaic,
|
|
5353
5512
|
{
|
|
@@ -5370,11 +5529,11 @@ function FlatMessageRow({
|
|
|
5370
5529
|
lineHeight: dense ? theme.fonts.lineHeight - 3 : theme.fonts.lineHeight
|
|
5371
5530
|
};
|
|
5372
5531
|
const edited = !!msg.edited_at && !deleted;
|
|
5373
|
-
const meta = edited || isSelf && readState ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
5532
|
+
const meta = edited || isSelf && readState ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles25.meta, children: [
|
|
5374
5533
|
edited ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
5375
5534
|
reactNative.Text,
|
|
5376
5535
|
{
|
|
5377
|
-
style: [
|
|
5536
|
+
style: [styles25.edited, { color: theme.colors.textSubtle }],
|
|
5378
5537
|
...editHistory && canShowEditHistory(msg.id) ? {
|
|
5379
5538
|
onPress: () => setHistoryOpen(true),
|
|
5380
5539
|
suppressHighlighting: true,
|
|
@@ -5394,7 +5553,7 @@ function FlatMessageRow({
|
|
|
5394
5553
|
}
|
|
5395
5554
|
) : null
|
|
5396
5555
|
] }) : null;
|
|
5397
|
-
const body = deleted ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [bodyText,
|
|
5556
|
+
const body = deleted ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [bodyText, styles25.deleted, { color: theme.colors.textMuted }], children: "This message was deleted" }) : raw ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { children: [
|
|
5398
5557
|
jumbo > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: { fontSize: emojiFontSize(jumbo), lineHeight: emojiFontSize(jumbo) + 8 }, children: raw }) : markdown && hasMarkdown(shown) ? renderMarkdown(shown, {
|
|
5399
5558
|
textColor: bodyText.color,
|
|
5400
5559
|
linkColor: theme.colors.link,
|
|
@@ -5406,8 +5565,8 @@ function FlatMessageRow({
|
|
|
5406
5565
|
return false;
|
|
5407
5566
|
}
|
|
5408
5567
|
}) : /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: bodyText, children: shown }),
|
|
5409
|
-
trimmable ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { onPress: () => setExpanded((e) => !e), children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
5410
|
-
previews.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
5568
|
+
trimmable ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { onPress: () => setExpanded((e) => !e), children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles25.readMore, { color: theme.colors.link }], children: expanded ? "Show less" : "Read more" }) }) : null,
|
|
5569
|
+
previews.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles25.previews, children: previews.map((p) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
5411
5570
|
LinkPreviewCard,
|
|
5412
5571
|
{
|
|
5413
5572
|
preview: p,
|
|
@@ -5431,7 +5590,7 @@ function FlatMessageRow({
|
|
|
5431
5590
|
}
|
|
5432
5591
|
) : null
|
|
5433
5592
|
);
|
|
5434
|
-
const reactionsEl = reactions && !
|
|
5593
|
+
const reactionsEl = reactions && !inert ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles25.reactions, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5435
5594
|
ReactionStrip,
|
|
5436
5595
|
{
|
|
5437
5596
|
messageId: msg.id,
|
|
@@ -5450,15 +5609,24 @@ function FlatMessageRow({
|
|
|
5450
5609
|
...onQuotedClick ? { onPress: () => onQuotedClick(msg.quoted_message.id) } : {}
|
|
5451
5610
|
}
|
|
5452
5611
|
) : null;
|
|
5453
|
-
const content = /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
5612
|
+
const content = /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles25.content, children: [
|
|
5454
5613
|
!compact ? renderSlot(slots?.header, ctx, header) : null,
|
|
5455
5614
|
quote,
|
|
5456
5615
|
renderSlot(slots?.attachments, ctx, attachmentsEl),
|
|
5457
5616
|
renderSlot(slots?.body, ctx, body),
|
|
5458
5617
|
renderSlot(slots?.reactions, ctx, reactionsEl),
|
|
5459
|
-
renderSlot(slots?.thread, ctx, threadEl)
|
|
5618
|
+
renderSlot(slots?.thread, ctx, threadEl),
|
|
5619
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5620
|
+
SendStatus,
|
|
5621
|
+
{
|
|
5622
|
+
message: msg,
|
|
5623
|
+
alignEnd: false,
|
|
5624
|
+
...onRetrySend ? { onRetry: onRetrySend } : {},
|
|
5625
|
+
...onDiscardSend ? { onDiscard: onDiscardSend } : {}
|
|
5626
|
+
}
|
|
5627
|
+
)
|
|
5460
5628
|
] });
|
|
5461
|
-
const sheet = actions && actionsOpen && !
|
|
5629
|
+
const sheet = actions && actionsOpen && !inert ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
5462
5630
|
RowActionsSheet,
|
|
5463
5631
|
{
|
|
5464
5632
|
msg,
|
|
@@ -5482,28 +5650,32 @@ function FlatMessageRow({
|
|
|
5482
5650
|
reactNative.View,
|
|
5483
5651
|
{
|
|
5484
5652
|
style: [
|
|
5485
|
-
|
|
5486
|
-
compact ?
|
|
5487
|
-
dense ?
|
|
5488
|
-
!compact && isRunStart ? dense ?
|
|
5653
|
+
styles25.row,
|
|
5654
|
+
compact ? styles25.rowCompact : null,
|
|
5655
|
+
dense ? styles25.rowDense : null,
|
|
5656
|
+
!compact && isRunStart ? dense ? styles25.runStartDense : styles25.runStart : null,
|
|
5489
5657
|
mentionsMe ? { backgroundColor: theme.colors.mention, borderLeftColor: theme.colors.accent } : null,
|
|
5490
|
-
isEditing ?
|
|
5658
|
+
isEditing ? styles25.rowEditing : null
|
|
5491
5659
|
],
|
|
5492
5660
|
children: [
|
|
5493
5661
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5494
5662
|
reactNative.Pressable,
|
|
5495
5663
|
{
|
|
5496
5664
|
onLongPress: openActions,
|
|
5497
|
-
style: [
|
|
5498
|
-
|
|
5499
|
-
|
|
5665
|
+
style: [styles25.line, compact ? styles25.lineCompact : null],
|
|
5666
|
+
accessibilityLabel: messageA11yLabel(msg, senderName, isSelf),
|
|
5667
|
+
...actions && !inert ? {
|
|
5668
|
+
accessibilityHint: "Long press for message actions",
|
|
5669
|
+
accessibilityActions: [{ name: "longpress", label: "Message actions" }],
|
|
5670
|
+
onAccessibilityAction: openActions
|
|
5671
|
+
} : {},
|
|
5500
5672
|
children: compact ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5501
5673
|
timeText(false),
|
|
5502
|
-
avatar ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
5674
|
+
avatar ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles25.avatarCompact, children: avatar }) : null,
|
|
5503
5675
|
renderSlot(slots?.header, ctx, header),
|
|
5504
5676
|
content
|
|
5505
5677
|
] }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5506
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
5678
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles25.gutter, children: isRunStart ? avatar : timeText(true) }),
|
|
5507
5679
|
content
|
|
5508
5680
|
] })
|
|
5509
5681
|
}
|
|
@@ -5524,7 +5696,7 @@ function FlatMessageRow({
|
|
|
5524
5696
|
}
|
|
5525
5697
|
);
|
|
5526
5698
|
}
|
|
5527
|
-
var
|
|
5699
|
+
var styles25 = reactNative.StyleSheet.create({
|
|
5528
5700
|
row: {
|
|
5529
5701
|
// 3px left border reserved for the mention accent bar.
|
|
5530
5702
|
borderLeftWidth: 3,
|
|
@@ -5592,7 +5764,10 @@ var styles23 = reactNative.StyleSheet.create({
|
|
|
5592
5764
|
},
|
|
5593
5765
|
timeDim: {
|
|
5594
5766
|
fontSize: 10,
|
|
5595
|
-
opacity: 0.7
|
|
5767
|
+
opacity: 0.7,
|
|
5768
|
+
// Fill the gutter so shrink-to-fit measures against its width.
|
|
5769
|
+
width: GUTTER,
|
|
5770
|
+
textAlign: "center"
|
|
5596
5771
|
},
|
|
5597
5772
|
attachments: {
|
|
5598
5773
|
marginVertical: 4,
|
|
@@ -5673,13 +5848,13 @@ function MessageActions({
|
|
|
5673
5848
|
animationType: "fade",
|
|
5674
5849
|
onRequestClose: onClose,
|
|
5675
5850
|
...EDGE_TO_EDGE_MODAL,
|
|
5676
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style:
|
|
5851
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style: styles26.backdrop, onPress: onClose, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5677
5852
|
reactNative.Pressable,
|
|
5678
5853
|
{
|
|
5679
5854
|
onPress: () => void 0,
|
|
5680
5855
|
accessible: false,
|
|
5681
5856
|
style: [
|
|
5682
|
-
|
|
5857
|
+
styles26.sheet,
|
|
5683
5858
|
{
|
|
5684
5859
|
backgroundColor: theme.colors.surface,
|
|
5685
5860
|
borderTopLeftRadius: theme.radii.lg,
|
|
@@ -5692,7 +5867,7 @@ function MessageActions({
|
|
|
5692
5867
|
theme.shadows.lg
|
|
5693
5868
|
],
|
|
5694
5869
|
children: [
|
|
5695
|
-
showEmojiRow ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
5870
|
+
showEmojiRow ? /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles26.emojiRow, { borderBottomColor: theme.colors.border }], children: [
|
|
5696
5871
|
emojis.map((emoji) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
5697
5872
|
reactNative.Pressable,
|
|
5698
5873
|
{
|
|
@@ -5700,10 +5875,10 @@ function MessageActions({
|
|
|
5700
5875
|
onPickReaction(emoji);
|
|
5701
5876
|
onClose();
|
|
5702
5877
|
},
|
|
5703
|
-
style:
|
|
5878
|
+
style: styles26.emojiBtn,
|
|
5704
5879
|
hitSlop: 6,
|
|
5705
5880
|
accessibilityLabel: `React with ${emoji}`,
|
|
5706
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style:
|
|
5881
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: styles26.emoji, children: emoji })
|
|
5707
5882
|
},
|
|
5708
5883
|
emoji
|
|
5709
5884
|
)),
|
|
@@ -5714,7 +5889,7 @@ function MessageActions({
|
|
|
5714
5889
|
onClose();
|
|
5715
5890
|
onMoreReactions();
|
|
5716
5891
|
},
|
|
5717
|
-
style: [
|
|
5892
|
+
style: [styles26.moreBtn, { backgroundColor: theme.colors.surfaceAlt }],
|
|
5718
5893
|
hitSlop: 6,
|
|
5719
5894
|
accessibilityRole: "button",
|
|
5720
5895
|
accessibilityLabel: "More reactions",
|
|
@@ -5722,7 +5897,7 @@ function MessageActions({
|
|
|
5722
5897
|
}
|
|
5723
5898
|
) : null
|
|
5724
5899
|
] }) : null,
|
|
5725
|
-
items.map((item) => /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { onPress: item.onPress, style:
|
|
5900
|
+
items.map((item) => /* @__PURE__ */ jsxRuntime.jsxs(reactNative.Pressable, { onPress: item.onPress, style: styles26.item, children: [
|
|
5726
5901
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5727
5902
|
PoolseIcon,
|
|
5728
5903
|
{
|
|
@@ -5735,7 +5910,7 @@ function MessageActions({
|
|
|
5735
5910
|
reactNative.Text,
|
|
5736
5911
|
{
|
|
5737
5912
|
style: [
|
|
5738
|
-
|
|
5913
|
+
styles26.itemText,
|
|
5739
5914
|
{
|
|
5740
5915
|
color: item.danger ? theme.colors.danger : theme.colors.text,
|
|
5741
5916
|
fontFamily: theme.fonts.body
|
|
@@ -5755,7 +5930,7 @@ function hostOf2(url) {
|
|
|
5755
5930
|
const m = /^[a-z][a-z0-9+.-]*:\/\/([^/?#]+)/i.exec(url);
|
|
5756
5931
|
return (m?.[1] ?? url).replace(/^www\./, "");
|
|
5757
5932
|
}
|
|
5758
|
-
var
|
|
5933
|
+
var styles26 = reactNative.StyleSheet.create({
|
|
5759
5934
|
backdrop: {
|
|
5760
5935
|
flex: 1,
|
|
5761
5936
|
backgroundColor: "rgba(0,0,0,0.35)",
|
|
@@ -5919,11 +6094,13 @@ function BubbleMessageRow({
|
|
|
5919
6094
|
linkPreviews = true,
|
|
5920
6095
|
onRemoveLinkPreview,
|
|
5921
6096
|
onMarkUnread,
|
|
5922
|
-
editHistory = true
|
|
6097
|
+
editHistory = true,
|
|
6098
|
+
onRetrySend,
|
|
6099
|
+
onDiscardSend
|
|
5923
6100
|
}) {
|
|
5924
6101
|
const theme = useTheme();
|
|
5925
6102
|
const isSelf = meId !== null && msg.sender_id === meId;
|
|
5926
|
-
const tombstone = react$1.isTombstone(msg);
|
|
6103
|
+
const tombstone = react$1.isTombstone(msg) || !!msg.local_status;
|
|
5927
6104
|
const [actionsOpen, setActionsOpen] = react.useState(false);
|
|
5928
6105
|
const [emojiOpen, setEmojiOpen] = react.useState(false);
|
|
5929
6106
|
const [historyOpen, setHistoryOpen] = react.useState(false);
|
|
@@ -6005,8 +6182,7 @@ function BubbleMessageRow({
|
|
|
6005
6182
|
});
|
|
6006
6183
|
const showAvatarSlot = showAvatar && !isSelf;
|
|
6007
6184
|
const showAvatarRender = showAvatarSlot && (groupPosition === "last" || groupPosition === "standalone");
|
|
6008
|
-
const
|
|
6009
|
-
const rowSender = react$1.useUser(wantsSender ? msg.sender_external_id : null);
|
|
6185
|
+
const rowSender = react$1.useUser(msg.sender_external_id);
|
|
6010
6186
|
const avatarUrl = msg.sender_external_id ? avatarFor?.(msg.sender_external_id) ?? rowSender.profile?.avatarUrl ?? null : null;
|
|
6011
6187
|
const senderLabel = msg.sender_external_id ? labelFor?.(msg.sender_external_id) ?? rowSender.profile?.displayName ?? msg.sender_external_id : null;
|
|
6012
6188
|
const sender = {
|
|
@@ -6036,16 +6212,16 @@ function BubbleMessageRow({
|
|
|
6036
6212
|
reactNative.View,
|
|
6037
6213
|
{
|
|
6038
6214
|
style: [
|
|
6039
|
-
|
|
6215
|
+
styles27.row,
|
|
6040
6216
|
{ alignSelf: isSelf ? "flex-end" : "flex-start" },
|
|
6041
|
-
density === "compact" ?
|
|
6217
|
+
density === "compact" ? styles27.rowDense : null,
|
|
6042
6218
|
// Lift this row above the dim backdrop the parent renders
|
|
6043
6219
|
// during edit mode. zIndex covers iOS / web; elevation does
|
|
6044
6220
|
// the equivalent on Android.
|
|
6045
|
-
isEditing ?
|
|
6221
|
+
isEditing ? styles27.rowEditing : null
|
|
6046
6222
|
],
|
|
6047
6223
|
children: [
|
|
6048
|
-
showAvatarSlot ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
6224
|
+
showAvatarSlot ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles27.avatarSlot, children: !showAvatarRender ? null : onAvatarPress ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
6049
6225
|
reactNative.Pressable,
|
|
6050
6226
|
{
|
|
6051
6227
|
onPress: () => onAvatarPress(sender),
|
|
@@ -6055,14 +6231,14 @@ function BubbleMessageRow({
|
|
|
6055
6231
|
children: avatar
|
|
6056
6232
|
}
|
|
6057
6233
|
) : avatar }) : null,
|
|
6058
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
6234
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles27.bubbleCol, children: [
|
|
6059
6235
|
swipeEnabled ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
6060
6236
|
reactNative.Animated.View,
|
|
6061
6237
|
{
|
|
6062
6238
|
pointerEvents: "none",
|
|
6063
6239
|
style: [
|
|
6064
|
-
|
|
6065
|
-
isSelf ?
|
|
6240
|
+
styles27.replyHint,
|
|
6241
|
+
isSelf ? styles27.replyHintRight : styles27.replyHintLeft,
|
|
6066
6242
|
{
|
|
6067
6243
|
opacity: replyIconOpacity,
|
|
6068
6244
|
transform: [{ scale: replyIconScale }],
|
|
@@ -6084,8 +6260,12 @@ function BubbleMessageRow({
|
|
|
6084
6260
|
if (!actions || tombstone) return;
|
|
6085
6261
|
setActionsOpen(true);
|
|
6086
6262
|
},
|
|
6087
|
-
|
|
6088
|
-
|
|
6263
|
+
accessibilityLabel: messageA11yLabel(msg, senderLabel ?? "Unknown", isSelf),
|
|
6264
|
+
...actions && !tombstone ? {
|
|
6265
|
+
accessibilityHint: "Long press for message actions",
|
|
6266
|
+
accessibilityActions: [{ name: "longpress", label: "Message actions" }],
|
|
6267
|
+
onAccessibilityAction: () => setActionsOpen(true)
|
|
6268
|
+
} : {},
|
|
6089
6269
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6090
6270
|
MessageBubble,
|
|
6091
6271
|
{
|
|
@@ -6114,6 +6294,15 @@ function BubbleMessageRow({
|
|
|
6114
6294
|
)
|
|
6115
6295
|
}
|
|
6116
6296
|
),
|
|
6297
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6298
|
+
SendStatus,
|
|
6299
|
+
{
|
|
6300
|
+
message: msg,
|
|
6301
|
+
alignEnd: isSelf,
|
|
6302
|
+
...onRetrySend ? { onRetry: onRetrySend } : {},
|
|
6303
|
+
...onDiscardSend ? { onDiscard: onDiscardSend } : {}
|
|
6304
|
+
}
|
|
6305
|
+
),
|
|
6117
6306
|
renderSlot(
|
|
6118
6307
|
slots?.thread,
|
|
6119
6308
|
slotContext,
|
|
@@ -6131,7 +6320,7 @@ function BubbleMessageRow({
|
|
|
6131
6320
|
renderSlot(
|
|
6132
6321
|
slots?.reactions,
|
|
6133
6322
|
slotContext,
|
|
6134
|
-
reactions && !tombstone ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
6323
|
+
reactions && !tombstone ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles27.reactionsRow, { alignSelf: isSelf ? "flex-end" : "flex-start" }], children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6135
6324
|
ReactionStrip,
|
|
6136
6325
|
{
|
|
6137
6326
|
messageId: msg.id,
|
|
@@ -6182,7 +6371,7 @@ function BubbleMessageRow({
|
|
|
6182
6371
|
}
|
|
6183
6372
|
);
|
|
6184
6373
|
}
|
|
6185
|
-
var
|
|
6374
|
+
var styles27 = reactNative.StyleSheet.create({
|
|
6186
6375
|
row: {
|
|
6187
6376
|
flexDirection: "row",
|
|
6188
6377
|
alignItems: "flex-end",
|
|
@@ -6239,24 +6428,24 @@ function NewMessagesDivider({ label = "New messages" }) {
|
|
|
6239
6428
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
6240
6429
|
reactNative.View,
|
|
6241
6430
|
{
|
|
6242
|
-
style: [
|
|
6431
|
+
style: [styles28.row, { paddingHorizontal: theme.spacing.md }],
|
|
6243
6432
|
accessibilityRole: "text",
|
|
6244
6433
|
accessibilityLabel: label,
|
|
6245
6434
|
children: [
|
|
6246
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
6435
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles28.line, { backgroundColor: theme.colors.accent }] }),
|
|
6247
6436
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6248
6437
|
reactNative.Text,
|
|
6249
6438
|
{
|
|
6250
|
-
style: [
|
|
6439
|
+
style: [styles28.label, { color: theme.colors.accentStrong, fontFamily: theme.fonts.body }],
|
|
6251
6440
|
children: label
|
|
6252
6441
|
}
|
|
6253
6442
|
),
|
|
6254
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
6443
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles28.line, { backgroundColor: theme.colors.accent }] })
|
|
6255
6444
|
]
|
|
6256
6445
|
}
|
|
6257
6446
|
);
|
|
6258
6447
|
}
|
|
6259
|
-
var
|
|
6448
|
+
var styles28 = reactNative.StyleSheet.create({
|
|
6260
6449
|
row: {
|
|
6261
6450
|
flexDirection: "row",
|
|
6262
6451
|
alignItems: "center",
|
|
@@ -6425,15 +6614,15 @@ function ThreadSheet({
|
|
|
6425
6614
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
6426
6615
|
reactNative.View,
|
|
6427
6616
|
{
|
|
6428
|
-
style:
|
|
6617
|
+
style: styles29.modalRoot,
|
|
6429
6618
|
onLayout: (e) => setRootHeight(Math.round(e.nativeEvent.layout.height)),
|
|
6430
6619
|
children: [
|
|
6431
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style:
|
|
6620
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style: styles29.backdrop, onPress: onClose, accessibilityLabel: "Close thread" }),
|
|
6432
6621
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
6433
6622
|
reactNative.Animated.View,
|
|
6434
6623
|
{
|
|
6435
6624
|
style: [
|
|
6436
|
-
|
|
6625
|
+
styles29.sheet,
|
|
6437
6626
|
{
|
|
6438
6627
|
height: sheetHeight,
|
|
6439
6628
|
backgroundColor: theme.colors.background,
|
|
@@ -6447,14 +6636,14 @@ function ThreadSheet({
|
|
|
6447
6636
|
],
|
|
6448
6637
|
children: [
|
|
6449
6638
|
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { ...panHandlers, children: [
|
|
6450
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
6451
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
6639
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles29.dragHandle, children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles29.dragPill, { backgroundColor: theme.colors.textSubtle }] }) }),
|
|
6640
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles29.header, { borderBottomColor: theme.colors.border }], children: [
|
|
6452
6641
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6453
6642
|
reactNative.Pressable,
|
|
6454
6643
|
{
|
|
6455
6644
|
onPress: onClose,
|
|
6456
6645
|
hitSlop: 16,
|
|
6457
|
-
style: [
|
|
6646
|
+
style: [styles29.closeBtn, { backgroundColor: theme.colors.surfaceAlt }],
|
|
6458
6647
|
accessibilityLabel: "Close thread",
|
|
6459
6648
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "close", size: 18, color: theme.colors.text })
|
|
6460
6649
|
}
|
|
@@ -6462,7 +6651,7 @@ function ThreadSheet({
|
|
|
6462
6651
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6463
6652
|
reactNative.Text,
|
|
6464
6653
|
{
|
|
6465
|
-
style: [
|
|
6654
|
+
style: [styles29.title, { color: theme.colors.text, fontFamily: theme.fonts.display }],
|
|
6466
6655
|
children: "Thread"
|
|
6467
6656
|
}
|
|
6468
6657
|
)
|
|
@@ -6471,18 +6660,25 @@ function ThreadSheet({
|
|
|
6471
6660
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
6472
6661
|
reactNative.KeyboardAvoidingView,
|
|
6473
6662
|
{
|
|
6474
|
-
style:
|
|
6663
|
+
style: styles29.kavBody,
|
|
6475
6664
|
behavior: "padding",
|
|
6476
6665
|
keyboardVerticalOffset: gutter,
|
|
6477
6666
|
children: [
|
|
6478
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
6479
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
6667
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles29.rootPreview, { backgroundColor: theme.colors.surfaceAlt }], children: rootRow }),
|
|
6668
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles29.listWrap, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6480
6669
|
MessageList,
|
|
6481
6670
|
{
|
|
6482
6671
|
messages: replies,
|
|
6483
6672
|
hasMore,
|
|
6484
6673
|
onLoadMore: loadMore,
|
|
6485
|
-
renderItem: renderReply
|
|
6674
|
+
renderItem: renderReply,
|
|
6675
|
+
emptyState: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6676
|
+
EmptyState,
|
|
6677
|
+
{
|
|
6678
|
+
title: "No replies yet",
|
|
6679
|
+
hint: "Write a reply below to start the thread."
|
|
6680
|
+
}
|
|
6681
|
+
)
|
|
6486
6682
|
}
|
|
6487
6683
|
) }),
|
|
6488
6684
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -6514,7 +6710,7 @@ function ThreadSheet({
|
|
|
6514
6710
|
}
|
|
6515
6711
|
);
|
|
6516
6712
|
}
|
|
6517
|
-
var
|
|
6713
|
+
var styles29 = reactNative.StyleSheet.create({
|
|
6518
6714
|
modalRoot: {
|
|
6519
6715
|
flex: 1,
|
|
6520
6716
|
justifyContent: "flex-end"
|
|
@@ -6586,7 +6782,7 @@ function TypingIndicator({ typing, labelFor }) {
|
|
|
6586
6782
|
const ids = Array.from(typing);
|
|
6587
6783
|
const isTyping = ids.length > 0;
|
|
6588
6784
|
if (!isTyping) return /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: { height: 0 } });
|
|
6589
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
6785
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles30.row, children: [
|
|
6590
6786
|
/* @__PURE__ */ jsxRuntime.jsx(TypingDots, {}),
|
|
6591
6787
|
/* @__PURE__ */ jsxRuntime.jsx(TypingLabel, { ids, ...labelFor ? { labelFor } : {} })
|
|
6592
6788
|
] });
|
|
@@ -6631,7 +6827,7 @@ function TypingDots() {
|
|
|
6631
6827
|
],
|
|
6632
6828
|
opacity: val.interpolate({ inputRange: [0, 1], outputRange: [0.5, 1] })
|
|
6633
6829
|
});
|
|
6634
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
6830
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles30.dotsWrap, children: [
|
|
6635
6831
|
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Animated.View, { style: dot(a) }),
|
|
6636
6832
|
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Animated.View, { style: dot(b) }),
|
|
6637
6833
|
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Animated.View, { style: dot(c) })
|
|
@@ -6647,9 +6843,9 @@ function TypingLabel({
|
|
|
6647
6843
|
const name1 = useDisplayName(id1, labelFor);
|
|
6648
6844
|
const name2 = useDisplayName(id2, labelFor);
|
|
6649
6845
|
const text = ids.length === 1 ? `${name1} is typing` : ids.length === 2 ? `${name1} and ${name2} are typing` : `${ids.length} people are typing`;
|
|
6650
|
-
return /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
6846
|
+
return /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles30.label, { color: theme.colors.textMuted, fontFamily: theme.fonts.body }], children: text });
|
|
6651
6847
|
}
|
|
6652
|
-
var
|
|
6848
|
+
var styles30 = reactNative.StyleSheet.create({
|
|
6653
6849
|
row: {
|
|
6654
6850
|
flexDirection: "row",
|
|
6655
6851
|
alignItems: "center",
|
|
@@ -6687,21 +6883,40 @@ function parseDraft(raw) {
|
|
|
6687
6883
|
}
|
|
6688
6884
|
}
|
|
6689
6885
|
var DraftStore = class {
|
|
6886
|
+
/**
|
|
6887
|
+
* `namespace` resolves to the client's namespace; without it keys are
|
|
6888
|
+
* the pre-3.8 `poolse:draft:<conversation>` (tests, single client).
|
|
6889
|
+
*/
|
|
6890
|
+
constructor(namespace) {
|
|
6891
|
+
this.namespace = namespace;
|
|
6892
|
+
}
|
|
6893
|
+
namespace;
|
|
6690
6894
|
memory = /* @__PURE__ */ new Map();
|
|
6895
|
+
written = /* @__PURE__ */ new Map();
|
|
6691
6896
|
/** The in-memory draft, if any. */
|
|
6692
6897
|
peek(conversationId) {
|
|
6693
6898
|
return this.memory.get(conversationId) ?? null;
|
|
6694
6899
|
}
|
|
6695
6900
|
/**
|
|
6696
6901
|
* The draft: from memory, else from `storage` (which then seeds the
|
|
6697
|
-
* memory). Null when there's none, or
|
|
6902
|
+
* memory; a pre-3.8 key is moved over). Null when there's none, or
|
|
6903
|
+
* storage fails.
|
|
6698
6904
|
*/
|
|
6699
6905
|
async load(conversationId, storage) {
|
|
6700
6906
|
const inMemory = this.memory.get(conversationId);
|
|
6701
6907
|
if (inMemory) return inMemory;
|
|
6702
6908
|
if (!storage) return null;
|
|
6703
6909
|
try {
|
|
6704
|
-
const
|
|
6910
|
+
const key = await this.key(conversationId);
|
|
6911
|
+
let stored = parseDraft(await storage.get(key));
|
|
6912
|
+
const legacy = draftKey(conversationId);
|
|
6913
|
+
if (!stored && key !== legacy) {
|
|
6914
|
+
stored = parseDraft(await storage.get(legacy));
|
|
6915
|
+
if (stored && !isEmptyDraft(stored)) {
|
|
6916
|
+
this.write(storage, key, stored);
|
|
6917
|
+
swallow(() => storage.remove(legacy));
|
|
6918
|
+
}
|
|
6919
|
+
}
|
|
6705
6920
|
if (stored && !isEmptyDraft(stored) && !this.memory.has(conversationId)) {
|
|
6706
6921
|
this.memory.set(conversationId, stored);
|
|
6707
6922
|
}
|
|
@@ -6717,15 +6932,72 @@ var DraftStore = class {
|
|
|
6717
6932
|
return;
|
|
6718
6933
|
}
|
|
6719
6934
|
this.memory.set(conversationId, draft);
|
|
6720
|
-
if (storage) {
|
|
6721
|
-
|
|
6935
|
+
if (storage && !this.namespace) {
|
|
6936
|
+
this.write(storage, draftKey(conversationId), draft);
|
|
6937
|
+
} else if (storage) {
|
|
6938
|
+
void this.key(conversationId).then(
|
|
6939
|
+
(key) => this.write(storage, key, draft),
|
|
6940
|
+
() => void 0
|
|
6941
|
+
);
|
|
6722
6942
|
}
|
|
6723
6943
|
}
|
|
6724
6944
|
clear(conversationId, storage) {
|
|
6725
6945
|
this.memory.delete(conversationId);
|
|
6726
|
-
if (storage
|
|
6946
|
+
if (storage && !this.namespace) {
|
|
6947
|
+
swallow(() => storage.remove(draftKey(conversationId)));
|
|
6948
|
+
} else if (storage) {
|
|
6949
|
+
void this.key(conversationId).then(
|
|
6950
|
+
(key) => swallow(() => storage.remove(key)),
|
|
6951
|
+
() => void 0
|
|
6952
|
+
);
|
|
6953
|
+
}
|
|
6954
|
+
}
|
|
6955
|
+
/** Called by `chat.destroy()`. @internal */
|
|
6956
|
+
async destroy(opts) {
|
|
6957
|
+
this.memory.clear();
|
|
6958
|
+
if (!opts.clearStorage) return;
|
|
6959
|
+
const ns = this.namespace ? await this.namespace() : null;
|
|
6960
|
+
for (const [storage, keys] of this.written) {
|
|
6961
|
+
const all = new Set(keys);
|
|
6962
|
+
if (ns) {
|
|
6963
|
+
try {
|
|
6964
|
+
const listed = JSON.parse(await storage.get(indexKey(ns)) ?? "[]");
|
|
6965
|
+
if (Array.isArray(listed)) {
|
|
6966
|
+
for (const k of listed) if (typeof k === "string") all.add(k);
|
|
6967
|
+
}
|
|
6968
|
+
} catch {
|
|
6969
|
+
}
|
|
6970
|
+
swallow(() => storage.remove(indexKey(ns)));
|
|
6971
|
+
}
|
|
6972
|
+
for (const k of all) swallow(() => storage.remove(k));
|
|
6973
|
+
}
|
|
6974
|
+
this.written.clear();
|
|
6975
|
+
}
|
|
6976
|
+
async key(conversationId) {
|
|
6977
|
+
if (!this.namespace) return draftKey(conversationId);
|
|
6978
|
+
return `${await this.namespace()}:draft:${conversationId}`;
|
|
6979
|
+
}
|
|
6980
|
+
write(storage, key, draft) {
|
|
6981
|
+
swallow(() => storage.set(key, JSON.stringify(draft)));
|
|
6982
|
+
let keys = this.written.get(storage);
|
|
6983
|
+
if (!keys) {
|
|
6984
|
+
keys = /* @__PURE__ */ new Set();
|
|
6985
|
+
this.written.set(storage, keys);
|
|
6986
|
+
}
|
|
6987
|
+
if (keys.has(key) || !this.namespace) return;
|
|
6988
|
+
keys.add(key);
|
|
6989
|
+
const all = keys;
|
|
6990
|
+
void this.namespace().then(async (ns) => {
|
|
6991
|
+
try {
|
|
6992
|
+
const listed = JSON.parse(await storage.get(indexKey(ns)) ?? "[]");
|
|
6993
|
+
const prev = Array.isArray(listed) ? listed.filter((k) => typeof k === "string") : [];
|
|
6994
|
+
await storage.set(indexKey(ns), JSON.stringify([.../* @__PURE__ */ new Set([...prev, ...all])]));
|
|
6995
|
+
} catch {
|
|
6996
|
+
}
|
|
6997
|
+
});
|
|
6727
6998
|
}
|
|
6728
6999
|
};
|
|
7000
|
+
var indexKey = (ns) => `${ns}:draft-index`;
|
|
6729
7001
|
function swallow(fn) {
|
|
6730
7002
|
try {
|
|
6731
7003
|
const r = fn();
|
|
@@ -6735,7 +7007,9 @@ function swallow(fn) {
|
|
|
6735
7007
|
} catch {
|
|
6736
7008
|
}
|
|
6737
7009
|
}
|
|
6738
|
-
|
|
7010
|
+
function draftStoreOf(chat) {
|
|
7011
|
+
return chat.scoped("react-native:drafts", (c) => new DraftStore(() => c.whenNamespace()));
|
|
7012
|
+
}
|
|
6739
7013
|
|
|
6740
7014
|
// src/internal/errors.ts
|
|
6741
7015
|
function sendErrorNotice(err) {
|
|
@@ -6850,11 +7124,14 @@ function ConversationView({
|
|
|
6850
7124
|
loadMore,
|
|
6851
7125
|
loadUntil,
|
|
6852
7126
|
send,
|
|
7127
|
+
retry: retrySend,
|
|
7128
|
+
discard: discardSend,
|
|
6853
7129
|
edit,
|
|
6854
7130
|
delete: deleteMsg,
|
|
6855
7131
|
markReadUpTo,
|
|
6856
7132
|
refetch
|
|
6857
7133
|
} = react$1.useMessages(conversationId);
|
|
7134
|
+
const drafts = draftStoreOf(chat);
|
|
6858
7135
|
const { typing: typingPeople, signalTyping } = react$1.useTyping(conversationId);
|
|
6859
7136
|
const streams = react$1.useMessageStreams(conversationId);
|
|
6860
7137
|
const typing = react.useMemo(() => {
|
|
@@ -6895,24 +7172,22 @@ function ConversationView({
|
|
|
6895
7172
|
[layout, density, timeFormat, slots]
|
|
6896
7173
|
);
|
|
6897
7174
|
const [draftFor, setDraftFor] = react.useState(conversationId);
|
|
6898
|
-
const [draftText, setDraftText] = react.useState(
|
|
6899
|
-
() => sharedDraftStore.peek(conversationId)?.text ?? ""
|
|
6900
|
-
);
|
|
7175
|
+
const [draftText, setDraftText] = react.useState(() => drafts.peek(conversationId)?.text ?? "");
|
|
6901
7176
|
const [replyingTo, setReplyingTo] = react.useState(
|
|
6902
|
-
() =>
|
|
7177
|
+
() => drafts.peek(conversationId)?.quote ?? null
|
|
6903
7178
|
);
|
|
6904
7179
|
const touchedRef = react.useRef(false);
|
|
6905
7180
|
const [storedDraftRead, setStoredDraftRead] = react.useState(false);
|
|
6906
7181
|
react.useEffect(() => {
|
|
6907
7182
|
let live = true;
|
|
6908
7183
|
touchedRef.current = false;
|
|
6909
|
-
const inMemory =
|
|
7184
|
+
const inMemory = drafts.peek(conversationId);
|
|
6910
7185
|
setDraftFor(conversationId);
|
|
6911
7186
|
setDraftText(inMemory?.text ?? "");
|
|
6912
7187
|
setReplyingTo(inMemory?.quote ?? null);
|
|
6913
7188
|
if (!inMemory && storage) {
|
|
6914
7189
|
setStoredDraftRead(false);
|
|
6915
|
-
void
|
|
7190
|
+
void drafts.load(conversationId, storage).then((d) => {
|
|
6916
7191
|
if (!live) return;
|
|
6917
7192
|
setStoredDraftRead(true);
|
|
6918
7193
|
if (!d || touchedRef.current) return;
|
|
@@ -6930,23 +7205,23 @@ function ConversationView({
|
|
|
6930
7205
|
react.useEffect(() => {
|
|
6931
7206
|
if (draftFor !== conversationId) return;
|
|
6932
7207
|
const draft = { text: draftText, quote: replyingTo };
|
|
6933
|
-
|
|
7208
|
+
drafts.save(conversationId, draft);
|
|
6934
7209
|
if (!storage || !storedDraftRead) return;
|
|
6935
7210
|
pendingDraftRef.current = { id: conversationId, draft };
|
|
6936
7211
|
const t = setTimeout(() => {
|
|
6937
7212
|
pendingDraftRef.current = null;
|
|
6938
|
-
|
|
7213
|
+
drafts.save(conversationId, draft, storage);
|
|
6939
7214
|
}, 400);
|
|
6940
7215
|
return () => clearTimeout(t);
|
|
6941
|
-
}, [draftFor, conversationId, draftText, replyingTo, storage, storedDraftRead]);
|
|
7216
|
+
}, [drafts, draftFor, conversationId, draftText, replyingTo, storage, storedDraftRead]);
|
|
6942
7217
|
const storageRef = react.useRef(storage);
|
|
6943
7218
|
storageRef.current = storage;
|
|
6944
7219
|
react.useEffect(
|
|
6945
7220
|
() => () => {
|
|
6946
7221
|
const pending = pendingDraftRef.current;
|
|
6947
|
-
if (pending)
|
|
7222
|
+
if (pending) drafts.save(pending.id, pending.draft, storageRef.current);
|
|
6948
7223
|
},
|
|
6949
|
-
[]
|
|
7224
|
+
[drafts]
|
|
6950
7225
|
);
|
|
6951
7226
|
const [notice, setNotice] = react.useState(null);
|
|
6952
7227
|
react.useEffect(() => {
|
|
@@ -7133,6 +7408,10 @@ function ConversationView({
|
|
|
7133
7408
|
showPresence,
|
|
7134
7409
|
linkPreviews,
|
|
7135
7410
|
...markable ? { onMarkUnread: () => markMessageUnread(msg) } : {},
|
|
7411
|
+
...msg.local_status ? {
|
|
7412
|
+
onRetrySend: () => void retrySend(msg.id).catch(() => void 0),
|
|
7413
|
+
onDiscardSend: () => discardSend(msg.id)
|
|
7414
|
+
} : {},
|
|
7136
7415
|
...linkPreviews && isSelf && !tombstone && (msg.link_previews?.length ?? 0) > 0 ? { onRemoveLinkPreview: (url) => removeLinkPreview(msg.id, url) } : {},
|
|
7137
7416
|
reactions,
|
|
7138
7417
|
attachments,
|
|
@@ -7164,6 +7443,8 @@ function ConversationView({
|
|
|
7164
7443
|
return /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: { backgroundColor: theme.colors.accentSoft }, children: row });
|
|
7165
7444
|
},
|
|
7166
7445
|
[
|
|
7446
|
+
retrySend,
|
|
7447
|
+
discardSend,
|
|
7167
7448
|
onCallBack,
|
|
7168
7449
|
onQuotedClick,
|
|
7169
7450
|
onSenderPress,
|
|
@@ -7239,9 +7520,17 @@ function ConversationView({
|
|
|
7239
7520
|
const composerProps = react.useMemo(
|
|
7240
7521
|
() => ({
|
|
7241
7522
|
onSend: async (body, opts) => {
|
|
7523
|
+
const id = sdk.safeUuid();
|
|
7242
7524
|
try {
|
|
7243
|
-
await send({ body, ...opts });
|
|
7525
|
+
await send({ body, ...opts, id });
|
|
7244
7526
|
} catch (err) {
|
|
7527
|
+
const kept = err instanceof sdk.MessageQueuedError || chat.outboxEnabled && !isQuoteGone(err);
|
|
7528
|
+
if (kept) {
|
|
7529
|
+
setReplyingTo(null);
|
|
7530
|
+
setAutoReadPaused(false);
|
|
7531
|
+
return;
|
|
7532
|
+
}
|
|
7533
|
+
if (isQuoteGone(err)) discardSend(id);
|
|
7245
7534
|
setDraftText((now) => now ? now : body);
|
|
7246
7535
|
if (isQuoteGone(err)) setReplyingTo(null);
|
|
7247
7536
|
setNotice(sendErrorNotice(err));
|
|
@@ -7274,6 +7563,8 @@ function ConversationView({
|
|
|
7274
7563
|
}),
|
|
7275
7564
|
[
|
|
7276
7565
|
send,
|
|
7566
|
+
chat.outboxEnabled,
|
|
7567
|
+
discardSend,
|
|
7277
7568
|
signalTyping,
|
|
7278
7569
|
attachments,
|
|
7279
7570
|
replyingTo,
|
|
@@ -7301,7 +7592,7 @@ function ConversationView({
|
|
|
7301
7592
|
return /* @__PURE__ */ jsxRuntime.jsx(UploadProvider, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7302
7593
|
reactNative.KeyboardAvoidingView,
|
|
7303
7594
|
{
|
|
7304
|
-
style: [
|
|
7595
|
+
style: [styles31.root, { backgroundColor: theme.colors.background }],
|
|
7305
7596
|
behavior: reactNative.Platform.OS === "ios" ? "padding" : "height",
|
|
7306
7597
|
keyboardVerticalOffset: keyboardOffset,
|
|
7307
7598
|
children: [
|
|
@@ -7310,7 +7601,7 @@ function ConversationView({
|
|
|
7310
7601
|
reactNative.Text,
|
|
7311
7602
|
{
|
|
7312
7603
|
style: [
|
|
7313
|
-
|
|
7604
|
+
styles31.notice,
|
|
7314
7605
|
{ color: theme.colors.textMuted, backgroundColor: theme.colors.surfaceAlt }
|
|
7315
7606
|
],
|
|
7316
7607
|
accessibilityRole: "alert",
|
|
@@ -7326,7 +7617,7 @@ function ConversationView({
|
|
|
7326
7617
|
onJoin: onJoinCall
|
|
7327
7618
|
}
|
|
7328
7619
|
) : null,
|
|
7329
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
7620
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles31.listWrap, children: [
|
|
7330
7621
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7331
7622
|
MessageList,
|
|
7332
7623
|
{
|
|
@@ -7345,7 +7636,7 @@ function ConversationView({
|
|
|
7345
7636
|
(stream) => stream.status === "failed" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7346
7637
|
reactNative.Text,
|
|
7347
7638
|
{
|
|
7348
|
-
style: [
|
|
7639
|
+
style: [styles31.streamFailed, { color: theme.colors.textSubtle }],
|
|
7349
7640
|
accessibilityRole: "alert",
|
|
7350
7641
|
children: stream.error ? `The agent couldn't reply: ${stream.error}` : "The agent couldn't reply."
|
|
7351
7642
|
},
|
|
@@ -7372,7 +7663,13 @@ function ConversationView({
|
|
|
7372
7663
|
),
|
|
7373
7664
|
/* @__PURE__ */ jsxRuntime.jsx(TypingIndicator, { typing, ...labelFor ? { labelFor } : {} })
|
|
7374
7665
|
] }),
|
|
7375
|
-
|
|
7666
|
+
emptyState: emptyState !== void 0 ? emptyState : /* @__PURE__ */ jsxRuntime.jsx(
|
|
7667
|
+
EmptyState,
|
|
7668
|
+
{
|
|
7669
|
+
title: "No messages yet",
|
|
7670
|
+
...showComposer ? { hint: "Write the first message below \u2014 everyone here will see it." } : {}
|
|
7671
|
+
}
|
|
7672
|
+
)
|
|
7376
7673
|
}
|
|
7377
7674
|
),
|
|
7378
7675
|
unreadPending ? /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -7380,7 +7677,7 @@ function ConversationView({
|
|
|
7380
7677
|
{
|
|
7381
7678
|
onPress: jumpToUnread,
|
|
7382
7679
|
style: [
|
|
7383
|
-
|
|
7680
|
+
styles31.unreadPill,
|
|
7384
7681
|
{ backgroundColor: theme.colors.accent, borderRadius: theme.radii.pill },
|
|
7385
7682
|
theme.shadows.sm
|
|
7386
7683
|
],
|
|
@@ -7396,7 +7693,7 @@ function ConversationView({
|
|
|
7396
7693
|
label: null
|
|
7397
7694
|
}
|
|
7398
7695
|
),
|
|
7399
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
7696
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles31.unreadPillText, { color: theme.colors.accentText }], children: seekingUnread ? "Loading\u2026" : "New messages" }),
|
|
7400
7697
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7401
7698
|
reactNative.Pressable,
|
|
7402
7699
|
{
|
|
@@ -7413,7 +7710,7 @@ function ConversationView({
|
|
|
7413
7710
|
editingId ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7414
7711
|
reactNative.Pressable,
|
|
7415
7712
|
{
|
|
7416
|
-
style: [
|
|
7713
|
+
style: [styles31.editBackdrop, { backgroundColor: theme.colors.overlay }],
|
|
7417
7714
|
onPress: () => setEditingId(null),
|
|
7418
7715
|
accessibilityLabel: "Cancel editing"
|
|
7419
7716
|
}
|
|
@@ -7475,7 +7772,7 @@ function readStateForMessage(msg, members, meId, sequenceByMessageId) {
|
|
|
7475
7772
|
return anyRead ? "read" : "sent";
|
|
7476
7773
|
}
|
|
7477
7774
|
var NEW_MESSAGES_KEY = "new-messages";
|
|
7478
|
-
var
|
|
7775
|
+
var styles31 = reactNative.StyleSheet.create({
|
|
7479
7776
|
root: {
|
|
7480
7777
|
flex: 1
|
|
7481
7778
|
},
|
|
@@ -7611,15 +7908,15 @@ function UserPickerSheet({
|
|
|
7611
7908
|
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7612
7909
|
reactNative.View,
|
|
7613
7910
|
{
|
|
7614
|
-
style:
|
|
7911
|
+
style: styles32.modalRoot,
|
|
7615
7912
|
onLayout: (e) => setRootHeight(Math.round(e.nativeEvent.layout.height)),
|
|
7616
7913
|
children: [
|
|
7617
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style:
|
|
7914
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style: styles32.backdrop, onPress: handleClose }),
|
|
7618
7915
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7619
7916
|
reactNative.Animated.View,
|
|
7620
7917
|
{
|
|
7621
7918
|
style: [
|
|
7622
|
-
|
|
7919
|
+
styles32.sheet,
|
|
7623
7920
|
{
|
|
7624
7921
|
backgroundColor: theme.colors.background,
|
|
7625
7922
|
borderTopLeftRadius: theme.radii.xl,
|
|
@@ -7637,18 +7934,18 @@ function UserPickerSheet({
|
|
|
7637
7934
|
children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7638
7935
|
reactNative.KeyboardAvoidingView,
|
|
7639
7936
|
{
|
|
7640
|
-
style:
|
|
7937
|
+
style: styles32.kav,
|
|
7641
7938
|
behavior: "padding",
|
|
7642
7939
|
keyboardVerticalOffset: screenHeight - sheetHeight,
|
|
7643
7940
|
children: [
|
|
7644
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { ...panHandlers, style:
|
|
7645
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
7941
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { ...panHandlers, style: styles32.dragHandle, children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles32.dragPill, { backgroundColor: theme.colors.textSubtle }] }) }),
|
|
7942
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles32.header, children: [
|
|
7646
7943
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7647
7944
|
reactNative.Pressable,
|
|
7648
7945
|
{
|
|
7649
7946
|
onPress: handleClose,
|
|
7650
7947
|
hitSlop: 16,
|
|
7651
|
-
style: [
|
|
7948
|
+
style: [styles32.closeBtn, { backgroundColor: theme.colors.surfaceAlt }],
|
|
7652
7949
|
accessibilityLabel: "Close picker",
|
|
7653
7950
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "close", size: 18, color: theme.colors.text })
|
|
7654
7951
|
}
|
|
@@ -7657,7 +7954,7 @@ function UserPickerSheet({
|
|
|
7657
7954
|
reactNative.Text,
|
|
7658
7955
|
{
|
|
7659
7956
|
style: [
|
|
7660
|
-
|
|
7957
|
+
styles32.title,
|
|
7661
7958
|
{ color: theme.colors.text, fontFamily: theme.fonts.display }
|
|
7662
7959
|
],
|
|
7663
7960
|
numberOfLines: 1,
|
|
@@ -7671,7 +7968,7 @@ function UserPickerSheet({
|
|
|
7671
7968
|
disabled: !canCreate,
|
|
7672
7969
|
hitSlop: 6,
|
|
7673
7970
|
style: [
|
|
7674
|
-
|
|
7971
|
+
styles32.createBtn,
|
|
7675
7972
|
{
|
|
7676
7973
|
backgroundColor: canCreate ? theme.colors.accent : theme.colors.surfaceAlt,
|
|
7677
7974
|
opacity: canCreate ? 1 : 0.6
|
|
@@ -7702,7 +7999,7 @@ function UserPickerSheet({
|
|
|
7702
7999
|
value: groupName,
|
|
7703
8000
|
onChangeText: setGroupName,
|
|
7704
8001
|
style: [
|
|
7705
|
-
|
|
8002
|
+
styles32.groupNameInput,
|
|
7706
8003
|
{
|
|
7707
8004
|
color: theme.colors.text,
|
|
7708
8005
|
backgroundColor: theme.colors.surfaceAlt,
|
|
@@ -7721,7 +8018,7 @@ function UserPickerSheet({
|
|
|
7721
8018
|
value: query,
|
|
7722
8019
|
onChangeText: setQuery,
|
|
7723
8020
|
style: [
|
|
7724
|
-
|
|
8021
|
+
styles32.searchInput,
|
|
7725
8022
|
{
|
|
7726
8023
|
color: theme.colors.text,
|
|
7727
8024
|
backgroundColor: theme.colors.surfaceAlt,
|
|
@@ -7738,7 +8035,7 @@ function UserPickerSheet({
|
|
|
7738
8035
|
data: filtered,
|
|
7739
8036
|
keyExtractor: (u) => u.externalId,
|
|
7740
8037
|
keyboardShouldPersistTaps: "handled",
|
|
7741
|
-
ListEmptyComponent: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
8038
|
+
ListEmptyComponent: /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles32.empty, children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles32.emptyText, { color: theme.colors.textSubtle }], children: query ? "No matches." : "No users to show." }) }),
|
|
7742
8039
|
renderItem: ({ item }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7743
8040
|
UserRow,
|
|
7744
8041
|
{
|
|
@@ -7780,29 +8077,29 @@ function UserRow({
|
|
|
7780
8077
|
{
|
|
7781
8078
|
onPress,
|
|
7782
8079
|
style: [
|
|
7783
|
-
|
|
8080
|
+
styles32.row,
|
|
7784
8081
|
{
|
|
7785
8082
|
backgroundColor: selected ? theme.colors.accentSoft : "transparent"
|
|
7786
8083
|
}
|
|
7787
8084
|
],
|
|
7788
8085
|
children: [
|
|
7789
|
-
user.avatarUrl ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Image, { source: { uri: user.avatarUrl }, style:
|
|
7790
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
8086
|
+
user.avatarUrl ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Image, { source: { uri: user.avatarUrl }, style: styles32.avatarImg }) : /* @__PURE__ */ jsxRuntime.jsx(Avatar, { src: null, name: user.name, seed: user.externalId, size: "md" }),
|
|
8087
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles32.body, children: [
|
|
7791
8088
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7792
8089
|
reactNative.Text,
|
|
7793
8090
|
{
|
|
7794
|
-
style: [
|
|
8091
|
+
style: [styles32.name, { color: theme.colors.text, fontFamily: theme.fonts.body }],
|
|
7795
8092
|
numberOfLines: 1,
|
|
7796
8093
|
children: user.name
|
|
7797
8094
|
}
|
|
7798
8095
|
),
|
|
7799
|
-
user.subtitle ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
8096
|
+
user.subtitle ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles32.subtitle, { color: theme.colors.textSubtle }], numberOfLines: 1, children: user.subtitle }) : null
|
|
7800
8097
|
] }),
|
|
7801
8098
|
isGroup ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
7802
8099
|
reactNative.View,
|
|
7803
8100
|
{
|
|
7804
8101
|
style: [
|
|
7805
|
-
|
|
8102
|
+
styles32.checkbox,
|
|
7806
8103
|
{
|
|
7807
8104
|
borderColor: selected ? theme.colors.accent : theme.colors.border,
|
|
7808
8105
|
backgroundColor: selected ? theme.colors.accent : "transparent"
|
|
@@ -7815,7 +8112,7 @@ function UserRow({
|
|
|
7815
8112
|
}
|
|
7816
8113
|
);
|
|
7817
8114
|
}
|
|
7818
|
-
var
|
|
8115
|
+
var styles32 = reactNative.StyleSheet.create({
|
|
7819
8116
|
modalRoot: {
|
|
7820
8117
|
flex: 1,
|
|
7821
8118
|
justifyContent: "flex-end"
|
|
@@ -8086,7 +8383,7 @@ var PoolseInbox = react.forwardRef(
|
|
|
8086
8383
|
},
|
|
8087
8384
|
[renderConversationRow, meExternalId, meId, labelFor, avatarFor, unreadCounts, showPresence]
|
|
8088
8385
|
);
|
|
8089
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [
|
|
8386
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: [styles33.root, { backgroundColor: theme.colors.background }], children: [
|
|
8090
8387
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8091
8388
|
reactNative.Animated.View,
|
|
8092
8389
|
{
|
|
@@ -8097,7 +8394,7 @@ var PoolseInbox = react.forwardRef(
|
|
|
8097
8394
|
reactNative.View,
|
|
8098
8395
|
{
|
|
8099
8396
|
style: [
|
|
8100
|
-
|
|
8397
|
+
styles33.listHeader,
|
|
8101
8398
|
{
|
|
8102
8399
|
backgroundColor: theme.colors.surface,
|
|
8103
8400
|
borderBottomColor: theme.colors.border
|
|
@@ -8108,13 +8405,13 @@ var PoolseInbox = react.forwardRef(
|
|
|
8108
8405
|
reactNative.Text,
|
|
8109
8406
|
{
|
|
8110
8407
|
style: [
|
|
8111
|
-
|
|
8408
|
+
styles33.listTitle,
|
|
8112
8409
|
{ color: theme.colors.text, fontFamily: theme.fonts.display }
|
|
8113
8410
|
],
|
|
8114
8411
|
children: title
|
|
8115
8412
|
}
|
|
8116
8413
|
),
|
|
8117
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
8414
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles33.headerActions, children: [
|
|
8118
8415
|
users ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
8119
8416
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8120
8417
|
HeaderIconButton,
|
|
@@ -8230,7 +8527,7 @@ function HeaderIconButton({
|
|
|
8230
8527
|
hitSlop: 10,
|
|
8231
8528
|
accessibilityLabel: label,
|
|
8232
8529
|
style: ({ pressed }) => [
|
|
8233
|
-
|
|
8530
|
+
styles33.iconBtn,
|
|
8234
8531
|
{
|
|
8235
8532
|
backgroundColor: pressed ? theme.colors.surfaceAlt : "transparent"
|
|
8236
8533
|
}
|
|
@@ -8263,7 +8560,7 @@ function DefaultConversationRow({
|
|
|
8263
8560
|
{
|
|
8264
8561
|
onPress,
|
|
8265
8562
|
style: [
|
|
8266
|
-
|
|
8563
|
+
styles33.row,
|
|
8267
8564
|
{
|
|
8268
8565
|
backgroundColor: selected ? theme.colors.surfaceAlt : "transparent",
|
|
8269
8566
|
borderBottomColor: theme.colors.border
|
|
@@ -8280,23 +8577,23 @@ function DefaultConversationRow({
|
|
|
8280
8577
|
...presence ? { presence: presence.state, doNotDisturb: !!presence.do_not_disturb } : {}
|
|
8281
8578
|
}
|
|
8282
8579
|
),
|
|
8283
|
-
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
8580
|
+
/* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles33.rowBody, children: [
|
|
8284
8581
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8285
8582
|
reactNative.Text,
|
|
8286
8583
|
{
|
|
8287
|
-
style: [
|
|
8584
|
+
style: [styles33.rowTitle, { color: theme.colors.text, fontFamily: theme.fonts.body }],
|
|
8288
8585
|
numberOfLines: 1,
|
|
8289
8586
|
children: title
|
|
8290
8587
|
}
|
|
8291
8588
|
),
|
|
8292
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
8589
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles33.rowSubtitle, { color: theme.colors.textSubtle }], numberOfLines: 1, children: react$1.formatCallLogPreview(conv.last_message_preview, meId) ?? conv.last_message_preview ?? (isDirect ? otherExtId ?? "" : `${(conv.member_external_ids ?? []).length} members`) })
|
|
8293
8590
|
] }),
|
|
8294
|
-
unread > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [
|
|
8591
|
+
unread > 0 ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: [styles33.unreadPill, { backgroundColor: theme.colors.badge }], children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles33.unreadText, { color: theme.colors.badgeText }], children: unread > 99 ? "99+" : String(unread) }) }) : null
|
|
8295
8592
|
]
|
|
8296
8593
|
}
|
|
8297
8594
|
);
|
|
8298
8595
|
}
|
|
8299
|
-
var
|
|
8596
|
+
var styles33 = reactNative.StyleSheet.create({
|
|
8300
8597
|
root: {
|
|
8301
8598
|
flex: 1,
|
|
8302
8599
|
overflow: "hidden"
|
|
@@ -8432,9 +8729,9 @@ function useAppStateLifecycle(options = {}) {
|
|
|
8432
8729
|
const sub = reactNative.AppState.addEventListener("change", (next) => {
|
|
8433
8730
|
if (next === "background") {
|
|
8434
8731
|
setActivity("idle");
|
|
8435
|
-
poolse.
|
|
8732
|
+
poolse.setBackground(true);
|
|
8436
8733
|
} else if (next === "active") {
|
|
8437
|
-
poolse.
|
|
8734
|
+
poolse.setBackground(false);
|
|
8438
8735
|
setActivity("active");
|
|
8439
8736
|
} else {
|
|
8440
8737
|
setActivity("idle");
|
|
@@ -8444,6 +8741,41 @@ function useAppStateLifecycle(options = {}) {
|
|
|
8444
8741
|
}, [poolse, presence]);
|
|
8445
8742
|
}
|
|
8446
8743
|
|
|
8744
|
+
// src/internal/background.ts
|
|
8745
|
+
function applyBackground(clients, active, appActive, keepConnected = []) {
|
|
8746
|
+
for (const c of clients) {
|
|
8747
|
+
if (c.destroyed) continue;
|
|
8748
|
+
const foreground = appActive && (c === active || keepConnected.includes(c));
|
|
8749
|
+
c.setBackground(!foreground);
|
|
8750
|
+
}
|
|
8751
|
+
}
|
|
8752
|
+
|
|
8753
|
+
// src/lifecycle/useBackgroundClients.ts
|
|
8754
|
+
function useBackgroundClients(clients, active, opts = {}) {
|
|
8755
|
+
const [appState, setAppState] = react.useState(reactNative.AppState.currentState ?? "active");
|
|
8756
|
+
react.useEffect(() => {
|
|
8757
|
+
const sub = reactNative.AppState.addEventListener("change", setAppState);
|
|
8758
|
+
return () => sub.remove();
|
|
8759
|
+
}, []);
|
|
8760
|
+
const appActive = appState !== "background";
|
|
8761
|
+
const keep = opts.keepConnected ?? EMPTY;
|
|
8762
|
+
const presence = opts.presence ?? true;
|
|
8763
|
+
const lastActive = react.useRef(null);
|
|
8764
|
+
react.useEffect(() => {
|
|
8765
|
+
applyBackground(clients, active, appActive, keep);
|
|
8766
|
+
}, [clients, active, appActive, keep]);
|
|
8767
|
+
react.useEffect(() => {
|
|
8768
|
+
if (!presence) return;
|
|
8769
|
+
const prev = lastActive.current;
|
|
8770
|
+
if (prev && prev !== active && !prev.destroyed) prev.presence.setActivity("idle");
|
|
8771
|
+
lastActive.current = active;
|
|
8772
|
+
if (active && !active.destroyed) {
|
|
8773
|
+
active.presence.setActivity(appState === "active" ? "active" : "idle");
|
|
8774
|
+
}
|
|
8775
|
+
}, [active, appState, presence]);
|
|
8776
|
+
}
|
|
8777
|
+
var EMPTY = [];
|
|
8778
|
+
|
|
8447
8779
|
// src/voice/callTheme.ts
|
|
8448
8780
|
var callColors = {
|
|
8449
8781
|
/** Behind everything. Near-black, cooled toward the brand. */
|
|
@@ -8492,7 +8824,7 @@ function CallControlButton({
|
|
|
8492
8824
|
const size = large ? CONTROL_SIZE_LARGE : CONTROL_SIZE;
|
|
8493
8825
|
const background = tone === "danger" ? callColors.danger : tone === "accept" ? callColors.accept : active ? callColors.controlActive : callColors.control;
|
|
8494
8826
|
const iconColor = tone === "neutral" && active ? callColors.controlActiveIcon : callColors.onAction;
|
|
8495
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style:
|
|
8827
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(reactNative.View, { style: styles34.slot, children: [
|
|
8496
8828
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8497
8829
|
reactNative.Pressable,
|
|
8498
8830
|
{
|
|
@@ -8503,7 +8835,7 @@ function CallControlButton({
|
|
|
8503
8835
|
accessibilityLabel: accessibilityLabel ?? label ?? icon,
|
|
8504
8836
|
hitSlop: 8,
|
|
8505
8837
|
style: ({ pressed }) => [
|
|
8506
|
-
|
|
8838
|
+
styles34.button,
|
|
8507
8839
|
{
|
|
8508
8840
|
width: size,
|
|
8509
8841
|
height: size,
|
|
@@ -8517,10 +8849,10 @@ function CallControlButton({
|
|
|
8517
8849
|
children: /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: icon, size: large ? 30 : 25, color: iconColor, label: null })
|
|
8518
8850
|
}
|
|
8519
8851
|
),
|
|
8520
|
-
label ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { numberOfLines: 1, style:
|
|
8852
|
+
label ? /* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { numberOfLines: 1, style: styles34.label, children: label }) : null
|
|
8521
8853
|
] });
|
|
8522
8854
|
}
|
|
8523
|
-
var
|
|
8855
|
+
var styles34 = reactNative.StyleSheet.create({
|
|
8524
8856
|
// Fixed width so captions of different lengths cannot shift the row.
|
|
8525
8857
|
slot: { width: 76, alignItems: "center", gap: 7 },
|
|
8526
8858
|
button: { alignItems: "center", justifyContent: "center" },
|
|
@@ -8533,7 +8865,7 @@ function CallAvatar({ name, seed, size, speaking = false }) {
|
|
|
8533
8865
|
reactNative.View,
|
|
8534
8866
|
{
|
|
8535
8867
|
style: [
|
|
8536
|
-
|
|
8868
|
+
styles35.ring,
|
|
8537
8869
|
{
|
|
8538
8870
|
width: outer,
|
|
8539
8871
|
height: outer,
|
|
@@ -8546,7 +8878,7 @@ function CallAvatar({ name, seed, size, speaking = false }) {
|
|
|
8546
8878
|
reactNative.View,
|
|
8547
8879
|
{
|
|
8548
8880
|
style: [
|
|
8549
|
-
|
|
8881
|
+
styles35.circle,
|
|
8550
8882
|
{
|
|
8551
8883
|
width: size,
|
|
8552
8884
|
height: size,
|
|
@@ -8557,7 +8889,7 @@ function CallAvatar({ name, seed, size, speaking = false }) {
|
|
|
8557
8889
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
8558
8890
|
reactNative.Text,
|
|
8559
8891
|
{
|
|
8560
|
-
style: [
|
|
8892
|
+
style: [styles35.initials, { fontSize: Math.round(size * 0.38) }],
|
|
8561
8893
|
numberOfLines: 1,
|
|
8562
8894
|
allowFontScaling: false,
|
|
8563
8895
|
children: initialsOf(name)
|
|
@@ -8574,7 +8906,7 @@ function initialsOf(name) {
|
|
|
8574
8906
|
if (parts.length === 1) return parts[0].slice(0, 2).toUpperCase();
|
|
8575
8907
|
return (parts[0][0] + parts[parts.length - 1][0]).toUpperCase();
|
|
8576
8908
|
}
|
|
8577
|
-
var
|
|
8909
|
+
var styles35 = reactNative.StyleSheet.create({
|
|
8578
8910
|
ring: { alignItems: "center", justifyContent: "center" },
|
|
8579
8911
|
circle: { alignItems: "center", justifyContent: "center" },
|
|
8580
8912
|
initials: { color: "#ffffff", fontWeight: "600" }
|
|
@@ -8602,15 +8934,15 @@ function AudioRouteSheet({
|
|
|
8602
8934
|
animationType: "fade",
|
|
8603
8935
|
onRequestClose: onClose,
|
|
8604
8936
|
...EDGE_TO_EDGE_MODAL,
|
|
8605
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style:
|
|
8937
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(reactNative.Pressable, { style: styles36.backdrop, onPress: onClose, accessibilityRole: "button", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
8606
8938
|
reactNative.Pressable,
|
|
8607
8939
|
{
|
|
8608
|
-
style: [
|
|
8940
|
+
style: [styles36.sheet, { paddingBottom: Math.max(34, insets.bottom + 16) }],
|
|
8609
8941
|
onPress: () => {
|
|
8610
8942
|
},
|
|
8611
8943
|
children: [
|
|
8612
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style:
|
|
8613
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style:
|
|
8944
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.View, { style: styles36.grabber }),
|
|
8945
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: styles36.title, children: "Audio output" }),
|
|
8614
8946
|
routes.map((route) => {
|
|
8615
8947
|
const selected = route.id === selectedRouteId;
|
|
8616
8948
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -8622,7 +8954,7 @@ function AudioRouteSheet({
|
|
|
8622
8954
|
},
|
|
8623
8955
|
accessibilityRole: "button",
|
|
8624
8956
|
accessibilityState: { selected },
|
|
8625
|
-
style: ({ pressed }) => [
|
|
8957
|
+
style: ({ pressed }) => [styles36.row, pressed && styles36.rowPressed],
|
|
8626
8958
|
children: [
|
|
8627
8959
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8628
8960
|
PoolseIcon,
|
|
@@ -8633,7 +8965,7 @@ function AudioRouteSheet({
|
|
|
8633
8965
|
label: null
|
|
8634
8966
|
}
|
|
8635
8967
|
),
|
|
8636
|
-
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [
|
|
8968
|
+
/* @__PURE__ */ jsxRuntime.jsx(reactNative.Text, { style: [styles36.label, selected && styles36.labelSelected], children: route.label }),
|
|
8637
8969
|
selected && /* @__PURE__ */ jsxRuntime.jsx(PoolseIcon, { name: "check", size: 19, color: callColors.accept, label: "selected" })
|
|
8638
8970
|
]
|
|
8639
8971
|
},
|
|
@@ -8646,7 +8978,7 @@ function AudioRouteSheet({
|
|
|
8646
8978
|
}
|
|
8647
8979
|
);
|
|
8648
8980
|
}
|
|
8649
|
-
var
|
|
8981
|
+
var styles36 = reactNative.StyleSheet.create({
|
|
8650
8982
|
backdrop: { flex: 1, backgroundColor: "rgba(0,0,0,0.55)", justifyContent: "flex-end" },
|
|
8651
8983
|
sheet: {
|
|
8652
8984
|
backgroundColor: callColors.tile,
|
|
@@ -8743,6 +9075,7 @@ exports.ConversationView = ConversationView;
|
|
|
8743
9075
|
exports.DaySeparator = DaySeparator;
|
|
8744
9076
|
exports.EditHistorySheet = EditHistorySheet;
|
|
8745
9077
|
exports.EmojiPicker = EmojiPicker;
|
|
9078
|
+
exports.EmptyState = EmptyState;
|
|
8746
9079
|
exports.GroupDetailsSheet = GroupDetailsSheet;
|
|
8747
9080
|
exports.ImageMosaic = ImageMosaic;
|
|
8748
9081
|
exports.LinkPreviewCard = LinkPreviewCard;
|
|
@@ -8763,16 +9096,19 @@ exports.PresenceBadge = PresenceBadge;
|
|
|
8763
9096
|
exports.Primitives = primitives;
|
|
8764
9097
|
exports.ReactionPicker = ReactionPicker;
|
|
8765
9098
|
exports.ReactionStrip = ReactionStrip;
|
|
9099
|
+
exports.SendStatus = SendStatus;
|
|
8766
9100
|
exports.ThreadSummary = ThreadSummary;
|
|
8767
9101
|
exports.ThreadView = ThreadView;
|
|
8768
9102
|
exports.TypingIndicator = TypingIndicator;
|
|
8769
9103
|
exports.UploadQueueStrip = UploadQueueStrip;
|
|
8770
9104
|
exports.UserName = UserName;
|
|
9105
|
+
exports.applyBackground = applyBackground;
|
|
8771
9106
|
exports.callColors = callColors;
|
|
8772
9107
|
exports.defaultDarkTheme = defaultDarkTheme;
|
|
8773
9108
|
exports.defaultLightTheme = defaultLightTheme;
|
|
8774
9109
|
exports.useAppStateLifecycle = useAppStateLifecycle;
|
|
8775
9110
|
exports.useAppStatePresence = useAppStatePresence;
|
|
9111
|
+
exports.useBackgroundClients = useBackgroundClients;
|
|
8776
9112
|
exports.useCallDuration = useCallDuration;
|
|
8777
9113
|
exports.useDisplayName = useDisplayName;
|
|
8778
9114
|
exports.usePoolseTheme = usePoolseTheme;
|