PluginProbe
Yatra – Travel Booking & Tour Operator Software / 3.0.15
Yatra – Travel Booking & Tour Operator Software v3.0.15
3.0.15 3.0.14 3.0.14.1 3.0.14.2 3.0.12 3.0.13 3.0.11 3.0.10 3.0.9 3.0.8 3.0.7 3.0.6 3.0.5 3.0.5.1 3.0.4 3.0.3 3.0.2.9 3.0.2.7 3.0.2.8 3.0.2.6 trunk 1.0.0 2.0.0 2.0.1 2.0.10 All 83 releases
yatra / resources / js / lib / icon-map.ts

icon-map.ts in Yatra – Travel Booking & Tour Operator Software 3.0.15, at resources/js/lib/icon-map.ts

86 lines 1.4 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /**
2 * String → Lucide icon component map.
3 *
4 * White Label menu overrides persist icon choices as strings (so they
5 * survive JSON serialization in wp_options); this map turns them back
6 * into React components. Only icons listed in SELECTABLE_ICON_NAMES need
7 * an entry here — anything missing falls back to the default icon at
8 * render time.
9 */
10
11 import type { LucideIcon } from "lucide-react";
12 import {
13 LayoutDashboard,
14 MapPin,
15 Calendar,
16 CalendarClock,
17 CalendarDays,
18 Star,
19 BarChart3,
20 Settings,
21 Wrench,
22 FileText,
23 CreditCard,
24 Package,
25 UserCircle,
26 Users,
27 FolderTree,
28 Tag,
29 TrendingUp,
30 List,
31 Activity,
32 Crown,
33 Mail,
34 Key,
35 FileSignature,
36 Route,
37 BadgePercent,
38 Plane,
39 MessageSquare,
40 Puzzle,
41 RotateCcw,
42 Sparkles,
43 MessageCircle,
44 Network,
45 } from "lucide-react";
46
47 export const ICON_MAP: Record<string, LucideIcon> = {
48 LayoutDashboard,
49 MapPin,
50 Calendar,
51 CalendarClock,
52 CalendarDays,
53 Star,
54 BarChart3,
55 Settings,
56 Wrench,
57 FileText,
58 CreditCard,
59 Package,
60 UserCircle,
61 Users,
62 FolderTree,
63 Tag,
64 TrendingUp,
65 List,
66 Activity,
67 Crown,
68 Mail,
69 Key,
70 FileSignature,
71 Route,
72 BadgePercent,
73 Plane,
74 MessageSquare,
75 Puzzle,
76 RotateCcw,
77 Sparkles,
78 MessageCircle,
79 Network,
80 Tools: Wrench,
81 };
82
83 export function resolveIcon(name: string, fallback: LucideIcon): LucideIcon {
84 return ICON_MAP[name] ?? fallback;
85 }
86