pages/public/gamedevtree/docs/infoboxes.html

39 lines
22 KiB
HTML
Raw Normal View History

<!DOCTYPE html>
<html lang="en-US" dir="ltr">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Infoboxes | The Paper Pilot</title>
<meta name="description" content="The Paper Pilot portfolio site">
<meta name="generator" content="VitePress v1.2.2">
<link rel="preload stylesheet" href="/assets/style.BG12FMT-.css" as="style">
<script type="module" src="/assets/app.Hkf4QKZH.js"></script>
<link rel="preload" href="/assets/inter-roman-latin.Di8DUHzh.woff2" as="font" type="font/woff2" crossorigin="">
<link rel="modulepreload" href="/assets/chunks/framework.CW2X4ZVO.js">
<link rel="modulepreload" href="/assets/chunks/theme.LU1JJ70W.js">
<link rel="modulepreload" href="/assets/public_gamedevtree_docs_infoboxes.md.BipbzJhO.lean.js">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Pacifico&amp;family=Roboto+Mono:ital,wght@0,400;0,600;1,400&amp;display=swap">
<link rel="manifest" href="/site.webmanifest">
<script defer data-domain="thepaperpilot.org" src="https://plausible.io/js/plausible.js"></script>
<meta name="og:description" content="The Paper Pilot portfolio site">
<script id="check-dark-mode">(()=>{const e=localStorage.getItem("vitepress-theme-appearance")||"auto",a=window.matchMedia("(prefers-color-scheme: dark)").matches;(!e||e==="auto"?a:e==="dark")&&document.documentElement.classList.add("dark")})();</script>
<script id="check-mac-os">document.documentElement.classList.toggle("mac",/Mac|iPhone|iPod|iPad/i.test(navigator.platform));</script>
</head>
<body>
<div id="app"><div class="Layout" data-v-5d98c3a5><!--[--><!--]--><!--[--><span tabindex="-1" data-v-0f60ec36></span><a href="#VPContent" class="VPSkipLink visually-hidden" data-v-0f60ec36> Skip to content </a><!--]--><!----><header class="VPNav" data-v-5d98c3a5 data-v-ae24b3ad><div class="VPNavBar top" data-v-ae24b3ad data-v-ccf7ddec><div class="wrapper" data-v-ccf7ddec><div class="container" data-v-ccf7ddec><div class="title" data-v-ccf7ddec><div class="VPNavBarTitle" data-v-ccf7ddec data-v-ab179fa1><a class="title" href="/" data-v-ab179fa1><!--[--><!--]--><!----><span data-v-ab179fa1>The Paper Pilot</span><!--[--><!--]--></a></div></div><div class="content" data-v-ccf7ddec><div class="content-body" data-v-ccf7ddec><!--[--><!--]--><div class="VPNavBarSearch search" data-v-ccf7ddec><!----></div><nav aria-labelledby="main-nav-aria-label" class="VPNavBarMenu menu" data-v-ccf7ddec data-v-7f418b0f><span id="main-nav-aria-label" class="visually-hidden" data-v-7f418b0f>Main Navigation</span><!--[--><!--[--><a class="VPLink link VPNavBarMenuLink" href="/guide-to-incrementals/" tabindex="0" data-v-7f418b0f data-v-9c663999><!--[--><span data-v-9c663999>Guide to Incrementals</span><!--]--></a><!--]--><!--[--><a class="VPLink link VPNavBarMenuLink" href="/projects/" tabindex="0" data-v-7f418b0f data-v-9c663999><!--[--><span data-v-9c663999>Projects</span><!--]--></a><!--]--><!--[--><a class="VPLink link vp-external-link-icon VPNavBarMenuLink" href="https://moddingtree.com" target="_blank" rel="noreferrer" tabindex="0" data-v-7f418b0f data-v-9c663999><!--[--><span data-v-9c663999>Profectus</span><!--]--></a><!--]--><!--]--></nav><!----><div class="VPNavBarAppearance appearance" data-v-ccf7ddec data-v-e6aabb21><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="Switch to dark theme" aria-checked="false" data-v-e6aabb21 data-v-d1f28634 data-v-1d5665e3><span class="check" data-v-1d5665e3><span class="icon" data-v-1d5665e3><!--[--><span class="vpi-sun sun" data-v-d1f28634></span><span class="vpi-moon moon" data-v-d1f28634></span><!--]--></span></span></button></div><div class="VPSocialLinks VPNavBarSocialLinks social-links" data-v-ccf7ddec data-v-0394ad82 data-v-7bc22406><!--[--><a class="VPSocialLink no-icon" href="https://github.com/thepaperpilot" aria-label="github" target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><span class="vpi-social-github" /></a><a class="VPSocialLink no-icon" href="https://www.linkedin.com/pub/anthony-lawn/a9/a98/2" aria-label="linkedin" target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><span class="vpi-social-linkedin" /></a><a class="VPSocialLink no-icon" href="https://discord.gg/yJ4fjnjU54" aria-label="discord" target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><span class="vpi-social-discord" /></a><a class="VPSocialLink no-icon" href="https://mastodon.gamedev.place/@thepaperpilot" aria-label target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-mastodon" viewBox="0 0 16 16">
<path d="M11.19 12.195c2.016-.24 3.77-1.475 3.99-2.603.348-1.778.32-4.339.32-4.339 0-3.47-2.286-4.488-2.286-4.488C12.062.238 10.083.017 8.027 0h-.05C5.92.017 3.942.238 2.79.765c0 0-2.285 1.017-2.285 4.488l-.002.662c-.004.64-.007 1.35.011 2.091.083 3.394.626 6.74 3.78 7.57 1.454.383 2.703.463 3.709.408 1.823-.1 2.847-.647 2.847-.647l-.06-1.317s-1.303.41-2.767.36c-1.45-.05-2.98-.156-3.215-1.928a3.614 3.614 0 0 1-.033-.496s1.424.346 3.228.428c1.103.05 2.137-.064 3.188-.189zm1.613-2.47H11.13v-4.08c0-.859-.364-1.295-1.091-1.295-.804 0-1.207.517-1.207 1.541v2.233H7.168V5.89c0-1.024-.403-1.541-1.207-1.541-.727 0-1.091.436-1.091 1.296v4.079H3.197V5.522c0-.859.22-1.541.66-2.046.456-.505 1.052-.764 1.793-.764.856 0 1.504.328 1.933.983L8 4.39l.417-.695c.429-.655 1.077-.983 1.934-.983.74 0 1.336.259 1.791.764.442.505.661 1.187.661 2.046v4.203z"/>
</svg></a><!--]--></div><div class="VPFlyout VPNavBarExtra extra" data-v-ccf7ddec data-v-d0bd9dde data-v-b6c34ac9><button type="button" class="button" aria-haspopup="true" aria-expanded="false" aria-label="extra navigation" data-v-b6c34ac9><span class="vpi-more-horizontal icon" data-v-b6c34ac9></span></button><div class="menu" data-v-b6c34ac9><div class="VPMenu" data-v-b6c34ac9 data-v-e7ea1737><!----><!--[--><!--[--><!----><div class="group" data-v-d0bd9dde><div class="item appearance" data-v-d0bd9dde><p class="label" data-v-d0bd9dde>Appearance</p><div class="appearance-action" data-v-d0bd9dde><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="Switch to dark theme" aria-checked="false" data-v-d0bd9dde data-v-d1f28634 data-v-1d5665e3><span class="check" data-v-1d5665e3><span class="icon" data-v-1d5665e3><!--[--><span class="vpi-sun sun" data-v-d1f28634></span><span class="vpi-moon moon" data-v-d1f28634></span><!--]--></span></span></button></div></div></div><div class="group" data-v-d0bd9dde><div class="item social-links" data-v-d0bd9dde><div class="VPSocialLinks social-links-list" data-v-d0bd9dde data-v-7bc22406><!--[--><a class="VPSocialLink no-icon" href="https://github.com/thepaperpilot" aria-label="github" target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><span class="vpi-social-github" /></a><a class="VPSocialLink no-icon" href="https://www.linkedin.com/pub/anthony-lawn/a9/a98/2" aria-label="linkedin" target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><span class="vpi-social-linkedin" /></a><a class="VPSocialLink no-icon" href="https://discord.gg/yJ4fjnjU54" aria-label="discord" target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><span class="vpi-social-discord" /></a><a class="VPSocialLink no-icon" href="https://mastodon.gamedev.place/@thepaperpilot" aria-label target="_blank" rel="noopener" data-v-7bc22406 data-v-eee4e7cb><svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-mastodon" viewBox="0 0 16 16">
<path d="M11.19 12.195c2.016-.24 3.77-1.475 3.99-2.603.348-1.778.32-4.339.32-4.339 0-3.47-2.286-4.488-2.286-4.488C12.062.238 10.083.017 8.027 0h-.05C5.92.017 3.942.238 2.79.765c0 0-2.285 1.017-2.285 4.488l-.002.662c-.004.64-.007 1.35.011 2.091.083 3.394.626 6.74 3.78 7.57 1.454.383 2.703.463 3.709.408 1.823-.1 2.847-.647 2.847-.647l-.06-1.317s-1.303.41-2.767.36c-1.45-.05-2.98-.156-3.215-1.928a3.614 3.614 0 0 1-.033-.496s1.424.346 3.228.428c1.103.05 2.137-.064 3.188-.189zm1.613-2.47H11.13v-4.08c0-.859-.364-1.295-1.091-1.295-.804 0-1.207.517-1.207 1.541v2.233H7.168V5.89c0-1.024-.403-1.541-1.207-1.541-.727 0-1.091.436-1.091 1.296v4.079H3.197V5.522c0-.859.22-1.541.66-2.046.456-.505 1.052-.764 1.793-.764.856 0 1.504.328 1.933.983L8 4.39l.417-.695c.429-.655 1.077-.983 1.934-.983.74 0 1.336.259 1.791.764.442.505.661 1.187.661 2.046v4.203z"/>
</svg></a><!--]--></div></div></div><!--]--><!--]--></div></div></div><!--[--><!--]--><button type="button" class="VPNavBarHamburger hamburger" aria-label="mobile navigation" aria-expanded="false" aria-controls="VPNavScreen" data-v-ccf7ddec data-v-e5dd9c1c><span class="container" data-v-e5dd9c1c><span class="top" data-v-e5dd9c1c></span><span class="middle" data-v-e5dd9c1c></span><span class="bottom" data-v-e5dd9c1c></span></span></button></div></div></div></div><div class="divider" data-v-ccf7ddec><div class="divider-line" data-v-ccf7ddec></div></div></div><!----></header><div class="VPLocalNav empty fixed" data-v-5d98c3a5 data-v-a6f0e41e><div class="container" data-v-a6f0e41e><!----><div class="VPLocalNavOutlineDropdown" style="--vp-vh:0px;" data-v-a6f0e41e data-v-17a5e62e><button data-v-17a5e62e>Return to top</button><!----></div></div></div><!----><div class="VPContent" id="VPContent" data-v-5d98c3a5 data-v-1428d186><div class="VPDoc has-aside" data-v-1428d186 data-v-39a288b8><!--[--><!--]--><div class="container" data-v-39a288b8><div class="aside" data-v-39a288b8><div class="aside-curtain" data-v-39a288b8></div><div class="aside-container" data-v-39a288b8><div class="aside-content" data-v-39a288b8><div class="VPDocAside" data-v-39a288b8 data-v-3f215769><!--[--><!--]--><!--[--><!--]--><nav aria-labelledby="doc-outline-aria-label" class="VPDocAsideOutline" data-v-3f215769 data-v-a5bbad30><div class="content" data-v-a5bbad30><div class="outline-marker" data-v-a5bbad30></div><div aria-level="2" class="outline-title" id="doc-outline-aria-label" role="heading" data-v-a5bbad30>On this page</div><ul class="VPDocOutlineItem root" data-v-a5bbad30 data-v-b933a997><!--[--><!--]--></ul></div></nav><!--[--><!--]--><div class="spacer" data-v-3f215769></div><!--[--><!--]--><!----><!--[--><!--]--><!--[--><!--]--></div></div></div></div><div class="content" data-v-39a288b8><div class="content-container" data-v-39a288b8><!--[--><!--]--><main class="main" data-v-39a288b8><div style="position:relative;" class="vp-doc _public_gamedevtree_docs_infoboxes" data-v-39a288b8><div><h1 id="infoboxes" tabindex="-1">Infoboxes <a class="header-anchor" href="#infoboxes" aria-label="Permalink to &quot;Infoboxes&quot;"></a></h1><p>Infoboxes are good for displaying &quot;lore&quot;, or story elements, as well as for explaining complicated things.</p><p>In the default tab layout, the first infobox will be displayed at the very top of the tab.</p><p>Infoboxes are defined like other Big Features:</p><div class="language-js vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;"> infoboxes</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">: {</span></span>
<span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;"> infobox</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">: {</span></span>
<span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;"> display</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">() {</span><span style="--shiki-light:#D73A49;--shiki-dark:#F97583;">return</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> &quot;Blah&quot;</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">},</span></span>
<span class="line"><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> etc</span></span>
<span class="line"><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> }</span></span>
<span class="line"><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> etc</span></span>
<span class="line"><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> }</span></span></code></pre></div><p>Features:</p><ul><li><p>title: The text displayed above the main box. Can be a function to be dynamic, and can use basic HTML.</p></li><li><p>body: The text displayed inside the box. Can be a function to be dynamic, and can use basic HTML.</p></li><li><p>style, titleStyle, bodyStyle: <strong>Optional</strong>, Apply CSS to the infobox, or to the title button or body of the infobox, in the form of an object where the keys are CSS attributes, and the values are the Values for those attributes (both as strings).</p></li><li><p>unlocked(): <strong>optional</strong>, A function returning a bool to determine if the infobox is visible or not. Default is unlocked.</p></li><li><p>layer: <strong>Assigned automagically</strong>. It&#39;s the same value as the name of this layer, so you can do player[this.layer].points or similar</p></li><li><p>id: <strong>Assigned automagically</strong>. It&#39;s the &quot;key&quot; which the bar was stored under, for convenient access. The bar in the example&#39;s id is &quot;bigBar&quot;.</p></li></ul></div></div></main><footer class="VPDocFooter" data-v-39a288b8 data-v-d4a0bba5><!--[--><!--]--><div class="edit-info" data-v-d4a0bba5><!----><div class="last-updated" data-v-d4a0bba5><p class="VPLastUpdated" data-v-d4a0bba5 data-v-7e05ebdb>Last updated: <time datetime="2023-11-28T02:07:21.000Z" data-v-7e05ebdb></time></p></div></div><!----></footer><!--[--><!--]--></div></div></div><!--[--><!--]--></div></div><!----><!--[--><!--]--></div></div>
<script>window.__VP_HASH_MAP__=JSON.parse("{\"garden_garden-rss_index.md\":\"DMuXTEzl\",\"garden_chat-glue_index.md\":\"C449juJd\",\"garden_cinny_index.md\":\"D6hYbz7-\",\"garden_commune_index.md\":\"Di_fTeDb\",\"garden_decentralized_index.md\":\"DHdY88o-\",\"garden_atproto_index.md\":\"BVtktjLw\",\"garden_federated-identity_index.md\":\"BJ9Oi_bu\",\"garden_fedi-v2_index.md\":\"DSEBihHA\",\"garden_fediverse_index.md\":\"C7Vhx_wy\",\"garden_forgejo_index.md\":\"pVeq8opE\",\"garden_freeform-vs-chronological-dichotomy_index.md\":\"DHJ5f4NP\",\"garden_freeform_index.md\":\"4f5H8p6a\",\"garden_synapse_index.md\":\"6PICcRkX\",\"garden_incremental-social_index.md\":\"BeSmfpmy\",\"garden_logseq_index.md\":\"CdJTa-eh\",\"garden_my-personal-website_index.md\":\"B0ppvuEb\",\"garden_nostr_index.md\":\"BvHH48sW\",\"garden_open-source_index.md\":\"gahlPQvW\",\"garden_social-media_index.md\":\"CjbTBW_q\",\"garden_vitepress_index.md\":\"m7Id_at2\",\"garden_the-small-web_index.md\":\"BCZLKQAE\",\"garden_mbin_index.md\":\"CdaUtWJs\",\"garden_the-cozy-web_index.md\":\"I9o-fq40\",\"garden_matrix_index.md\":\"DS5rN2hh\",\"garden_this-knowledge-hub_index.md\":\"B2wl8_Xh\",\"public_kronos_docs_!general-info.md\":\"EuB5fdqx\",\"public_kronos_changelog.md\":\"D6Y2yJoD\",\"public_kronos_docs_buyables.md\":\"DBoSSKpb\",\"public_kronos_docs_bars.md\":\"ieNVvJB_\",\"public_kronos_docs_basic-layer-breakdown.md\":\"CB1mQ_I0\",\"public_kronos_docs_clickables.md\":\"BEPI6Dtc\",\"public_kronos_docs_custom-tab-layouts.md\":\"BUSqDz6c\",\"public_kronos_docs_getting-started.md\":\"8csa7_tZ\",\"public_kronos_docs_challenges.md\":\"C_k5KJfE\",\"public_kronos_docs_infoboxes.md\":\"BJmtw3vd\",\"public_kronos_docs_milestones.md\":\"ab5rh9XE\",\"public_kronos_docs_upgrades.md\":\"Bpi9bUwq\",\"public_lit_docs_custom-tab-layouts.md\":\"DbPd7BGK\",\"public_kronos_docs_trees-and-tree-customization.md\":\"By2EFg0F\",\"public_kronos_docs_subtabs-and-microtabs.md\":\"Cn3QhiN2\",\"public_lit_readme.md\":\"LuMWoyn-\",\"public_lit_changelog.md\":\"DRI7c8Ml\",\"public_lit_docs_achievements.md\":\"CwdHpp1u\",\"public_lit_docs_bars.md\":\"uFDt9Rqh\",\"public_lit_docs_!general-info.md\":\"C34luG0g\",\"public_lit_docs_basic-layer-breakdown.md\":\"D0nc9F2J\",\"public_lit_docs_challenges.md\":\"COuOQ6No\",\"public_lit_docs_clickables.md\":\"CNdv-3GF\",\"public_lit_docs_buyables.md\":\"DnaSeFD0\",\"public_gamedevtree_docs_!general-info.md\":\"Cw0DVUCA\",\"projects_index.md\":\"cyxUyThz\",\"projects_babble_index.md\":\"kspChx8z\",\"projects_optispeech_index.md\":\"C1HCdfWG\",\"projects_vecs_index.md\":\"DnEjJUiP\",\"public_gamedevtree_2.0-format-changes.md\":\"CD0Npi_4\",\"projects_dice_index.md\":\"9YHg_Dxn\",\"public_gamedevtree_readme.md\":\"Cn4R8ymc\",\"public_gamedevtree_docs_getting-started.md\":\"CRye-c6-\",\"public_gamedevtree_docs_achievements.md\":\"B4VWZ2LE\",\"public_gamedevtree_docs_bars.md\":\"YCxRPz9a\",\"public_gamedevtree_changelog.md\":\"9bai4XrJ\",\"public_gamedevtree_docs_basic-layer-breakdown.md\":\"DNmosgoQ\",\"index.md\":\"BdglAbxN\",\"public_gamedevtree_docs_challenges.md\":\"DTe4jW_G\",\"projects_citadel_index.md\":\"C6a1xN8H\",\"public_gamedevtree_docs_buyables.md\":\"ztjgjcoN\",\"public_lit_docs_trees-and-tree-customization.md\":\"D4BGEyVy\",\"public_kronos_readme.md\":\"_K8J0OCm\",\"public_lit_docs_upgrades.md\":\"BW_xlcHT\",\"garden_digital-gardens_index.md\":\"Blrs56lK\",\"garden_chronological_index.md\":\"PnVPd0Tu\",\"garden_activitypub_index.md\":\"8r2pi39e\",\"public_kronos_docs_main-mod-info.md\":\"DyMjpJ77\",\"public_lit_old things_2.0-format-changes.md\":\"BFlcO312\",\"public_kronos_docs_achievements.md\":\"BaopLUbc\",\"public_kronos_docs_layer-features.md\":\"Dvf8anVd\",\"public_kronos_docs_updating-tmt.md\":\"3ckirx-d\",\"guide-to-incrementals_design_introduction_index.md\":\"DJpuP2iT\",\"guide-to-incrementals_index.md\":\"DkRArpQS\",\"guide-to-incrementals_ludology_appeal-developers_index.md\":\"DPxrJMXH\",\"guide-to-incrementals_ludology_appeal-gamers_index.md\":\"ASWFgarJ\",\"public_kronos_docs_grids.md\":\"B_fTrMnh\",\"garden_weird_ind
</body>
</html>