mirror of
https://github.com/slint-ui/slint.git
synced 2025-09-30 22:01:13 +00:00
77 lines
No EOL
2.2 KiB
HTML
77 lines
No EOL
2.2 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<!--
|
|
This is a static html file used to display the wasm build.
|
|
In order to generate the build
|
|
- uncomment the #wasm# lines in Cargo.toml
|
|
- Run `wasm-pack build --release --target web` in this directory.
|
|
-->
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>SixtyFPS UI Printer Demo (Web Assembly version)</title>
|
|
<style>
|
|
canvas {
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
canvas:focus {
|
|
outline: none;
|
|
}
|
|
|
|
@media screen and (max-width: 992px) and (orientation: landscape) {
|
|
.hide-in-mobile-landscape {
|
|
display: none;
|
|
}
|
|
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
overflow: hidden;
|
|
}
|
|
|
|
canvas {
|
|
width: 100vw !important;
|
|
height: 100vh !important;
|
|
}
|
|
}
|
|
|
|
/* beautify ignore:start */
|
|
.spinner:before {
|
|
content: ''; box-sizing: border-box; position: absolute;
|
|
top: 50%; left: 50%; width: 100px; height: 100px;
|
|
margin-top: -10px; margin-left: -10px;
|
|
border-radius: 50%; border: 2px solid transparent;
|
|
border-top-color: #07d; border-bottom-color: #07d;
|
|
animation: spinner 1s ease infinite;
|
|
}
|
|
@keyframes spinner { to { transform: rotate(360deg); } }
|
|
/* beautify ignore:end */
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<p class="hide-in-mobile-landscape">This is the <a href="https://sixtyfps.io">SixtyFPS</a> UI Printer Demo compiled to WebAssembly. It simulates the
|
|
touch user interface of
|
|
the advanced "Print Machine 2000", without actually printing anything.</p>
|
|
<div id="spinner" style="position: relative;">
|
|
<div class="spinner">Loading...</div>
|
|
</div>
|
|
<canvas id="canvas" width="640" height="480" unselectable="on"></canvas>
|
|
<p class="hide-in-mobile-landscape">
|
|
<a href="https://github.com/sixtyfpsui/sixtyfps/blob/master/examples/printerdemo/ui/printerdemo.60">
|
|
View Source Code on GitHub</a> -
|
|
<a
|
|
href="https://sixtyfps.io/editor?load_url=https://raw.githubusercontent.com/sixtyfpsui/sixtyfps/master/examples/printerdemo/ui/printerdemo.60">
|
|
Edit in the online code editor
|
|
</a>
|
|
</p>
|
|
<script type="module">
|
|
import init from './pkg/printerdemo.js';
|
|
init().finally(() => {
|
|
document.getElementById("spinner").remove();
|
|
});
|
|
</script>
|
|
</body>
|
|
|
|
</html> |