Skip to content

Commit

Permalink
Merge tag 'v0.45.0' into fix-ios-file-status-zero
Browse files Browse the repository at this point in the history
  • Loading branch information
oscarfonts committed Jun 6, 2018
2 parents 59a8b7f + b28bc17 commit 9ea7464
Show file tree
Hide file tree
Showing 19 changed files with 89 additions and 53 deletions.
10 changes: 8 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
## 0.45.0-beta.1

## 0.45.0

### ⚠️ Breaking changes

Expand All @@ -10,6 +11,8 @@
* :rainbow: Add `line-gradient` property [#6303](https://github.com/mapbox/mapbox-gl-js/pull/6303)
* Add `abs`, `round`, `floor`, and `ceil` expression operators [#6496](https://github.com/mapbox/mapbox-gl-js/pull/6496)
* Add `collator` expression for controlling case and diacritic sensitivity in string comparisons [#6270](https://github.com/mapbox/mapbox-gl-js/pull/6270)
- Rename `caseSensitive` and `diacriticSensitive` expressions to `case-sensitive` and `diacritic-sensitive` for consistency [#6598](https://github.com/mapbox/mapbox-gl-js/pull/6598)
- Prevent `collator` expressions for evaluating as constant to account for potential environment-specific differences in expression evaluation [#6596](https://github.com/mapbox/mapbox-gl-js/pull/6596)
* Add CSS linting to test suite (h/t @jasonbarry) [#6071](https://github.com/mapbox/mapbox-gl-js/pull/6071)
* Add support for configurable maxzoom in `raster-dem` tilesets [#6103](https://github.com/mapbox/mapbox-gl-js/pull/6103)
* Add `Map#isZooming` and `Map#isRotating` methods [#6128](https://github.com/mapbox/mapbox-gl-js/pull/6128), [#6183](https://github.com/mapbox/mapbox-gl-js/pull/6183)
Expand Down Expand Up @@ -59,7 +62,10 @@
* Fix bug causing flickering when panning across the anti-meridian [#6438](https://github.com/mapbox/mapbox-gl-js/pull/6438)
* Fix error when using tiles of non-power-of-two size [#6444](https://github.com/mapbox/mapbox-gl-js/pull/6444)
* Fix bug causing `Map#moveLayer(layerId, beforeId)` to remove the layer when `layerId === beforeId` [#6542](https://github.com/mapbox/mapbox-gl-js/pull/6542)

- Fix Rollup build for style-spec module [6575](https://github.com/mapbox/mapbox-gl-js/pull/6575)
- Fix bug causing `Map#querySourceFeatures` to throw an `Uncaught TypeError`(https://github.com/mapbox/mapbox-gl-js/pull/6555)
- Fix issue where label collision detection was inaccurate for some symbol layers that shared layout properties with another layer [#6558](https://github.com/mapbox/mapbox-gl-js/pull/6558)
- Restore `target` property for `mouse{enter,over,leave,out}` events [#6623](https://github.com/mapbox/mapbox-gl-js/pull/6623)

## 0.44.2

Expand Down
1 change: 0 additions & 1 deletion circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@ jobs:
at: .
- run: yarn run build-min
- run: yarn run build-dev
- run: yarn run build-css
- run: yarn run build-style-spec
- run: yarn run test-build
- persist_to_workspace:
Expand Down
4 changes: 2 additions & 2 deletions docs/components/example.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,8 @@ ${html}
<div key={i} className='space-bottom1'>
{!filter && <h3 className='heading'>{title}</h3>}
{examples
.filter(({tags, title}) =>
tags.indexOf(tag) !== -1 && title.toLowerCase().indexOf(filter) !== -1)
.filter(({tags, title, description}) =>
tags.indexOf(tag) !== -1 && (title.toLowerCase().indexOf(filter) !== -1 || description.toLowerCase().indexOf(filter) !== -1))
.map(({pathname, title}, i) =>
<a key={i} href={prefixUrl(pathname)}
className={`block small truncate ${title === frontMatter.title && 'active'}`}>{title}</a>
Expand Down
26 changes: 20 additions & 6 deletions docs/pages/example/animate-point-along-route.html
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@
"type": "FeatureCollection",
"features": [{
"type": "Feature",
"properties": {},
"geometry": {
"type": "Point",
"coordinates": origin
Expand All @@ -75,9 +76,14 @@

var arc = [];

// Number of steps to use in the arc and animation, more steps means
// a smoother arc and animation, but too many steps will result in a
// low frame rate
var steps = 500;

// Draw an arc between the `origin` & `destination` of the two points
for (var i = 0; i < lineDistance; i++) {
var segment = turf.along(route.features[0], i / 1000 * lineDistance, 'kilometers');
for (var i = 0; i < lineDistance; i += lineDistance / steps) {
var segment = turf.along(route.features[0], i, 'kilometers');
arc.push(segment.geometry.coordinates);
}

Expand Down Expand Up @@ -115,7 +121,8 @@
"type": "symbol",
"layout": {
"icon-image": "airport-15",
"icon-rotate": 90,
"icon-rotate": ["get", "bearing"],
"icon-rotation-alignment": "map",
"icon-allow-overlap": true
}
});
Expand All @@ -125,12 +132,19 @@
// the index to access the arc.
point.features[0].geometry.coordinates = route.features[0].geometry.coordinates[counter];

// Calculate the bearing to ensure the icon is rotated to match the route arc
// The bearing is calculate between the current point and the next point, except
// at the end of the arc use the previous point and the current point
point.features[0].properties.bearing = turf.bearing(
turf.point(route.features[0].geometry.coordinates[counter >= steps ? counter - 1 : counter]),
turf.point(route.features[0].geometry.coordinates[counter >= steps ? counter : counter + 1])
);

// Update the source with this new data.
map.getSource('point').setData(point);

// Request the next frame of animation so long as destination has not
// been reached.
if (point.features[0].geometry.coordinates[0] !== destination[0]) {
// Request the next frame of animation so long the end has not been reached.
if (counter < steps) {
requestAnimationFrame(animate);
}

Expand Down
4 changes: 2 additions & 2 deletions docs/pages/example/mapbox-gl-directions.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script src='https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-directions/v3.1.1/mapbox-gl-directions.js'></script>
<link rel='stylesheet' href='https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-directions/v3.1.1/mapbox-gl-directions.css' type='text/css' />
<script src='https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-directions/v3.1.3/mapbox-gl-directions.js'></script>
<link rel='stylesheet' href='https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-directions/v3.1.3/mapbox-gl-directions.css' type='text/css' />
<div id='map'></div>

<script>
Expand Down
2 changes: 1 addition & 1 deletion docs/pages/example/point-from-geocoder-result.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: >-
Listen to the `geocoder.input` event from the [Geocoder plugin](https://github.com/mapbox/mapbox-gl-geocoder) and
place a point on the coordinate results.
tags:
- controls-and-overlays
- geocoder
pathname: /mapbox-gl-js/example/point-from-geocoder-result/
---*/
import Example from '../../components/example';
Expand Down
18 changes: 9 additions & 9 deletions docs/pages/example/popup-on-hover.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"features": [{
"type": "Feature",
"properties": {
"description": "<strong>Make it Mount Pleasant</strong><p><a href=\"http://www.mtpleasantdc.com/makeitmtpleasant\" target=\"_blank\" title=\"Opens in a new window\">Make it Mount Pleasant</a> is a handmade and vintage market and afternoon of live entertainment and kids activities. 12:00-6:00 p.m.</p>",
"description": "<strong>Make it Mount Pleasant</strong><p>Make it Mount Pleasant is a handmade and vintage market and afternoon of live entertainment and kids activities. 12:00-6:00 p.m.</p>",
"icon": "theatre"
},
"geometry": {
Expand All @@ -37,7 +37,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>Mad Men Season Five Finale Watch Party</strong><p>Head to Lounge 201 (201 Massachusetts Avenue NE) Sunday for a <a href=\"http://madmens5finale.eventbrite.com/\" target=\"_blank\" title=\"Opens in a new window\">Mad Men Season Five Finale Watch Party</a>, complete with 60s costume contest, Mad Men trivia, and retro food and drink. 8:00-11:00 p.m. $10 general admission, $20 admission and two hour open bar.</p>",
"description": "<strong>Mad Men Season Five Finale Watch Party</strong><p>Head to Lounge 201 (201 Massachusetts Avenue NE) Sunday for a Mad Men Season Five Finale Watch Party, complete with 60s costume contest, Mad Men trivia, and retro food and drink. 8:00-11:00 p.m. $10 general admission, $20 admission and two hour open bar.</p>",
"icon": "theatre"
},
"geometry": {
Expand All @@ -47,7 +47,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>Big Backyard Beach Bash and Wine Fest</strong><p>EatBar (2761 Washington Boulevard Arlington VA) is throwing a <a href=\"http://tallulaeatbar.ticketleap.com/2012beachblanket/\" target=\"_blank\" title=\"Opens in a new window\">Big Backyard Beach Bash and Wine Fest</a> on Saturday, serving up conch fritters, fish tacos and crab sliders, and Red Apron hot dogs. 12:00-3:00 p.m. $25.grill hot dogs.</p>",
"description": "<strong>Big Backyard Beach Bash and Wine Fest</strong><p>EatBar (2761 Washington Boulevard Arlington VA) is throwing a Big Backyard Beach Bash and Wine Fest on Saturday, serving up conch fritters, fish tacos and crab sliders, and Red Apron hot dogs. 12:00-3:00 p.m. $25.grill hot dogs.</p>",
"icon": "bar"
},
"geometry": {
Expand All @@ -57,7 +57,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>Ballston Arts & Crafts Market</strong><p>The <a href=\"http://ballstonarts-craftsmarket.blogspot.com/\" target=\"_blank\" title=\"Opens in a new window\">Ballston Arts & Crafts Market</a> sets up shop next to the Ballston metro this Saturday for the first of five dates this summer. Nearly 35 artists and crafters will be on hand selling their wares. 10:00-4:00 p.m.</p>",
"description": "<strong>Ballston Arts & Crafts Market</strong><p>The Ballston Arts & Crafts Market sets up shop next to the Ballston metro this Saturday for the first of five dates this summer. Nearly 35 artists and crafters will be on hand selling their wares. 10:00-4:00 p.m.</p>",
"icon": "art-gallery"
},
"geometry": {
Expand All @@ -67,7 +67,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>Seersucker Bike Ride and Social</strong><p>Feeling dandy? Get fancy, grab your bike, and take part in this year's <a href=\"http://dandiesandquaintrelles.com/2012/04/the-seersucker-social-is-set-for-june-9th-save-the-date-and-start-planning-your-look/\" target=\"_blank\" title=\"Opens in a new window\">Seersucker Social</a> bike ride from Dandies and Quaintrelles. After the ride enjoy a lawn party at Hillwood with jazz, cocktails, paper hat-making, and more. 11:00-7:00 p.m.</p>",
"description": "<strong>Seersucker Bike Ride and Social</strong><p>Feeling dandy? Get fancy, grab your bike, and take part in this year's Seersucker Social bike ride from Dandies and Quaintrelles. After the ride enjoy a lawn party at Hillwood with jazz, cocktails, paper hat-making, and more. 11:00-7:00 p.m.</p>",
"icon": "bicycle"
},
"geometry": {
Expand All @@ -77,7 +77,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>Capital Pride Parade</strong><p>The annual <a href=\"http://www.capitalpride.org/parade\" target=\"_blank\" title=\"Opens in a new window\">Capital Pride Parade</a> makes its way through Dupont this Saturday. 4:30 p.m. Free.</p>",
"description": "<strong>Capital Pride Parade</strong><p>The annual Capital Pride Parade makes its way through Dupont this Saturday. 4:30 p.m. Free.</p>",
"icon": "star"
},
"geometry": {
Expand All @@ -87,7 +87,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>Muhsinah</strong><p>Jazz-influenced hip hop artist <a href=\"http://www.muhsinah.com\" target=\"_blank\" title=\"Opens in a new window\">Muhsinah</a> plays the <a href=\"http://www.blackcatdc.com\">Black Cat</a> (1811 14th Street NW) tonight with <a href=\"http://www.exitclov.com\" target=\"_blank\" title=\"Opens in a new window\">Exit Clov</a> and <a href=\"http://godsilla.bandcamp.com\" target=\"_blank\" title=\"Opens in a new window\">Gods’illa</a>. 9:00 p.m. $12.</p>",
"description": "<strong>Muhsinah</strong><p>Jazz-influenced hip hop artist Muhsinah plays the Black Cat (1811 14th Street NW) tonight with Exit Clov and Gods’illa. 9:00 p.m. $12.</p>",
"icon": "music"
},
"geometry": {
Expand All @@ -97,7 +97,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>A Little Night Music</strong><p>The Arlington Players' production of Stephen Sondheim's <a href=\"http://www.thearlingtonplayers.org/drupal-6.20/node/4661/show\" target=\"_blank\" title=\"Opens in a new window\"><em>A Little Night Music</em></a> comes to the Kogod Cradle at The Mead Center for American Theater (1101 6th Street SW) this weekend and next. 8:00 p.m.</p>",
"description": "<strong>A Little Night Music</strong><p>The Arlington Players' production of Stephen Sondheim's <em>A Little Night Music</em> comes to the Kogod Cradle at The Mead Center for American Theater (1101 6th Street SW) this weekend and next. 8:00 p.m.</p>",
"icon": "music"
},
"geometry": {
Expand All @@ -107,7 +107,7 @@
}, {
"type": "Feature",
"properties": {
"description": "<strong>Truckeroo</strong><p><a href=\"http://www.truckeroodc.com/www/\" target=\"_blank\">Truckeroo</a> brings dozens of food trucks, live music, and games to half and M Street SE (across from Navy Yard Metro Station) today from 11:00 a.m. to 11:00 p.m.</p>",
"description": "<strong>Truckeroo</strong><p>Truckeroo brings dozens of food trucks, live music, and games to half and M Street SE (across from Navy Yard Metro Station) today from 11:00 a.m. to 11:00 p.m.</p>",
"icon": "music"
},
"geometry": {
Expand Down
2 changes: 1 addition & 1 deletion docs/pages/example/set-popup.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
});

// create the popup
var popup = new mapboxgl.Popup()
var popup = new mapboxgl.Popup({ offset: 25 })
.setText('Construction on the Washington Monument began in 1848.');

// create DOM element for the marker
Expand Down
18 changes: 7 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "mapbox-gl",
"description": "A WebGL interactive maps library",
"version": "0.45.0-beta.1",
"version": "0.45.0",
"main": "dist/mapbox-gl.js",
"style": "dist/mapbox-gl.css",
"license": "SEE LICENSE IN LICENSE.txt",
Expand Down Expand Up @@ -61,7 +61,7 @@
"eslint-plugin-node": "^5.1.1",
"eslint-plugin-react": "^7.3.0",
"execcommand-copy": "^1.1.0",
"flow-bin": "^0.69.0",
"flow-bin": "^0.66.0",
"flow-coverage-report": "^0.3.0",
"github-slugger": "^1.1.1",
"gl": "^4.0.1",
Expand All @@ -77,8 +77,6 @@
"object.entries": "^1.0.4",
"pirates": "^3.0.2",
"pngjs": "^3.0.0",
"postcss-cli": "^5.0.0",
"postcss-inline-svg": "^3.1.1",
"prismjs": "^1.8.1",
"prop-types": "^15.6.0",
"raw-loader": "^0.5.1",
Expand Down Expand Up @@ -119,24 +117,22 @@
"build-dev": "rollup -c --environment BUILD:dev",
"watch-dev": "rollup -c --environment BUILD:dev --watch",
"build-min": "rollup -c --environment BUILD:production",
"build-css": "postcss -o dist/mapbox-gl.css src/css/mapbox-gl.css",
"build-style-spec": "cd src/style-spec && npm run build && cd ../.. && mkdir -p dist/style-spec && cp src/style-spec/dist/* dist/style-spec",
"watch-css": "postcss --watch -o dist/mapbox-gl.css src/css/mapbox-gl.css",
"build-token": "node build/generate-access-token-script.js",
"build-benchmarks": "BENCHMARK_VERSION=${BENCHMARK_VERSION:-\"$(git rev-parse --abbrev-ref HEAD) $(git rev-parse --short=7 HEAD)\"} rollup -c bench/rollup_config_benchmarks.js",
"build-benchmarks-view": "BENCHMARK_VERSION=${BENCHMARK_VERSION:-\"$(git rev-parse --abbrev-ref HEAD) $(git rev-parse --short=7 HEAD)\"} rollup -c bench/rollup_config_benchmarks_view.js",
"watch-benchmarks": "BENCHMARK_VERSION=${BENCHMARK_VERSION:-\"$(git rev-parse --abbrev-ref HEAD) $(git rev-parse --short=7 HEAD)\"} rollup -c bench/rollup_config_benchmarks.js --watch",
"watch-benchmarks-view": "BENCHMARK_VERSION=${BENCHMARK_VERSION:-\"$(git rev-parse --abbrev-ref HEAD) $(git rev-parse --short=7 HEAD)\"} rollup -c bench/rollup_config_benchmarks_view.js --watch",
"start-server": "st --no-cache -H 0.0.0.0 --port 9966 --index index.html .",
"start": "run-p build-token watch-css watch-dev watch-benchmarks watch-benchmarks-view start-server",
"start-debug": "run-p build-token watch-css watch-dev start-server",
"start": "run-p build-token watch-dev watch-benchmarks watch-benchmarks-view start-server",
"start-debug": "run-p build-token watch-dev start-server",
"start-bench": "run-p build-token watch-benchmarks watch-benchmarks-view start-server",
"build-docs": "documentation build --github --format json --config ./docs/documentation.yml --output docs/components/api.json src/index.js",
"build": "run-s build-docs && DEPLOY_ENV=production batfish build # invoked by publisher when publishing docs on the mb-pages branch",
"start-docs": "run-s build-min build-css build-docs && DEPLOY_ENV=local batfish start",
"start-docs": "run-s build-min build-docs && DEPLOY_ENV=local batfish start",
"lint": "eslint --cache --ignore-path .gitignore src test bench docs docs/pages/example/*.html debug/*.html",
"lint-docs": "documentation lint src/index.js",
"lint-css": "stylelint 'src/css/mapbox-gl.css'",
"lint-css": "stylelint 'dist/mapbox-gl.css'",
"open-changed-examples": "git diff --name-only mb-pages HEAD -- docs/pages/example/*.html | awk '{print \"http://127.0.0.1:4000/mapbox-gl-js/example/\" substr($0,33,length($0)-37)}' | xargs open",
"test": "run-s lint lint-css test-flow test-unit",
"test-suite": "run-s test-render test-query",
Expand All @@ -149,7 +145,7 @@
"test-flow": "node build/generate-flow-typed-style-spec && flow .",
"test-flow-cov": "flow-coverage-report -i 'src/**/*.js' -t html",
"test-cov": "nyc --require=@mapbox/flow-remove-types/register --reporter=text-summary --reporter=lcov --cache run-s test-unit test-expressions test-query test-render",
"prepublish": "in-publish && run-s build-dev build-min build-css build-style-spec test-build || not-in-publish",
"prepublish": "in-publish && run-s build-dev build-min build-style-spec test-build || not-in-publish",
"codegen": "build/run-node build/generate-style-code.js && build/run-node build/generate-struct-arrays.js"
},
"files": [
Expand Down
Loading

0 comments on commit 9ea7464

Please sign in to comment.