back-testing-react 2.1.0 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "back-testing-react",
3
- "version": "2.1.0",
3
+ "version": "2.1.2",
4
4
  "type": "module",
5
5
  "description": "Parametric back testing application developed by NormanMax Insurance Solutions",
6
6
  "main": "dist/index.js",
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
 
3
- import { MediaType, Payout, PayoutWizardStepType, RadioChoice, WizardStep } from "../step.types";
3
+ import { MediaType, PayoutWizardStepType, RadioChoice, WizardStep } from "../step.types";
4
4
  import React, { forwardRef, useEffect, useImperativeHandle } from "react";
5
5
  import { generateNewAnemometer, InputAnemometerStepProps, Anemometer } from "./input-anemometer.types";
6
6
  import './input-anemometer.css'
@@ -16,6 +16,7 @@ import TextInput from "../../inputs/text-input/text-input";
16
16
  import { useAppSelector, useAppDispatch } from "../../../../lib/hooks";
17
17
  import { selectActiveStep, selectAnemometerPayoutOptions, selectAnemometers, selectDefaultAnemometerPayoutOption, setActiveStep, setAnemometers, setWizardStep } from "../../../../lib/features/wizard/wizardSlice";
18
18
  import { cloneDeep } from "lodash";
19
+ import { Payout } from "../../../../lib/features/back-testing/backTestingAPISlice";
19
20
 
20
21
  const addProxyButtonBase = '#FFF';
21
22
  const addProxyButtonMain = alpha(addProxyButtonBase, 0.7);
@@ -1,4 +1,5 @@
1
- import { Payout, PayoutOption, PayoutWizardStepType, RadioChoice } from "../step.types"
1
+ import { ProxyPayout } from "../../../../lib/features/back-testing/backTestingAPISlice";
2
+ import { RadioChoice } from "../step.types"
2
3
  import { v4 as uuidv4 } from 'uuid';
3
4
 
