license import { ActionButton } from '../src/elements/action-button/action-button.js' ; import { Card } from '../src/elements/card/card.js' ; import { DotLoader } from '../src/elements/dot-loader/dot-loader.js' ; import { PerceptionToolkit } from '../src/elements/perception-toolkit/perception-toolkit.js' ; import { StreamCapture } from '../src/elements/stream-capture/stream-capture.js' ; import { defineElement } from '../src/utils/define-element.js' ; export { Card } from '../src/elements/card/card.js' ; export { ActionButton } from '../src/elements/action-button/action-button.js' ; defineElement ( ActionButton . defaultTagName , ActionButton ) ; defineElement ( Card . defaultTagName , Card ) ; defineElement ( DotLoader . defaultTagName , DotLoader ) ; defineElement ( PerceptionToolkit . defaultTagName , PerceptionToolkit ) ; defineElement ( StreamCapture . defaultTagName , StreamCapture ) ; let toolkit = document . querySelector ( PerceptionToolkit . defaultTagName ) as PerceptionToolkit ; if ( ! toolkit ) { toolkit = new PerceptionToolkit ( ) ; document . body . appendChild ( toolkit ) ; } export async function initialize ( ) { if ( ! toolkit ) { return ; } await toolkit . start ( ) ; } export async function close ( ) { if ( ! toolkit ) { return ; } await toolkit . stop ( ) ; }