[{"data":1,"prerenderedAt":736},["ShallowReactive",2],{"navigation":3,"/api-reference/visibility-api":238,"/api-reference/visibility-api-surround":731},[4,22,55,88,105,138,159,180,217],{"title":5,"icon":6,"path":7,"stem":8,"children":9,"page":6},"Getting Started",false,"/getting-started","01.getting-started",[10,14,18],{"title":11,"path":12,"stem":13},"Introduction","/getting-started/introduction","01.getting-started/1.introduction",{"title":15,"path":16,"stem":17},"Installation","/getting-started/installation","01.getting-started/2.installation",{"title":19,"path":20,"stem":21},"Quick Start","/getting-started/quick-start","01.getting-started/3.quick-start",{"title":23,"path":24,"stem":25,"children":26,"page":6},"Configuration","/configuration","02.configuration",[27,31,35,39,43,47,51],{"title":28,"path":29,"stem":30},"Overview","/configuration/overview","02.configuration/1.overview",{"title":32,"path":33,"stem":34},"Size","/configuration/size","02.configuration/2.size",{"title":36,"path":37,"stem":38},"Shape","/configuration/shape","02.configuration/3.shape",{"title":40,"path":41,"stem":42},"Positioning","/configuration/positioning","02.configuration/4.positioning",{"title":44,"path":45,"stem":46},"Placement","/configuration/placement","02.configuration/5.placement",{"title":48,"path":49,"stem":50},"Video","/configuration/video","02.configuration/6.video",{"title":52,"path":53,"stem":54},"Styles","/configuration/styles","02.configuration/7.styles",{"title":56,"path":57,"stem":58,"children":59,"page":6},"Components","/components","03.components",[60,64,68,72,76,80,84],{"title":61,"path":62,"stem":63},"Container","/components/container","03.components/1.container",{"title":65,"path":66,"stem":67},"Close Button","/components/close-button","03.components/2.close-button",{"title":69,"path":70,"stem":71},"CTA Button","/components/cta-button","03.components/3.cta-button",{"title":73,"path":74,"stem":75},"Video Controls","/components/video-controls","03.components/4.video-controls",{"title":77,"path":78,"stem":79},"Video Loader","/components/video-loader","03.components/5.video-loader",{"title":81,"path":82,"stem":83},"Video Progress","/components/video-progress","03.components/6.video-progress",{"title":85,"path":86,"stem":87},"Video Volume","/components/video-volume","03.components/7.video-volume",{"title":89,"path":90,"stem":91,"children":92,"page":6},"Features","/features","04.features",[93,97,101],{"title":94,"path":95,"stem":96},"Preview","/features/preview","04.features/1.preview",{"title":98,"path":99,"stem":100},"Visibility","/features/visibility","04.features/2.visibility",{"title":102,"path":103,"stem":104},"Responsive","/features/responsive","04.features/3.responsive",{"title":106,"path":107,"stem":108,"children":109,"page":6},"API Reference","/api-reference","05.api-reference",[110,114,118,122,126,130,134],{"title":111,"path":112,"stem":113},"useScena","/api-reference/use-scena","05.api-reference/1.use-scena",{"title":115,"path":116,"stem":117},"useConfig","/api-reference/use-config","05.api-reference/2.use-config",{"title":119,"path":120,"stem":121},"Scena Instance","/api-reference/scena-instance","05.api-reference/3.scena-instance",{"title":123,"path":124,"stem":125},"Video Controller","/api-reference/video-controller","05.api-reference/4.video-controller",{"title":127,"path":128,"stem":129},"Video State","/api-reference/video-state","05.api-reference/5.video-state",{"title":131,"path":132,"stem":133},"Visibility API","/api-reference/visibility-api","05.api-reference/6.visibility-api",{"title":135,"path":136,"stem":137},"Preview API","/api-reference/preview-api","05.api-reference/7.preview-api",{"title":139,"path":140,"stem":141,"children":142,"page":6},"Events","/events","06.events",[143,147,151,155],{"title":144,"path":145,"stem":146},"Widget Events","/events/widget-events","06.events/1.widget-events",{"title":148,"path":149,"stem":150},"Video Events","/events/video-events","06.events/2.video-events",{"title":152,"path":153,"stem":154},"Feature Events","/events/feature-events","06.events/3.feature-events",{"title":156,"path":157,"stem":158},"Click Events","/events/click-events","06.events/4.click-events",{"title":160,"path":161,"stem":162,"children":163,"page":6},"Custom Element","/custom-element","07.custom-element",[164,168,172,176],{"title":165,"path":166,"stem":167},"Setup","/custom-element/setup","07.custom-element/1.setup",{"title":169,"path":170,"stem":171},"Usage","/custom-element/usage","07.custom-element/2.usage",{"title":173,"path":174,"stem":175},"DOM Events","/custom-element/events","07.custom-element/3.events",{"title":177,"path":178,"stem":179},"Integration","/custom-element/integration","07.custom-element/4.integration",{"title":181,"path":182,"stem":183,"children":184,"page":6},"Examples","/examples","08.examples",[185,189,193,197,201,205,209,213],{"title":186,"path":187,"stem":188},"Basic Setup","/examples/basic-setup","08.examples/1.basic-setup",{"title":190,"path":191,"stem":192},"Custom Styling","/examples/custom-styling","08.examples/2.custom-styling",{"title":194,"path":195,"stem":196},"Responsive Widget","/examples/responsive-widget","08.examples/3.responsive-widget",{"title":198,"path":199,"stem":200},"Custom Controls","/examples/custom-controls","08.examples/4.custom-controls",{"title":202,"path":203,"stem":204},"Viewport Mount","/examples/viewport-mount","08.examples/5.viewport-mount",{"title":206,"path":207,"stem":208},"Timed Overlay","/examples/timed-overlay","08.examples/6.timed-overlay",{"title":210,"path":211,"stem":212},"Loop Segment","/examples/loop-segment","08.examples/7.loop-segment",{"title":214,"path":215,"stem":216},"Heatmap Data","/examples/heatmap-data","08.examples/8.heatmap-data",{"title":218,"path":219,"stem":220,"children":221,"page":6},"Distribution","/distribution","09.distribution",[222,226,230,234],{"title":223,"path":224,"stem":225},"Formats","/distribution/formats","09.distribution/1.formats",{"title":227,"path":228,"stem":229},"Browser Support","/distribution/browser-support","09.distribution/2.browser-support",{"title":231,"path":232,"stem":233},"Bundle Size","/distribution/bundle-size","09.distribution/3.bundle-size",{"title":235,"path":236,"stem":237},"TypeScript","/distribution/typescript","09.distribution/4.typescript",{"id":239,"title":131,"body":240,"description":725,"extension":726,"links":727,"meta":728,"navigation":435,"path":132,"seo":729,"stem":133,"__hash__":730},"docs/05.api-reference/6.visibility-api.md",{"type":241,"value":242,"toc":719},"minimark",[243,252,290,295,347,351,396,399,518,521,524,698,715],[244,245,246,247,251],"p",{},"The visibility API is available at ",[248,249,250],"code",{},"instance.visibility",". It provides reactive state and methods for showing and hiding the widget at runtime — useful for deferred rendering, conditional display, or toggling the widget in response to user actions on the host page.",[253,254,259],"pre",{"className":255,"code":256,"language":257,"meta":258,"style":258},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","const visibility = instance.visibility;\n","ts","",[248,260,261],{"__ignoreMap":258},[262,263,266,270,274,278,281,284,287],"span",{"class":264,"line":265},"line",1,[262,267,269],{"class":268},"spNyl","const",[262,271,273],{"class":272},"sTEyZ"," visibility ",[262,275,277],{"class":276},"sMK4o","=",[262,279,280],{"class":272}," instance",[262,282,283],{"class":276},".",[262,285,286],{"class":272},"visibility",[262,288,289],{"class":276},";\n",[291,292,294],"h2",{"id":293},"properties","Properties",[296,297,298,314],"table",{},[299,300,301],"thead",{},[302,303,304,308,311],"tr",{},[305,306,307],"th",{},"Property",[305,309,310],{},"Type",[305,312,313],{},"Description",[315,316,317,333],"tbody",{},[302,318,319,325,330],{},[320,321,322],"td",{},[248,323,324],{},"isHidden",[320,326,327],{},[248,328,329],{},"boolean",[320,331,332],{},"Whether the widget is currently hidden",[302,334,335,340,344],{},[320,336,337],{},[248,338,339],{},"isShownOnReady",[320,341,342],{},[248,343,329],{},[320,345,346],{},"Whether the widget auto-shows when the video is ready",[291,348,350],{"id":349},"methods","Methods",[296,352,353,365],{},[299,354,355],{},[302,356,357,360,363],{},[305,358,359],{},"Method",[305,361,362],{},"Signature",[305,364,313],{},[315,366,367,382],{},[302,368,369,374,379],{},[320,370,371],{},[248,372,373],{},"show",[320,375,376],{},[248,377,378],{},"() => void",[320,380,381],{},"Show the widget",[302,383,384,389,393],{},[320,385,386],{},[248,387,388],{},"hide",[320,390,391],{},[248,392,378],{},[320,394,395],{},"Hide the widget",[291,397,169],{"id":398},"usage",[253,400,402],{"className":255,"code":401,"language":257,"meta":258,"style":258},"// Hide the widget\ninstance.visibility.hide();\n\n// Show it later\ninstance.visibility.show();\n\n// Check state\nif (instance.visibility.isHidden) {\n  instance.visibility.show();\n}\n",[248,403,404,410,430,437,443,460,465,471,493,512],{"__ignoreMap":258},[262,405,406],{"class":264,"line":265},[262,407,409],{"class":408},"sHwdD","// Hide the widget\n",[262,411,413,416,418,420,422,425,428],{"class":264,"line":412},2,[262,414,415],{"class":272},"instance",[262,417,283],{"class":276},[262,419,286],{"class":272},[262,421,283],{"class":276},[262,423,388],{"class":424},"s2Zo4",[262,426,427],{"class":272},"()",[262,429,289],{"class":276},[262,431,433],{"class":264,"line":432},3,[262,434,436],{"emptyLinePlaceholder":435},true,"\n",[262,438,440],{"class":264,"line":439},4,[262,441,442],{"class":408},"// Show it later\n",[262,444,446,448,450,452,454,456,458],{"class":264,"line":445},5,[262,447,415],{"class":272},[262,449,283],{"class":276},[262,451,286],{"class":272},[262,453,283],{"class":276},[262,455,373],{"class":424},[262,457,427],{"class":272},[262,459,289],{"class":276},[262,461,463],{"class":264,"line":462},6,[262,464,436],{"emptyLinePlaceholder":435},[262,466,468],{"class":264,"line":467},7,[262,469,470],{"class":408},"// Check state\n",[262,472,474,478,481,483,485,487,490],{"class":264,"line":473},8,[262,475,477],{"class":476},"s7zQu","if",[262,479,480],{"class":272}," (instance",[262,482,283],{"class":276},[262,484,286],{"class":272},[262,486,283],{"class":276},[262,488,489],{"class":272},"isHidden) ",[262,491,492],{"class":276},"{\n",[262,494,496,499,501,503,505,507,510],{"class":264,"line":495},9,[262,497,498],{"class":272},"  instance",[262,500,283],{"class":276},[262,502,286],{"class":272},[262,504,283],{"class":276},[262,506,373],{"class":424},[262,508,427],{"class":509},"swJcz",[262,511,289],{"class":276},[262,513,515],{"class":264,"line":514},10,[262,516,517],{"class":276},"}\n",[291,519,139],{"id":520},"events",[244,522,523],{},"Visibility changes emit events on the event bus:",[253,525,527],{"className":255,"code":526,"language":257,"meta":258,"style":258},"import { ScenaEvent } from '@retoo/scena';\n\ninstance.api.events.on(ScenaEvent.ON_VISIBILITY_SHOW, () => {\n  console.log('Widget is now visible');\n});\n\ninstance.api.events.on(ScenaEvent.ON_VISIBILITY_HIDE, () => {\n  console.log('Widget is now hidden');\n});\n",[248,528,529,558,562,600,625,634,638,669,690],{"__ignoreMap":258},[262,530,531,534,537,540,543,546,549,553,556],{"class":264,"line":265},[262,532,533],{"class":476},"import",[262,535,536],{"class":276}," {",[262,538,539],{"class":272}," ScenaEvent",[262,541,542],{"class":276}," }",[262,544,545],{"class":476}," from",[262,547,548],{"class":276}," '",[262,550,552],{"class":551},"sfazB","@retoo/scena",[262,554,555],{"class":276},"'",[262,557,289],{"class":276},[262,559,560],{"class":264,"line":412},[262,561,436],{"emptyLinePlaceholder":435},[262,563,564,566,568,571,573,575,577,580,583,585,588,591,594,597],{"class":264,"line":432},[262,565,415],{"class":272},[262,567,283],{"class":276},[262,569,570],{"class":272},"api",[262,572,283],{"class":276},[262,574,520],{"class":272},[262,576,283],{"class":276},[262,578,579],{"class":424},"on",[262,581,582],{"class":272},"(ScenaEvent",[262,584,283],{"class":276},[262,586,587],{"class":272},"ON_VISIBILITY_SHOW",[262,589,590],{"class":276},",",[262,592,593],{"class":276}," ()",[262,595,596],{"class":268}," =>",[262,598,599],{"class":276}," {\n",[262,601,602,605,607,610,613,615,618,620,623],{"class":264,"line":439},[262,603,604],{"class":272},"  console",[262,606,283],{"class":276},[262,608,609],{"class":424},"log",[262,611,612],{"class":509},"(",[262,614,555],{"class":276},[262,616,617],{"class":551},"Widget is now visible",[262,619,555],{"class":276},[262,621,622],{"class":509},")",[262,624,289],{"class":276},[262,626,627,630,632],{"class":264,"line":445},[262,628,629],{"class":276},"}",[262,631,622],{"class":272},[262,633,289],{"class":276},[262,635,636],{"class":264,"line":462},[262,637,436],{"emptyLinePlaceholder":435},[262,639,640,642,644,646,648,650,652,654,656,658,661,663,665,667],{"class":264,"line":467},[262,641,415],{"class":272},[262,643,283],{"class":276},[262,645,570],{"class":272},[262,647,283],{"class":276},[262,649,520],{"class":272},[262,651,283],{"class":276},[262,653,579],{"class":424},[262,655,582],{"class":272},[262,657,283],{"class":276},[262,659,660],{"class":272},"ON_VISIBILITY_HIDE",[262,662,590],{"class":276},[262,664,593],{"class":276},[262,666,596],{"class":268},[262,668,599],{"class":276},[262,670,671,673,675,677,679,681,684,686,688],{"class":264,"line":473},[262,672,604],{"class":272},[262,674,283],{"class":276},[262,676,609],{"class":424},[262,678,612],{"class":509},[262,680,555],{"class":276},[262,682,683],{"class":551},"Widget is now hidden",[262,685,555],{"class":276},[262,687,622],{"class":509},[262,689,289],{"class":276},[262,691,692,694,696],{"class":264,"line":495},[262,693,629],{"class":276},[262,695,622],{"class":272},[262,697,289],{"class":276},[699,700,702],"callout",{"icon":701,"to":99},"i-lucide-arrow-right",[244,703,704,705,708,709,712,713,283],{},"See ",[706,707,98],"strong",{}," feature guide for config options like ",[248,710,711],{},"isAnimated"," and ",[248,714,339],{},[716,717,718],"style",{},"html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .s7zQu, html code.shiki .s7zQu{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}html pre.shiki code .swJcz, html code.shiki .swJcz{--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}",{"title":258,"searchDepth":265,"depth":412,"links":720},[721,722,723,724],{"id":293,"depth":412,"text":294},{"id":349,"depth":412,"text":350},{"id":398,"depth":412,"text":169},{"id":520,"depth":412,"text":139},"Programmatically show and hide the widget with show(), hide(), isHidden, and isShownOnReady.","md",null,{},{"title":131,"description":725},"1It6hGIAg6rcsgy6pvhnyqxKKsGLXLKii-_8K3T__2k",[732,734],{"title":127,"path":128,"stem":129,"description":733,"children":-1},"Playback state machine — idle, loading, playing, paused, ended, error.",{"title":135,"path":136,"stem":137,"description":735,"children":-1},"Control preview mode with start(), stop(), and isPreviewing state.",1777984323284]