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

Create component "filter by section" #286

Closed
plutonik-a opened this issue Nov 10, 2017 · 5 comments
Closed

Create component "filter by section" #286

plutonik-a opened this issue Nov 10, 2017 · 5 comments

Comments

@plutonik-a
Copy link
Contributor

plutonik-a commented Nov 10, 2017

  • Toggle between entire search or selected sections:
    a. Option "Entire Office of The Historian Website"
    b. Option Group with all Website Sections as a list
  • Selecting option a selects also all options b.
  • Deselecting option a leaves all options b selected.
  • Single options in b can be deselected.
  • If the last item of option b is deselected, all options a and b will be selected entirely.
  • If the section "Historical Documents" is selected, show the filter component "Filter By Date".

Component in search page:
bildschirmfoto 2017-11-10 um 15 27 17

Component in results page:
bildschirmfoto 2017-11-13 um 13 12 50


Update: from #284 (comment)

  • Text-color should be default text-color instead of link-color
  • Display amount of hits next to the option (on the results page)
  • "More Sections" instead of "Show more"

URL: https://history.state.gov/search
Template: pages/search/index.html
Parent: #284
Dependent on: #287

@plutonik-a plutonik-a changed the title Create component for "filter by section" Create component "filter by section" Nov 10, 2017
@plutonik-a plutonik-a added this to the 2.1 FRUS Advanced search milestone Nov 13, 2017
@joewiz
Copy link
Member

joewiz commented Nov 13, 2017

Regarding this point:

If the section "Historical Documents" is selected, show the filter component "Filter By Date".

We hope it's possible to "gray out" the "Filter By Date" component, rather than hide it.

plutonik-a added a commit that referenced this issue Nov 16, 2017
* update form markup
* rename classnames and IDs in forms for filters, main search form,
navigation search form and main search button
* create sidebar markup
* create reset filters button
* add event listeners to all search buttons
plutonik-a added a commit that referenced this issue Nov 20, 2017
* refactor code into template include file
* remove „filter volumes“ code from search landing page and move into
seperate include file „_filte-volumes.html“
* add styling to sections list: move sub-sections to the right like a
nested list
@plutonik-a
Copy link
Contributor Author

Landing Page
bildschirmfoto 2017-11-20 um 16 56 09

Result Page
bildschirmfoto 2017-11-20 um 16 56 32

plutonik-a added a commit that referenced this issue Nov 21, 2017
* remove the main search button from section form
* encapsule sections filters into seperate form and move it to the
include
* add event listener to main search button and trigger submission of
section filters, when button is clicked
plutonik-a added a commit that referenced this issue Nov 21, 2017
* add attribute checked to the input
* add parameter $scope to map, to process a distinction of the search
scope
plutonik-a added a commit that referenced this issue Nov 21, 2017
as it is currently handled in search.xqm already.
plutonik-a added a commit that referenced this issue Nov 21, 2017
plutonik-a added a commit that referenced this issue Nov 21, 2017
* restructure markup: Un-nest the input from its wrapping label, which
was not accessible and put it on the same level
* connect label and input by adding „label for“ and „input id“
attributes
* therefore, modularize and restructure template functions
plutonik-a added a commit that referenced this issue Nov 22, 2017
* rename functions according to their updated tasks
* delete markup entirely from template functions
* move markup to template instead
* update comment headers in functions
* remove obsolete comments
plutonik-a added a commit that referenced this issue Nov 23, 2017
* if entire search is checked, all other options are unchecked
* if any of the sections is checked, entire search is unchecked
* if all sections are selected, all will be unchecked and entire search
will be checked again
@plutonik-a
Copy link
Contributor Author

Update: Changed the layout according to https://standards.usa.gov/components/form-controls/#checkboxes
and fixed the logic of selecting and deselecting the checkbox options.

bildschirmfoto 2017-11-23 um 17 49 55

bildschirmfoto 2017-11-23 um 17 50 03

@tuurma
Copy link
Contributor

tuurma commented Nov 29, 2017

Looks like we're done here, we'll test it a bit more and then close if everything's okay

@tuurma
Copy link
Contributor

tuurma commented Nov 30, 2017

Looks like I had some hiccups with my local instance yesterday. Closing.

@tuurma tuurma closed this as completed Nov 30, 2017
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

No branches or pull requests

3 participants