@combos-fun/plugin-development-tool 0.0.47 → 0.0.49

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.
@@ -1 +1 @@
1
- "use strict";var e=require("tslib"),t=require("@combos-fun/engine"),n=require("@combos-fun/plugin-renderer"),o=require("@combos-fun/plugin-renderer-graphics"),s=require("@combos-fun/plugin-renderer-event"),i=require("@combos-fun/inspector-decorator");const r="combos-development-tool:set-pick-mode",a="combos-development-tool:pick-mode-success",c="combos-development-tool:refresh",d="combos-development-tool:gameobject-selected",l="combos-development-tool:clear-selection",h="combos-development-tool:gameobject-deselected",u="combos-development-tool:apply-property",p="combos-development-tool:set-muted",m="combos-development-tool:state-changed",f="combos-development-tool:set-marker-overlay",g="combos-development-tool:marker-overlay-success";class y extends t.Component{constructor(){super(...arguments),this.payload={}}static{this.componentName="CombosDevelopmentToolTarget"}init(e){this.payload=e?.payload?{...e.payload}:{}}}const O=[{componentName:"Sound",badgeColor:9133302,glyph:"speaker"}];function b(e,t=O){for(const n of t)if(e.getComponent(n.componentName))return n;return null}const w=16777215;function v(e,t,n=28){if(function(e,t,n){e.clear(),e.roundRect(0,0,n,n,.22*n),e.fill({color:t.badgeColor,alpha:.92}),e.roundRect(0,0,n,n,.22*n),e.stroke({width:Math.max(1,.05*n),color:16777215,alpha:.6})}(e,t,n),"speaker"===t.glyph)!function(e,t){e.poly([.28*t,.4*t,.42*t,.4*t,.55*t,.26*t,.55*t,.74*t,.42*t,.6*t,.28*t,.6*t]),e.fill({color:w,alpha:.96}),e.rect(.62*t,.44*t,.045*t,.12*t),e.fill({color:w,alpha:.96}),e.rect(.71*t,.39*t,.045*t,.22*t),e.fill({color:w,alpha:.96})}(e,n);else!function(e,t){e.circle(.5*t,.5*t,.18*t),e.fill({color:w,alpha:.96})}(e,n)}const E=["knoffice.tech","converge.ai"];function M(e,t){if(t.includes("*"))return!0;if(0===t.length)return!1;let n;try{n=new URL(e)}catch{return!1}const o=e.toLowerCase(),s=n.hostname.toLowerCase();for(const e of t){const t=e.trim();if(!t)continue;if(t.includes("://")){if(o===t.toLowerCase())return!0;continue}const n=t.toLowerCase().replace(/^\./,"");if(s===n||s.endsWith(`.${n}`))return!0}return!1}function S(e){if(!e?.length)return[...E];if(e.includes("*"))return["*"];const t=new Set,n=[];for(const o of[...E,...e]){const e=o.trim();e&&!t.has(e)&&(t.add(e),n.push(e))}return n}function k(e){return"string"==typeof e?"string":"number"==typeof e?"number":"boolean"==typeof e?"boolean":null!==e&&"object"==typeof e?"object":"unsupported"}function G(e,t=0){if(null==e)return e;if("number"==typeof e||"string"==typeof e||"boolean"==typeof e)return e;if(!(t>6)){if(Array.isArray(e))return e.map(e=>G(e,t+1));if("object"==typeof e){const n={};for(const[o,s]of Object.entries(e)){if("function"==typeof s)continue;const e=G(s,t+1);void 0!==e&&(n[o]=e)}return n}}}function C(e){const t=e.constructor,n=function(e){const t=Reflect.getMetadata(i.IDE_PROPERTY_METADATA,e)||{};return Object.keys(t).map(e=>({key:e,...t[e]}))}(t);return n.length>0?n:function(e){const t=e.IDEProps;return!t||Array.isArray(t)||"object"!=typeof t?[]:Object.keys(t).map(e=>{const n=t[e]||{};return{key:e,type:"string"==typeof n.type?n.type:void 0,step:"number"==typeof n.step?n.step:void 0,min:"number"==typeof n.min?n.min:void 0,max:"number"==typeof n.max?n.max:void 0,label:"string"==typeof n.label?n.label:void 0,description:"string"==typeof n.description?n.description:void 0,group:"string"==typeof n.group?n.group:void 0,editor:n.editor,enumOptions:Array.isArray(n.enumOptions)?n.enumOptions:void 0,unit:"string"==typeof n.unit?n.unit:void 0}})}(t)}function T(e,t){return e.editor?e.editor:"boolean"===t?"toggle":e.enumOptions?.length&&"string"===t?"enum":"number"===t?void 0!==e.min&&void 0!==e.max?"number-slider":"number-stepper":"string"===t?"text":void 0}function _(e){if(void 0!==e.min||void 0!==e.max||void 0!==e.step||void 0!==e.unit)return{min:e.min,max:e.max,step:e.step,unit:e.unit}}function x(e,t){if(e.label?.trim())return e.label.trim();const n=t[t.length-1];return n?function(e){return e.replace(/([a-z0-9])([A-Z])/g,"$1 $2").replace(/_/g," ").replace(/^./,e=>e.toUpperCase())}(n):void 0}function P(e,t,n,o){const s=t.description?.trim();if(!s)return[];const i=k(o);if("unsupported"===i)return[];const r=t.type,a="size"===r||"object"===i&&null!==o&&"width"in o&&"height"in o;if("vector2"===r||"object"===i&&null!==o&&"x"in o&&"y"in o||a){const i=o,r=a?["width","height"]:["x","y"],c=x(t,n)??e,d=[];for(const o of r){const r=i[o],a=k(r);if("unsupported"===a||"object"===a)continue;const l=[...n,o];d.push({path:l,value:r,valueType:a,label:`${c} ${o.toUpperCase()}`,description:s,group:t.group??e,editorKind:T(t,a),numberMeta:_(t),persistTarget:"Transform"===e?"gameObjectConstructor":"component"})}return d}if("object"===i)return[];const c=x(t,n);return c?[{path:n,value:G(o),valueType:i,label:c,description:s,group:t.group??e,editorKind:T(t,i),enumOptions:t.enumOptions,numberMeta:_(t),persistTarget:"Transform"===e?"gameObjectConstructor":"component"}]:[]}function R(e){const t=e.name,n=C(e);if(0===n.length)return[];const o=[],s=e;for(const e of n){const n=s[e.key];"function"!=typeof n&&o.push(...P(t,e,[e.key],n))}return o}function B(e){const t=e.getComponent(y),n=t?.payload?.source;var o;if((o=n)&&"object"==typeof o&&"string"==typeof o.file)return{file:n.file,anchor:n.anchor??e.name}}function L(e){const t=e.components.filter(e=>"CombosDevelopmentToolTarget"!==e.name).map(e=>({componentName:e.name,fieldDescriptors:R(e)})).filter(e=>e.fieldDescriptors.length>0);return{id:e.id,name:e.name,components:t,source:B(e)}}function A(e,t,n,o){const s=e.getComponent(t);if(!s||!n.length)return!1;let i=s;for(let e=0;e<n.length-1;e++){const t=n[e];void 0!==i[t]&&null!==i[t]||(i[t]={}),i=i[t]}return i[n[n.length-1]]=o,!0}const j=new Set(["position","size","origin","anchor","scale","skew"]);function D(e){if("number"==typeof e&&Number.isFinite(e))return e;if("string"==typeof e&&""!==e.trim()){const t=Number(e);return Number.isFinite(t)?t:void 0}}const N={Transform:function(e,t,n,o){const s=e.transform,i=s;if(1===n.length&&"rotation"===n[0]){const e=D(o);return void 0!==e&&(s.rotation=e,!0)}if(2===n.length&&j.has(n[0])){const t=n[0],s=n[1],r=D(o);if(void 0===r)return!1;const a=i[t];return!(!a||"object"!=typeof a)&&(a[s]=r,"position"===t&&(function(e){const t=e.getComponent("Physics");if(!t?.body)return;const{x:n,y:o}=e.transform.position;t.Body?.setPosition?t.Body.setPosition(t.body,{x:n,y:o}):(t.body.position.x=n,t.body.position.y=o)}(e),function(e){const t=e.getComponent("PlatformerMover");t&&(t.originX=e.transform.position.x,t.originY=e.transform.position.y)}(e)),!0)}return!1},Text:function(e,t,n,o){const s=t;if(1===n.length&&"text"===n[0])return s.text=String(o??""),!0;if(2===n.length&&"style"===n[0]){const e=n[1],t={...s.style??{},[e]:o};return s.style=t,!0}return!1},Sound:function(e,t,n,o){const s=t;if(1===n.length&&"volume"===n[0]||2===n.length&&"config"===n[0]&&"volume"===n[1]){const e=D(o);return void 0!==e&&(s.volume=e,!0)}return!1}};function I(e,t,n,o){const s=e.getComponent(t);if(!s||!n.length)return!1;const i=N[t];return!!i?.(e,s,n,o)||A(e,t,n,o)}function W(e){return{type:h,reason:e}}function V(e){return e}function q(e){return!(!e||"object"!=typeof e)&&e.type===l}const H="__combosDevelopmentToolOutline",U="__combosDevelopmentToolMarker:";let Y=class extends t.System{constructor(){super(...arguments),this.postMessageOrigin="*",this.allowedMessageOrigins=S(),this.enabled=!1,this.outlineGo=null,this.selected=null,this.tapHandlers=new Map,this.tapOwners=new Map,this.disabledGameEventGoIds=new Set,this.pickEvents=new Set,this.needsRescan=!1,this.lastOutlineBounds=null,this.mutedWithoutSoundSystem=!1,this.markerOverlayEnabled=!1,this.needsMarkerRescan=!1,this.markerGoByOwner=new Map,this.onWindowSetPickMode=e=>{const t=e.detail;t&&"boolean"==typeof t.enabled&&this.setEnabled(t.enabled)},this.onWindowSetMuted=e=>{const t=e.detail;t&&"boolean"==typeof t.muted&&this.setMuted(t.muted)},this.onWindowSetMarkerOverlay=e=>{const t=e.detail;t&&"boolean"==typeof t.enabled&&this.setMarkerOverlay(t.enabled)},this.onGameSetMarkerOverlay=e=>{e&&"boolean"==typeof e.enabled&&this.setMarkerOverlay(e.enabled)},this.onWindowMessage=e=>{if(!M(e.origin,this.allowedMessageOrigins))return;const t=e.data;t&&"object"==typeof t&&(t.type===r&&"boolean"==typeof t.enabled?this.setEnabled(t.enabled):t.type===p&&"boolean"==typeof t.muted?this.setMuted(t.muted):t.type===f&&"boolean"==typeof t.enabled?this.setMarkerOverlay(t.enabled):t.type===c?this.requestSceneRescan():q(t)?this.clearSelectionAndNotify("parent-request"):t.type===u&&this.handleApplyProperty(t))},this.onGameSetPickMode=e=>{e&&"boolean"==typeof e.enabled&&this.setEnabled(e.enabled)},this.onGameRefresh=()=>{this.requestSceneRescan()},this.onGameSetMuted=e=>{e&&"boolean"==typeof e.muted&&this.setMuted(e.muted)},this.onWindowRefresh=()=>{this.requestSceneRescan()}}static{this.systemName="CombosDevelopmentToolSystem"}init(e){this.postMessageOrigin=e?.postMessageOrigin??"*",this.allowedMessageOrigins=S(e?.allowedMessageOrigins),"undefined"!=typeof window&&(window.addEventListener(r,this.onWindowSetPickMode),window.addEventListener(p,this.onWindowSetMuted),window.addEventListener(f,this.onWindowSetMarkerOverlay),window.addEventListener(c,this.onWindowRefresh),window.addEventListener("message",this.onWindowMessage)),this.game.on(r,this.onGameSetPickMode),this.game.on(p,this.onGameSetMuted),this.game.on(f,this.onGameSetMarkerOverlay),this.game.on(c,this.onGameRefresh),this.enabled&&(this.needsRescan=!0)}onDestroy(){"undefined"!=typeof window&&(window.removeEventListener(r,this.onWindowSetPickMode),window.removeEventListener(p,this.onWindowSetMuted),window.removeEventListener(f,this.onWindowSetMarkerOverlay),window.removeEventListener(c,this.onWindowRefresh),window.removeEventListener("message",this.onWindowMessage)),this.game.off(r,this.onGameSetPickMode),this.game.off(p,this.onGameSetMuted),this.game.off(f,this.onGameSetMarkerOverlay),this.game.off(c,this.onGameRefresh),this.detachAllPicks(),this.detachAllMarkers(),this.restoreDisabledGameEvents(),this.clearSelectionAndNotify("pick-disabled")}setEnabled(e){this.enabled!==e&&(this.enabled=e,e?this.needsRescan=!0:(this.clearSelectionAndNotify("pick-disabled"),this.detachAllPicks(),this.restoreDisabledGameEvents(),this.postSetSuccess(!1)))}get isEnabled(){return this.enabled}setMarkerOverlay(e){this.markerOverlayEnabled!==e&&(this.markerOverlayEnabled=e,e?this.needsMarkerRescan=!0:(this.detachAllMarkers(),this.postMarkerOverlaySuccess(!1,[]),this.enabled&&(this.needsRescan=!0)))}get isMarkerOverlayEnabled(){return this.markerOverlayEnabled}get isMuted(){const e=this.getSoundSystem();return e?e.muted:this.mutedWithoutSoundSystem}setMuted(e){const t=this.getSoundSystem();t?t.muted=e:this.mutedWithoutSoundSystem=e,this.postStateChanged()}update(e){this.enabled&&this.needsRescan&&(this.needsRescan=!1,this.attachEditMode(),this.postSetSuccess(!0)),this.markerOverlayEnabled&&this.needsMarkerRescan&&(this.needsMarkerRescan=!1,this.attachMarkers());for(const e of[...this.tapOwners.values()])e.destroyed&&this.releasePick(e);for(const[e,t]of[...this.markerGoByOwner.entries()]){const n=this.findGameObjectById(e);(!n||n.destroyed||t.destroyed)&&this.removeMarker(e)}this.enabled&&this.selected&&this.outlineGo&&this.updateSelectionOutline()}componentChanged(e){if(!this.enabled)return;const{type:n,gameObject:o,componentName:s}=e;o&&"CombosDevelopmentToolTarget"===s&&(n===t.OBSERVER_TYPE.ADD?(this.stripGameEvent(o),this.ensurePick(o)):n===t.OBSERVER_TYPE.REMOVE&&(this.releasePick(o),this.selected===o&&this.clearSelectionAndNotify("target-removed")))}requestSceneRescan(){this.enabled&&(this.needsRescan=!0),this.markerOverlayEnabled&&(this.needsMarkerRescan=!0)}attachEditMode(){this.detachAllPicks();const e=[];for(const t of this.game.scene.transform.children)this.collectGameObjects(t.gameObject,e);for(const t of e)this.isIgnoredPickGo(t)||this.stripGameEvent(t);for(const t of e)this.isIgnoredPickGo(t)||t.getComponent(y)&&this.ensurePick(t)}collectGameObjects(e,t){t.push(e);for(const n of e.transform.children)this.collectGameObjects(n.gameObject,t)}isIgnoredPickGo(e){return e.name===H||e===this.outlineGo||this.isMarkerGo(e)}isMarkerGo(e){return"string"==typeof e.name&&e.name.startsWith(U)}stripGameEvent(e){if(this.disabledGameEventGoIds.has(e.id))return;if(!e.getComponent(s.Event))return;const t=this.getRendererContainer(e);if(t)try{t.interactive=!1,this.disabledGameEventGoIds.add(e.id)}catch{}}restoreDisabledGameEvents(){for(const e of[...this.disabledGameEventGoIds]){const t=this.findGameObjectById(e);if(!t||t.destroyed){this.disabledGameEventGoIds.delete(e);continue}const n=this.getRendererContainer(t);if(n)try{n.interactive=!0}catch{}this.disabledGameEventGoIds.delete(e)}}detachAllPicks(){for(const e of[...this.tapOwners.values()])this.releasePick(e)}ensurePick(e){if(this.tapHandlers.has(e.id))return;const t=this.getRendererContainer(e);if(t)try{t.interactive=!0}catch{}let n=e.getComponent(s.Event);n||(n=e.addComponent(this.createPickEvent(e)),this.pickEvents.add(e.id));const o=t=>this.onSelect(e,t);this.tapHandlers.set(e.id,o),this.tapOwners.set(e.id,e),n.on("tap",o)}createPickEvent(e){const t=this.resolvePickBounds(e);return t.width>0&&t.height>0?new s.Event({hitArea:{type:s.HIT_AREA_TYPE.Rect,style:{x:t.x,y:t.y,width:t.width,height:t.height}}}):new s.Event}resolvePickBounds(e){if(this.shouldPreferRenderedBounds(e)){const t=this.resolveOwnGraphicsLocalBounds(e);if(t)return t;const n=this.resolveContainerLocalBounds(e);if(n)return n}const{width:t,height:n}=e.transform.size;if(t>0&&n>0)return{x:0,y:0,width:t,height:n};const o=this.resolveContainerLocalBounds(e);return o||{x:0,y:0,width:1,height:1}}shouldPreferRenderedBounds(e){return null!=e.getComponent(o.Graphics)}resolveOwnGraphicsLocalBounds(e){const t=e.getComponent(o.Graphics);if(!t?.graphics)return null;try{const e=t.graphics.getLocalBounds();if(e.width>0&&e.height>0)return{x:e.x,y:e.y,width:e.width,height:e.height}}catch{}return null}resolveContainerLocalBounds(e){const t=this.getRendererContainer(e);if(!t)return null;const n=this.getOutlineContainerIfChildOf(e);let o=!1;n?.parent===t&&(t.removeChild(n),o=!0);try{const e=t.getLocalBounds();if(e.width>0&&e.height>0)return{x:e.x,y:e.y,width:e.width,height:e.height}}catch{}finally{o&&n&&t.addChild(n)}return null}getOutlineContainerIfChildOf(e){return this.outlineGo&&this.outlineGo.parent===e?this.getRendererContainer(this.outlineGo):null}getRendererContainer(e){const t=this.game.getSystem(n.RendererSystem);if(!t?.containerManager)return null;try{return t.containerManager.getContainer(e.id)}catch{return null}}releasePick(e){const t=this.tapHandlers.get(e.id);if(!t)return;const n=e.getComponent(s.Event);if(n?.off("tap",t),this.tapHandlers.delete(e.id),this.tapOwners.delete(e.id),this.pickEvents.has(e.id)){try{e.removeComponent(s.Event)}catch{}this.pickEvents.delete(e.id)}}postSetSuccess(e){const t={type:a,enabled:e};"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(t,this.postMessageOrigin),this.game.emit(a,{enabled:e})}postStateChanged(){const e={muted:this.isMuted},t={type:m,...e};"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(t,this.postMessageOrigin),this.game.emit(m,e)}attachMarkers(){this.detachAllMarkers();const e=[];for(const t of this.game.scene.transform.children)this.collectGameObjects(t.gameObject,e);const t=new Map;for(const n of e){if(this.isIgnoredPickGo(n))continue;const e=b(n);e&&(this.createMarker(n,e),t.set(e.componentName,(t.get(e.componentName)??0)+1))}const n=[...t.entries()].map(([e,t])=>({componentName:e,count:t}));this.postMarkerOverlaySuccess(!0,n),this.enabled&&(this.needsRescan=!0)}createMarker(e,n){if(this.markerGoByOwner.has(e.id))return;const s=this.resolvePickBounds(e),i=new t.GameObject(U+e.id,{size:{width:28,height:28},position:{x:s.x,y:s.y},origin:{x:0,y:0}}),r=i.addComponent(new o.Graphics);r?.graphics&&v(r.graphics,n,28),e.addChild(i),this.markerGoByOwner.set(e.id,i)}removeMarker(e){const t=this.markerGoByOwner.get(e);t&&(this.markerGoByOwner.delete(e),t.destroyed||t.destroy())}detachAllMarkers(){for(const e of[...this.markerGoByOwner.keys()])this.removeMarker(e);this.markerGoByOwner.clear()}postMarkerOverlaySuccess(e,t){const n={enabled:e,total:t.reduce((e,t)=>e+t.count,0),markers:t},o={type:g,...n};"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(o,this.postMessageOrigin),this.game.emit(g,n)}getSoundSystem(){const e=this.game.getSystem("SoundSystem");return e&&"object"==typeof e&&"muted"in e&&"boolean"==typeof e.muted?e:null}ensureOutline(){if(this.outlineGo)return;const e=new t.GameObject(H,{size:{width:1,height:1},position:{x:0,y:0},origin:{x:0,y:0}});e.addComponent(new o.Graphics),this.outlineGo=e}onSelect(e,t){if(!this.enabled)return;if(t?.stopPropagation?.(),this.ensureOutline(),!this.outlineGo)return;this.selected=e,this.outlineGo.parent&&this.outlineGo.remove(),e.addChild(this.outlineGo),this.invalidateOutlineBounds(),this.updateSelectionOutline();const n=L(e),o={type:d,snapshot:n,pointer:t?.data?.position??null};"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(o,this.postMessageOrigin)}findGameObjectById(e){const t=[];for(const e of this.game.scene.transform.children)this.collectGameObjects(e.gameObject,t);return t.find(t=>t.id===e)??null}findGameObjectBySource(e){const t=[];for(const e of this.game.scene.transform.children)this.collectGameObjects(e.gameObject,t);const n=e.file.trim(),o=(e.anchor??"").trim();if(!o)return null;for(const e of t){const t=B(e);if(!t||t.file!==n)continue;if((t.anchor??e.name)===o)return e}return null}resolveApplyTarget(e){if("number"==typeof e.gameObjectId){const t=this.findGameObjectById(e.gameObjectId);if(t)return t}const t=e.source?.file?.trim(),n=e.source?.anchor?.trim();return t&&n?this.findGameObjectBySource({file:t,anchor:n}):null}handleApplyProperty(e){const t=e.componentName,n=e.path,o="number"==typeof e.gameObjectId,s=Boolean(e.source?.file?.trim())&&Boolean(e.source?.anchor?.trim());if(!o&&!s||"string"!=typeof t||!Array.isArray(n)||0===n.length)return;const i=this.resolveApplyTarget(e);if(!i)return;I(i,t,n,e.value)&&this.selected?.id===i.id&&(this.invalidateOutlineBounds(),this.updateSelectionOutline(),this.postSnapshotUpdate(i))}postSnapshotUpdate(e){const t=L(e);"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage({type:d,snapshot:t,pointer:null,source:"property-applied"},this.postMessageOrigin)}clearSelectionAndNotify(e){const t=null!=this.selected;this.clearSelection(),t&&this.postGameObjectDeselected(e)}postGameObjectDeselected(e){const t=W(e);"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(t,this.postMessageOrigin),this.game.emit(t.type,{reason:e})}clearSelection(){this.selected=null,this.invalidateOutlineBounds(),this.outlineGo?.parent&&this.outlineGo.remove();const e=this.outlineGo?.getComponent(o.Graphics);e?.graphics&&e.graphics.clear()}updateSelectionOutline(){if(!this.enabled||!this.selected||!this.outlineGo)return;const e=this.outlineGo.getComponent(o.Graphics);if(!e?.graphics)return;const t=this.resolvePickBounds(this.selected);if(this.lastOutlineBounds&&this.pickBoundsEqual(this.lastOutlineBounds,t))return;this.lastOutlineBounds=t;const n=e.graphics;n.clear(),n.rect(t.x,t.y,t.width,t.height),n.stroke({width:4,color:5636010,alpha:1})}invalidateOutlineBounds(){this.lastOutlineBounds=null}pickBoundsEqual(e,t){const n=.01;return Math.abs(e.x-t.x)<n&&Math.abs(e.y-t.y)<n&&Math.abs(e.width-t.width)<n&&Math.abs(e.height-t.height)<n}};Y=e.__decorate([t.decorators.componentObserver({CombosDevelopmentToolTarget:[]})],Y);var K=Y;Object.assign(K,{packageName:"@combos-fun/plugin-development-tool",packageVersion:"0.0.47"}),exports.COMBOS_DEVELOPMENT_TOOL_APPLY_PROPERTY=u,exports.COMBOS_DEVELOPMENT_TOOL_CLEAR_SELECTION=l,exports.COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_DESELECTED=h,exports.COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_SELECTED=d,exports.COMBOS_DEVELOPMENT_TOOL_MARKER_OVERLAY_SUCCESS=g,exports.COMBOS_DEVELOPMENT_TOOL_PICK_MODE_SUCCESS=a,exports.COMBOS_DEVELOPMENT_TOOL_READY="combos-development-tool:ready",exports.COMBOS_DEVELOPMENT_TOOL_REFRESH=c,exports.COMBOS_DEVELOPMENT_TOOL_SET_MARKER_OVERLAY=f,exports.COMBOS_DEVELOPMENT_TOOL_SET_MUTED=p,exports.COMBOS_DEVELOPMENT_TOOL_SET_PICK_MODE=r,exports.COMBOS_DEVELOPMENT_TOOL_STATE_CHANGED=m,exports.CombosDevelopmentToolSystem=K,exports.CombosDevelopmentToolTarget=y,exports.DEFAULT_ALLOWED_MESSAGE_HOST_SUFFIXES=E,exports.MARKER_COMPONENTS=O,exports.MARKER_ICON_SIZE=28,exports.applyPropertyValue=A,exports.applyPropertyWithHooks=I,exports.buildGameObjectDeselectedPayload=W,exports.buildGameObjectSnapshot=L,exports.drawMarkerIcon=v,exports.isAllowedMessageOrigin=M,exports.isClearSelectionMessage=q,exports.mergeAllowedMessageOrigins=S,exports.readPropertyValue=function(e,t,n){const o=e.getComponent(t);if(!o||!n.length)return;let s=o;for(const e of n){if(null==s||"object"!=typeof s)return;s=s[e]}return s},exports.readSourceAnchor=B,exports.resolveMarkerDef=b,exports.shouldNotifyGameObjectDeselected=V;
1
+ "use strict";var e=require("tslib"),t=require("@combos-fun/engine"),n=require("@combos-fun/inspector-decorator");const o="combos-development-tool:set-pick-mode",r="combos-development-tool:pick-mode-success",i="combos-development-tool:refresh",s="combos-development-tool:gameobject-selected",a="combos-development-tool:clear-selection",c="combos-development-tool:gameobject-deselected",l="combos-development-tool:apply-property",d="combos-development-tool:set-marker-overlay",h="combos-development-tool:marker-overlay-success";class u extends t.Component{constructor(){super(...arguments),this.payload={}}static{this.componentName="CombosDevelopmentToolTarget"}init(e){this.payload=e?.payload?{...e.payload}:{}}}function p(e,t=1){return`rgba(${e>>16&255}, ${e>>8&255}, ${255&e}, ${t})`}class m{constructor(e){this.ctx=e}clear(){this.ctx.beginPath()}roundRect(e,t,n,o,r=0){const i=this.ctx;if("function"==typeof i.roundRect)return void i.roundRect(e,t,n,o,r);const s=Math.max(0,Math.min(r,Math.min(n,o)/2));i.moveTo(e+s,t),i.lineTo(e+n-s,t),i.quadraticCurveTo(e+n,t,e+n,t+s),i.lineTo(e+n,t+o-s),i.quadraticCurveTo(e+n,t+o,e+n-s,t+o),i.lineTo(e+s,t+o),i.quadraticCurveTo(e,t+o,e,t+o-s),i.lineTo(e,t+s),i.quadraticCurveTo(e,t,e+s,t),i.closePath()}rect(e,t,n,o){this.ctx.rect(e,t,n,o)}circle(e,t,n){this.ctx.moveTo(e+n,t),this.ctx.arc(e,t,n,0,2*Math.PI)}poly(e,t=!0){if(!(e.length<4)){this.ctx.moveTo(e[0],e[1]);for(let t=2;t<e.length;t+=2)this.ctx.lineTo(e[t],e[t+1]);t&&this.ctx.closePath()}}fill(e){this.ctx.fillStyle=p(e.color,e.alpha??1),this.ctx.fill(),this.ctx.beginPath()}stroke(e){this.ctx.strokeStyle=p(e.color,e.alpha??1),this.ctx.lineWidth=e.width,this.ctx.stroke(),this.ctx.beginPath()}}const f=[{componentName:"Sound",badgeColor:9133302,glyph:"speaker"}],y=28;function g(e,t=f){for(const n of t)if(e.getComponent(n.componentName))return n;return null}const b=16777215;function v(e,t,n=28){if(function(e,t,n){e.clear(),e.roundRect(0,0,n,n,.22*n),e.fill({color:t.badgeColor,alpha:.92}),e.roundRect(0,0,n,n,.22*n),e.stroke({width:Math.max(1,.05*n),color:16777215,alpha:.6})}(e,t,n),"speaker"===t.glyph)!function(e,t){e.poly([.28*t,.4*t,.42*t,.4*t,.55*t,.26*t,.55*t,.74*t,.42*t,.6*t,.28*t,.6*t]),e.fill({color:b,alpha:.96}),e.rect(.62*t,.44*t,.045*t,.12*t),e.fill({color:b,alpha:.96}),e.rect(.71*t,.39*t,.045*t,.22*t),e.fill({color:b,alpha:.96})}(e,n);else!function(e,t){e.circle(.5*t,.5*t,.18*t),e.fill({color:b,alpha:.96})}(e,n)}const w=["knoffice.tech","converge.ai"];function O(e,t){if(t.includes("*"))return!0;if(0===t.length)return!1;let n;try{n=new URL(e)}catch{return!1}const o=e.toLowerCase(),r=n.hostname.toLowerCase();for(const e of t){const t=e.trim();if(!t)continue;if(t.includes("://")){if(o===t.toLowerCase())return!0;continue}const n=t.toLowerCase().replace(/^\./,"");if(r===n||r.endsWith(`.${n}`))return!0}return!1}function x(e){if(!e?.length)return[...w];if(e.includes("*"))return["*"];const t=new Set,n=[];for(const o of[...w,...e]){const e=o.trim();e&&!t.has(e)&&(t.add(e),n.push(e))}return n}function M(){if("undefined"==typeof document)return null;const e=document.createElement("canvas");e.setAttribute("data-combos-development-tool-overlay","true"),e.style.position="fixed",e.style.left="0",e.style.top="0",e.style.width="0",e.style.height="0",e.style.margin="0",e.style.padding="0",e.style.border="0",e.style.background="transparent",e.style.pointerEvents="none",e.style.touchAction="none",e.style.userSelect="none",e.style.zIndex="2147483000",e.style.display="none";const t=e.getContext("2d");if(!t)return null;let n=!1,o=!1;return{canvas:e,ctx:t,sync:n=>{!function(e,t){const n=e.parentElement??document.body;t.parentElement!==n&&n.appendChild(t)}(n,e);const r=n.getBoundingClientRect();if(r.width<=0||r.height<=0)return e.style.display="none",null;e.style.display=o?"block":"none",e.style.left=`${r.left}px`,e.style.top=`${r.top}px`,e.style.width=`${r.width}px`,e.style.height=`${r.height}px`;const i="undefined"!=typeof window&&window.devicePixelRatio||1,s=Math.max(1,Math.round(r.width*i)),a=Math.max(1,Math.round(r.height*i));return e.width===s&&e.height===a||(e.width=s,e.height=a),t.setTransform(i,0,0,i,0,0),{width:r.width,height:r.height}},setPickEnabled(t){n=t,e.style.pointerEvents=n?"auto":"none",e.style.cursor=n?"crosshair":"default"},setVisible(t){o=t,e.style.display=t?"block":"none"},destroy(){e.remove()}}}function E(e){return!!e&&"object"==typeof e&&"string"==typeof e.file}function S(e){return"string"==typeof e?"string":"number"==typeof e?"number":"boolean"==typeof e?"boolean":null!==e&&"object"==typeof e?"object":"unsupported"}function k(e,t=0){if(null==e)return e;if("number"==typeof e||"string"==typeof e||"boolean"==typeof e)return e;if(!(t>6)){if(Array.isArray(e))return e.map(e=>k(e,t+1));if("object"==typeof e){const n={};for(const[o,r]of Object.entries(e)){if("function"==typeof r)continue;const e=k(r,t+1);void 0!==e&&(n[o]=e)}return n}}}function T(e){const t=e.constructor,o=function(e){const t=Reflect.getMetadata(n.IDE_PROPERTY_METADATA,e)||{};return Object.keys(t).map(e=>({key:e,...t[e]}))}(t);return o.length>0?o:function(e){const t=e.IDEProps;return!t||Array.isArray(t)||"object"!=typeof t?[]:Object.keys(t).map(e=>{const n=t[e]||{};return{key:e,type:"string"==typeof n.type?n.type:void 0,step:"number"==typeof n.step?n.step:void 0,min:"number"==typeof n.min?n.min:void 0,max:"number"==typeof n.max?n.max:void 0,label:"string"==typeof n.label?n.label:void 0,description:"string"==typeof n.description?n.description:void 0,group:"string"==typeof n.group?n.group:void 0,editor:n.editor,enumOptions:Array.isArray(n.enumOptions)?n.enumOptions:void 0,unit:"string"==typeof n.unit?n.unit:void 0}})}(t)}function C(e,t){return e.editor?e.editor:"boolean"===t?"toggle":e.enumOptions?.length&&"string"===t?"enum":"number"===t?void 0!==e.min&&void 0!==e.max?"number-slider":"number-stepper":"string"===t?"text":void 0}function P(e){if(void 0!==e.min||void 0!==e.max||void 0!==e.step||void 0!==e.unit)return{min:e.min,max:e.max,step:e.step,unit:e.unit}}function _(e,t){if(e.label?.trim())return e.label.trim();const n=t[t.length-1];return n?function(e){return e.replace(/([a-z0-9])([A-Z])/g,"$1 $2").replace(/_/g," ").replace(/^./,e=>e.toUpperCase())}(n):void 0}function R(e,t,n,o){const r=t.description?.trim();if(!r)return[];const i=S(o);if("unsupported"===i)return[];const s=t.type,a="size"===s||"object"===i&&null!==o&&"width"in o&&"height"in o;if("vector2"===s||"object"===i&&null!==o&&"x"in o&&"y"in o||a){const i=o,s=a?["width","height"]:["x","y"],c=_(t,n)??e,l=[];for(const o of s){const s=i[o],a=S(s);if("unsupported"===a||"object"===a)continue;const d=[...n,o];l.push({path:d,value:s,valueType:a,label:`${c} ${o.toUpperCase()}`,description:r,group:t.group??e,editorKind:C(t,a),numberMeta:P(t),persistTarget:"Transform"===e?"gameObjectConstructor":"component"})}return l}if("object"===i)return[];const c=_(t,n);return c?[{path:n,value:k(o),valueType:i,label:c,description:r,group:t.group??e,editorKind:C(t,i),enumOptions:t.enumOptions,numberMeta:P(t),persistTarget:"Transform"===e?"gameObjectConstructor":"component"}]:[]}function D(e){const t=e.name,n=T(e);if(0===n.length)return[];const o=[],r=e;for(const e of n){const n=r[e.key];"function"!=typeof n&&o.push(...R(t,e,[e.key],n))}return o}function j(e){const t=e.getComponent(u),n=t?.payload?.source;if(E(n))return{file:n.file,anchor:n.anchor??e.name}}function L(e){const t=e.components.filter(e=>"CombosDevelopmentToolTarget"!==e.name).map(e=>({componentName:e.name,fieldDescriptors:D(e)})).filter(e=>e.fieldDescriptors.length>0);return{id:e.id,name:e.name,components:t,source:j(e)}}function N(e,t,n,o){const r=e.getComponent(t);if(!r||!n.length)return!1;let i=r;for(let e=0;e<n.length-1;e++){const t=n[e];void 0!==i[t]&&null!==i[t]||(i[t]={}),i=i[t]}return i[n[n.length-1]]=o,!0}const A=new Set(["position","size","origin","anchor","scale","skew"]);function G(e){if("number"==typeof e&&Number.isFinite(e))return e;if("string"==typeof e&&""!==e.trim()){const t=Number(e);return Number.isFinite(t)?t:void 0}}const B={Transform:function(e,t,n,o){const r=e.transform,i=r;if(1===n.length&&"rotation"===n[0]){const e=G(o);return void 0!==e&&(r.rotation=e,!0)}if(2===n.length&&A.has(n[0])){const t=n[0],r=n[1],s=G(o);if(void 0===s)return!1;const a=i[t];return!(!a||"object"!=typeof a)&&(a[r]=s,"position"===t&&(function(e){const t=e.getComponent("Physics");if(!t?.body)return;const{x:n,y:o}=e.transform.position;t.Body?.setPosition?t.Body.setPosition(t.body,{x:n,y:o}):(t.body.position.x=n,t.body.position.y=o)}(e),function(e){const t=e.getComponent("PlatformerMover");t&&(t.originX=e.transform.position.x,t.originY=e.transform.position.y)}(e)),!0)}return!1},Text:function(e,t,n,o){const r=t;if(1===n.length&&"text"===n[0])return r.text=String(o??""),!0;if(2===n.length&&"style"===n[0]){const e=n[1],t={...r.style??{},[e]:o};return r.style=t,!0}return!1},Sound:function(e,t,n,o){const r=t;if(1===n.length&&"volume"===n[0]||2===n.length&&"config"===n[0]&&"volume"===n[1]){const e=G(o);return void 0!==e&&(r.volume=e,!0)}return!1}};function I(e,t,n,o){const r=e.getComponent(t);if(!r||!n.length)return!1;const i=B[t];return!!i?.(e,r,n,o)||N(e,t,n,o)}function W(e){return{type:c,reason:e}}function V(e){return e}function F(e){return!(!e||"object"!=typeof e)&&e.type===a}function U(e,t){return{a:e.a*t.a+e.c*t.b,b:e.b*t.a+e.d*t.b,c:e.a*t.c+e.c*t.d,d:e.b*t.c+e.d*t.d,tx:e.a*t.tx+e.c*t.ty+e.tx,ty:e.b*t.tx+e.d*t.ty+e.ty}}function Y(e){const t=e.position.x+(e.parent?e.parent.size.width*e.anchor.x:0),n=e.position.y+(e.parent?e.parent.size.height*e.anchor.y:0),o=e.size.width*e.origin.x,r=e.size.height*e.origin.y,i=Math.cos(e.rotation),s=Math.sin(e.rotation),a=i*e.scale.x,c=s*e.scale.x,l=-s*e.scale.y,d=i*e.scale.y;return{a:a,b:c,c:l,d:d,tx:t-(o*a+r*l),ty:n-(o*c+r*d)}}function $(e){if(0===e.length)return null;let t=1/0,n=1/0,o=-1/0,r=-1/0;for(const i of e)Number.isFinite(i.x)&&Number.isFinite(i.y)&&(t=Math.min(t,i.x),n=Math.min(n,i.y),o=Math.max(o,i.x),r=Math.max(r,i.y));return Number.isFinite(t)&&Number.isFinite(n)?{x:t,y:n,width:o-t,height:r-n}:null}function q(e){return"number"==typeof e&&Number.isFinite(e)&&e>0?e:null}function z(e){const t=e?.getSystem?.("Renderer"),n=t?.application?.screen,o=q(n?.width),r=q(n?.height);if(o&&r)return{width:o,height:r};const i=q(t?.params?.width),s=q(t?.params?.height);return i&&s?{width:i,height:s}:null}function K(e){const t=e?.getSystem?.("Renderer3DSystem");return t?.threeContext?.camera??null}function X(e,t){const n=e?.getSystem?.("Renderer3DSystem");return n?.threeContext?.nodes?.get?.(t)??null}function Z(e,t,n,o,r){return[e[0]*t+e[4]*n+e[8]*o+e[12]*r,e[1]*t+e[5]*n+e[9]*o+e[13]*r,e[2]*t+e[6]*n+e[10]*o+e[14]*r,e[3]*t+e[7]*n+e[11]*o+e[15]*r]}function H(e,t,n,o,r){const i=o.matrixWorldInverse?.elements,s=o.projectionMatrix?.elements;if(!i||i.length<16||!s||s.length<16)return null;if(r.width<=0||r.height<=0)return null;const a=Z(i,e,t,n,1),c=Z(s,a[0],a[1],a[2],a[3]);if(!Number.isFinite(c[3])||Math.abs(c[3])<1e-8)return null;if(c[3]<0)return null;const l=c[0]/c[3],d=c[1]/c[3],h=c[2]/c[3];return{x:.5*(l+1)*r.width,y:.5*(1-d)*r.height,depth:h}}function J(e,t,n,o){const r=e[3]*t+e[7]*n+e[11]*o+e[15],i=Math.abs(r)<1e-8?1:1/r;return[(e[0]*t+e[4]*n+e[8]*o+e[12])*i,(e[1]*t+e[5]*n+e[9]*o+e[13])*i,(e[2]*t+e[6]*n+e[10]*o+e[14])*i]}function Q(e,t){const n=Math.max(1,t);return{x:e.x-n/2,y:e.y-n/2,width:n,height:n}}function ee(e,t,n){const o=function(e){const t=[];let n=e;for(;n;)t.push(n),n=n.parent;t.reverse();let o={a:1,b:0,c:0,d:1,tx:0,ty:0};for(const e of t)o=U(o,Y(e));return o}(e),r=e.size.width,i=e.size.height,s=(r>0&&i>0?[{x:0,y:0},{x:r,y:0},{x:r,y:i},{x:0,y:i}]:[{x:0,y:0}]).map(e=>{return t=o,n=e.x,r=e.y,{x:t.a*n+t.c*r+t.tx,y:t.b*n+t.d*r+t.ty};var t,n,r}).map(e=>function(e,t,n){return!t||t.width<=0||t.height<=0?{x:e.x,y:e.y}:{x:e.x*(n.width/t.width),y:e.y*(n.height/t.height)}}(e,n,t)),a=$(s);if(a&&a.width>0&&a.height>0)return a;return Q(s[0]??{x:0,y:0},1)}function te(e,t,n,o){if(o){const e=function(e){const t=[],n=e=>{const n=e.geometry;if(!n)return;n.computeBoundingBox?.();const o=n.boundingBox,r=e.matrixWorld?.elements;if(!o||!r||r.length<16)return;const{min:i,max:s}=o;for(const e of[i.x,s.x])for(const n of[i.y,s.y])for(const o of[i.z,s.z])t.push(J(r,e,n,o))};return e.updateWorldMatrix?.(!0,!0),"function"==typeof e.traverse?e.traverse(n):n(e),t}(o),r=e.map(([e,o,r])=>H(e,o,r,t,n)).filter(e=>null!=e),i=$(r);if(i&&i.width>0&&i.height>0)return i}const r=H(e.worldPositionX??e.positionX??0,e.worldPositionY??e.positionY??0,e.worldPositionZ??e.positionZ??0,t,n);if(!r)return null;return Q(r,32*Math.max(Math.abs(e.scaleX??1),Math.abs(e.scaleY??1),Math.abs(e.scaleZ??1),1))}function ne(e,t){if(t.css.width<=0||t.css.height<=0)return null;const n=function(e){if(!e||"object"!=typeof e)return null;const t=e,n=[t.worldPositionX,t.worldPositionY,t.worldPositionZ].some(e=>"number"==typeof e&&Number.isFinite(e)),o=[t.positionX,t.positionY,t.positionZ].some(e=>"number"==typeof e&&Number.isFinite(e));return n||o?t:null}(e.getComponent("Transform3D"));return n&&t.camera?te(n,t.camera,t.css,t.object3D):ee(e.transform,t.css,t.design??null)}function oe(e,t,n){return t>=e.x&&n>=e.y&&t<=e.x+e.width&&n<=e.y+e.height}let re=class extends t.System{constructor(){super(...arguments),this.postMessageOrigin="*",this.allowedMessageOrigins=x(),this.enabled=!1,this.selected=null,this.overlay=null,this.overlayCss={width:0,height:0},this.pointerDownGoId=null,this.needsRescan=!1,this.mutedWithoutSoundSystem=!1,this.markerOverlayEnabled=!1,this.needsMarkerRescan=!1,this.markerOwners=new Set,this.onWindowSetPickMode=e=>{const t=e.detail;t&&"boolean"==typeof t.enabled&&this.setEnabled(t.enabled)},this.onWindowSetMarkerOverlay=e=>{const t=e.detail;t&&"boolean"==typeof t.enabled&&this.setMarkerOverlay(t.enabled)},this.onGameSetMarkerOverlay=e=>{e&&"boolean"==typeof e.enabled&&this.setMarkerOverlay(e.enabled)},this.onWindowMessage=e=>{if(!O(e.origin,this.allowedMessageOrigins))return;const t=e.data;t&&"object"==typeof t&&(t.type===o&&"boolean"==typeof t.enabled?this.setEnabled(t.enabled):t.type===d&&"boolean"==typeof t.enabled?this.setMarkerOverlay(t.enabled):t.type===i?this.requestSceneRescan():F(t)?this.clearSelectionAndNotify("parent-request"):t.type===l&&this.handleApplyProperty(t))},this.onGameSetPickMode=e=>{e&&"boolean"==typeof e.enabled&&this.setEnabled(e.enabled)},this.onGameRefresh=()=>{this.requestSceneRescan()},this.onWindowRefresh=()=>{this.requestSceneRescan()},this.onPointerDown=e=>{if(!this.enabled)return;e.preventDefault(),e.stopPropagation();try{this.overlay?.canvas.setPointerCapture(e.pointerId)}catch{}const t=this.hitTestPointer(e);this.pointerDownGoId=t?.id??null},this.onPointerUp=e=>{if(!this.enabled)return;e.preventDefault(),e.stopPropagation();const t=this.hitTestPointer(e);t&&t.id===this.pointerDownGoId&&this.onSelect(t,e),this.pointerDownGoId=null}}static{this.systemName="CombosDevelopmentToolSystem"}init(e){this.postMessageOrigin=e?.postMessageOrigin??"*",this.allowedMessageOrigins=x(e?.allowedMessageOrigins),this.overlay=M(),this.overlay&&(this.overlay.canvas.addEventListener("pointerdown",this.onPointerDown),this.overlay.canvas.addEventListener("pointerup",this.onPointerUp)),"undefined"!=typeof window&&(window.addEventListener(o,this.onWindowSetPickMode),window.addEventListener(d,this.onWindowSetMarkerOverlay),window.addEventListener(i,this.onWindowRefresh),window.addEventListener("message",this.onWindowMessage)),this.game.on(o,this.onGameSetPickMode),this.game.on(d,this.onGameSetMarkerOverlay),this.game.on(i,this.onGameRefresh),this.syncOverlayMode(),this.enabled&&(this.needsRescan=!0)}onDestroy(){this.overlay&&(this.overlay.canvas.removeEventListener("pointerdown",this.onPointerDown),this.overlay.canvas.removeEventListener("pointerup",this.onPointerUp),this.overlay.destroy(),this.overlay=null),"undefined"!=typeof window&&(window.removeEventListener(o,this.onWindowSetPickMode),window.removeEventListener(d,this.onWindowSetMarkerOverlay),window.removeEventListener(i,this.onWindowRefresh),window.removeEventListener("message",this.onWindowMessage)),this.game.off(o,this.onGameSetPickMode),this.game.off(d,this.onGameSetMarkerOverlay),this.game.off(i,this.onGameRefresh),this.markerOwners.clear(),this.clearSelectionAndNotify("pick-disabled")}setEnabled(e){this.enabled!==e&&(this.enabled=e,this.syncOverlayMode(),e?(this.needsRescan=!0,this.redrawOverlay()):(this.clearSelectionAndNotify("pick-disabled"),this.postSetSuccess(!1)))}get isEnabled(){return this.enabled}setMarkerOverlay(e){this.markerOverlayEnabled!==e&&(this.markerOverlayEnabled=e,this.syncOverlayMode(),e?this.needsMarkerRescan=!0:(this.markerOwners.clear(),this.postMarkerOverlaySuccess(!1,[]),this.redrawOverlay()))}get isMarkerOverlayEnabled(){return this.markerOverlayEnabled}get isMuted(){const e=this.getSoundSystem();return e?e.muted:this.mutedWithoutSoundSystem}setMuted(e){const t=this.getSoundSystem();t?t.muted=e:this.mutedWithoutSoundSystem=e}update(){this.enabled&&this.needsRescan&&(this.needsRescan=!1,this.postSetSuccess(!0)),this.markerOverlayEnabled&&this.needsMarkerRescan&&(this.needsMarkerRescan=!1,this.attachMarkers()),this.selected?.destroyed&&this.clearSelectionAndNotify("target-removed")}lateUpdate(e){this.redrawOverlay()}componentChanged(e){const{type:n,gameObject:o,componentName:r}=e;o&&"CombosDevelopmentToolTarget"===r&&(n===t.OBSERVER_TYPE.REMOVE&&this.selected===o&&this.clearSelectionAndNotify("target-removed"),this.markerOverlayEnabled&&(this.needsMarkerRescan=!0))}requestSceneRescan(){this.enabled&&(this.needsRescan=!0),this.markerOverlayEnabled&&(this.needsMarkerRescan=!0)}syncOverlayMode(){const e=this.enabled||this.markerOverlayEnabled;this.overlay?.setVisible(e),this.overlay?.setPickEnabled(this.enabled)}collectGameObjects(e,t){t.push(e);for(const n of e.transform.children)this.collectGameObjects(n.gameObject,t)}listSceneObjects(){const e=[],t=this.game.scene;if(!t?.transform?.children)return e;for(const n of t.transform.children)this.collectGameObjects(n.gameObject,e);return e}isIgnoredPickGo(e){return"__combosDevelopmentToolOutline"===e.name||this.isMarkerGo(e)}isMarkerGo(e){return"string"==typeof e.name&&e.name.startsWith("__combosDevelopmentToolMarker:")}projectGo(e){return ne(e,{css:this.overlayCss,design:z(this.game),camera:K(this.game),object3D:X(this.game,e.id)})}collectOverlayHits(){const e=[];for(const t of this.listSceneObjects()){if(t.destroyed||this.isIgnoredPickGo(t))continue;if(!t.getComponent(u))continue;const n=this.projectGo(t);if(n&&e.push({go:t,rect:n}),this.markerOverlayEnabled&&g(t)){const o=this.markerRectFor(t,n);o&&e.push({go:t,rect:o})}}return e}markerRectFor(e,t){const n=t??this.projectGo(e);return n?e.getComponent("Transform3D")?{x:n.x+n.width/2-14,y:n.y+n.height/2-14,width:y,height:y}:{x:n.x,y:n.y,width:y,height:y}:null}overlayPoint(e){const t=this.overlay?.canvas;if(!t)return{x:0,y:0};const n=t.getBoundingClientRect();return{x:e.clientX-n.left,y:e.clientY-n.top}}hitTestPointer(e){const t=this.overlayPoint(e),n=this.collectOverlayHits();return function(e,t,n){let o=null;for(let r=0;r<n.length;r++){const i=n[r];if(!oe(i.rect,e,t))continue;const s=Math.max(i.rect.width,0)*Math.max(i.rect.height,0);(!o||s<o.area||s===o.area&&r>o.index)&&(o={id:i.id,area:s,index:r})}return o?o.id:null}(t.x,t.y,n.map(e=>({id:e.go,rect:e.rect})))}redrawOverlay(){const e=this.overlay;if(!e)return;if(!(this.enabled||this.markerOverlayEnabled))return void e.setVisible(!1);const t=this.game.canvas??this.game.scene?.canvas;if(!t)return;const n=e.sync(t);n&&(this.overlayCss=n,e.ctx.clearRect(0,0,n.width,n.height),this.drawMarkers(e.ctx),this.drawSelectionOutline(e.ctx))}drawMarkers(e){if(!this.markerOverlayEnabled)return;const t=new m(e);for(const n of this.listSceneObjects()){if(n.destroyed||this.isIgnoredPickGo(n))continue;const o=g(n);if(!o)continue;const r=this.projectGo(n),i=this.markerRectFor(n,r);i&&(e.save(),e.translate(i.x,i.y),v(t,o,y),e.restore())}}drawSelectionOutline(e){if(!this.enabled||!this.selected||this.selected.destroyed)return;const t=this.projectGo(this.selected);if(!t)return;const n=z(this.game),o=n?this.overlayCss.width/n.width:1;e.save(),e.strokeStyle="#55ffaa",e.lineWidth=Math.max(2,4*(Number.isFinite(o)&&o>0?o:1)),e.strokeRect(t.x,t.y,t.width,t.height),e.restore()}postSetSuccess(e){const t={type:r,enabled:e};"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(t,this.postMessageOrigin),this.game.emit(r,{enabled:e})}attachMarkers(){this.markerOwners.clear();const e=new Map;for(const t of this.listSceneObjects()){if(this.isIgnoredPickGo(t))continue;const n=g(t);n&&(this.markerOwners.add(t.id),e.set(n.componentName,(e.get(n.componentName)??0)+1))}const t=[...e.entries()].map(([e,t])=>({componentName:e,count:t}));this.postMarkerOverlaySuccess(!0,t),this.redrawOverlay()}postMarkerOverlaySuccess(e,t){const n={enabled:e,total:t.reduce((e,t)=>e+t.count,0),markers:t},o={type:h,...n};"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(o,this.postMessageOrigin),this.game.emit(h,n)}getSoundSystem(){const e=this.game.getSystem("SoundSystem");return e&&"object"==typeof e&&"muted"in e&&"boolean"==typeof e.muted?e:null}onSelect(e,t){if(!this.enabled)return;this.selected=e,this.redrawOverlay();const n=this.overlayPoint(t),o=(r=n,i=z(this.game),a=this.overlayCss,!i||i.width<=0||i.height<=0||a.width<=0||a.height<=0?{x:r.x,y:r.y}:{x:r.x*(i.width/a.width),y:r.y*(i.height/a.height)});var r,i,a;const c=L(e),l={type:s,snapshot:c,pointer:o};"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(l,this.postMessageOrigin)}findGameObjectById(e){return this.listSceneObjects().find(t=>t.id===e)??null}findGameObjectBySource(e){const t=e.file.trim(),n=(e.anchor??"").trim();if(!n)return null;for(const e of this.listSceneObjects()){const o=j(e);if(!o||o.file!==t)continue;if((o.anchor??e.name)===n)return e}return null}resolveApplyTarget(e){if("number"==typeof e.gameObjectId){const t=this.findGameObjectById(e.gameObjectId);if(t)return t}const t=e.source?.file?.trim(),n=e.source?.anchor?.trim();return t&&n?this.findGameObjectBySource({file:t,anchor:n}):null}handleApplyProperty(e){const t=e.componentName,n=e.path,o="number"==typeof e.gameObjectId,r=Boolean(e.source?.file?.trim())&&Boolean(e.source?.anchor?.trim());if(!o&&!r||"string"!=typeof t||!Array.isArray(n)||0===n.length)return;const i=this.resolveApplyTarget(e);if(!i)return;I(i,t,n,e.value)&&this.selected?.id===i.id&&(this.redrawOverlay(),this.postSnapshotUpdate(i))}postSnapshotUpdate(e){const t=L(e);"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage({type:s,snapshot:t,pointer:null,source:"property-applied"},this.postMessageOrigin)}clearSelectionAndNotify(e){const t=null!=this.selected;this.selected=null,this.redrawOverlay(),t&&this.postGameObjectDeselected(e)}postGameObjectDeselected(e){const t=W(e);"undefined"!=typeof window&&window.parent&&window.parent!==window&&window.parent.postMessage(t,this.postMessageOrigin),this.game.emit(t.type,{reason:e})}};re=e.__decorate([t.decorators.componentObserver({CombosDevelopmentToolTarget:[]})],re);var ie=re;Object.assign(ie,{packageName:"@combos-fun/plugin-development-tool",packageVersion:"0.0.49"}),exports.COMBOS_DEVELOPMENT_TOOL_APPLY_PROPERTY=l,exports.COMBOS_DEVELOPMENT_TOOL_CLEAR_SELECTION=a,exports.COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_DESELECTED=c,exports.COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_SELECTED=s,exports.COMBOS_DEVELOPMENT_TOOL_MARKER_OVERLAY_SUCCESS=h,exports.COMBOS_DEVELOPMENT_TOOL_PICK_MODE_SUCCESS=r,exports.COMBOS_DEVELOPMENT_TOOL_READY="combos-development-tool:ready",exports.COMBOS_DEVELOPMENT_TOOL_REFRESH=i,exports.COMBOS_DEVELOPMENT_TOOL_SET_MARKER_OVERLAY=d,exports.COMBOS_DEVELOPMENT_TOOL_SET_MUTED="combos-development-tool:set-muted",exports.COMBOS_DEVELOPMENT_TOOL_SET_PICK_MODE=o,exports.COMBOS_DEVELOPMENT_TOOL_STATE_CHANGED="combos-development-tool:state-changed",exports.CombosDevelopmentToolSystem=ie,exports.CombosDevelopmentToolTarget=u,exports.DEFAULT_ALLOWED_MESSAGE_HOST_SUFFIXES=w,exports.MARKER_COMPONENTS=f,exports.MARKER_ICON_SIZE=y,exports.applyPropertyValue=N,exports.applyPropertyWithHooks=I,exports.attachDevelopmentTarget=function(e,t){if(!e||e.destroyed||function(e){return"string"==typeof e.name&&e.name.startsWith("__")}(e)||function(e){return Array.isArray(e.gameObjects)}(e))return e;const n=t.file.trim(),o=t.anchor.trim();if(!n||!o)return e;const r=e.getComponent(u);return r?(i=r.payload?.source,E(i)&&Boolean(i.file.trim())&&Boolean((i.anchor??"").trim())||(r.payload={...r.payload??{},source:{file:n,anchor:o}}),e):(e.addComponent(new u({payload:{source:{file:n,anchor:o}}})),e);var i},exports.buildGameObjectDeselectedPayload=W,exports.buildGameObjectSnapshot=L,exports.drawMarkerIcon=v,exports.isAllowedMessageOrigin=O,exports.isClearSelectionMessage=F,exports.mergeAllowedMessageOrigins=x,exports.readPropertyValue=function(e,t,n){const o=e.getComponent(t);if(!o||!n.length)return;let r=o;for(const e of n){if(null==r||"object"!=typeof r)return;r=r[e]}return r},exports.readSourceAnchor=j,exports.resolveMarkerDef=g,exports.shouldNotifyGameObjectDeselected=V;
@@ -17,10 +17,8 @@ declare const COMBOS_DEVELOPMENT_TOOL_APPLY_PROPERTY: "combos-development-tool:a
17
17
  /** iframe → parent: game scene bootstrap finished; parent may enable pick mode. */
18
18
  declare const COMBOS_DEVELOPMENT_TOOL_READY: "combos-development-tool:ready";
19
19
  /**
20
- * Parent → iframe: mute or unmute audio when `SoundSystem` is registered. Payload: `{ muted: boolean }`.
21
- *
22
- * Note: play / pause / resume are owned by the engine core lifecycle protocol
23
- * (`combos-game:set-playing` / `combos-game:state-changed`), not this tool.
20
+ * Parent → iframe: mute or unmute. Handled by `@combos-fun/plugin-sound`.
21
+ * Payload: `{ muted: boolean }`.
24
22
  */
25
23
  declare const COMBOS_DEVELOPMENT_TOOL_SET_MUTED: "combos-development-tool:set-muted";
26
24
  /** iframe → parent (and `game.emit`): current mute snapshot after a successful change. */
@@ -62,7 +60,7 @@ interface MarkerComponentDef {
62
60
  * to reuse the same layer) but only audio is wanted right now.
63
61
  */
64
62
  declare const MARKER_COMPONENTS: readonly MarkerComponentDef[];
65
- /** Fixed badge size in the owner's local space. */
63
+ /** Fixed badge size in overlay CSS pixels. */
66
64
  declare const MARKER_ICON_SIZE = 28;
67
65
  /**
68
66
  * First registered marker def whose component is present on `go`, else `null`.
@@ -89,7 +87,7 @@ interface MarkerGraphicsLike {
89
87
  alpha?: number;
90
88
  }): unknown;
91
89
  }
92
- /** Render a full marker (badge + glyph) into `g`, sized to `size` (local units). */
90
+ /** Render a full marker (badge + glyph) into `g`, sized to `size` (overlay CSS pixels). */
93
91
  declare function drawMarkerIcon(g: MarkerGraphicsLike, def: MarkerComponentDef, size?: number): void;
94
92
 
95
93
  /** Default inbound postMessage host suffixes (host + all subdomains). */
@@ -112,8 +110,7 @@ interface CombosDevelopmentToolTargetParams extends ComponentParams {
112
110
  }
113
111
  /**
114
112
  * Marks a `GameObject` as selectable in editor pick mode. While the development tool is enabled,
115
- * only nodes carrying this component receive a pick `Event`; all other game `Event` components
116
- * are removed and cached until disable.
113
+ * only nodes carrying this component are hit-tested on the canvas overlay.
117
114
  */
118
115
  declare class CombosDevelopmentToolTarget extends Component<CombosDevelopmentToolTargetParams> {
119
116
  static componentName: string;
@@ -132,64 +129,56 @@ interface CombosDevelopmentToolSystemParams {
132
129
  }
133
130
  /**
134
131
  * **Off** at start. While enabled:
135
- * - soft-disables game `Event` hit targets (`container.interactive = false`, restored on disable);
136
- * - attaches pick `Event` + outline only on nodes with {@link CombosDevelopmentToolTarget}.
132
+ * - a transparent HTML canvas overlay captures pointer events (game Event / Event3D
133
+ * do not receive the tap);
134
+ * - only nodes with {@link CombosDevelopmentToolTarget} are pickable;
135
+ * - selection outline and markers are drawn with the Canvas 2D API (no renderer plugin).
137
136
  *
138
137
  * Turn on/off via:
139
138
  * - `window.dispatchEvent(new CustomEvent(COMBOS_DEVELOPMENT_TOOL_SET_PICK_MODE, { detail: { enabled: true } }))`
140
139
  * - `window.postMessage({ type: COMBOS_DEVELOPMENT_TOOL_SET_PICK_MODE, enabled: true }, targetOrigin)` (e.g. from parent iframe)
141
140
  * - `game.emit(COMBOS_DEVELOPMENT_TOOL_SET_PICK_MODE, { enabled: true })` or `getSystem(CombosDevelopmentToolSystem).setEnabled(true)`
142
141
  *
143
- * Mute (independent of pick mode; parent toolbar or in-game debug UI):
144
- * - `postMessage({ type: COMBOS_DEVELOPMENT_TOOL_SET_MUTED, muted: true })`
145
- * - `game.emit(COMBOS_DEVELOPMENT_TOOL_SET_MUTED, { muted: true })` or `.setMuted(true)`
146
- * Mute applies when `SoundSystem` is registered; otherwise the desired value is remembered until it appears.
147
- * Emits / posts `COMBOS_DEVELOPMENT_TOOL_STATE_CHANGED` with `{ muted }`.
142
+ * Mute is owned by `@combos-fun/plugin-sound` (`combos-development-tool:set-muted` /
143
+ * `SoundSystem.setMuted`). This system still forwards `.setMuted()` to
144
+ * `SoundSystem` so older in-game callers keep working.
148
145
  *
149
146
  * Play / pause / resume are handled by the engine core lifecycle protocol
150
147
  * (`combos-game:set-playing` / `combos-game:state-changed`), not this tool.
151
148
  *
152
149
  * While enabled: `game.emit(COMBOS_DEVELOPMENT_TOOL_REFRESH)`, `window` event `combos-development-tool:refresh`,
153
- * or `postMessage({ type: 'combos-development-tool:refresh' })` to re-bind after adding/removing objects.
150
+ * or `postMessage({ type: 'combos-development-tool:refresh' })` after adding/removing objects.
154
151
  */
155
152
  declare class CombosDevelopmentToolSystem extends System<CombosDevelopmentToolSystemParams> {
156
153
  static systemName: string;
157
154
  private postMessageOrigin;
158
155
  private allowedMessageOrigins;
159
156
  private enabled;
160
- private outlineGo;
161
157
  private selected;
162
- private readonly tapHandlers;
163
- private readonly tapOwners;
164
- /** Game `Event` hit targets soft-disabled while enabled (`container.interactive = false`). */
165
- private readonly disabledGameEventGoIds;
166
- /** Pick `Event` injected for {@link CombosDevelopmentToolTarget} nodes. */
167
- private readonly pickEvents;
158
+ private overlay;
159
+ private overlayCss;
160
+ private pointerDownGoId;
168
161
  private needsRescan;
169
- private lastOutlineBounds;
170
162
  /** Remembered mute when `SoundSystem` is not registered yet. */
171
163
  private mutedWithoutSoundSystem;
172
164
  /**
173
165
  * Marker overlay (see {@link markerLayer}): a visual-only icon layer, toggled
174
- * independently of pick mode + mute. Selection/persistence are NOT handled here
175
- * a marked object (e.g. Sound) carries its own `CombosDevelopmentToolTarget`
176
- * (added by the game code), so it is picked and serialized through the normal
177
- * Target path. The icon just makes the invisible object visible and, by adding
178
- * to the owner's rendered bounds, gives its Target pick a clickable hit area.
166
+ * independently of pick mode + mute. Selection/persistence still go through
167
+ * `CombosDevelopmentToolTarget` (added by the Vite plugin).
179
168
  */
180
169
  private markerOverlayEnabled;
181
170
  private needsMarkerRescan;
182
- /** ownerGoId → its marker GO (icon child, Graphics only). */
183
- private readonly markerGoByOwner;
171
+ /** ownerGoId → marker def currently shown. */
172
+ private readonly markerOwners;
184
173
  private readonly onWindowSetPickMode;
185
- private readonly onWindowSetMuted;
186
174
  private readonly onWindowSetMarkerOverlay;
187
175
  private readonly onGameSetMarkerOverlay;
188
176
  private readonly onWindowMessage;
189
177
  private readonly onGameSetPickMode;
190
178
  private readonly onGameRefresh;
191
- private readonly onGameSetMuted;
192
179
  private readonly onWindowRefresh;
180
+ private readonly onPointerDown;
181
+ private readonly onPointerUp;
193
182
  init(params?: CombosDevelopmentToolSystemParams): void;
194
183
  onDestroy(): void;
195
184
  /** Programmatic toggle (same effect as events). */
@@ -198,53 +187,40 @@ declare class CombosDevelopmentToolSystem extends System<CombosDevelopmentToolSy
198
187
  /**
199
188
  * Toggle the marker overlay: pin a persistent icon on every object that owns a
200
189
  * registered invisible component ({@link markerLayer}, Sound first). Independent
201
- * of pick mode / mute. This layer is purely visual the icon makes the object
202
- * visible and adds to its rendered bounds so the owner's own
203
- * `CombosDevelopmentToolTarget` pick gets a clickable hit area. Selecting and
204
- * persisting edits (e.g. volume) still go through that Target, exactly like any
205
- * other scene edit, so the object must carry a Target (added by the game code).
190
+ * of pick mode / mute. Selecting and persisting edits still go through the
191
+ * owner's `CombosDevelopmentToolTarget`.
206
192
  */
207
193
  setMarkerOverlay(on: boolean): void;
208
194
  get isMarkerOverlayEnabled(): boolean;
209
195
  /** Master mute when `SoundSystem` exists; otherwise the last requested value. */
210
196
  get isMuted(): boolean;
211
197
  /**
212
- * Mute or unmute audio via `SoundSystem` when registered.
213
- * No-op on the audio graph if `SoundSystem` is missing; value is remembered for `isMuted`.
198
+ * @deprecated Host mute is handled by `@combos-fun/plugin-sound`.
199
+ * Forwards to `SoundSystem.muted` when that system is registered.
214
200
  */
215
201
  setMuted(muted: boolean): void;
216
- update(e: UpdateParams): void;
202
+ update(): void;
203
+ lateUpdate(_e: UpdateParams): void;
217
204
  componentChanged(changed: ComponentChanged): void;
218
205
  /** Re-bind pick targets / markers after dynamic scene changes while active. */
219
206
  requestSceneRescan(): void;
220
- private attachEditMode;
207
+ private syncOverlayMode;
221
208
  private collectGameObjects;
209
+ private listSceneObjects;
222
210
  private isIgnoredPickGo;
223
211
  private isMarkerGo;
224
- private stripGameEvent;
225
- private restoreDisabledGameEvents;
226
- private detachAllPicks;
227
- private ensurePick;
228
- private createPickEvent;
229
- private resolvePickBounds;
230
- private shouldPreferRenderedBounds;
231
- /** Bounds of this GO's own Graphics only — excludes child GOs such as the selection outline. */
232
- private resolveOwnGraphicsLocalBounds;
233
- private resolveContainerLocalBounds;
234
- /** Outline is parented under the selected GO; exclude it when measuring content bounds. */
235
- private getOutlineContainerIfChildOf;
236
- private getRendererContainer;
237
- private releasePick;
212
+ private projectGo;
213
+ private collectOverlayHits;
214
+ private markerRectFor;
215
+ private overlayPoint;
216
+ private hitTestPointer;
217
+ private redrawOverlay;
218
+ private drawMarkers;
219
+ private drawSelectionOutline;
238
220
  private postSetSuccess;
239
- private postStateChanged;
240
- /** (Re)build markers for every object owning a registered marker component. */
241
221
  private attachMarkers;
242
- private createMarker;
243
- private removeMarker;
244
- private detachAllMarkers;
245
222
  private postMarkerOverlaySuccess;
246
223
  private getSoundSystem;
247
- private ensureOutline;
248
224
  private onSelect;
249
225
  private findGameObjectById;
250
226
  private findGameObjectBySource;
@@ -253,13 +229,21 @@ declare class CombosDevelopmentToolSystem extends System<CombosDevelopmentToolSy
253
229
  private postSnapshotUpdate;
254
230
  private clearSelectionAndNotify;
255
231
  private postGameObjectDeselected;
256
- private clearSelection;
257
- /** Redraw the green outline only when content bounds change (movement follows via child transform). */
258
- private updateSelectionOutline;
259
- private invalidateOutlineBounds;
260
- private pickBoundsEqual;
261
232
  }
262
233
 
234
+ interface DevelopmentTargetSource {
235
+ file: string;
236
+ anchor: string;
237
+ }
238
+ /**
239
+ * Marks `go` for editor pick / persist. Idempotent: existing Targets keep a
240
+ * complete `payload.source`; missing identity is filled from `source`.
241
+ *
242
+ * Inserted by `@combos-fun/plugin-development-tool/vite`. Game code should
243
+ * not call this by hand.
244
+ */
245
+ declare function attachDevelopmentTarget<T extends GameObject>(go: T, source: DevelopmentTargetSource): T;
246
+
263
247
  /** Optional bootstrap anchor stored on {@link CombosDevelopmentToolTarget}.payload.source */
264
248
  interface SceneSourceAnchor {
265
249
  /** Project-relative path, e.g. `src/index.ts` */
@@ -325,5 +309,5 @@ declare function buildGameObjectDeselectedPayload(reason: DevelopmentToolDeselec
325
309
  declare function shouldNotifyGameObjectDeselected(hadSelection: boolean): boolean;
326
310
  declare function isClearSelectionMessage(data: unknown): boolean;
327
311
 
328
- export { COMBOS_DEVELOPMENT_TOOL_APPLY_PROPERTY, COMBOS_DEVELOPMENT_TOOL_CLEAR_SELECTION, COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_DESELECTED, COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_SELECTED, COMBOS_DEVELOPMENT_TOOL_MARKER_OVERLAY_SUCCESS, COMBOS_DEVELOPMENT_TOOL_PICK_MODE_SUCCESS, COMBOS_DEVELOPMENT_TOOL_READY, COMBOS_DEVELOPMENT_TOOL_REFRESH, COMBOS_DEVELOPMENT_TOOL_SET_MARKER_OVERLAY, COMBOS_DEVELOPMENT_TOOL_SET_MUTED, COMBOS_DEVELOPMENT_TOOL_SET_PICK_MODE, COMBOS_DEVELOPMENT_TOOL_STATE_CHANGED, CombosDevelopmentToolSystem, CombosDevelopmentToolTarget, DEFAULT_ALLOWED_MESSAGE_HOST_SUFFIXES, MARKER_COMPONENTS, MARKER_ICON_SIZE, applyPropertyValue, applyPropertyWithHooks, buildGameObjectDeselectedPayload, buildGameObjectSnapshot, drawMarkerIcon, isAllowedMessageOrigin, isClearSelectionMessage, mergeAllowedMessageOrigins, readPropertyValue, readSourceAnchor, resolveMarkerDef, shouldNotifyGameObjectDeselected };
329
- export type { CombosDevelopmentToolSystemParams, CombosDevelopmentToolTargetParams, DevelopmentToolDeselectReason, MarkerComponentDef, MarkerGlyph, MarkerGraphicsLike, SceneEditComponentSnapshot, SceneEditGameObjectSnapshot, SceneEditPropertyRef, SceneSourceAnchor };
312
+ export { COMBOS_DEVELOPMENT_TOOL_APPLY_PROPERTY, COMBOS_DEVELOPMENT_TOOL_CLEAR_SELECTION, COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_DESELECTED, COMBOS_DEVELOPMENT_TOOL_GAMEOBJECT_SELECTED, COMBOS_DEVELOPMENT_TOOL_MARKER_OVERLAY_SUCCESS, COMBOS_DEVELOPMENT_TOOL_PICK_MODE_SUCCESS, COMBOS_DEVELOPMENT_TOOL_READY, COMBOS_DEVELOPMENT_TOOL_REFRESH, COMBOS_DEVELOPMENT_TOOL_SET_MARKER_OVERLAY, COMBOS_DEVELOPMENT_TOOL_SET_MUTED, COMBOS_DEVELOPMENT_TOOL_SET_PICK_MODE, COMBOS_DEVELOPMENT_TOOL_STATE_CHANGED, CombosDevelopmentToolSystem, CombosDevelopmentToolTarget, DEFAULT_ALLOWED_MESSAGE_HOST_SUFFIXES, MARKER_COMPONENTS, MARKER_ICON_SIZE, applyPropertyValue, applyPropertyWithHooks, attachDevelopmentTarget, buildGameObjectDeselectedPayload, buildGameObjectSnapshot, drawMarkerIcon, isAllowedMessageOrigin, isClearSelectionMessage, mergeAllowedMessageOrigins, readPropertyValue, readSourceAnchor, resolveMarkerDef, shouldNotifyGameObjectDeselected };
313
+ export type { CombosDevelopmentToolSystemParams, CombosDevelopmentToolTargetParams, DevelopmentTargetSource, DevelopmentToolDeselectReason, MarkerComponentDef, MarkerGlyph, MarkerGraphicsLike, SceneEditComponentSnapshot, SceneEditGameObjectSnapshot, SceneEditPropertyRef, SceneSourceAnchor };