Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: V6.0.0 #2844

Merged
merged 191 commits into from
Dec 12, 2024
Merged
Changes from 1 commit
Commits
Show all changes
191 commits
Select commit Hold shift + click to select a range
1ce7e8e
fix: remove netinfo from native handlers and add it as dev dependency…
khushal87 Jun 6, 2024
9b0367f
feat: remove usage of flatlist-mvcp in favour of mvcp support in RN >…
khushal87 Jun 6, 2024
e9f8a52
fix: change quotedMessage type to MessageType or undefined (#2527)
khushal87 Jun 6, 2024
85b17b7
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Jun 6, 2024
7ad0442
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Jun 7, 2024
633c76d
fix: change react-native-image-resizer to @bam.tech/react-native-imag…
khushal87 Jun 7, 2024
9f8f299
chore: resolve conflicts from develop
khushal87 Jun 18, 2024
3e73dfc
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Jun 19, 2024
62f5ca3
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Jun 21, 2024
87593c3
fix: add reanimated and gesture handler as peer deps to package
khushal87 Jun 21, 2024
c27a218
fix: change old gesture handler useAnimatedGestureHandler to the new …
khushal87 Jun 21, 2024
de929f3
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Jun 28, 2024
b967cfc
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Jun 28, 2024
622bbcb
feat: move react-native-quick-sqlite to op-sqlite (#2541)
khushal87 Jun 28, 2024
709d42b
chore: update deps of expo messaging app
khushal87 Jul 1, 2024
5e14f62
feat: use react-native-blob-util instead of the react-native-fs and m…
khushal87 Jul 5, 2024
573040b
fix: upgrade cameraroll, documentpicker, haptics feedback and image c…
khushal87 Jul 5, 2024
7f4a10d
fix: change react-native-image-crop-picker to react-native-image-pick…
khushal87 Jul 5, 2024
4f29a3f
docs: add migration guide
khushal87 Jul 5, 2024
8386bcd
fix: make expo-image-picker optional
khushal87 Jul 9, 2024
c660b0f
fix: make expo-image-picker optional
khushal87 Jul 9, 2024
c17a629
docs: apply docs changes
khushal87 Jul 9, 2024
b6039f3
Merge pull request #2581 from GetStream/upgrade-deps-cameraroll-image…
khushal87 Jul 10, 2024
d6741b8
fix: conflicts from branch
khushal87 Jul 10, 2024
4f8dbad
fix: add check for handlers in native.ts
khushal87 Jul 10, 2024
d6788b8
Merge pull request #2582 from GetStream/PBE-5070-rn-image-picker
khushal87 Jul 10, 2024
49ab5f4
chore: resolve conflicts from develop
khushal87 Jul 24, 2024
09b5251
fix: resolve conflicts from branch develop to v6 (#2621)
khushal87 Aug 20, 2024
25eb0ff
chore: resolve conflicts from develop
khushal87 Aug 20, 2024
3a13460
chore: resolve conflicts from develop
khushal87 Aug 20, 2024
2f541da
chore: resolve conflicts from develop
khushal87 Aug 20, 2024
1a917b8
chore: fix vale issues
khushal87 Aug 20, 2024
3737e73
chore: fix vale issues
khushal87 Aug 20, 2024
e79ae2e
fix: react-native-safe-area-context ios build issue
khushal87 Aug 21, 2024
4454761
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Aug 21, 2024
35bffd8
fix: bottom sheet version
khushal87 Aug 21, 2024
7325b99
chore: resolve conflicts from develop
khushal87 Aug 21, 2024
a0b617e
fix: remove flipper debugger
khushal87 Aug 21, 2024
05005ce
fix: issue with rn-svg on android and rn-video fabric compatibility
khushal87 Aug 21, 2024
bb58577
fix: animations usage in ImageGallery (#2627)
khushal87 Aug 22, 2024
b14e4db
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Aug 26, 2024
d676da9
fix: remove rn-sqlite patch
khushal87 Aug 26, 2024
924beb4
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Aug 26, 2024
de27078
fix: animations laginess on the ImageGallery and MessageOverlay on ne…
khushal87 Aug 27, 2024
36f2fe1
chore: resolve conflicts from develop
khushal87 Aug 30, 2024
8207356
chore: resolve conflicts from develop (#2682)
khushal87 Sep 19, 2024
8da3ac0
fix: chat.test.ts
khushal87 Sep 26, 2024
f66b4a0
chore: cleanup v3 docs setup and e2e tests from project (#2701)
khushal87 Oct 9, 2024
8b0b4f4
feat: add new message action list and reaction selector UI (#2686)
khushal87 Oct 9, 2024
61fa097
feat: remove StreamChatRN in favour of a global context ChatConfigCon…
khushal87 Oct 11, 2024
0e5a3ef
fix: remove deprecated code from v6 branch (#2702)
khushal87 Oct 11, 2024
1c52f4f
chore: resolve conflicts from develop
khushal87 Oct 15, 2024
56c0b41
feat: new reaction list design and improvements to MessageSimple comp…
khushal87 Oct 15, 2024
db90318
chore: resolve conflicts from v6
khushal87 Oct 15, 2024
e9cc98b
chore: resolve conflicts from develop
khushal87 Oct 21, 2024
7383f88
fix: circular dependency issue
khushal87 Oct 21, 2024
7ea133b
fix: upgrade expo to latest in expo messaging app
khushal87 Oct 21, 2024
5b7aa9c
fix: padding for reaction picker
khushal87 Oct 21, 2024
2f2fb51
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Oct 23, 2024
f087ee5
fix: update dependencies for native cli apps
khushal87 Oct 23, 2024
ac8157f
fix: add Flatlist mvcp as optional package and peer deps versions (#2…
khushal87 Oct 24, 2024
8c7a4ea
chore: resolve conflicts from develop
khushal87 Oct 24, 2024
edab454
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Oct 24, 2024
76cb67d
fix: design issues with ReactionList bottom UI (#2717)
khushal87 Oct 24, 2024
457c694
fix: add a log that complains for removal for mvcp package on RN vers…
khushal87 Oct 25, 2024
c17e542
Merge branch 'develop' of github.com:GetStream/stream-chat-react-nati…
khushal87 Oct 25, 2024
0759817
fix: bottom sheet modal improvements
khushal87 Oct 25, 2024
f093028
fix: use process reactions improvements for thread list
khushal87 Oct 25, 2024
8f4ca60
docs: docusaurus setup for v6 release (#2721)
khushal87 Oct 25, 2024
252e90c
chore: setup workflow and improve migration guide for v6 rc release (…
khushal87 Oct 25, 2024
002ed5a
fix: linting issues
khushal87 Oct 25, 2024
df4d9c0
featv6 rc release
khushal87 Oct 25, 2024
eff9872
feat!: v6 rc release
khushal87 Oct 25, 2024
c4d3e66
feat!: v6 rc release
khushal87 Oct 25, 2024
97762b5
BREAKING CHANGE: v6 rc release
khushal87 Oct 25, 2024
2f36076
fix: upgrade react native version in sample apps to 0.73.10 (#2728)
khushal87 Oct 25, 2024
4e68d2d
feat!: rc release v6 (#2729)
khushal87 Oct 25, 2024
72f7adc
feat: styles changes for MessageActionList
khushal87 Oct 28, 2024
0bad2c5
Merge pull request #2730 from GetStream/v6-rc-release-2
khushal87 Oct 28, 2024
ab94a9e
feat: styles changes for MessageUserReactions
khushal87 Oct 28, 2024
0b8a8d7
Merge pull request #2731 from GetStream/v6-rc-release-3
khushal87 Oct 28, 2024
15b125c
chore: fix noteKeywords in release config
khushal87 Oct 28, 2024
2a7d931
Merge pull request #2732 from GetStream/v6-rc-release-4
khushal87 Oct 28, 2024
1dfe741
feat: improve Message.tsx render conditional (#2733)
khushal87 Oct 28, 2024
4756d0d
feat: remove dry run mode from release config
khushal87 Oct 28, 2024
308806e
fix: way of reading the value from animated shared values in the comp…
khushal87 Oct 29, 2024
4366578
fix: upgrade the RN version in example apps to 0.75.4 (#2739)
khushal87 Oct 29, 2024
3c05a9f
feat: move react native image resizer native module to the SDK (#2751)
khushal87 Nov 4, 2024
d1ecfd7
fix: attachment picker image picker icon visibility as per dependency
khushal87 Nov 4, 2024
f65878d
Merge pull request #2757 from GetStream/attachment-picker-icons-visib…
isekovanic Nov 5, 2024
aeeea75
Merge branch 'develop' into feat/forward-port-polls
isekovanic Nov 5, 2024
4aea22d
fix: changes after merge
isekovanic Nov 5, 2024
7b5dc30
fix: lint issues
isekovanic Nov 5, 2024
ca1853a
fix: revalidate pod cache
isekovanic Nov 5, 2024
0299da9
chore: revert cache revalidation
isekovanic Nov 5, 2024
7f3dcf4
Merge pull request #2759 from GetStream/feat/forward-port-polls
isekovanic Nov 5, 2024
3a6d4c3
fix: sender and receiver message theme colors
khushal87 Nov 8, 2024
7c6fa15
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Nov 8, 2024
9b02af2
fix: sender and receiver message theme colors (#2767)
khushal87 Nov 8, 2024
d778d6d
fix: upgrade op-sqlite version to be compatible with latest react nat…
khushal87 Nov 8, 2024
325629f
chore: backport the polls docs to v5 too
isekovanic Nov 8, 2024
09f06ba
fix: add versioned sidebar update as well
isekovanic Nov 8, 2024
65f1a6b
Merge pull request #2769 from GetStream/chore/backport-poll-docs-to-v5
isekovanic Nov 8, 2024
77980fa
chore: upgrade sample apps to RN 0.76.1 and added new arch docs (#2756)
khushal87 Nov 8, 2024
3efe254
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Nov 8, 2024
fd88bef
fix: poll offline fixes (#2772)
isekovanic Nov 13, 2024
5be800c
fix: revert cache revalidation and introduce dummy change in docs to …
isekovanic Nov 13, 2024
bf52846
fix: resolve lint issues once again
isekovanic Nov 13, 2024
684d659
fix: remove channel constants - isAdmin, isOwner and isModerator
khushal87 Nov 11, 2024
c252930
fix: offline mode channel hydration issues
isekovanic Nov 14, 2024
5ebda4f
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Nov 14, 2024
511c5f2
fix: remove channel constants - isAdmin, isOwner and isModerator (#2778)
khushal87 Nov 14, 2024
913ce07
Merge pull request #2779 from GetStream/fix/critical-v6-bugs
isekovanic Nov 14, 2024
a4c1105
fix: faulty build for sample apps
khushal87 Nov 14, 2024
4811497
Merge branch 'v6.0.0' of github.com:GetStream/stream-chat-react-nativ…
khushal87 Nov 14, 2024
5c03e20
Merge branch 'develop' into v6.0.0
isekovanic Nov 14, 2024
8875dbd
fix: update yarn.lock files to fix build
isekovanic Nov 14, 2024
d1c9755
fix: android modal size
isekovanic Nov 14, 2024
81507fb
Merge pull request #2783 from GetStream/fix/android-poll-creation-mod…
isekovanic Nov 14, 2024
eaecbf6
fix: race conditions on db open and close
isekovanic Nov 14, 2024
d353d32
fix: move dropTables into check as well
isekovanic Nov 14, 2024
32ab860
fix: crash in some instances of useIsChannelMuted hook invocation
isekovanic Nov 15, 2024
f8c7545
fix: properly use hook in channel preview
isekovanic Nov 15, 2024
bbf6a85
fix: edge cases and test
isekovanic Nov 15, 2024
f667148
Merge pull request #2786 from GetStream/fix/is-muted-hook-crash
isekovanic Nov 15, 2024
e029830
Merge pull request #2785 from GetStream/fix/db-open-close-issues
isekovanic Nov 15, 2024
99abac0
fix: regex state machine stack depth crash
isekovanic Nov 18, 2024
e847dca
fix: update test
isekovanic Nov 18, 2024
32115ca
Merge pull request #2789 from GetStream/fix/regex-max-stack-depth-crash
isekovanic Nov 18, 2024
b818b0f
fix: channel hook regressions
isekovanic Nov 19, 2024
fcf7001
Merge pull request #2792 from GetStream/fix/channel-hook-extraction-r…
isekovanic Nov 19, 2024
84f1468
fix: expo media library permissions race conditions
isekovanic Nov 19, 2024
5ba1784
Merge pull request #2793 from GetStream/fix/expo-media-permissions-race
isekovanic Nov 19, 2024
e900410
feat: enable moderation v2 on the sdk and sample apps
isekovanic Nov 19, 2024
2767234
fix: listen to correct channel read events
isekovanic Nov 19, 2024
ec3ebbd
Merge pull request #2795 from GetStream/fix/listen-to-correct-read-ev…
isekovanic Nov 19, 2024
6217d94
fix: add FlatList default for Expo
isekovanic Nov 19, 2024
9f3eb2a
Merge pull request #2798 from GetStream/fix/flat-list-export-expo
isekovanic Nov 20, 2024
6568ff8
Merge pull request #2794 from GetStream/feat/moderation-v2
isekovanic Nov 20, 2024
14e003f
feat: add support for membership customization
isekovanic Nov 20, 2024
d4dbb2b
Merge pull request #2800 from GetStream/feat/membership-customization…
isekovanic Nov 20, 2024
1db8637
fix: modify deployment workflow of SampleApp so that we get a release
isekovanic Nov 20, 2024
4883751
fix: try bumping firebase version
isekovanic Nov 20, 2024
b1fc71d
fix: revert FB changes and CODE_SIGN_STYLE regression
isekovanic Nov 20, 2024
af52e85
fix: PROVISIONING_PROFILE_SPECIFIER specific val
isekovanic Nov 20, 2024
ca4590a
fix: certificate distribution settings
isekovanic Nov 20, 2024
5a077bf
fix: upgrade bottom sheet and fix reanimated errors in new arch (#2806)
isekovanic Nov 21, 2024
7b414ca
fix: channel.state break on going to background
isekovanic Nov 22, 2024
6201f33
Merge pull request #2807 from GetStream/fix/channel-state-break-on-ba…
isekovanic Nov 22, 2024
dc7d09c
fix: expo media library exceptions in new arch
isekovanic Nov 25, 2024
44025e4
chore: resolve conflicts from develop on v6 (#2813)
khushal87 Nov 25, 2024
baa5360
fix: camera roll issues
isekovanic Nov 25, 2024
a6936e0
fix: refactor photo resolution to native level
isekovanic Nov 25, 2024
e30decf
fix: expo media library
isekovanic Nov 25, 2024
096dde1
fix: properly resolve videos too
isekovanic Nov 25, 2024
1d61f8b
chore: remove console.log
isekovanic Nov 25, 2024
a52b38b
chore: update yarn.lock files for example apps
khushal87 Nov 26, 2024
b469846
fix: bring back camera-roll to SampleApp
isekovanic Nov 26, 2024
7397107
fix: also podfile.lock
isekovanic Nov 26, 2024
1f1589b
Merge branch 'v6.0.0' into fix/asset-library-issues
isekovanic Nov 26, 2024
b1fadc0
fix: remove console.log
isekovanic Nov 26, 2024
72d7c7d
fix: issues with video preview
isekovanic Nov 26, 2024
45488c1
chore: remove console.log
isekovanic Nov 26, 2024
289331f
chore: resolve conflicts from develop
khushal87 Dec 3, 2024
ab21961
chore: resolve conflicts from develop
khushal87 Dec 3, 2024
dec67fc
feat: ai-bot integration poc (#2819)
isekovanic Dec 3, 2024
43be5ac
chore: upgrade expo sample app to expo 52
khushal87 Dec 5, 2024
bab78f4
fix: remove unnecessary android and ios permissions
khushal87 Dec 5, 2024
f310076
Merge pull request #2828 from GetStream/expo-52-sample-app-upgrade
isekovanic Dec 5, 2024
a1090cb
Merge pull request #2815 from GetStream/fix/asset-library-issues
isekovanic Dec 5, 2024
cb0b223
Merge branch 'develop' into v6.0.0
isekovanic Dec 5, 2024
de095b0
chore: update yarn.lock files
isekovanic Dec 5, 2024
9692f1a
refactor: remove stale subscriber count logic and types refactor (#2832)
khushal87 Dec 6, 2024
6975abe
feat: Message list pagination implementation using hasPrev and hasNex…
khushal87 Dec 6, 2024
f1977dd
fix: add theme for the bottom sheet styles and message user reactions…
khushal87 Dec 6, 2024
ab8f1a2
fix: refactor some of the buttons
isekovanic Dec 6, 2024
1fd1b69
fix: refactor context usage
isekovanic Dec 6, 2024
0907f29
fix: solve final cyclical dep
isekovanic Dec 6, 2024
7577f5c
fix: add corrected app.json
isekovanic Dec 6, 2024
cbf111e
fix: convert all poll buttons to pressables
isekovanic Dec 9, 2024
d3de92c
fix: lint issues (that somehow passed without issues before)
isekovanic Dec 9, 2024
ca873e5
chore: move add comment button to correct file
isekovanic Dec 9, 2024
3992fcc
fix: move vote button to correct file too
isekovanic Dec 9, 2024
b0fda59
Merge pull request #2834 from GetStream/fix/v6-poll-circular-requires
isekovanic Dec 9, 2024
9b2dd77
fix: image gallery issues (#2835)
isekovanic Dec 10, 2024
abbcdf8
fix: remove unnecessary logs
khushal87 Dec 10, 2024
875c6a4
fix: image gallery header and footer safe area view (#2840)
khushal87 Dec 11, 2024
82ec7d9
chore: remove disable if frozen channel (#2841)
isekovanic Dec 11, 2024
d5c3294
fix: old arch image resizer native module spec file name fix (#2842)
khushal87 Dec 11, 2024
21f18e5
Merge branch 'develop' into v6.0.0
isekovanic Dec 11, 2024
f3c3ee3
chore: fix all of the GH workflow stuff related to v6 in prep for rel…
isekovanic Dec 11, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: solve final cyclical dep
  • Loading branch information
isekovanic committed Dec 6, 2024
commit 0907f298a6b818b2c2b4bb54f1579c282c3f4d8e
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ import { FlatList, type FlatListProps, StyleSheet, Text, View } from 'react-nati

import { PollOption, PollVote as PollVoteClass } from 'stream-chat';

import { PollVote } from './PollResultItem';
import { PollVote } from './PollVote';

import {
PollContextProvider,
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import React, { useCallback, useMemo, useState } from 'react';
import React, { useCallback, useState } from 'react';
import { Modal, SafeAreaView, StyleSheet, Text, View } from 'react-native';

import { Poll, PollOption, PollVote as PollVoteClass, VotingVisibility } from 'stream-chat';
import { Poll, PollOption, PollVote as PollVoteClass } from 'stream-chat';

import { PollOptionFullResults } from './PollOptionFullResults';
import { PollVote } from './PollVote';

import {
useOwnCapabilitiesContext,
@@ -12,8 +13,6 @@ import {
useTranslationContext,
} from '../../../../contexts';
import type { DefaultStreamChatGenerics } from '../../../../types/types';
import { getDateString } from '../../../../utils/i18n/getDateString';
import { Avatar } from '../../../Avatar/Avatar';
import { MessageType } from '../../../MessageList/hooks/useMessageList';
import { usePollState } from '../../hooks/usePollState';
import { GenericPollButton } from '../Button';
@@ -86,51 +85,6 @@ export type PollResultItemProps<
option: PollOption<StreamChatGenerics>;
};

export const PollVote = ({ vote }: { vote: PollVoteClass }) => {
const { t, tDateTimeParser } = useTranslationContext();
const { votingVisibility } = usePollState();
const {
theme: {
colors: { black, text_low_emphasis },
poll: {
results: {
vote: { container, dateText, userName },
},
},
},
} = useTheme();

const dateString = useMemo(
() =>
getDateString({
date: vote.created_at,
t,
tDateTimeParser,
timestampTranslationKey: 'timestamp/PollVote',
}),
[vote.created_at, t, tDateTimeParser],
);

const isAnonymous = useMemo(
() => votingVisibility === VotingVisibility.anonymous,
[votingVisibility],
);

return (
<View style={[styles.voteContainer, container]}>
<View style={{ flexDirection: 'row' }}>
{!isAnonymous && vote.user?.image ? (
<Avatar image={vote.user.image as string} key={vote.id} size={20} />
) : null}
<Text style={[styles.voteUserName, { color: black }, userName]}>
{isAnonymous ? t<string>('Anonymous') : vote.user?.name}
</Text>
</View>
<Text style={[styles.voteDate, { color: text_low_emphasis }, dateText]}>{dateString}</Text>
</View>
);
};

const PollResultsVoteItem = (vote: PollVoteClass) => (
<PollVote key={`results_vote_${vote.id}`} vote={vote} />
);
@@ -177,13 +131,5 @@ const styles = StyleSheet.create({
},
headerContainer: { flexDirection: 'row', justifyContent: 'space-between' },
title: { flex: 1, fontSize: 16, fontWeight: '500' },
voteContainer: {
flexDirection: 'row',
justifyContent: 'space-between',
marginBottom: 8,
paddingVertical: 8,
},
voteCount: { fontSize: 16, marginLeft: 16 },
voteDate: { fontSize: 14 },
voteUserName: { fontSize: 14, marginLeft: 2 },
});
68 changes: 68 additions & 0 deletions package/src/components/Poll/components/PollResults/PollVote.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
import React, { useMemo } from 'react';

import { StyleSheet, Text, View } from 'react-native';

import { PollVote as PollVoteClass, VotingVisibility } from 'stream-chat';

import { useTheme, useTranslationContext } from '../../../../contexts';
import { getDateString } from '../../../../utils/i18n/getDateString';

import { Avatar } from '../../../Avatar/Avatar';
import { usePollState } from '../../hooks/usePollState';

export const PollVote = ({ vote }: { vote: PollVoteClass }) => {
const { t, tDateTimeParser } = useTranslationContext();
const { votingVisibility } = usePollState();
const {
theme: {
colors: { black, text_low_emphasis },
poll: {
results: {
vote: { container, dateText, userName },
},
},
},
} = useTheme();

const dateString = useMemo(
() =>
getDateString({
date: vote.created_at,
t,
tDateTimeParser,
timestampTranslationKey: 'timestamp/PollVote',
}),
[vote.created_at, t, tDateTimeParser],
);

const isAnonymous = useMemo(
() => votingVisibility === VotingVisibility.anonymous,
[votingVisibility],
);

return (
<View style={[styles.voteContainer, container]}>
<View style={{ flexDirection: 'row' }}>
{!isAnonymous && vote.user?.image ? (
<Avatar image={vote.user.image as string} key={vote.id} size={20} />
) : null}
<Text style={[styles.voteUserName, { color: black }, userName]}>
{isAnonymous ? t<string>('Anonymous') : vote.user?.name}
</Text>
</View>
<Text style={[styles.voteDate, { color: text_low_emphasis }, dateText]}>{dateString}</Text>
</View>
);
};

const styles = StyleSheet.create({
voteContainer: {
flexDirection: 'row',
justifyContent: 'space-between',
marginBottom: 8,
paddingVertical: 8,
},
voteCount: { fontSize: 16, marginLeft: 16 },
voteDate: { fontSize: 14 },
voteUserName: { fontSize: 14, marginLeft: 2 },
});