Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
9783832
build(deps): bump ajv
dependabot[bot] Feb 22, 2026
37b4d1b
Merge pull request #730 from RMI/dependabot/npm_and_yarn/multi-73726a…
AlexAxthelm Feb 23, 2026
ebd8dc6
build(deps): bump the minor-and-patch group across 1 directory with 9…
dependabot[bot] Feb 23, 2026
5b14bd3
Merge pull request #732 from RMI/dependabot/npm_and_yarn/minor-and-pa…
AlexAxthelm Feb 23, 2026
ac238d8
build(deps): bump actions/download-artifact from 7 to 8
dependabot[bot] Feb 27, 2026
98e865c
build(deps): bump actions/upload-artifact from 6 to 7
dependabot[bot] Feb 27, 2026
eb07320
Merge pull request #734 from RMI/dependabot/github_actions/actions/up…
AlexAxthelm Feb 27, 2026
f0c2dca
Merge pull request #733 from RMI/dependabot/github_actions/actions/do…
AlexAxthelm Feb 27, 2026
aa57e18
build(deps): bump rollup from 4.44.0 to 4.59.0
dependabot[bot] Feb 27, 2026
7eafea2
Merge pull request #735 from RMI/dependabot/npm_and_yarn/rollup-4.59.0
AlexAxthelm Feb 27, 2026
613893d
build(deps): bump the minor-and-patch group with 9 updates
dependabot[bot] Mar 2, 2026
821a2f4
Merge pull request #736 from RMI/dependabot/npm_and_yarn/minor-and-pa…
AlexAxthelm Mar 2, 2026
fffacbb
remove policyType direct policy and reclassify
jacobvjk Mar 3, 2026
9ab5c86
feat: remove pathwayType Direct Policy
jacobvjk Mar 3, 2026
9eb499c
Update src/data/README.md
jacobvjk Mar 3, 2026
761a876
update test to retain meaningful coverage
jacobvjk Mar 3, 2026
2214581
update classification
jacobvjk Mar 4, 2026
20b4a2b
Merge pull request #739 from RMI/production
AlexAxthelm Mar 4, 2026
fbf839f
Merge branch 'main' into update-pathway-type
AlexAxthelm Mar 4, 2026
e82f9eb
Merge pull request #738 from RMI/update-pathway-type
jacobvjk Mar 4, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/azure-static-web-apps-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
name: Build and Deploy Job
steps:
- uses: actions/download-artifact@v7
- uses: actions/download-artifact@v8
with:
name: dist-tgz

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/node-build_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ jobs:
# Reuse the artifact for downstream deploy
- name: Upload dist.tgz as workflow artifact
if: ${{ steps.check_artifact.outputs.has_artifact == 'true' }}
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: dist-tgz
path: dist.tgz
Expand Down
945 changes: 531 additions & 414 deletions package-lock.json

Large diffs are not rendered by default.

26 changes: 13 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,25 +31,25 @@
"author": "RMI",
"license": "MIT",
"dependencies": {
"ajv": "^8.17.1",
"ajv": "^8.18.0",
"ajv-formats": "^3.0.1",
"clsx": "^2.1.1",
"d3": "^7.9.0",
"i18n-iso-countries": "^7.14.0",
"json-schema-to-typescript": "^15.0.4",
"lucide-react": "^0.563.0",
"lucide-react": "^0.575.0",
"react": "^19.2.4",
"react-dom": "^19.2.4",
"react-markdown": "^10.1.0",
"react-router-dom": "^7.13.0",
"react-router-dom": "^7.13.1",
"rehype-external-links": "^3.0.0",
"vite-plugin-static-copy": "^3.2.0"
},
"devDependencies": {
"@eslint/js": "^9.39.2",
"@jirutka/ajv-cli": "^6.0.0",
"@semantic-release/exec": "^7.1.0",
"@tailwindcss/postcss": "^4.1.18",
"@tailwindcss/postcss": "^4.2.1",
"@tailwindcss/typography": "^0.5.19",
"@testing-library/jest-dom": "^6.9.1",
"@testing-library/react": "^16.3.2",
Expand All @@ -62,28 +62,28 @@
"@types/d3-shape": "^3.1.8",
"@types/d3-time-format": "^4.0.3",
"@types/d3-transition": "^3.0.9",
"@types/node": "^25.2.2",
"@types/react": "^19.2.13",
"@types/node": "^25.3.3",
"@types/react": "^19.2.14",
"@types/react-dom": "^19.2.3",
"@vitejs/plugin-react": "^5.1.3",
"autoprefixer": "^10.4.24",
"@vitejs/plugin-react": "^5.1.4",
"autoprefixer": "^10.4.27",
"chokidar-cli": "^3.0.0",
"conventional-changelog-conventionalcommits": "^9.1.0",
"conventional-changelog-conventionalcommits": "^9.2.0",
"cross-env": "^10.1.0",
"eslint": "^9.39.2",
"eslint-plugin-react": "^7.37.5",
"eslint-plugin-react-hooks": "^7.0.1",
"globals": "^17.3.0",
"globals": "^17.4.0",
"jiti": "^2.6.1",
"jsdom": "^28.0.0",
"jsdom": "^28.1.0",
"postcss": "^8.5.6",
"prettier": "^3.8.1",
"semantic-release": "^25.0.3",
"simple-git": "^3.30.0",
"simple-git": "^3.32.3",
"tailwindcss": "^4.1.7",
"ts-node": "^10.9.2",
"typescript": "^5.9.3",
"typescript-eslint": "^8.54.0",
"typescript-eslint": "^8.56.1",
"vite": "^7.3.1",
"vitest": "^4.0.18"
},
Expand Down
1 change: 0 additions & 1 deletion public/schema/pathwayMetadata.v1.html
Original file line number Diff line number Diff line change
Expand Up @@ -9296,7 +9296,6 @@ <h4>Must be one of:</h4>
<ul class="list-group">
<li class="list-group-item enum-item">"Normative"</li>
<li class="list-group-item enum-item">"Exploratory"</li>
<li class="list-group-item enum-item">"Direct Policy"</li>
<li class="list-group-item enum-item">"Predictive"</li>
</ul>
</div>
Expand Down
8 changes: 4 additions & 4 deletions src/components/Badge.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -222,17 +222,17 @@ describe("Badge component", () => {
);
});

