-
Notifications
You must be signed in to change notification settings - Fork 90
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
feat: Add an Operator Selector to data-research page #444
Conversation
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.
Thanks for your contribution!
The code looks great- just please try to separate the data layer from the UI layer. having all
come from the data getter could be confusing for future developers
src/model/operator.ts
Outdated
const allOperators = Array.from( | ||
agencyList.map((agency) => ({ | ||
name: agency.agency_name, | ||
id: agency.operator_ref.toString(), | ||
})), | ||
) | ||
allOperators.push({ name: 'הכל', id: '' }) |
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.
why do we need the הכל
here?
const allOperators = Array.from( | |
agencyList.map((agency) => ({ | |
name: agency.agency_name, | |
id: agency.operator_ref.toString(), | |
})), | |
) | |
allOperators.push({ name: 'הכל', id: '' }) | |
const allOperators = agencyList.map((agency) => ({ | |
name: agency.agency_name, | |
id: agency.operator_ref.toString(), | |
})) | |
allOperators.push({ name: 'הכל', id: '' }) |
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.
Changed, Thanks! (assumed the problem with adding this in this function doesn't fit the function name?)
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.
Thanks! It's also about the data model should not be aware of the UI options
…s-map-search into add-operator-selector
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.
Looks great! thanks for adding a story
Add the selection option of operators on the research page