-
Notifications
You must be signed in to change notification settings - Fork 75
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
Create Volumetric Task #7227
base: master
Are you sure you want to change the base?
Create Volumetric Task #7227
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
import PropTypes from "prop-types"; | ||
import React from "react"; | ||
import GenericTaskEditor from "../generic-editor"; | ||
|
||
export default class VolumetricTask extends React.Component { | ||
constructor(props) { | ||
super(props); | ||
} | ||
render() { | ||
return <div>{"VolumetricTask Tool"}</div>; | ||
} | ||
} | ||
|
||
VolumetricTask.Editor = GenericTaskEditor; | ||
|
||
VolumetricTask.getDefaultTask = () => ({ | ||
help: "", | ||
instruction: "Describe how to use this tool", | ||
type: "volumetric", | ||
}); | ||
|
||
VolumetricTask.getTaskText = (task) => task.instruction; | ||
|
||
VolumetricTask.getDefaultAnnotation = () => ({ _toolIndex: 0, value: [] }); | ||
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. Does this task annotation actually use |
||
|
||
VolumetricTask.defaultProps = { | ||
showRequiredNotice: false, | ||
task: { | ||
help: "", | ||
type: "volumetric", | ||
instruction: "Describe how to use this tool", | ||
kieftrav marked this conversation as resolved.
Show resolved
Hide resolved
|
||
}, | ||
workflow: { | ||
tasks: [], | ||
}, | ||
Comment on lines
+31
to
+33
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. Query: what's the If we're following the same Task pattern in PFE, then this parameter isn't required. We only really need (In practice, it double doesn't matter, since this Task shouldn't be working in PFE. 🤔 ) 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. Awesome - thank you for the context. Removed. |
||
}; | ||
|
||
VolumetricTask.propTypes = { | ||
showRequiredNotice: PropTypes.bool, | ||
task: PropTypes.shape({ | ||
help: PropTypes.string, | ||
instruction: PropTypes.string, | ||
required: PropTypes.bool, | ||
tools: PropTypes.array, | ||
type: PropTypes.string, | ||
}), | ||
workflow: PropTypes.shape({ | ||
tasks: PropTypes.object, | ||
}), | ||
}; | ||
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. Query: are 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. Removed - didn't need them. |
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.
[minor] This could be a bit more descriptive. e.g. "This is a placeholder for the Volumetric Task, which is only supposed to work on the FEM Classifier."
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.
Agreed and implemented.