RC-7: remove useless files

This commit is contained in:
2023-08-06 15:27:12 +01:00
parent d944147a77
commit 3c3ec7da11
4 changed files with 5 additions and 49 deletions

View File

@@ -1,39 +0,0 @@
import { forwardRef, useState } from 'react';
import { styled } from '@mui/material/styles';
import { convertToRaw, EditorState } from 'draft-js';
import { Editor } from 'react-draft-wysiwyg';
import draftToHtml from 'draftjs-to-html';
import 'react-draft-wysiwyg/dist/react-draft-wysiwyg.css';
import clsx from 'clsx';
const Root = styled('div')({
'& .rdw-dropdown-selectedtext': {
color: 'inherit',
},
'& .rdw-editor-toolbar': {
borderWidth: '0 0 1px 0!important',
margin: '0!important',
},
'& .rdw-editor-main': {
padding: '8px 12px',
height: `${256}px!important`,
},
});
const WYSIWYGEditor = forwardRef((props, ref) => {
const [editorState, setEditorState] = useState(EditorState.createEmpty());
function onEditorStateChange(_editorState) {
setEditorState(_editorState);
return props.onChange(draftToHtml(convertToRaw(_editorState.getCurrentContent())));
}
return (
<Root className={clsx('rounded-4 border-1 overflow-hidden w-full', props.className)} ref={ref}>
<Editor editorState={editorState} onEditorStateChange={onEditorStateChange} />
</Root>
);
});
export default WYSIWYGEditor;

View File

@@ -1,3 +0,0 @@
const linksConfigLayout2 = ['rent-and-buy', 'about-us', 'blog', 'contacts'];
export default linksConfigLayout2;

View File

@@ -1,5 +0,0 @@
const en = {
translation: {},
};
export default en;

View File

@@ -1,9 +1,12 @@
import i18n from 'i18next';
import { initReactI18next } from 'react-i18next';
import en from './assets/locales/en';
// the translations
// (tip move them in a JSON file and import them)
const resources = {
en,
en: {
translation: {},
},
};
i18n