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

Improved Az and El display for ATDome MTDome and TMA #414

Merged
merged 3 commits into from
Dec 20, 2022

Conversation

MiaRoseElbo
Copy link
Contributor

This PR contains improvements for Az and EL displays for ATDome, MTDome and TMA.

Created a new Elevation and Azimuth General Purpose components instanced in both the AT and MT Dome components and in the TMA component.

Created a unique Az display for the TMA.

render() {
const { className, height, width, currentValue, targetValue, radius, valueOrigin, displayLabels } = this.props;

//const {currentValue, targetValue} = this.state;
Copy link
Contributor

Choose a reason for hiding this comment

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

this line should be removed


>

{/* Ritate Center */}
Copy link
Contributor

Choose a reason for hiding this comment

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

this should be Rotate

className={styles.targetText}
>
<text
//transform={`${"translate("+currentText_X+" "+currentText_Y+")"}`}
Copy link
Contributor

@sebastian-aranda sebastian-aranda Dec 12, 2022

Choose a reason for hiding this comment

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

this line should be removed

Comment on lines 45 to 56
setInterval(() => {
const randomValue = Math.ceil(Math.random()*360)

this.setState((prevState) => ({
...prevState,targetValue: randomValue
}))

setTimeout(() => console.log(this.setState((prevState) => ({
...prevState,currentValue: randomValue
}))), 2500);

}, 5000);
Copy link
Contributor

@sebastian-aranda sebastian-aranda Dec 12, 2022

Choose a reason for hiding this comment

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

I think these lines should be removed as they are only setting random values

Comment on lines 61 to 72
setInterval(() => {
const randomValue = Math.ceil(Math.random()*130-20)

this.setState((prevState) => ({
...prevState,targetValue: randomValue
}))

setTimeout(() => console.log(this.setState((prevState) => ({
...prevState,currentValue: randomValue
}))), 2500);

}, 5000);
Copy link
Contributor

Choose a reason for hiding this comment

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

As explained above, this should be removed too

transform={`${"rotate("+(currentValue*-1)+")"}`}
>
<text
//transform={`${"translate("+currentText_X+" "+currentText_Y+")"}`}
Copy link
Contributor

Choose a reason for hiding this comment

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

this line should be removed

Comment on lines 65 to 76
setInterval(() => {
const randomValue = Math.ceil((Math.random()*((2*270))-270))

this.setState((prevState) => ({
...prevState,targetValue: randomValue
}))

setTimeout(() => console.log(this.setState((prevState) => ({
...prevState,currentValue: randomValue
}))), 2500);

}, 5000);
Copy link
Contributor

Choose a reason for hiding this comment

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

As explained above these lines should be removed too

render() {
const {currentValue, targetValue, height, maxL3, maxL2, maxL1, minL1, minL2, minL3, radius, rotationOffset, displayLabels } = this.props;

//const {currentValue, targetValue} = this.state;
Copy link
Contributor

Choose a reason for hiding this comment

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

this line should be removed

Copy link
Contributor

@sebastian-aranda sebastian-aranda left a comment

Choose a reason for hiding this comment

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

Really nice job @MiaRoseElbo 👏. I've left a few minor comments.

Copy link
Contributor

@sebastian-aranda sebastian-aranda left a comment

Choose a reason for hiding this comment

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

Nice job @MiaRoseElbo . This is ready to merge 👍️

@MiaRoseElbo MiaRoseElbo merged commit e9bcc28 into develop Dec 20, 2022
@sebastian-aranda sebastian-aranda deleted the tickets/LOVE-126 branch December 20, 2022 13:44
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.

2 participants