Skip to content

Commit

Permalink
fix: #3266 - centered world map (#3268)
Browse files Browse the repository at this point in the history
  • Loading branch information
monsieurtanuki authored Nov 5, 2022
1 parent b807c20 commit 12a47b7
Showing 1 changed file with 8 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ class KnowledgePanelWorldMapCard extends StatelessWidget {
),
zoom: 6.0,
),
layers: <LayerOptions>[
TileLayerOptions(
urlTemplate: 'https://tile.openstreetmap.org/{z}/{x}/{y}.png',
),
MarkerLayerOptions(
markers: getMarkers(mapElement.pointers),
),
],
nonRotatedChildren: <Widget>[
AttributionWidget(
attributionBuilder: (BuildContext context) {
Expand Down Expand Up @@ -65,18 +73,6 @@ class KnowledgePanelWorldMapCard extends StatelessWidget {
},
)
],
children: <Widget>[
FlutterMap(
options: MapOptions(),
layers: <LayerOptions>[
TileLayerOptions(
urlTemplate: 'https://tile.openstreetmap.org/{z}/{x}/{y}.png',
userAgentPackageName: 'world.openfoodfacts.org',
),
MarkerLayerOptions(markers: getMarkers(mapElement.pointers))
],
),
],
),
),
);
Expand Down

0 comments on commit 12a47b7

Please sign in to comment.