mirror of
https://github.com/JannisX11/blockbench.git
synced 2024-11-27 04:21:46 +08:00
Optimize sketchfab tag suggestions, add NoAI tag
This commit is contained in:
parent
ec9b085aac
commit
c22ca7848a
@ -4,11 +4,11 @@ BARS.defineActions(function() {
|
||||
if (elements.length === 0 || !Format) {
|
||||
return;
|
||||
}
|
||||
let tag_suggestions = ['low-poly', 'pixel-art'];
|
||||
let tag_suggestions = ['low-poly', 'pixel-art', 'NoAI'];
|
||||
if (Format.id !== 'free') tag_suggestions.push('minecraft');
|
||||
if (Format.id === 'skin') tag_suggestions.push('skin');
|
||||
if (!Mesh.all.length) tag_suggestions.push('voxel');
|
||||
let clean_project_name = Project.name.toLowerCase().replace(/[_.-]+/g, '-').replace(/[^a-z0-9-]+/, '')
|
||||
let clean_project_name = Project.name.toLowerCase().replace(/[_.-]+/g, '-').replace(/[^a-z0-9-]+/, '').replace(/-geo/, '');
|
||||
if (Project.name) tag_suggestions.push(clean_project_name);
|
||||
if (clean_project_name.includes('-')) tag_suggestions.safePush(...clean_project_name.split('-').filter(s => s.length > 2 && s != 'geo').reverse());
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user