4
5
  export interface InputAnemometerStepProps {
@@ -12,7 +13,7 @@ export interface Anemometer {
12
13
  file: File | undefined
13
14
  fileError: boolean,
14
15
  fileErrorMsg: string,
15
- customPayouts: Payout[] | undefined
16
+ customPayouts: ProxyPayout[] | undefined
16
17
  }
17
18
 
18
19
  export function generateNewAnemometer(code:string,payoutTableRef:string | undefined) : Anemometer {
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
 
3
- import { generateLocationOptions, LocationChoice, MediaType, Payout, PayoutWizardStepType, RadioChoice, WizardStep } from "../step.types";
3
+ import { generateLocationOptions, LocationChoice, MediaType, PayoutWizardStepType, RadioChoice, WizardStep } from "../step.types";
4
4
  import React, { forwardRef, useEffect, useImperativeHandle } from "react";
5
5
  import { CIAS, generateNewCIAS, InputCIASStepProps } from "./input-cias.types";
6
6
  import './input-cias.css'
@@ -19,6 +19,7 @@ import DeleteIcon from '@mui/icons-material/Delete';
19
19
  import PlaceIcon from '@mui/icons-material/Place';
20
20
  import { setAutoCalculatePayoutsEnabled } from "../../../../lib/features/back-testing/backTestingSlice";
21
21
  import { cloneDeep } from "lodash";
22
+ import { Payout } from "../../../../lib/features/back-testing/backTestingAPISlice";
22
23
 
23
24
  const addCIASButtonBase = '#FFF';
24
25
  const addCIASButtonMain = alpha(addCIASButtonBase, 0.7);
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
 
3
- import { generateLocationOptions, LocationChoice, MediaType, Payout, PayoutWizardStepType, RadioChoice, WizardStep } from "../step.types";
3
+ import { generateLocationOptions, LocationChoice, MediaType, PayoutWizardStepType, RadioChoice, WizardStep } from "../step.types";
4
4
  import React, { forwardRef, useEffect, useImperativeHandle } from "react";
5
5
  import { generateNewProxy, InputProxyStepProps, Proxy } from "./input-proxy.types";
6
6
  import './input-proxy.css'
@@ -16,6 +16,7 @@ import NumberInput from "../../inputs/number-input/number-input";
16
16
  import { selectActiveStep, selectDefaultProxyPayoutOption, selectLocations, selectProxies, selectProxyPayoutOptions, selectSelectedProxy, setActiveStep, setWizardStep, setProxies } from "../../../../lib/features/wizard/wizardSlice";
17
17
  import { useAppSelector, useAppDispatch } from "../../../../lib/hooks";
18
18
  import { cloneDeep } from "lodash";
19
+ import { Payout } from "../../../../lib/features/back-testing/backTestingAPISlice";
19
20
 
20
21
  const addProxyButtonBase = '#FFF';
21
22
  const addProxyButtonMain = alpha(addProxyButtonBase, 0.7);
@@ -1,5 +1,5 @@
1
- import { RiskLocation } from "../input-location/input-location.types"
2
- import { Payout, PayoutOption, PayoutWizardStepType, RadioChoice } from "../step.types"
1
+ import { Payout } from "../../../../lib/features/back-testing/backTestingAPISlice";
2
+ import { RadioChoice } from "../step.types"
3
3
  import { v4 as uuidv4 } from 'uuid';
4
4
 
5
5
  export interface InputProxyStepProps {
@@ -1,3 +1,4 @@
1
+ import { Payout } from "../../../lib/features/back-testing/backTestingAPISlice";
1
2
  import { RiskLocation } from "./input-location/input-location.types";
2
3
 
3
4
  export interface WizardStep {
@@ -50,11 +51,6 @@ export interface PayoutOption {
50
51
  refId: string
51
52
  value: Payout[]
52
53
  }
53
-
54
- export interface Payout {
55
- category: number,
56
- payout: number
57
- }
58
54
 
59
55
  export function getConfiguredPayoutTable(index:number, options: Payout[][]) : Payout[] {
60
56
  return options[index];
@@ -1,4 +1,8 @@
1
1
  import BackTestingWizard from './back-testing-wizard';
2
- import {ProxyRequest,AnemometerRequest,CIASRequest,StormPayout,WSPayoutRequest,WSPayoutResponse,PGADTO,EQPayoutDTO,EQPayoutsRequest,EQPayoutsResponse} from './../../lib/features/back-testing/backTestingAPISlice'
2
+ import {Payout,PayoutDetails,ProxyRequest,AnemometerRequest,CIASRequest,StormPayout,WSPayoutRequest,WSPayoutResponse,PGADTO,EQPayoutDTO,EQPayoutsRequest,EQPayoutsResponse} from './../../lib/features/back-testing/backTestingAPISlice'
3
+ import {CATCircle,CATCounty,CATPolygon,CATShape,CATShapeType} from './../back-testing-map/back-testing-map.types'
4
+ import { WizardAnemometer,WizardCIAS,WizardLocation,WizardPGA,WizardProxy,WizardView } from '../back-testing-hub/back-testing-hub.types';
5
+ import { PayoutWizardStepType } from '../back-testing-stepper/steps/step.types';
6
+ import { WeatherEventOption } from '../back-testing-sidebar/back-testing-sidebar.types';
3
7
  export {BackTestingWizard}
4
- export type {ProxyRequest,AnemometerRequest,CIASRequest,StormPayout,WSPayoutRequest,WSPayoutResponse,PGADTO,EQPayoutDTO,EQPayoutsRequest,EQPayoutsResponse}
8
+ export type {Payout,PayoutDetails,WeatherEventOption,ProxyRequest,AnemometerRequest,CIASRequest,StormPayout,WSPayoutRequest,WSPayoutResponse,PGADTO,EQPayoutDTO,EQPayoutsRequest,EQPayoutsResponse,CATShapeType,CATCircle,CATCounty,CATPolygon,CATShape,WizardView,PayoutWizardStepType,WizardAnemometer,WizardCIAS,WizardLocation,WizardPGA,WizardProxy}