aboutsummaryrefslogtreecommitdiff
path: root/src/lib/sections
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/sections')
-rw-r--r--src/lib/sections/Armor.svelte4
-rw-r--r--src/lib/sections/Collections.svelte8
-rw-r--r--src/lib/sections/Inventories.svelte47
3 files changed, 46 insertions, 13 deletions
diff --git a/src/lib/sections/Armor.svelte b/src/lib/sections/Armor.svelte
index 655de31..285a898 100644
--- a/src/lib/sections/Armor.svelte
+++ b/src/lib/sections/Armor.svelte
@@ -1,8 +1,10 @@
<script lang="ts">
import type { CleanMemberProfile } from '$lib/APITypes'
import Inventory from '$lib/minecraft/Inventory.svelte'
+ import type { MatcherFile } from 'skyblock-assets'
+
export let data: CleanMemberProfile
- export let pack
+ export let pack: MatcherFile
</script>
{#if data.member.inventories}
diff --git a/src/lib/sections/Collections.svelte b/src/lib/sections/Collections.svelte
index 9624ec2..7ca1969 100644
--- a/src/lib/sections/Collections.svelte
+++ b/src/lib/sections/Collections.svelte
@@ -1,9 +1,10 @@
<script lang="ts">
+ import furfskyReborn from 'skyblock-assets/matchers/furfsky_reborn.json'
import type { CleanMemberProfile, Collection } from '$lib/APITypes'
import { skyblockItemToUrl } from '$lib/minecraft/inventory'
import ListItemWithIcon from '$lib/ListItemWithIcon.svelte'
- import { cleanId } from '$lib/utils'
import Tooltip from '$lib/Tooltip.svelte'
+ import { cleanId } from '$lib/utils'
export let data: CleanMemberProfile
@@ -21,7 +22,10 @@
<h3>{cleanId(categoryName)}</h3>
<ul>
{#each collections as collection}
- <ListItemWithIcon url={skyblockItemToUrl(collection.name)} alt={cleanId(collection.name)}>
+ <ListItemWithIcon
+ url={skyblockItemToUrl(collection.name, furfskyReborn)}
+ alt={cleanId(collection.name)}
+ >
<Tooltip>
<span slot="tooltip">
Amount: {collection.xp.toLocaleString()}
diff --git a/src/lib/sections/Inventories.svelte b/src/lib/sections/Inventories.svelte
index 8be6853..9001430 100644
--- a/src/lib/sections/Inventories.svelte
+++ b/src/lib/sections/Inventories.svelte
@@ -1,11 +1,11 @@
<script lang="ts">
+ import { skyblockItemToUrl, type Item } from '$lib/minecraft/inventory'
import Inventory from '$lib/minecraft/Inventory.svelte'
- import { fade } from 'svelte/transition'
+ import type { MatcherFile } from 'skyblock-assets'
import { cleanId } from '$lib/utils'
- import { skyblockItemToUrl, type Item } from '$lib/minecraft/inventory'
export let data
- export let pack
+ export let pack: MatcherFile
let displayingInventories: string[] = []
for (const inventoryName in data.member.inventories)
@@ -19,11 +19,38 @@
vanillaId: 'nether_star',
display: { name: 'SkyBlock Menu' },
},
- ender_chest: 'ender_chest',
- potion_bag: 'potion',
- fishing_bag: 'fishing_rod',
- quiver: 'arrow',
- wardrobe: 'leather_chestplate',
+ ender_chest: {
+ vanillaId: 'ender_chest',
+ display: { name: '\\u00a7aEnder Chest' },
+ },
+ talisman_bag: {
+ vanillaId: 'skull:3',
+ display: { name: 'Accessory Bag' },
+ head_texture: '961a918c0c49ba8d053e522cb91abc74689367b4d8aa06bfc1ba9154730985ff',
+ },
+ potion_bag: {
+ vanillaId: 'skull:3',
+ display: { name: 'Potion Bag' },
+ head_texture: '9f8b82427b260d0a61e6483fc3b2c35a585851e08a9a9df372548b4168cc817c',
+ },
+ fishing_bag: {
+ vanillaId: 'skull:3',
+ display: { name: 'Fishing Bag' },
+ head_texture: 'eb8e297df6b8dffcf135dba84ec792d420ad8ecb458d144288572a84603b1631',
+ },
+ quiver: {
+ vanillaId: 'skull:3',
+ display: {
+ name: 'Quiver',
+ },
+ head_texture: '4cb3acdc11ca747bf710e59f4c8e9b3d949fdd364c6869831ca878f0763d1787',
+ },
+ wardrobe: {
+ vanillaId: 'leather_chestplate',
+ display: {
+ name: '\\u00a7aWardrobe',
+ },
+ },
}
</script>
@@ -38,7 +65,7 @@
<img
class="inventory-tab-icon"
loading="lazy"
- src={skyblockItemToUrl(inventoryIconMap[inventoryName])}
+ src={skyblockItemToUrl(inventoryIconMap[inventoryName], pack)}
alt={cleanId(inventoryName)}
/>
{/if}
@@ -68,7 +95,7 @@
color: var(--theme-main-text);
border: none;
border-radius: 0;
- /* padding: 0.8em; */
+ padding: 0 0.5em;
cursor: pointer;
transition-duration: 200ms;
height: 2.5em;