Skip to content

Commit 16eb142

Browse files
committed
feat: add new improvements
1 parent 9804a70 commit 16eb142

File tree

57 files changed

+2245
-927
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+2245
-927
lines changed

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<meta charset="UTF-8" />
55
<meta
66
http-equiv="Content-Security-Policy"
7-
content="default-src 'self' https://raw.githubusercontent.com data:; style-src 'self' 'unsafe-inline'; script-src 'self'"
7+
content="default-src 'self' https://raw.githubusercontent.com https://stwcdn.com data:; style-src 'self' 'unsafe-inline'; script-src 'self'"
88
/>
99
<title>Aerial Launcher</title>
1010
</head>

package-lock.json

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
"immer": "^10.1.1",
6969
"just-random": "^3.2.0",
7070
"lucide-react": "^0.372.0",
71+
"modern-screenshot": "^4.6.0",
7172
"next-themes": "^0.3.0",
7273
"node-schedule": "^2.1.1",
7374
"react": "^18.3.1",

src/components/go-to-top.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export const GoToTop = memo(({ containerId }: GoToTopProps) => {
2020
return (
2121
<Button
2222
className={cn(
23-
'bottom-5 fixed opacity-0 px-4 right-5 transition-all translate-x-28 z-10',
23+
'bottom-5 fixed opacity-0 px-4 right-5 transition-all translate-x-28 z-30',
2424
{
2525
'opacity-100 translate-x-0': scrollToTopButtonIsVisible,
2626
}

src/components/menu/sidebar.tsx

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,12 @@ export function SidebarMenu({
5757
const goToPage = () => {
5858
onOpenChange?.(false)
5959
}
60+
const gotToPage: MouseEventHandler<HTMLButtonElement> = (event) => {
61+
event.preventDefault()
62+
window.electronAPI.openExternalURL(
63+
(event.currentTarget as unknown as HTMLAnchorElement).href
64+
)
65+
}
6066
const goToDiscordServerURL: MouseEventHandler<HTMLButtonElement> = (
6167
event
6268
) => {
@@ -215,6 +221,21 @@ export function SidebarMenu({
215221
</Link>
216222
</li>
217223
)}
224+
{getMenuOptionVisibility('unlock') && (
225+
<li className="item">
226+
<Link
227+
to="/stw-operations/unlock"
228+
className={currentClassNameHover}
229+
activeProps={{
230+
className: cn(activeClassName),
231+
}}
232+
onClick={goToPage}
233+
onAuxClick={whatIsThis()}
234+
>
235+
{t('stw-operations.options.unlock')}
236+
</Link>
237+
</li>
238+
)}
218239
</ul>
219240
</div>
220241
</>
@@ -489,6 +510,68 @@ export function SidebarMenu({
489510
)}
490511

491512
<div>
513+
<Button
514+
className={cn(
515+
'flex items-center gap-3 justify-center px-3 py-2 rounded-lg transition-all w-full',
516+
'text-muted-foreground',
517+
'hover:bg-muted hover:text-primary'
518+
)}
519+
size="sm"
520+
variant="ghost"
521+
onClick={gotToPage}
522+
onAuxClick={whatIsThis()}
523+
asChild
524+
>
525+
<a href="https://ko-fi.com/ciensprog">
526+
<img
527+
src="https://stwcdn.com/ko-fi.webp"
528+
className="flex-shrink-0 h-5"
529+
alt="icon"
530+
/>
531+
</a>
532+
</Button>
533+
<Button
534+
className={cn(
535+
'flex items-center gap-3 justify-start px-3 py-2 rounded-lg transition-all w-full',
536+
'text-muted-foreground',
537+
'hover:bg-muted hover:text-primary'
538+
)}
539+
size="sm"
540+
variant="ghost"
541+
onClick={gotToPage}
542+
onAuxClick={whatIsThis()}
543+
asChild
544+
>
545+
<a href="https://stw.news/">
546+
<img
547+
src="https://stwcdn.com/aerial-stwnews.webp"
548+
className="flex-shrink-0 -ml-0.5 size-5"
549+
alt="icon"
550+
/>
551+
<span className="-ml-1">STW News</span>
552+
</a>
553+
</Button>
554+
<Button
555+
className={cn(
556+
'flex items-center gap-3 justify-start px-3 py-2 rounded-lg transition-all w-full',
557+
'text-muted-foreground',
558+
'hover:bg-muted hover:text-primary'
559+
)}
560+
size="sm"
561+
variant="ghost"
562+
onClick={gotToPage}
563+
onAuxClick={whatIsThis()}
564+
asChild
565+
>
566+
<a href="https://discord.gg/XbGSTuXZdy">
567+
<img
568+
src="https://stwcdn.com/aerial-ml-corp.webp"
569+
className="flex-shrink-0 -ml-0.5 size-5"
570+
alt="icon"
571+
/>
572+
<span className="-ml-1">ML Corp</span>
573+
</a>
574+
</Button>
492575
<Button
493576
className={cn(
494577
'flex items-center gap-3 justify-start px-3 py-2 rounded-lg transition-all w-full',

src/config/constants/alerts/filters.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,11 @@ export const missionTypeOptions: Array<
125125
label: 'Repair The Shelter',
126126
value: 'rts',
127127
},
128+
{
129+
icon: imgWorld('htm.png'),
130+
label: 'Hunt The Titan',
131+
value: 'htm',
132+
},
128133
]
129134

130135
export const rarityOptions: Array<FilterOption<RarityType>> = [
@@ -166,6 +171,16 @@ export const rewardOptions: Array<FilterOption> = [
166171
label: 'Survivors',
167172
value: 'Worker',
168173
},
174+
{
175+
icon: imgResources('voucher_generic_manager.png'),
176+
label: 'Lead Survivors',
177+
value: 'Manager',
178+
},
179+
{
180+
icon: imgResources('voucher_generic_defender.png'),
181+
label: 'Defenders',
182+
value: 'Defender',
183+
},
169184
{
170185
icon: imgResources('voucher_generic_hero.png'),
171186
label: 'Heroes',

src/config/constants/fortnite/world-info.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,9 +179,19 @@ export const zonesCategories = {
179179
'StabilizeTheRift',
180180
'StC',
181181
'StormQuest2018Landmark',
182-
'TestTheSuit',
183182
'VindermanMansion',
184183
'WatchTheSkies',
184+
185+
// Blockbuster
186+
'TestTheSuit',
187+
188+
// Ventures related
189+
'FinalFrontier',
190+
'FinalRehearsal',
191+
192+
// Pirate season related (EventFlag.Phoenix.Adventure)
193+
'AdventureRevenge',
194+
'Yarrr',
185195
],
186196
atlas: ['1Gate', 'Cat1FtS', 'GateSingle'],
187197
'atlas-c2': ['2Gates'],

src/config/constants/main-process.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,9 @@ export enum ElectronAPIEventKeys {
125125
XPBoostsConsumeTeammateNotification = 'xpboosts:consume:teammate:notification',
126126
XPBoostsConsumeTeammateProgressionNotification = 'xpboosts:consume:teammate:progression:notification',
127127

128+
UnlockRequest = 'unlock:request',
129+
UnlockNotification = 'unlock:notification',
130+
128131
/**
129132
* Party
130133
*/

src/config/fortnite/links.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@ export function epicGamesAccountSettingsURL(exchangeCode: string) {
77
return `https://www.epicgames.com/id/exchange?exchangeCode=${exchangeCode}`
88
}
99

10-
export function fortniteDBProfileURL(displayName: string) {
11-
return `https://fortnitedb.com/profile/${displayName}`
10+
export function stwNewsProfileURL(displayName: string) {
11+
return `https://stw.news/${displayName}`
1212
}

src/hooks/alerts/filters.ts

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ export function useAlertsOverviewFiltersData() {
1414
rarities,
1515
rewards,
1616
zones,
17+
group,
1718
changeInputSearch,
1819
} = useAlertsOverviewFiltersStore(
1920
useShallow((state) => ({
@@ -22,6 +23,7 @@ export function useAlertsOverviewFiltersData() {
2223
missionTypes: state.missionTypes,
2324
rarities: state.rarities,
2425
rewards: state.rewards,
26+
group: state.group,
2527

2628
changeInputSearch: state.changeInputSearch,
2729
}))
@@ -33,28 +35,32 @@ export function useAlertsOverviewFiltersData() {
3335
rarities,
3436
rewards,
3537
zones,
38+
group,
3639

3740
changeInputSearch,
3841
}
3942
}
4043

4144
export function useAlertsOverviewFiltersActions() {
4245
const { initPagination } = useAlertsOverviewPaginationInit()
43-
const { resetFilters, toggleFilterKeys } = useAlertsOverviewFiltersStore(
44-
useShallow((state) => ({
45-
resetFilters: () => {
46-
initPagination([])
47-
state.resetFilters()
48-
},
49-
toggleFilterKeys: (keys: FilterKeys) => (ids: Array<string>) => {
50-
initPagination([])
51-
state.toggleFilterKeys(keys)(ids)
52-
},
53-
}))
54-
)
46+
const { resetFilters, toggleFilterKeys, toggleGroup } =
47+
useAlertsOverviewFiltersStore(
48+
useShallow((state) => ({
49+
resetFilters: () => {
50+
initPagination([])
51+
state.resetFilters()
52+
},
53+
toggleFilterKeys: (keys: FilterKeys) => (ids: Array<string>) => {
54+
initPagination([])
55+
state.toggleFilterKeys(keys)(ids)
56+
},
57+
toggleGroup: state.toggleGroup,
58+
}))
59+
)
5560

5661
return {
5762
resetFilters,
5863
toggleFilterKeys,
64+
toggleGroup,
5965
}
6066
}

0 commit comments

Comments
 (0)