We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
isOrganizationRepo
1 parent 68b74c1 commit 77bff52Copy full SHA for 77bff52
index.ts
@@ -144,6 +144,8 @@ collect.set('isNotifications', [
144
145
export const isOrganizationProfile = (): boolean => exists('meta[name="hovercard-subject-tag"][content^="organization"]');
146
147
+export const isOrganizationRepo = (): boolean => Boolean(document.querySelector<HTMLElement>('[data-owner-scoped-search-url]')?.dataset.ownerScopedSearchUrl!.startsWith('/org'));
148
+
149
export const isOrganizationDiscussion = (url: URL | HTMLAnchorElement | Location = location): boolean => /^orgs\/[^/]+\/teams\/[^/]+($|\/discussions)/.test(getCleanPathname(url));
150
collect.set('isOrganizationDiscussion', [
151
'https://github.com/orgs/refined-github/teams/core-team/discussions?pinned=1',
0 commit comments