added default popup and minor fixes
This commit is contained in:
parent
c1174af3fe
commit
cbe5c021d7
6 changed files with 80 additions and 22 deletions
|
|
@ -32,7 +32,7 @@ body{
|
||||||
|
|
||||||
@media (max-width: 470px){
|
@media (max-width: 470px){
|
||||||
.menu a:nth-child(2){
|
.menu a:nth-child(2){
|
||||||
display: text-decoration:none;
|
display: none;
|
||||||
border:none;none;
|
border:none;none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -26,9 +26,7 @@
|
||||||
<a href="https://codeberg.org/coderofsalvation/xrforge-v2">Sourcecode</a> <br>
|
<a href="https://codeberg.org/coderofsalvation/xrforge-v2">Sourcecode</a> <br>
|
||||||
{if footerlinks then
|
{if footerlinks then
|
||||||
for i,v in pairs(footerlinks) do
|
for i,v in pairs(footerlinks) do
|
||||||
print([[
|
print('<a href="' .. v.url .. '" ' .. ' onclick="' .. (v.onclick or '') .. '">' .. v.title .. '</a><br>')
|
||||||
<a href="]] .. v.url .. [[">]] .. v.title .. [[</a><br>
|
|
||||||
]])
|
|
||||||
end
|
end
|
||||||
end}
|
end}
|
||||||
</td>
|
</td>
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,11 @@ ${header}
|
||||||
<iframe border="0" frameborder="0" src="janusweb/index.html#janus.url=${janusurl}&janus.referrer=${referrer}" id="viewer"></iframe>
|
<iframe border="0" frameborder="0" src="janusweb/index.html#janus.url=${janusurl}&janus.referrer=${referrer}" id="viewer"></iframe>
|
||||||
|
|
||||||
{if defined(item) and item.parent and item.parent.info then
|
{if defined(item) and item.parent and item.parent.info then
|
||||||
print([[
|
description = item.parent.info
|
||||||
|
else
|
||||||
|
description = opts.plugin_global_popup_instructions
|
||||||
|
end}
|
||||||
|
|
||||||
<div id="popup" class="content">
|
<div id="popup" class="content">
|
||||||
<div class="spectrum span" style="top:-1px">
|
<div class="spectrum span" style="top:-1px">
|
||||||
<div></div>
|
<div></div>
|
||||||
|
|
@ -15,10 +19,8 @@ ${header}
|
||||||
<img src="${item.parent.thumbnail}" width="100%"/>
|
<img src="${item.parent.thumbnail}" width="100%"/>
|
||||||
</noscript>
|
</noscript>
|
||||||
<img src="img/close.svg" width="20" class="icon close" onclick="document.querySelector('#popup').style.display = 'none'"/>
|
<img src="img/close.svg" width="20" class="icon close" onclick="document.querySelector('#popup').style.display = 'none'"/>
|
||||||
]] .. item.parent.info .. [[
|
${description}
|
||||||
</div>
|
</div>
|
||||||
]])
|
|
||||||
end}
|
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
// Title- and URL-sync between parent/iframe to foster addressibility
|
// Title- and URL-sync between parent/iframe to foster addressibility
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ local plugin = {
|
||||||
key='app.opts.plugin_archive_scraper',
|
key='app.opts.plugin_archive_scraper',
|
||||||
title='XR Scraper',
|
title='XR Scraper',
|
||||||
info='archive external links in experiences as local copies',
|
info='archive external links in experiences as local copies',
|
||||||
default = os.getenv('DEBUG') and 'enabled' or "disabled",
|
default = "disabled",
|
||||||
values={disabled="disabled",enabled="enabled"}
|
values={disabled="disabled",enabled="enabled"}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -32,11 +32,12 @@ app.on('util.template', function(data)
|
||||||
data.footerlinks = data.footerlinks or {}
|
data.footerlinks = data.footerlinks or {}
|
||||||
table.insert(data.footerlinks, {
|
table.insert(data.footerlinks, {
|
||||||
title="<img class='icon download' src='/img/download.svg'> Download data",
|
title="<img class='icon download' src='/img/download.svg'> Download data",
|
||||||
url="/" .. app.bin:gsub(".com",".zip")
|
url="/" .. app.bin:gsub("-.*_.*%.","."):gsub(".com",".zip")
|
||||||
})
|
})
|
||||||
table.insert(data.footerlinks, {
|
table.insert(data.footerlinks, {
|
||||||
title="<img class='icon download' src='/img/download.svg'> Download data+platform",
|
title="<img class='icon download' src='/img/download.svg'> Download data+platform",
|
||||||
url="/" .. app.bin
|
url="/" .. app.bin:gsub("-.*_.*%.","."),
|
||||||
|
onclick="alert('This will download the platform executable, which runs on WINDOWS/MAC/LINUX.\\n\\nFor MAC/LINUX users it should be made executable first\\n\\nHappy credible exit! \\o/\\n')"
|
||||||
})
|
})
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
@ -92,6 +93,61 @@ local plugin = {
|
||||||
default = "2D",
|
default = "2D",
|
||||||
values={ ['3D'] = '3D', ['2D'] = '2D' },
|
values={ ['3D'] = '3D', ['2D'] = '2D' },
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
key='app.opts.plugin_global_popup_instructions',
|
||||||
|
title='Viewer instructions',
|
||||||
|
info='Default popup for 3D viewer instructions',
|
||||||
|
default = [[
|
||||||
|
<h1>Tips to navigate in XR</h1>
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<td width="200">
|
||||||
|
<b>AR/VR headset</b>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
walk around / use right-longpinch (or thumbstick) for local teleports<br/>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<b>PhoneVR</b>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
use gaze or bluetooth/mouse to navigate
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<b>PhoneAR</b>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
walk around and tap screen to click
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<b>Mobile</b>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
use the WASD-keys and mousedrag to navigate
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<b>Keyboard+Mouse</b>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
use the WASD-keys and mousedrag to navigate
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<br/>
|
||||||
|
You've got this!
|
||||||
|
<br/>
|
||||||
|
]],
|
||||||
|
control='textarea',
|
||||||
|
values=''
|
||||||
|
},
|
||||||
{
|
{
|
||||||
key='app.opts.plugin_global_credible_exit',
|
key='app.opts.plugin_global_credible_exit',
|
||||||
title='Credible exit',
|
title='Credible exit',
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,8 @@ download(){
|
||||||
chmod +x /tmp/assimilate
|
chmod +x /tmp/assimilate
|
||||||
}
|
}
|
||||||
rm $OUTDIR/*.bak || true
|
rm $OUTDIR/*.bak || true
|
||||||
/tmp/assimilate $OUTDIR/xrforge.com
|
cp $OUTDIR/xrforge.com $OUTDIR/xrforge-$ARCH.com
|
||||||
|
/tmp/assimilate $OUTDIR/xrforge-$ARCH.com
|
||||||
}
|
}
|
||||||
chmod +x $OUTDIR/*.com
|
chmod +x $OUTDIR/*.com
|
||||||
#verify
|
#verify
|
||||||
|
|
@ -46,8 +47,9 @@ build(){
|
||||||
download redbean
|
download redbean
|
||||||
download janusweb
|
download janusweb
|
||||||
cd src
|
cd src
|
||||||
zip -yr ../result/bin/xrforge.com * .lua .init.lua .args
|
bundle(){ zip -yr $1 * .lua .init.lua .args; }
|
||||||
test -n "$ARCH" && cp ../result/bin/xrforge.com ../result/bin/xrforge-$ARCH.com
|
bundle ../result/bin/xrforge.com
|
||||||
|
test -n "$ARCH" && bundle ../result/bin/xrforge-$ARCH.com
|
||||||
}
|
}
|
||||||
|
|
||||||
rebuild(){
|
rebuild(){
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue