2017-05-02 20:04:16 -04:00
|
|
|
import React from 'react';
|
2016-11-13 13:08:52 -05:00
|
|
|
import ImmutablePropTypes from 'react-immutable-proptypes';
|
2017-03-23 22:50:30 -04:00
|
|
|
import UploadProgressContainer from '../containers/upload_progress_container';
|
2017-09-28 09:31:31 -04:00
|
|
|
import ImmutablePureComponent from 'react-immutable-pure-component';
|
|
|
|
import UploadContainer from '../containers/upload_container';
|
2016-11-18 09:36:16 -05:00
|
|
|
|
2017-09-28 09:31:31 -04:00
|
|
|
export default class UploadForm extends ImmutablePureComponent {
|
2016-11-13 13:08:52 -05:00
|
|
|
|
2017-05-12 08:44:10 -04:00
|
|
|
static propTypes = {
|
2017-09-28 09:31:31 -04:00
|
|
|
mediaIds: ImmutablePropTypes.list.isRequired,
|
2017-05-12 08:44:10 -04:00
|
|
|
};
|
|
|
|
|
2016-11-13 13:08:52 -05:00
|
|
|
render () {
|
2017-09-28 09:31:31 -04:00
|
|
|
const { mediaIds } = this.props;
|
2016-11-13 13:08:52 -05:00
|
|
|
|
|
|
|
return (
|
2017-04-22 22:26:55 -04:00
|
|
|
<div className='compose-form__upload-wrapper'>
|
2017-03-23 22:50:30 -04:00
|
|
|
<UploadProgressContainer />
|
2017-09-28 09:31:31 -04:00
|
|
|
|
|
|
|
<div className='compose-form__uploads-wrapper'>
|
|
|
|
{mediaIds.map(id => (
|
|
|
|
<UploadContainer id={id} key={id} />
|
|
|
|
))}
|
|
|
|
</div>
|
2016-11-13 13:08:52 -05:00
|
|
|
</div>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
2017-04-21 14:05:35 -04:00
|
|
|
}
|