-
Notifications
You must be signed in to change notification settings - Fork 30
feat: add weeds and compost #311
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
35 commits
Select commit
Hold shift + click to select a range
0d5e470
feat: add weeds and compost
lstebner c92808e
updates based on feedback
lstebner 6e95990
remove fertilizer from items in favor of one in recipes
lstebner 724f4c4
fixing some references to items.fertilizer since it is now part of re…
lstebner 172722a
add field to saveDataStubFactory
lstebner 5a27de1
remove type COMPOST
lstebner 159e671
change WEEDS to WEED
lstebner b4eed15
change composter name to 'Basic' and change export to be inline
lstebner dac5556
change weeds to weed
lstebner 2583b13
more code review feedback updates
lstebner 6b7d09e
categorize weeds in new Foraged Items category and associated recipes…
lstebner c03b15b
add some variety to weed image and remove original one
lstebner a42cf79
jsdoc
lstebner d572730
fix fertilizer image not showing in workshop, change compost recipe i…
lstebner 140c9e0
update mock for RECYCLING
lstebner 5a02753
spec fix
lstebner b0878a6
fix more specs
lstebner 9b82a13
some tests for weed scenario in harvestPlot
lstebner 1f493b1
change default weed image to pink weed
lstebner c0d7d8f
add purchaseComposter tests
lstebner 64a5675
add tests for purchaseSmelter
lstebner 6d96ae6
add description for compost
lstebner 54086a5
fix string casing and add recycling tests to Workshop
lstebner 3235c17
add some missing piskel files for images
lstebner 33d7d91
Update src/game-logic/reducers/purchaseSmelter.test.js
lstebner 99fdcaa
add wasJustShoveled to plotContents when mined
lstebner 760bcb4
fix: update clearPlot to handle weeds
jeremyckahn ba36404
update specs for wasJustShoveled changes
lstebner 06a5b1f
slightly simpler way to write this bit
lstebner e8f48b4
add compost piskel file
lstebner e7908c4
fix: update JSDoc
jeremyckahn e830fad
fix: prevent shoveled plot animations from replaying
jeremyckahn 8cf4ccd
refactor: remove wasJustShoveled from farmhand.crop typedef
jeremyckahn bc9e211
refactor: rename resetWasShoveled to updatePlotShoveledState
jeremyckahn e7aef69
refactor: rename isRipe to canBeHarvested
jeremyckahn File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
import React from 'react' | ||
import PropTypes from 'prop-types' | ||
|
||
import Card from '@material-ui/core/Card' | ||
import CardContent from '@material-ui/core/CardContent' | ||
import Divider from '@material-ui/core/Divider' | ||
import ReactMarkdown from 'react-markdown' | ||
|
||
import { recipeType } from '../../enums' | ||
|
||
import { recipeCategories } from '../../data/maps' | ||
|
||
import { TabPanel } from './TabPanel' | ||
import { RecipeList } from './RecipeList' | ||
|
||
export function RecyclingTabPanel({ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nice! 😁 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this was so easy thanks to the panel refactors done recently. very glad i did that 😄 |
||
currentTab, | ||
index, | ||
learnedRecipes, | ||
setCurrentTab, | ||
}) { | ||
return ( | ||
<TabPanel value={currentTab} index={index}> | ||
<RecipeList | ||
learnedRecipes={learnedRecipes} | ||
allRecipes={recipeCategories[recipeType.RECYCLING]} | ||
/> | ||
<Divider /> | ||
<ul className="card-list"> | ||
<li> | ||
<Card> | ||
<CardContent> | ||
<ReactMarkdown | ||
{...{ | ||
linkTarget: '_blank', | ||
className: 'markdown', | ||
source: `Recyling recipes are learned by selling items foraged from the field.`, | ||
}} | ||
/> | ||
</CardContent> | ||
</Card> | ||
</li> | ||
</ul> | ||
</TabPanel> | ||
) | ||
} | ||
|
||
RecyclingTabPanel.propTypes = { | ||
currentTab: PropTypes.number.isRequired, | ||
index: PropTypes.number.isRequired, | ||
learnedRecipes: PropTypes.array.isRequired, | ||
setCurrentTab: PropTypes.func.isRequired, | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch!