Component Contract

Search

Site search input and results layout for finding pension plan resources across the CAAT member experience.

Live Demo

Search Input

Rendered

Search with Suggestions

Rendered

Search Results Page

Rendered

12 results for “pension benefits”

Page

Understanding Your CAAT Pension Benefits

caat.ca › members › benefits › overview

Learn about your pension benefits as a CAAT member, including defined benefit plan details, survivor benefits, and inflation protection.

Member Resources
Article

Retirement Planning & Pension Estimates

caat.ca › blog › retirement-planning

Use our pension calculator to estimate your pension benefits at retirement. See how your years of service and salary affect your monthly income.

Blog ·
PDF

DBplus Plan Member Handbook (PDF, 2.4 MB)

caat.ca › documents › dbplus-handbook.pdf

A comprehensive guide to your pension benefits, including contribution rates, retirement options, and survivor protections under the DBplus plan.

Documents · Updated Jan 2026
Page

Survivor and Death Benefits

caat.ca › members › benefits › survivor

Your CAAT pension benefits include important protections for your loved ones. Learn about survivor pensions, lump-sum options, and beneficiary designations.

Member Resources

No Results State

Rendered

No results found for “xyz”

Try different keywords or check the spelling of your search term.

States

Follows the Interaction States matrix. The input implements default and focus; suggestions and result filters implement default, hover, focus, and selected. The static is-* classes mirror the live pseudo-class states.

Input

Result filters

Code sample

HTML

<!-- Search input -->
<form class="caat-search" role="search" aria-label="Site search">
  <i class="bi bi-search caat-search__icon" aria-hidden="true"></i>
  <input type="search" class="form-control caat-search__input"
         placeholder="Search CAAT resources..."
         aria-label="Search CAAT resources">
  <button type="button" class="caat-search__clear"
          aria-label="Clear search">
    <i class="bi bi-x-lg" aria-hidden="true"></i>
  </button>
</form>

<!-- Results -->
<div class="caat-search-results">
  <p class="caat-search-results__count">12 results for "pension benefits"</p>
  <div class="caat-search-results__item">
    <h4 class="caat-search-results__title"><a href="#">Result Title</a></h4>
    <p class="caat-search-results__url">caat.ca &rsaquo; section</p>
    <p class="caat-search-results__excerpt">Excerpt with <mark>highlighted term</mark>.</p>
    <div class="caat-search-results__meta">
      <span class="badge bg-light text-dark">Category</span>
    </div>
  </div>
</div>

1. Summary

ComponentSearch
AEM Resource Typecaat/components/search
PurposeProvides site search input and results display for finding pension plan resources across the CAAT member experience.
VariantsSearch input · Search with suggestions · Results page · No results state
ContainsSearch input, icon, clear button, suggestion dropdown, results list, no-results message
Used inGlobal header, search results page, knowledge base, member portal
FigmaCAAT DS / Components / Search
Status Rebuild

2. Design Tokens

TokenRoleValue (light)
--caat-blue-900Result title hover colour#003750
--caat-blue-700Result title link colour#0b5a80
--caat-blue-100Search term highlight (<mark>) background#e7f4fb
--caat-greenResult URL breadcrumb colour#55a546
--caat-grey-200Input border, dividers#dfe6ef
--caat-focusFocus ring on input and interactive elements#4D90FE
--caat-inkPrimary text colour#102637
--caat-radiusBorder-radius for input and dropdown.75rem
--caat-font-primaryFont familyLibre Franklin

3. Authoring Fields

FieldTypeRequiredNotes
Placeholder textTextNoDefault: "Search CAAT resources…"
Accessible labelTextYesPopulates aria-label on the search input.
Search endpointURLYesAPI endpoint for search queries.
Enable suggestionsToggleNoEnables typeahead suggestion dropdown.
Suggestion endpointURLConditionalRequired when suggestions enabled. Returns suggestion JSON.
Results per pageNumberNoDefault: 10. Controls pagination of results.
No-results messageTextNoDefault: "No results found for…"
Helpful linksMultifieldNoLinks shown in the no-results state. Each: label (text) + URL.

4. Validation

RuleError message
Accessible label is required."Provide an accessible label for the search input."
Search endpoint is required."Enter a valid search endpoint URL."
Suggestion endpoint required when suggestions enabled."Provide a suggestion endpoint URL."
Results per page must be between 1 and 50."Enter a value between 1 and 50."
Helpful links must have both label and URL."Each helpful link requires a label and URL."

5. Content Guidance

  • Placeholder text should guide users: "Search CAAT resources…" or "Search for pension information…".
  • Keep suggestion terms concise — ideally 2 – 4 words matching common member queries.
  • Result excerpts should be 1 – 2 sentences long, with the search term highlighted using <mark>.
  • URL breadcrumbs should reflect the page hierarchy, not the full URL.
  • No-results state should always include helpful links to guide users to relevant content.
  • Category tags on results help members identify content type at a glance.

6. Semantic HTML

Search input

<form class="caat-search" role="search" aria-label="Site search">
  <i class="bi bi-search caat-search__icon" aria-hidden="true"></i>
  <input type="search"
         class="form-control caat-search__input"
         placeholder="Search CAAT resources..."
         aria-label="Search CAAT resources">
  <button type="button" class="caat-search__clear"
          aria-label="Clear search">
    <i class="bi bi-x-lg" aria-hidden="true"></i>
  </button>
</form>

Search results

<div class="caat-search-results">
  <p class="caat-search-results__count">
    12 results for &ldquo;pension benefits&rdquo;
  </p>
  <div class="caat-search-results__item">
    <h4 class="caat-search-results__title">
      <a href="/page-url">Page Title</a>
    </h4>
    <p class="caat-search-results__url">
      caat.ca &rsaquo; section &rsaquo; page
    </p>
    <p class="caat-search-results__excerpt">
      Excerpt with <mark>highlighted term</mark>.
    </p>
    <div class="caat-search-results__meta">
      <span class="badge bg-light text-dark">Category</span>
    </div>
  </div>
</div>

Suggestions dropdown

<ul class="caat-search__suggestions" id="search-suggestions"
    role="listbox">
  <li class="caat-search__suggestion" role="option">
    <i class="bi bi-search" aria-hidden="true"></i>
    pension calculator
  </li>
</ul>

7. CSS Contract

SelectorPurpose
.caat-searchSearch form wrapper. Relative positioning for icon/clear button.
.caat-search__inputLarge search input (3.5rem height). Left padding for icon, right padding for clear button.
.caat-search__iconMagnifying glass icon positioned absolutely left.
.caat-search__clearClear/reset button positioned absolutely right.
.caat-search__suggestionsTypeahead dropdown. White background, shadow, rounded bottom corners.
.caat-search__suggestionIndividual suggestion item. Hover background uses --caat-blue-100.
.caat-search-resultsResults list container.
.caat-search-results__countResults count line with bottom border.
.caat-search-results__itemIndividual result. Bottom border divider.
.caat-search-results__titleResult title. Link colour --caat-blue-700.
.caat-search-results__urlURL breadcrumb in small green text (--caat-green).
.caat-search-results__excerptResult excerpt text. <mark> uses --caat-blue-100 background.
.caat-search-results__metaMetadata row for category tags.

8. Accessibility

RequirementImplementation
Landmarkrole="search" on the <form> element.
Labelaria-label on both the form and the input.
Clear buttonaria-label="Clear search" on the clear/reset button.
Suggestionsrole="listbox" on suggestions list, role="option" on each item. aria-expanded and aria-controls on input.
KeyboardArrow keys navigate suggestions. Enter selects. Escape closes dropdown.
FocusVisible :focus-visible ring on input, clear button, and suggestion items.
ResultsResult count announced via aria-live="polite" region after search.
Highlight<mark> element used for search term highlighting — semantically meaningful.
Colour contrastAll text and interactive elements meet WCAG 2.1 AA (4.5:1 text, 3:1 non-text).

9. SEO

Transient / structural UI with no indexable content of its own — no SEO markup required. Ensure any content this component wraps or reveals stays server-rendered and crawlable.

10. Analytics

Analytics are captured through the shared data-analytics-component attribute on the component root (emitted automatically) and reported to the central data layer. Event names and payloads follow the organisation's standard analytics schema — defined centrally with the analytics team, not invented per component — so no bespoke tracking is specified here.

11. AEM Notes

  • Resource type: caat/components/search
  • Sling Model: SearchModel — exposes query, results[], totalResults, suggestions[], helpfulLinks[].
  • HTL template: search.html — uses data-sly-test to switch between results, no-results, and initial states.
  • Client library: caat.components.search — CSS + JS. JS handles typeahead debounce, keyboard navigation, and analytics events.
  • Policy: Authors can configure search endpoint, enable/disable suggestions, and set results-per-page via template policy.
  • Allowed parents: Layout Container, Header, Experience Fragment.
  • Search service: Integrates with AEM QueryBuilder or external search API (e.g. Azure Cognitive Search). Endpoint configured in OSGi.

12. Dialog Model

Simplified model — shows field intent and Granite UI resource types, not the literal cq:dialog node tree (e.g. select options are authored as child items nodes).

{
  "jcr:primaryType": "nt:unstructured",
  "sling:resourceType": "cq/gui/components/authoring/dialog",
  "tabs": {
    "properties": {
      "placeholderText": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/textfield",
        "label": "Placeholder text",
        "name": "./placeholderText"
      },
      "accessibleLabel": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/textfield",
        "label": "Accessible label",
        "name": "./accessibleLabel",
        "required": true
      },
      "searchEndpoint": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/textfield",
        "label": "Search endpoint",
        "name": "./searchEndpoint",
        "required": true
      },
      "enableSuggestions": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/checkbox",
        "label": "Enable suggestions",
        "name": "./enableSuggestions"
      },
      "suggestionEndpoint": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/textfield",
        "label": "Suggestion endpoint",
        "name": "./suggestionEndpoint"
      },
      "resultsPerPage": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/numberfield",
        "label": "Results per page",
        "name": "./resultsPerPage",
        "min": 1,
        "max": 50,
        "value": 10
      },
      "noResultsMessage": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/textfield",
        "label": "No-results message",
        "name": "./noResultsMessage"
      },
      "helpfulLinks": {
        "sling:resourceType": "granite/ui/components/coral/foundation/form/multifield",
        "label": "Helpful links",
        "name": "./helpfulLinks",
        "fields": {
          "linkLabel": { "type": "textfield", "label": "Link label" },
          "linkUrl": { "type": "textfield", "label": "URL" }
        }
      }
    }
  }
}

13. QA Acceptance Checklist

  • Search input renders at 3.5rem height with magnifying glass icon and clear button.
  • Placeholder text displays correctly and is customisable via dialog.
  • Focus ring appears on input using --caat-focus token colour.
  • Clear button resets the input and is keyboard accessible.
  • Suggestion dropdown appears on typing with correct hover/focus states.
  • Arrow keys, Enter, and Escape work correctly with suggestions.
  • Search results display title (linked), URL breadcrumb, excerpt, and category tag.
  • Search term is highlighted with <mark> in result excerpts.
  • Results count displays correctly (e.g. "12 results for 'pension benefits'").
  • No-results state shows message, suggestions, and helpful links.
  • role="search" is present on the form element.
  • Screen readers announce result count via aria-live region.
  • Analytics events (search-submitted, search-result-click, search-no-results) fire correctly.
  • Cross-browser tested: Chrome, Firefox, Safari, Edge.

14. Definition of Done

AreaDone means
Design Figma component matches this contract. Input, suggestions, results, and no-results variants are documented. All interactive states (hover, focus, active) specified.
Development AEM proxy component created. HTL template emits semantic HTML per Section 6. CSS uses design tokens exclusively. JS handles typeahead, keyboard nav, and clear. Unit and integration tests pass.
QA All items in the QA Acceptance Checklist (Section 13) pass. Manual accessibility audit completed. Cross-browser tested (Chrome, Firefox, Safari, Edge).
Launch Component deployed to AEM production. Search endpoint configured and returning results. Content authors trained on configuration options. Analytics dashboards confirmed receiving events.