Skip to content

[594] Add the ability to search case studies tags#114

Merged
IhorMasechko merged 18 commits into
mainfrom
594-case-study-search-by-tags
May 27, 2025
Merged

[594] Add the ability to search case studies tags#114
IhorMasechko merged 18 commits into
mainfrom
594-case-study-search-by-tags

Conversation

@IhorMasechko
Copy link
Copy Markdown
Contributor

@IhorMasechko IhorMasechko commented May 23, 2025

  • Refactor case studies page to support filtering by industry, stack, and case study type
  • Add per-tag-type search input and client-side filtering for tags
  • Update case study templates for new tag relationships

This PR is needed to provide more flexible filtering for case studies, improve content relationships.

IhorMasechko and others added 9 commits May 21, 2025 10:06
- Refactor case-studies-page/index.js to fix ESLint errors while maintaining functionality
- Split large functions into smaller utility functions
- Fix race condition warnings using defensive copies
- Implement dynamic tag counting with proper modularization
- Update template to use the dynamic tag counts
- Remove invalid tagCountsMethods property from module top level
- Move tag counting logic into helper utility functions
- Simplify module structure to comply with ApostropheCMS conventions
- Fix linter errors related to function length
- Remove main search form from case studies page
- Add per-tag-type search input for filtering tags
- Implement client-side tag filtering with JavaScript
@IhorMasechko IhorMasechko requested a review from killev as a code owner May 23, 2025 09:57
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 23, 2025

📝 Walkthrough

Walkthrough

The changes refactor the case studies page to support a multi-filter system with separate categories for industry, stack, and caseStudyType. The UI and template logic are updated to display and manage multiple values per category, and new JavaScript modules are added to enable client-side tag filtering within each category.

Changes

File(s) Change Summary
website/modules/case-studies-page/views/index.html Refactored template to support multi-category filtering (industry, stack, caseStudyType), updated filter UI, and enabled multi-valued attribute display.
website/modules/case-studies-page/views/show.html Updated template to render multiple values for industry, caseStudyType, and stack using array iteration.
website/modules/asset/ui/src/index.js Added initCaseStudiesTagFilter for initializing tag search filters and integrated it into component setup.
website/modules/asset/ui/src/searchInputHandler.js New module for dynamic client-side filtering of tag items based on search input.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant CaseStudiesPage (HTML/JS)
    participant FilterLogic
    participant Data

    User->>CaseStudiesPage (HTML/JS): Selects filter (industry/stack/caseStudyType) or types in search
    CaseStudiesPage (HTML/JS)->>FilterLogic: Updates filter state and triggers UI update
    FilterLogic->>Data: Filters articles based on selected categories
    Data-->>FilterLogic: Returns filtered article list
    FilterLogic-->>CaseStudiesPage (HTML/JS): Renders updated articles and filter UI
    User->>CaseStudiesPage (HTML/JS): Types in tag search input
    CaseStudiesPage (HTML/JS)->>searchInputHandler.js: Filters visible tags in category section
Loading

Possibly related PRs

  • speedandfunction/website#101: Extends multi-value tag rendering and filtering UI, building on similar template logic for multi-category filtering.
  • speedandfunction/website#85: Adds initial caseStudyType and industry fields to schema/templates, which are further extended in this PR.
  • speedandfunction/website#48: Introduces the original case studies page template and single tag filter system, which this PR refactors and expands.

Suggested reviewers

  • yuramax
  • VitalyyP
  • Anton-88
✨ Finishing Touches
  • 📝 Generate Docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@IhorMasechko IhorMasechko self-assigned this May 23, 2025
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 23, 2025

🔍 Vulnerabilities of apostrophe-cms:test

📦 Image Reference apostrophe-cms:test
digestsha256:4e57dfeb98781f6dcd220e5d7678f6a9485fe4919a97d526445bad98a28810eb
vulnerabilitiescritical: 0 high: 3 medium: 0 low: 0
platformlinux/amd64
size284 MB
packages935
📦 Base Image node:23-alpine
also known as
  • 23-alpine3.21
  • 23.11-alpine
  • 23.11-alpine3.21
  • 23.11.1-alpine
  • 23.11.1-alpine3.21
digestsha256:169ee1b69bd3f5c7c8508a9919e8b367bba9dc7fa9a03097ec9f85d2e8179631
vulnerabilitiescritical: 0 high: 0 medium: 0 low: 0
critical: 0 high: 1 medium: 0 low: 0 async 1.5.2 (npm)

pkg:npm/async@1.5.2

high 7.8: CVE--2021--43138 OWASP Top Ten 2017 Category A9 - Using Components with Known Vulnerabilities

Affected range<2.6.4
Fixed version2.6.4, 3.2.2
CVSS Score7.8
CVSS VectorCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
EPSS Score1.061%
EPSS Percentile77th percentile
Description

A vulnerability exists in Async through 3.2.1 (fixed in 3.2.2), which could let a malicious user obtain privileges via the mapValues() method.

critical: 0 high: 1 medium: 0 low: 0 async 0.9.2 (npm)

pkg:npm/async@0.9.2

high 7.8: CVE--2021--43138 OWASP Top Ten 2017 Category A9 - Using Components with Known Vulnerabilities

Affected range<2.6.4
Fixed version2.6.4, 3.2.2
CVSS Score7.8
CVSS VectorCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
EPSS Score1.061%
EPSS Percentile77th percentile
Description

A vulnerability exists in Async through 3.2.1 (fixed in 3.2.2), which could let a malicious user obtain privileges via the mapValues() method.

critical: 0 high: 1 medium: 0 low: 0 connect-multiparty 2.2.0 (npm)

pkg:npm/connect-multiparty@2.2.0

high 7.8: CVE--2022--29623 Unrestricted Upload of File with Dangerous Type

Affected range<=2.2.0
Fixed versionNot Fixed
CVSS Score7.8
CVSS VectorCVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
EPSS Score0.119%
EPSS Percentile32nd percentile
Description

An arbitrary file upload vulnerability in the file upload module of Express Connect-Multiparty 2.2.0 allows attackers to execute arbitrary code via a crafted PDF file. NOTE: the Supplier has not verified this vulnerability report.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 11

🧹 Nitpick comments (1)
website/modules/case-studies-page/index.js (1)

34-46: Consider using explicit object reference instead of this for clarity.

While the current implementation works, using this in object methods can lead to context issues if these methods are extracted or used as callbacks. Consider using the explicit object name for better maintainability.

