Skip to content

Commit d3a68db

Browse files
authored
Prepare v2.5.0 (#78)
2 parents ef29f6f + a473a51 commit d3a68db

File tree

18 files changed

+452
-426
lines changed

18 files changed

+452
-426
lines changed

.github/actions/auth/package-lock.json

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

.github/actions/auth/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"playwright": "^1.56.1"
1818
},
1919
"devDependencies": {
20-
"@types/node": "^24.9.2",
20+
"@types/node": "^24.10.1",
2121
"typescript": "^5.9.3"
2222
}
2323
}

.github/actions/file/package-lock.json

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

.github/actions/file/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,11 @@
1414
"type": "module",
1515
"dependencies": {
1616
"@actions/core": "^1.11.1",
17-
"@octokit/core": "^7.0.5",
18-
"@octokit/plugin-throttling": "^11.0.2"
17+
"@octokit/core": "^7.0.6",
18+
"@octokit/plugin-throttling": "^11.0.3"
1919
},
2020
"devDependencies": {
21-
"@types/node": "^24.9.2",
21+
"@types/node": "^24.10.1",
2222
"typescript": "^5.9.3"
2323
}
2424
}

.github/actions/file/src/openIssue.ts

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,28 @@ import type { Finding } from './types.d.js';
33
import * as url from 'node:url'
44
const URL = url.URL;
55

6+
/** Max length for GitHub issue titles */
7+
const GITHUB_ISSUE_TITLE_MAX_LENGTH = 256;
8+
9+
/**
10+
* Truncates text to a maximum length, adding an ellipsis if truncated.
11+
* @param text Original text
12+
* @param maxLength Maximum length of the returned text (including ellipsis)
13+
* @returns Either the original text or a truncated version with an ellipsis
14+
*/
15+
function truncateWithEllipsis(text: string, maxLength: number): string {
16+
return text.length > maxLength ? text.slice(0, maxLength - 1) + '…' : text;
17+
}
18+
619
export async function openIssue(octokit: Octokit, repoWithOwner: string, finding: Finding) {
720
const owner = repoWithOwner.split('/')[0];
821
const repo = repoWithOwner.split('/')[1];
922

1023
const labels = [`${finding.scannerType} rule: ${finding.ruleId}`, `${finding.scannerType}-scanning-issue`];
11-
const title = `Accessibility issue: ${finding.problemShort[0].toUpperCase() + finding.problemShort.slice(1)} on ${new URL(finding.url).pathname}`;
24+
const title = truncateWithEllipsis(
25+
`Accessibility issue: ${finding.problemShort[0].toUpperCase() + finding.problemShort.slice(1)} on ${new URL(finding.url).pathname}`,
26+
GITHUB_ISSUE_TITLE_MAX_LENGTH
27+
);
1228
const solutionLong = finding.solutionLong
1329
?.split("\n")
1430
.map((line) =>

.github/actions/find/package-lock.json

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

.github/actions/find/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"playwright": "^1.56.1"
1919
},
2020
"devDependencies": {
21-
"@types/node": "^24.9.2",
21+
"@types/node": "^24.10.1",
2222
"typescript": "^5.9.3"
2323
}
2424
}

0 commit comments

Comments
 (0)