-
Notifications
You must be signed in to change notification settings - Fork 440
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add: clown mimic voice menu[bounty] (#5512)
* almost * final * ue * bundle * bundle * forgotten * zwei talking * Update code/game/jobs/job/support.dm Co-authored-by: Zwei <[email protected]> --------- Co-authored-by: Zwei <[email protected]> Co-authored-by: Aziz Chynaliev <[email protected]>
- Loading branch information
1 parent
9e4427f
commit a5521e4
Showing
6 changed files
with
179 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
import { useBackend } from '../backend'; | ||
import { Box, Button, Section, Stack } from '../components'; | ||
import { Window } from '../layouts'; | ||
|
||
export const Mimicking = (props, context) => { | ||
const { act, data } = useBackend(context); | ||
const slots = data.slots || []; | ||
|
||
return ( | ||
<Window width={400} height={300}> | ||
<Window.Content scrollable> | ||
<Stack vertical fill> | ||
<Section fill scrollable> | ||
{slots.map((voice) => ( | ||
<Section | ||
mb={0.5} | ||
title={voice.name} | ||
key={voice.id} | ||
level={2} | ||
buttons={ | ||
<> | ||
<Button | ||
content="Choose" | ||
selected={voice.selected} | ||
onClick={() => act('Choose', { 'id': voice.id })} | ||
/> | ||
<Button | ||
content="Delete" | ||
color="bad" | ||
onClick={() => act('Delete', { 'id': voice.id })} | ||
/> | ||
</> | ||
} | ||
> | ||
<Box preserveWhitespace textColor="#878787" fontSize="14px"> | ||
Voice: {voice.voice} | ||
</Box> | ||
</Section> | ||
))} | ||
<Button fluid content="Add" onClick={() => act('Add')} /> | ||
</Section> | ||
</Stack> | ||
</Window.Content> | ||
</Window> | ||
); | ||
}; |
Large diffs are not rendered by default.
Oops, something went wrong.