GithubHelp home page GithubHelp logo

death-save / pin-cushion Goto Github PK

View Code? Open in Web Editor NEW
7.0 7.0 18.0 321 KB

Adds additional functionality around Map Pins

License: GNU General Public License v3.0

JavaScript 90.44% CSS 3.48% HTML 0.78% Handlebars 5.30%

pin-cushion's People

Contributors

brothersharper avatar dependabot[bot] avatar eclarke12 avatar ethaks avatar lozalojo avatar lozanoje avatar rinnocenti avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

pin-cushion's Issues

SVG not scaling in new FVTT

Having an issue with Pin Cushion not sizing custom SVG correctly after the update. Standard ones are fine, the custom ones are not scaling to the size of the box and are too large to display

See image:
unknown

Enhancement - Option to suppress H3 title in HTML

I'm not sure if this is warranted or not. But would it be possible to add an option to suppress the h3 header in the Pin Cushion on hover text?
I already included h2 headers in most of my journal entries. This creates a double header for pin cushion hover text. First an h3, then my h2. I can easily remove the html whenever I update pin cushion and this is really just a qol thing for me; but thought others may want to suppress the header as well.

Preview length improvements

It would be handy to be able to configure the journal previews more finely. In particular, it'd be nice to be able to adjust the max length of HTML previews (though I understand why it isn't that way right now). I think it would be great if it could show a preview of the text up to the first heading.

For instance if I have a description of a settlement, I could start it off with a short summary:

"Heston is a very nice town nestled in the Piramor valley, surrounded by groves of peach trees"

Then have a heading (or maybe horizontal rule could work) followed by a more detailed description.

Ideally I could set it to show only the summary paragraph prior to the first heading.

Configurable preview on a per-pin basis

It would be nice to configure for each individual pin whether the preview shows or not. In the Map Note Configuration screen there could be a checkbox that determines whether a preview is show for that individual map note.

Feature Request: "Pin Mold" functionality

This is a pretty major request, but I'd like the option to automatically set a default icon and other settings (size, etc) for a map pin instead of the default Book icon. I'm envisioning this behaving like Token mold does.

BUG in loading

foundry.js:2213 Error: This is not a registered game setting
at ClientSettings.get (foundry.js:3020)
at pin-cushion.js:228
at Function._call (foundry.js:2210)
at Function.call [as __furnace_original_call] (foundry.js:2195)
at Function.callOriginalFunction (Patches.js:56)
at Function. (Debug.js:42)
at HeadsUpDisplay._render (foundry.js:3865)
at async HeadsUpDisplay._render (foundry.js:20526)

Failing to get game settings

Getting:

Error: This is not a registered game setting
    at ClientSettings.get (foundry.js:3436)
    at pin-cushion.js:245
    at Function._call (foundry.js:2496)
    at Function.callAll (foundry.js:2456)
    at Note._onHoverOut (foundry.js:11839)
    at Note._onHoverOut (foundry.js:42638)
    at MouseInteractionManager.callback (foundry.js:36392)
    at MouseInteractionManager._handleMouseOut (foundry.js:36531)
    at ControlIcon.a.emit (index.js:181)
    at r.dispatchEvent (InteractionManager.ts:1106)

Going into that file, it looks like it's failing to fetch those variables (showJournalPreview and previewDelay). Running that command separately confirms that those variables aren't getting set properly. I saw that #15 and #11 had the same issue, so this seems intermittent.

Player Notes - default folder for player made notes

In order to avoid spam with too excited groups that start making notes that the DM must spend time to delete one by one, please add default folder for Player-made notes so the DM can easily delete the whole folder, or at least keep his Journal structure clean without players messing it.

Allow Users (other than GM) to create Pins on scenes. (Willing to commission)

By default in Foundry "Note" extends "PlaceableObject" and the "_canCreate" method of "PlaceableObject" is a boolean set as "user.isGM", so Note seems to require GM privs to create.

