// Module ID: 4495 // Function ID: 4496 // Name: CustomThemesRandomUtils // Dependencies: [672, 2] // Exports: generateRandomColorOptions // Module 4495 (CustomThemesRandomUtils) import _modDef672 from "module_672" /* 672 */; import size from "module_2" /* 2 */; let items = ["#94E0CF", "#9AF0B1", "#9A90FF", "#9A53FF", "#FDA6E4", "#FFE6C0", "#EFB4AA", "#56B69F", "#29C566", "#5348CA", "#6D24D4", "#CA48C8", "#F0AE29", "#DF4232"]; const ColorType = { SOLID: "solid", GRADIENT: "gradient" }; let obj2 = { TWO_COLOR: "two-color", ANALOGOUS: "analogous", COMPLEMENTARY: "complementary", SPLIT_COMPLEMENTARY: "split-complementary", TRIADIC: "triadic" }; let items1 = [, , , ]; ({ ANALOGOUS: arr2[0], COMPLEMENTARY: arr2[1], SPLIT_COMPLEMENTARY: arr2[2], TRIADIC: arr2[3] } = obj2); const result = size.fileFinishedImporting("modules/client_themes/CustomThemesRandomUtils.tsx"); export const COLOR_PALETTE = items; export { ColorType }; export const GradientType = obj2; export const generateRandomColorOptions = function generateRandomColorOptions() { const tmp = length2[Math.floor(Math, Math.random(Math) * length2.length)]; const tmp2 = length[Math.floor(Math, Math.random(Math) * length.length)]; let str = "path2"; if (Math.random() < 0.2) { str = "path1"; } if ("path1" === str) { const _Math = Math; const _Math2 = Math; let tmp3 = items; const rounded = Math.floor(Math.random() * items.length); const _Math3 = Math; const _Math4 = Math; let rounded1 = Math.floor(Math.random() * items.length); if (rounded1 === rounded) { do { let _Math5 = Math; let _Math6 = Math; rounded1 = Math.floor(Math.random() * items.length); tmp3 = items; } while (rounded1 === rounded); } items = [tmp3[rounded], tmp3[rounded1]]; let obj = { type: null, colors: null, angle: null, intensity: null, gradientType: null }; obj.type = obj.GRADIENT; obj.colors = items; obj.angle = tmp2; obj.intensity = tmp; obj.gradientType = obj2.TWO_COLOR; return obj; } else { const _Math7 = Math; const _Math8 = Math; const _Math9 = Math; const _Math10 = Math; const tmp11 = items1[Math.floor(Math, Math.random(Math) * items1.length)]; obj2 = { type: obj.GRADIENT, colors: (function generateColorHarmony(items, items1) { try { let obj = _modDef672(items); value = obj.get("hsl.h"); const value3 = obj.get("hsl.s"); const value4 = obj.get("hsl.l"); if (constants.ANALOGOUS === items1) { return (function generateAnalogousColors(items, value3, value4, value) { const obj = closure_1_0(672); items = [closure_1_0(672).hsl(value - 30, value3, value4).hex(), items, ]; const hslResult = closure_1_0(672).hsl(value - 30, value3, value4); const obj3 = closure_1_0(672); items[2] = closure_1_0(672).hsl(value + 30, value3, value4).hex(); return items; })(items, value3, value4, value); } else if (tmp8.COMPLEMENTARY === items1) { return (function generateComplementaryColors(items, value3, value4, value) { const obj = closure_1_0(672); const hexResult = closure_1_0(672).hsl((value + 180) % 360, value3, value4).hex(); items = [items, , ]; const hslResult = closure_1_0(672).hsl((value + 180) % 360, value3, value4); const obj3 = closure_1_0(672); items[1] = closure_1_0(672).mix(items, hexResult, 0.5).hex(); items[2] = hexResult; return items; })(items, value3, value4, value); } else if (tmp8.SPLIT_COMPLEMENTARY === items1) { return (function generateSplitComplementaryColors(items, value3, value4, value) { items = [items, , ]; const obj = closure_1_0(672); items[1] = closure_1_0(672).hsl((value + 150) % 360, value3, value4).hex(); const hslResult = closure_1_0(672).hsl((value + 150) % 360, value3, value4); const obj3 = closure_1_0(672); items[2] = closure_1_0(672).hsl((value + 210) % 360, value3, value4).hex(); return items; })(items, value3, value4, value); } else if (tmp8.TRIADIC === items1) { return (function generateTriadicColors(items, value3, value4, value) { items = [items, , ]; const obj = closure_1_0(672); items[1] = closure_1_0(672).hsl((value + 120) % 360, value3, value4).hex(); const hslResult = closure_1_0(672).hsl((value + 120) % 360, value3, value4); const obj3 = closure_1_0(672); items[2] = closure_1_0(672).hsl((value + 240) % 360, value3, value4).hex(); return items; })(items, value3, value4, value); } else { items = [items]; return items; } } catch (err) { items1 = [tmp]; return items1; } })(items[Math.floor(Math, Math.random(Math) * items.length)], tmp11), angle: tmp2, intensity: tmp, gradientType: tmp11 }; return obj2; } };