-
Notifications
You must be signed in to change notification settings - Fork 6
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
[#8752] Add kiezradar filter options on project overview #6057
Conversation
2f158e8
to
3db626f
Compare
a186345
to
e32c5ae
Compare
e4b8698
to
5460fac
Compare
74c1082
to
c68a986
Compare
import { classNames } from 'adhocracy4' | ||
import useCombobox from 'adhocracy4/adhocracy4/static/forms/useCombobox' | ||
|
||
export const GroupMultiSelect = ({ |
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 help with the multiselect, @hom3mad3. It was quite different from the existing MultiSelect
component, so created a new GroupMultiSelect
component.
c68a986
to
a59a173
Compare
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 good, thank you 🫶🏼
09dfe84
to
ca598d7
Compare
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.
LGTM, thanks for the work! Just one remark
<ul className="a4-combo-box__group-dropdown"> | ||
{choices.map((choice) => { | ||
const { active, focused, ...attrs } = getChoicesAttr(choice) | ||
const liClasses = classNames( | ||
liClassName, | ||
'a4-combo-box__option', | ||
active && 'a4-combo-box__option--active', | ||
focused && 'a4-combo-box__option--focus' | ||
) | ||
|
||
return ( | ||
<li key={choice.value} className={liClasses} {...attrs}> | ||
<span>{choice.name}</span> | ||
{active && ( | ||
<i className="bicon bicon-check" aria-hidden="true" /> | ||
)} | ||
</li> | ||
) | ||
})} | ||
</ul> |
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.
This generates an empty list if there are no items. Can you wrap it in an if
?
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.
@vellip thanks for finding this...
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, this is now changed 👍
ca598d7
to
17c263a
Compare
Describe your changes
This PR adds kiezradars as filter options on the project overview.
Tasks