Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Popup Templates Support #64

Open
wants to merge 25 commits into
base: master
Choose a base branch
from
Open

Popup Templates Support #64

wants to merge 25 commits into from

Conversation

versx
Copy link
Collaborator

@versx versx commented Aug 22, 2020

Introduces the functionality to customize your own marker popup contents for the following:

  • Pokemon
  • Gyms (with Raids)
  • Pokestops (with Lures/Quests/Invasions)
  • Nests
  • Spawnpoints (removed for performance issues)
  • Weather
  • Devices
  • Scan Areas
  • S2 Scan Cells (removed for performance issues)
  • S2 Submission Cells (removed for performance issues)

TODO:

  • Update docs to show all available options

@versx
Copy link
Collaborator Author

versx commented Aug 22, 2020

Please test 👀

@versx versx added enhancement New feature or request needs-testing labels Aug 22, 2020
Copy link
Contributor

@clburlison clburlison left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In it's current form this ejs template implementation is much much slower than master. I tested all of the templates with simple changes and they worked but filters like spawnpoints, submission cells, and s2 cells ended up taking the browser much longer to render when on this PR.

Additionally it locks the UI while it's attempting to render so it looks like it simply crashed. Waiting long enough does have the rendering complete.

Third point using /templates is not git friendly. I recommend putting the default templates some where inside of /src then have /templates/foobar.example.ejs files. Modify gitignore with

/templates/*
!/templates/*.example.ejs

When changes happen git won't prompt admin's to stash, commit, etc with local changes.

@Mygod
Copy link
Contributor

Mygod commented Sep 17, 2020

Should probably look at #200 while you're at it.

@versx
Copy link
Collaborator Author

versx commented Sep 17, 2020

Should probably look at #200 while you're at it.

Should be fixed now, last thing is the raid popups still shift to the left. Normal gym icons are fine though.

Copy link
Contributor

@TurtIeSocks TurtIeSocks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still finishing up some work before more testing but some initial feedback:

  • Scan Area is a bit sluggish, manageable, but maybe not necessary unless someone more creative than I can envision how these can be further customized?

  • Pokemon also seem a bit sluggish, I don't remember them being this slow when I tested this previously.

  • Pokemon image is stretched (Desktop, chrome)

  • Quests & Invasions seem fine

  • Pokemon in the raid popup also stretched, I think maybe we revert the recent commits? I'm not that worried about the ultra ball catch rate being on a separate line.

  • Nests are also sluggish, I'm guessing this is related to the polygon drawing, similar to scan areas.

  • Weather is sluggish

  • I would suggest having a templates.example directory then have people copy the folder and rename to templates, instead of having to copy and rename each template file.

Copy link
Contributor

@Mygod Mygod left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pokemon popup is not scaling the Pokemon correctly. Fix it.

@versx
Copy link
Collaborator Author

versx commented Sep 18, 2020

Pokemon popup is not scaling the Pokemon correctly. Fix it.

🤔 Seems fine to me?
image

@Mygod
Copy link
Contributor

Mygod commented Sep 18, 2020

@versx Use an icon pack that is not square.

@versx
Copy link
Collaborator Author

versx commented Sep 18, 2020

@versx Use an icon pack that is not square.

Shuffle
image

Pogo
image

Home
image

@Mygod
Copy link
Contributor

Mygod commented Sep 18, 2020

God damn it I bet it works fine on Koffing too.

@Mygod
Copy link
Contributor

Mygod commented Sep 18, 2020

spot what is wrong with this pic

image

@versx
Copy link
Collaborator Author

versx commented Sep 18, 2020

spot what is wrong with this pic

image

I know the type icons are shifted to the left

@Mygod
Copy link
Contributor

Mygod commented Sep 18, 2020

image
ok sPoT wHaT iS wRoNg

@TurtIeSocks
Copy link
Contributor

image
Perhaps a more dramatic example >.>

@versx
Copy link
Collaborator Author

versx commented Sep 18, 2020

Ok that's more obvious! 😂

@Mygod
Copy link
Contributor

Mygod commented Sep 18, 2020

Fix it or we are not merging your patch into our map.

@versx
Copy link
Collaborator Author

versx commented Sep 18, 2020

Fix it or we are not merging your patch into our map.

What if I can't? Will you help with your map? 😂

@Mygod
Copy link
Contributor

Mygod commented Sep 18, 2020

image
Also are you fucking serious with these requests? This should explain all the slowness.

Fix it or we are not merging your patch into our map.

What if I can't? Will you help with your map? 😂

As a matter of fact, I will probably just delete your entire PR. If map admin wants to change a template, they can just edit js code.

@versx
Copy link
Collaborator Author

versx commented Sep 18, 2020

image
Also are you fucking serious with these requests? This should explain all the slowness.

Fix it or we are not merging your patch into our map.

What if I can't? Will you help with your map? 😂

As a matter of fact, I will probably just delete your entire PR. If map admin wants to change a template, they can just edit js code.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request needs-testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants