mirror of
				https://github.com/superseriousbusiness/gotosocial.git
				synced 2025-10-31 06:52:26 -05:00 
			
		
		
		
	[frogend] Emoji categories (#1051)
* emoji category combobox * emoji categorizing * dropdown entry separation * emoji filtering/sorting * add some explaining comments * remove unneeded default-value code * remove wrongly created package.json * configurable ComboBox label+placeHolder
This commit is contained in:
		
					parent
					
						
							
								940abc279c
							
						
					
				
			
			
				commit
				
					
						aa5c4e065c
					
				
			
		
					 10 changed files with 249 additions and 35 deletions
				
			
		|  | @ -20,7 +20,6 @@ | |||
| 
 | ||||
| const { createSlice } = require("@reduxjs/toolkit"); | ||||
| const d = require("dotty"); | ||||
| const defaultValue = require("default-value"); | ||||
| 
 | ||||
| module.exports = createSlice({ | ||||
| 	name: "user", | ||||
|  | @ -30,10 +29,10 @@ module.exports = createSlice({ | |||
| 	}, | ||||
| 	reducers: { | ||||
| 		setAccount: (state, { payload }) => { | ||||
| 			payload.source = defaultValue(payload.source, {}); | ||||
| 			payload.source.language = defaultValue(payload.source.language.toUpperCase(), "EN"); | ||||
| 			payload.source.status_format = defaultValue(payload.source.status_format, "plain"); | ||||
| 			payload.source.sensitive = defaultValue(payload.source.sensitive, false); | ||||
| 			payload.source = payload.source ?? {}; | ||||
| 			payload.source.language = payload.source.language.toUpperCase() ?? "EN"; | ||||
| 			payload.source.status_format = payload.source.status_format ?? "plain"; | ||||
| 			payload.source.sensitive = payload.source.sensitive ?? false; | ||||
| 
 | ||||
| 			state.profile = payload; | ||||
| 			// /user/settings only needs a copy of the 'source' obj
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue