Skip to content

Commit

Permalink
feat(viz-gallery): add search weight for viz-name (#19581)
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenLYZ committed May 13, 2022
1 parent 1cd002e commit e625c03
Showing 1 changed file with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -579,7 +579,17 @@ export default function VizTypeGallery(props: VizTypeGalleryProps) {
new Fuse(chartMetadata, {
ignoreLocation: true,
threshold: 0.3,
keys: ['value.name', 'value.tags', 'value.description'],
keys: [
{
name: 'value.name',
weight: 4,
},
{
name: 'value.tags',
weight: 2,
},
'value.description',
],
}),
[chartMetadata],
);
Expand Down

0 comments on commit e625c03

Please sign in to comment.