Skip to content

Commit

Permalink
Hide Tabs for Hidden Children
Browse files Browse the repository at this point in the history
  • Loading branch information
poirazis committed Aug 3, 2023
1 parent c0b6a72 commit 78b5d10
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/Component.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
const { styleable, builderStore, componentStore } = getContext("sdk")
const component = getContext("component")
//
let tabsToRender = []
let container
let contents
let vertical
Expand Down Expand Up @@ -75,9 +76,10 @@
}
let left, top, width, height
function calculateIndicator ()
async function calculateIndicator ()
{
if ($tabStore.id) {
console.log("Calculating")
if (!vertical) {
width = $tabStore?.boundingBox?.width + "px"
height = "2px";
Expand Down Expand Up @@ -137,6 +139,7 @@
</div>
</div>
<div bind:this={contents} class="tabContents">
<slot />
</div>
Expand Down
48 changes: 48 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -318,9 +318,15 @@
integrity sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==

"@types/node@*", "@types/node@^20.4.5":
<<<<<<< HEAD
version "20.4.6"
resolved "https://registry.yarnpkg.com/@types/node/-/node-20.4.6.tgz#b66b66c9bb5d49b199f03399e341c9d6036e9e88"
integrity sha512-q0RkvNgMweWWIvSMDiXhflGUKMdIxBo2M2tYM/0kEGDueQByFzK4KZAgu5YHGFNxziTlppNpTIBcqHQAxlfHdA==
=======
version "20.4.5"
resolved "https://registry.yarnpkg.com/@types/node/-/node-20.4.5.tgz#9dc0a5cb1ccce4f7a731660935ab70b9c00a5d69"
integrity sha512-rt40Nk13II9JwQBdeYqmbn2Q6IVTA5uPhvSO+JVqdXw/6/4glI6oR9ezty/A9Hg5u7JH4OmYmuQ+XvjKm0Datg==
>>>>>>> 885c51b (Hide Tabs for Hidden Children)

"@types/[email protected]":
version "1.17.1"
Expand Down Expand Up @@ -697,9 +703,20 @@ caniuse-api@^3.0.0:
lodash.uniq "^4.5.0"

caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001517:
<<<<<<< HEAD
version "1.0.30001519"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001519.tgz#3e7b8b8a7077e78b0eb054d69e6edf5c7df35601"
integrity sha512-0QHgqR+Jv4bxHMp8kZ1Kn8CH55OikjKJ6JmKkZYP1F3D7w+lnFXF70nG5eNfsZS89jadi5Ywy5UCSKLAglIRkg==
=======
version "1.0.30001518"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001518.tgz#b3ca93904cb4699c01218246c4d77a71dbe97150"
integrity sha512-rup09/e3I0BKjncL+FesTayKtPrdwKhUufQFd3riFw1hHg8JmIFoInYfB102cFcY/pPgGmdyl/iy+jgiDi2vdA==

canvas-confetti@^1.6.0:
version "1.6.0"
resolved "https://registry.yarnpkg.com/canvas-confetti/-/canvas-confetti-1.6.0.tgz#193f71aa8f38fc850a5ba94f59091a7afdb43ead"
integrity sha512-ej+w/m8Jzpv9Z7W7uJZer14Ke8P2ogsjg4ZMGIuq4iqUOqY2Jq8BNW42iGmNfRwREaaEfFIczLuZZiEVSYNHAA==
>>>>>>> 885c51b (Hide Tabs for Hidden Children)

caseless@~0.12.0:
version "0.12.0"
Expand Down Expand Up @@ -1137,9 +1154,15 @@ [email protected]:
integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==

electron-to-chromium@^1.4.477:
<<<<<<< HEAD
version "1.4.482"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.482.tgz#77c5ed37b93d4dda860e27538e0e2a01d6a19e02"
integrity sha512-h+UqpfmEr1Qkk0zp7ej/jid7CXoq4m4QzW6wNTb0ELJ/BZCpA4wgUylBIMGCe621tnr4l5VmoHjdoSx2lbnNJA==
=======
version "1.4.480"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.480.tgz#40e32849ca50bc23ce29c1516c5adb3fddac919d"
integrity sha512-IXTgg+bITkQv/FLP9FjX6f9KFCs5hQWeh5uNSKxB9mqYj/JXhHDbu+ekS43LVvbkL3eW6/oZy4+r9Om6lan1Uw==
>>>>>>> 885c51b (Hide Tabs for Hidden Children)

[email protected]:
version "1.1.2"
Expand Down Expand Up @@ -2443,9 +2466,15 @@ msgpackr-extract@^3.0.2:
"@msgpackr-extract/msgpackr-extract-win32-x64" "3.0.2"

msgpackr@^1.5.2:
<<<<<<< HEAD
version "1.9.6"
resolved "https://registry.yarnpkg.com/msgpackr/-/msgpackr-1.9.6.tgz#0b2bd37fba705756df795fdfe06a55f447c7bc47"
integrity sha512-50rmb6+ZWvEm0vJn8R8CwI1Eavss3h5rgtKrcdUal3EkZcpqw82+xsmc7RoHb8fYB5V4EOU2NDaOitDAdO0t+w==
=======
version "1.9.5"
resolved "https://registry.yarnpkg.com/msgpackr/-/msgpackr-1.9.5.tgz#ac548c5f4546db895e84e46d39d813be961dc527"
integrity sha512-/IJ3cFSN6Ci3eG2wLhbFEL6GT63yEaoN/R5My2QkV6zro+OJaVRLPlwvxY7EtHYSmDlQpk8stvOQTL2qJFkDRg==
>>>>>>> 885c51b (Hide Tabs for Hidden Children)
optionalDependencies:
msgpackr-extract "^3.0.2"

Expand Down Expand Up @@ -3353,6 +3382,16 @@ [email protected]:
uuid "8.3.2"
vuvuzela "1.0.3"

prism-svelte@^0.5.0:
version "0.5.0"
resolved "https://registry.yarnpkg.com/prism-svelte/-/prism-svelte-0.5.0.tgz#c4aeffeaddb179cfef213aab91ee785b66d22992"
integrity sha512-db91Bf3pRGKDPz1lAqLFSJXeW13mulUJxhycysFpfXV5MIK7RgWWK2E5aPAa71s8TCzQUXxF5JOV42/iOs6QkA==

prismjs@^1.29.0:
version "1.29.0"
resolved "https://registry.yarnpkg.com/prismjs/-/prismjs-1.29.0.tgz#f113555a8fa9b57c35e637bba27509dcf802dd12"
integrity sha512-Kx/1w86q/epKcmte75LNrEoT+lX8pBpavuAbvJWRXar7Hz8jrtF+e3vY751p0R8H9HdArwaCTNDDzHg/ScJK1Q==

process-nextick-args@~2.0.0:
version "2.0.1"
resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2"
Expand Down Expand Up @@ -4097,6 +4136,15 @@ supports-preserve-symlinks-flag@^1.0.0:
resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09"
integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==

svelte-legos@^0.2.1:
version "0.2.1"
resolved "https://registry.yarnpkg.com/svelte-legos/-/svelte-legos-0.2.1.tgz#93923ce34fb6ef1bc065502407fc93561b36453a"
integrity sha512-M7IncWP2e8FaHzQN1DSzxLSoq/6aQYWZ93REZam9bYlvLEjdPGWLAYdpPNnnZtXlHco+o3zrgYTdwsyyS9beUQ==
dependencies:
canvas-confetti "^1.6.0"
prism-svelte "^0.5.0"
prismjs "^1.29.0"

svelte@^3.49.0:
version "3.59.2"
resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.59.2.tgz#a137b28e025a181292b2ae2e3dca90bf8ec73aec"
Expand Down

0 comments on commit 78b5d10

Please sign in to comment.