@undp/carbon-library 1.0.63 → 1.0.65

Sign up to get free protection for your applications and to get access to all the features.
Files changed (46) hide show
  1. package/dist/cjs/index.js +7971 -1711
  2. package/dist/cjs/index.js.map +1 -1
  3. package/dist/cjs/types/Components/Common/CoBenifits/assessment.d.ts +3 -0
  4. package/dist/cjs/types/Components/Common/CoBenifits/coBenifits.d.ts +14 -0
  5. package/dist/cjs/types/Components/Common/CoBenifits/economic.d.ts +3 -0
  6. package/dist/cjs/types/Components/Common/CoBenifits/environmental.d.ts +3 -0
  7. package/dist/cjs/types/Components/Common/CoBenifits/genderParity.d.ts +3 -0
  8. package/dist/cjs/types/Components/Common/CoBenifits/safeguards.d.ts +3 -0
  9. package/dist/cjs/types/Components/Common/CoBenifits/sdgGoals.d.ts +3 -0
  10. package/dist/cjs/types/Components/Common/CoBenifits/social.d.ts +3 -0
  11. package/dist/cjs/types/Components/Common/NdcActionDetails/ndcActionDetails.d.ts +13 -0
  12. package/dist/cjs/types/Components/NdcActions/AddNdcAction/addNdcActionComponent.d.ts +3 -0
  13. package/dist/cjs/types/Components/index.d.ts +1 -0
  14. package/dist/cjs/types/Definitions/Definitions/programme.definitions.d.ts +2 -0
  15. package/dist/cjs/types/Definitions/Enums/commonEnums.d.ts +23 -0
  16. package/dist/cjs/types/Definitions/Enums/consumerGroups.enum.d.ts +4 -0
  17. package/dist/cjs/types/Definitions/Enums/energyGenerationUnits.enum.d.ts +13 -0
  18. package/dist/cjs/types/Definitions/Enums/landAreaUnits.enum.d.ts +15 -0
  19. package/dist/cjs/types/Definitions/Enums/mitigation.types.enum.d.ts +1 -0
  20. package/dist/cjs/types/Definitions/Enums/sdgGoals.enum.d.ts +19 -0
  21. package/dist/cjs/types/Definitions/Enums/sector.enum.d.ts +12 -0
  22. package/dist/cjs/types/Definitions/index.d.ts +6 -0
  23. package/dist/esm/index.js +7967 -1714
  24. package/dist/esm/index.js.map +1 -1
  25. package/dist/esm/types/Components/Common/CoBenifits/assessment.d.ts +3 -0
  26. package/dist/esm/types/Components/Common/CoBenifits/coBenifits.d.ts +14 -0
  27. package/dist/esm/types/Components/Common/CoBenifits/economic.d.ts +3 -0
  28. package/dist/esm/types/Components/Common/CoBenifits/environmental.d.ts +3 -0
  29. package/dist/esm/types/Components/Common/CoBenifits/genderParity.d.ts +3 -0
  30. package/dist/esm/types/Components/Common/CoBenifits/safeguards.d.ts +3 -0
  31. package/dist/esm/types/Components/Common/CoBenifits/sdgGoals.d.ts +3 -0
  32. package/dist/esm/types/Components/Common/CoBenifits/social.d.ts +3 -0
  33. package/dist/esm/types/Components/Common/NdcActionDetails/ndcActionDetails.d.ts +13 -0
  34. package/dist/esm/types/Components/NdcActions/AddNdcAction/addNdcActionComponent.d.ts +3 -0
  35. package/dist/esm/types/Components/index.d.ts +1 -0
  36. package/dist/esm/types/Definitions/Definitions/programme.definitions.d.ts +2 -0
  37. package/dist/esm/types/Definitions/Enums/commonEnums.d.ts +23 -0
  38. package/dist/esm/types/Definitions/Enums/consumerGroups.enum.d.ts +4 -0
  39. package/dist/esm/types/Definitions/Enums/energyGenerationUnits.enum.d.ts +13 -0
  40. package/dist/esm/types/Definitions/Enums/landAreaUnits.enum.d.ts +15 -0
  41. package/dist/esm/types/Definitions/Enums/mitigation.types.enum.d.ts +1 -0
  42. package/dist/esm/types/Definitions/Enums/sdgGoals.enum.d.ts +19 -0
  43. package/dist/esm/types/Definitions/Enums/sector.enum.d.ts +12 -0
  44. package/dist/esm/types/Definitions/index.d.ts +6 -0
  45. package/dist/index.d.ts +98 -1
  46. package/package.json +2 -1
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Assessment: (props: any) => React.JSX.Element;
3
+ export default Assessment;
@@ -0,0 +1,14 @@
1
+ import React from "react";
2
+ import "./coBenifits.scss";
3
+ export interface CoBenefitProps {
4
+ onClickedBackBtn?: any;
5
+ onFormSubmit?: any;
6
+ coBenefitsDetails?: any;
7
+ submitButtonText?: any;
8
+ viewOnly?: boolean;
9
+ coBenifitsViewDetails?: any;
10
+ loading?: any;
11
+ t: any;
12
+ }
13
+ declare const CoBenifitsComponent: (props: CoBenefitProps) => React.JSX.Element;
14
+ export default CoBenifitsComponent;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Economic: (props: any) => React.JSX.Element;
3
+ export default Economic;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Environmental: (props: any) => React.JSX.Element;
3
+ export default Environmental;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const GenderParity: (props: any) => React.JSX.Element;
3
+ export default GenderParity;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Safeguards: (props: any) => React.JSX.Element;
3
+ export default Safeguards;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const SdgGoals: (props: any) => React.JSX.Element;
3
+ export default SdgGoals;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ declare const Social: (props: any) => React.JSX.Element;
3
+ export default Social;
@@ -0,0 +1,13 @@
1
+ import React from "react";
2
+ import "./ndcActionDetails.scss";
3
+ import "../../../Styles/common.table.scss";
4
+ export interface NdcActionDetailsProps {
5
+ isBackBtnVisible: boolean;
6
+ onFormSubmit: any;
7
+ ndcActionDetails: any;
8
+ t: any;
9
+ programmeDetails?: any;
10
+ onClickedBackBtn?: any;
11
+ }
12
+ declare const NdcActionDetails: (props: NdcActionDetailsProps) => React.JSX.Element;
13
+ export default NdcActionDetails;
@@ -0,0 +1,3 @@
1
+ import React from "react";
2
+ import "./addNdcActionComponent.scss";
3
+ export declare const AddNdcActionComponent: (props: any) => React.JSX.Element;
@@ -9,6 +9,7 @@ export * from "./User/UserManagement/userManagementComponent";
9
9
  export * from "./Investment/AddNewInvestment/investmentCreationComponent";
