Skip to content

Instantly share code, notes, and snippets.

View grantglidewell's full-sized avatar

Grant Glidewell grantglidewell

View GitHub Profile
export class SelectGuide extends Component {
state = {
value: 'Initial message',
text: 'Initial'
}
render() {
return (
<React.Fragment>
<p>
The Select component requires that you also import the Option
Usage:
<Input name="name" placeholder="Name" disabled />
<Input
name="name"
autoComplete="off"
placeholder="Name (autocomplete disabled)"
/>
Usage:
<React.Fragment>
<p>Mouseover for more information</p>
<Infotip title="This is the Infotip title" />
</React.Fragment>
Code:
export function Infotip(props) {
export class TextFieldType extends Component {
constructor(props) {
super(props);
this.state = {
textInput: ""
};
}
render() {
const { textInput } = this.state;
return (
export class TextareaFieldType extends Component {
constructor(props) {
super(props)
this.state = {
textInput: ''
}
}
render() {
const { textInput } = this.state
return (
export class NumberFieldType extends Component {
constructor(props) {
super(props);
this.state = {
numberInput: ""
};
}
render() {
const { numberInput } = this.state;
export class UrlFieldType extends Component {
constructor(props) {
super(props)
this.state = {
textInput: ''
}
}
render() {
const { textInput } = this.state
return (
<CollapsibleCard header="Collapse Me" footer="this is a footer">
<p>This is the body</p>
</CollapsibleCard>
<CollapsibleCard header="Default Collapsed" collapsed >
<h3>A whole component! look at that!</h3>
<GithubEmbed />
</CollapsibleCard>
export class CollapsibleCard extends Component {
static defaultProps = {
isCollapsed: false,
header: 'Header Required',
body: 'body required',
footer: ''
}
state = {
isCollapsed: false
}
<Button type="" text="Button" />
<Button type="save" text="Save" />
<Button type="cancel" text="Cancel" />
<Button type="warn" text="Warn" />
<Button type="alt" text="Alt" />