未验证 提交 c3f58ff8 编写于 作者: M Mr.doob 提交者: GitHub

Merge pull request #18779 from makc/better-search-2

Examples: Make examples searchable by tags.
......@@ -391,3 +391,14 @@ var files = {
"misc_uv_tests"
]
};
var tags = {
"webgl_clipping_intersection": [ "csg", "solid" ],
"webgl_fire": [ "smoke" ],
"webgl_materials_translucency": [ "subsurface", "scattering" ],
"webgl_postprocessing_unreal_bloom": [ "glow" ],
"webgl_postprocessing_unreal_bloom_selective": [ "glow" ],
"webgl_shadowmap_csm": [ "cascade" ],
"webgl_shadowmap_pcss": [ "soft" ],
"webgl_simple_gi": [ "global", "illumination" ]
};
......@@ -249,7 +249,9 @@
var link = links[ file ];
var name = getName( file );
var res = file.match( exp );
var matchCandidates = ( tags[ file ] || [] ).slice();
matchCandidates.push( file );
var res = matchCandidates.join( ' ' ).match( exp );
var text;
if ( res && res.length > 0 ) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册