x0/test.html

41 lines
1.9 KiB
HTML
Raw Normal View History

<html
x0-mods="locale,copy,http"
x0-module-root="./modules/"
2023-12-24 20:40:28 +01:00
x0-locale-file="./test.json"
x0-locale-watch
>
2023-12-24 00:32:43 +01:00
<body>
<button onclick="window.x0.update()">Update x0</button>
2023-12-24 20:40:28 +01:00
<button onclick="window.location.reload()" x-locale-key="debug-tools.reload">Reload page</button>
<input type="text" onfocus="this.value = document.querySelector('html').getAttribute('x0-mods')" onchange="document.querySelector('html').setAttribute('x0-mods', this.value); document.querySelector('#status').innerHTML='updated x0-mods'; window.x0.update(); setInterval(() => document.querySelector('#status').innerHTML = '', 500)">
<span id="status"></span>
2023-12-24 20:40:28 +01:00
<h1 x-locale-key="main.greeting">main.greeting</h1>
2023-12-24 00:32:43 +01:00
<div>
<h2 x-locale-key="copy-section.header"></h2>
2023-12-24 00:32:43 +01:00
<div id="ex">
2023-12-24 20:40:28 +01:00
<span x-locale-key="copy-section.content-span">origin</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
<span x-locale-key="copy-section.content-span">duplicate</span>
2023-12-24 00:32:43 +01:00
</div>
<div x-copy-query="#ex"></div>
2023-12-24 00:32:43 +01:00
</div>
<div>
<h2 x-locale-key="http-section.header"></h2>
<pre x-inner-text x-get="./test.html" x-get-refresh=1000>
2023-12-24 00:32:43 +01:00
</div>
</body>
<script src="./x0.js"></script>
</html>