ThemeRevision icon indicating copy to clipboard operation
ThemeRevision copied to clipboard

Issue with PluginManager

Open HumanG33k opened this issue 1 year ago • 7 comments

Issue White text on white background.

https://github.com/aljawaid/PluginManager

Capture d’écran_2023-03-09_17-17-43 Capture d’écran_2023-03-09_17-32-43

cross issue https://github.com/aljawaid/PluginManager/issues/34

HumanG33k avatar Mar 09 '23 16:03 HumanG33k

Hi @HumanG33k,

This issue may not be able to solve temporarily. Currently, identifying CSS that came from PluginManager is hard. A possible way is to ask PluginManager to add an identification (attribute or class) on html body at first.

greyaz avatar Mar 10 '23 09:03 greyaz

Hi @HumanG33k,

This issue may not be able to solve temporarily. Currently, identifying CSS that came from PluginManager is hard. A possible way is to ask PluginManager to add an identification (attribute or class) on html body at first.

@greyaz Hello, how is it hard? You can target through <table id="DirectoryInfo" class="directory-info">

aljawaid avatar Mar 12 '23 21:03 aljawaid

@aljawaid

PluginManager not only overrides the CSS of the plugin management page, but also has a global impact on other styles.

For example, PluginManager directly modifies the color value of "--link-color-primary", which is a global variable. As ThemeRevision does not know who modified this value through CSS, I cannot determine whether to override it.

Some other styles can be temporarily located, but the added class or ID is relatively generic. It may not belong to the PluginManager and is prone to being overwritten by mistake. For example, "PluginSideBar" and "plugin-to-counts".

PluginManager is an excellent plugin that I have been wanting to make compatible for a long time. If some more unique IDs or classes can be provided, it would be easier to make it compatible.

greyaz avatar Mar 13 '23 09:03 greyaz

@aljawaid

PluginManager not only overrides the CSS of the plugin management page, but also has a global impact on other styles.

  • I fixed this few months ago, will look at the code again

For example, PluginManager directly modifies the color value of "--link-color-primary", which is a global variable. As ThemeRevision does not know who modified this value through CSS, I cannot determine whether to override it.

  • Firefox shows which class is being used by which css file inInspector Tools

Some other styles can be temporarily located, but the added class or ID is relatively generic. It may not belong to the PluginManager and is prone to being overwritten by mistake. For example, "PluginSideBar" and "plugin-to-counts".

  • ok so any of the CSS Id's in any of my plugins, are all mine written like PluginSideBar. Kanboard itself uses CSS ID as this-is-id which is the same as css classes. I dont.

PluginManager is an excellent plugin that I have been wanting to make compatible for a long time. If some more unique IDs or classes can be provided, it would be easier to make it compatible.

  • "for a long time" Why did you not reach out? I will look into the css file again tonight and my code, but I still think you can target through <table id="DirectoryInfo" class="directory-info">. The classes and ID's you want are already part of all my plugins.... however I will review my code tonight. The --link-color-primary was the only core variable I once used, that can easily be fixed.

aljawaid avatar Mar 13 '23 16:03 aljawaid

Hi @HumanG33k, This issue may not be able to solve temporarily. Currently, identifying CSS that came from PluginManager is hard. A possible way is to ask PluginManager to add an identification (attribute or class) on html body at first.

@greyaz Hello, how is it hard? You can target through <table id="DirectoryInfo" class="directory-info">

Reviewing my code, the css code is already present, which you can easily override: https://github.com/aljawaid/PluginManager/blob/a595d38b4918d6df59a7a3c70247b8f96e0d816c/Assets/css/plugin-manager.css#L472

aljawaid avatar Mar 13 '23 20:03 aljawaid

@aljawaid

Thank you for your updates. I will try to make it compatible in next release. 🤝

greyaz avatar Mar 14 '23 03:03 greyaz

I really glad to see how you both work together. I will take time after next release to test all that stuff.

HumanG33k avatar Mar 31 '23 14:03 HumanG33k