Skip to content

Commit

Permalink
support ember-render-helpers v1
Browse files Browse the repository at this point in the history
  • Loading branch information
jelhan committed Dec 3, 2024
1 parent 1d20642 commit a6aa889
Show file tree
Hide file tree
Showing 6 changed files with 271 additions and 361 deletions.
6 changes: 3 additions & 3 deletions addon/components/base-layer.hbs
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{{#each this.leafletDescriptorsProps as |prop|}}
{{#if (ember-leaflet-eq prop "location")}}
{{did-update (fn this.updateOption "location") this.location}}
{{did-update-helper (fn this.updateOption "location") this.location}}
{{else}}
{{did-update (fn this.updateOption prop) (get this.args prop)}}
{{did-update-helper (fn this.updateOption prop) (get this.args prop)}}
{{/if}}
{{/each}}

{{#each this.leafletStyleProperties as |prop|}}
{{did-update (fn this.updateStyleProperty prop) (get this.args prop)}}
{{did-update-helper (fn this.updateStyleProperty prop) (get this.args prop)}}
{{/each}}

<@node @didInsertParent={{this.didInsertParent}} @willDestroyParent={{this.willDestroyParent}} as |Node|>
Expand Down
4 changes: 2 additions & 2 deletions addon/components/div-overlay-layer.hbs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{{#if this.popupOpenDidChange}}
{{did-update this.popupOpenDidChange @popupOpen}}
{{did-update-helper this.popupOpenDidChange @popupOpen}}
{{/if}}

{{#each this.leafletDescriptorsProps as |prop|}}
{{did-update (fn this.updateOption prop) (get this.args prop)}}
{{did-update-helper (fn this.updateOption prop) (get this.args prop)}}
{{/each}}

<@node @didInsertParent={{this.didInsertParent}} @willDestroyParent={{this.willDestroyParent}}>
Expand Down
4 changes: 2 additions & 2 deletions addon/components/geojson-layer.hbs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{{#each this.leafletDescriptorsProps as |prop|}}
{{did-update (fn this.updateOption prop) (get this.args prop)}}
{{did-update-helper (fn this.updateOption prop) (get this.args prop)}}
{{/each}}

{{did-update this.didChangeGeojson @geoJSON}}
{{did-update-helper this.didChangeGeojson @geoJSON}}

<@node @didInsertParent={{this.didInsertParent}} @willDestroyParent={{this.willDestroyParent}} as |Node|>
{{#let (ember-leaflet-hash) as |components|}}
Expand Down
4 changes: 2 additions & 2 deletions addon/components/leaflet-map.hbs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{{#each this.leafletDescriptorsProps as |prop|}}
{{#if (ember-leaflet-eq prop "center")}}
{{did-update (fn this.updateOption "center") this.center}}
{{did-update-helper (fn this.updateOption "center") this.center}}
{{else}}
{{did-update (fn this.updateOption prop) (get this.args prop)}}
{{did-update-helper (fn this.updateOption prop) (get this.args prop)}}
{{/if}}
{{/each}}

Expand Down
Loading

0 comments on commit a6aa889

Please sign in to comment.