-
Notifications
You must be signed in to change notification settings - Fork 334
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
General purpose search form component #2184
Comments
Doesn't https://github.com/silverstripe/silverstripe-asset-admin/blob/1/client/src/components/Search/Search.js already a cover lot of the points in the acceptance critera? I'm thinking I might be better moving it under admin and working from there. |
The asset admin search components looks like this right now: <Search
onSearch={this.handleDoSearch}
id="AssetSearchForm"
searchFormSchemaUrl={searchFormSchemaUrl}
filters={filters}
formData={{}}
/>
I would tweak things this way. <Search
onSearch={this.handleDoSearch}
onClear={this.clear}
onShowFilters={this.showFilter}
onHideFilters={this.showFilter}
onShow={this.showSearch}
onHide={this.hideSearch}
show={true}
hiddeable={false}
showFilters={true}
toggable={true}
placeholder={searchTerm}
id="RandomSearchForm"
formSchemaUrl={searchFormSchemaUrl}
filters={filters}
formData={{}}
/>
Edit On second thought, I'll merge |
Yeah finally got it over line. Here's what it looks like. https://youtu.be/xNFkyLOgrzg |
Looks awesome! Does the content area need a loading indicator to prevent the search button from rendering half way off the container? 😛 |
I've made some adjustments based on @clarkepaul's feedback: https://youtu.be/eAyTQYW-kXM
Getting the switch between the [enter] hint and clear button ended up being a bit of a mission, because I had to track if the search form was dirty and make sure it got reset to pristine on search. The The clear button will show if there's data to clear and if the enter hint is not showing. edit |
Looks great, those Youtube previews are super helpful for low friction review. Great to see the pattern library being actively used as well |
Functionality is working great :), do we have control over how the search suggested results appears? |
The suggested results you see in the vid is just the browser's native auto-suggest features. It remembers values you posted in the form previously and will offer them to you again. We could use |
@lukereative and I had a catch up with @newleeland today. That should be be last changes to this guy ... fingers crossed. Here's what's been changed
|
Parent story: #1777
Acceptance Criteria
Notes
Tasks
Pull requests
Related PRs
The text was updated successfully, but these errors were encountered: