Skip to content

[ENG-11492] Improvements to shared search components and interfaces.#986

Open
nsemets wants to merge 6 commits into
CenterForOpenScience:feature/pbs-26-12from
nsemets:fix/search-improvements
Open

[ENG-11492] Improvements to shared search components and interfaces.#986
nsemets wants to merge 6 commits into
CenterForOpenScience:feature/pbs-26-12from
nsemets:fix/search-improvements

Conversation

@nsemets

@nsemets nsemets commented May 12, 2026

Copy link
Copy Markdown
Collaborator

Purpose

Improve code quality.

Summary of Changes

  1. Added interfaces for search events.
  2. Updated search tutorial position function.

@nsemets nsemets changed the title Fix/search improvements Improvements to shared search components and interfaces. May 12, 2026
@nsemets nsemets marked this pull request as ready for review May 27, 2026 14:51
@nsemets nsemets changed the base branch from feature/pbs-26-9 to feature/pbs-26-12 June 22, 2026 12:23
@nsemets nsemets requested a review from brianjgeiger June 22, 2026 12:23
@brianjgeiger

Copy link
Copy Markdown
Contributor

@nsemets Could you make a jira ticket for this so we can track it?

@nsemets nsemets changed the title Improvements to shared search components and interfaces. [ENG-11492] Improvements to shared search components and interfaces. Jun 22, 2026
@for (step of steps(); track $index) {
@if (currentStep() === $index + 1) {
<div class="stepper" [ngStyle]="getStepPosition(step)">
<div class="stepper" [ngStyle]="isTablet() ? step.position : step.mobilePosition">

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The old method returned step.mobilePosition || {} but the new template expression passes undefined directly to ngStyle when mobilePosition is absent. Change to step.mobilePosition ?? {} and add a test covering this case since the one that verified it was deleted.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SEARCH_TUTORIAL_STEPS always defines both positions. I made position and mobilePosition required on TutorialStep, so the compiler enforces this. The ?? {} fallback is no longer needed.

@nsemets nsemets requested a review from omar-cos June 26, 2026 14:16
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

Successfully merging this pull request may close these issues.

3 participants