@tresjs/nuxt 3.0.6 → 4.0.0-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/client/200.html +9 -10
- package/dist/client/404.html +9 -10
- package/dist/client/_nuxt/BK7-Y-q6.js +37 -0
- package/dist/client/_nuxt/C0Qz2vsI.js +3 -0
- package/dist/client/_nuxt/C5TOz6B6.js +1 -0
- package/dist/client/_nuxt/DkfJP6hB.js +1 -0
- package/dist/client/_nuxt/Dnn3U3St.js +1 -0
- package/dist/client/_nuxt/builds/latest.json +1 -1
- package/dist/client/_nuxt/builds/meta/c498c9c1-7699-4d46-8591-cd45a3483c8f.json +1 -0
- package/dist/client/_nuxt/entry.DWRHDGAm.css +1 -0
- package/dist/client/_nuxt/error-404.BbX5noJR.css +1 -0
- package/dist/client/_nuxt/error-500.Cu2U7TTf.css +1 -0
- package/dist/client/_nuxt/index.Ivt4LUQj.css +1 -0
- package/dist/client/_nuxt/{DLrlLUpD.js → zIW675W1.js} +3 -3
- package/dist/client/index.html +9 -10
- package/dist/module.json +2 -2
- package/dist/module.mjs +2 -2
- package/dist/runtime/TresCanvas.client.vue +1 -1
- package/dist/runtime/TresCanvas.server.vue +1 -1
- package/package.json +34 -35
- package/dist/client/_nuxt/Bga_S8Bf.js +0 -1
- package/dist/client/_nuxt/BsCY1oT1.js +0 -36
- package/dist/client/_nuxt/ByZDnZPR.js +0 -3
- package/dist/client/_nuxt/CBXazWey.js +0 -1
- package/dist/client/_nuxt/DSIVedaD.js +0 -1
- package/dist/client/_nuxt/builds/meta/39a9104a-e239-4a13-b7a3-05df09b4d5f6.json +0 -1
- package/dist/client/_nuxt/entry.DyrmTTiK.css +0 -1
- package/dist/client/_nuxt/error-404.BAR-Dz9D.css +0 -1
- package/dist/client/_nuxt/error-500.CcP-UbTX.css +0 -1
- package/dist/client/_nuxt/index.FktY5T_i.css +0 -1
package/dist/client/index.html
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
<!DOCTYPE html><html data-capo=""><head><meta charset="utf-8">
|
|
2
2
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
3
|
-
<link rel="stylesheet" href="/__tres_nuxt_devtools/_nuxt/entry.
|
|
4
|
-
<link rel="modulepreload" as="script" crossorigin href="/__tres_nuxt_devtools/_nuxt/
|
|
5
|
-
<link rel="prefetch" as="
|
|
6
|
-
<link rel="prefetch" as="
|
|
7
|
-
<link rel="prefetch" as="script" crossorigin href="/__tres_nuxt_devtools/_nuxt/
|
|
8
|
-
<link rel="prefetch" as="
|
|
9
|
-
<link rel="prefetch" as="
|
|
10
|
-
<
|
|
11
|
-
<script
|
|
12
|
-
<script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__tres_nuxt_devtools",buildId:"39a9104a-e239-4a13-b7a3-05df09b4d5f6",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
|
|
3
|
+
<link rel="stylesheet" href="/__tres_nuxt_devtools/_nuxt/entry.DWRHDGAm.css" crossorigin>
|
|
4
|
+
<link rel="modulepreload" as="script" crossorigin href="/__tres_nuxt_devtools/_nuxt/BK7-Y-q6.js">
|
|
5
|
+
<link rel="prefetch" as="style" crossorigin href="/__tres_nuxt_devtools/_nuxt/error-404.BbX5noJR.css">
|
|
6
|
+
<link rel="prefetch" as="script" crossorigin href="/__tres_nuxt_devtools/_nuxt/C5TOz6B6.js">
|
|
7
|
+
<link rel="prefetch" as="script" crossorigin href="/__tres_nuxt_devtools/_nuxt/DkfJP6hB.js">
|
|
8
|
+
<link rel="prefetch" as="style" crossorigin href="/__tres_nuxt_devtools/_nuxt/error-500.Cu2U7TTf.css">
|
|
9
|
+
<link rel="prefetch" as="script" crossorigin href="/__tres_nuxt_devtools/_nuxt/Dnn3U3St.js">
|
|
10
|
+
<script type="module" src="/__tres_nuxt_devtools/_nuxt/BK7-Y-q6.js" crossorigin></script><script>"use strict";(()=>{const t=window,e=document.documentElement,c=["dark","light"],n=getStorageValue("localStorage","nuxt-color-mode")||"system";let i=n==="system"?u():n;const r=e.getAttribute("data-color-mode-forced");r&&(i=r),l(i),t["__NUXT_COLOR_MODE__"]={preference:n,value:i,getColorScheme:u,addColorScheme:l,removeColorScheme:d};function l(o){const s=""+o+"",a="";e.classList?e.classList.add(s):e.className+=" "+s,a&&e.setAttribute("data-"+a,o)}function d(o){const s=""+o+"",a="";e.classList?e.classList.remove(s):e.className=e.className.replace(new RegExp(s,"g"),""),a&&e.removeAttribute("data-"+a)}function f(o){return t.matchMedia("(prefers-color-scheme"+o+")")}function u(){if(t.matchMedia&&f("").media!=="not all"){for(const o of c)if(f(":"+o).matches)return o}return"light"}})();function getStorageValue(t,e){switch(t){case"localStorage":return window.localStorage.getItem(e);case"sessionStorage":return window.sessionStorage.getItem(e);case"cookie":return getCookie(e);default:return null}}function getCookie(t){const c=("; "+window.document.cookie).split("; "+t+"=");if(c.length===2)return c.pop()?.split(";").shift()}</script></head><body><div id="__nuxt"></div><div id="teleports"></div><script type="application/json" data-nuxt-data="nuxt-app" data-ssr="false" id="__NUXT_DATA__">[{"prerenderedAt":1,"serverRendered":2},1740241784463,false]</script>
|
|
11
|
+
<script>window.__NUXT__={};window.__NUXT__.config={public:{},app:{baseURL:"/__tres_nuxt_devtools",buildId:"c498c9c1-7699-4d46-8591-cd45a3483c8f",buildAssetsDir:"/_nuxt/",cdnURL:""}}</script></body></html>
|
package/dist/module.json
CHANGED
package/dist/module.mjs
CHANGED
|
@@ -2,9 +2,9 @@ import { readFile } from 'node:fs/promises';
|
|
|
2
2
|
import { defineNuxtModule, createResolver, addImports, resolvePath, addComponent, addVitePlugin } from '@nuxt/kit';
|
|
3
3
|
import * as core from '@tresjs/core';
|
|
4
4
|
import { templateCompilerOptions } from '@tresjs/core';
|
|
5
|
-
import { readPackageJSON } from 'pkg-types';
|
|
6
|
-
import { findExportNames } from 'mlly';
|
|
7
5
|
import { defu } from 'defu';
|
|
6
|
+
import { findExportNames } from 'mlly';
|
|
7
|
+
import { readPackageJSON } from 'pkg-types';
|
|
8
8
|
import glsl from 'vite-plugin-glsl';
|
|
9
9
|
import { existsSync } from 'node:fs';
|
|
10
10
|
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tresjs/nuxt",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "
|
|
5
|
-
"packageManager": "pnpm@9.
|
|
4
|
+
"version": "4.0.0-next.0",
|
|
5
|
+
"packageManager": "pnpm@9.15.4",
|
|
6
6
|
"description": "TresJS integration for Nuxt.",
|
|
7
7
|
"author": "Daniel Roe (https://github.com/danielroe/)",
|
|
8
8
|
"license": "MIT",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"client:dev": "nuxi dev client --port 3300",
|
|
36
36
|
"dev": "nuxi dev playground",
|
|
37
37
|
"dev:build": "nuxi build playground",
|
|
38
|
-
"dev:prepare": "nuxt-module-build --stub && nuxi prepare playground",
|
|
38
|
+
"dev:prepare": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxi prepare playground",
|
|
39
39
|
"release": "release-it",
|
|
40
40
|
"lint": "eslint .",
|
|
41
41
|
"lint:fix": "eslint . --fix",
|
|
@@ -46,41 +46,40 @@
|
|
|
46
46
|
"three": ">=0.133"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@nuxt/
|
|
50
|
-
"@nuxt/
|
|
51
|
-
"@
|
|
52
|
-
"@
|
|
53
|
-
"@tresjs/nuxt": "3.0.4",
|
|
54
|
-
"@types/three": "^0.167.2",
|
|
55
|
-
"@unocss/nuxt": "^0.62.3",
|
|
49
|
+
"@nuxt/kit": "^3.15.4",
|
|
50
|
+
"@nuxt/ui": "^2.21.0",
|
|
51
|
+
"@tresjs/core": "https://pkg.pr.new/@tresjs/core@47bb9e7",
|
|
52
|
+
"@unocss/nuxt": "^66.0.0",
|
|
56
53
|
"defu": "^6.1.4",
|
|
57
|
-
"mlly": "^1.7.
|
|
58
|
-
"pkg-types": "^1.
|
|
59
|
-
"sirv": "^
|
|
60
|
-
"
|
|
61
|
-
"vite-plugin-glsl": "^1.3.0"
|
|
54
|
+
"mlly": "^1.7.4",
|
|
55
|
+
"pkg-types": "^1.3.1",
|
|
56
|
+
"sirv": "^3.0.1",
|
|
57
|
+
"vite-plugin-glsl": "^1.3.1"
|
|
62
58
|
},
|
|
63
59
|
"devDependencies": {
|
|
64
|
-
"@iconify-json/carbon": "^1.
|
|
65
|
-
"@iconify-json/file-icons": "^1.1
|
|
66
|
-
"@iconify-json/iconoir": "^1.
|
|
67
|
-
"@iconify-json/ph": "^1.
|
|
68
|
-
"@nuxt/devtools
|
|
69
|
-
"@nuxt/
|
|
70
|
-
"@nuxt/
|
|
71
|
-
"@nuxt/
|
|
72
|
-
"@nuxt/
|
|
73
|
-
"@nuxt/
|
|
74
|
-
"@
|
|
75
|
-
"@
|
|
76
|
-
"@
|
|
77
|
-
"
|
|
78
|
-
"
|
|
79
|
-
"
|
|
80
|
-
"
|
|
81
|
-
"
|
|
82
|
-
"
|
|
83
|
-
"
|
|
60
|
+
"@iconify-json/carbon": "^1.2.5",
|
|
61
|
+
"@iconify-json/file-icons": "^1.2.1",
|
|
62
|
+
"@iconify-json/iconoir": "^1.2.6",
|
|
63
|
+
"@iconify-json/ph": "^1.2.2",
|
|
64
|
+
"@nuxt/devtools": "^1.6.4",
|
|
65
|
+
"@nuxt/devtools-ui-kit": "^1.6.4",
|
|
66
|
+
"@nuxt/eslint-config": "^0.7.3",
|
|
67
|
+
"@nuxt/icon": "^1.10.2",
|
|
68
|
+
"@nuxt/module-builder": "^0.8.4",
|
|
69
|
+
"@nuxt/schema": "^3.14.1592",
|
|
70
|
+
"@nuxt/test-utils": "^3.15.1",
|
|
71
|
+
"@release-it/conventional-changelog": "^9.0.3",
|
|
72
|
+
"@tresjs/cientos": "^4.0.3",
|
|
73
|
+
"@types/node": "^22.10.2",
|
|
74
|
+
"@types/three": "^0.171.0",
|
|
75
|
+
"changelogen": "^0.5.7",
|
|
76
|
+
"eslint": "^9.17.0",
|
|
77
|
+
"nuxt": "^3.14.1592",
|
|
78
|
+
"playwright": "^1.49.1",
|
|
79
|
+
"release-it": "^17.10.0",
|
|
80
|
+
"three": "^0.171.0",
|
|
81
|
+
"typescript": "^5.6.3",
|
|
82
|
+
"vitest": "^2.1.8"
|
|
84
83
|
},
|
|
85
84
|
"build": {
|
|
86
85
|
"externals": [
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{$ as S,g as B,K as _,a0 as R,B as N,a1 as T,a2 as E,a3 as U,a4 as F,a5 as A,a6 as w,a7 as I,a8 as V,q as x,a9 as O,aa as k,ab as D,ac as H,ad as $,ae as z,af as M}from"./BsCY1oT1.js";async function j(t,r=S()){const{path:f,matched:y}=r.resolve(t);if(!y.length||(r._routePreloaded||(r._routePreloaded=new Set),r._routePreloaded.has(f)))return;const e=r._preloadPromises=r._preloadPromises||[];if(e.length>4)return Promise.all(e).then(()=>j(t,r));r._routePreloaded.add(f);const a=y.map(o=>{var n;return(n=o.components)==null?void 0:n.default}).filter(o=>typeof o=="function");for(const o of a){const n=Promise.resolve(o()).catch(()=>{}).finally(()=>e.splice(e.indexOf(n)));e.push(n)}await Promise.all(e)}const K=(...t)=>t.find(r=>r!==void 0);function Q(t){const r=t.componentName||"NuxtLink";function f(e,a){if(!e||t.trailingSlash!=="append"&&t.trailingSlash!=="remove")return e;if(typeof e=="string")return L(e,t.trailingSlash);const o="path"in e&&e.path!==void 0?e.path:a(e).path;return{...e,name:void 0,path:L(o,t.trailingSlash)}}function y(e){const a=S(),o=$(),n=x(()=>!!e.target&&e.target!=="_self"),v=x(()=>{const d=e.to||e.href||"";return typeof d=="string"&&O(d,{acceptRelative:!0})}),b=w("RouterLink"),m=b&&typeof b!="string"?b.useLink:void 0,h=x(()=>{if(e.external)return!0;const d=e.to||e.href||"";return typeof d=="object"?!1:d===""||v.value}),i=x(()=>{const d=e.to||e.href||"";return h.value?d:f(d,a.resolve)}),s=h.value||m==null?void 0:m({...e,to:i}),p=x(()=>{var d;if(!i.value||v.value)return i.value;if(h.value){const P=typeof i.value=="object"&&"path"in i.value?k(i.value):i.value,C=typeof P=="object"?a.resolve(P).href:P;return f(C,a.resolve)}return typeof i.value=="object"?((d=a.resolve(i.value))==null?void 0:d.href)??null:f(D(o.app.baseURL,i.value),a.resolve)});return{to:i,hasTarget:n,isAbsoluteUrl:v,isExternal:h,href:p,isActive:(s==null?void 0:s.isActive)??x(()=>i.value===a.currentRoute.value.path),isExactActive:(s==null?void 0:s.isExactActive)??x(()=>i.value===a.currentRoute.value.path),route:(s==null?void 0:s.route)??x(()=>a.resolve(i.value)),async navigate(){await H(p.value,{replace:e.replace,external:h.value||n.value})}}}return B({name:r,props:{to:{type:[String,Object],default:void 0,required:!1},href:{type:[String,Object],default:void 0,required:!1},target:{type:String,default:void 0,required:!1},rel:{type:String,default:void 0,required:!1},noRel:{type:Boolean,default:void 0,required:!1},prefetch:{type:Boolean,default:void 0,required:!1},prefetchOn:{type:[String,Object],default:void 0,required:!1},noPrefetch:{type:Boolean,default:void 0,required:!1},activeClass:{type:String,default:void 0,required:!1},exactActiveClass:{type:String,default:void 0,required:!1},prefetchedClass:{type:String,default:void 0,required:!1},replace:{type:Boolean,default:void 0,required:!1},ariaCurrentValue:{type:String,default:void 0,required:!1},external:{type:Boolean,default:void 0,required:!1},custom:{type:Boolean,default:void 0,required:!1}},useLink:y,setup(e,{slots:a}){const o=S(),{to:n,href:v,navigate:b,isExternal:m,hasTarget:h,isAbsoluteUrl:i}=y(e),s=_(!1),p=_(null),d=l=>{var c;p.value=e.custom?(c=l==null?void 0:l.$el)==null?void 0:c.nextElementSibling:l==null?void 0:l.$el};function P(l){var c,u;return!s.value&&(typeof e.prefetchOn=="string"?e.prefetchOn===l:((c=e.prefetchOn)==null?void 0:c[l])??((u=t.prefetchOn)==null?void 0:u[l]))&&(e.prefetch??t.prefetch)!==!1&&e.noPrefetch!==!0&&e.target!=="_blank"&&!G()}async function C(l=R()){if(s.value)return;s.value=!0;const c=typeof n.value=="string"?n.value:m.value?k(n.value):o.resolve(n.value).fullPath;await Promise.all([l.hooks.callHook("link:prefetch",c).catch(()=>{}),!m.value&&!h.value&&j(n.value,o).catch(()=>{})])}if(P("visibility")){const l=R();let c,u=null;N(()=>{const g=W();T(()=>{c=E(()=>{var q;(q=p==null?void 0:p.value)!=null&&q.tagName&&(u=g.observe(p.value,async()=>{u==null||u(),u=null,await C(l)}))})})}),U(()=>{c&&F(c),u==null||u(),u=null})}return()=>{var u;if(!m.value&&!h.value){const g={ref:d,to:n.value,activeClass:e.activeClass||t.activeClass,exactActiveClass:e.exactActiveClass||t.exactActiveClass,replace:e.replace,ariaCurrentValue:e.ariaCurrentValue,custom:e.custom,onPointerenter:P("interaction")?C.bind(null,void 0):void 0,onFocus:P("interaction")?C.bind(null,void 0):void 0};return e.custom||(s.value&&(g.class=e.prefetchedClass||t.prefetchedClass),g.rel=e.rel||void 0),A(w("RouterLink"),g,a.default)}const l=e.target||null,c=K(e.noRel?"":e.rel,t.externalRelAttribute,i.value||h.value?"noopener noreferrer":"")||null;return e.custom?a.default?a.default({href:v.value,navigate:b,get route(){if(!v.value)return;const g=new URL(v.value,window.location.href);return{path:g.pathname,fullPath:g.pathname,get query(){return I(g.search)},hash:g.hash,params:{},name:void 0,matched:[],redirectedFrom:void 0,meta:{},href:v.value}},rel:c,target:l,isExternal:m.value||h.value,isActive:!1,isExactActive:!1}):null:A("a",{ref:p,href:v.value||null,rel:c,target:l},(u=a.default)==null?void 0:u.call(a))}}})}const X=Q(V);function L(t,r){const f=r==="append"?z:M;return O(t)&&!t.startsWith("http")?t:f(t,!0)}function W(){const t=R();if(t._observer)return t._observer;let r=null;const f=new Map,y=(a,o)=>(r||(r=new IntersectionObserver(n=>{for(const v of n){const b=f.get(v.target);(v.isIntersecting||v.intersectionRatio>0)&&b&&b()}})),f.set(a,o),r.observe(a),()=>{f.delete(a),r.unobserve(a),f.size===0&&(r.disconnect(),r=null)});return t._observer={observe:y}}function G(){const t=navigator.connection;return!!(t&&(t.saveData||/2g/.test(t.effectiveType)))}export{X as _};
|