processCaseStudies(caseStudies, tagMap, tagCounts) {
  caseStudies.forEach((study) => {
-    this.countTagsOfType(study.industryIds, tagMap, tagCounts.industry);
+    tagCountHelpers.countTagsOfType(study.industryIds, tagMap, tagCounts.industry);

-    this.countTagsOfType(study.stackIds, tagMap, tagCounts.stack);
+    tagCountHelpers.countTagsOfType(study.stackIds, tagMap, tagCounts.stack);

-    this.countTagsOfType(
+    tagCountHelpers.countTagsOfType(
      study.caseStudyTypeIds,
      tagMap,
      tagCounts.caseStudyType,
    );
  });
},
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4967df0 and a4d3885.

📒 Files selected for processing (5)
  • website/modules/case-studies-page/index.js (2 hunks)
  • website/modules/case-studies-page/views/index.html (4 hunks)
  • website/modules/case-studies-page/views/show.html (2 hunks)
  • website/modules/case-studies/index.js (4 hunks)
  • website/modules/cases-tags/index.js (3 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (4)
  • GitHub Check: e2e-tests
  • GitHub Check: lint
  • GitHub Check: unit-tests
  • GitHub Check: security-scan
🔇 Additional comments (7)
website/modules/cases-tags/index.js (3)

25-25: LGTM! Consistent with relationship field requirements.

Adding _category: 1 to the project builder is necessary for the tag categorization feature and aligns with the relationship field definitions.


47-53: LGTM! Category filtering support added correctly.

The addition of category-based filtering enhances the admin interface capabilities and follows ApostropheCMS conventions.


7-7:

Details

✅ Verification successful

Verify shortcut key uniqueness across the application.

The shortcut was changed from "G,M" to "G,H". Ensure this doesn't conflict with other modules or browser shortcuts.


🏁 Script executed:

#!/bin/bash
# Check if the shortcut "G,H" is used elsewhere in the codebase
rg -r '$1' 'shortcut:\s*["\']([^"\']*G,H[^"\']*)["\']' --type js

Length of output: 247


🏁 Script executed:

#!/bin/bash
# Search all shortcut definitions in JS files to spot potential conflicts
rg -n "shortcut:" --type js

# Specifically look for any usage of "G,H" in JavaScript files
rg -n "G,H" --type js

Length of output: 228


Shortcut ‘G,H’ uniqueness confirmed

  • Searched all JS modules for shortcut::
    • website/modules/cases-tags/index.js (line 7): ‘G,H’
    • website/modules/team-members/index.js (line 9): ‘G,K’
  • No other occurrences of ‘G,H’ found in the codebase.

This change poses no cross-module shortcut conflicts. You may still want to verify that G,H isn’t reserved by your shortcut library or browser.

website/modules/case-studies-page/views/index.html (1)

8-9: LGTM! Improved filter condition logic.

The new condition properly checks for multiple filter types instead of a single generic filter, which aligns with the enhanced filtering capabilities.

website/modules/case-studies/index.js (1)

12-12: LGTM! Alias addition improves module accessibility.

Adding the caseStudy alias provides a more intuitive way to reference this piece type in code and queries.

website/modules/case-studies-page/index.js (2)

55-61: Module configuration looks good!

The configuration correctly defines the three distinct piece filters (industry, stack, caseStudyType) and properly sets the pieces source and filter URL. This aligns well with the refactoring from generic tags to relationship-based fields.


104-127: Clean implementation of tag counting logic!

The calculateTagCounts method is well-structured with proper initialization and effective use of helper functions. The separation of concerns makes the code easy to understand and maintain.

Comment thread website/modules/case-studies-page/views/show.html Outdated
Comment thread website/modules/case-studies-page/views/show.html Outdated
Comment thread website/modules/case-studies-page/views/show.html Outdated
Comment thread website/modules/case-studies-page/views/index.html
Comment thread website/modules/case-studies-page/views/index.html Outdated
Comment thread website/modules/case-studies-page/views/index.html Outdated
Comment thread website/modules/case-studies/index.js
Comment thread website/modules/case-studies/index.js
Comment thread website/modules/case-studies/index.js
Comment thread website/modules/case-studies-page/index.js
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

♻️ Duplicate comments (3)
website/modules/case-studies-page/views/index.html (3)

33-68: Reduce duplication in selected-tags rendering via a macro
The nested loops and repeated if/elif for each filter type have been flagged before. Extracting this into a macro (e.g. renderSelectedTag(filterType, tag, data)) will DRY up the logic and make future changes simpler.


76-152: DRY up filter sections with a macro
All three filter categories share nearly identical markup and logic. A renderFilterSection(filterType, filterLabel, tags, data) macro (as suggested in earlier feedback) would consolidate this code, reducing maintenance overhead.


181-189: ⚠️ Potential issue

Add defensive checks for _industry and _stack relationships
You’ve already guarded _caseStudyType against missing data, but the _industry and _stack sections assume those arrays always exist. If those properties are undefined, calling .length will throw. Please update to:

{% if article._industry and article._industry.length %}
  {# … #}
{% endif %}{% if article._stack and article._stack.length %}
  {# … #}
{% endif %}

Also applies to: 196-200

🧹 Nitpick comments (4)
website/modules/case-studies-page/views/index.html (4)

1-3: Template filename inconsistency: remove .new suffix
The header comment references index.new.html, but Apostrophe’s view discovery expects index.html. Please rename this file (and update any imports) so the template loader picks it up correctly.


8-9: Improve Jinja tag readability: separate set and if statements
The current combined tag makes scanning and diffs harder. Splitting them enhances clarity:

{% set hasActiveFilters = data.query.industry or data.query.stack or data.query.caseStudyType %}
{% if hasActiveFilters %}{% endif %}

83-88: Extract inline styles to a CSS class
Avoid hard-coded style="margin-bottom: 10px; width: 100%" on the search input. Instead, define a utility class (e.g. .filter-search-input) in your stylesheet and apply it here for consistent styling and easier theming.


214-237: Move inline JavaScript to an external file and add error handling
Embedding this script in the template prevents caching and mixes concerns. Consider:

  1. Extracting it to assets/js/case-studies-filters.js.
  2. Adding guards or optional chaining to prevent runtime errors:
document.addEventListener('DOMContentLoaded', () => {
  const inputs = document.querySelectorAll('.tag-search') || [];
  inputs.forEach(input => {
    input.addEventListener('input', () => {
      const items = input.closest('.filter-section')?.querySelectorAll('.tag-item') || [];
      items.forEach(item => { /* … */ });
    });
  });
});
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a4d3885 and 8ee217c.

📒 Files selected for processing (2)
  • website/modules/case-studies-page/views/index.html (4 hunks)
  • website/modules/case-studies-page/views/show.html (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • website/modules/case-studies-page/views/show.html
⏰ Context from checks skipped due to timeout of 90000ms (4)
  • GitHub Check: lint
  • GitHub Check: e2e-tests
  • GitHub Check: unit-tests
  • GitHub Check: security-scan

coderabbitai[bot]
coderabbitai Bot previously approved these changes May 23, 2025
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

♻️ Duplicate comments (2)
website/modules/case-studies-page/views/index.html (2)

187-189: ⚠️ Potential issue

Add defensive check for industry relationship array.

The code assumes article._industry is always an array, but there's no defensive check like the one implemented for _caseStudyType. This could cause runtime errors if the data is malformed.

Apply this diff to add the defensive check:

-            {% if article._industry.length %} {% for industry in
+            {% if article._industry and article._industry.length %} {% for industry in
             article._industry %} {{ industry.title }}{% if not loop.last %},
             {% endif %} {% endfor %} {% endif %}

197-199: ⚠️ Potential issue

Add defensive check for stack relationship array.

Similar to the industry section, the stack section lacks a defensive check to ensure article._stack exists before accessing its length property.

Apply this diff to add the defensive check:

-            {% if article._stack.length %} {% for tech in article._stack %} {{
+            {% if article._stack and article._stack.length %} {% for tech in article._stack %} {{
             tech.title }}{% if not loop.last %}, {% endif %} {% endfor %} {%
             endif %}
🧹 Nitpick comments (1)
website/modules/case-studies-page/views/index.html (1)

183-184: Consider XSS protection for dynamic content.

While the title field is likely safe, consider adding explicit escaping for consistency and security best practices, especially since this data comes from relationship fields.

Apply this diff for additional security:

-            {% for type in article._caseStudyType %} {{ type.title | e }}{% if
+            {% for type in article._caseStudyType %} {{ type.title | e }}{% if

The escaping is already present - this is good! Apply similar escaping to industry and stack sections:

             {% if article._industry and article._industry.length %} {% for industry in
-            article._industry %} {{ industry.title }}{% if not loop.last %},
+            article._industry %} {{ industry.title | e }}{% if not loop.last %},
             {% if article._stack and article._stack.length %} {% for tech in article._stack %} {{
-            tech.title }}{% if not loop.last %}, {% endif %} {% endfor %} {%
+            tech.title | e }}{% if not loop.last %}, {% endif %} {% endfor %} {%
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 8ee217c and bfed418.

📒 Files selected for processing (2)
  • website/modules/asset/ui/src/index.js (1 hunks)
  • website/modules/case-studies-page/views/index.html (3 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (1)
website/modules/asset/ui/src/index.js (2)
website/modules/asset/ui/src/swipers.js (1)
  • initAllSwipers (57-69)
website/modules/asset/ui/src/smoothCounters.js (1)
  • initSmoothCounters (58-78)
⏰ Context from checks skipped due to timeout of 90000ms (4)
  • GitHub Check: e2e-tests
  • GitHub Check: security-scan
  • GitHub Check: unit-tests
  • GitHub Check: lint
🔇 Additional comments (1)
website/modules/asset/ui/src/index.js (1)

75-75: Confirm proper integration with page lifecycle.

The bindTagSearch function is correctly integrated into the initialization flow, ensuring it runs both on initial page load and after Barba.js page transitions.

Comment thread website/modules/asset/ui/src/index.js Outdated
coderabbitai[bot]
coderabbitai Bot previously approved these changes May 23, 2025
VitalyyP
VitalyyP previously approved these changes May 23, 2025
Copy link
Copy Markdown
Contributor

@VitalyyP VitalyyP left a comment

Choose a reason for hiding this comment

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

LGTM

@IhorMasechko IhorMasechko dismissed stale reviews from VitalyyP and coderabbitai[bot] via 122e5e0 May 23, 2025 19:45
@IhorMasechko IhorMasechko requested a review from VitalyyP May 23, 2025 19:46
@IhorMasechko IhorMasechko enabled auto-merge (squash) May 23, 2025 19:48
VitalyyP
VitalyyP previously approved these changes May 25, 2025
Copy link
Copy Markdown
Contributor

@VitalyyP VitalyyP left a comment

Choose a reason for hiding this comment

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

LGTM. Only notice - fix the PR description

Copy link
Copy Markdown
Contributor

@Anton-88 Anton-88 left a comment

Choose a reason for hiding this comment

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

If there is no necessity in using inline styles, please, move them to class="tag-search" for your input
image

yuramax
yuramax previously approved these changes May 26, 2025
Copy link
Copy Markdown
Contributor

@yuramax yuramax left a comment

Choose a reason for hiding this comment

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

LGTM!

@Anton-88 Anton-88 self-requested a review May 26, 2025 07:58
Anton-88
Anton-88 previously approved these changes May 26, 2025
Copy link
Copy Markdown
Contributor

@Anton-88 Anton-88 left a comment

Choose a reason for hiding this comment

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

LGTM

@IhorMasechko IhorMasechko dismissed stale reviews from yuramax, VitalyyP, and Anton-88 via ccf584a May 27, 2025 13:07
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (2)
website/modules/asset/ui/src/searchInputHandler.js (2)

26-38: Consider adding input validation.

The function should validate that required parameters are provided before proceeding.

 const handleTagSearch = (
   input,
   containerSelector,
   tagSelector,
   getTagLabel,
 ) => {
+  if (!input || !containerSelector || !tagSelector || !getTagLabel) {
+    console.warn('Missing required parameters for tag search');
+    return;
+  }
+  
   const filterValue = getFilterValue(input);
   const container = input.closest(containerSelector);
   if (!container) return;

   const tagItems = getTagItems(container, tagSelector);
   filterTagItems(tagItems, filterValue, getTagLabel);
 };

50-63: Consider performance optimization for large datasets.

For better performance with large tag lists, consider adding debouncing to prevent excessive filtering on rapid input changes.

+const debounce = (func, wait) => {
+  let timeout;
+  return function executedFunction(...args) {
+    const later = () => {
+      clearTimeout(timeout);
+      func(...args);
+    };
+    clearTimeout(timeout);
+    timeout = setTimeout(later, wait);
+  };
+};
+
 export const setupTagSearchForInput = (
   input,
   { containerSelector, tagSelector, getTagLabel },
 ) => {
   removePreviousHandler(input);
-  const handler = createTagSearchHandler(
+  const baseHandler = createTagSearchHandler(
     input,
     containerSelector,
     tagSelector,
     getTagLabel,
   );
+  const handler = debounce(baseHandler, 150);
   input.tagSearchHandler = handler;
   input.addEventListener('input', handler);
 };
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bfed418 and ccf584a.

📒 Files selected for processing (2)
  • website/modules/asset/ui/src/index.js (2 hunks)
  • website/modules/asset/ui/src/searchInputHandler.js (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • website/modules/asset/ui/src/index.js
⏰ Context from checks skipped due to timeout of 90000ms (4)
  • GitHub Check: unit-tests
  • GitHub Check: e2e-tests
  • GitHub Check: lint
  • GitHub Check: security-scan
🔇 Additional comments (1)
website/modules/asset/ui/src/searchInputHandler.js (1)

1-5: LGTM! Good cleanup pattern for event handlers.

The function properly removes previous event listeners to prevent memory leaks and duplicate handlers.

Comment thread website/modules/asset/ui/src/searchInputHandler.js
Comment thread website/modules/asset/ui/src/searchInputHandler.js
Copy link
Copy Markdown
Contributor

@yuramax yuramax left a comment

Choose a reason for hiding this comment

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

LGTM 👌

Copy link
Copy Markdown
Contributor

@Anton-88 Anton-88 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Copy Markdown
Collaborator

@killev killev left a comment

Choose a reason for hiding this comment

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

This is not what I mean, but OK.

@sonarqubecloud
Copy link
Copy Markdown

@IhorMasechko IhorMasechko merged commit 7ea09c1 into main May 27, 2025
12 checks passed
@IhorMasechko IhorMasechko deleted the 594-case-study-search-by-tags branch May 27, 2025 18:40
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.

5 participants