You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
935 B
33 lines
935 B
8 years ago
|
import React from 'react';
|
||
8 years ago
|
import ImmutablePropTypes from 'react-immutable-proptypes';
|
||
8 years ago
|
import UploadProgressContainer from '../containers/upload_progress_container';
|
||
7 years ago
|
import ImmutablePureComponent from 'react-immutable-pure-component';
|
||
|
import UploadContainer from '../containers/upload_container';
|
||
6 years ago
|
import SensitiveButtonContainer from '../containers/sensitive_button_container';
|
||
8 years ago
|
|
||
7 years ago
|
export default class UploadForm extends ImmutablePureComponent {
|
||
8 years ago
|
|
||
8 years ago
|
static propTypes = {
|
||
7 years ago
|
mediaIds: ImmutablePropTypes.list.isRequired,
|
||
8 years ago
|
};
|
||
|
|
||
8 years ago
|
render () {
|
||
7 years ago
|
const { mediaIds } = this.props;
|
||
8 years ago
|
|
||
|
return (
|
||
8 years ago
|
<div className='compose-form__upload-wrapper'>
|
||
2 years ago
|
<UploadProgressContainer />
|
||
7 years ago
|
|
||
|
<div className='compose-form__uploads-wrapper'>
|
||
|
{mediaIds.map(id => (
|
||
|
<UploadContainer id={id} key={id} />
|
||
|
))}
|
||
|
</div>
|
||
6 years ago
|
|
||
|
{!mediaIds.isEmpty() && <SensitiveButtonContainer />}
|
||
8 years ago
|
</div>
|
||
|
);
|
||
|
}
|
||
|
|
||
8 years ago
|
}
|