From 953d7f7791282731de6b944a8cec38c4faeb2484 Mon Sep 17 00:00:00 2001 From: Shruthi Rai Date: Fri, 17 Dec 2021 11:43:28 +0100 Subject: [PATCH] fix: interface loader issue --- react-app/src/component/ColorTableTypes.ts | 2 +- react-app/src/component/Legend/ContinuousLegend.tsx | 4 ++-- react-app/src/component/Legend/DiscreteLegend.tsx | 4 ++-- react-app/src/component/Utils/discreteLegend.ts | 2 +- react-app/src/component/WelllayerTemplateTypes.ts | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/react-app/src/component/ColorTableTypes.ts b/react-app/src/component/ColorTableTypes.ts index 82fbe49d..078c8a60 100644 --- a/react-app/src/component/ColorTableTypes.ts +++ b/react-app/src/component/ColorTableTypes.ts @@ -1,4 +1,4 @@ -export interface colorTablesObj { +export declare type colorTablesObj = { name: string; description: string; colors: [number, number, number, number][]; diff --git a/react-app/src/component/Legend/ContinuousLegend.tsx b/react-app/src/component/Legend/ContinuousLegend.tsx index d72aac04..16b74583 100644 --- a/react-app/src/component/Legend/ContinuousLegend.tsx +++ b/react-app/src/component/Legend/ContinuousLegend.tsx @@ -4,7 +4,7 @@ import { select, scaleLinear, scaleSequential, axisBottom } from "d3"; import { templateArray } from "../WelllayerTemplateTypes"; import { colorTablesArray } from "../ColorTableTypes"; -interface legendProps { +declare type legendProps = { min: number; max: number; dataObjectName: string; @@ -15,7 +15,7 @@ interface legendProps { horizontal: boolean; } -interface ItemColor { +declare type ItemColor = { color: string; offset: number; } diff --git a/react-app/src/component/Legend/DiscreteLegend.tsx b/react-app/src/component/Legend/DiscreteLegend.tsx index e3157053..8cffcad4 100644 --- a/react-app/src/component/Legend/DiscreteLegend.tsx +++ b/react-app/src/component/Legend/DiscreteLegend.tsx @@ -4,11 +4,11 @@ import { scaleOrdinal, select } from "d3"; import { templateArray, propertiesObj } from "../WelllayerTemplateTypes"; import { colorTablesArray, colorTablesObj } from "../ColorTableTypes"; -interface ItemColor { +declare type ItemColor = { color: string; } -interface colorLegendProps { +declare type colorLegendProps = { discreteData: { objects: Record }; dataObjectName: string; name: string; diff --git a/react-app/src/component/Utils/discreteLegend.ts b/react-app/src/component/Utils/discreteLegend.ts index ca1f960e..cd4b794c 100644 --- a/react-app/src/component/Utils/discreteLegend.ts +++ b/react-app/src/component/Utils/discreteLegend.ts @@ -1,4 +1,4 @@ -interface ItemColor { +declare type ItemColor = { color: string; } diff --git a/react-app/src/component/WelllayerTemplateTypes.ts b/react-app/src/component/WelllayerTemplateTypes.ts index 6c148ed0..45c75f3a 100644 --- a/react-app/src/component/WelllayerTemplateTypes.ts +++ b/react-app/src/component/WelllayerTemplateTypes.ts @@ -1,4 +1,4 @@ -export interface propertiesObj { +export declare type propertiesObj = { objectName: string; colorTable: string; context: string; @@ -7,7 +7,7 @@ export interface propertiesObj { type propertiesArr = Array; -interface template { +declare type template = { name: string; properties: propertiesArr; }