-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsplice-css.cjs
More file actions
60 lines (50 loc) · 2.1 KB
/
Copy pathsplice-css.cjs
File metadata and controls
60 lines (50 loc) · 2.1 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
const fs = require('fs');
const path = require('path');
const cssPath = path.join(__dirname, 'src', 'index.css');
let lines = fs.readFileSync(cssPath, 'utf8').split('\n');
const insertContent = `-webkit-text-fill-color: transparent;
background-clip: text;
margin-bottom: 10px;
}
.certificates-container {
width: 100%;
max-width: 100%;
overflow: hidden;
padding: 40px 0;
mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
-webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
&:has(.certificate-card:hover) .certificate-card:not(:hover) {
opacity: 0.3;
transform: scale(0.95);
}
.certificates-marquee {
display: flex;
gap: 30px;
width: max-content;
animation: marqueeScroll 40s linear infinite;
&:hover {
animation-play-state: paused;
}
}
.certificate-card {
flex: 0 0 400px;
height: 480px;
background: linear-gradient(145deg, rgba(255, 0, 0, 0.08), rgba(142, 0, 0, 0.05));
backdrop-filter: blur(10px);
border: 1px solid rgba(255, 0, 0, 0.2);
padding: 40px 35px;
border-radius: 25px;
box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.5);
transition: transform 0.3s ease, box-shadow 0.3s ease;
display: flex;
flex-direction: column;
&:hover {
transform: translateY(-10px);
box-shadow: 0 30px 60px -12px rgba(255, 0, 0, 0.3);
}
`.split('\n');
// Find where to insert (at line 452 which is index 451)
// We want to replace index 452 (line 453)
lines.splice(452, 1, ...insertContent);
fs.writeFileSync(cssPath, lines.join('\n'));
console.log('CSS arrays spliced successfully');