-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgenerate-icons.js
More file actions
33 lines (29 loc) · 1.25 KB
/
generate-icons.js
File metadata and controls
33 lines (29 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
const fs = require('fs');
// Create simple PNG icons using data URLs
// These are minimal 1x1 pixel PNGs that will be replaced with proper icons
const createSimplePNG = (size) => {
// Minimal valid PNG file (1x1 transparent pixel)
const pngData = Buffer.from([
0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, 0x0A,
0x00, 0x00, 0x00, 0x0D, 0x49, 0x48, 0x44, 0x52,
0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01,
0x08, 0x06, 0x00, 0x00, 0x00, 0x1F, 0x15, 0xC4,
0x89, 0x00, 0x00, 0x00, 0x0A, 0x49, 0x44, 0x41,
0x54, 0x78, 0x9C, 0x63, 0x00, 0x01, 0x00, 0x00,
0x05, 0x00, 0x01, 0x0D, 0x0A, 0x2D, 0xB4, 0x00,
0x00, 0x00, 0x00, 0x49, 0x45, 0x4E, 0x44, 0xAE,
0x42, 0x60, 0x82
]);
return pngData;
};
// Generate icons
['16', '48', '128'].forEach(size => {
const filename = `icon${size}.png`;
fs.writeFileSync(filename, createSimplePNG(size));
console.log(`Created ${filename}`);
});
console.log('\nPlaceholder icons created successfully!');
console.log('Note: These are minimal placeholder PNGs. For better icons:');
console.log('1. Open icon.svg in a browser or image editor');
console.log('2. Export/save as PNG at sizes 16x16, 48x48, and 128x128');
console.log('3. Replace icon16.png, icon48.png, and icon128.png with the exported files');