misc_pterodactyl-panel/resources/scripts/components/server/users/AddSubuserButton.tsx

17 lines
495 B
TypeScript
Raw Normal View History

import React, { useState } from 'react';
import EditSubuserModal from '@/components/server/users/EditSubuserModal';
import { Button } from '@/components/elements/button/index';
export default () => {
const [ visible, setVisible ] = useState(false);
return (
<>
<EditSubuserModal visible={visible} onModalDismissed={() => setVisible(false)}/>
2020-07-04 23:26:07 +00:00
<Button onClick={() => setVisible(true)}>
New User
2020-07-04 23:26:07 +00:00
</Button>
</>
);
};