Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: Legacy filters
shortDescription: Legacy version of the Filters component. Used to filter the items of a list or table.
category: Selection and input
category: Deprecated
keywords:
- filters
- filtering
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ keywords:
- color use
- black and white
- grayscale
icon: ColorsIcon
icon: ColorIcon
---

# Color → {frontmatter.title}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
title: Spacial organization
order: 1
icon: BuyButtonButtonLayoutIcon
icon: LayoutBuyButtonHorizontalIcon
keywords:
- layout
- layout components
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ keywords:
- type styles
- font sizes
- fonts
icon: TextAlignmentLeftIcon
icon: TextAlignLeftIcon
hideChildren: true
order: 1
---
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ keywords:
- type styles
- font sizes
- fonts
icon: TypeIcon
icon: TextFontIcon
hideChildren: true
order: 2
---
Expand Down
9 changes: 7 additions & 2 deletions polaris.shopify.com/pages/api/search/v0/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ import {slugify, stripMarkdownLinks} from '../../../../src/utils/various';
import pages from '../../../../.cache/site';

type IndexablePages = {
[K in keyof typeof pages as (typeof pages)[K]['frontMatter'] extends {
[K in keyof typeof pages as typeof pages[K]['frontMatter'] extends {
noIndex: true;
}
? never
: K]: (typeof pages)[K];
: K]: typeof pages[K];
};

const searchablePages = Object.fromEntries(
Expand Down Expand Up @@ -70,12 +70,17 @@ const getSearchResults = (query?: string) => {
title,
description = '',
category = '',
internalOnly,
} = searchablePages[slug].frontMatter as FrontMatter;

const url = category
? `/components/${slugify(category)}/${slugify(title)}`
: `/components/${slugify(title)}`;

if (internalOnly) {
return;
}

results.push({
id: slugify(`components ${title}`),
category: 'components',
Expand Down