ens-usernames/app/components/ensSubManagement.js

45 lines
1.5 KiB
JavaScript
Raw Normal View History

import EmbarkJS from 'Embark/EmbarkJS';
2018-05-23 18:45:29 +00:00
import ENSRegistry from 'Embark/contracts/ENSRegistry';
import UsernameRegistrar from 'Embark/contracts/UsernameRegistrar';
import TestToken from 'Embark/contracts/TestToken';
import React, { Fragment } from 'react';
import { Form, FormGroup, FormControl, HelpBlock, Button, ControlLabel } from 'react-bootstrap';
2018-05-27 20:28:07 +00:00
import AddDomain from './ens/addDomain';
import MoveDomain from './ens/moveDomain';
2018-05-27 20:28:07 +00:00
import RegisterSubDomain from './ens/registerSubDomain';
import TokenPermissions from './standard/TokenPermission';
2018-05-27 20:28:07 +00:00
import SetupENS from './ens/setupENS';
2018-08-08 20:54:18 +00:00
import UpdateController from './ens/updateController';
const FieldGroup = ({ id, label, help, ...props }) => (
<FormGroup controlId={id}>
<ControlLabel>{label}</ControlLabel>
<FormControl {...props} />
{help && <HelpBlock>{help}</HelpBlock>}
</FormGroup>
)
2018-08-08 20:54:18 +00:00
const ENSSubManagement = props => (
<Fragment>
2018-08-08 20:54:18 +00:00
<h2 style={{ textAlign: 'center' }}>Subdomain Management</h2>
<h3>Change Registry Controller</h3>
<UpdateController />
<h3>Activate Registry/Update Registry Price</h3>
2018-05-22 19:44:33 +00:00
<AddDomain />
<h3>Move Domain To Another Registry</h3>
<MoveDomain />
2018-05-23 18:45:29 +00:00
<hr/>
2018-05-27 20:28:07 +00:00
<h3>Register Sub-Domain</h3>
<RegisterSubDomain />
<hr/>
<TokenPermissions
symbol='SNT'
spender={UsernameRegistrar._address}
methods={TestToken.methods} />
<hr/>
2018-05-23 18:45:29 +00:00
<SetupENS ENSRegistry={ENSRegistry} />
</Fragment>
)
2018-05-27 20:28:07 +00:00
export default ENSSubManagement;