import { DialogContentText } from '@material-ui/core';
import { TextField } from '~/components/text-field/text-field';
import { RENAME_FILE_DIALOG, RenameFileDialogData, renameFile } from '~/store/collection-panel/collection-panel-files/collection-panel-files-actions';
-import { WarningIcon } from "~/components/icon/icon";
+import { WarningCollection } from '~/components/warning-collection/warning-collection';
export const RenameFileDialog = compose(
withDialog(RENAME_FILE_DIALOG),
<Field
name='name'
component={TextField}
+ autoFocus={true}
/>
- <span style={{ display: 'flex', alignItems: 'center' }}>
- <WarningIcon />
- <DialogContentText style={{ paddingLeft: '8px' }}>Renaming a file will change content adress.</DialogContentText>
- </span>
-
+ <WarningCollection text="Renaming a file will change content adress." />
</>;