let tags = [ "animal", "scenery", "people", "life", "plant", "girl", "flower", "fantasy", "data_good", "mandala", "food", "special_date", "nature", "cat", "landscape", "dog", "countryside", "forest", "ban", "flowers", "bird", "river", "mountains", "snow", "recommend", "winter", "house", "village", "heart", "Christmas", "garden", "butterfly", "fashion", "summer", "farm", "boy", "place", "sea", "culture", "car", "horse", "lake", "autumn", "tree", "building", "wild", "woman", "room", "park", "ocean", "meadow", "rabbit", "family", "patterns", "home", "mountain", "halloween", "bridge", "friends", "city", "baby", "sunset", "simple", "boat", "window", "plants", "man", "trees", "fruit", "rose", "vacation", "evening", "castle", "snowman", "street", "tiger", "grass", "lady", "child", "vintage", "holiday", "pasture", "deer", "sweet", "night", "beach", "travel", "dress", "fish", "couple", "view", "fairy", "harvest", "yard", "sky", "toys", "wildflowers", "love", "pumpkin", "water", "transportation", "birds", "rocks", "famous", "downtown", "ice", "bear", "spring", "road", "wolf", "unicorn", "lion", "stone", "magic", "cake", "book", "furniture", "children", "fox", "cartoon", "duck", "owl", "squirrel", "sport", // "angel", // "cub", // "decorations", // "pond", // "sheep", // "fence", // "interior", // "coastline", // "beauty", // "chicken", // "train", // "mermaid", // "history", // "moon", // "picnic", // "bedroom", // "blooming", // "sunflower", // "mystery", // "lovers", // "stairs", // "walk", // "jungle", // "livingroom", // "thanksgiving", // "kingdom", // "mother and daughter", // "domestic", // "mother", // "lotus", // "dragon", // "panda", // "pet", // "cottage", // "tea", // "coast", ] function getRandomDarkColor() { // 生成 0 到 127 之间的随机整数,因为较深的颜色分量值较低 const r = Math.floor(Math.random() * 222); const g = Math.floor(Math.random() * 222); const b = Math.floor(Math.random() * 222); // 将 RGB 值转换为十六进制字符串 const toHex = (num) => { const hex = num.toString(16); return hex.length === 1 ? `0${hex}` : hex; }; // 返回 RGB 十六进制颜色字符串 return `#${toHex(r)}${toHex(g)}${toHex(b)}`; } tags = tags.map(e => { return { tag: e, color: getRandomDarkColor() } }); module.exports = tags;