update assets

This commit is contained in:
Mario Voigt 2021-10-24 19:38:14 +02:00
parent e44f35095a
commit f7354f5fd5

View File

@ -36,17 +36,15 @@ function lS(src){
document.body.appendChild(s) document.body.appendChild(s)
}); });
} }
```
```
if($('.view-raw>a[href$=".stl" i]').length){ if($('.view-raw>a[href$=".stl" i]').length){
$('body').append('<link href="/Madeleine.js/src/css/Madeleine.css" rel="stylesheet">'); $('body').append('<link href="/assets/Madeleine.js/src/css/Madeleine.css" rel="stylesheet">');
Promise.all([lS("/Madeleine.js/src/lib/stats.js"),lS("/Madeleine.js/src/lib/detector.js"), lS("/Madeleine.js/src/lib/three.min.js"), lS("/Madeleine.js/src/Madeleine.js")]).then(function() { Promise.all([lS("/assets/Madeleine.js/src/lib/stats.js"),lS("/assets/Madeleine.js/src/lib/detector.js"), lS("/assets/Madeleine.js/src/lib/three.min.js"), lS("/assets/Madeleine.js/src/Madeleine.js")]).then(function() {
$('.view-raw').attr('id', 'view-raw').attr('style', 'padding: 0;margin-bottom: -10px;'); $('.view-raw').attr('id', 'view-raw').attr('style', 'padding: 0;margin-bottom: -10px;');
new Madeleine({ new Madeleine({
target: 'view-raw', target: 'view-raw',
data: $('.view-raw>a[href$=".stl" i]').attr('href'), data: $('.view-raw>a[href$=".stl" i]').attr('href'),
path: '/Madeleine.js/src' path: '/assets/Madeleine.js/src'
}); });
$('.view-raw>a[href$=".stl"]').remove() $('.view-raw>a[href$=".stl"]').remove()
}); });