You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-09-06 05:26:44 +03:00
Set timezone publish at the device level to prevent all devices writing to the timezone field.
This commit is contained in:
@@ -143,7 +143,7 @@ export default class PreferencesUserSettingsTab extends React.Component<IProps,
|
|||||||
"MessageComposerInput.insertTrailingColon",
|
"MessageComposerInput.insertTrailingColon",
|
||||||
];
|
];
|
||||||
|
|
||||||
private static TIME_SETTINGS = ["showTwelveHourTimestamps", "alwaysShowTimestamps", "userTimezonePublish"];
|
private static TIME_SETTINGS = ["showTwelveHourTimestamps", "alwaysShowTimestamps"];
|
||||||
|
|
||||||
private static CODE_BLOCKS_SETTINGS = [
|
private static CODE_BLOCKS_SETTINGS = [
|
||||||
"enableSyntaxHighlightLanguageDetection",
|
"enableSyntaxHighlightLanguageDetection",
|
||||||
@@ -310,6 +310,7 @@ export default class PreferencesUserSettingsTab extends React.Component<IProps,
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{this.renderGroup(PreferencesUserSettingsTab.TIME_SETTINGS)}
|
{this.renderGroup(PreferencesUserSettingsTab.TIME_SETTINGS)}
|
||||||
|
<SettingsFlag name="userTimezonePublish" level={SettingLevel.DEVICE} />
|
||||||
</SettingsSubsection>
|
</SettingsSubsection>
|
||||||
|
|
||||||
<SettingsSubsection
|
<SettingsSubsection
|
||||||
|
@@ -656,7 +656,8 @@ export const SETTINGS: { [setting: string]: ISetting } = {
|
|||||||
default: "",
|
default: "",
|
||||||
},
|
},
|
||||||
"userTimezonePublish": {
|
"userTimezonePublish": {
|
||||||
supportedLevels: LEVELS_ACCOUNT_SETTINGS,
|
// This is per-device so you can avoid having devices overwrite each other.
|
||||||
|
supportedLevels: LEVELS_DEVICE_ONLY_SETTINGS,
|
||||||
displayName: _td("settings|preferences|publish_timezone"),
|
displayName: _td("settings|preferences|publish_timezone"),
|
||||||
default: false,
|
default: false,
|
||||||
controller: new ServerSupportUnstableFeatureController(
|
controller: new ServerSupportUnstableFeatureController(
|
||||||
|
Reference in New Issue
Block a user