GithubHelp home page GithubHelp logo

chromedotfiles's People

Contributors

matthewhadley avatar uri avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

chromedotfiles's Issues

Doesn't work - outdated?

Hey,

it doesn't work on the latest Chrome Build (90.0.4430.93) (Official Build) (64-Bit).
I followed the instruction steps and tried creating the 2 example files just as you did but neither of them caused any difference on google.com

Greetings,
ars4l4n

Repo for .js and .css files?

I use something similar on Safari, and wondered if there was a central repo for shared scripts and styles?

A bit like userscripts.org was for those things.

How to access window object of top frame?

How can I access the window object of the top frame? The Chrome dotfiles content script has its own window object and window.top doesn't return the window of the top frame.

image

image

I want to do the following for Sharepoint because they open every freaking link in a new browser tab (second part works fine, but they use javascript/window.open for some of the links):

window.open = url => location.href = url

for (const a of document.querySelectorAll('a')) {
  a.removeAttribute('target')
}

appending CSS

I'm playing with the CSS injection and added this to a github.com.css file:

body {
  background-color: #F00;
}

But it had no effect. looking at the Elements tab in chrome, I see that it's inserted before the page's CSS
image

So how do I override existing CSS? Shouldn't appending the CSS be the default? Or maybe there could be a github.com.append.css file that is treated differently at the very least?

Unchecked runtime.lastError while running tabs.insertCSS: Failed to load file:

Adding console.log to background.js, when going to create this issue it says:

// i'm logging here
tab: https://github.com/diffsky/chromedotfiles/issues/new
match: Object {protocol: "https:", host: "github.com", hostname: "github.com", port: undefined, pathname: "/diffsky/chromedotfiles/issues/new"…}

// chrome throws these errors
extensions::sendRequest:82 Unchecked runtime.lastError while running tabs.insertCSS: Failed to load file: "chromedotfiles/github.com.css". 
    at chrome-extension://hocrtbokejcqajcfomloelehcgookikb/background.js:23:17
extensions::sendRequest:82 Unchecked runtime.lastError while running tabs.executeScript: Failed to load file: "chromedotfiles/github.com.js". 
    at chrome-extension://hocrtbokejcqajcfomloelehcgookikb/background.js:26:17

I tried placing a file in 2 different places to see if it'd work, but doesn't seem to:

~/.chromedotfiles/github.com.js
~/chromedotfiles/github.com.js

Is there any other setup I have to do? Do you have to do anything with certificates like with dotjs?

Does it depend on a specific version of chrome or operating system? I haven't updated my mac in a while, still using 10.9.2, not sure if that's a problem.

Would love to get this working :)

Fix description of plugin: Directory for injected files

I just needed a lot of time to figure out, that the description of the addon saying place files to ~/.chromedotfiles/{domain}.(js|css) is wrong. You should change this (stored int the manifest.json) and the description of the repository (on GitHub just below the tabs) to something like {repository}/chromedotfiles/{domain}.(js|css) so it matches what your README says.

a few improvements made

First off, thank you for your work on this.

I forked the project and made a few improvements you might be interested in.

added default.css

works the same as default.js

loading css earlier

CSS is now applied instantaneously. No more visible delay.

added support to load multiple JS files

can now organize your files and load vendors without having everything meshed into one file.

Example:

// load dependencies in that exact order
loadJS(['vendor/jquery.js', 'vendor/jquery-time-ago.js', 'vendor/underscore.js']);

// load and execute my callback
loadJS('vendor/jquery.js', "callback");
function callback() {}


// load and execute my callback in namespace
loadJS('vendor/jquery.js', 'App.callback');
var App = {
  callback: function() {
  }
};

updated readme

Update readme to explain changes + added example directory

Pick and choose whatever you wanna pull into your repo.
Forked here https://github.com/hbt/chromedotfiles

Take care

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.