Giter VIP home page Giter VIP logo

web-media-controller's People

Contributors

alexesprit avatar brookst avatar doronbehar avatar f1u77y avatar gutierri 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

web-media-controller's Issues

Spotify connector no longer returning artist/track information

Controls do still work and I get the current position, but do not get track length, artist, or track name. I'm not sure when this stopped working, rolling back to previous versions of this addon doesn't seem to fix the problem. Other sites (Youtube and Soundcloud) still work as expected.

OS: Arch Linux
Native: wmc-mpris from web-media-controller-mpris-git AUR package, r96.d56d02a
Browser: Firefox 69

deezer connector not working

Can someone please test the deezer connector? It doesn't work for me - I see the "Stopped" sign in the extension indicator..

Suggestion to update contributing guide

After changes made in 033e6de there's no need to call the BaseConnector.observe function in the connector constructor. But this is still described in CONTRIBUTING.md.

I think removing the "Setup an observer..." section is not a best solution. Probably, we could list different ways to listen track info changes instead.

Also, the last section ("Lint your code") is quite hard to read. The first paragraph could be splitted:

Lint your code (Click to expand)

Run npx grunt eslint:target to check if your code conforms to the project code style.
npx grunt eslint:fix might fix some errors for you automatically. Please make sure
npx grunt eslint:target reports no errors before sumbitting pull request.

Please don't disable eslint rules in files. The one exception is scripts located
in src/inject: they could use website internals (which of course might not conform
to this project code style), so feel free to disable some rules in these scripts
(see src/inject/vk.js for example). Warnings reported by eslint could be
discussed. Errors could also be discussed but only if you're absolutely sure
you need to break some rule to implement a feature or fix some bug.

I'd also ask you to set up your editor or IDE to work with EditorConfig.
It could save some time for both of us.

Run `npx grunt eslint:target` to check if your code conforms to the project code style.
`npx grunt eslint:fix` might fix some errors for you automatically. Please make sure
`npx grunt eslint:target` reports no errors before sumbitting pull request.

Please don't disable `eslint` rules in files. The one exception is scripts located 
in `src/inject`: they could use website internals (which of course might not conform 
to this project code style), so feel free to disable some rules in these scripts
(see `src/inject/vk.js` for example). Warnings reported by `eslint` could be 
discussed. Errors could also be discussed but only if you're absolutely sure
you need to break some rule to implement a feature or fix some bug.

I'd also ask you to set up your editor or IDE to work with [EditorConfig](https://editorconfig.org/).
It could save some time for both of us.

This is a minor change, but it improves readability a little.

@f1u77y What do you think?

Question: why properties canControl, canSeek &c set to true by default

Hey,

I'm writing a script using https://github.com/acrisci/playerctl (https://github.com/pavouk/lgi bindings to be precise) that unifies keybindings for the currently active player either (usually either mpv, the browser or mpd (with https://github.com/natsukagami/mpd-mpris).

I noticed that no matter if there is a tab with a supported website playing something or not, web-media-controller sets the all following properties to true anyway:

TBH, it doesn't make sense to me. The only property my script can use now in order not to try to control web-media-controller only when it actually plays something is using PlaybackStatus which is set to Stopped when nothing is playing. This is not very accurate IMO..

Расширение висит в статусе "Disconnected"

Сломалось сегодня, подозреваю что после автоапдейта на версию 0.10.0.

Linux, Firefox 69.0.2 (64-bit), Debian Sid.
wmc-mpris собран и установлен ручками, переустановить пробовал, не помогло.

Куда копать, где логи смотреть? :)

Support several Invidious instances (dynamically?)

Since the invidious connector was merged, I've learned that there are several public invidious instances. A list is available here: https://github.com/omarroth/invidious/wiki/Invidious-Instances
Users (myself included) could have wished to make the connector work for them in their preferred instance.

I was wondering, do you think web-media-controller could dynamically or via a user preference set a hostname for which the connector will work with? If not, perhaps we can at least update the list of hostnames for this connector from time to time according to the list?

npx grunt build failes: entry.isFile is not a function

Hey,

While trying to test a new connector I'd like to contribute when ready, I've encountered this error from npx grunt build:firefox when trying to test it:

Loading "Gruntfile.js" tasks...ERROR
>> TypeError: entry.isFile is not a function
Warning: Task "build:firefox" not found. Use --force to continue.

Aborted due to warnings.

Could there have been an update to fs module that introduced a change in the API? Perhaps package-lock.json should be committed to the repository as well so these changes could be tracked (I'm not sure if this suggestion is right).

Split dependencies

Some dependencies are actually not for development, e.g. bootstrap, jquery. Should we list them in the dependencies section of the package.json file?

Yandex Music double switching

Apparently, the Yandex music team changed something on their website and now double triggering occurs on the forward / back buttons. What can I do to fix this?

npx grunt build fails: "Required config property "copy.undefined" missing

I would like to contribute a connector for https://invidio.us, it should be very similar to YouTube's. I get this error when running npx grunt build:

Running "build" task

Running "copy:undefined" (copy) task
Verifying property copy.undefined exists in config...ERROR
>> Unable to process task.
Warning: Required config property "copy.undefined" missing. Use --force to continue.

Aborted due to warnings.

I couldn't find any solution when searching the web for this error. I've worked around it though for my tests with Firefox by using npx grunt build:firefox instead.

I still thought you should know so you'll be able to fix the Gruntfile.js accordingly.

Support music.youtube.com

Currently there is partial support: play/pause works, but next/previous do not. I'm pretty sure this is because the css selectors are different from YouTube proper, .next-button and .previous-button instead of .ytp-next-button and .ytp-previous-button respectively.

add bandcamp

I started implementing it based on the soundcloud connector, but I don't know how to write the observer

import BaseConnector from 'content/base-connector';
import Utils from 'content/utils';

new class extends BaseConnector {
    constructor() {
        super();
        this.name = 'BandCamp';
        this.prefix = '/com/bandcamp';

        this.artistSelector = '#band-name-location .title';
        this.titleSelector = '.title-section .title';

        this.currentTimeSelector = '.time .secondaryTexgt .time_elapsed';
        this.lengthSelector = '.time .secondaryTexgt .time_total';
        this.playButtonSelector = '.playbutton';
        this.prevButtonSelector = '.prev_cell .prevbutton';
        this.nextButtonSelector = '.next_cell .nextbutton';
        this.artSelector = '#tralbumArt .popupImage';

        //Utils.query('.playControls .playControls__inner').then((elem) => this.observe(elem));
    }

    get playbackStatus() {
        return Utils.query(this.playButtonSelector).then((elem) => (elem.classList.contains('playing') ? 'playing' : 'paused'));
    }

    getArtistTrack() {
        const artistTrack = {
            artist: document.querySelector(this.artistSelector).textContent.trim(),
            track: document.querySelector(this.titleSelector).textContent.trim(),
        };
        const match = /(.+)\s[-–—:]\s(.+)/.exec(artistTrack.track);

        if (match && ! /.*#\d+.*/.test(match[1])) {
            return { artist: match[1], track: match[2] };
        }

        return artistTrack;
    }

    get artist() {
        return this.getArtistTrack().artist;
    }

    get title() {
        return this.getArtistTrack().track;
    }

    get artUrl() {
        return super.artUrl.then((url)
    }
}();

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.