babylonjs-accessibility 6.3.1 → 6.4.1

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.
@@ -44,12 +44,14 @@ declare module BABYLON.Accessibility {
44
44
 
45
45
  interface IHTMLTwinHostComponentProps {
46
46
  scene: BABYLON.Scene;
47
+ options?: IHTMLTwinRendererOptions;
47
48
  }
48
49
  interface IHTMLTwinHostComponentState {
49
50
  a11yTreeItems: HTMLTwinItem[];
50
51
  }
51
52
  export class HTMLTwinHostComponent extends React.Component<IHTMLTwinHostComponentProps, IHTMLTwinHostComponentState> {
52
53
  private _observersMap;
54
+ private _options;
53
55
  constructor(props: IHTMLTwinHostComponentProps);
54
56
  componentDidUpdate(prevProps: Readonly<IHTMLTwinHostComponentProps>, prevState: Readonly<IHTMLTwinHostComponentState>, snapshot?: any): void;
55
57
  /**
@@ -160,8 +162,28 @@ declare module BABYLON.Accessibility {
160
162
  }
161
163
 
162
164
 
165
+ /**
166
+ * Options for the HTMLTwinRenderer.
167
+ */
168
+ export interface IHTMLTwinRendererOptions {
169
+ /**
170
+ * If this is true, all GUI controls will be added to the twin tree, regardless if they have
171
+ * a defined accessibility tag or not. If it's false, only controls with an accessibility tag
172
+ * will be added. True by default.
173
+ */
174
+ addAllControls: boolean;
175
+ }
176
+ /**
177
+ * This class is the main entry point for the HTML twin renderer. To render a twin for a scene,
178
+ * simply call HTMLTwinRenderer.Render(scene).
179
+ */
163
180
  export class HTMLTwinRenderer {
164
- static Render(scene: BABYLON.Scene): void;
181
+ /**
182
+ * Render the HTML twin for the given scene.
183
+ * @param scene the scene to render the twin for
184
+ * @param options options for the renderer
185
+ */
186
+ static Render(scene: BABYLON.Scene, options?: IHTMLTwinRendererOptions): void;
165
187
  }
166
188
 
167
189