You've already forked matrix-react-sdk
							
							
				mirror of
				https://github.com/matrix-org/matrix-react-sdk.git
				synced 2025-11-04 11:51:45 +03:00 
			
		
		
		
	Extensibility, TypeScript and lazy loading
This commit is contained in:
		@@ -77,6 +77,7 @@ export const CommandCategories = {
 | 
			
		||||
    "actions": _td("Actions"),
 | 
			
		||||
    "admin": _td("Admin"),
 | 
			
		||||
    "advanced": _td("Advanced"),
 | 
			
		||||
    "effects": _td("Effects"),
 | 
			
		||||
    "other": _td("Other"),
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
@@ -1045,19 +1046,16 @@ export const Commands = [
 | 
			
		||||
        args: '<message>',
 | 
			
		||||
        runFn: function(roomId, args) {
 | 
			
		||||
            return success((async () => {
 | 
			
		||||
                const isChatEffectsDisabled = SettingsStore.getValue('dontShowChatEffects');
 | 
			
		||||
                if ((!args) || (!args && isChatEffectsDisabled)) {
 | 
			
		||||
                if (!args) {
 | 
			
		||||
                    args = _t("sends confetti");
 | 
			
		||||
                    MatrixClientPeg.get().sendEmoteMessage(roomId, args);
 | 
			
		||||
                } else {
 | 
			
		||||
                    MatrixClientPeg.get().sendTextMessage(roomId, args);
 | 
			
		||||
                }
 | 
			
		||||
                if (!isChatEffectsDisabled) {
 | 
			
		||||
                    dis.dispatch({action: 'confetti'});
 | 
			
		||||
                }
 | 
			
		||||
                dis.dispatch({action: 'effects.confetti'});
 | 
			
		||||
            })());
 | 
			
		||||
        },
 | 
			
		||||
        category: CommandCategories.actions,
 | 
			
		||||
        category: CommandCategories.effects,
 | 
			
		||||
    }),
 | 
			
		||||
 | 
			
		||||
    // Command definitions for autocompletion ONLY:
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user