10
10
  export * from "./Investment/InvestmentManagement/investmentManagementComponent";
11
11
  export * from "./NdcActions/NdcActionManagement/ndcActionManagementComponent";
12
+ export * from "./NdcActions/AddNdcAction/addNdcActionComponent";
12
13
  export * from "./Common/Loading/loading";
13
14
  export * from "./Common/LegendItem/legendItem";
14
15
  export * from "./Common/Maps/mapComponent";
@@ -4,6 +4,7 @@ import { ProgrammeStage } from "../Enums/programmeStage.enum";
4
4
  import { ProgrammeStageMRV } from "../Enums/programmeStageMRV.enum";
5
5
  import { TypeOfMitigation } from "../Enums/typeOfMitigation.enum";
6
6
  import { CreditTransferStage } from "../Enums/creditTransferStage.enum";
7
+ import { RcFile } from "rc-upload/lib/interface";
7
8
  export declare const getStageEnumVal: (value: string) => string;
8
9
  export declare const getCreditStageVal: (value: string) => string;
9
10
  export declare const getStageTransferEnumVal: (value: string, transfer: ProgrammeTransfer) => string;
@@ -139,3 +140,4 @@ export declare const getFinancialFields: (programme: Programme) => {
139
140
  export declare const getCompanyBgColor: (item: string) => "rgba(185, 226, 244, 0.56)" | "rgba(254, 241, 173, 0.55)" | "rgba(128, 255, 0, 0.12)";
140
141
  export declare const getRetirementTypeString: (retirementType: string | null) => "-" | "CROSS BORDER TRANSFER" | "LEGAL ACTION" | "OTHER" | undefined;
141
142
  export declare const sumArray: (arrList: any[]) => any;
143
+ export declare const getBase64: (file: RcFile) => Promise<string>;
@@ -0,0 +1,23 @@
1
+ export declare enum RadioButtonStatus {
2
+ YES = "YES",
3
+ NO = "NO",
4
+ NA = "N/A"
5
+ }
6
+ export declare enum RadioButtonStatus2 {
7
+ YES = "YES",
8
+ NO = "NO",
9
+ MAYBE = "MAYBE"
10
+ }
11
+ export declare enum Titles {
12
+ Mr = "Mr",
13
+ Mrs = "Mrs"
14
+ }
15
+ export declare const titleList: {
16
+ value: Titles;
17
+ label: string;
18
+ }[];
19
+ export declare enum FormElementType {
20
+ Radio = 0,
21
+ Label = 1,
22
+ Input = 2
23
+ }
@@ -0,0 +1,4 @@
1
+ export declare const consumerGroupList: {
2
+ value: string;
3
+ label: string;
4
+ }[];
@@ -0,0 +1,13 @@
1
+ export declare enum EnergyGenerationUnits {
2
+ Wh = "Wh/year/unit",
3
+ mWh = "mWh/year/unit",
4
+ kWh = "kWh/year/unit",
5
+ MWh = "MWh/year/unit",
6
+ GWh = "GWh/year/unit",
7
+ J = "J/year/unit",
8
+ KJ = "kJ/year/unit"
9
+ }
10
+ export declare const energyGenerationUnitList: {
11
+ value: string;
12
+ label: string;
13
+ }[];
@@ -0,0 +1,15 @@
1
+ export declare enum LandAreaUnits {
2
+ mm2 = "mm2",
3
+ cm2 = "cm2",
4
+ m2 = "m2",
5
+ ha = "ha",
6
+ km2 = "km2",
7
+ in2 = "in2",
8
+ ft2 = "ft2",
9
+ ac = "ac",
10
+ Mi2 = "Mi2"
11
+ }
12
+ export declare const landAreaUnitList: {
13
+ value: string;
14
+ label: string;
15
+ }[];
@@ -28,3 +28,4 @@ export declare const mitigationTypeList: {
28
28
  value: string;
29
29
  label: string;
30
30
  }[];
31
+ export declare const sectorMitigationTypesListMapped: any;
@@ -0,0 +1,19 @@
1
+ export declare enum SdgGoals {
2
+ noPoverty = "No Poverty",
3
+ zeroHunger = "Zero Hunger",
4
+ gdHealth = "Good Health and Well-being",
5
+ qualityEducation = "Quality Education",
6
+ genderEq = "Gender Equality",
7
+ cleanWatr = "Clean Water and Sanitation",
8
+ affEnergy = "Affordable and Clean Energy",
9
+ decentWork = "Decent Work and Economic Growth",
10
+ industry = "Industry, Innovation and Infrastructure",
11
+ reducedInEq = "Reduced Inequalities",
12
+ sustainableCities = "Sustainable Cities and Communities",
13
+ responsibleConsumption = "Responsible Consumption and Production",
14
+ climateAction = "Climate Action",
15
+ lifeBelowWater = "Life Below Water",
16
+ lifeOnLand = "Life On Land",
17
+ peace = "Peace, Justice and Strong Institutions",
18
+ partnership = "Partnerships for the Goals"
19
+ }
@@ -0,0 +1,12 @@
1
+ export declare enum Sector {
2
+ Energy = "Energy",
3
+ Health = "Health",
4
+ Education = "Education",
5
+ Transport = "Transport",
6
+ Manufacturing = "Manufacturing",
7
+ Hospitality = "Hospitality",
8
+ Forestry = "Forestry",
9
+ Waste = "Waste",
10
+ Agriculture = "Agriculture",
11
+ Other = "Other"
12
+ }
@@ -16,6 +16,12 @@ export * from "./Enums/retireType.enum";
16
16
  export * from "./Enums/programmeStageMRV.enum";
17
17
  export * from "./Enums/programmeStage.enum";
18
18
  export * from "./Enums/company.role.enum";
19
+ export * from "./Enums/energyGenerationUnits.enum";
20
+ export * from "./Enums/landAreaUnits.enum";
21
+ export * from "./Enums/consumerGroups.enum";
22
+ export * from "./Enums/sector.enum";
23
+ export * from "./Enums/commonEnums";
24
+ export * from "./Enums/sdgGoals.enum";
19
25
  export * from "./Definitions/userLogin.definitions";
20
26
  export * from "./Definitions/userInformationContext.definitions";
21
27
  export * from "./Definitions/userForgotPassword.definitions";
package/dist/index.d.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import React, { FC, ReactNode } from 'react';
2
2
  import { DateTime } from 'luxon';
3
+ import { RcFile } from 'rc-upload/lib/interface';
3
4
  import { RawAxiosResponseHeaders, AxiosResponseHeaders, AxiosRequestConfig } from 'axios';
4
5
 
5
6
  declare const CompanyManagementComponent: (props: any) => React.JSX.Element;
@@ -24,6 +25,8 @@ declare const InvestmentManagementComponent: (props: any) => React.JSX.Element;
24
25
 
25
26
  declare const NdcActionManagementComponent: (props: any) => React.JSX.Element;
26
27
 
28
+ declare const AddNdcActionComponent: (props: any) => React.JSX.Element;
29
+
27
30
  declare const Loading: () => React.JSX.Element;
28
31
 
29
32
  interface LegendItemItemProps {
@@ -179,6 +182,7 @@ declare const mitigationTypeList: {
179
182
  value: string;
180
183
  label: string;
181
184
  }[];
185
+ declare const sectorMitigationTypesListMapped: any;
182
186
 
183
187
  declare enum ESGType {
184
188
  AAA = "AAA",
@@ -315,6 +319,98 @@ declare enum CompanyRole {
315
319
  API = "API"
316
320
  }
317
321
 
322
+ declare enum EnergyGenerationUnits {
323
+ Wh = "Wh/year/unit",
324
+ mWh = "mWh/year/unit",
325
+ kWh = "kWh/year/unit",
326
+ MWh = "MWh/year/unit",
327
+ GWh = "GWh/year/unit",
328
+ J = "J/year/unit",
329
+ KJ = "kJ/year/unit"
330
+ }
331
+ declare const energyGenerationUnitList: {
332
+ value: string;
333
+ label: string;
334
+ }[];
335
+
336
+ declare enum LandAreaUnits {
337
+ mm2 = "mm2",
338
+ cm2 = "cm2",
339
+ m2 = "m2",
340
+ ha = "ha",
341
+ km2 = "km2",
342
+ in2 = "in2",
343
+ ft2 = "ft2",
344
+ ac = "ac",
345
+ Mi2 = "Mi2"
346
+ }
347
+ declare const landAreaUnitList: {
348
+ value: string;
349
+ label: string;
350
+ }[];
351
+
352
+ declare const consumerGroupList: {
353
+ value: string;
354
+ label: string;
355
+ }[];
356
+
357
+ declare enum Sector {
358
+ Energy = "Energy",
359
+ Health = "Health",
360
+ Education = "Education",
361
+ Transport = "Transport",
362
+ Manufacturing = "Manufacturing",
363
+ Hospitality = "Hospitality",
364
+ Forestry = "Forestry",
365
+ Waste = "Waste",
366
+ Agriculture = "Agriculture",
367
+ Other = "Other"
368
+ }
369
+
370
+ declare enum RadioButtonStatus {
371
+ YES = "YES",
372
+ NO = "NO",
373
+ NA = "N/A"
374
+ }
375
+ declare enum RadioButtonStatus2 {
376
+ YES = "YES",
377
+ NO = "NO",
378
+ MAYBE = "MAYBE"
379
+ }
380
+ declare enum Titles {
381
+ Mr = "Mr",
382
+ Mrs = "Mrs"
383
+ }
384
+ declare const titleList: {
385
+ value: Titles;
386
+ label: string;
387
+ }[];
388
+ declare enum FormElementType {
389
+ Radio = 0,
390
+ Label = 1,
391
+ Input = 2
392
+ }
393
+
394
+ declare enum SdgGoals {
395
+ noPoverty = "No Poverty",
396
+ zeroHunger = "Zero Hunger",
397
+ gdHealth = "Good Health and Well-being",
398
+ qualityEducation = "Quality Education",
399
+ genderEq = "Gender Equality",
400
+ cleanWatr = "Clean Water and Sanitation",
401
+ affEnergy = "Affordable and Clean Energy",
402
+ decentWork = "Decent Work and Economic Growth",
403
+ industry = "Industry, Innovation and Infrastructure",
404
+ reducedInEq = "Reduced Inequalities",
405
+ sustainableCities = "Sustainable Cities and Communities",
406
+ responsibleConsumption = "Responsible Consumption and Production",
407
+ climateAction = "Climate Action",
408
+ lifeBelowWater = "Life Below Water",
409
+ lifeOnLand = "Life On Land",
410
+ peace = "Peace, Justice and Strong Institutions",
411
+ partnership = "Partnerships for the Goals"
412
+ }
413
+
318
414
  interface LoginProps {
319
415
  email: string;
320
416
  password: string;
@@ -506,6 +602,7 @@ declare const getFinancialFields: (programme: Programme) => {
506
602
  declare const getCompanyBgColor: (item: string) => "rgba(185, 226, 244, 0.56)" | "rgba(254, 241, 173, 0.55)" | "rgba(128, 255, 0, 0.12)";
507
603
  declare const getRetirementTypeString: (retirementType: string | null) => "-" | "CROSS BORDER TRANSFER" | "LEGAL ACTION" | "OTHER" | undefined;
508
604
  declare const sumArray: (arrList: any[]) => any;
605
+ declare const getBase64: (file: RcFile) => Promise<string>;
509
606
 
510
607
  interface ProgrammeDeveloperCreation {
511
608
  companyName?: string;
@@ -601,4 +698,4 @@ declare class ProgrammeEntity implements BaseEntity {
601
698
  companyId?: number[];
602
699
  }
603
700
 
604
- export { AddNewCompanyComponent, AddNewUserComponent, BaseEntity, Company, CompanyManagementColumns, CompanyManagementComponent, CompanyProfileComponent, CompanyRole, ConfigurationSettingsType, ConnectionContextProviderProps, ConnectionProps, CountrySelect, CreditTransferStage, ESGType, HeaderProps, Instrument, InvestmentCreationComponent, InvestmentLevel, InvestmentManagementComponent, InvestmentStatus, InvestmentStream, InvestmentType, LayoutSiderProps, LegendItem, LegendItemItemProps, Loading, LoginProps, MapComponent, MapComponentProps, MapPopupData, MapSourceData, MapTypes, MapboxComponent, MarkerData, Methods, MitigationTypes, NdcActionManagementComponent, NdcActionStatus, NdcActionTypes, ProfileIcon, ProfileIconProps, Programme, ProgrammeDeveloperCreation, ProgrammeEntity, ProgrammeManagementColumns, ProgrammeManagementComponent, ProgrammeProperties, ProgrammePropertiesT, ProgrammeStage, ProgrammeStageMRV, ProgrammeT, ProgrammeTransfer, ProgrammeViewComponent, Response, RetireType, Role, RoleIcon, RoleIconProps, SectoralScope, StasticCard, StasticCardItemProps, TxType, TypeOfMitigation, UnitField, User, UserContextProps, UserCreationProps, UserManagementColumns, UserManagementComponent, UserProfileComponent, UserProps, addCommSep, addCommSepRound, addRoundNumber, addSpaces, getCompanyBgColor, getCreditStageVal, getFinancialFields, getGeneralFields, getInvestmentStatusEnumVal, getNdcActionStatusEnumVal, getNdcStatusTagType, getRetirementTypeString, getStageEnumVal, getStageTagType, getStageTagTypeMRV, getStageTransferEnumVal, getStatusTagType, getTransferStageTagType, isBase64, mitigationTypeList, ndcActionTypeList, sumArray, userForgotPasswordProps };
701
+ export { AddNdcActionComponent, AddNewCompanyComponent, AddNewUserComponent, BaseEntity, Company, CompanyManagementColumns, CompanyManagementComponent, CompanyProfileComponent, CompanyRole, ConfigurationSettingsType, ConnectionContextProviderProps, ConnectionProps, CountrySelect, CreditTransferStage, ESGType, EnergyGenerationUnits, FormElementType, HeaderProps, Instrument, InvestmentCreationComponent, InvestmentLevel, InvestmentManagementComponent, InvestmentStatus, InvestmentStream, InvestmentType, LandAreaUnits, LayoutSiderProps, LegendItem, LegendItemItemProps, Loading, LoginProps, MapComponent, MapComponentProps, MapPopupData, MapSourceData, MapTypes, MapboxComponent, MarkerData, Methods, MitigationTypes, NdcActionManagementComponent, NdcActionStatus, NdcActionTypes, ProfileIcon, ProfileIconProps, Programme, ProgrammeDeveloperCreation, ProgrammeEntity, ProgrammeManagementColumns, ProgrammeManagementComponent, ProgrammeProperties, ProgrammePropertiesT, ProgrammeStage, ProgrammeStageMRV, ProgrammeT, ProgrammeTransfer, ProgrammeViewComponent, RadioButtonStatus, RadioButtonStatus2, Response, RetireType, Role, RoleIcon, RoleIconProps, SdgGoals, Sector, SectoralScope, StasticCard, StasticCardItemProps, Titles, TxType, TypeOfMitigation, UnitField, User, UserContextProps, UserCreationProps, UserManagementColumns, UserManagementComponent, UserProfileComponent, UserProps, addCommSep, addCommSepRound, addRoundNumber, addSpaces, consumerGroupList, energyGenerationUnitList, getBase64, getCompanyBgColor, getCreditStageVal, getFinancialFields, getGeneralFields, getInvestmentStatusEnumVal, getNdcActionStatusEnumVal, getNdcStatusTagType, getRetirementTypeString, getStageEnumVal, getStageTagType, getStageTagTypeMRV, getStageTransferEnumVal, getStatusTagType, getTransferStageTagType, isBase64, landAreaUnitList, mitigationTypeList, ndcActionTypeList, sectorMitigationTypesListMapped, sumArray, titleList, userForgotPasswordProps };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@undp/carbon-library",
3
- "version": "1.0.63",
3
+ "version": "1.0.65",
4
4
  "description": "Shared Library of tools for Carbon Credits applications ecosystem for ExO and and HQ/GEF",
5
5
  "type": "module",
6
6
  "scripts": {
@@ -15,6 +15,7 @@
15
15
  "@rollup/plugin-commonjs": "^25.0.0",
16
16
  "@rollup/plugin-node-resolve": "^15.0.2",
17
17
  "@rollup/plugin-typescript": "^11.1.1",
18
+ "@undp/carbon-credit-calculator": "^1.0.0",
18
19
  "node-sass": "^7.0.3",
19
20
  "postcss": "^8.4.23",
20
21
  "rollup": "^3.22.0",