mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-03-24 06:32:12 -03:00
Add NSFW browse control functionality - Done
This commit is contained in:
@@ -90,6 +90,7 @@ export const BASE_MODEL_CLASSES = {
|
||||
};
|
||||
|
||||
export const NSFW_LEVELS = {
|
||||
UNKNOWN: 0,
|
||||
PG: 1,
|
||||
PG13: 2,
|
||||
R: 4,
|
||||
|
||||
@@ -151,4 +151,15 @@ export function initBackToTop() {
|
||||
|
||||
// Initial check
|
||||
toggleBackToTop();
|
||||
}
|
||||
|
||||
export function getNSFWLevelName(level) {
|
||||
if (level === 0) return 'Unknown';
|
||||
if (level >= 32) return 'Blocked';
|
||||
if (level >= 16) return 'XXX';
|
||||
if (level >= 8) return 'X';
|
||||
if (level >= 4) return 'R';
|
||||
if (level >= 2) return 'PG13';
|
||||
if (level >= 1) return 'PG';
|
||||
return 'Unknown';
|
||||
}
|
||||
Reference in New Issue
Block a user