Skip to content
Merged

Deploy #1769

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 13 additions & 3 deletions apps/frontend/components/character-table/CharacterTableHead.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
<script lang="ts">
import type { Snippet } from 'svelte';

import { settingsState } from '@/shared/state/settings.svelte';
import type { ChildrenProp } from '@/types/props';

type Props = ChildrenProp & {
headText?: Snippet;
headTop?: Snippet<[number]>;
};
let { children, headText, headTop }: Props = $props();

let commonFields = $derived(settingsState.value.views[0].commonFields);
let colspan = $derived(
Expand All @@ -17,12 +26,13 @@
</style>

<thead>
<slot name="headTop" {colspan}></slot>
{@render headTop?.(colspan)}

<tr>
<th class="head-text" {colspan}>
<slot name="headText" />
{@render headText?.()}
</th>

<slot />
{@render children?.()}
</tr>
</thead>
5 changes: 2 additions & 3 deletions apps/frontend/components/collectible/CollectibleCount.svelte
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
<script lang="ts">
import type { Snippet } from 'svelte';

import type { UserCount } from '@/types';
import type { ChildrenProp } from '@/types/props';

let { children, counts }: { children?: Snippet; counts: UserCount } = $props();
let { children, counts }: ChildrenProp & { counts: UserCount } = $props();

let have = $derived(counts?.have ?? '??');
let total = $derived(counts?.total ?? '??');
Expand Down
16 changes: 8 additions & 8 deletions apps/frontend/components/common/TableIcon.svelte
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<script lang="ts">
export let padLeft = 'unset';
export let padRight = 'unset';
import type { ChildrenProp } from '@/types/props';

$: {
padLeft = padLeft ?? 'unset';
padRight = padRight ?? 'unset';
}
type Props = ChildrenProp & {
padLeft?: string;
padRight?: string;
};
let { children, padLeft, padRight }: Props = $props();
</script>

<style lang="scss">
Expand All @@ -16,6 +16,6 @@
}
</style>

