Advertisement
Guest User

Untitled

a guest
Mar 18th, 2019
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.44 KB | None | 0 0
  1. import React, { Component } from 'react';
  2. import './index.scss';
  3.  
  4. class Images extends Component {
  5. render() {
  6. return (
  7. <div>
  8. <div className="row">
  9. <div className="col-sm-6">
  10. <label>-{this.props.index + 1}{'.1'}- Title</label>
  11. </div>
  12. <div className="col-sm-6">
  13. <input type="text" name="title" value={this.props.item.title} onChange={this.props.onChange.bind(this, this.props.index)} />
  14. </div>
  15. </div>
  16. <div className="row">
  17. <div className="col-sm-6">
  18. <label>-{this.props.index + 1}{'.2'}- URL</label>
  19. </div>
  20. <div className="col-sm-6">
  21. <input type="text" name="url" value={this.props.item.url} onChange={this.props.onChange.bind(this, this.props.index)} />
  22. </div>
  23. </div>
  24. <div className="row">
  25. <div>
  26. <button type="button" onClick={() => this.props.onClickRemove(this.props.index)} className="btn btn-secondary btn-sm btn-danger">Remove Image</button>
  27. </div>
  28. </div>
  29. <div>
  30. &nbsp;
  31. </div>
  32. </div>
  33. );
  34. }
  35. }
  36.  
  37. export default Images;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement