2016-07-16 02:06:10 +00:00
|
|
|
import React from 'react';
|
2016-07-07 20:10:55 +00:00
|
|
|
import {Tab, Tabs, TabList, TabPanel} from 'react-tabs'
|
2016-07-16 02:06:10 +00:00
|
|
|
import {shell} from 'electron';
|
2016-05-07 17:29:24 +00:00
|
|
|
|
2016-07-16 02:06:10 +00:00
|
|
|
import Link from './base/Link';
|
|
|
|
import Modal from './base/Modal';
|
|
|
|
import ModalBody from './base/ModalBody';
|
|
|
|
import ModalHeader from './base/ModalHeader';
|
|
|
|
import ModalFooter from './base/ModalFooter';
|
|
|
|
import ModalComponent from './lib/ModalComponent';
|
|
|
|
import {MASHAPE_URL} from '../lib/constants';
|
|
|
|
import {getVersion} from '../lib/appInfo';
|
2016-05-07 17:29:24 +00:00
|
|
|
|
2016-07-14 22:48:56 +00:00
|
|
|
class SettingsModal extends ModalComponent {
|
2016-07-07 20:10:55 +00:00
|
|
|
render () {
|
2016-05-07 17:29:24 +00:00
|
|
|
return (
|
2016-07-07 20:10:55 +00:00
|
|
|
<Modal ref="modal" tall={true} {...this.props}>
|
|
|
|
<ModalHeader>Insomnia Settings</ModalHeader>
|
|
|
|
<ModalBody>
|
|
|
|
<Tabs>
|
|
|
|
<TabList>
|
|
|
|
<Tab>
|
|
|
|
<button>General</button>
|
|
|
|
</Tab>
|
|
|
|
<Tab>
|
|
|
|
<button>Import/Export</button>
|
|
|
|
</Tab>
|
|
|
|
<Tab>
|
|
|
|
<button>Editor</button>
|
|
|
|
</Tab>
|
|
|
|
<Tab>
|
|
|
|
<button>Hotkeys</button>
|
|
|
|
</Tab>
|
|
|
|
<Tab>
|
|
|
|
<button>About v{getVersion()}</button>
|
|
|
|
</Tab>
|
|
|
|
</TabList>
|
|
|
|
<TabPanel className="pad">
|
|
|
|
<div>
|
|
|
|
<input id="setting-show-passwords" type="checkbox"/>
|
|
|
|
<label htmlFor="setting-show-passwords">
|
|
|
|
Show HTTP authentication passwords in plain-text
|
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
<div className="pad-top">
|
|
|
|
<input id="setting-bulk-header-edit" type="checkbox"/>
|
|
|
|
<label htmlFor="setting-bulk-header-edit">
|
|
|
|
Use bulk header editor by default
|
|
|
|
</label>
|
|
|
|
</div>
|
2016-07-07 22:06:18 +00:00
|
|
|
<div className="pad-top">
|
|
|
|
<input id="setting-follow-redirects" type="checkbox"/>
|
|
|
|
<label htmlFor="setting-follow-redirects">
|
|
|
|
Follow Redirects
|
|
|
|
</label>
|
|
|
|
</div>
|
2016-07-07 20:10:55 +00:00
|
|
|
<div>
|
|
|
|
<label htmlFor="setting-request-timeout" className="pad-top">
|
|
|
|
Request Timeout (milliseconds)
|
|
|
|
</label>
|
|
|
|
<div className="form-control form-control--outlined no-marg">
|
|
|
|
<input id="setting-request-timeout" type="text" defaultValue={30000}/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<br/>
|
|
|
|
</TabPanel>
|
|
|
|
<TabPanel className="pad">
|
|
|
|
Import/Export
|
|
|
|
</TabPanel>
|
|
|
|
<TabPanel className="pad">
|
|
|
|
Editor
|
|
|
|
</TabPanel>
|
|
|
|
<TabPanel className="pad">
|
|
|
|
Keyboard
|
|
|
|
</TabPanel>
|
|
|
|
<TabPanel className="pad">
|
|
|
|
<p>
|
|
|
|
<Link href="http://insomnia.rest">Insomnia</Link> is made with love by me,
|
|
|
|
<Link href="http://schier.co">Gregory Schier</Link>.
|
|
|
|
</p>
|
|
|
|
<p>
|
|
|
|
You can help me out by sending your feedback to
|
|
|
|
<Link href="mailto:greg@schier.co">greg@schier.co</Link> or tweet
|
|
|
|
<Link href="https://twitter.com/GetInsomnia">@GetInsomnia</Link>.
|
|
|
|
</p>
|
|
|
|
<p>Thanks!</p>
|
|
|
|
<br/>
|
|
|
|
<p>~Gregory</p>
|
|
|
|
</TabPanel>
|
|
|
|
</Tabs>
|
2016-05-07 17:29:24 +00:00
|
|
|
</ModalBody>
|
2016-07-07 20:10:55 +00:00
|
|
|
<ModalFooter className="pad text-right">
|
|
|
|
<div className="relative">
|
|
|
|
Supported By
|
|
|
|
<Link href={MASHAPE_URL}>
|
|
|
|
<img src="images/mashape.png" style={{height: '1.5em'}} className="valign-bottom"/>
|
|
|
|
</Link>
|
|
|
|
</div>
|
|
|
|
</ModalFooter>
|
2016-05-07 17:29:24 +00:00
|
|
|
</Modal>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-07-06 20:18:26 +00:00
|
|
|
SettingsModal.propTypes = {};
|
2016-05-07 17:29:24 +00:00
|
|
|
|
|
|
|
export default SettingsModal;
|