Thanks to visit codestin.com
Credit goes to github.com

Skip to content

0.1.53a

Latest

Choose a tag to compare

@RobertCraigie RobertCraigie released this 26 Oct 16:22
c29060a

Addons API

You can now install addons directly from the Glide config:

glide.addons.install(
  "https://addons.mozilla.org/firefox/downloads/file/4598854/ublock_origin-1.67.0.xpi",
);

This will install the uBlock Origin addon, if it isn't already installed. If you want to install the addon even if it's installed already, use glide.addons.install('...', { force: true }).

glide.addons.install() expects a URL for an XPI file, you can obtain the XPI URL from an addons.mozilla.org page by right clicking on "Add to Firefox", and selecting "Copy link".

Styles API

You can now easily inject custom CSS into the browser UI directly from the Glide config:

glide.styles.add(css`
  #TabsToolbar {
    visibility: collapse !important;
  }
`);

This particular example hides the horizontal native tabs toolbar, but you can customise essentialy anything in the browser UI with this method.

Note that prior to this release you could inject custom CSS yourself but it was slower and would be persisted between config reloads.

Old API
glide.autocmds.create("WindowLoaded", () => {
  document.head!.appendChild(DOM.create_element("style", {
    textContent: css`
      #TabsToolbar {
        visibility: collapse !important;
      }
    `,
  }));
});

Changes