stash icon indicating copy to clipboard operation
stash copied to clipboard

[Feature] Add window.stash object to provide simple functions for bookmarklets and customizations

Open StashPowerUser opened this issue 1 year ago • 3 comments

It would be nice if bookmarklets could do some simple actions like window.stash.setSceneRating(90) and other common tasks to allow for easy extension of the stash frontend.

On a similar note, is there any documentation for the existing UI plugin system anywhere for someone looking to get started with customizations that way?

StashPowerUser avatar Mar 24 '24 15:03 StashPowerUser

On a similar note, is there any documentation for the existing UI plugin system anywhere for someone looking to get started with customizations that way?

  • https://docs.stashapp.cc/in-app-manual/plugins/uipluginapi/
  • https://github.com/stashapp/stash/tree/develop/pkg/plugin/examples

DogmaDragon avatar Mar 24 '24 22:03 DogmaDragon

Cool, thanks for pointing this out.

From looking at this though it seems highly targeted at use in react (exposed hooks that can't be used outside components) and isn't useful for simpler interactions like bookmarklets.

StashPowerUser avatar Mar 26 '24 06:03 StashPowerUser

Since "comon" simple functions do vary wildly, a lot of userscripts and plugins instead rely on customizable / reusable GQL queries

Libaries like https://github.com/stashapp/CommunityScripts/tree/main/plugins/CommunityScriptsUILibrary https://github.com/7dJx1qP/stash-plugins/tree/main/plugins/stashUserscriptLibrary7dJx1qP

Have some reusable queries but also allow access to advanced and customizable GQL queries

feederbox826 avatar Jun 03 '24 20:06 feederbox826