Merge pull request #3232 from matrix-org/jryans/v1.4.0/enable-reactions-edits-default

Enable reactions and edits by default
This commit is contained in:
J. Ryan Stinnett 2019-07-17 15:19:08 +01:00 committed by GitHub
commit 88a0dbe2f1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 3 deletions

View file

@ -118,13 +118,13 @@ export const SETTINGS = {
isFeature: true, isFeature: true,
displayName: _td("Edit messages after they have been sent (refresh to apply changes)"), displayName: _td("Edit messages after they have been sent (refresh to apply changes)"),
supportedLevels: LEVELS_FEATURE, supportedLevels: LEVELS_FEATURE,
default: false, default: true,
}, },
"feature_reactions": { "feature_reactions": {
isFeature: true, isFeature: true,
displayName: _td("React to messages with emoji (refresh to apply changes)"), displayName: _td("React to messages with emoji (refresh to apply changes)"),
supportedLevels: LEVELS_FEATURE, supportedLevels: LEVELS_FEATURE,
default: false, default: true,
}, },
"MessageComposerInput.suggestEmoji": { "MessageComposerInput.suggestEmoji": {
supportedLevels: LEVELS_ACCOUNT_SETTINGS, supportedLevels: LEVELS_ACCOUNT_SETTINGS,

View file

@ -122,7 +122,10 @@ export default class DeviceSettingsHandler extends SettingsHandler {
} }
const value = localStorage.getItem("mx_labs_feature_" + featureName); const value = localStorage.getItem("mx_labs_feature_" + featureName);
return value === "true"; if (value === "true") return true;
if (value === "false") return false;
// Try to read the next config level for the feature.
return null;
} }
_writeFeature(featureName, enabled) { _writeFeature(featureName, enabled) {