@vincentt-xr/sdk 2.0.0-alpha.11 → 2.0.0-alpha.12
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/GROUNDING.md +12 -7
- package/dist/{TextLabel-Dgt-uNN9.js → TextLabel-C6F5xoaz.js} +243 -264
- package/dist/TextLabel-ChZCoB3P.cjs +2 -0
- package/dist/components/ScreenImage/ScreenImage.d.ts +1 -1
- package/dist/components/ScreenShape/index.d.ts +1 -1
- package/dist/debug-ui.cjs +1 -1
- package/dist/debug-ui.js +2 -2
- package/dist/{index-WkEZBuB4.js → index-BaNlidsb.js} +276 -270
- package/dist/index-BzGLgXJm.cjs +46 -0
- package/dist/index-Cm3v6Dlg.cjs +21 -0
- package/dist/{index-CXaj3tOT.js → index-bL819L-K.js} +345 -338
- package/dist/instructions.cjs +1 -1
- package/dist/instructions.js +1 -1
- package/dist/main.cjs +1 -1
- package/dist/main.js +4 -4
- package/dist/scene-object.cjs +1 -1
- package/dist/scene-object.js +1 -1
- package/dist/useEditOverrides-BTkPGVjN.js +38 -0
- package/dist/useEditOverrides-C3ZVXuIH.cjs +1 -0
- package/dist/utils/useEditOverrides.d.ts +9 -2
- package/package.json +1 -1
- package/settings.json +1 -1
- package/dist/TextLabel-Ctp-a7g9.cjs +0 -2
- package/dist/index-Bxb_UcfF.cjs +0 -46
- package/dist/index-CYwAL_d7.cjs +0 -21
package/GROUNDING.md
CHANGED
|
@@ -190,17 +190,22 @@ that is not on an exported component.
|
|
|
190
190
|
|
|
191
191
|
### Live preview of unsaved editor changes
|
|
192
192
|
|
|
193
|
-
In the console's visual editor, an unsaved change to
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
193
|
+
In the console's visual editor, an unsaved change to one of these settings
|
|
194
|
+
shows in the running app at once: `<ScreenText>` colour, font size and screen
|
|
195
|
+
placement; `<ScreenImage>` screen placement; `<ScreenShape>` screen placement
|
|
196
|
+
and fill colour; `<TextLabel>` colour. Other changes show after Save, which
|
|
197
|
+
rebuilds the app. The editor's build defines a small override store on the
|
|
198
|
+
page, and those components read it for those settings. Published and
|
|
197
199
|
preview builds have no store, so they render the props exactly as written.
|
|
198
200
|
App code does nothing for this and must not define or read
|
|
199
201
|
`__VCT_EDIT_OVERRIDES__`.
|
|
200
202
|
|
|
201
|
-
SDK authors: to make another prop live, add its
|
|
202
|
-
`LIVE_EDITABLE` list (`
|
|
203
|
-
`
|
|
203
|
+
SDK authors: to make another prop live, add its key to the component's
|
|
204
|
+
`LIVE_EDITABLE` list (in `ScreenText`, `ScreenImage`, `ScreenShape` and
|
|
205
|
+
`TextLabel`). A key is the prop name or a dotted path into an object prop
|
|
206
|
+
(`settings.fillColor`, `transform.position`), the same key as in
|
|
207
|
+
`settings.json`. A dotted key replaces only that leaf, copying the objects
|
|
208
|
+
around it, and is skipped when the parent object is not written. The hook is
|
|
204
209
|
`useEditOverrides(props, keys)` in `lib/utils/useEditOverrides.ts`. Call it with
|
|
205
210
|
the component's own props object, before destructuring.
|
|
206
211
|
|