diff --git a/.tmp/proof/issue-123-landing.png b/.tmp/proof/issue-123-landing.png new file mode 100644 index 0000000..b4aa42a Binary files /dev/null and b/.tmp/proof/issue-123-landing.png differ diff --git a/.tmp/proof/issue-123-showcase.png b/.tmp/proof/issue-123-showcase.png new file mode 100644 index 0000000..9b18bb2 Binary files /dev/null and b/.tmp/proof/issue-123-showcase.png differ diff --git a/packages/app/public/portal-showcase.png b/packages/app/public/portal-showcase.png index 317ea3a..9b18bb2 100644 Binary files a/packages/app/public/portal-showcase.png and b/packages/app/public/portal-showcase.png differ diff --git a/packages/app/src/components/landing/LandingPage.test.tsx b/packages/app/src/components/landing/LandingPage.test.tsx index 5efd6c8..5ac143d 100644 --- a/packages/app/src/components/landing/LandingPage.test.tsx +++ b/packages/app/src/components/landing/LandingPage.test.tsx @@ -15,6 +15,12 @@ describe('LandingPage', () => { expect( screen.getByText(/Try it as a guest, no account needed/), ).toBeInTheDocument(); + expect( + screen.getByText(/search across your catalog and docs/), + ).toBeInTheDocument(); + expect( + screen.queryByText(/an answer engine grounded in your own docs/), + ).not.toBeInTheDocument(); }); it('links the primary call to action into the showcase', async () => { diff --git a/packages/app/src/components/landing/LandingPage.tsx b/packages/app/src/components/landing/LandingPage.tsx index c1a2138..bdb0e0e 100644 --- a/packages/app/src/components/landing/LandingPage.tsx +++ b/packages/app/src/components/landing/LandingPage.tsx @@ -93,7 +93,7 @@ export const LandingPage = () => { sx={{ fontWeight: 400, maxWidth: 640 }} > Software templates that publish to GitHub, a catalog that keeps - services findable, and an answer engine grounded in your own docs. + services findable, and search across your catalog and docs. Try it as a guest, no account needed. diff --git a/packages/app/src/components/showcase/ShowcaseCard.tsx b/packages/app/src/components/showcase/ShowcaseCard.tsx index e9738ae..7071f04 100644 --- a/packages/app/src/components/showcase/ShowcaseCard.tsx +++ b/packages/app/src/components/showcase/ShowcaseCard.tsx @@ -63,6 +63,11 @@ export const ShowcaseCard = ({ item }: { item: ShowcaseItem }) => { fontWeight: 500, }} /> + {item.availability && ( + + {item.availability} + + )} { + it('distinguishes live keyword search from the answer-engine extension', async () => { + await renderInTestApp(); + + fireEvent.click(screen.getByText(/^Answer Engine \(/)); + + expect(screen.getByRole('alert')).toHaveTextContent( + 'The demo does not generate answers.', + ); + const search = within( + screen.getByTestId('showcase-card-answer-engine-search'), + ); + expect(search.getByText('Built-in search')).toBeInTheDocument(); + expect(search.getByText('Catalog and Docs Search')).toBeInTheDocument(); + expect( + search.getByRole('link', { name: 'Search catalog and docs' }), + ).toHaveAttribute('href', '/search'); + + const extension = within( + screen.getByTestId('showcase-card-answer-engine-worker-card'), + ); + expect(extension.getByText('Extension template')).toBeInTheDocument(); + expect( + extension.getByText(/your own document index and AI Hub/), + ).toBeInTheDocument(); + expect(extension.getByRole('link', { name: 'Use template' })).toHaveAttribute( + 'href', + '/self-service/templates/default/answer-engine-worker', + ); + expect(screen.queryByText('Answer Engine Search')).not.toBeInTheDocument(); + expect(screen.getByText('2 items available')).toBeInTheDocument(); + }); + it('renders every item with the total count and category chips', async () => { await renderInTestApp(); const counts = countByCategory(showcaseItems); diff --git a/packages/app/src/components/showcase/ShowcasePage.tsx b/packages/app/src/components/showcase/ShowcasePage.tsx index 4054dd3..c2e60bf 100644 --- a/packages/app/src/components/showcase/ShowcasePage.tsx +++ b/packages/app/src/components/showcase/ShowcasePage.tsx @@ -5,6 +5,7 @@ import TextField from '@mui/material/TextField'; import InputAdornment from '@mui/material/InputAdornment'; import Chip from '@mui/material/Chip'; import Grid from '@mui/material/Grid'; +import Alert from '@mui/material/Alert'; import { Page, Header, Content } from '@backstage/core-components'; import SearchIcon from '@mui/icons-material/Search'; import { @@ -39,7 +40,7 @@ export const ShowcasePage = () => {
@@ -48,11 +49,18 @@ export const ShowcasePage = () => { Start a new service from a proven template, publish it to GitHub, - and make it findable through the catalog and answer engine. Pick a - card to jump straight to the live surface. + and make it findable through the catalog and docs search. Pick a + card to explore a portal feature or preview a software template. + + Catalog and TechDocs keyword search runs in this portal. Generated + answers are an extension you can build with the Answer Engine Worker + template, your own document index and AI Hub. The demo does not generate + answers. + + = { @@ -143,25 +144,27 @@ export const showcaseItems: ShowcaseItem[] = [ }, { id: 'answer-engine-search', - name: 'Answer Engine Search', + name: 'Catalog and Docs Search', description: - 'Ask questions across the catalog and docs and get cited answers grounded in your own content.', + 'Find services and documentation with keyword search across the catalog and TechDocs.', category: 'answer-engine', link: '/search', - linkLabel: 'Try search', - tags: ['ai', 'search', 'rag'], + linkLabel: 'Search catalog and docs', + tags: ['catalog', 'search', 'techdocs'], isRecommended: true, + availability: 'Built-in search', }, { id: 'answer-engine-worker-card', name: 'Answer Engine Worker Template', description: - 'Start your own answer engine worker with retrieval, citation handling and catalog registration built in.', + 'Scaffold an answer engine worker to connect to your own document index and AI Hub for cited answers.', category: 'answer-engine', link: templateShowcaseLink('answer-engine-worker'), linkLabel: 'Use template', tags: ['ai', 'rag', 'template'], isRecommended: true, + availability: 'Extension template', }, { id: 'platform-techdocs',