profectus-docs/assets/api_interfaces_game_layers.BaseLayer.md.deeb1a42.js

1 line
7.3 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import{_ as e,c as a,o as t,N as r}from"./chunks/framework.0799945b.js";const u=JSON.parse('{"title":"Interface: BaseLayer","description":"","frontmatter":{"editLink":false},"headers":[],"relativePath":"api/interfaces/game/layers.BaseLayer.md","lastUpdated":null}'),o={name:"api/interfaces/game/layers.BaseLayer.md"},n=r('<h1 id="interface-baselayer" tabindex="-1">Interface: BaseLayer <a class="header-anchor" href="#interface-baselayer" aria-label="Permalink to &quot;Interface: BaseLayer&quot;"></a></h1><p><a href="./../../modules/game/layers">game/layers</a>.BaseLayer</p><p>The properties that are added onto a processed <a href="./layers.LayerOptions">LayerOptions</a> to create a <a href="./../../modules/game/layers#layer">Layer</a></p><h2 id="properties" tabindex="-1">Properties <a class="header-anchor" href="#properties" aria-label="Permalink to &quot;Properties&quot;"></a></h2><h3 id="emit" tabindex="-1">emit <a class="header-anchor" href="#emit" aria-label="Permalink to &quot;emit&quot;"></a></h3><p>• <strong>emit</strong>: &lt;K&gt;(...<code>args</code>: [<code>K</code>, ...Parameters&lt;LayerEvents[K]&gt;[]]) =&gt; <code>void</code></p><h4 id="type-declaration" tabindex="-1">Type declaration <a class="header-anchor" href="#type-declaration" aria-label="Permalink to &quot;Type declaration&quot;"></a></h4><p>▸ &lt;<code>K</code>&gt;(<code>...args</code>): <code>void</code></p><p>A function to emit a <a href="./layers.LayerEvents">LayerEvents</a> event to this layer.</p><h5 id="type-parameters" tabindex="-1">Type parameters <a class="header-anchor" href="#type-parameters" aria-label="Permalink to &quot;Type parameters&quot;"></a></h5><table><thead><tr><th style="text-align:left;">Name</th><th style="text-align:left;">Type</th></tr></thead><tbody><tr><td style="text-align:left;"><code>K</code></td><td style="text-align:left;">extends keyof <a href="./layers.LayerEvents"><code>LayerEvents</code></a></td></tr></tbody></table><h5 id="parameters" tabindex="-1">Parameters <a class="header-anchor" href="#parameters" aria-label="Permalink to &quot;Parameters&quot;"></a></h5><table><thead><tr><th style="text-align:left;">Name</th><th style="text-align:left;">Type</th></tr></thead><tbody><tr><td style="text-align:left;"><code>...args</code></td><td style="text-align:left;">[<code>K</code>, ...Parameters&lt;LayerEvents[K]&gt;[]]</td></tr></tbody></table><h5 id="returns" tabindex="-1">Returns <a class="header-anchor" href="#returns" aria-label="Permalink to &quot;Returns&quot;"></a></h5><p><code>void</code></p><h4 id="defined-in" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/8c0a0c4/src/game/layers.tsx#L162" target="_blank" rel="noreferrer">profectus/src/game/layers.tsx:162</a></p><hr><h3 id="emitter" tabindex="-1">emitter <a class="header-anchor" href="#emitter" aria-label="Permalink to &quot;emitter&quot;"></a></h3><p>• <strong>emitter</strong>: <code>Emitter</code>&lt;<a href="./layers.LayerEvents"><code>LayerEvents</code></a>&gt;</p><p>An emitter for sending <a href="./layers.LayerEvents">LayerEvents</a> events for this layer.</p><h4 id="defined-in-1" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in-1" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/8c0a0c4/src/game/layers.tsx#L158" target="_blank" rel="noreferrer">profectus/src/game/layers.tsx:158</a></p><hr><h3 id="id" tabindex="-1">id <a class="header-anchor" href="#id" aria-label="Permalink to &quot;id&quot;"></a></h3><p>• <strong>id</strong>: <code>string</code></p><p>The ID of the layer. Populated from the <a href="./../../modules/game/layers#createlayer">createLayer</a> parameters. Used for saving and tracking open tabs.</p><h4 id="defined-in-2" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in-2" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/8c0a0c4/src/game/layers.tsx#L154" target="_blank" rel="noreferrer">profectus/src/game/layers.tsx:154</a></p><hr><h3 id="minimized" tabindex="-1">minimized <a class="header-anchor" href="#minimized" aria-label="Permalink to &quot;minimized&quot;"></a></h3><p>• <strong>minimized</strong>: <a href="./../../modules/game/persistence#persistent"><code>Persistent</code></a>&lt;<code>boolean</code>&gt;</p><p>A persistent ref tracking if the tab is minimized or not.</p><h4 id="defined-in-3" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in-3" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/8c0a0c4/src/game/layers.tsx#L156" target="_blank" rel="noreferrer">profectus/src/game/layers.tsx:156</a></p><hr><h3 id="nodes" tabindex="-1">nodes <a class="header-anchor" href="#nodes" aria-label="Permalink to &quot;nodes&quot;"></a></h3><p>• <strong>nodes</strong>: <code>Ref</code>&lt;<a href="https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type" target="_blank" rel="noreferrer"><code>Record</code></a>&lt;<code>string</code>, <code>undefined</code> | <a href="./layers.FeatureNode"><code>FeatureNode</code></a>&gt;&gt;</p><p>A map of <a href="./layers.FeatureNode">FeatureNode</a>s present in this layer&#39;s ContextComponent component.</p><h4 id="defined-in-4" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in-4" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/8c0a0c4/src/game/layers.tsx#L164" target="_blank" rel="noreferrer">profectus/src/game/layers.tsx:164</a></p><hr><h3 id="on" tabindex="-1">on <a class="header-anchor" href="#on" aria-label="Permalink to &quot;on&quot;"></a></h3><p>• <strong>on</strong>: (...<code>args</code>: [event: keyof LayerEvents, cb: Function | Function | Function]) =&gt; <code>Unsubscribe</code></p><h4 id="type-declaration-1" tabindex="-1">Type declaration <a class="header-anchor" href="#type-declaration-1" aria-label="Permalink to &quot;Type declaration&quot;"></a></h4><p>▸ (<code>...args</code>): <code>Unsubscribe</code></p><p>A function to register an event listener on <a href="./layers.BaseLayer#emitter">emitter</a>.</p><h5 id="parameters-1" tabindex="-1">Parameters <a class="header-anchor" href="#parameters-1" aria-label="Permalink to &quot;Parameters&quot;"></a></h5><table><thead><tr><th style="text-align:left;">Name</th><th style="text-align:left;">Type</th></tr></thead><tbody><tr><td style="text-align:left;"><code>...args</code></td><td style="text-align:left;">[event: keyof LayerEvents, cb: Function | Function | Function]</td></tr></tbody></table><h5 id="returns-1" tabindex="-1">Returns <a class="header-anchor" href="#returns-1" aria-label="Permalink to &quot;Returns&quot;"></a></h5><p><code>Unsubscribe</code></p><h4 id="defined-in-5" tabindex="-1">Defined in <a class="header-anchor" href="#defined-in-5" aria-label="Permalink to &quot;Defined in&quot;"></a></h4><p><a href="https://github.com/profectus-engine/Profectus/blob/8c0a0c4/src/game/layers.tsx#L160" target="_blank" rel="noreferrer">profectus/src/game/layers.tsx:160</a></p>',53),s=[n];function i(d,l,c,h,f,p){return t(),a("div",null,s)}const y=e(o,[["render",i]]);export{u as __pageData,y as default};