|
| 1 | +const colors = [ |
| 2 | + { bg: '00BCD4', fg: 'ffffff' }, // Cyan |
| 3 | + { bg: 'FF9800', fg: 'ffffff' }, // Orange |
| 4 | + { bg: '8BC34A', fg: 'ffffff' }, // Green |
| 5 | + { bg: '3F51B5', fg: 'ffffff' }, // Indigo |
| 6 | + { bg: 'E91E63', fg: 'ffffff' }, // Pink |
| 7 | +]; |
| 8 | + |
| 9 | +const generateImageURL = (text, index) => { |
| 10 | + const { bg, fg } = colors[index % colors.length]; |
| 11 | + return `https://dummyimage.com/600x400/${bg}/${fg}&text=${encodeURIComponent(text)}`; |
| 12 | +}; |
| 13 | + |
1 | 14 | const courses = {
|
2 | 15 | 'course 1: oh my zsh setup': {
|
3 | 16 | title: 'Course 1: OH MY ZSH Setup',
|
4 | 17 | author: 'Dev Gautam Kumar',
|
5 |
| - image: 'https://dummyimage.com/600x400/00BCD4/fff&text=ZSH+Setup', // Cyan |
| 18 | + image: generateImageURL('ZSH Setup', 0), |
6 | 19 | description: 'Enhance your terminal experience with OH MY ZSH.',
|
7 | 20 | embed_link: 'https://www.youtube.com/embed/dCdX5v3IU60',
|
8 | 21 | contentFile: 'course1.md',
|
9 | 22 | },
|
10 | 23 | 'course 2: getting started with cli': {
|
11 | 24 | title: 'Course 2: Getting Started with CLI',
|
12 | 25 | author: 'Dev Gautam Kumar',
|
13 |
| - image: 'https://dummyimage.com/600x400/FF9800/fff&text=CLI+PART+1', // Orange |
| 26 | + image: generateImageURL('CLI PART 1', 1), |
14 | 27 | description: 'Kick your journey with CLI.',
|
15 | 28 | embed_link: 'https://www.youtube.com/embed/B4b9pX1lqU4',
|
16 | 29 | contentFile: 'course2.md',
|
17 | 30 | },
|
18 | 31 | 'course 3: playing in the shell': {
|
19 | 32 | title: 'Course 3: Playing in the Shell',
|
20 | 33 | author: 'Dev Gautam Kumar',
|
21 |
| - image: 'https://dummyimage.com/600x400/FF9800/fff&text=Playing+in+the+Shell', // Orange |
| 34 | + image: generateImageURL('Playing in the Shell', 2), |
22 | 35 | description: 'Get familiar with UNIX Shell.',
|
23 | 36 | embed_link: 'https://www.canva.com/design/DAGTIaBPhDM/a_G7XN1OSANZPmkoR_vLnQ/view?embed',
|
24 | 37 | contentFile: 'course3.md',
|
25 | 38 | },
|
26 | 39 | 'course 4: introduction to bourne shell': {
|
27 | 40 | title: 'Course 4: Introduction to Bourne Shell',
|
28 | 41 | author: 'Dev Gautam Kumar',
|
29 |
| - image: 'https://dummyimage.com/600x400/fff&text=B0urn3+$h3ll', // Orange |
| 42 | + image: generateImageURL('Bourne Shell', 3), |
30 | 43 | description: 'Get started with Shell Scripts.',
|
31 | 44 | embed_link: 'https://www.canva.com/design/DAGS2jSbGgI/NHrTUX9491PY9e31licHrA/view?embed',
|
32 | 45 | contentFile: 'course4.md',
|
33 | 46 | },
|
34 | 47 | 'course 5: bash scripting basics': {
|
35 | 48 | title: 'Course 5: Bash Scripting Basics',
|
36 | 49 | author: 'Sangharsh',
|
37 |
| - image: 'https://dummyimage.com/600x400/8BC34A/fff&text=Bash+Scripting+Basics', // Green |
| 50 | + image: generateImageURL('Bash Scripting Basics', 4), |
38 | 51 | description: 'Learn the basics of Bash scripting and automate tasks.',
|
39 | 52 | embed_link: 'https://www.youtube.com/embed/SPwyp2NG-bE',
|
40 | 53 | contentFile: 'course5.md',
|
41 | 54 | },
|
42 | 55 | 'course 6: termux for web testing': {
|
43 | 56 | title: 'Course 6: Termux For Web Testing',
|
44 | 57 | author: 'Dev Gautam Kumar',
|
45 |
| - image: 'https://dummyimage.com/600x400/8BC34A/fff&text=Termux+For+Web+Testing', // Green |
46 |
| - description: 'Hello there, I am dropping a Termux Guide mainly focused for Web Bug Hunting . It will help you to save time , esp if you are doing a full time Job like me. This might aid in your journey especially to those who are starting this bug hunting journey on Andorid.', |
| 58 | + image: generateImageURL('Termux For Web Testing', 0), |
| 59 | + description: 'Hello there, I am dropping a Termux Guide mainly focused for Web Bug Hunting. It will help you to save time, esp if you are doing a full-time job like me. This might aid in your journey, especially to those who are starting this bug hunting journey on Android.', |
47 | 60 | embed_link: 'https://dummyimage.com/600x400/8BC34A/fff&text=Termux+For+Web+Testing',
|
48 | 61 | contentFile: 'course6.md',
|
49 | 62 | }
|
|
0 commit comments