Skip to content
Merged
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
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 1.0.1

- The banners above the server console and the dashboard now have a 12px gap below them, the same as Connect Buttons, Custom Links and Next Wipe.

## 1.0.0

- First release.
2 changes: 1 addition & 1 deletion extension.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"$schema": "./node_modules/@pterodactyl/sdk/manifest.schema.json",
"id": "announcements",
"name": "Announcements",
"version": "1.0.0",
"version": "1.0.1",
"description": "Show scheduled announcements to everyone, or only to servers on chosen nodes, locations or eggs.",
"author": "RustixDev",
"icon": "megaphone",
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "announcements",
"private": true,
"version": "1.0.0",
"version": "1.0.1",
"type": "module",
"scripts": {
"build": "vite build",
Expand Down
8 changes: 8 additions & 0 deletions src/client/announcements.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,14 @@ test('the server banner reads the server announcements query', async () => {
expect(await screen.findByText('Egg update')).toBeTruthy();
});

test('the banner block has 12px below it and no top margin, like the other console rows', async () => {
render(<AnnouncementList items={[announcement()]} />, { wrapper: host.Wrapper });

const block = (await screen.findByText('Dismiss')).closest('div.rxan\\:flex-col')!;
expect(block.className).toContain('rxan:mb-3');
expect(block.className).toContain('rxan:mt-0');
});

test('datetime-local values round-trip through ISO', () => {
const iso = fromLocalInput('2026-11-05T14:30');
expect(iso).not.toBeNull();
Expand Down
2 changes: 1 addition & 1 deletion src/client/components/AnnouncementList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export default function AnnouncementList({ items }: { items: Announcement[] }) {
};

return (
<div className={'rxan:mb-4 rxan:flex rxan:flex-col rxan:gap-2'}>
<div className={'rxan:mt-0 rxan:mb-3 rxan:flex rxan:flex-col rxan:gap-2'}>
{visible.map((a) => (
<Alert key={a.id} type={a.level} title={a.title}>
<div className={'rxan:flex rxan:items-start rxan:justify-between rxan:gap-4'}>
Expand Down
Loading