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

Youtube demo #1

Open
ssured opened this issue Jan 24, 2015 · 4 comments
Open

Youtube demo #1

ssured opened this issue Jan 24, 2015 · 4 comments

Comments

@ssured
Copy link
Contributor

ssured commented Jan 24, 2015

Hi Jerel, I just saw your youtube ember leaflet demo. Impressive stuff. Are you willing to share any insights in how you render the templates in the dialogs? It looks awesome! Thanks, Sjoerd

@jerel
Copy link
Owner

jerel commented Jan 24, 2015

This is where the magic happens: https://github.com/jerel/poc/blob/master/app/components/leaflet-popup.js#L4-L8 I'm creating my own popup element which I then pass to Leaflet as the popup content and also pass to the _super render method so it adds the template to it

@ssured
Copy link
Contributor Author

ssured commented Jan 24, 2015

Thanks for responding so fast! Cool, I'll poke around with those lines. In the video it looks like you also added some hooks to the leaflet controls, did you?
Did you also play around with the new HTMLBars in 1.10? The lines you reference seem to use private API, it might break? With the new HTMLBars I think it will finally be possible to write some nice leaflet-ember components. This pull emberjs/ember.js#10244 seems quite promising too

@ssured
Copy link
Contributor Author

ssured commented Jan 24, 2015

For people coming here, it's all about this demo: https://t.co/ACEUZHK5Hw

@jerel
Copy link
Owner

jerel commented Jan 24, 2015

In the video it looks like you also added some hooks to the leaflet controls, did you?

No, I instead I implement my own controls and absolutely position them over the map. The tile switcher is as simple as {{#radio-button value="street" groupValue=selectedTiles}}Streets{{/radio-button}} which the tile component observes.

Did you also play around with the new HTMLBars in 1.10?

Yes, I run master

The lines you reference seem to use private API, it might break?

Yes, no guarantees. However it's minimal, buffer._element and renderer IIRC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants