sindresorhus/electron-util

Please, make "showAboutWindow" more useful

Closed this issue · 2 comments

Hi, I am using you utils (on Windows) and here are my comments:

  1. Icon is poor quality (I even tried very large PNG file);
  2. Text is not centered, in fact, it does look very different compared to the screenshot on the page of this project;
  3. I am puzzled about how to change title - it seems to use "name" from "package.json", but that is lower cased with the dashes, e.g., it shows "my-app", but, obviously, I want to have "My App".
  4. Why there is limitation about "website"? To me, it seems obvious, that everyone would want to display link to project homepage.

Thanks!

One more thing- the window should me modal, I can open it multiple times.

These things are problems with Electron, not this package. This package simply wraps its API:

electron-util/index.js

Lines 197 to 229 in f5440bb

exports.showAboutWindow = (options = {}) => {
// TODO: When https://github.com/electron/electron/issues/18918 is fixed,
// these defaults should not need to be set for Linux.
// TODO: The defaults are standardized here, instead of being set in
// Electron when https://github.com/electron/electron/issues/23851 is fixed.
const appName = api.app.getName();
const appVersion = api.app.getVersion();
const aboutPanelOptions = {
applicationName: appName,
applicationVersion: appVersion
};
if (options.icon) {
aboutPanelOptions.iconPath = options.icon;
}
if (options.copyright) {
aboutPanelOptions.copyright = options.copyright;
}
if (options.text) {
aboutPanelOptions.copyright = (options.copyright || '') + '\n\n' + options.text;
}
if (options.website) {
aboutPanelOptions.website = options.website;
}
api.app.setAboutPanelOptions(aboutPanelOptions);
api.app.showAboutPanel();
};

You will need to open an isuse on Electron.