Implement events for external use + Rename interfaces with a I prefix + add some documentation (#26)
All checks were successful
continuous-integration/drone/push Build is passing

Implement events for external use
Rename interfaces with a I prefix
Add some documentation

Co-authored-by: Eric NGUYEN <enguyen@techform.fr>
Reviewed-on: https://git.siklos-chaneru.duckdns.org/Siklos/svg-layout-designer-react/pulls/26
This commit is contained in:
Siklos 2022-08-12 06:36:14 -04:00
parent 6c601429b9
commit c81a6fe44b
38 changed files with 228 additions and 116 deletions

View file

@ -1,8 +1,8 @@
import { Dispatch, SetStateAction } from 'react';
import { Configuration } from '../../Interfaces/Configuration';
import { ContainerModel } from '../../Interfaces/ContainerModel';
import { IConfiguration } from '../../Interfaces/IConfiguration';
import { ContainerModel } from '../../Interfaces/IContainerModel';
import { fetchConfiguration } from '../API/api';
import { IEditorState } from '../Editor/Editor';
import { IEditorState } from "../../Interfaces/IEditorState";
import { LoadState } from './Load';
export function NewEditor(
@ -11,7 +11,7 @@ export function NewEditor(
): void {
// Fetch the configuration from the API
fetchConfiguration()
.then((configuration: Configuration) => {
.then((configuration: IConfiguration) => {
// Set the main container from the given properties of the API
const MainContainer = new ContainerModel(
null,