mirror of https://gitee.com/antv-l7/antv-l7
Merge branch 'master' of github.com:antvis/L7
This commit is contained in:
commit
46be5ae946
|
@ -155,6 +155,9 @@ export function printCanvas(canvas: HTMLCanvasElement) {
|
|||
|
||||
export function getViewPortScale() {
|
||||
const meta = document.querySelector('meta[name="viewport"]');
|
||||
if (!meta) {
|
||||
return 1;
|
||||
}
|
||||
const contentItems = (meta as any).content?.split(',');
|
||||
const scale = contentItems.find((item: string) => {
|
||||
const [key, value] = item.split('=');
|
||||
|
|
Loading…
Reference in New Issue