@@ -20,7 +20,7 @@ export const VERSION_PRESETS = [
2020 { label : "≥ 1.0" , value : ">=1.0.0" } ,
2121 { label : "< 1.0" , value : "<1.0.0" }
2222] ;
23- export const FILTERS_NAME = new Set ( [ "package" , "version" , "flag" , "license" , "author" , "ext" , "builtin" , "size" ] ) ;
23+ export const FILTERS_NAME = new Set ( [ "package" , "version" , "flag" , "license" , "author" , "ext" , "builtin" , "size" , "highlighted" ] ) ;
2424export const PRESETS = [
2525 { id : "has_vulnerabilities" , filter : "flag" , value : "hasVulnerabilities" } ,
2626 { id : "has_scripts" , filter : "flag" , value : "hasScript" } ,
@@ -32,6 +32,8 @@ export const PRESETS = [
3232export const FILTER_HAS_HELPERS = new Set ( [ "license" , "ext" , "builtin" , "author" ] ) ;
3333// Filters where the mode persists after selection (multi-select)
3434export const FILTER_MULTI_SELECT = new Set ( [ "flag" ] ) ;
35+ // Filters that auto-confirm immediately on selection (no text input needed)
36+ export const FILTER_INSTANT_CONFIRM = new Set ( [ "highlighted" ] ) ;
3537
3638/**
3739 * Returns per-flag package counts across the full linker.
@@ -243,6 +245,8 @@ function matchesFilter(opt, filterName, inputValue) {
243245 }
244246 case "flag" :
245247 return opt . flags . includes ( inputValue ) ;
248+ case "highlighted" :
249+ return inputValue === "all" ? opt . isHighlighted === true : opt . isHighlighted !== true ;
246250 default :
247251 return false ;
248252 }
0 commit comments