From 7de07901b2bc1dcdeb88c2045856c51a926f6c34 Mon Sep 17 00:00:00 2001 From: onehanddev Date: Fri, 29 Nov 2024 19:55:14 +0530 Subject: [PATCH 1/6] added tooltip constant file to centralise and store all content used inside of tooltips in the project, implemented the info popup in the dashboard --- client/src/components/ui/info-button.tsx | 6 +- client/src/constants/tooltip.tsx | 688 ++++++++++++++++++ .../overview/table/toolbar/index.tsx | 260 ++++++- 3 files changed, 928 insertions(+), 26 deletions(-) create mode 100644 client/src/constants/tooltip.tsx diff --git a/client/src/components/ui/info-button.tsx b/client/src/components/ui/info-button.tsx index 8f777e83..a1642f30 100644 --- a/client/src/components/ui/info-button.tsx +++ b/client/src/components/ui/info-button.tsx @@ -3,6 +3,8 @@ import * as React from "react"; import { InfoIcon } from "lucide-react"; +import { cn } from "@/lib/utils"; + import { Button } from "@/components/ui/button"; import { Dialog, @@ -16,8 +18,10 @@ import { export default function InfoButton({ title, children, + classNames, }: PropsWithChildren<{ title?: string; + classNames?: string; }>) { return ( @@ -26,7 +30,7 @@ export default function InfoButton({ - + {title && {title}} {children} diff --git a/client/src/constants/tooltip.tsx b/client/src/constants/tooltip.tsx new file mode 100644 index 00000000..c36a8746 --- /dev/null +++ b/client/src/constants/tooltip.tsx @@ -0,0 +1,688 @@ +export const OVERVIEW = { + SCORECARD_RATING: + "The individual non-economic scores, in addition to the economic feasibility and abatement potential, are weighted using the weights on the left to an overall score per project", + COST: "Cost per tCO2e (incl. CAPEX and OPEX)", + + ABATEMENT_POTENTIAL: + "Estimation of the total amount of CO2e abatement that is expected during the life of the project. Used to determine whether the scale justifies the development costs", + TOTAL_COST: "Total cost (incl. CAPEX and OPEX)", +}; + +export const SCORECARD_PRIORITIZATION = { + FINANCIAL_FEASIBILITY: + "Evaluation of the forecasted costs, revenues, and potential break-even price for carbon credits", + LEGAL_FEASIBILITY: + "Evaluation of whether a country has the legal protection, government infrastructure, and political support that is required for a project to successfully produce carbon credits. Focus will also be on community aspects and benefits for community", + IMPLEMENTATION_FEASIBILITY: + "Assessment of the permanence risk a project faces due to deforestation and natural disasters. Used to determine whether a project will achieve the estimated abatement and approval for credit issuance", + SOCIAL_FEASIBILITY: + "Assessment of the leakage risk a project faces from communities reverting to previous activities that degraded or destroyed ecosystems (e.g., deforestation, walling off shrimp ponds, etc.)", + SECURITY_FEASIBILITY: + "Assessment of the safety threat to individuals entering the country. Used to determine the physical risk posed to on-the-ground teams", + AVAILABILITY_OF_EXPERIENCED_LABOR: + "Assessment of whether a country has a pre-existing labor pool with experience in conservation or restoration work, based on the number of blue carbon or AFOLU carbon projects completed or in development", + AVAILABILITY_OF_ALTERNATIVE_FUNDING: + "Assessment of the possibility a project could access revenues outside of carbon credits (e.g., grants, biodiversity credits, resilience credits, etc.) to cover gaps between costs and carbon pricing", + COASTAL_PROTECTION_BENEFIT: + "Estimation of a project's ability to reduce community risk through improved coastal resilience, to inform likelihood of achieving higher credit price", + BIODIVERSITY_BENEFIT: + "Estimation of a project's impact on biodiversity, to inform likelihood of achieving higher credit price", + ABATEMENT_POTENTIAL: + "Estimation of the total amount of CO2e abatement that is expected during the life of the project. Used to determine whether the scale justifies the development costs", +}; + +export const KEY_COSTS = { + TOTAL_COST: "Total cost (incl. CAPEX and OPEX)", + IMPLEMENTATION_LABOR: + "Only applicable to restoration. The costs associated with labor and materials required for rehabilitating the degraded area (hydrology, planting or hybrid)", + COMMUNITY_BENEFIT_SHARING_FUND: + "The creation of a fund to compensate for alternative livelihoods, and opportunity cost. The objective of the fund is to meet the community's socioeconomic and financial priorities, which can be realized through goods, services, infrastructure, and/or cash (e.g., textbooks, desalination plant).", + MONITORING_AND_MAINTENANCE: + "• Monitoring: The expenses related to individuals moving throughout the project site to prevent degradation and report necessary actions/changes.\n• Maintenance: Only applicable to restoration. The costs associated with the physical upkeep of the original implementation, such as pest control, removing blockages, and rebuilding small portions.", + COMMUNITY_REPRESENTATION: + "Efforts aimed at obtaining community buy-in, including assessing community needs, obtaining free, prior, and informed consent, conducting stakeholder surveys, and providing education about blue carbon.", + CONSERVATION_PLANNING: + "Activities in the project start-up phase like project management, vendor coordination, fundraising, research, travel, etc.", + LONG_TERM_OPERATING: + "The expenses related to project oversight, vendor coordination, community engagement, stakeholder management, etc., during the ongoing operating years of the project.", + CARBON_STANDARD_FEES: + "Administrative fees charged by the carbon standard (e.g., Verra).", +}; + +export const FILTERS = { + CONTINENT: + "Continents are displayed based on the inclusion of countries with available data for blue carbon projects within each region.", + COUNTRY: + "Countries have been selected based on the availability of data supporting blue carbon projects.", + ECOSYSTEM: + "Ecosystems are categorized based on their unique coastal habitats that play a critical role in carbon sequestration and ecosystem services. These include mangroves, seagrasses, and salt marshes, each offering distinct environmental and carbon storage benefits.", + ACTIVITY_TYPE: + "Activity refers to the overarching strategy implemented in a blue carbon project to protect or enhance ecosystem health and carbon sequestration. Projects can focus on either Restoration or Conservation:\n\n• Conservation: Aims to maintain existing ecosystems, preventing degradation and preserving their carbon sequestration potential. Conservation is cost-effective and crucial for long-term climate mitigation, offering benefits like avoiding biodiversity loss, ensuring ecosystem resilience, and reducing financial investment compared to restoration. However, proving additionality can be challenging.\n\n• Restoration: Focuses on rehabilitating degraded ecosystems to restore their functionality and enhance carbon capture. While often more resource-intensive, restoration projects are highly visible and impactful. Restoration is implemented through one of three approaches: planting, hydrology, or a hybrid of the two.", + COST: "Total cost (incl. CAPEX and OPEX)", + ABATEMENT_POTENTIAL: + "Estimation of the total amount of CO2e abatement that is expected during the life of the project. Used to determine whether the scale justifies the development costs", +}; + +export const MAP_LEGEND = + "Comparison of the total costs ($/tCO2e) of blue carbon projects with their carbon abatement potential (tCO₂e/yr)"; + +export const PROJECT_DETAILS = { + TOTAL_PROJECT_COST_NPV: + "The total cost represents the Net Present Value (NPV) of all expenses associated with a hypothetical blue carbon project, including both capital expenditures (CAPEX) and operating expenditures (OPEX) but excluding financing costs.", + TOTAL_PROJECT_COST: + "The total cost represents all expenses associated with a hypothetical blue carbon project, including both capital expenditures (CAPEX) and operating expenditures (OPEX) but excluding financing costs.", + LEFTOVER_AFTER_OPEX: "OPEX gap (rounded to nearest million):", + ABATEMENT_POTENTIAL: + "Estimation of the total amount of CO2e abatement that is expected during the life of the project. Used to determine whether the scale justifies the development costs", + OVERALL_SCORE: + "The individual non-economic scores, in addition to the economic feasibility and abatement potential, are weighted to an overall score per project", +}; + +export const CUSTOM_PROJECT = { + COUNTRY: + "Countries have been selected based on the availability of data supporting blue carbon projects.", + PROJECT_SIZE: "", // Empty as no text is shown excel sheet + ECOSYSTEM: + "Ecosystems are categorized based on their unique coastal habitats that play a critical role in carbon sequestration and ecosystem services. These include mangroves, seagrasses, and salt marshes, each offering distinct environmental and carbon storage benefits.", + ACTIVITY_TYPE: ( +
+

+ Activity refers to the overarching strategy implemented in a blue carbon + project to protect or enhance ecosystem health and carbon sequestration. + Projects can focus on either Restoration or Conservation: +

+
    +
  • + Conservation: Aims to maintain existing ecosystems, preventing + degradation and preserving their carbon sequestration potential. + Conservation is cost-effective and crucial for long-term climate + mitigation, offering benefits like avoiding biodiversity loss, + ensuring ecosystem resilience, and reducing financial investment + compared to restoration. However, proving additionality can be + challenging. +
  • +
  • + Restoration: Focuses on rehabilitating degraded ecosystems to restore + their functionality and enhance carbon capture. While often more + resource-intensive, restoration projects are highly visible and + impactful. Restoration is implemented through one of three approaches: + planting, hydrology, or a hybrid of the two. +
  • +
+
+ ), // TSX +}; + +export const RESTORATION_PROJECT_DETAILS = { + ACTIVITY_TYPE: ( +
+

+ Restoration activity type describes the specific methods used in + restoration projects to rehabilitate degraded ecosystems. The Blue + Carbon Cost Tool supports three types of restoration activities: +

+
    +
  • + Planting: Includes activities such as planting seeds, creating + nurseries, and other efforts to regenerate vegetation in degraded + ecosystems. +
  • +
  • + Hydrology: Focuses on repairing and restoring natural water flow and + ecosystem health. This involves tasks like erosion control, + excavation, and building infrastructure such as culverts or + breakwaters. Hydrology projects often require heavy machinery and tend + to be more capital-intensive than planting projects. +
  • +
  • + Hybrid: Combines planting and hydrology techniques for a comprehensive + restoration approach that addresses multiple ecosystem needs. +
  • +
+

+ Each restoration activity type addresses specific challenges and + ecosystem conditions, allowing tailored interventions for maximum + impact. +

+
+ ), + SEQUESTRATION_RATE: ( +
+

+ The sequestration rate used represents the rate at which a blue carbon + project captures and stores carbon dioxide equivalent (CO2e) within its + ecosystem. The tool allows selection from three tiers of sequestration + rate options: +

+
    +
  • + Tier 1 - Global Sequestration Rate: A default value provided by the + IPCC, applicable to all ecosystems. +
  • +
  • + Tier 2 - Country-Specific Sequestration Rate: National-level + sequestration rates, which are more specific but currently available + only for mangroves. +
  • +
  • + Tier 3 - Project-Specific Sequestration Rate: Custom sequestration + rates based on site-specific data, entered directly into the tool. +
  • +
+

Note: only mangroves have Tier 2 default values.

+
    +
  • + Methane (CH4) and nitrous oxide (N2O) emissions are not currently + included in the default sequestration rate values of the model (please + refer to the “Limitations of the tool” section for further details). + However, it is possible to incorporate CH4 and N2O emissions if the + user possesses project-specific data. In such cases, the emissions + should be converted to their respective CO2e before being added to the + dashboard. For instance, if a project removes 0.71 CO2 but introduces + 0.14 tCO2e of CH4 and 0.12 tCO2e of N2O, the net sequestration value + would be 0.45 tCO2e. +
  • +
  • + We assume that all soil organic carbon has been lost post-disturbance. + As such, we do not include emissions reductions from avoided loss of + soil organic carbon. If the user has this data available, it can be + included in the project-specific sequestration rates as described + above. +
  • +
+
+ ), + PROJECT_SPECIFIC_SEQUESTRATION_RATE: + "The project-specific sequestration rate (Tier 3) refers to a customized sequestration rate derived from detailed site-specific data unique to a particular project. This rate provides the most accurate representation of carbon sequestration potential by incorporating local environmental conditions, ecosystem characteristics, and project-specific factors. It must be directly entered into the tool to tailor calculations to the specific circumstances of the project.", + PLANTING_SUCCESS_RATE: + "The planting success rate refers to the percentage of vegetation or trees successfully established and thriving in a reforestation or afforestation project. This metric is critical for assessing the effectiveness of restoration activities and estimating the carbon sequestration potential of the project. A higher planting success rate indicates more robust ecosystem recovery and greater likelihood of achieving the project's environmental and climate objectives.", +}; + +export const CONSERVATION_PROJECT_DETAILS = { + LOSS_RATE_USED: ( +
+

+ The loss rate used represents the percentage of an ecosystem's + carbon stock expected to be lost annually due to degradation or + deforestation. The tool allows selection between: +

+
    +
  • + National average loss rate: Reflects the average rate of ecosystem + loss specific to the country. Note: Only available for mangroves. +
  • +
  • + Global average loss rate: Default values applicable to salt marshes + and seagrass. +
  • +
  • + Project-specific loss rate: A customized rate based on site-specific + data, which can be manually entered for enhanced precision. +
  • +
+

+ While default loss rates do not factor in background recovery rates, + these can be incorporated when using project-specific loss rates. +

+
+ ), + + PROJECT_SPECIFIC_LOSS_RATE: ( +
+

+ The Project-Specific Loss Rate enables the incorporation of customized + data on ecosystem loss tailored to the specific conditions of the + project site. This loss rate reflects the unique degradation or + disturbance factors affecting the project's ecosystem, allowing for + a more accurate representation of carbon sequestration potential. It is + particularly useful when the national or global default loss rates do + not sufficiently capture the specific environmental, economic, or + operational factors influencing the project area. +

+
+ ), + + EMISSION_FACTOR_USED: ( +
+

+ The Emission Factor Used allows the selection of emission factors from + three distinct tiers, providing flexibility based on the level of + available data for the project: +

+
    +
  • + Tier 1: Utilizes global default emission factors, offering a general + yearly estimate per hectare, suitable when local data is unavailable. +
  • +
  • + Tier 2: Uses country-specific values derived from literature sources, + modeling Above-Ground Biomass (AGB) and Soil Organic Carbon (SOC) + emissions separately. Note: Tier 2 default values are only available + for mangrove ecosystems. +
  • +
  • + Tier 3: Enables the use of project-specific emission factors, which + can be entered either as a single value (similar to Tier 1) or as + separate AGB and SOC values (similar to Tier 2), based on the specific + data available for the project. +
  • +
+

+ Note: The model does not currently account for methane (CH4) and nitrous + oxide (N2O) emissions in the default emission factor values. However, + these emissions can be included if project-specific data is available, + following the appropriate conversion to CO2e. +

+
+ ), + + PROCET_SPECIFIC_EMISSIONS_TYPE: ( +
+

+ The Tier 3 - Project-Specific Emissions approach allows for the highest + level of customization and accuracy in estimating emissions. This can be + achieved by either: +

+
    +
  • + Providing a single, consolidated emission factor specific to the + project, which accounts for all relevant sources of emissions, or +
  • +
  • + Separating emissions into Above-Ground Biomass (AGB) and Soil Organic + Carbon (SOC) components, with distinct values entered for each. +
  • +
+

+ This tier relies on project-specific data, offering the most precise + reflection of local conditions and practices. +

+

+ Note: Default values are not available for Tier 3, requiring + comprehensive project data to be entered manually. +

+
+ ), + + EMISSION_FACTOR: ( +
+

+ One emission: Tier 3 allows the use of a project-specific emission + factor, which is entered as a single value in tCO2e per hectare per + year. This approach provides the highest level of precision by + incorporating local data specific to the project site. The emission + factor represents the annual carbon emissions associated with the + project area and can include factors like changes in vegetation or soil + carbon stocks, tailored to the particular conditions of the project. +

+
+ ), + + SOC_EMISSIONS: ( +
+

+ SOC and AGB separately: Tier 3 - Separate AGB and SOC allows for the + entry of project-specific emission factors for both Aboveground Biomass + (AGB) and Soil Organic Carbon (SOC), each expressed in tCO2e per hectare + per year. By separating AGB and SOC, this approach enables a more + detailed and tailored estimate of carbon sequestration and emissions + specific to the project site. The AGB value represents the committed + emissions from aboveground vegetation, such as trees, shrubs, and other + plant matter, while the SOC value accounts for the carbon stored in the + soil. Both of these emission factors are influenced by local conditions, + land use practices, and ecosystem characteristics. Entering these values + separately provides a more precise reflection of the project's + carbon dynamics and allows for a more accurate calculation of overall + emissions reductions or sequestration potential. +

+
+ ), +}; + +export const GENERAL_ASSUMPTIONS = { + CARBON_REVENUES_TO_COVER: ( +
+

+ Carbon Revenues to Cover provides the flexibility to determine whether + carbon revenues should be used to cover only OPEX (Operational + Expenditures) or both CAPEX (Capital Expenditures) and OPEX. This option + allows developers to account for external funding sources such as grants + or philanthropic contributions that may be used to cover a portion of + the costs. +

+

+ Given that CAPEX, which includes start-up and implementation costs, is + typically higher in blue carbon projects, it is generally recommended + that these costs be covered by other funding sources. In contrast, OPEX, + which includes ongoing operational and maintenance costs, can be + sustainably supported by the revenue generated from carbon credits. This + feature provides flexibility based on the funding strategy and the + expected financial structure of the project. +

+
+ ), + + INITIAL_CARBON_PRICE_ASSUMPTIONS: ( +
+

+ Initial Carbon Price Assumptions (in $) sets the default market price + per ton of CO2 equivalent (tCO2e) for carbon + credits. This price is used to estimate potential revenue from carbon + credits, and can be adjusted based on market conditions or projections. +

+
+ ), +}; + +export const ASSUMPTIONS = { + VERIFICATION_FREQUENCY: ( +
+

+ Verification Frequency refers to how often the carbon credits generated + by the project will be verified by a third-party entity. It is typically + set at regular intervals to ensure the project's carbon + sequestration claims are accurate and to issue verified carbon credits + accordingly. +

+
+ ), + + DISCOUNT_RATE: ( +
+

+ The model currently utilizes a fixed discount rate of 4%. However, this + value can be adjusted to incorporate country-specific premiums or other + relevant circumstances. To gain more insights on this topic, we + recommend referring to the "Benchmark discount rates" sheet in + the Carbon Markets pre-feasibility tool, accessible through the Carbon + Markets Community of Practice. +

+
+ ), + + CARBON_PRICE_INCREASE: ( +
+

+ The assumed increase in carbon price (%) does not include inflation, as + the model does not account for inflation or cost increases in its + calculations. +

+
+ ), + + BUFFER: ( +
+

+ When considering carbon credits, it is crucial to account for + non-permanence, leakage, and uncertainty, which are significant factors. + These factors are encompassed within the "buffer" assumption + in the Blue Carbon Cost Tool, where the default value is set at 20%. +

+

+ While modeling specific scenarios, it is valuable to undertake the + exercise of calculating non-permanence, leakage, and uncertainty. +

+
    +
  • + Non-permanence: Verra offers the VCS Non-permanence risk tool, which + can be employed to estimate non-permanence. This tool considers + various risks, including internal factors (e.g., project management, + project longevity), natural elements (e.g., extreme weather events), + and external influences (e.g., land tenure, political aspects). +
  • +
  • + Leakage: Estimating leakage can be challenging. However, it may be + minimal if the project satisfies specific conditions, for example the + project area having been abandoned or previous commercial activities + having been unprofitable. Additionally, inclusion of leakage + mitigation activities (e.g., ecosystem services payments) within the + project can further reduce leakage potential. +
  • +
  • + Uncertainty: The allowable uncertainty is 20% at 90% confidence level + (or 30% of Net Emissions Reductions at 95% confidence level). In cases + where the uncertainty falls below these thresholds, no deduction for + uncertainty would be applicable. More guidance can be found in + Verra's Tidal wetlands and seagrass restoration methodology. In + cases where uncertainty falls above this threshold, you must deduct an + amount equal to the amount that exceeds uncertainty. For example, if + uncertainty is 28% at a 90% confidence level, you must deduct an + additional 8% from your emissions reductions. When using the tool, + this amount should be added to the buffer (in addition to + non-permanence and leakage amounts). +
  • +
+
+ ), + + BASELINE_REASSESSMENT_FREQUENCY: ( +
+

+ Baseline Reassessment Frequency refers to how often the baseline + emissions or sequestration values are reassessed to ensure the + project's ongoing accuracy in estimating carbon impacts. This is + typically done at regular intervals to account for changes in project + conditions or new data, ensuring that the original assumptions remain + valid throughout the project's lifespan. +

+
+ ), + + CONSERVATION_PROJECT_LENGTH: ( +
+

+ Conservation Project Length refers to the duration over which + conservation efforts are implemented and maintained. This includes + activities aimed at preserving and protecting existing ecosystems to + prevent further degradation and enhance carbon sequestration over time. + The length of a conservation project is typically long-term, as it + involves ongoing monitoring and management to ensure ecosystem stability + and carbon storage potential. +

+
+ ), + + RESTORATION_RATE: ( +
+

+ Make sure to adapt the restoration rate depending on what is feasibly + restorable per year. Then adapt the project size according to this rate + and the duration of the restoration activity. For example, if the + reasonable restoration rate is 50 ha / year and you will restore for + five years, your project size will be 250 ha total. +

+
+ ), + + RESTORATION_PROJECT_LENGTH: ( +
+

+ Restoration Project Length refers to the duration required to restore a + degraded ecosystem to a healthier, functional state, including the time + needed for physical interventions (such as planting or hydrological + modifications) and subsequent maintenance. The length can vary depending + on the scale of restoration activities, site conditions, and the time + required for the ecosystem to recover its full carbon sequestration + potential. +

+
+ ), +}; + +export const COST_INPUT_OVERRIDE = { + FEASIBILITY_ANALYSIS: + "The production of a feasibility assessment, evaluating GHG mitigation potential and financial and non-financial considerations (e.g., legal, social).", + CONSERVATION_PLANNING_AND_ADMIN: + "Activities involved in the project start-up phase, such as project management, vendor coordination, fundraising, research, and travel.", + DATA_COLLECTION_AND_FIELD_COSTS: + "The expenses associated with onsite and field sampling to gather necessary data for conservation plan, blue carbon plan, and credit creation (e.g., carbon stock, vegetation and soil characteristics, hydrological data).", + COMMUNITY_REPRESENTATION: + "Efforts aimed at obtaining community buy-in, including assessing community needs, obtaining free, prior, and informed consent, conducting stakeholder surveys, and providing education about blue carbon.", + BLUE_CARBON_PROJECT_PLANNING: + "The preparation of the project design document (PD), which may include potential sea level rise, hydrological or other modeling.", + ESTABLISHING_CARBON_RIGHTS: + "Legal expenses related to clarifying carbon rights, establishing conservation and community agreements, and packaging carbon benefits for legally valid sales.", + VALIDATION: + "The fee or price associated with the validation of the PD (e.g., by Verra).", + IMPLEMENTATION_LABOR: + "Only applicable to restoration. The costs associated with labor and materials required for rehabilitating the degraded area (hydrology, planting or hybrid). Note: Certain countries, ecosystems and activity types don't have implementation labor estimates.", + MONITORING: + "The expenses related to individuals moving throughout the project site to prevent degradation and report necessary actions/changes.", + MAINTENANCE: + "Only applicable to restoration. The costs associated with the physical upkeep of the original implementation, such as pest control, removing blockages, and rebuilding small portions.", + COMMUNITY_BENEFIT_SHARING_FUND: + "The creation of a fund to compensate for alternative livelihoods, and opportunity cost. The objective of the fund is to meet the community's socioeconomic and financial priorities, which can be realized through goods, services, infrastructure, and/or cash (e.g., textbooks, desalination plant).", + CARBON_STANDARD_FEES: + "Administrative fees charged by the carbon standard (e.g., Verra).", + BASELINE_REASSESSMENT: + "The costs associated with a third-party assessment to ensure the initial GHG emission/reduction estimates are accurate and remain so over time.", + MRV: "The costs associated with measuring, reporting, and verifying GHG emissions that occur post-implementation to enable carbon benefit sales through a third party.", + LONG_TERM_PROJECT_OPERATING: + "The expenses related to project oversight, vendor coordination, community engagement, stakeholder management, etc., during the ongoing operating years of the project.", + FINANCING_COST: + "The time, effort, and cost associated with securing financing for the set-up phase of the project.", +}; + +export const CUSTOM_PROJECT_OUTPUTS = { + TOTAL_PROJECT_COST: + "The total financial investment required for the project, including both capital expenditure (CAPEX) and operating expenditure (OPEX), expressed as NPV (Net Present Value).", + LEFTOVER_AFTER_OPEX: + "The remaining net revenue after accounting for all operating expenses (OPEX) associated with the project.", + ANNUAL_PROJECT_CASH_FLOW: + "The net amount of cash generated or consumed by the project on an annual basis, accounting for revenues, CAPEX, and OPEX.", +}; + +export const PROJECT_SUMMARY = { + COST_PER_TCOE_NPV: + "The NPV of the total cost (CAPEX & OPEX, excl. financing cost) divided by the total credits the project will generate.", + COST_PER_HA: + "The NPV of the total cost (CAPEX & OPEX, excl. financing cost) divided by the total ha of the project", + NPV_COVERING_TOTAL_COST: + 'The NPV of the carbon credit revenues subtracted by either the OPEX or the total cost (depending on parameter in "carbon revenues to cover")', + IRR_WHEN_PRICED_TO_COVER_OPEX: + "The internal rate of return (IRR) calculated when carbon credits are priced to only cover the operating expenses (OPEX).", + IRR_WHEN_PRICED_TO_COVER_TOTAL_COST: + "The internal rate of return (IRR) calculated when carbon credits are priced to cover both capital (CAPEX) and operating expenses (OPEX).", + TOTAL_COST_NPV: + "The NPV of the total cost associated with the hypothetical blue carbon project (incl. CAPEX and OPEX, excl. financing cost)", + CAPITAL_EXPENDITURE_NPV: + "The NPV of the CAPEX associated with the hypothetical blue carbon project", + OPERATING_EXPENDITURE_NPV: + "The NPV of the OPEX associated with the hypothetical blue carbon project", + CREDITS_ISSUED: + "The carbon credits issued as part of the project. The buffer has already been subtracted from this total number", + TOTAL_REVENUE_NPV: "The NPV of the carbon credit revenues", + TOTAL_REVENUE_NON_DISCOUNTED: "The non-discounted carbon credit revenues", + FINANCING_COST: + "The financing cost is the time, effort and cost associated with securing financing for the set up (pre-revenue) phase of the project. Calculated as the financing cost assumption (default 5%) multiplied by the non-discounted CAPEX total.", + FUNDING_GAP_NPV: + 'The reverse of the "NPV covering OPEX" or "NPV covering total cost" metric.', + FUNDING_GAP_PER_TCOE_NPV: + 'The reverse of the "NPV covering OPEX" or "NPV covering total cost" metric.', + COMMUNITY_BENEFIT_SHARING_FUND: + "The percentage of the revenues assumed to go back to the community as part of the community benefit sharing fund.", +}; + +export const COST_DETAILS = ( +
+

+ The cost details provide a comprehensive breakdown of the financial + requirements for the project, divided into capital expenditure (CAPEX) and + operating expenditure (OPEX), with values expressed in both total costs + and their Net Present Value (NPV). Each category represents specific + activities or components of the project: +

+ +

+ Total CAPEX: The total one-time costs required to + establish the project. +

+
    +
  • + Feasibility Analysis: The costs for evaluating the GHG mitigation + potential, legal, social, and financial considerations during project + setup. +
  • +
  • + Conservation Planning and Administration: Expenses for planning and + management activities, including vendor coordination, fundraising, + research, and travel during the setup phase. +
  • +
  • + Data Collection and Field Costs: The expenses related to field sampling + for carbon stock, vegetation, soil characteristics, and hydrological + data collection. +
  • +
  • + Community Representation / Liaison: Costs associated with engaging + communities, obtaining informed consent, and conducting stakeholder + surveys. +
  • +
  • + Blue Carbon Project Planning: The preparation of project design + documents, including modeling for sea level rise, hydrology, and + ecosystem impact. +
  • +
  • + Establishing Carbon Rights: Legal costs for defining carbon rights, + establishing community agreements, and enabling valid carbon credit + sales. +
  • +
  • + Validation: Fees for third-party validation of the project design + documentation. +
  • +
  • + Implementation Labor: Costs for restoration-related labor and materials + (if applicable, e.g., planting or hydrological interventions). +
  • +
+ +

+ Total OPEX: The ongoing costs required to maintain and + monitor the project throughout its operational lifespan. +

+
    +
  • + Monitoring: Expenses for ensuring the project site remains intact, with + regular checks to prevent degradation. +
  • +
  • + Maintenance: Costs for maintaining the physical project infrastructure + (if applicable, e.g., in restoration projects). +
  • +
  • + Community Benefit Sharing Fund: A percentage of the project revenues + allocated for community benefits, such as infrastructure, goods, or + cash. +
  • +
  • + Carbon Standard Fees: Administrative fees associated with carbon credit + standards (e.g., registration or issuance). +
  • +
  • + Baseline Reassessment: Costs for periodic re-evaluation of initial GHG + reduction estimates. +
  • +
  • + Measuring, Reporting, and Verification (MRV): Expenses for ongoing + measurement, reporting, and verification of GHG emissions. +
  • +
  • + Long-Term Project Operating: General expenses for continued oversight, + stakeholder engagement, and vendor coordination over the project's + lifetime. +
  • +
+ +

+ Total Project Cost: The sum of all CAPEX and OPEX costs, + expressed in both total value and NPV. The total project cost gives + stakeholders a clear view of financial investment required for the + hypothetical blue carbon project. +

+
+); + +export const ANNUAL_PROJECT_CASHFLOW = + "The Annual Project Cash Flow represents the year-by-year net financial outcome of the project, calculated as the total revenues (primarily from carbon credit sales) minus the annual operating expenditures (OPEX). This metric provides insight into the financial viability and sustainability of the project over its operational lifespan, highlighting when the project is expected to become profitable or break even"; diff --git a/client/src/containers/overview/table/toolbar/index.tsx b/client/src/containers/overview/table/toolbar/index.tsx index e0e23712..446c84e9 100644 --- a/client/src/containers/overview/table/toolbar/index.tsx +++ b/client/src/containers/overview/table/toolbar/index.tsx @@ -1,7 +1,65 @@ +import { SCORECARD_PRIORITIZATION, KEY_COSTS } from "@/constants/tooltip"; + import SearchProjectsTable from "@/containers/overview/table/toolbar/search"; import TabsProjectsTable from "@/containers/overview/table/toolbar/table-selector"; import InfoButton from "@/components/ui/info-button"; +import { + Table, + TableHeader, + TableRow, + TableHead, + TableBody, + TableCell, +} from "@/components/ui/table"; +import { Tabs, TabsList, TabsTrigger, TabsContent } from "@/components/ui/tabs"; + +interface ScorecardMetric { + name: string; + description: string; + weight: number; +} + +const SCORECARD_METRICS: ScorecardMetric[] = [ + { + name: "Economic feasibility", + description: "FINANCIAL_FEASIBILITY", + weight: 20, + }, + { + name: "Abatement potential", + description: "ABATEMENT_POTENTIAL", + weight: 18, + }, + { name: "Legal feasibility", description: "LEGAL_FEASIBILITY", weight: 12 }, + { + name: "Implementation risk score", + description: "IMPLEMENTATION_FEASIBILITY", + weight: 12, + }, + { name: "Social feasibility", description: "SOCIAL_FEASIBILITY", weight: 12 }, + { + name: "Availability of experienced labor", + description: "AVAILABILITY_OF_EXPERIENCED_LABOR", + weight: 10, + }, + { name: "Security rating", description: "SECURITY_FEASIBILITY", weight: 5 }, + { + name: "Availability of alternative funding", + description: "AVAILABILITY_OF_ALTERNATIVE_FUNDING", + weight: 5, + }, + { + name: "Coastal protection benefit", + description: "COASTAL_PROTECTION_BENEFIT", + weight: 3, + }, + { + name: "Biodiversity benefit", + description: "BIODIVERSITY_BENEFIT", + weight: 3, + }, +]; export default function ToolbarProjectsTable() { return ( @@ -9,31 +67,183 @@ export default function ToolbarProjectsTable() {
- -

- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed - vehicula, nunc nec vehicula fermentum, nunc libero bibendum purus, - nec tincidunt libero nunc nec libero. Integer nec libero nec libero - tincidunt tincidunt. Sed vehicula, nunc nec vehicula fermentum, nunc - libero bibendum purus, nec tincidunt libero nunc nec libero. Integer - nec libero nec libero tincidunt tincidunt. -

-

- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed - vehicula, nunc nec vehicula fermentum, nunc libero bibendum purus, - nec tincidunt libero nunc nec libero. Integer nec libero nec libero - tincidunt tincidunt. Sed vehicula, nunc nec vehicula fermentum, nunc - libero bibendum purus, nec tincidunt libero nunc nec libero. Integer - nec libero nec libero tincidunt tincidunt. -

-

- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed - vehicula, nunc nec vehicula fermentum, nunc libero bibendum purus, - nec tincidunt libero nunc nec libero. Integer nec libero nec libero - tincidunt tincidunt. Sed vehicula, nunc nec vehicula fermentum, nunc - libero bibendum purus, nec tincidunt libero nunc nec libero. Integer - nec libero nec libero tincidunt tincidunt. -

+ +
+ +
+ + + General + + + Overview table + + + Scorecard prioritization table + + + Key costs table + + +
+ +
+ +

+ This table offers three distinct views, showcasing example + projects across various countries and activity types. Use + the filters to refine your results, or adjust the selectors + —"Project Size," "Carbon Pricing Type," + and "Cost"—to see different perspectives. +

+
+ + +

+ In addition to economic feasibility and abatement potential, + this table includes{" "} + + qualitative, non-economic scores + + , which may vary by country or ecosystem. Each + project's overall score combines these non-economic + scores with economic feasibility and abatement potential to + give a comprehensive evaluation. These scores add additional + insights for project assessment. +

+
+
+
Low
+
+ Medium +
+
High
+
+
+
+ + + +
+
+

+ In addition to economic feasibility and abatement + potential, this table includes{" "} + + qualitative, non-economic scores + + , which may vary by country or ecosystem. Each + project's overall score combines these non-economic + scores with economic feasibility and abatement potential + to give a comprehensive evaluation. These scores add + additional insights for project assessment. +

+

+ Each metric can go from a scale from low to high: +

+
+
+
Low
+
Description of low
+
+
+
Medium
+
Description
+
+
+
High
+
Description
+
+
+
+ + + + + Metric + Description + + Weight + + + + + {SCORECARD_METRICS.map((metric) => ( + + + {metric.name} + + + { + SCORECARD_PRIORITIZATION[ + metric.description as keyof typeof SCORECARD_PRIORITIZATION + ] + } + + + {metric.weight} + + + ))} + +
+
+
+ + +

+ This table provides an overview of the most significant cost + components for typical blue carbon projects, categorized by + country, ecosystem, and activity. This table enables easy + comparison of these essential cost components. +

+
+
+

Implementation labor

+

+ {KEY_COSTS.IMPLEMENTATION_LABOR} +

+
+
+

+ Community benefit sharing fund +

+

+ {KEY_COSTS.COMMUNITY_BENEFIT_SHARING_FUND} +

+
+
+
+
+ +
From abd756bc17188f536c9a44e2de9ce6b506cfcf55 Mon Sep 17 00:00:00 2001 From: onehanddev Date: Tue, 3 Dec 2024 14:47:42 +0530 Subject: [PATCH 2/6] fix: addressed PR comments --- client/src/components/ui/info-button.tsx | 8 +++----- client/src/containers/overview/table/toolbar/index.tsx | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/client/src/components/ui/info-button.tsx b/client/src/components/ui/info-button.tsx index a1642f30..9b68067f 100644 --- a/client/src/components/ui/info-button.tsx +++ b/client/src/components/ui/info-button.tsx @@ -3,8 +3,6 @@ import * as React from "react"; import { InfoIcon } from "lucide-react"; -import { cn } from "@/lib/utils"; - import { Button } from "@/components/ui/button"; import { Dialog, @@ -18,10 +16,10 @@ import { export default function InfoButton({ title, children, - classNames, + className, }: PropsWithChildren<{ title?: string; - classNames?: string; + className?: string; }>) { return ( @@ -30,7 +28,7 @@ export default function InfoButton({ - + {title && {title}} {children} diff --git a/client/src/containers/overview/table/toolbar/index.tsx b/client/src/containers/overview/table/toolbar/index.tsx index 446c84e9..d68c5d11 100644 --- a/client/src/containers/overview/table/toolbar/index.tsx +++ b/client/src/containers/overview/table/toolbar/index.tsx @@ -67,7 +67,7 @@ export default function ToolbarProjectsTable() {
- +
Date: Tue, 3 Dec 2024 15:58:55 +0530 Subject: [PATCH 3/6] fix: added scrollbar, added new content for key costs table, design fixes --- .../overview/table/toolbar/index.tsx | 243 ++++++++++++------ 1 file changed, 159 insertions(+), 84 deletions(-) diff --git a/client/src/containers/overview/table/toolbar/index.tsx b/client/src/containers/overview/table/toolbar/index.tsx index d68c5d11..c85818e2 100644 --- a/client/src/containers/overview/table/toolbar/index.tsx +++ b/client/src/containers/overview/table/toolbar/index.tsx @@ -13,6 +13,7 @@ import { TableCell, } from "@/components/ui/table"; import { Tabs, TabsList, TabsTrigger, TabsContent } from "@/components/ui/tabs"; +import { ScrollArea } from "@/components/ui/scroll-area"; interface ScorecardMetric { name: string; @@ -20,6 +21,11 @@ interface ScorecardMetric { weight: number; } +interface KeyCost { + name: string; + description: string | keyof typeof KEY_COSTS; +} + const SCORECARD_METRICS: ScorecardMetric[] = [ { name: "Economic feasibility", @@ -61,6 +67,38 @@ const SCORECARD_METRICS: ScorecardMetric[] = [ }, ]; +const KEY_COSTS_DATA: KeyCost[] = [ + { + name: "Implementation labor", + description: "IMPLEMENTATION_LABOR", + }, + { + name: "Community benefit sharing fund", + description: "COMMUNITY_BENEFIT_SHARING_FUND", + }, + { + name: "Monitoring and maintenance", + description: "MONITORING_AND_MAINTENANCE", + }, + { + name: "Community representation/liaison", + description: "COMMUNITY_REPRESENTATION", + }, + { + name: "Conservation planning and admin", + description: + "Approximated as the salaries of a project manager and a program coordinator. 20% of the salaries is added to account for meetings/ expenses. 75% of these approximations are considered here and 25% of these costs are applied for community representation/ liaison", + }, + { + name: "Long-term project operating", + description: "LONG_TERM_OPERATING", + }, + { + name: "Carbon standard fees", + description: "CARBON_STANDARD_FEES", + }, +]; + export default function ToolbarProjectsTable() { return (
@@ -77,7 +115,7 @@ export default function ToolbarProjectsTable() { General @@ -105,7 +143,7 @@ export default function ToolbarProjectsTable() {

This table offers three distinct views, showcasing example @@ -118,7 +156,7 @@ export default function ToolbarProjectsTable() {

In addition to economic feasibility and abatement potential, @@ -148,98 +186,135 @@ export default function ToolbarProjectsTable() { value="scorecard" className="mt-4 h-full space-y-4 data-[state=inactive]:hidden" > -

-
-

- In addition to economic feasibility and abatement - potential, this table includes{" "} - - qualitative, non-economic scores - - , which may vary by country or ecosystem. Each - project's overall score combines these non-economic - scores with economic feasibility and abatement potential - to give a comprehensive evaluation. These scores add - additional insights for project assessment. -

-

- Each metric can go from a scale from low to high: -

-
-
-
Low
-
Description of low
-
-
-
Medium
-
Description
-
-
-
High
-
Description
+ +
+
+

+ In addition to economic feasibility and abatement + potential, this table includes{" "} + + qualitative, non-economic scores + + , which may vary by country or ecosystem. Each + project's overall score combines these + non-economic scores with economic feasibility and + abatement potential to give a comprehensive + evaluation. These scores add additional insights for + project assessment. +

+

+ Each metric can go from a scale from low to high: +

+
+
+
Low
+
Description of low
+
+
+
Medium
+
Description
+
+
+
High
+
Description
+
-
- - - - Metric - Description - - Weight - - - - - {SCORECARD_METRICS.map((metric) => ( - - - {metric.name} - - - { - SCORECARD_PRIORITIZATION[ - metric.description as keyof typeof SCORECARD_PRIORITIZATION - ] - } - - - {metric.weight} - +
+ + + Metric + + Description + + + Weight + - ))} - -
-
+ + + {SCORECARD_METRICS.map((metric) => ( + + + {metric.name} + + + { + SCORECARD_PRIORITIZATION[ + metric.description as keyof typeof SCORECARD_PRIORITIZATION + ] + } + + + {metric.weight} + + + ))} + + +
+ -

- This table provides an overview of the most significant cost - components for typical blue carbon projects, categorized by - country, ecosystem, and activity. This table enables easy - comparison of these essential cost components. -

-
-
-

Implementation labor

-

- {KEY_COSTS.IMPLEMENTATION_LABOR} -

-
-
-

- Community benefit sharing fund -

-

- {KEY_COSTS.COMMUNITY_BENEFIT_SHARING_FUND} -

+ +
+
+

+ This table provides an overview of the most + significant cost components for typical blue carbon + projects, categorized by country, ecosystem, and + activity. This table enables easy comparison of these + essential cost components. +

+

+ Each metric is color coded depending on the minimum + range for each metric. +

+
+
+
+ Min value + Max value +
+
+
+ + + + + Metric + + Description + + + + + {KEY_COSTS_DATA.map((cost) => ( + + + {cost.name} + + + {typeof cost.description === "string" && + !KEY_COSTS[ + cost.description as keyof typeof KEY_COSTS + ] + ? cost.description + : KEY_COSTS[ + cost.description as keyof typeof KEY_COSTS + ]} + + + ))} + +
-
+
From a5006671b254b084f7d873e52ef0762e65a896e3 Mon Sep 17 00:00:00 2001 From: onehanddev Date: Tue, 3 Dec 2024 20:07:44 +0530 Subject: [PATCH 4/6] fix: scroll issue for info modal --- client/src/containers/overview/table/toolbar/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/containers/overview/table/toolbar/index.tsx b/client/src/containers/overview/table/toolbar/index.tsx index c85818e2..fcc285c1 100644 --- a/client/src/containers/overview/table/toolbar/index.tsx +++ b/client/src/containers/overview/table/toolbar/index.tsx @@ -140,7 +140,7 @@ export default function ToolbarProjectsTable() {
-
+
Date: Tue, 3 Dec 2024 20:08:17 +0530 Subject: [PATCH 5/6] fix: lint --- client/src/containers/overview/table/toolbar/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/containers/overview/table/toolbar/index.tsx b/client/src/containers/overview/table/toolbar/index.tsx index fcc285c1..509afda8 100644 --- a/client/src/containers/overview/table/toolbar/index.tsx +++ b/client/src/containers/overview/table/toolbar/index.tsx @@ -4,6 +4,7 @@ import SearchProjectsTable from "@/containers/overview/table/toolbar/search"; import TabsProjectsTable from "@/containers/overview/table/toolbar/table-selector"; import InfoButton from "@/components/ui/info-button"; +import { ScrollArea } from "@/components/ui/scroll-area"; import { Table, TableHeader, @@ -13,7 +14,6 @@ import { TableCell, } from "@/components/ui/table"; import { Tabs, TabsList, TabsTrigger, TabsContent } from "@/components/ui/tabs"; -import { ScrollArea } from "@/components/ui/scroll-area"; interface ScorecardMetric { name: string; From b921c5ab19a29c9d52a8cc76eed22a7c713e0db5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Gonz=C3=A1lez=20Mu=C3=B1oz?= Date: Tue, 3 Dec 2024 17:08:59 +0100 Subject: [PATCH 6/6] minor styling updates --- client/src/components/ui/dialog.tsx | 2 +- client/src/constants/tooltip.tsx | 21 ++++++++++++++++--- .../overview/table/toolbar/index.tsx | 20 ++++++++++-------- 3 files changed, 30 insertions(+), 13 deletions(-) diff --git a/client/src/components/ui/dialog.tsx b/client/src/components/ui/dialog.tsx index a62d3271..1a8b3919 100644 --- a/client/src/components/ui/dialog.tsx +++ b/client/src/components/ui/dialog.tsx @@ -39,7 +39,7 @@ const DialogContent = React.forwardRef< +
    +
  • + Monitoring: The expenses related to individuals moving throughout the + project site to prevent degradation and report necessary + actions/changes. +
  • +
  • + Maintenance: Only applicable to restoration. The costs associated with + the physical upkeep of the original implementation, such as pest + control, removing blockages, and rebuilding small portions. +
  • +
  • +
+ + ), COMMUNITY_REPRESENTATION: "Efforts aimed at obtaining community buy-in, including assessing community needs, obtaining free, prior, and informed consent, conducting stakeholder surveys, and providing education about blue carbon.", CONSERVATION_PLANNING: diff --git a/client/src/containers/overview/table/toolbar/index.tsx b/client/src/containers/overview/table/toolbar/index.tsx index 509afda8..1cfcf14d 100644 --- a/client/src/containers/overview/table/toolbar/index.tsx +++ b/client/src/containers/overview/table/toolbar/index.tsx @@ -1,3 +1,5 @@ +import { cn } from "@/lib/utils"; + import { SCORECARD_PRIORITIZATION, KEY_COSTS } from "@/constants/tooltip"; import SearchProjectsTable from "@/containers/overview/table/toolbar/search"; @@ -99,42 +101,42 @@ const KEY_COSTS_DATA: KeyCost[] = [ }, ]; +const TABS_TRIGGER_CLASSES = + "border-b-2 border-transparent transition-colors data-[state=active]:!border-sky-blue-300 data-[state=active]:bg-transparent"; + export default function ToolbarProjectsTable() { return (
- +
- + General Overview table Scorecard prioritization table - + Key costs table