Add a rendering test case for text-align css property

This commit is contained in:
Frederic Junod
2019-10-07 13:25:04 +02:00
parent 057cc92716
commit 2ce14a50a1
3 changed files with 50 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 112 KiB

View File

@@ -0,0 +1,26 @@
<!DOCTYPE html>
<html>
<head>
<style>
html, body {
margin: 0;
padding: 0;
width: 100%;
height: 100%;
}
#map {
width: 100%;
height: 100%;
text-align: right;
}
.ol-control {
display: none;
}
</style>
</head>
<body>
<div id="map"></div>
<script src="main.js"></script>
</body>
</script>
</html>

View File

@@ -0,0 +1,24 @@
import Map from '../../../src/ol/Map.js';
import View from '../../../src/ol/View.js';
import TileLayer from '../../../src/ol/layer/Tile.js';
import {fromLonLat} from '../../../src/ol/proj.js';
import XYZ from '../../../src/ol/source/XYZ.js';
new Map({
layers: [
new TileLayer({
source: new XYZ({
url: '/data/tiles/satellite/{z}/{x}/{y}.jpg'
})
})
],
target: 'map',
view: new View({
rotation: Math.PI / 3,
center: fromLonLat([8.6, 50.1]),
zoom: 3
})
});
render();