diff --git a/cypress/e2e/search/item-search.cy.ts b/cypress/e2e/search/item-search.cy.ts
index b7790426..c8dea607 100644
--- a/cypress/e2e/search/item-search.cy.ts
+++ b/cypress/e2e/search/item-search.cy.ts
@@ -1,50 +1,42 @@
///
-describe('Utopia Map Item Search', () => {
- beforeEach(() => {
- cy.clearCookies()
- cy.clearLocalStorage()
- cy.window().then((win) => {
- win.sessionStorage.clear()
+describe('Utopia Map Search', () => {
+ describe('Item Search', () => {
+ beforeEach(() => {
+ cy.clearCookies()
+ cy.clearLocalStorage()
+ cy.window().then((win) => {
+ win.sessionStorage.clear()
+ })
+
+ cy.visit('/')
+ cy.waitForMapReady()
})
- cy.visit('/')
- cy.waitForMapReady()
- })
-
- it('should find items by exact name match', () => {
- cy.searchFor('Tech Meetup Munich')
- cy.get('[data-cy="search-suggestions"]').should('contain', 'Tech Meetup Munich')
- })
-
- it('should find items by partial name match (case insensitive)', () => {
- cy.searchFor('café collaboration')
- cy.get('[data-cy="search-suggestions"]').should('contain', 'Café Collaboration London')
- })
-
- it('should find items by text content', () => {
- cy.searchFor('sustainability')
- cy.get('[data-cy="search-suggestions"]').should('contain', 'Alex Entrepreneur')
- })
-
- it('should navigate to item profile when clicking search result', () => {
- cy.intercept('GET', '**/items*').as('getItems')
-
- cy.visit('/')
- cy.waitForMapReady()
-
- cy.searchFor('makerspace')
- cy.get('[data-cy="search-suggestions"]').within(() => {
- cy.get('[data-cy="search-item-result"]').contains('Makerspace Tokyo').click()
+ it('should find items by exact name match', () => {
+ cy.searchFor('Tech Meetup Munich')
+ cy.get('[data-cy="search-suggestions"]').should('contain', 'Tech Meetup Munich')
})
- cy.url().should('match', /\/(item\/|[a-f0-9-]+)/)
- cy.get('body').should('contain', 'Makerspace Tokyo')
+ it('should find items by partial name match (case insensitive)', () => {
+ cy.searchFor('café collaboration')
+ cy.get('[data-cy="search-suggestions"]').should('contain', 'Café Collaboration London')
+ })
- // Verify search uses local filtering (items already loaded)
- cy.get('@getItems.all').then((calls) => {
- expect(calls.length).to.be.greaterThan(0)
+ it('should find items by text content', () => {
+ cy.searchFor('sustainability')
+ cy.get('[data-cy="search-suggestions"]').should('contain', 'Alex Entrepreneur')
+ })
+
+ it('should navigate to item profile when clicking search result', () => {
+ cy.searchFor('makerspace')
+ cy.get('[data-cy="search-suggestions"]').within(() => {
+ cy.get('[data-cy="search-item-result"]').contains('Makerspace Tokyo').click()
+ })
+
+ cy.url().should('match', /\/(item\/|[a-f0-9-]+)/)
+ cy.get('[data-cy="profile-view"]').should('exist')
+ cy.get('[data-cy="profile-title"]').should('contain', 'Makerspace Tokyo')
})
})
-
})
diff --git a/lib/src/Components/Map/Subcomponents/ItemPopupComponents/HeaderView.tsx b/lib/src/Components/Map/Subcomponents/ItemPopupComponents/HeaderView.tsx
index d31f3cd3..ad544e0b 100644
--- a/lib/src/Components/Map/Subcomponents/ItemPopupComponents/HeaderView.tsx
+++ b/lib/src/Components/Map/Subcomponents/ItemPopupComponents/HeaderView.tsx
@@ -102,6 +102,7 @@ export function HeaderView({
{title}
diff --git a/lib/src/Components/Profile/ProfileView.tsx b/lib/src/Components/Profile/ProfileView.tsx
index 498f0347..f1859d60 100644
--- a/lib/src/Components/Profile/ProfileView.tsx
+++ b/lib/src/Components/Profile/ProfileView.tsx
@@ -174,10 +174,11 @@ export function ProfileView({ attestationApi }: { attestationApi?: ItemsApi
{item && (
<>
-