mass update
This commit is contained in:
parent
c0ee4f06d4
commit
5f8d09bcaf
@ -26,7 +26,7 @@
|
|||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "inferno-scripts build",
|
"build": "inferno-scripts build",
|
||||||
"dist": "npm run build && build",
|
"dist": "yarn run build && build",
|
||||||
"eject": "inferno-scripts eject",
|
"eject": "inferno-scripts eject",
|
||||||
"electron-start": "node src/electron/wait-inferno",
|
"electron-start": "node src/electron/wait-inferno",
|
||||||
"electron": "electron .",
|
"electron": "electron .",
|
||||||
|
@ -31,6 +31,12 @@ bs-container > * {
|
|||||||
padding: 0.5em 1em;
|
padding: 0.5em 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bs-card,
|
||||||
|
bs-card-deck,
|
||||||
|
bs-card-group,
|
||||||
|
bs-card-header,
|
||||||
|
bs-card-body,
|
||||||
|
bs-card-footer,
|
||||||
bs-form-feedback,
|
bs-form-feedback,
|
||||||
bs-form-group,
|
bs-form-group,
|
||||||
bs-jumbotron {
|
bs-jumbotron {
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import Alert from 'inferno-bootstrap/dist/Alert';
|
import BSAlert from 'inferno-bootstrap/dist/Alert';
|
||||||
import Badge from 'inferno-bootstrap/dist/Badge';
|
import Badge from 'inferno-bootstrap/dist/Badge';
|
||||||
import Breadcrumb from 'inferno-bootstrap/dist/Breadcrumb';
|
import Breadcrumb from 'inferno-bootstrap/dist/Breadcrumb';
|
||||||
import BreadcrumbItem from 'inferno-bootstrap/dist/BreadcrumbItem';
|
import BreadcrumbItem from 'inferno-bootstrap/dist/BreadcrumbItem';
|
||||||
@ -31,10 +31,10 @@ export const BSWrapper = (Component, tagName) => {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const Alert = BSWrapper(BSAlert, 'bs-alert');
|
||||||
export const Jumbotron = BSWrapper(BSJumbotron, 'bs-jumbotron');
|
export const Jumbotron = BSWrapper(BSJumbotron, 'bs-jumbotron');
|
||||||
|
|
||||||
export {
|
export {
|
||||||
Alert,
|
|
||||||
Badge,
|
Badge,
|
||||||
Breadcrumb,
|
Breadcrumb,
|
||||||
BreadcrumbItem,
|
BreadcrumbItem,
|
||||||
|
@ -1,27 +1,30 @@
|
|||||||
import Card from 'inferno-bootstrap/dist/Card/Card';
|
import BSCard from 'inferno-bootstrap/dist/Card/Card';
|
||||||
import CardBody from 'inferno-bootstrap/dist/Card/CardBody';
|
import BSCardBody from 'inferno-bootstrap/dist/Card/CardBody';
|
||||||
import CardColumns from 'inferno-bootstrap/dist/Card/CardColumns';
|
import BSCardColumns from 'inferno-bootstrap/dist/Card/CardColumns';
|
||||||
import CardDeck from 'inferno-bootstrap/dist/Card/CardDeck';
|
import BSCardDeck from 'inferno-bootstrap/dist/Card/CardDeck';
|
||||||
import CardFooter from 'inferno-bootstrap/dist/Card/CardFooter';
|
import BSCardFooter from 'inferno-bootstrap/dist/Card/CardFooter';
|
||||||
import CardGroup from 'inferno-bootstrap/dist/Card/CardGroup';
|
import BSCardGroup from 'inferno-bootstrap/dist/Card/CardGroup';
|
||||||
import CardHeader from 'inferno-bootstrap/dist/Card/CardHeader';
|
import BSCardHeader from 'inferno-bootstrap/dist/Card/CardHeader';
|
||||||
|
import BSCardImgOverlay from 'inferno-bootstrap/dist/Card/CardImgOverlay';
|
||||||
import CardImg from 'inferno-bootstrap/dist/Card/CardImg';
|
import CardImg from 'inferno-bootstrap/dist/Card/CardImg';
|
||||||
import CardImgOverlay from 'inferno-bootstrap/dist/Card/CardImgOverlay';
|
|
||||||
import CardLink from 'inferno-bootstrap/dist/Card/CardLink';
|
import CardLink from 'inferno-bootstrap/dist/Card/CardLink';
|
||||||
import CardSubtitle from 'inferno-bootstrap/dist/Card/CardSubtitle';
|
import CardSubtitle from 'inferno-bootstrap/dist/Card/CardSubtitle';
|
||||||
import CardText from 'inferno-bootstrap/dist/Card/CardText';
|
import CardText from 'inferno-bootstrap/dist/Card/CardText';
|
||||||
import CardTitle from 'inferno-bootstrap/dist/Card/CardTitle';
|
import CardTitle from 'inferno-bootstrap/dist/Card/CardTitle';
|
||||||
|
|
||||||
|
import { BSWrapper } from 'components/Bootstrap';
|
||||||
|
|
||||||
|
export const Card = BSWrapper(BSCard, 'bs-card');
|
||||||
|
export const CardBody = BSWrapper(BSCardBody, 'bs-card-body');
|
||||||
|
export const CardColumns = BSWrapper(BSCardColumns, 'bs-card-columns');
|
||||||
|
export const CardDeck = BSWrapper(BSCardDeck, 'bs-card-deck');
|
||||||
|
export const CardFooter = BSWrapper(BSCardFooter, 'bs-card-footer');
|
||||||
|
export const CardGroup = BSWrapper(BSCardGroup, 'bs-card-group');
|
||||||
|
export const CardHeader = BSWrapper(BSCardHeader, 'bs-card-header');
|
||||||
|
export const CardImgOverlay = BSWrapper(BSCardImgOverlay, 'bs-card-img-overlay');
|
||||||
|
|
||||||
export {
|
export {
|
||||||
Card,
|
|
||||||
CardBody,
|
|
||||||
CardColumns,
|
|
||||||
CardDeck,
|
|
||||||
CardFooter,
|
|
||||||
CardGroup,
|
|
||||||
CardHeader,
|
|
||||||
CardImg,
|
CardImg,
|
||||||
CardImgOverlay,
|
|
||||||
CardLink,
|
CardLink,
|
||||||
CardSubtitle,
|
CardSubtitle,
|
||||||
CardText,
|
CardText,
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
import { BSWrapper } from './Bootstrap';
|
|
||||||
import Button from 'inferno-bootstrap/dist/Button';
|
import Button from 'inferno-bootstrap/dist/Button';
|
||||||
import Form from 'inferno-bootstrap/dist/Form/Form';
|
import Form from 'inferno-bootstrap/dist/Form/Form';
|
||||||
import BSFormFeedback from 'inferno-bootstrap/dist/Form/FormFeedback';
|
import BSFormFeedback from 'inferno-bootstrap/dist/Form/FormFeedback';
|
||||||
@ -11,6 +10,8 @@ import InputGroupButtonDropdown from 'inferno-bootstrap/dist/Form/InputGroupButt
|
|||||||
import InputGroupText from 'inferno-bootstrap/dist/Form/InputGroupText';
|
import InputGroupText from 'inferno-bootstrap/dist/Form/InputGroupText';
|
||||||
import Label from 'inferno-bootstrap/dist/Form/Label';
|
import Label from 'inferno-bootstrap/dist/Form/Label';
|
||||||
|
|
||||||
|
import { BSWrapper } from 'components/Bootstrap';
|
||||||
|
|
||||||
export const FormFeedback = BSWrapper(BSFormFeedback, 'bs-form-feedback');
|
export const FormFeedback = BSWrapper(BSFormFeedback, 'bs-form-feedback');
|
||||||
export const FormGroup = BSWrapper(BSFormGroup, 'bs-form-group');
|
export const FormGroup = BSWrapper(BSFormGroup, 'bs-form-group');
|
||||||
|
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
import BSCol from 'inferno-bootstrap/dist/Col';
|
import BSCol from 'inferno-bootstrap/dist/Col';
|
||||||
import BSContainer from 'inferno-bootstrap/dist/Container';
|
import BSContainer from 'inferno-bootstrap/dist/Container';
|
||||||
import BSRow from 'inferno-bootstrap/dist/Row';
|
import BSRow from 'inferno-bootstrap/dist/Row';
|
||||||
|
|
||||||
import { BSWrapper } from './Bootstrap'
|
import { BSWrapper } from './Bootstrap'
|
||||||
|
|
||||||
export const Col = BSWrapper(BSCol, 'bs-col');
|
export const Col = BSWrapper(BSCol, 'bs-col');
|
||||||
|
@ -3,7 +3,7 @@ import {
|
|||||||
FormGroup,
|
FormGroup,
|
||||||
Input,
|
Input,
|
||||||
Label,
|
Label,
|
||||||
} from './Bootstrap';
|
} from 'components/Bootstrap';
|
||||||
|
|
||||||
export const FormBlock = ({
|
export const FormBlock = ({
|
||||||
children,
|
children,
|
||||||
@ -16,7 +16,7 @@ export const FormBlock = ({
|
|||||||
: <Input id={props.name} name={props.name} type={type} {...props} />;
|
: <Input id={props.name} name={props.name} type={type} {...props} />;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Col xs={12} sm={6} md={3}>
|
<Col xs={12} sm={6} md={3} className="d-flex align-items-baseline justify-content-around">
|
||||||
<FormGroup>
|
<FormGroup>
|
||||||
<Label for={props.name}>{label}</Label>
|
<Label for={props.name}>{label}</Label>
|
||||||
{formElement}
|
{formElement}
|
1
src/components/Form/index.js
Normal file
1
src/components/Form/index.js
Normal file
@ -0,0 +1 @@
|
|||||||
|
export * from './FormBlock';
|
@ -1,2 +1,2 @@
|
|||||||
export * from './Bootstrap';
|
export * from './Bootstrap';
|
||||||
export * from './FormBlock';
|
export * from './Form';
|
||||||
|
@ -1,67 +1,92 @@
|
|||||||
import { Component } from 'inferno';
|
import { linkEvent, Component } from 'inferno';
|
||||||
|
|
||||||
import {
|
import {
|
||||||
Button,
|
Button,
|
||||||
|
Card,
|
||||||
|
CardBody,
|
||||||
|
CardHeader,
|
||||||
|
CardFooter,
|
||||||
|
CardTitle,
|
||||||
Col,
|
Col,
|
||||||
Form,
|
Form,
|
||||||
Row,
|
Row,
|
||||||
} from '../../components/Bootstrap'
|
} from 'components/Bootstrap'
|
||||||
|
|
||||||
import { FormBlock } from '../../components';
|
import { FormBlock } from 'components/Form';
|
||||||
|
|
||||||
export class FilmAddView extends Component {
|
export class FilmAddView extends Component {
|
||||||
constructor (props) {
|
constructor (props) {
|
||||||
super (props);
|
super (props);
|
||||||
|
|
||||||
this.state = {
|
this.state = {
|
||||||
|
form: {
|
||||||
|
valid: {},
|
||||||
|
values: {},
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
handleFormChange (e) {
|
||||||
|
console.log(e);
|
||||||
|
}
|
||||||
|
|
||||||
render () {
|
render () {
|
||||||
return (
|
return (
|
||||||
<Form>
|
<Row className="full-height">
|
||||||
<Row>
|
<Col sm={12} md={8} lg={4} className="abs-center">
|
||||||
<FormBlock
|
<Form onChange={ linkEvent(this, this.handleFormChange) }>
|
||||||
label="Brand"
|
<Card>
|
||||||
name="brand"
|
<CardHeader>
|
||||||
required
|
<CardTitle>Add a Film</CardTitle>
|
||||||
/>
|
</CardHeader>
|
||||||
<FormBlock
|
<CardBody>
|
||||||
label="Film Name"
|
<Row className="align-items-baseline">
|
||||||
name="film-name"
|
<FormBlock
|
||||||
required
|
label="Brand"
|
||||||
/>
|
name="brand"
|
||||||
<FormBlock
|
required
|
||||||
label="Film Speed (ISO)"
|
/>
|
||||||
max="6400"
|
<FormBlock
|
||||||
name="film-speed-asa"
|
label="Film Name"
|
||||||
required
|
name="film-name"
|
||||||
type="number"
|
required
|
||||||
/>
|
/>
|
||||||
<FormBlock
|
<FormBlock
|
||||||
label="Film Speed (DIN)"
|
label="Film Speed (ISO)"
|
||||||
name="film-speed-din"
|
max="6400"
|
||||||
type="number"
|
name="film-speed-asa"
|
||||||
/>
|
required
|
||||||
<FormBlock
|
type="number"
|
||||||
label="Film Format"
|
/>
|
||||||
name="film-format"
|
<FormBlock
|
||||||
>
|
label="Film Speed (DIN)"
|
||||||
<select className="custom-select" id="film-format" name="film-format">
|
name="film-speed-din"
|
||||||
<option value="110">110</option>
|
type="number"
|
||||||
<option value="120">120</option>
|
/>
|
||||||
<option value="127">127</option>
|
<FormBlock
|
||||||
<option value="135">135</option>
|
label="Film Format"
|
||||||
</select>
|
name="film-format"
|
||||||
</FormBlock>
|
>
|
||||||
</Row>
|
<select className="custom-select" id="film-format" name="film-format">
|
||||||
<Row>
|
<option value="110">110</option>
|
||||||
<Col xs={12}>
|
<option value="120">120</option>
|
||||||
<Button color="primary" type="submit">Save</Button>
|
<option value="127">127</option>
|
||||||
</Col>
|
<option value="135">135</option>
|
||||||
</Row>
|
</select>
|
||||||
</Form>
|
</FormBlock>
|
||||||
|
</Row>
|
||||||
|
</CardBody>
|
||||||
|
<CardFooter>
|
||||||
|
<Row>
|
||||||
|
<Col xs={12}>
|
||||||
|
<Button color="primary" type="submit">Save</Button>
|
||||||
|
</Col>
|
||||||
|
</Row>
|
||||||
|
</CardFooter>
|
||||||
|
</Card>
|
||||||
|
</Form>
|
||||||
|
</Col>
|
||||||
|
</Row>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,7 +2,7 @@ import {
|
|||||||
Container,
|
Container,
|
||||||
Jumbotron,
|
Jumbotron,
|
||||||
Row,
|
Row,
|
||||||
} from '../components/Bootstrap';
|
} from 'components/Bootstrap';
|
||||||
|
|
||||||
function handleDrop (e) {
|
function handleDrop (e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Alert, Row } from '../components/Bootstrap';
|
import { Alert, Row } from 'components/Bootstrap';
|
||||||
|
|
||||||
export const OopsView = (props) => (
|
export const OopsView = (props) => (
|
||||||
<Row className="align-items-center justify-content-center full-height">
|
<Row className="align-items-center justify-content-center full-height">
|
||||||
|
Loading…
Reference in New Issue
Block a user