<td style="--padding-left:{padLeft};--padding-right:{padRight};">
<slot />
<td style:--padding-left={padLeft} style:--padding-right={padRight}>
{@render children?.()}
</td>
4 changes: 2 additions & 2 deletions apps/frontend/components/items/convertible/ClassTable.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
{#if data}
<CharacterTable characterLimit={hasEverySlot ? 1 : 0} skipGrouping={true} {filterFunc}>
<CharacterTableHead slot="head">
<svelte:fragment slot="headText">
{#snippet headText()}
<div class="flex-wrapper">
<span class="difficulty-text">
{#if modifier === AppearanceModifier.LookingForRaid}
Expand All @@ -85,7 +85,7 @@
{stats.percent.toFixed(0)} %
</span>
</div>
</svelte:fragment>
{/snippet}

{#each convertibleTypes as inventoryType (inventoryType)}
<th class="item-slot">
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/components/journal/JournalItem.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@
</div>
{/if}

{#if [BindType.NotBound, BindType.OnEquip].includes(dataItem.bindType)}
{#if [BindType.NotBound, BindType.OnEquip].includes(dataItem.bindType) && !dataItem.boundToAccount}
<div
class="overlay buyable iconify-icon drop-shadow"
class:status-success={appearance.userHas}
Expand Down
8 changes: 4 additions & 4 deletions apps/frontend/components/lockouts/Lockouts.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@

<CharacterTable skipGrouping={true} skipIgnored={true} {filterFunc} {sortFunc}>
<CharacterTableHead slot="head">
<svelte:fragment slot="headText">
{#snippet headText()}
<CheckboxInput
name="lockouts_grouped"
bind:value={browserState.current.lockouts.grouped}>Grouped</CheckboxInput
Expand All @@ -88,13 +88,13 @@
bind:value={browserState.current.lockouts.onlyWithLockout}
>ONLY characters with lockout</CheckboxInput
>
</svelte:fragment>
{/snippet}

<svelte:fragment slot="headTop" let:colspan>
{#snippet headTop(colspan)}
{#if browserState.current.lockouts.grouped}
<GroupedHead {colspan} {groupedLockouts} />
{/if}
</svelte:fragment>
{/snippet}

{#each allLockouts as instanceDifficulty, index (instanceDifficulty)}
<HeadInstance
Expand Down
4 changes: 2 additions & 2 deletions apps/frontend/components/professions/overview/Table.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@
{#if profession}
<CharacterTable {filterFunc} {sortFunc}>
<CharacterTableHead slot="head">
<svelte:fragment slot="headText">
{#snippet headText()}
<WowthingImage name={imageStrings[profession.slug]} size={20} border={1} />
{profession.name.split('|')[0]}
</svelte:fragment>
{/snippet}

{#if profession.slug === 'archaeology'}
<th class="profession-head">Ugh</th>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,10 @@
{#if profession}
<CharacterTable {filterFunc} showEmpty={false}>
<CharacterTableHead slot="head">
<svelte:fragment slot="headText">
{#snippet headText()}
<WowthingImage name={imageStrings[profession.slug]} size={20} border={1} />
{profession.name.split('|')[0]}
</svelte:fragment>
{/snippet}

<th>
<div class="header">
Expand Down
8 changes: 7 additions & 1 deletion apps/frontend/data/holidays.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export const holidayIds: Record<number, [number[], number[]?]> = {
[Holiday.Brewfest]: [[19]],
[Holiday.ChildrensWeek]: [[13]],
[Holiday.DarkmoonFaire]: [[1]],
[Holiday.DarkspearDash]: [[458]],
[Holiday.DayOfTheDead]: [[81]],
[Holiday.HallowsEnd]: [[16]],
[Holiday.LoveIsInTheAir]: [[9]],
Expand Down Expand Up @@ -117,6 +118,11 @@ export const fancyHolidays: FancyHoliday[] = [
shortName: '🎡',
everything: 'darkmoon-faire',
},
{
holiday: Holiday.DarkspearDash,
shortName: '🧌',
everything: 'darkspear-dash',
},
{
holiday: Holiday.DayOfTheDead,
shortName: '💀',
Expand All @@ -139,7 +145,7 @@ export const fancyHolidays: FancyHoliday[] = [
},
{
holiday: Holiday.MidsummerFireFestival,
shortName: 'Midsummer',
shortName: '🌞',
everything: 'midsummer-fire-festival',
},
{
Expand Down
1 change: 1 addition & 0 deletions apps/frontend/enums/holiday.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ export enum Holiday {
Brewfest,
ChildrensWeek,
DarkmoonFaire,
DarkspearDash,
DayOfTheDead,
HallowsEnd,
LoveIsInTheAir,
Expand Down
18 changes: 10 additions & 8 deletions apps/frontend/enums/item-flags.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
/* prettier-ignore */
export enum ItemFlags {
Cosmetic = 0b00_00_00_01,
CannotTransmogToThisItem = 0b00_00_00_10,
AllianceOnly = 0b00_00_01_00,
HordeOnly = 0b00_00_10_00,
LookingForRaidDifficulty = 0b00_01_00_00,
HeroicDifficulty = 0b00_10_00_00,
MythicDifficulty = 0b01_00_00_00,
Openable = 0b10_00_00_00,
Cosmetic = 0b0000_0000_0000_0001,
CannotTransmogToThisItem = 0b0000_0000_0000_0010,
AllianceOnly = 0b0000_0000_0000_0100,
HordeOnly = 0b0000_0000_0000_1000,
LookingForRaidDifficulty = 0b0000_0000_0001_0000,
HeroicDifficulty = 0b0000_0000_0010_0000,
MythicDifficulty = 0b0000_0000_0100_0000,
Openable = 0b0000_0000_1000_0000,
BoundToAccount = 0b0000_0001_0000_0000,
}
7 changes: 3 additions & 4 deletions apps/frontend/shared/components/GenericTooltip.svelte
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
<script lang="ts">
import type { Snippet } from 'svelte';
import type { ChildrenProp } from '@/types/props';

import ParsedText from './parsed-text/ParsedText.svelte';

type Props = {
children: Snippet;
type Props = ChildrenProp & {
subTitle: string;
title: string;
};
Expand All @@ -24,7 +23,7 @@

<table>
<tbody>
{@render children()}
{@render children?.()}
</tbody>
</table>
</div>
6 changes: 2 additions & 4 deletions apps/frontend/shared/components/forms/CheckboxInput.svelte
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
<script lang="ts">
import type { Snippet } from 'svelte';

import { iconLibrary } from '@/shared/icons';
import type { ChildrenProp } from '@/types/props';

import IconifyWrapper from '@/shared/components/images/IconifyWrapper.svelte';

type Props = {
type Props = ChildrenProp & {
name: string;
value?: boolean;
children?: Snippet;
disabled?: boolean;
onChange?: (newValue: boolean) => void;
textClass?: string;
Expand Down
7 changes: 3 additions & 4 deletions apps/frontend/shared/components/links/SpellLink.svelte
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
<script lang="ts">
import type { Snippet } from 'svelte';
import type { ChildrenProp } from '@/types/props';

import { settingsState } from '@/shared/state/settings.svelte';

type Props = {
children: Snippet;
type Props = ChildrenProp & {
id: number;
itemLevel?: number;
};
Expand All @@ -25,5 +24,5 @@
</script>

<a href={url}>
{@render children()}
{@render children?.()}
</a>
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
<script lang="ts">
import type { Snippet } from 'svelte';
import type { ChildrenProp } from '@/types/props';

import { settingsState } from '@/shared/state/settings.svelte';

type Props = {
children?: Snippet;
type Props = ChildrenProp & {
cls?: string;
id: number;
};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
<script lang="ts"></script>
<script lang="ts">
import type { ChildrenProp } from '@/types/props';

let { children }: ChildrenProp = $props();
</script>

<style lang="scss">
.under-construction {
Expand All @@ -8,7 +12,9 @@
</style>

<div class="under-construction thing-container bg-fail border">
<slot>
{#if children}
{@render children()}
{:else}
This area is under construction and probably doesn't work very well, please be patient!
</slot>
{/if}
</div>
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export enum DbThingContentType {
Item = 1,
Pet = 2,
Title = 3,
}
3 changes: 3 additions & 0 deletions apps/frontend/types/data/item/item.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ export class ItemDataItem {
return this._appearances;
}

get boundToAccount(): boolean {
return (this.flags & ItemFlags.BoundToAccount) > 0;
}
get cosmetic(): boolean {
return (this.flags & ItemFlags.Cosmetic) > 0;
}
Expand Down
6 changes: 6 additions & 0 deletions apps/frontend/types/props.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
import type { Snippet } from 'svelte';

import type { Character } from './character';

export type CharacterProps = {
character: Character;
};

export type ChildrenProp = {
children?: Snippet;
};

export type SlugsProps = {
slug1: string;
slug2?: string;
Expand Down
5 changes: 5 additions & 0 deletions apps/frontend/user-home/components/everything/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ export const everythingData: Record<string, EverythingData> = {
achievementsKey: ['world-events', 'darkmoon-faire'],
vendorsKey: ['world-events', 'darkmoon-faire'],
},
'darkspear-dash': {
name: 'Darkspear Dash',
tag: 'event:darkspear-dash',
vendorsKey: ['world-events', 'darkspear-dash'],
},
'day-of-the-dead': {
name: 'Day of the Dead',
tag: 'event:day-of-the-dead',
Expand Down
18 changes: 18 additions & 0 deletions apps/tool/Data/ExtraEncounters.cs
Original file line number Diff line number Diff line change
Expand Up @@ -368,5 +368,23 @@ public static partial class Hardcoded
}
},
#endregion Legion

#region Midnight
// Midnight > Midnight (world bosses)
{
1312,
new[]
{
new ExtraEncounter("Nexus Captain Leth'ir")
{
AfterEncounter = 2782, // Cragpine
},
new ExtraEncounter("Imperator Pertinax")
{
AfterEncounter = 2782, // Cragpine
},
}
},
#endregion Midnight
};
}
Loading
Loading