// ─────────────────────────────────────────────────────────────
// icons.jsx — Custom line icons (replacing emojis)
// All icons are 24x24 stroke SVGs, currentColor.
// ─────────────────────────────────────────────────────────────
window.AreaIcon = function AreaIcon({ id, size = 24 }) {
const props = {
width: size, height: size, viewBox: "0 0 24 24",
fill: "none", stroke: "currentColor", strokeWidth: 1.6,
strokeLinecap: "round", strokeLinejoin: "round"
};
switch (id) {
case 1: // Selección — target / aim
return (
);
case 2: // Onboarding — door / entrance with arrow
return (
);
case 3: // Desempeño — chart up with arrow
return (
);
case 4: // Desarrollo — graduation cap / books stacked
return (
);
case 5: // Clima — pulse / barometer
return (
);
case 6: // Bienestar — hand holding heart / sprout
return (
);
default:
return null;
}
};
// Level indicator: a stack of bars showing fill level 1-4 (like cellphone signal)
window.LevelBars = function LevelBars({ level = 1, color = "#009aba", size = "md", className = "" }) {
const dims = size === "lg"
? { w: 6, gap: 3, h: [10, 14, 18, 22] }
: size === "sm"
? { w: 3, gap: 2, h: [5, 7, 9, 11] }
: { w: 4, gap: 2, h: [7, 10, 13, 16] };
const totalW = dims.w * 4 + dims.gap * 3;
const totalH = dims.h[3];
return (
);
};
// Numeric level chip — for level options on survey
window.LevelDot = function LevelDot({ level, color, active = false }) {
// Filled segments based on level (1-4)
const segs = [0,1,2,3];
return (
{segs.map(i => (
))}
);
};
// Common UI icons
window.UIIcon = function UIIcon({ name, size = 16, strokeWidth = 2 }) {
const props = {
width: size, height: size, viewBox: "0 0 24 24",
fill: "none", stroke: "currentColor", strokeWidth,
strokeLinecap: "round", strokeLinejoin: "round"
};
switch(name) {
case 'arrow-right': return ;
case 'arrow-left': return ;
case 'clock': return ;
case 'check': return ;
case 'check-circle':return ;
case 'document': return ;
case 'download': return ;
case 'lock': return ;
case 'grid': return ;
case 'sparkle': return ;
case 'chart': return ;
case 'whatsapp': return ;
case 'mail': return ;
default: return null;
}
};
// Export the components that the views need
Object.assign(window, {
AreaIcon: window.AreaIcon,
LevelBars: window.LevelBars,
LevelDot: window.LevelDot,
UIIcon: window.UIIcon,
});