summaryrefslogtreecommitdiff
path: root/source/features/same-branch-author-commits.tsx
blob: 84afda1c7892bf56c3a6c89b9d6693665a955203 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import select from 'select-dom';
import * as pageDetect from 'github-url-detection';

import features from '../feature-manager.js';

function init(): void {
	for (const author of select.all('.js-navigation-container a.commit-author')) {
		author.pathname = location.pathname;
	}
}

void features.add(import.meta.url, {
	include: [
		pageDetect.isRepoCommitList,
	],
	awaitDomReady: true, // Small page
	init,
});