Porównaj commity

...

13 Commity

Autor SHA1 Wiadomość Data
tomasz t fb1fb23946 updated readme 2022-03-28 23:20:24 +02:00
tomasz t b5d6fe18d4 changed icon overlap to mapbox compatible property to be able to use maputnik editor 2022-03-28 22:05:49 +02:00
tomasz t 36ff7cfda6 Merge branch 'main' into development
# Conflicts:
#	.github/workflows/deploy_to_prod.yaml
2022-03-28 19:01:26 +02:00
tomasz t ca98c2977c fixed path in deploy script 2022-03-28 18:54:09 +02:00
ANCMN 8196b2421a
Development (#67)
* Added layers.js (settings in separate file) and sprite test (#66)

* sprites fix, hardcoded url

* aed icon

* Fixed icon size

* icon-size -> 0.5

* icon-size -> 0.33

* size -> 0.36

* new sprites

* aed icon fix

* Sprites fix

* removed uneccesary code / formatting code

* removed unecessary attribution + code formatting

* Fixed sprite on mobile

* width + height fixed

* fixed hash #map

* fixed hash

* added formatting + missing "icon-overlap"

* removed download of custom_layer data

* changed map style from js to json

* changed data urls to be absolute

* clean up

* changed size of cluster circles

* added info about generating sprites

* added sprites for high dpi screens

Co-authored-by: tomasz t <tomasztaras@outlook.com>
2022-03-28 18:48:54 +02:00
tomasz t 40a4f266bd added sprites for high dpi screens 2022-03-28 18:13:09 +02:00
ttomasz b02e6fd4dd
Merge pull request #65 from openstreetmap-polska/development
Development
2022-02-24 19:25:22 +01:00
ttomasz 04951a59cd
Merge pull request #63 from openstreetmap-polska/development
Development
2022-02-21 17:56:55 +01:00
BNDR 2b6e442830
Fixed esacaping
Fixed bug with wrong escaped values.
2022-02-09 11:44:32 +01:00
BNDR 2e5cc08851
Merge pull request #58 from openstreetmap-polska/development
update
2022-02-03 08:49:01 +01:00
tomasz t eea4a5e468 Merge branch 'development' 2022-01-30 12:32:51 +01:00
ttomasz e51702e29b
Merge pull request #57 from openstreetmap-polska/development
small fixes
2022-01-30 11:26:05 +01:00
BNDR b19e5966b1
Merge pull request #56 from openstreetmap-polska/development
UI improvements
2022-01-29 23:19:11 +01:00
5 zmienionych plików z 47 dodań i 2 usunięć

Wyświetl plik

@ -42,7 +42,7 @@ jobs:
--exclude 'requirements.txt' --exclude 'LICENSE' --exclude 'README.md' --exclude '*.ods' --exclude '*.csv' \
--quiet /home/${{ secrets.SSH_USER }}/aed-mapa/ /home/${{ secrets.SSH_USER }}/temp_deploy_prod/
sed -i "s/<< oauth_consumer_key >>/$OAUTH_CONSUMER_KEY/;s/<< oauth_secret >>/$OAUTH_SECRET/;s|<< url >>|$OSM_API_URL|" /home/${{ secrets.SSH_USER }}/temp_deploy_prod/src/osm-integration.js
sed -i "s|https://aed.openstreetmap.org.pl/dev/|https://aed.openstreetmap.org.pl/|g" /home/${{ secrets.SSH_USER }}/temp_deploy_dev/src/map_style/style.json
sed -i "s|https://aed.openstreetmap.org.pl/dev/|https://aed.openstreetmap.org.pl/|g" /home/${{ secrets.SSH_USER }}/temp_deploy_prod/src/map_style/style.json
rsync --update --recursive --delete \
--exclude '*.py' --exclude '*.geojson' --exclude '.git*' --exclude 'aed_poland_metadata.json' \
--exclude 'requirements.txt' --exclude 'LICENSE' --exclude 'README.md' --exclude '*.ods' --exclude '*.csv' \

Wyświetl plik

@ -67,10 +67,25 @@ cp /home/aeduser/data_dir/aed_poland.csv /var/www/html/aed_poland.csv
#### Editing style
You can use [Maputnik](https://maputnik.github.io/) editor to prepare new style for the map.
Steps:
1. Open https://aed.openstreetmap.org.pl/maputnik/?layer=1311944204%7E0#6/52/20 (it's a copy of maputnik editor with newer version than what is available on the official site).
2. If the AED map style has not been loaded click _open_ and select it.
3. Once finished click _export_ and create PR or an issue with your style attached.
#### Creating sprites with icons
If you want to add new icons to the sprite sheet please place the SVG files in ./src/marker_icons/ folder.
SVG should be scaled to 50x50px size.
```bash
# install requirements (assumes NVM has been installed)
nvm use 8
npm install -g @mapbox/spritezero-cli
# create sprite for regular screens
spritezero --ratio 1 ./src/map_style/sprite ./src/marker_icons/
# create sprite for high-dpi screens
spritezero --ratio 2 ./src/map_style/sprite@2x ./src/marker_icons/
```

Wyświetl plik

@ -0,0 +1,30 @@
{
"marker_customers": {
"height": 100,
"pixelRatio": 2,
"width": 100,
"x": 0,
"y": 0
},
"marker_default": {
"height": 100,
"pixelRatio": 2,
"width": 100,
"x": 100,
"y": 0
},
"marker_no": {
"height": 100,
"pixelRatio": 2,
"width": 99,
"x": 0,
"y": 100
},
"marker_private": {
"height": 100,
"pixelRatio": 2,
"width": 100,
"x": 99,
"y": 100
}
}

Plik binarny nie jest wyświetlany.

Po

Szerokość:  |  Wysokość:  |  Rozmiar: 8.1 KiB

Wyświetl plik

@ -44,7 +44,7 @@
"layout": {
"icon-image": "marker_default",
"icon-size": 0.5,
"icon-overlap": "always"
"icon-allow-overlap": true
}
},
{