Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
5 changes: 5 additions & 0 deletions .changeset/add_command_for_msc4268_e2ee_history_sharing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
default: minor
---

added a `/sharehistory` command to [share encrypted history with a user](https://github.com/matrix-org/matrix-spec-proposals/blob/rav/proposal/encrypted_history_sharing/proposals/4268-encrypted-history-sharing.md)
2 changes: 2 additions & 0 deletions src/app/features/settings/experimental/Experimental.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { InfoCard } from '$components/info-card';
import { LanguageSpecificPronouns } from '../cosmetics/LanguageSpecificPronouns';
import { Sync } from '../general';
import { BandwidthSavingEmojis } from './BandwithSavingEmojis';
import { MSC4268HistoryShare } from './MSC4268HistoryShare';

type ExperimentalProps = {
requestClose: () => void;
Expand Down Expand Up @@ -43,6 +44,7 @@ export function Experimental({ requestClose }: ExperimentalProps) {
<br />
<Box direction="Column" gap="700">
<Sync />
<MSC4268HistoryShare />
<LanguageSpecificPronouns />
<BandwidthSavingEmojis />
</Box>
Expand Down
42 changes: 42 additions & 0 deletions src/app/features/settings/experimental/MSC4268HistoryShare.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
import { SequenceCard } from '$components/sequence-card';
import { SettingTile } from '$components/setting-tile';
import { useSetting } from '$state/hooks/settings';
import { settingsAtom } from '$state/settings';
import { Box, Switch, Text } from 'folds';
import { SequenceCardStyle } from '../styles.css';

export function MSC4268HistoryShare() {
const [enabledMSC4268Command, setEnabledMSC4268Command] = useSetting(
settingsAtom,
'enableMSC4268CMD'
);

return (
<Box direction="Column" gap="100">
<Text size="L400">Enable Sharing of Encrypted History</Text>
<SequenceCard
className={SequenceCardStyle}
variant="SurfaceVariant"
direction="Column"
gap="100"
>
<SettingTile
title="Enable the /sharehistory command"
description="If enabled, this command will allow users to share encrypted history with other newly joined users, as per MSC4268."
after={
<Switch
variant="Primary"
value={enabledMSC4268Command}
onChange={setEnabledMSC4268Command}
title={
enabledMSC4268Command
? 'Disable /sharehistory command'
: 'Enable /sharehistory command'
}
/>
}
/>
</SequenceCard>
</Box>
);
}
Loading
Loading