MCPcopy Create free account
hub / github.com/MiniMax-AI/OpenRoom / handleAdd

Function handleAdd

apps/webuiapps/src/components/ChatPanel/CharacterPanel.tsx:39–51  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

37 };
38
39 const handleAdd = () => {
40 const id = generateCharacterId();
41 const newChar: CharacterConfig = {
42 id,
43 character_name: 'New Character',
44 character_gender_desc: '',
45 character_desc: '',
46 character_emotion_list: [...CHARACTER_EMOTION_LIST],
47 character_meta_info: { base_image_url: '' },
48 };
49 setCol({ ...col, items: { ...col.items, [id]: newChar } });
50 setEditingId(id);
51 };
52
53 const handleSave = () => {
54 onSave(col);

Callers

nothing calls this directly

Calls 1

generateCharacterIdFunction · 0.90

Tested by

no test coverage detected