Skip to content

Commit af973fb

Browse files
CopilotdevakesuCopilot
authored
fix(mobile): scope desktop scroll CSS to pointer:fine + guard reactive-glow scroll listener — v1.1.3 (#106)
* Initial plan * fix: mobile scroll lag + bump to v1.1.3 - scope scroll-behavior/overscroll-behavior-y to @media (pointer: fine) - add touch device guard to reactive-glow.js scroll listener - bump version to 1.1.3 across package.json, README.md, SECURITY.md - update react-icons 5.5.0 → 5.6.0 - update GitHub Actions: harden-runner v2.15.1, setup-node v6.3.0, trivy-action v0.34.2, setup-buildx-action v4.0.0, login-action v4.0.0, build-push-action v7.0.0, sbom-action v0.23.0, upload-artifact v7.0.0, attest-build-provenance v4.1.0 Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com> * Update .github/workflows/deploy.yml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Devanarayanan <fusion@devakesu.com> * Update app/globals.css Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Devanarayanan <fusion@devakesu.com> --------- Signed-off-by: Devanarayanan <fusion@devakesu.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: devakesu <61821107+devakesu@users.noreply.github.com> Co-authored-by: Devanarayanan <fusion@devakesu.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 60331cb commit af973fb

7 files changed

Lines changed: 132 additions & 55 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,17 @@ jobs:
2424
actions: read # Allow cache restore without high-privilege write access
2525
steps:
2626
- name: Harden Runner
27-
uses: step-security/harden-runner@a90bcbc6539c36a85cdfeb73f7e2f433735f215b # v2.15.0
27+
uses: step-security/harden-runner@58077d3c7e43986b6b15fba718e8ea69e387dfcc # v2.15.1
2828
with:
2929
egress-policy: audit
3030

3131
- name: Checkout Code
3232
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
3333

3434
- name: Set up Node.js
35-
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
35+
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
3636
with:
37-
node-version: '20'
37+
node-version: '20.19.0'
3838

3939
- name: Install dependencies
4040
run: npm ci
@@ -56,15 +56,15 @@ jobs:
5656
contents: read
5757
steps:
5858
- name: Harden Runner
59-
uses: step-security/harden-runner@a90bcbc6539c36a85cdfeb73f7e2f433735f215b # v2.15.0
59+
uses: step-security/harden-runner@58077d3c7e43986b6b15fba718e8ea69e387dfcc # v2.15.1
6060
with:
6161
egress-policy: audit
6262

6363
- name: Checkout Code
6464
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
6565

6666
- name: Set up Node.js
67-
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
67+
uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
6868
with:
6969
node-version: '20'
7070

@@ -107,7 +107,7 @@ jobs:
107107
steps:
108108
# 🛡️ HARDEN RUNNER: Monitor network traffic
109109
- name: Harden Runner
110-
uses: step-security/harden-runner@a90bcbc6539c36a85cdfeb73f7e2f433735f215b # v2.15.0
110+
uses: step-security/harden-runner@58077d3c7e43986b6b15fba718e8ea69e387dfcc # v2.15.1
111111
with:
112112
egress-policy: audit
113113

@@ -116,7 +116,7 @@ jobs:
116116

117117
# 🔍 TRIVY: Scan for known vulnerabilities in dependencies
118118
- name: Run Trivy Vulnerability Scanner
119-
uses: aquasecurity/trivy-action@e368e328979b113139d6f9068e03accaed98a518 # v0.34.1
119+
uses: aquasecurity/trivy-action@97e0b3872f55f89b95b2f65b3dbab56962816478 # v0.34.2
120120
with:
121121
scan-type: 'fs'
122122
ignore-unfixed: true
@@ -148,18 +148,18 @@ jobs:
148148
image: ${{ steps.image.outputs.image }}
149149
steps:
150150
- name: Harden Runner
151-
uses: step-security/harden-runner@a90bcbc6539c36a85cdfeb73f7e2f433735f215b # v2.15.0
151+
uses: step-security/harden-runner@58077d3c7e43986b6b15fba718e8ea69e387dfcc # v2.15.1
152152
with:
153153
egress-policy: audit
154154

155155
- name: Checkout Code
156156
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
157157

158158
- name: Set up Docker Buildx
159-
uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3.12.0
159+
uses: docker/setup-buildx-action@4d04d5d9486b7bd6fa91e7baf45bbb4f8b9deedd # v4.0.0
160160

161161
- name: Log in to GitHub Container Registry
162-
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3.7.0
162+
uses: docker/login-action@b45d80f862d83dbcd57f89517bcf500b2ab88fb2 # v4.0.0
163163
with:
164164
registry: ghcr.io
165165
username: ${{ github.actor }}
@@ -173,7 +173,7 @@ jobs:
173173
echo "started_on=$TIMESTAMP" >> $GITHUB_OUTPUT
174174
175175
- name: Build and push Docker image
176-
uses: docker/build-push-action@10e90e3645eae34f1e60eeb005ba3a3d33f178e8 # v6.19.2
176+
uses: docker/build-push-action@d08e5c354a6adb9ed34480a06d141179aa583294 # v7.0.0
177177
id: build
178178
with:
179179
context: .
@@ -220,14 +220,14 @@ jobs:
220220
221221
# 📦 GENERATE SBOM
222222
- name: Generate SBOM
223-
uses: anchore/sbom-action@28d71544de8eaf1b958d335707167c5f783590ad # v0.22.2
223+
uses: anchore/sbom-action@17ae1740179002c89186b61233e0f892c3118b11 # v0.23.0
224224
with:
225225
image: ${{ steps.image.outputs.image }}
226226
format: cyclonedx-json
227227
output-file: sbom.json
228228

229229
- name: Upload SBOM
230-
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
230+
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
231231
with:
232232
name: sbom
233233
path: sbom.json
@@ -286,7 +286,7 @@ jobs:
286286
287287
# 🏆 GITHUB ATTESTATION
288288
- name: Generate GitHub Attestation
289-
uses: actions/attest-build-provenance@977bb373ede98d70efdf65b84cb5f73e068dcc2a # v3
289+
uses: actions/attest-build-provenance@a2bbfa25375fe432b6a289bc6b6cd05ecd0c4c32 # v4.1.0
290290
with:
291291
subject-name: ghcr.io/${{ github.repository }}
292292
subject-digest: ${{ steps.build.outputs.digest }}

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
**Where code meets conscience.** A brutalist × cyberpunk portfolio built with Next.js 16.
44

5-
[![Version](https://img.shields.io/badge/version-1.1.2-cyan?logo=github)](package.json)
5+
[![Version](https://img.shields.io/badge/version-1.1.3-cyan?logo=github)](package.json)
66
[![Security: SLSA Level 3](https://img.shields.io/badge/SLSA-Level%203-brightgreen)](https://github.com/devakesu/devakesu-web/attestations)
77
[![Security Scan: Trivy](https://img.shields.io/badge/Security-Trivy%20Scanned-blue)](.github/workflows/deploy.yml)
88
[![Attestations](https://img.shields.io/badge/Attestations-Enabled-success)](https://github.com/devakesu/devakesu-web/attestations)
@@ -414,4 +414,4 @@ _Love is the only way to rescue humanity from all evils._
414414
---
415415

416416
**Last Updated**: March 02, 2026
417-
**Version**: 1.1.2
417+
**Version**: 1.1.3

SECURITY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,4 +149,4 @@ We appreciate security researchers who responsibly disclose vulnerabilities.
149149
---
150150

151151
**Last Updated**: March 02, 2026
152-
**Version**: 1.1.2
152+
**Version**: 1.1.3

app/globals.css

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
@import 'tailwindcss';
22

33
html {
4-
scroll-behavior: smooth;
54
scroll-padding-top: 0px;
6-
/* Improve mouse wheel scrolling smoothness */
7-
overscroll-behavior-y: contain;
8-
scroll-snap-type: none;
95
/* Mobile optimization */
106
-webkit-font-smoothing: antialiased;
117
-moz-osx-font-smoothing: grayscale;
128
text-rendering: optimizeLegibility;
139
}
1410

11+
/* Desktop-only scroll behavior — avoids killing iOS momentum / rubber-band scrolling */
12+
@media (pointer: fine) {
13+
html {
14+
scroll-behavior: smooth;
15+
/* Improve mouse wheel scrolling smoothness */
16+
overscroll-behavior-y: contain;
17+
scroll-snap-type: none;
18+
}
19+
}
20+
1521
body {
1622
/* Enable smooth momentum scrolling on all platforms */
1723
-webkit-overflow-scrolling: touch;

package-lock.json

Lines changed: 71 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "devakesu-web",
3-
"version": "1.1.2",
3+
"version": "1.1.3",
44
"private": true,
55
"engines": {
66
"node": ">=20.19.0"
@@ -18,7 +18,7 @@
1818
"next": "16.1.6",
1919
"react": "19.2.4",
2020
"react-dom": "19.2.4",
21-
"react-icons": "5.5.0"
21+
"react-icons": "5.6.0"
2222
},
2323
"devDependencies": {
2424
"@tailwindcss/postcss": "4.2.1",

public/js/reactive-glow.js

Lines changed: 32 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -47,35 +47,42 @@
4747
{ passive: true }
4848
);
4949

50-
// Scroll velocity → pulse strength (throttled with rAF)
51-
window.addEventListener(
52-
'scroll',
53-
() => {
54-
if (!scrollTicking) {
55-
window.requestAnimationFrame(() => {
56-
const delta = Math.abs(window.scrollY - lastScrollY);
57-
scrollSpeed = Math.min(delta / 100, 2.5);
58-
lastScrollY = window.scrollY;
50+
// Skip scroll pulse effect on touch devices (causes jank during mobile scroll)
51+
const isTouchDevice =
52+
typeof window.matchMedia === 'function' &&
53+
window.matchMedia('(pointer: coarse)').matches;
5954

60-
// Update current scale and apply with cursor position to avoid jumps
61-
currentScale = 1 + scrollSpeed * 0.3;
62-
glow.style.transform = `translate3d(${lastCursorX}px, ${lastCursorY}px, 0) translate(-50%, -50%) scale(${currentScale})`;
63-
glow.style.opacity = Math.min(0.4 + scrollSpeed * 0.25, 1);
55+
// Scroll velocity → pulse strength (throttled with rAF)
56+
if (!isTouchDevice) {
57+
window.addEventListener(
58+
'scroll',
59+
() => {
60+
if (!scrollTicking) {
61+
window.requestAnimationFrame(() => {
62+
const delta = Math.abs(window.scrollY - lastScrollY);
63+
scrollSpeed = Math.min(delta / 100, 2.5);
64+
lastScrollY = window.scrollY;
6465

65-
clearTimeout(cooldownId);
66-
cooldownId = setTimeout(() => {
67-
currentScale = 1;
66+
// Update current scale and apply with cursor position to avoid jumps
67+
currentScale = 1 + scrollSpeed * 0.3;
6868
glow.style.transform = `translate3d(${lastCursorX}px, ${lastCursorY}px, 0) translate(-50%, -50%) scale(${currentScale})`;
69-
glow.style.opacity = 0.4;
70-
}, 200);
69+
glow.style.opacity = Math.min(0.4 + scrollSpeed * 0.25, 1);
7170

72-
scrollTicking = false;
73-
});
74-
scrollTicking = true;
75-
}
76-
},
77-
{ passive: true }
78-
);
71+
clearTimeout(cooldownId);
72+
cooldownId = setTimeout(() => {
73+
currentScale = 1;
74+
glow.style.transform = `translate3d(${lastCursorX}px, ${lastCursorY}px, 0) translate(-50%, -50%) scale(${currentScale})`;
75+
glow.style.opacity = 0.4;
76+
}, 200);
77+
78+
scrollTicking = false;
79+
});
80+
scrollTicking = true;
81+
}
82+
},
83+
{ passive: true }
84+
);
85+
}
7986

8087
// Click Burst + Haptic Feedback
8188
document.addEventListener(

0 commit comments

Comments
 (0)