Skip to content

Conversation

@meganrm
Copy link
Contributor

@meganrm meganrm commented Nov 4, 2025

Problem

closes #117

Solution

added a recipe to the default state

I also removed the recipe display name from the store and am now only using the id as an identification. The only place the name shows up is in the dropdown

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

Change summary:

  • Tidy, well formulated commit message
  • Another great commit message
  • Something else I/we did

Steps to Verify:

  1. bun dev
  2. the peroxisome recipe should be selected

@github-actions
Copy link

github-actions bot commented Nov 4, 2025

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 21.39% 365 / 1706
🔵 Statements 21.39% 365 / 1706
🔵 Functions 40.35% 23 / 57
🔵 Branches 71.42% 80 / 112
File Coverage
File Stmts % Branch % Funcs % Lines Uncovered Lines
Changed Files
src/components/Dropdown/index.tsx 0% 0% 0% 0% 1-2, 12-17, 19-26, 28, 30
src/components/PackingInput/index.tsx 0% 0% 0% 0% 1-2, 15-19, 29-35, 37-41, 43-46, 49-51, 53-55, 57-61, 63-65, 67-91, 93, 95
src/state/store.ts 0% 0% 0% 0% 1, 50, 52-58, 60-62, 64-72, 74-89, 91-92, 94-114, 116-118, 120-122, 124-127, 129-144, 146-148, 150-151, 153-160, 162-164, 166-169, 171-185, 187-199, 201-217, 220-232, 235-247
src/types/index.ts 100% 100% 100% 100%
src/utils/firebase.ts 27.51% 62.5% 26.66% 27.51% 33-34, 39-40, 74-76, 79-89, 92-96, 99-107, 111-124, 127-132, 135-137, 140-164, 167-188, 202-203, 206-216, 218-227, 229, 231-235, 237-242
Generated in workflow #108

@github-actions
Copy link

github-actions bot commented Nov 4, 2025

PR Preview Action v1.6.2
Preview removed because the pull request was closed.
2025-11-05 22:58 UTC

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements autoselection of a default recipe ("peroxisome_v_gradient_packing") on application load. The implementation changes the recipe identification system from using display names to recipe IDs as the primary identifier throughout the application.

Key changes:

  • Recipe selection now uses recipe IDs instead of display names as the primary identifier
  • Default recipe is automatically selected in the initial state
  • Display names are preserved for UI presentation in the dropdown

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/utils/firebase.ts Refactored getPackingInputsDict to use recipe IDs as dictionary keys instead of names; code formatting improvements
src/types/index.ts Added optional name field to PackingInputs type; formatting fixes
src/state/store.ts Removed selectedInputName state, replaced with recipe ID-based selection; set default recipe ID; renamed selectInput to selectRecipe
src/components/PackingInput/index.tsx Updated to use selectRecipe action and pass defaultValue to Dropdown
src/components/Dropdown/index.tsx Modified to display names from PackingInputs and use recipe IDs as values

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@meganrm meganrm requested a review from interim17 November 4, 2025 22:00
@meganrm meganrm merged commit cbb4226 into main Nov 5, 2025
2 checks passed
@meganrm meganrm deleted the feature/autoselect branch November 5, 2025 22:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

a recipe should be auto selected when you arrive at the site

5 participants