Skip to content

Commit 76bf932

Browse files
committed
Website updates
1 parent 5a1d6be commit 76bf932

File tree

9 files changed

+67
-8
lines changed

9 files changed

+67
-8
lines changed

dist/en/main/apidoc/module-ol_source_TileDebug-TileDebug.html

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ <h4 class="name">
166166

167167
<div class="tag-source">
168168
<a href="https://github.com/openlayers/openlayers/blob/main/src/ol/source/TileDebug.js">source/TileDebug.js</a>,
169-
<a href="https://github.com/openlayers/openlayers/blob/main/src/ol/source/TileDebug.js#L36">line 36</a>
169+
<a href="https://github.com/openlayers/openlayers/blob/main/src/ol/source/TileDebug.js#L37">line 37</a>
170170
</div>
171171

172172
</div>
@@ -368,6 +368,33 @@ <h4 class="name">
368368
</tr>
369369

370370

371+
372+
<tr class="">
373+
374+
<td class="name"><code>color</code></td>
375+
376+
377+
378+
<td class="type">
379+
380+
381+
<span class="param-type">string</span>
382+
383+
384+
385+
(defaults to 'grey')
386+
387+
388+
</td>
389+
390+
391+
392+
<td class="description last">
393+
394+
<p>CSS color to fill text and stroke grid lines of each tile.</p></td>
395+
</tr>
396+
397+
371398
</tbody>
372399
</table>
373400

dist/en/main/apidoc/module-ol_source_TileDebug.html

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -355,6 +355,31 @@ <h5 class="subsection-title">Properties:</h5>
355355
</tr>
356356

357357

358+
359+
<tr>
360+
361+
<td class="name"><code>color</code></td>
362+
363+
364+
<td class="type">
365+
366+
367+
<span class="param-type">string</span>
368+
369+
370+
371+
<br>(defaults to 'grey')
372+
373+
374+
</td>
375+
376+
<td class="description last">
377+
<p>CSS color to fill text and stroke grid lines of each tile.</p>
378+
379+
</td>
380+
</tr>
381+
382+
358383
</tbody>
359384
</table></dl>
360385

dist/en/main/examples/common.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/examples/common.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/ol/dist/ol.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/ol/dist/ol.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/ol/source/TileDebug.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ export type Options = {
2929
* Should include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
3030
*/
3131
template?: string | undefined;
32+
/**
33+
* CSS color to fill text and stroke grid lines of each tile.
34+
*/
35+
color?: string | undefined;
3236
};
3337
/**
3438
* @typedef {Object} Options
@@ -44,6 +48,7 @@ export type Options = {
4448
* If both `source` and individual options are specified the individual options will have precedence.
4549
* @property {string} [template='z:{z} x:{x} y:{y}'] Template for labeling the tiles.
4650
* Should include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
51+
* @property {string} [color='grey'] CSS color to fill text and stroke grid lines of each tile.
4752
*/
4853
/**
4954
* @classdesc

dist/en/main/ol/source/TileDebug.d.ts.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/ol/source/TileDebug.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ import ImageTile from './ImageTile.js';
2424
* If both `source` and individual options are specified the individual options will have precedence.
2525
* @property {string} [template='z:{z} x:{x} y:{y}'] Template for labeling the tiles.
2626
* Should include `{x}`, `{y}` or `{-y}`, and `{z}` placeholders.
27+
* @property {string} [color='grey'] CSS color to fill text and stroke grid lines of each tile.
2728
*/
2829

2930
/**
@@ -44,6 +45,7 @@ class TileDebug extends ImageTile {
4445
options = options || {};
4546
const template = options.template || 'z:{z} x:{x} y:{y}';
4647
const source = options.source;
48+
const color = options.color || 'grey';
4749

4850
super({
4951
transition: 0,
@@ -97,10 +99,10 @@ class TileDebug extends ImageTile {
9799
const [width, height] = this.getTileSize(z);
98100
const context = createCanvasContext2D(width, height);
99101

100-
context.strokeStyle = 'grey';
102+
context.strokeStyle = color;
101103
context.strokeRect(0.5, 0.5, width + 0.5, height + 0.5);
102104

103-
context.fillStyle = 'grey';
105+
context.fillStyle = color;
104106
context.strokeStyle = 'white';
105107
context.textAlign = 'center';
106108
context.textBaseline = 'middle';

0 commit comments

Comments
 (0)