Skip to content

Commit

Permalink
fix: cast this.get_options to support @types/leaflet@1.9.9
Browse files Browse the repository at this point in the history
  • Loading branch information
iisakkirotko committed Apr 11, 2024
1 parent 32e94db commit a3550f2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion python/jupyter_leaflet/src/layers/Circle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ export class LeafletCircleView extends LeafletCircleMarkerView {
obj: Circle;

create_obj() {
this.obj = L.circle(this.model.get('location'), this.get_options());
this.obj = L.circle(
this.model.get('location'),
this.get_options() as L.CircleOptions
);
}

model_events() {
Expand Down
5 changes: 4 additions & 1 deletion python/jupyter_leaflet/src/layers/CircleMarker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ export class LeafletCircleMarkerView extends LeafletPathView {
obj: CircleMarker;

create_obj() {
this.obj = L.circleMarker(this.model.get('location'), this.get_options());
this.obj = L.circleMarker(
this.model.get('location'),
this.get_options() as L.CircleMarkerOptions
);
}

model_events() {
Expand Down

0 comments on commit a3550f2

Please sign in to comment.