Comments (3)
Yeah. Currently the code in background.js only compares "hostRegExp" with the current URL "hostname". This doesn't include the path:
var urlParts = parseUrl(url);
...
if (urlParts.hostname.match(CONFIG.sites[siteKey].hostRegExp)) {
You could theoritically add code such as:
if (urlParts.path.match(CONFIG.sites[siteKey].pathRegExp)) {
to test the path.
However, I think skinning any website that contains /tfs/ in the path is a bit too risky. I'm sure few websites that are not Team Foundation Server have /tfs/ in the path, and we would accidentally skin them.
Is there any other way of detection TFS websites? (I'm not familiar with the product)
from darkness.
Thanks for the insight. To narrow /tfs/
further could be done by /tfs/DefaultCollection/` as that's unlikely to be used elsewhere.
That's helpful to know.
from darkness.
Yeah, limiting it to run only if path equals /tfs/DefaultCollection/ seems reasonable.
You could start by adding path matching to background.js:
if (CONFIG.sites[siteKey].pathRegExp && urlParts.path.match(CONFIG.sites[siteKey].pathRegExp)) {
This could run even before matching the hostname.
then adding "pathRegExp": "\/tfs\/DefaultCollection\/"
to the TFS site (under config.js)
from darkness.
Related Issues (20)
- Darkness vanishes as you scroll through Twitter HOT 1
- messenger.com new version breaks the themes HOT 4
- suggestion: visible elements HOT 1
- Elements on facebook.com not styled correctly HOT 1
- Firefox Extension Unavailable HOT 3
- The Upgrade Section
- negative trello image HOT 2
- Publish to Microsoft Edge Add-ons website HOT 1
- Poor support with github dark themes
- Messenger - messages have light gray background with medium gray text (unreadable) HOT 7
- Ms HOT 1
- Ms. HOT 1
- Enable extension in TikTok Web
- Darkness theme not applied to scrollbar on YouTube
- suggestion www.qwant.com
- Chrome extension stops working in random fashion
- Darkness icon gone and doesn't work anymore HOT 1
- "other actions" key not visible on Google Contacts website HOT 1
- Colors displayed in Google Calendar's color selection are different
- Google Photos: Action buttons covered by a solid color
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from darkness.