it("displays correct tooltip for Policy pathway type", () => {
it("displays correct tooltip for Exploratory pathway type", () => {
render(
<Badge
tooltip={pathwayTypeTooltips["Direct Policy"]}
tooltip={pathwayTypeTooltips["Exploratory"]}
variant="pathwayType"
>
Direct Policy
Exploratory
</Badge>,
);

const badge = screen.getByText("Direct Policy");
const badge = screen.getByText("Exploratory");
expect(badge).toBeInTheDocument();
expect(badge.closest("span")?.parentElement).toHaveAttribute(
"tabindex",
Expand Down
1 change: 0 additions & 1 deletion src/components/SearchSection.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,6 @@ describe("SearchSection", () => {
openByLabel("Sector");

openByLabel("Pathway Type");
expect(screen.getByText("Direct Policy")).toBeInTheDocument();
expect(screen.getByText("Exploratory")).toBeInTheDocument();
expect(screen.getByText("Normative")).toBeInTheDocument();
expect(screen.getByText("Predictive")).toBeInTheDocument();
Expand Down
7 changes: 3 additions & 4 deletions src/components/StepByStepGuide.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,9 @@ const StepByStepGuide: React.FC<StepByStepGuideProps> = ({

const descriptions: Record<string, Record<string, string>> = {
pathwayType: {
"Direct Policy": "Sourced directly from policy frameworks",
"Exploratory": "Future states under explicit assumptions",
"Normative": "Pre-determined target outcome",
"Predictive": "Extrapolates from current trends",
Exploratory: "Future states under explicit assumptions",
Normative: "Pre-determined target outcome",
Predictive: "Extrapolates from current trends",
},
emissionsTrajectory: {
"Significant increase": "Grow more than 50% by 2050",
Expand Down
2 changes: 1 addition & 1 deletion src/data/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ new_pathway_metadata <-
id = "R-import-example",
name = "R Import Pathway",
description = "Pathway Imported from R",
pathwayType = "Direct Policy",
pathwayType = "Normative",
modelYearEnd = 2050,
modelTempIncrease = 1.5,
geography = list("Global", "US", "Europe"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"name": { "full": "Clean Energy Scenario 1", "short": "CES 1" },
"description": "Philippines pathway following National Renewable Energy Plan with some offshore wind development.",
"geography": ["PH"],
"pathwayType": "Direct Policy",
"pathwayType": "Exploratory",
"modelYearStart": 2023,
"modelYearEnd": 2050,
"sectors": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"name": { "full": "Clean Energy Scenario 2", "short": "CES 2" },
"description": "Philippines pathway following National Renewable Energy Plan. Significant offshore wind development.",
"geography": ["PH"],
"pathwayType": "Direct Policy",
"pathwayType": "Exploratory",
"modelYearStart": 2023,
"modelYearEnd": 2050,
"sectors": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"name": { "full": "Reference Scenario", "short": "Reference" },
"description": "Continuation of historical trends in the energy system in the Philippines.",
"geography": ["PH"],
"pathwayType": "Direct Policy",
"pathwayType": "Exploratory",
"modelYearStart": 2023,
"modelYearEnd": 2050,
"sectors": [
Expand Down
2 changes: 1 addition & 1 deletion src/data/un-sdsn-cw/SDSN-CW-BAU-SG-2024.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
},
"description": "Singapore-specific pathway reflecting existing policy commitments and government targets.",
"geography": ["SG"],
"pathwayType": "Direct Policy",
"pathwayType": "Predictive",
"modelYearStart": 2023,
"modelYearEnd": 2050,
"ssp": "SSP2",
Expand Down
2 changes: 1 addition & 1 deletion src/schema/pathwayMetadata.v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"pathwayType": {
"description": "Type of the pathway pathway.",
"type": "string",
"enum": ["Normative", "Exploratory", "Direct Policy", "Predictive"]
"enum": ["Normative", "Exploratory", "Predictive"]
},
"modelYearNetzero": {
"description": "Year by which net zero is reached in the pathway. If Pathway does not reach net zero, this field should be omitted.",
Expand Down
2 changes: 1 addition & 1 deletion src/types/pathwayMetadata.v1.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export interface PathwayMetadataV1 {
/**
* Type of the pathway pathway.
*/
pathwayType: "Normative" | "Exploratory" | "Direct Policy" | "Predictive";
pathwayType: "Normative" | "Exploratory" | "Predictive";
/**
* Year by which net zero is reached in the pathway. If Pathway does not reach net zero, this field should be omitted.
*/
Expand Down
7 changes: 3 additions & 4 deletions src/utils/searchUtils.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ describe("filterPathways (array-backed facets)", () => {
sectors: [{ name: "Power" }],
geography: ["Europe"],
modelTempIncrease: 2.0,
pathwayType: "Direct Policy",
pathwayType: "Normative",
modelYearNetzero: 2040,
publisher: "X",
publicationYear: 2020,
Expand All @@ -255,7 +255,7 @@ describe("filterPathways (array-backed facets)", () => {

it("pathwayType: OR over multiple selections; empty array = no filter", () => {
let out = filterPathways(pathways, {
pathwayType: ["Direct Policy", "Exploratory"],
pathwayType: ["Normative", "Exploratory"],
} as FiltersWithArrays);
expect(out.map((s) => s.id)).toEqual(["B", "C"]);

Expand Down Expand Up @@ -492,11 +492,10 @@ describe("getGlobalFacetOptions", () => {

// pathwayTypeOptions should be in expected order
const pathwayTypeLabels = pathwayTypeOptions.map((opt) => opt.label);
expect(pathwayTypeLabels.slice(0, 4)).toEqual([
expect(pathwayTypeLabels.slice(0, 3)).toEqual([
"Predictive",
"Exploratory",
"Normative",
"Direct Policy",
]);
});

Expand Down
5 changes: 0 additions & 5 deletions src/utils/sortUtils.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,13 @@ describe("sortPathwayType", () => {
const arr = [
{ title: "Normative" },
{ title: "Predictive" },
{ title: "Direct Policy" },
{ title: "Exploratory" },
];
const sorted = sortPathwayType(arr);
expect(sorted.map((x) => x.title)).toEqual([
"Predictive",
"Exploratory",
"Normative",
"Direct Policy",
]);
});

Expand All @@ -22,13 +20,11 @@ describe("sortPathwayType", () => {
{ title: "Normative" },
{ title: "UnknownType" },
{ title: "Predictive" },
{ title: "Direct Policy" },
];
const sorted = sortPathwayType(arr);
expect(sorted.map((x) => x.title)).toEqual([
"Predictive",
"Normative",
"Direct Policy",
"UnknownType",
]);
// UnknownType is last
Expand All @@ -43,7 +39,6 @@ describe("sortPathwayType", () => {
const arr = [
{ title: "Normative" },
{ title: "Predictive" },
{ title: "Direct Policy" },
{ title: "Exploratory" },
];
const arrCopy = [...arr];
Expand Down
7 changes: 1 addition & 6 deletions src/utils/sortUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,7 @@ export const prioritizeGeographies = (
};

// Utility for sorting pathway types according to a fixed order
export const pathwayTypeOrder = [
"Predictive",
"Exploratory",
"Normative",
"Direct Policy",
];
export const pathwayTypeOrder = ["Predictive", "Exploratory", "Normative"];

export function sortPathwayType<T extends { title: string }>(arr: T[]): T[] {
return arr.slice().sort((a, b) => {
Expand Down
8 changes: 3 additions & 5 deletions src/utils/tooltipUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,9 @@ import type {
export const unknownTooltip = "No tooltip available.";

export const pathwayTypeTooltips: Record<PathwayType, string> = {
"Direct Policy":
"Outcomes based on legislated policy targets or commitments.",
"Exploratory": "Examines a range of plausible futures without fixed goals.",
"Normative": "Starts from a desired end state and works backward to actions.",
"Predictive":
Exploratory: "Examines a range of plausible futures without fixed goals.",
Normative: "Starts from a desired end state and works backward to actions.",
Predictive:
"Projects likely futures based on current trends and assumptions.",
};

Expand Down
2 changes: 1 addition & 1 deletion testdata/valid/pathwayMetadata_sample_03.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"year": 2024
},
"description": "Third Sample Pathway. asdf description.",
"pathwayType": "Direct Policy",
"pathwayType": "Normative",
"modelTempIncrease": 3,
"ssp": "SSP3",
"geography": ["North America"],
Expand Down