To enable players to create notes as well (specifically for scenes world maps, such as in a westmarches-style game) an inbuilt option would be great.

Some ideas from users in discord were:

  1. Perhaps the module could use sockets to get around this
  2. Why not just "PlayerNote" extends "Note", then override "_canCreate"?

Thanks for looking into this, you can contact me via foundry discord @tmtProdigy
Cheers!

"libWrapper missing" warning when it is installed

Running on the Forge.

Versions:
Foundry - 0.7.9
Game system - PF2 v 1.11.18.4689
Pin Cushion - 1.2.0
libWrapper - 1.3.5.0
Browser is firefox

Upon joining the game (I'm the GM) I recieve the "Pin Cushion relies on libWrapper but it's missing yadda yadda fallback implementation". I should not be seeing this since libWrapper has been installed. I tried reinstalling pin cushion but the message still appears.

I cannot tell if the message is appearing incorrectly and PC is actually using libWrapper, or if PC just can't find libWrapper at all.

ReferenceError: ENTITY_PERMISSIONS is not defined

Foundry VTT 0.8.6

VM7536:8 ReferenceError: ENTITY_PERMISSIONS is not defined
    at Function._registerSettings (pin-cushion.js:573)
    at pin-cushion.js:680
    at Function._call (eval at <anonymous> (libWrapper-errors.js:249), <anonymous>:4:14)
    at Function.callAll (foundry.js:153)
    at Game.initialize (foundry.js:4187)
    at z.🎁call_wrapped [as call_wrapped] (libWrapper-wrapper.js:448)
    at Game.🎁libWrapperInit (libWrapper-api.js:521)
    at Game.🎁Game.prototype.initialize#0 (libWrapper-wrapper.js:142)
    at window.addEventListener.once (foundry.js:52466)

Feature Request: Pin "auto-numbering" [Pie-in-the-sky]

One of the great uses for Pins is labelling the rooms in a dungeon. Particularly with the new VTTA Beyond Integration Module import, I'll have many numbered journal entries that need to go onto the scene.

My dream (!) is to be able to link up icons in a sequential order. For instance, I have a number of icons of basic numbers that is freely available. When I drag the first pin into the scene, I'd like it to automatically set the icon to be the number 1, then the number 2, etc. This is an example of me setting this up manually:

image

I was also thinking that being able to set the first X characters of the journal name as an "icon" through a drawing sort of thing might be neat to accomplish auto-numbering another way, but that may not even be technically possible.

Players can't see previews (but GM can)

I am using the module in two games. In both, as the GM I am able to see the journal note preview popups, but my players cannot see them at all regardless of the permission level set on the journal entry. There doesn't appear to be a control for this in the module settings but other issues here are written as if to imply this is a feature the module has.

[Suggestion] Different icon for players when shared with them

I am making my notes following a journal guide by Pyram King on Youtube which involves putting the room description, and any associated art, into a journal. Below this, in a 'secret' section, are my GM notes. The journals are shared to the player as 'observers' after they have entered the room. This allows them to see the room descriptor for future reference but also prevents them seeing the GM notes. A tidy solution.

I'm also using the Automatic Journal Icon Numbers module, which allows me to drop the journal on the map and also number the rooms for my reference. The issue I face is that the icon with a number is also shared to the players, I would like for the icon to be different for the players as to not show the room number.

tl;dr - have the ability to have gm icons separate to player icons for journals on scenes.

(Bug) Can add note for which we lack permission by double-clicking

When you double click on the canvas, you can create a new note. After it's created, a new "Note" window appears, and there is a selector menu which lets you select any journal note to pin. The problem is that all the notes appear there, including the ones the user does not have access to. If they select one for which thay have no permission, they can't see it on the canvas, but it's still added (and viewable by users that have permission).

Here is an example from one of my players.

image

Scene does not show Pins

When transitioning to a scene, none of the pins show.
Trouble-shooting:

  1. Loaded another scene and went back to existing scene.
  2. Disable/re-enable Pin Cushion
  3. Uninstalled/Installed Pin Cushion
  4. Created a new map with new pin cushions which disappeared when reloading foundry.
  5. Browsed open issues and didn't see one listed for this particular issue, however, I did see one that was closed which looked like it was resolved.

Work-around:

  1. creating a new pin brings all pins back across all scenes.

[FEATURE] Backgroundless pins

Hi,

I would like to suggest the inclusion of an option to make the pins brakgroundless. It makes it look better when added on the map and so on.

Note: there is already a module that does this and only this, but I think this would make sense to be included in the pin module itself (since the other module is an "improvement" to this module.
https://foundryvtt.com/packages/backgroundless-pins

V9 Update or Abandoned?

This is a really great module and it's used a lot in my campaign. I'm sure a lot of us are hoping to see a V9 update or to know if this module been abandoned? If we are getting an update when can we expect it?

[FEATURE] Hide Label or Title Text

I'm trying to give my players very quick notes while explore. Having the label and title is redundant. Ideally, I could disable either. Love this mod. Thanks!

Pin Labels not showing on hover

When only Pin Cushion module is active, my map pins don't show their referenced journal names (or text label) when I hover over them. It also doesn't show the names when you hold alt. I discovered that if you have "Enable feature Backgroundless Pins" checked off in the module settings and you open up the Map Note configuration menu for one of the map pins and then click "Update Map Note", even if you didn't change anything in the settings then the name will start appearing on hover. But if the feature is unchecked, nothing you do will make the name appear on hover.

Super weird issue but I'm thinking maybe it has to do with the backgroundless pin feature since it was recently added?

Prevent preview from showing when not hovering the canvas

Hello,

When a journal entry is open, if the mouse hover over the journal and at the same time a note journal on the canvas, the preview is opened.
And when the journal entry is closed, the preview is stuck until the mouse hover over another note on the canvas.

Journal Hover not working

Foundry 0.6.5
DnD5e 0.94

Only enabled module is latest Pincushion.

I link Journal Entry to pin.

Journal has an H1 header, and 2 lines of text (wrapped in paragraph tags).

Hover over pin.

Nothing happens.

There are no errors in console.

Edit: Closing issue. Works on first hover just fine on most occasions. If it doesn't it is likely due to mouse position on login.

Player lacks permission to create a journal

When a player tries to create a Pin by double-clicking on the map, the error mentioned in this issue's title pops-up. There is a folder created automatically in the Journal tab, with the player name. I tried granting owner permission to the folder, but I'm not sure it worked. I did set the Module settings to give Owner permissions to the new journal entry as well. Is there something else I need to do to make it work?

Settings
Pin CuShion

Error:
Pin Cushion

Pin preview gets stuck

Sometimes Pin previews get stuck on the screen and won't go away until I hover over a different pin

Add an option to disable the native Note Text showing on the canvas

I like what Pin Cushion does so far, but was looking for a little more customization with pins and couldn't find a module that goes that one step further. Specifically, I'd like to do the following 3 things:

  1. Disable the text field so that I can have just an icon with no text.
  2. Set the text to Always Show instead of just on hover. This would work great when using pins for map points that you don't want to have to have the players hover over them all to find the one they are looking for.
  3. Have a pin with text name not tied to a Journal entry.

Number 2 is the one I am most missing right now.

Enhancement - Left Justify Text

Would it be possible to add an option, or by default left justify the text in the pin cushion css? Currently the default text in Foundry has no Justification set, but shows as left justified. This causes every text entry in pin cushion to appear center justified.

.pin-cushion-hud #content {
    text-overflow: ellipsis;
    text-align: left;
}

Customizable Preview Width, support for scrolling inside the preview

Two feature requests:

  • Customize width (in pixels) of the preview in Settings, to avoid hard to read or unreadable long text (see screenshot)

image

image

  • Optional scrollable preview that renders a scroll bar and allows to scroll up and down with your mouse to read the full content of the journal.

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.