1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-30 13:20:05 -04:00

[egui_web] Add max canvas size to help perf issues on some platforms

Related: https://github.com/emilk/egui/issues/67
This commit is contained in:
Emil Ernerfeldt
2020-12-18 22:51:23 +01:00
parent c3c4f28a9d
commit 82a3997188
4 changed files with 46 additions and 13 deletions

View File

@@ -14,7 +14,7 @@
}
body {
background: #101010;
background: #202020;
}
/* Allow canvas to fill entire web page: */
@@ -24,6 +24,17 @@
margin: 0 !important;
padding: 0 !important;
}
/* Center canvas vertically and horizontally: */
canvas {
margin-right: auto;
margin-left: auto;
display: block;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
</style>
</head>