-
Notifications
You must be signed in to change notification settings - Fork 131
Ask search #8935
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
base: main
Are you sure you want to change the base?
Ask search #8935
Changes from all commits
fcf98e6
5f46526
51ee462
bdb2fda
b554c2b
02e3c19
70929b5
f9dc900
0072600
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 |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| {% extends 'v1/layouts/layout-2-1.html' %} | ||
| {% import 'v1/includes/templates/render_block.html' as render_block with context %} | ||
| {% import 'ask-cfpb/_ask-search.html' as ask_search with context %} | ||
| {% import 'v1/includes/molecules/notification.html' as notification with context %} | ||
|
|
||
| {% set read_answer_text = _('Read answer') %} | ||
|
|
||
|
|
@@ -25,24 +25,31 @@ | |
| {% import 'v1/includes/molecules/translation-links.html' as translation_links with context %} | ||
| {{ translation_links.render(modifier_classes='block--flush-top') }} | ||
|
|
||
| {% for block in page.content %} | ||
| {% if block.block_type == 'notification' %} | ||
| {% set has_notification = true %} | ||
| {% include_block block %} | ||
| {% endif %} | ||
| {% endfor %} | ||
|
|
||
| <section class="ask-search block block--sub{% if has_notification == false %} block--flush-top{% endif %}"> | ||
| {{ ask_search.render( language=page.language, is_subsection=False ) }} | ||
| </section> | ||
|
|
||
| {% for block in page.content %} | ||
| {% if block.block_type != 'notification' %} | ||
|
Contributor
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. I don't remember -- is it possible to add a notification block to this page's |
||
| {% include_block block %} | ||
| {% endif %} | ||
| {% endfor %} | ||
| </div> | ||
|
|
||
| <div class="m-notification | ||
|
Contributor
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. I wonder if we could add a new type ( (And/or pull this notification out into a template so it can be reused on the see-all page?) |
||
| m-notification--visible | ||
| m-notification--success"> | ||
| {{ svg_icon('help-round') }} | ||
| <div class="m-notification__content"> | ||
| <div class="m-notification__message">{{ _('Can\'t find what you\'re looking for?') }}</div> | ||
| <ul class="m-list m-list--links"> | ||
| <li class="m-list__item"> | ||
| <a class="a-link a-link--jump" href="{{ _('/search/') }}"> | ||
| <span class="a-link__text"> | ||
| {{ _('Search all of consumerfinance.gov') }} | ||
| </span> | ||
| </a> | ||
| </li> | ||
| </ul> | ||
| </div> | ||
| </div> | ||
|
|
||
| {% endblock %} | ||
|
|
||
| {% block content_sidebar scoped -%} | ||
|
|
||
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.
I wonder if this still needs to be a separate macro with various options if the search input is only being used on the answer page. Could we pull in the search bar from the searchgov page instead in the
answer-page.htmltemplate, and just include the h3 header from here?