diff --git a/app/Console/Commands/Translations/CoverageCommand.php b/app/Console/Commands/Translations/CoverageCommand.php
index f0b2e2ee0..5de8ecd26 100644
--- a/app/Console/Commands/Translations/CoverageCommand.php
+++ b/app/Console/Commands/Translations/CoverageCommand.php
@@ -56,6 +56,7 @@ class CoverageCommand extends Command
$this->components->info(sprintf('%s%s: %d of %d keys translated (%s%%).', $locale, $pack instanceof ExtensionManifest ? " ({$pack->id})" : '', $report['translated'], $report['total'], $percentage));
$this->section('Missing', $report['missing']);
+ $this->section('Same as English', $report['unchanged']);
$this->section('Not strings', $report['invalid']);
$this->section('Placeholders English does not have', $this->describe($report['unknown_placeholders']));
$this->section('Placeholders left out', $this->describe($report['dropped_placeholders']));
diff --git a/app/Http/Controllers/Api/Client/AccountController.php b/app/Http/Controllers/Api/Client/AccountController.php
index c39e4267a..38f72dbf1 100644
--- a/app/Http/Controllers/Api/Client/AccountController.php
+++ b/app/Http/Controllers/Api/Client/AccountController.php
@@ -101,7 +101,7 @@ class AccountController extends ClientApiController
if ($original !== $user->language) {
Activity::event('user:account.language-changed')
->subject($user)
- ->property(['old' => $original ?? 'default', 'new' => $user->language ?? 'default'])
+ ->property(['old' => $original, 'new' => $user->language])
->log();
}
diff --git a/app/Http/Controllers/Api/Client/Servers/StartupController.php b/app/Http/Controllers/Api/Client/Servers/StartupController.php
index 7c6e3d4d8..4cb41e6e8 100644
--- a/app/Http/Controllers/Api/Client/Servers/StartupController.php
+++ b/app/Http/Controllers/Api/Client/Servers/StartupController.php
@@ -60,7 +60,7 @@ class StartupController extends ClientApiController
public function update(UpdateStartupVariableRequest $request, UpdatesServerVariable $variables, Server $server): EggVariableResource
{
$variable = $request->variable();
- throw_if(! $variable instanceof EggVariable || ! $variable->user_viewable, BadRequestHttpException::class, 'The environment variable you are trying to edit does not exist.');
+ throw_if(! $variable instanceof EggVariable || ! $variable->user_viewable, BadRequestHttpException::class, __('exceptions.server.variable_not_found'));
throw_unless($variable->user_editable, BadRequestHttpException::class, __('exceptions.server.variable_read_only'));
diff --git a/app/Http/Middleware/Api/Admin/RequireSessionAuthentication.php b/app/Http/Middleware/Api/Admin/RequireSessionAuthentication.php
index 14dd78494..189ffd319 100644
--- a/app/Http/Middleware/Api/Admin/RequireSessionAuthentication.php
+++ b/app/Http/Middleware/Api/Admin/RequireSessionAuthentication.php
@@ -22,7 +22,7 @@ class RequireSessionAuthentication
{
$token = $request->user()?->currentAccessToken();
- throw_unless($token instanceof TransientToken, AccessDeniedHttpException::class, 'This action can only be performed from an authenticated panel session, not with an API key.');
+ throw_unless($token instanceof TransientToken, AccessDeniedHttpException::class, __('exceptions.api.session_required'));
return $next($request);
}
diff --git a/app/Http/Requests/Api/Application/Servers/StoreServerRequest.php b/app/Http/Requests/Api/Application/Servers/StoreServerRequest.php
index 57bfef6cb..218c7e342 100644
--- a/app/Http/Requests/Api/Application/Servers/StoreServerRequest.php
+++ b/app/Http/Requests/Api/Application/Servers/StoreServerRequest.php
@@ -153,7 +153,7 @@ class StoreServerRequest extends ApplicationApiRequest
private function validateDeployTagReference(string $attribute, mixed $value, Closure $fail): void
{
if (! is_int($value) && ! is_string($value)) {
- $fail("The {$attribute} field must be a tag ID or slug.");
+ $fail(__('validation.internal.tag_reference'));
}
}
}
diff --git a/app/Http/Requests/Api/Client/Servers/Schedules/ViewScheduleRequest.php b/app/Http/Requests/Api/Client/Servers/Schedules/ViewScheduleRequest.php
index 1f9a76be5..5c7a757ad 100644
--- a/app/Http/Requests/Api/Client/Servers/Schedules/ViewScheduleRequest.php
+++ b/app/Http/Requests/Api/Client/Servers/Schedules/ViewScheduleRequest.php
@@ -34,7 +34,7 @@ class ViewScheduleRequest extends ClientApiRequest implements ClientPermissionsR
// error if the task being requested does not belong to the associated schedule.
if ($schedule instanceof Schedule) {
$task = $route->parameter('task');
- throw_if($schedule->server_id !== $server->id || ($task instanceof Task && $task->schedule_id !== $schedule->id), NotFoundHttpException::class, 'The requested resource does not exist on the system.');
+ throw_if($schedule->server_id !== $server->id || ($task instanceof Task && $task->schedule_id !== $schedule->id), NotFoundHttpException::class, __('exceptions.api.resource_not_on_system'));
}
return true;
diff --git a/app/Http/Requests/Base/LocaleRequest.php b/app/Http/Requests/Base/LocaleRequest.php
index 67d1591ce..e287af63b 100644
--- a/app/Http/Requests/Base/LocaleRequest.php
+++ b/app/Http/Requests/Base/LocaleRequest.php
@@ -5,10 +5,11 @@ declare(strict_types=1);
namespace Pterodactyl\Http\Requests\Base;
use Illuminate\Foundation\Http\FormRequest;
+use Pterodactyl\Services\Extensions\ExtensionManifest;
class LocaleRequest extends FormRequest
{
- private const string LOCALE = '[a-z]{2}(?:_[A-Z]{2})?';
+ private const string LOCALE = ExtensionManifest::LOCALE_PATTERN;
private const string NAMESPACE = '(?:[a-z]{1,191}|ext-[a-z][a-z0-9-]{0,47}::[a-z][a-z0-9_-]{0,63})';
diff --git a/app/Http/Requests/Concerns/ValidatesNodeAcceptsEgg.php b/app/Http/Requests/Concerns/ValidatesNodeAcceptsEgg.php
index 36e0fa04c..75e7e585b 100644
--- a/app/Http/Requests/Concerns/ValidatesNodeAcceptsEgg.php
+++ b/app/Http/Requests/Concerns/ValidatesNodeAcceptsEgg.php
@@ -4,6 +4,7 @@ declare(strict_types=1);
namespace Pterodactyl\Http\Requests\Concerns;
+use Illuminate\Support\Str;
use Illuminate\Validation\Validator;
use Pterodactyl\Models\Egg;
use Pterodactyl\Models\Node;
@@ -22,12 +23,14 @@ trait ValidatesNodeAcceptsEgg
return;
}
- $tags = $node->eggTags->map(fn (Tag $tag): string => $tag->effectiveName())->implode(', ');
+ $replacements = [];
+ foreach (['node' => $node->name, 'tags' => $node->eggTags->map(fn (Tag $tag): string => $tag->effectiveName())->implode(', ')] as $key => $value) {
+ $replacements[':'.$key] = $value;
+ $replacements[':'.Str::ucfirst($key)] = Str::ucfirst($value);
+ $replacements[':'.Str::upper($key)] = Str::upper($value);
+ }
- $validator->addReplacer(
- 'node_accepts_egg',
- fn (string $message): string => str_replace([':node', ':tags'], [$node->name, $tags], $message),
- );
+ $validator->addReplacer('node_accepts_egg', fn (string $message): string => strtr($message, $replacements));
$validator->addFailure($field, 'NodeAcceptsEgg');
}
diff --git a/app/Http/Resources/Api/Concerns/FormatsActivityLogs.php b/app/Http/Resources/Api/Concerns/FormatsActivityLogs.php
index 671b3720f..263fc64ed 100644
--- a/app/Http/Resources/Api/Concerns/FormatsActivityLogs.php
+++ b/app/Http/Resources/Api/Concerns/FormatsActivityLogs.php
@@ -6,6 +6,7 @@ namespace Pterodactyl\Http\Resources\Api\Concerns;
use Illuminate\Support\Str;
use Pterodactyl\Models\ActivityLog;
+use Pterodactyl\Services\Translations\LanguageRegistry;
use stdClass;
trait FormatsActivityLogs
@@ -59,6 +60,10 @@ trait FormatsActivityLogs
return [$key => $value];
});
+ if ($model->event === 'user:account.language-changed') {
+ $properties = $properties->merge(array_map($this->languageLabel(...), $properties->only(['old', 'new'])->all()));
+ }
+
$keys = $properties->keys()->filter(fn (int|string $key): bool => Str::endsWith((string) $key, '_count'))->values();
if ($keys->containsOneItem()) {
$countKey = $keys->first();
@@ -98,4 +103,11 @@ trait FormatsActivityLogs
return false;
}
+
+ private function languageLabel(mixed $locale): string
+ {
+ return is_string($locale) && $locale !== '' && $locale !== 'default'
+ ? LanguageRegistry::displayName($locale, app()->getLocale())
+ : __('activity.values.panel-default');
+ }
}
diff --git a/app/Services/Extensions/ExtensionManifest.php b/app/Services/Extensions/ExtensionManifest.php
index 14cef4b79..bb7e3be94 100644
--- a/app/Services/Extensions/ExtensionManifest.php
+++ b/app/Services/Extensions/ExtensionManifest.php
@@ -19,7 +19,9 @@ class ExtensionManifest
public const string LANGUAGES_DIRECTORY = 'resources/languages';
- public const string LOCALE_REGEX = '/^[a-z]{2}(?:_[A-Z]{2})?$/D';
+ public const string LOCALE_PATTERN = '[a-z]{2,3}(?:_[A-Z][a-z]{3})?(?:_(?:[A-Z]{2}|[0-9]{3}))?';
+
+ public const string LOCALE_REGEX = '/^'.self::LOCALE_PATTERN.'$/D';
public const array TYPES = ['extension', 'theme'];
diff --git a/app/Services/Extensions/Scaffolding/stubs/language-readme.stub b/app/Services/Extensions/Scaffolding/stubs/language-readme.stub
index 5ee5678ee..41c931a22 100644
--- a/app/Services/Extensions/Scaffolding/stubs/language-readme.stub
+++ b/app/Services/Extensions/Scaffolding/stubs/language-readme.stub
@@ -21,8 +21,8 @@ file only needs the keys it translates. Extensions add their interface text to t
`resources/languages/vendor/ext-/{{language}}/.php` with that extension's keys.
When two enabled packs provide the same key for a locale, the one loaded later wins: a pack listed under
-`requires.extensions` loads first, and unrelated packs load in alphabetical order. The extension page in
-the admin area and `p:lang:coverage` list such conflicts.
+`requires.extensions` loads first, and unrelated packs load in alphabetical order.
+`p:lang:coverage` and the Admin API's extension listing (`language_conflicts`) report such conflicts.
## Develop
@@ -32,5 +32,7 @@ php {{artisan}} p:lang:coverage {{language}} --extension={{id}}
php {{artisan}} p:extension:pack .
```
-`p:lang:coverage` lists missing and stale keys and placeholder mistakes, and exits non-zero when keys are
-missing or a translation uses a placeholder English does not.
+`p:lang:coverage` lists missing and stale keys, values still the same as the English, and placeholder
+mistakes. It exits non-zero when keys are missing or a translation uses a placeholder English does not. The
+scaffolded files start as copies of the English, so every key is listed as the same as English until it is
+translated.
diff --git a/app/Services/Themes/ThemeSetting.php b/app/Services/Themes/ThemeSetting.php
index bc0b753e5..9ea71fc71 100644
--- a/app/Services/Themes/ThemeSetting.php
+++ b/app/Services/Themes/ThemeSetting.php
@@ -190,7 +190,7 @@ final readonly class ThemeSetting
return function (string $attribute, mixed $value, Closure $fail) use ($step, $base): void {
$steps = is_numeric($value) ? ((float) $value - $base) / $step : 0.5;
if (abs($steps - round($steps)) > 1e-9) {
- $fail("The :attribute must be in steps of {$this->step}.");
+ $fail(__('validation.internal.setting_step', ['step' => $this->step]));
}
};
}
diff --git a/app/Services/Translations/LanguageRegistry.php b/app/Services/Translations/LanguageRegistry.php
index 5514487a8..024da587f 100644
--- a/app/Services/Translations/LanguageRegistry.php
+++ b/app/Services/Translations/LanguageRegistry.php
@@ -100,6 +100,13 @@ class LanguageRegistry
return $entries;
}
+ public static function displayName(string $locale, string $in): string
+ {
+ $name = Locale::getDisplayName($locale, $in);
+
+ return Str::title($name === false ? $locale : $name);
+ }
+
/**
* @return Collection
*/
@@ -147,8 +154,7 @@ class LanguageRegistry
{
$languages = [];
foreach (array_keys($this->sources()) as $locale) {
- $name = Locale::getDisplayName($locale, $localize ? $locale : self::FALLBACK);
- $languages[$locale] = Str::title($name === false ? $locale : $name);
+ $languages[$locale] = self::displayName($locale, $localize ? $locale : self::FALLBACK);
}
return $languages;
diff --git a/app/Services/Translations/TranslationCoverage.php b/app/Services/Translations/TranslationCoverage.php
index 9dc0485bf..cd71af34f 100644
--- a/app/Services/Translations/TranslationCoverage.php
+++ b/app/Services/Translations/TranslationCoverage.php
@@ -25,7 +25,7 @@ class TranslationCoverage
) {}
/**
- * @return array{locale: string, extension: string|null, total: int, translated: int, missing: list, stale: list, invalid: list, unknown_placeholders: array>, dropped_placeholders: array>, conflicts: list, winner: string}>}
+ * @return array{locale: string, extension: string|null, total: int, translated: int, missing: list, unchanged: list, stale: list, invalid: list, unknown_placeholders: array>, dropped_placeholders: array>, conflicts: list, winner: string}>}
*/
public function report(string $locale, ?ExtensionManifest $pack = null): array
{
@@ -41,6 +41,7 @@ class TranslationCoverage
}
$missing = [];
+ $unchanged = [];
$unknown = [];
$dropped = [];
foreach ($base as $key => $english) {
@@ -52,6 +53,10 @@ class TranslationCoverage
continue;
}
+ if ($value === $english) {
+ $unchanged[] = $key;
+ }
+
$expected = $this->placeholders($key, $english);
$found = $this->placeholders($key, $value);
if (($extra = array_values(array_diff($found, $expected))) !== []) {
@@ -98,8 +103,9 @@ class TranslationCoverage
'locale' => $locale,
'extension' => $pack?->id,
'total' => count($base),
- 'translated' => count($base) - count($missing),
+ 'translated' => count($base) - count($missing) - count($unchanged),
'missing' => $missing,
+ 'unchanged' => $unchanged,
'stale' => $stale,
'invalid' => $invalid,
'unknown_placeholders' => $unknown,
diff --git a/database/migrations/2026_10_23_000000_make_users_language_nullable.php b/database/migrations/2026_10_23_000000_make_users_language_nullable.php
index 83d3bf4e9..c4030fda8 100644
--- a/database/migrations/2026_10_23_000000_make_users_language_nullable.php
+++ b/database/migrations/2026_10_23_000000_make_users_language_nullable.php
@@ -12,7 +12,7 @@ return new class extends Migration
public function up(): void
{
Schema::table('users', function (Blueprint $table): void {
- $table->char('language', 5)->nullable()->default(null)->change();
+ $table->string('language', 16)->nullable()->default(null)->change();
});
DB::table('users')->where('language', 'en')->update(['language' => null]);
@@ -20,6 +20,7 @@ return new class extends Migration
public function down(): void
{
+ DB::table('users')->whereRaw('LENGTH(language) > 5')->update(['language' => null]);
DB::table('users')->whereNull('language')->update(['language' => 'en']);
Schema::table('users', function (Blueprint $table): void {
diff --git a/packages/hello-world/src/client/examples.spec.tsx b/packages/hello-world/src/client/examples.spec.tsx
index 860f76a56..1b109bd39 100644
--- a/packages/hello-world/src/client/examples.spec.tsx
+++ b/packages/hello-world/src/client/examples.spec.tsx
@@ -202,7 +202,7 @@ it('composes the native server card using the real SDK fixture', () => {
});
expect(screen.getByText('Survival')).toBeTruthy();
- expect(screen.getByText('12.00 %')).toBeTruthy();
+ expect(screen.getByText('12.00%')).toBeTruthy();
// The prefixed utility replaces the native card's own gap instead of sitting beside it.
const card = screen.getByText('Survival').closest('.grid');
diff --git a/packages/sdk/manifest.schema.json b/packages/sdk/manifest.schema.json
index 1a9416c21..f074d5fef 100644
--- a/packages/sdk/manifest.schema.json
+++ b/packages/sdk/manifest.schema.json
@@ -130,9 +130,9 @@
"uniqueItems": true,
"items": {
"type": "string",
- "pattern": "^[a-z]{2}(?:_[A-Z]{2})?$"
+ "pattern": "^[a-z]{2,3}(?:_[A-Z][a-z]{3})?(?:_(?:[A-Z]{2}|[0-9]{3}))?$"
},
- "description": "Locales this package translates the panel into, such as de or pt_BR. Each one is a directory under resources/languages holding PHP files for core translation groups, which merge over the panel's own; resources/languages/vendor/ext-/ translates another extension. Packages that declare the same locale merge key by key, a package listed in requires.extensions loading first."
+ "description": "Locales this package translates the panel into, such as de, pt_BR or zh_Hant. Each one is a directory under resources/languages holding PHP files for core translation groups, which merge over the panel's own; resources/languages/vendor/ext-/ translates another extension. Packages that declare the same locale merge key by key, a package listed in requires.extensions loading first."
},
"routes": {
"type": "object",
diff --git a/packages/sdk/types/components/elements/Translate.d.ts b/packages/sdk/types/components/elements/Translate.d.ts
index 5d52c47b3..c6ced2ee7 100644
--- a/packages/sdk/types/components/elements/Translate.d.ts
+++ b/packages/sdk/types/components/elements/Translate.d.ts
@@ -9,7 +9,10 @@ interface Props {
i18nKey: string;
values?: TranslationValues;
components?: Readonly>;
+ valueComponent?: React.ReactElement<{
+ children?: React.ReactNode;
+ }>;
children?: React.ReactNode;
}
-export default function Translate({ ns, children, ...props }: Props): React.JSX.Element;
+export default function Translate({ ns, children, values, components, valueComponent, ...props }: Props): React.JSX.Element;
export {};
diff --git a/packages/sdk/types/lib/formatters.d.ts b/packages/sdk/types/lib/formatters.d.ts
index 343777fe8..5f44dc724 100644
--- a/packages/sdk/types/lib/formatters.d.ts
+++ b/packages/sdk/types/lib/formatters.d.ts
@@ -2,6 +2,7 @@
declare function mbToBytes(megabytes: number): number;
declare function bytesToString(bytes: number, decimals?: number): string;
declare function bytesRatioToString(used: number, total: number, decimals?: number): string;
+declare function percentageToString(value: number, decimals?: number): string;
/** Wraps IPv6 addresses in brackets. */
declare function ip(value: string): string;
-export { ip, mbToBytes, bytesToString, bytesRatioToString };
+export { ip, mbToBytes, bytesToString, bytesRatioToString, percentageToString };
diff --git a/packages/sdk/types/sdk/index.d.ts b/packages/sdk/types/sdk/index.d.ts
index 9c0210283..61a1bb102 100644
--- a/packages/sdk/types/sdk/index.d.ts
+++ b/packages/sdk/types/sdk/index.d.ts
@@ -56,7 +56,7 @@ export * from "./navigation.js";
export * from "./localization.js";
export * from "./progress.js";
export { onThemeChange, notifyThemeChange, readThemeToken } from "./theme.js";
-export { bytesToString, ip, mbToBytes } from "../lib/formatters.js";
+export { bytesToString, ip, mbToBytes, percentageToString } from "../lib/formatters.js";
export { formatDate, fromNow } from "../lib/dates.js";
export { useDebouncedCallback, type DebouncedCallback } from "../plugins/useDebouncedCallback.js";
export { useShortcut, type Shortcut } from "../plugins/useShortcut.js";
diff --git a/resources/lang/en.json b/resources/lang/en.json
index 39195504e..5383c6053 100644
--- a/resources/lang/en.json
+++ b/resources/lang/en.json
@@ -217,7 +217,8 @@
"Application Feature Limits": "Application Feature Limits",
"Archive": "Archive",
"Archive started": "Archive started",
- "Are you sure you want to delete {{number}} files? This is a permanent action and the files cannot be recovered.": "Are you sure you want to delete {{number}} files? This is a permanent action and the files cannot be recovered.",
+ "Are you sure you want to delete {{count}} files? This is a permanent action and the files cannot be recovered._one": "Are you sure you want to delete {{count}} file? This is a permanent action and the file cannot be recovered.",
+ "Are you sure you want to delete {{count}} files? This is a permanent action and the files cannot be recovered._other": "Are you sure you want to delete {{count}} files? This is a permanent action and the files cannot be recovered.",
"Are you sure you want to delete this task? This action cannot be undone.": "Are you sure you want to delete this task? This action cannot be undone.",
"Are you sure you wish to remove this subuser? They will have all access to this server revoked immediately.": "Are you sure you wish to remove this subuser? They will have all access to this server revoked immediately.",
"Assign Additional Ports": "Assign Additional Ports",
@@ -635,13 +636,13 @@
"File Name": "File Name",
"File Uploads": "File Uploads",
"File copied": "File copied",
- "File deleted": "File deleted",
"File editor": "File editor",
"File removed": "File removed",
"File saved": "File saved",
"File uploaded": "File uploaded",
"Files": "Files",
- "Files deleted": "Files deleted",
+ "Files deleted_one": "File deleted",
+ "Files deleted_other": "Files deleted",
"Files updated": "Files updated",
"Find": "Find",
"Find and import server templates from eggs.pterodactyl.io.": "Find and import server templates from eggs.pterodactyl.io.",
@@ -1227,23 +1228,28 @@
"Showing {{start}} to {{end}} of {{count}} API keys_other": "Showing {{start}} to {{end}} of {{count}} API keys",
"Showing {{start}} to {{end}} of {{count}} allocations_one": "Showing {{start}} to {{end}} of {{count}} allocation",
"Showing {{start}} to {{end}} of {{count}} allocations_other": "Showing {{start}} to {{end}} of {{count}} allocations",
+ "Showing {{start}} to {{end}} of {{count}} backups_one": "Showing {{start}} to {{end}} of {{count}} backup",
+ "Showing {{start}} to {{end}} of {{count}} backups_other": "Showing {{start}} to {{end}} of {{count}} backups",
"Showing {{start}} to {{end}} of {{count}} database hosts_one": "Showing {{start}} to {{end}} of {{count}} database host",
"Showing {{start}} to {{end}} of {{count}} database hosts_other": "Showing {{start}} to {{end}} of {{count}} database hosts",
"Showing {{start}} to {{end}} of {{count}} databases_one": "Showing {{start}} to {{end}} of {{count}} database",
"Showing {{start}} to {{end}} of {{count}} databases_other": "Showing {{start}} to {{end}} of {{count}} databases",
+ "Showing {{start}} to {{end}} of {{count}} items_one": "Showing {{start}} to {{end}} of {{count}} item",
+ "Showing {{start}} to {{end}} of {{count}} items_other": "Showing {{start}} to {{end}} of {{count}} items",
"Showing {{start}} to {{end}} of {{count}} locations_one": "Showing {{start}} to {{end}} of {{count}} location",
"Showing {{start}} to {{end}} of {{count}} locations_other": "Showing {{start}} to {{end}} of {{count}} locations",
"Showing {{start}} to {{end}} of {{count}} mounts_one": "Showing {{start}} to {{end}} of {{count}} mount",
"Showing {{start}} to {{end}} of {{count}} mounts_other": "Showing {{start}} to {{end}} of {{count}} mounts",
"Showing {{start}} to {{end}} of {{count}} nodes_one": "Showing {{start}} to {{end}} of {{count}} node",
"Showing {{start}} to {{end}} of {{count}} nodes_other": "Showing {{start}} to {{end}} of {{count}} nodes",
+ "Showing {{start}} to {{end}} of {{count}} results._one": "Showing {{start}} to {{end}} of {{count}} result.",
+ "Showing {{start}} to {{end}} of {{count}} results._other": "Showing {{start}} to {{end}} of {{count}} results.",
"Showing {{start}} to {{end}} of {{count}} servers_one": "Showing {{start}} to {{end}} of {{count}} server",
"Showing {{start}} to {{end}} of {{count}} servers_other": "Showing {{start}} to {{end}} of {{count}} servers",
"Showing {{start}} to {{end}} of {{count}} tags_one": "Showing {{start}} to {{end}} of {{count}} tag",
"Showing {{start}} to {{end}} of {{count}} tags_other": "Showing {{start}} to {{end}} of {{count}} tags",
"Showing {{start}} to {{end}} of {{count}} users_one": "Showing {{start}} to {{end}} of {{count}} user",
"Showing {{start}} to {{end}} of {{count}} users_other": "Showing {{start}} to {{end}} of {{count}} users",
- "Showing {{start}} to {{end}} of {{total}} results.": "Showing {{start}} to {{end}} of {{total}} results.",
"Showing {{start}} to {{end}} of {{total}} {{items}}": "Showing {{start}} to {{end}} of {{total}} {{items}}",
"Showing others' servers": "Showing others' servers",
"Showing your servers": "Showing your servers",
@@ -1464,7 +1470,8 @@
"This will flip the install status between installed and installing for this server.": "This will flip the install status between installed and installing for this server.",
"This will permanently delete every unassigned allocation for {{ip}}. This action cannot be undone.": "This will permanently delete every unassigned allocation for {{ip}}. This action cannot be undone.",
"This will permanently delete the {{address}} allocation. This action cannot be undone.": "This will permanently delete the {{address}} allocation. This action cannot be undone.",
- "This will permanently delete the {{selected}} selected allocation(s). This action cannot be undone.": "This will permanently delete the {{selected}} selected allocation(s). This action cannot be undone.",
+ "This will permanently delete the {{count}} selected allocations. This action cannot be undone._one": "This will permanently delete the {{count}} selected allocation. This action cannot be undone.",
+ "This will permanently delete the {{count}} selected allocations. This action cannot be undone._other": "This will permanently delete the {{count}} selected allocations. This action cannot be undone.",
"This will permanently remove the {{name}} variable from this egg.": "This will permanently remove the {{name}} variable from this egg.",
"This will reinstall the server with its assigned service scripts. This could overwrite server data.": "This will reinstall the server with its assigned service scripts. This could overwrite server data.",
"This will reinstall the server with the assigned service scripts.": "This will reinstall the server with the assigned service scripts.",
@@ -1700,7 +1707,8 @@
"Wings {{version}}": "Wings {{version}}",
"Yes, reinstall server": "Yes, reinstall server",
"Yes, remove subuser": "Yes, remove subuser",
- "You are currently using {{used}} of {{limit}} allowed allocations for this server.": "You are currently using {{used}} of {{limit}} allowed allocations for this server.",
+ "You are currently using {{used}} of {{count}} allowed allocations for this server._one": "You are currently using {{used}} of {{count}} allowed allocation for this server.",
+ "You are currently using {{used}} of {{count}} allowed allocations for this server._other": "You are currently using {{used}} of {{count}} allowed allocations for this server.",
"You are running version {{current}}.": "You are running version {{current}}.",
"You are running version {{current}}; the latest available is {{latest}}.": "You are running version {{current}}; the latest available is {{latest}}.",
"You are using reCAPTCHA keys that shipped with this Panel. Generate new invisible reCAPTCHA keys for this website to improve security.": "You are using reCAPTCHA keys that shipped with this Panel. Generate new invisible reCAPTCHA keys for this website to improve security.",
@@ -1735,9 +1743,9 @@
"Your server will be stopped and some files may be deleted or modified during this process, are you sure you wish to continue?": "Your server will be stopped and some files may be deleted or modified during this process, are you sure you wish to continue?",
"Your server will be stopped. You will not be able to control the power state, access the file manager, or create additional backups until completed.": "Your server will be stopped. You will not be able to control the power state, access the file manager, or create additional backups until completed.",
"active": "active",
- "and {{number}} others": "and {{number}} others",
+ "and {{count}} others_one": "and {{count}} other",
+ "and {{count}} others_other": "and {{count}} others",
"any value": "any value",
- "backups": "backups",
"by {{author}}": "by {{author}}",
"every 5 minutes": "every 5 minutes",
"every Monday": "every Monday",
@@ -1745,7 +1753,6 @@
"every hour": "every hour",
"hour range": "hour range",
"inactive": "inactive",
- "items": "items",
"n/a": "n/a",
"new": "new",
"of {{limit}}": "of {{limit}}",
@@ -1762,7 +1769,6 @@
"up to {{size}} KB": "up to {{size}} KB",
"value list separator": "value list separator",
"{{address}} is available.": "{{address}} is available.",
- "{{allocated}} of {{limit}} databases have been allocated to this server.": "{{allocated}} of {{limit}} databases have been allocated to this server.",
"{{count}} allocations_one": "{{count}} allocation",
"{{count}} allocations_other": "{{count}} allocations",
"{{count}} databases_one": "{{count}} database",
@@ -1771,9 +1777,18 @@
"{{count}} eggs_other": "{{count}} eggs",
"{{count}} extensions need attention_one": "{{count}} extension needs attention",
"{{count}} extensions need attention_other": "{{count}} extensions need attention",
+ "{{count}} files are uploading, click to view_one": "{{count}} file is uploading, click to view",
+ "{{count}} files are uploading, click to view_other": "{{count}} files are uploading, click to view",
+ "{{count}} granted_one": "{{count}} granted",
+ "{{count}} granted_other": "{{count}} granted",
"{{count}} nodes_one": "{{count}} node",
"{{count}} nodes_other": "{{count}} nodes",
- "{{created}} of {{limit}} backups have been created for this server.": "{{created}} of {{limit}} backups have been created for this server.",
+ "{{count}} selected_one": "{{count}} selected",
+ "{{count}} selected_other": "{{count}} selected",
+ "{{count}} servers_one": "{{count}} server",
+ "{{count}} servers_other": "{{count}} servers",
+ "{{created}} of {{count}} backups have been created for this server._one": "{{created}} of {{count}} backup has been created for this server.",
+ "{{created}} of {{count}} backups have been created for this server._other": "{{created}} of {{count}} backups have been created for this server.",
"{{days}}d {{hours}}h {{minutes}}m": "{{days}}d {{hours}}h {{minutes}}m",
"{{email}} avatar": "{{email}} avatar",
"{{email}} has been invited.": "{{email}} has been invited.",
@@ -1810,14 +1825,11 @@
"{{name}} is now active. Reload the page to see it.": "{{name}} is now active. Reload the page to see it.",
"{{name}} is ready to use.": "{{name}} is ready to use.",
"{{name}} settings": "{{name}} settings",
- "{{nodes}} nodes · {{servers}} servers": "{{nodes}} nodes · {{servers}} servers",
+ "{{nodes}} · {{servers}}": "{{nodes}} · {{servers}}",
"{{node}} only accepts eggs tagged {{tags}}.": "{{node}} only accepts eggs tagged {{tags}}.",
- "{{number}} files are uploading, click to view": "{{number}} files are uploading, click to view",
"{{seconds}}s later": "{{seconds}}s later",
- "{{selected}} selected": "{{selected}} selected",
"{{title}} usage": "{{title}} usage",
- "{{total}} granted": "{{total}} granted",
- "{{total}} selected": "{{total}} selected",
"{{unassigned}} unassigned": "{{unassigned}} unassigned",
- "{{used}} of {{limit}} databases have been allocated to this server.": "{{used}} of {{limit}} databases have been allocated to this server."
+ "{{used}} of {{count}} databases have been allocated to this server._one": "{{used}} of {{count}} database has been allocated to this server.",
+ "{{used}} of {{count}} databases have been allocated to this server._other": "{{used}} of {{count}} databases have been allocated to this server."
}
diff --git a/resources/lang/en/activity.php b/resources/lang/en/activity.php
index cb23658f1..f4f0c798a 100644
--- a/resources/lang/en/activity.php
+++ b/resources/lang/en/activity.php
@@ -241,4 +241,7 @@ return [
'disable-2fa' => 'Disabled two-factor authentication for :email',
],
],
+ 'values' => [
+ 'panel-default' => 'the panel default',
+ ],
];
diff --git a/resources/lang/en/exceptions.php b/resources/lang/en/exceptions.php
index 362913098..7e53507ba 100644
--- a/resources/lang/en/exceptions.php
+++ b/resources/lang/en/exceptions.php
@@ -111,6 +111,7 @@ return [
'default_allocation_not_assigned' => 'The requested default allocation is not currently assigned to this server.',
'offline_command' => 'Server must be online in order to send commands.',
'docker_image_locked' => "This server's Docker image has been manually set by an administrator and cannot be updated.",
+ 'variable_not_found' => 'The environment variable you are trying to edit does not exist.',
'variable_read_only' => 'The environment variable you are trying to edit is read-only.',
'websocket_forbidden' => "You do not have permission to connect to this server's websocket.",
'transfer_logs_forbidden' => 'You do not have permission to view server transfer logs.',
@@ -150,6 +151,7 @@ return [
'malformed_json' => 'The JSON data passed in the request appears to be malformed: :error',
'unauthenticated' => 'This endpoint requires an authenticated user.',
'unauthorized' => 'This action is unauthorized.',
+ 'session_required' => 'This action can only be performed from an authenticated panel session, not with an API key.',
'recaptcha_failed' => 'Failed to validate reCAPTCHA data.',
'application_key_rejected' => 'You are attempting to use an application API key on an endpoint that does not accept them.',
'client_key_required' => 'You are attempting to use an application API key on an endpoint that requires a client API key.',
diff --git a/resources/lang/en/validation.php b/resources/lang/en/validation.php
index a3238bcd5..a6a4919ae 100644
--- a/resources/lang/en/validation.php
+++ b/resources/lang/en/validation.php
@@ -109,6 +109,8 @@ return [
'fqdn_ip_with_https' => 'The :attribute must not be an IP address when HTTPS is enabled.',
'path_within' => 'The :field path cannot be or reside within [:path].',
'path_reserved' => 'The :field path cannot be [:path].',
+ 'tag_reference' => 'The :attribute field must be a tag ID or slug.',
+ 'setting_step' => 'The :attribute must be in steps of :step.',
'tag_slug_numeric' => 'A tag slug cannot be purely numeric (reserved for tag and legacy nest IDs).',
'docker_images_empty' => 'The :attribute field must list at least one image.',
'docker_image_invalid' => 'The :attribute entry ":image" is not a valid Docker image.',
diff --git a/resources/scripts/api/server/files/queries.ts b/resources/scripts/api/server/files/queries.ts
index ae85a8057..ac949536e 100644
--- a/resources/scripts/api/server/files/queries.ts
+++ b/resources/scripts/api/server/files/queries.ts
@@ -356,7 +356,7 @@ export const useDeleteFiles = () => {
);
}
- toast.success(body?.files?.length === 1 ? i18next.t('File deleted') : i18next.t('Files deleted'));
+ toast.success(i18next.t('Files deleted', { count: body?.files?.length ?? 0 }));
},
onError: (error) => notifyHttpError(error, i18next.t('Unable to delete files')),
});
diff --git a/resources/scripts/components/admin/api/ApiKeyTable.tsx b/resources/scripts/components/admin/api/ApiKeyTable.tsx
index a675a1ec5..77907baab 100644
--- a/resources/scripts/components/admin/api/ApiKeyTable.tsx
+++ b/resources/scripts/components/admin/api/ApiKeyTable.tsx
@@ -76,7 +76,7 @@ export const apiKeyColumns = (t: Translation['t']) =>
header: t('Permissions'),
cell: ({ row }) => (
- {t('{{total}} granted', { total: grantedCount(row.original) })}
+ {t('{{count}} granted', { count: grantedCount(row.original) })}
),
enableSorting: false,
diff --git a/resources/scripts/components/admin/extensions/ExtensionsContainer.tsx b/resources/scripts/components/admin/extensions/ExtensionsContainer.tsx
index e4fb95c28..3dea19914 100644
--- a/resources/scripts/components/admin/extensions/ExtensionsContainer.tsx
+++ b/resources/scripts/components/admin/extensions/ExtensionsContainer.tsx
@@ -2,6 +2,7 @@ import React, { useState } from 'react';
import { AlertCircle, FileArchive, RefreshCw, Settings2, Trash2, UploadCloud } from 'lucide-react';
import { getExtensionStates, useExtensionRegistry } from '@/extensions/registry';
import { cn } from '@/lib/cn';
+import { formatDate } from '@/lib/dates';
import { httpErrorToHuman } from '@/api/http';
import {
disableAdminExtensionInput,
@@ -630,9 +631,9 @@ function ExtensionCardDetails({ extension }: { extension: AdminExtension }) {
{extension.error_phase
? t('In {{phase}}, {{date}}', {
phase: extension.error_phase,
- date: new Date(extension.errored_at).toLocaleString(),
+ date: formatDate(extension.errored_at, 'll LTS'),
})
- : new Date(extension.errored_at).toLocaleString()}
+ : formatDate(extension.errored_at, 'll LTS')}