Skip to content
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

Implementation of #101 - Close comparison buttons #123

Merged
merged 22 commits into from
Jun 22, 2021
Merged

Implementation of #101 - Close comparison buttons #123

merged 22 commits into from
Jun 22, 2021

Conversation

ScoutAtlas
Copy link
Collaborator

No description provided.

IremToroslu and others added 6 commits June 18, 2021 09:56
regarding the #101

Co-authored-by: Julian Oelhaf <julian.oelhaf@posteo.de>
Expanded state of DetailsComponent to have three variables for each possible state
Made close buttons switch stats
Made DetailsComponent switch content depending on the state
Regarding #101

Co-authored-by: Irem Toroslu <irem.toroslu@fau.de>
structured and resized the navbar and the navbar icons
fontsizes and fontweight changed.
regarding the #101

Co-authored-by: Julian Oelhaf <julian.oelhaf@posteo.de>
Commented the changes made in the previous commit
Documented the new functionality
Regarding #101

Co-authored-by: Irem Toroslu <irem.toroslu@fau.de>
Copy link
Collaborator

@Waldleufer Waldleufer left a comment

Choose a reason for hiding this comment

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

I suggest we refactor the navbar somehow. Else looking good, and Close buttons work as expected. 🎉

frontend/src/components/details/DetailsComponent.js Outdated Show resolved Hide resolved
@@ -71,7 +96,8 @@ class DetailsComponent extends Component {

// postCalculationRequest(selectedProduct.productID);

if (!this.state.loadComparePage) {
if (this.state.baselineScenario) {
// if state equals baseline scenario only
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think if you really want an XOR you should maybe change this. Because

const baselineScenario = true;
const modifiedScenario = true;
const loadComparePage = true;

Would also activate this case e.g.

Copy link
Collaborator

Choose a reason for hiding this comment

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

The way it is rn: baselineScenario has top priority, then modified then loadCompare page. Intended?

Copy link
Collaborator

Choose a reason for hiding this comment

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

I really like how it is done btw :D

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yeah, we haven't given it too much thought what should be top priority, because in reality if all three are true, then we have a problem :)

frontend/src/components/details/NavbarComponent.js Outdated Show resolved Hide resolved
frontend/src/components/details/NavbarComponent.js Outdated Show resolved Hide resolved
frontend/src/components/details/NavbarComponent.js Outdated Show resolved Hide resolved
Copy link
Collaborator

@manifau manifau left a comment

Choose a reason for hiding this comment

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

Nice work :)
At the comparison view, there is one button for every scenario and on clicking this Button, the corresponding scenario is closed !!

regarding the #101

close , add and export buttons resized
close button text removed and restructured and a real close button
Copy link
Collaborator

@Waldleufer Waldleufer left a comment

Choose a reason for hiding this comment

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

Looks good to me 👍 🙂

frontend/src/components/details/NavbarComponent.js Outdated Show resolved Hide resolved
Put <a> in <div> to align them dynamically.
@Waldleufer Waldleufer merged commit 7926a1e into dev Jun 22, 2021
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.

4 participants