Compare commits
44 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 47f66030db | |||
| 70b3484f98 | |||
| 3c036eb09c | |||
| ce9ab89c1c | |||
| bb0a811432 | |||
| 8445e302e6 | |||
| 2bff15fd13 | |||
| 0345b7cced | |||
| 7a4ebdf985 | |||
| 05a61d8bf2 | |||
| 0a07d2578e | |||
| ee05a73834 | |||
| 13dce0c20b | |||
| 41f06bfe54 | |||
| 0cadd83e45 | |||
| d7879a8654 | |||
| 49b3dcc591 | |||
| e94405d1cd | |||
| 1dde7088bc | |||
| bd67ece479 | |||
| a3c5e31094 | |||
| 1b715c5f8b | |||
| 6dfac27bc3 | |||
| c6dd0b63f2 | |||
| bdd53b1551 | |||
| 982d2882e9 | |||
| 2b0cf9a46d | |||
| d6854076fe | |||
| 6991b69d40 | |||
| b8f630f8ab | |||
| 5ce5d62b22 | |||
| 2d5175d70f | |||
| 05d6c8947c | |||
| 8700cf6a91 | |||
| ebcebd7ddf | |||
| 54de16bdd5 | |||
| 597a01885b | |||
| 8a0baf3a61 | |||
| c4c4d5aea3 | |||
| 15540bfe16 | |||
| 634156206a | |||
| e2a357fea7 | |||
| 1d52642cb7 | |||
| 131693b604 |
+163
-63
@@ -1,77 +1,177 @@
|
||||
<a name="readme-top"></a>
|
||||
# Changelog
|
||||
|
||||
# [1.4.0](https://github.com/perfect-panel/ppanel-web/compare/v1.3.0...v1.4.0) (2025-09-14)
|
||||
|
||||
|
||||
### ♻ Code Refactoring
|
||||
|
||||
* **logs**: Add localization files and update existing translations for multiple languages ([2f20ac9](https://github.com/perfect-panel/ppanel-web/commit/2f20ac9))
|
||||
* **subscribe-form**: Replace server_group and server with node_tags and nodes in default values and form schema ([38dda84](https://github.com/perfect-panel/ppanel-web/commit/38dda84))
|
||||
* Add localization updates for log and server files across multiple languages ([2bcd4cf](https://github.com/perfect-panel/ppanel-web/commit/2bcd4cf))
|
||||
* Clean up NodeForm and ServerForm components by removing unused functions and optimizing state management ([10250d9](https://github.com/perfect-panel/ppanel-web/commit/10250d9))
|
||||
* Enhance log pages with Badge component and update translations ([a4de9df](https://github.com/perfect-panel/ppanel-web/commit/a4de9df))
|
||||
* Make 'scheme' field optional in client form schema ([f4a1237](https://github.com/perfect-panel/ppanel-web/commit/f4a1237))
|
||||
* Refactor server management API endpoints and typings ([4f7cc80](https://github.com/perfect-panel/ppanel-web/commit/4f7cc80))
|
||||
* Remove application management forms and related configurations ([0c43844](https://github.com/perfect-panel/ppanel-web/commit/0c43844))
|
||||
* Remove default options from TagInput component for improved flexibility ([6a3bb70](https://github.com/perfect-panel/ppanel-web/commit/6a3bb70))
|
||||
* Remove unused preview state variables and add sort order to node properties ([e63f823](https://github.com/perfect-panel/ppanel-web/commit/e63f823))
|
||||
* Rename buildScheme to buildSchema and update imports in server form components ([ee98e7e](https://github.com/perfect-panel/ppanel-web/commit/ee98e7e))
|
||||
* Simplify node display in subscribe form and remove unused Badge import ([551135d](https://github.com/perfect-panel/ppanel-web/commit/551135d))
|
||||
* Update bun.lockb to reflect dependency changes ([ba2b50e](https://github.com/perfect-panel/ppanel-web/commit/ba2b50e))
|
||||
* Update component imports and improve code consistency ([59faeab](https://github.com/perfect-panel/ppanel-web/commit/59faeab))
|
||||
* Update dependencies and improve code consistency across multiple files ([e37ae49](https://github.com/perfect-panel/ppanel-web/commit/e37ae49))
|
||||
* Update localization files and service imports ([d4b37e4](https://github.com/perfect-panel/ppanel-web/commit/d4b37e4))
|
||||
|
||||
|
||||
### ✨ Features
|
||||
|
||||
* **config**: Add translations for server configuration in multiple languages ([f9a7ece](https://github.com/perfect-panel/ppanel-web/commit/f9a7ece))
|
||||
* **logs**: Add various log pages for tracking user activities and system events ([d85af49](https://github.com/perfect-panel/ppanel-web/commit/d85af49))
|
||||
* Add bandwidth fields and placeholders for upload and download in server configuration forms; update localization files for multiple languages ([3e5402f](https://github.com/perfect-panel/ppanel-web/commit/3e5402f))
|
||||
* Add batch delete functionality and enhance chart tooltips in statistics cards ([c4f536e](https://github.com/perfect-panel/ppanel-web/commit/c4f536e))
|
||||
* Add language support and descriptions in product localization files ([fd48856](https://github.com/perfect-panel/ppanel-web/commit/fd48856))
|
||||
* Add log cleanup settings and update localization files ([6ccf9b8](https://github.com/perfect-panel/ppanel-web/commit/6ccf9b8))
|
||||
* Add queryNodeTag function and integrate tag retrieval in NodeForm and SubscribeForm components ([4563c57](https://github.com/perfect-panel/ppanel-web/commit/4563c57))
|
||||
* Add quota management features and localization updates ([fce627b](https://github.com/perfect-panel/ppanel-web/commit/fce627b))
|
||||
* Add server form component with protocol configuration and localization support ([217ddce](https://github.com/perfect-panel/ppanel-web/commit/217ddce))
|
||||
* Enhance TagInput component with option handling and improved tag addition logic ([b6e778d](https://github.com/perfect-panel/ppanel-web/commit/b6e778d))
|
||||
* Implement data migration functionality and update localization files ([6d81bfd](https://github.com/perfect-panel/ppanel-web/commit/6d81bfd))
|
||||
* Refactor user detail and subscription management components ([973c06f](https://github.com/perfect-panel/ppanel-web/commit/973c06f))
|
||||
* Update server list fetching logic and adjust query parameters ([5272360](https://github.com/perfect-panel/ppanel-web/commit/5272360))
|
||||
## [1.4.8](https://github.com/perfect-panel/ppanel-web/compare/v1.4.7...v1.4.8) (2025-09-23)
|
||||
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
* **page**: Refine version checking logic and remove unnecessary comments for clarity ([26176a7](https://github.com/perfect-panel/ppanel-web/commit/26176a7))
|
||||
* Add localization updates and new utility functions ([4da5960](https://github.com/perfect-panel/ppanel-web/commit/4da5960))
|
||||
* Add user_subscribe_id filter to SubscribeLogPage and update typings; disable eslint in service index files ([ab6f6a6](https://github.com/perfect-panel/ppanel-web/commit/ab6f6a6))
|
||||
* Added system version card and system log dialog components; updated statistics page to include total server and user statistics ([fe69980](https://github.com/perfect-panel/ppanel-web/commit/fe69980))
|
||||
* Adjust timestamp calculations to use milliseconds instead of seconds in quota broadcast form submission ([8dffd69](https://github.com/perfect-panel/ppanel-web/commit/8dffd69))
|
||||
* Correct cookie key format for sidebar state retrieval ([9e01f4f](https://github.com/perfect-panel/ppanel-web/commit/9e01f4f))
|
||||
* Improve UI for protocol status display in server form component ([461fdb1](https://github.com/perfect-panel/ppanel-web/commit/461fdb1))
|
||||
* Increase pagination size limit for server and node lists to improve data retrieval ([7c0a312](https://github.com/perfect-panel/ppanel-web/commit/7c0a312))
|
||||
* Optimize Task Manager to use milliseconds to calculate timers, and simplify import statements ([d8fa13b](https://github.com/perfect-panel/ppanel-web/commit/d8fa13b))
|
||||
* Refactor protocol status display for improved readability in server form component ([f700be0](https://github.com/perfect-panel/ppanel-web/commit/f700be0))
|
||||
* Remove GroupTable and related components, simplify SubscribeTable and update language handling in subscription forms ([1ab9b39](https://github.com/perfect-panel/ppanel-web/commit/1ab9b39))
|
||||
* Remove redundant transport label from localization files ([88ce8d7](https://github.com/perfect-panel/ppanel-web/commit/88ce8d7))
|
||||
* Remove unnecessary comments and improve variable handling in GoTemplateEditor; ensure zero value displays as empty in EnhancedInput ([c4a47a4](https://github.com/perfect-panel/ppanel-web/commit/c4a47a4))
|
||||
* Remove unnecessary comments to simplify code readability ([a988cb3](https://github.com/perfect-panel/ppanel-web/commit/a988cb3))
|
||||
* Replace MarkdownEditor with HTMLEditor in EmailBroadcastForm; simplify content rendering in EmailTaskManager; disable eslint in service index files ([e2d83ec](https://github.com/perfect-panel/ppanel-web/commit/e2d83ec))
|
||||
* Replace redundant icon rendering with a single instance in system version card component ([e4429a5](https://github.com/perfect-panel/ppanel-web/commit/e4429a5))
|
||||
* Update billing URL fetching logic and improve version handling in system version card component ([1c8d4af](https://github.com/perfect-panel/ppanel-web/commit/1c8d4af))
|
||||
* Update condition for plugin field in PROTOCOL_FIELDS to include specific plugins ([6376ec1](https://github.com/perfect-panel/ppanel-web/commit/6376ec1))
|
||||
* Update getAppSubLink function to improve URL handling and encoding logic ([351fffc](https://github.com/perfect-panel/ppanel-web/commit/351fffc))
|
||||
* Update order_id to order_no in BalanceLogPage and related typings; enhance timezone switch component with additional features and localization updates ([ac36075](https://github.com/perfect-panel/ppanel-web/commit/ac36075))
|
||||
* Update protocol plugin handling and add new options in typings ([6ca2433](https://github.com/perfect-panel/ppanel-web/commit/6ca2433))
|
||||
* Update release URLs to include 'v' prefix for versioning in system version card component ([1d526b5](https://github.com/perfect-panel/ppanel-web/commit/1d526b5))
|
||||
* Update SidebarLeft component styles to enhance hover effects ([e4fbd5c](https://github.com/perfect-panel/ppanel-web/commit/e4fbd5c))
|
||||
* Update validation for days and gift_value fields in QuotaBroadcastForm; set default values to avoid errors ([39d746f](https://github.com/perfect-panel/ppanel-web/commit/39d746f))
|
||||
* Rename 'server_id' to 'protocol' in NodesPage and clean up unused imports and code in ServerConfig ([70b3484](https://github.com/perfect-panel/ppanel-web/commit/70b3484))
|
||||
* Update announcement page to display timeline of announcements with Markdown content ([3c036eb](https://github.com/perfect-panel/ppanel-web/commit/3c036eb))
|
||||
* Update Empty component to support border prop and adjust usage in various pages ([ce9ab89](https://github.com/perfect-panel/ppanel-web/commit/ce9ab89))
|
||||
|
||||
## [1.4.7](https://github.com/perfect-panel/ppanel-web/compare/v1.4.6...v1.4.7) (2025-09-23)
|
||||
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
* Add unique key to ProTable for improved rendering with user ID filters ([2bff15f](https://github.com/perfect-panel/ppanel-web/commit/2bff15f))
|
||||
* Adjust layout spacing and chart aspect ratio in ServerConfig component ([05a61d8](https://github.com/perfect-panel/ppanel-web/commit/05a61d8))
|
||||
* Refactor server ID cell rendering for improved readability and consistency ([0345b7c](https://github.com/perfect-panel/ppanel-web/commit/0345b7c))
|
||||
* Update announcement page to format creation date and enhance content display ([8445e30](https://github.com/perfect-panel/ppanel-web/commit/8445e30))
|
||||
* Update OnlineUsersCell to display user count with icon instead of badge ([7a4ebdf](https://github.com/perfect-panel/ppanel-web/commit/7a4ebdf))
|
||||
* Update subscribe name fallback to return '--' instead of 'Unknown' ([0a07d25](https://github.com/perfect-panel/ppanel-web/commit/0a07d25))
|
||||
|
||||
## [1.4.6](https://github.com/perfect-panel/ppanel-web/compare/v1.4.5...v1.4.6) (2025-09-17)
|
||||
|
||||
|
||||
### 🎫 Chores
|
||||
|
||||
* Merge branch 'main' into develop ([41f06bf](https://github.com/perfect-panel/ppanel-web/commit/41f06bf))
|
||||
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
* Add loaded state to node, server, and subscribe stores for better loading management ([13dce0c](https://github.com/perfect-panel/ppanel-web/commit/13dce0c))
|
||||
* Removed node metadata fields in subscription schema to simplify structure ([0cadd83](https://github.com/perfect-panel/ppanel-web/commit/0cadd83))
|
||||
|
||||
## [1.4.5](https://github.com/perfect-panel/ppanel-web/compare/v1.4.4...v1.4.5) (2025-09-17)
|
||||
|
||||
|
||||
### ♻ Code Refactoring
|
||||
|
||||
* Replace useQuery with Zustand store for subscription and node data management ([c6dd0b6](https://github.com/perfect-panel/ppanel-web/commit/c6dd0b6))
|
||||
* Simplify TemplatePreview component structure by consolidating Sheet and Button elements ([1b715c5](https://github.com/perfect-panel/ppanel-web/commit/1b715c5))
|
||||
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
* Add showLineNumbers prop handling in MonacoEditor for improved placeholder positioning ([bd67ece](https://github.com/perfect-panel/ppanel-web/commit/bd67ece))
|
||||
* Add fetchTags method to NodesPage and ensure tags are fetched alongside nodes ([a3c5e31](https://github.com/perfect-panel/ppanel-web/commit/a3c5e31))
|
||||
* Add NEXT_PUBLIC_HIDDEN_TUTORIAL_DOCUMENT to control tutorial visibility and update page query accordingly ([e94405d](https://github.com/perfect-panel/ppanel-web/commit/e94405d))
|
||||
* Add subscribeSchema for subscription management with detailed proxy and user information ([49b3dcc](https://github.com/perfect-panel/ppanel-web/commit/49b3dcc))
|
||||
* Enhance server ID display in ServerTrafficLogPage with badges and server ratio ([6dfac27](https://github.com/perfect-panel/ppanel-web/commit/6dfac27))
|
||||
* Update platform handling in Content component to ensure available platforms are correctly filtered and displayed ([1dde708](https://github.com/perfect-panel/ppanel-web/commit/1dde708))
|
||||
|
||||
<a name="readme-top"></a>
|
||||
|
||||
# Changelog
|
||||
|
||||
## [1.4.4](https://github.com/perfect-panel/ppanel-web/compare/v1.4.3...v1.4.4) (2025-09-16)
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
- Add minimum value constraint for count and user limit inputs in CouponForm ([6991b69](https://github.com/perfect-panel/ppanel-web/commit/6991b69))
|
||||
- Add protocol-related constants, default configurations, field definitions, and validation modes ([d685407](https://github.com/perfect-panel/ppanel-web/commit/d685407))
|
||||
- Added the enabled field in the protocol configuration, updated the related type definition and default configuration ([2b0cf9a](https://github.com/perfect-panel/ppanel-web/commit/2b0cf9a))
|
||||
- Filter available protocols to exclude disabled ones in NodeForm ([982d288](https://github.com/perfect-panel/ppanel-web/commit/982d288))
|
||||
- Refactor key generation logic and update dependencies for ML-KEM-768 integration ([b8f630f](https://github.com/perfect-panel/ppanel-web/commit/b8f630f))
|
||||
|
||||
<a name="readme-top"></a>
|
||||
|
||||
# Changelog
|
||||
|
||||
## [1.4.3](https://github.com/perfect-panel/ppanel-web/compare/v1.4.2...v1.4.3) (2025-09-16)
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
- Add success toast message for sorting in nodes and servers pages ([2d5175d](https://github.com/perfect-panel/ppanel-web/commit/2d5175d))
|
||||
- Implement encryption and obfuscation features in protocol configuration ([54de16b](https://github.com/perfect-panel/ppanel-web/commit/54de16b))
|
||||
- Refactor toB64 function to toB64Url for URL-safe base64 encoding in VlessX25519Pair generation ([8700cf6](https://github.com/perfect-panel/ppanel-web/commit/8700cf6))
|
||||
- Simplify initialValues assignment and update node submission logic in NodesPage ([05d6c89](https://github.com/perfect-panel/ppanel-web/commit/05d6c89))
|
||||
- Update bun.lockb to reflect dependency changes ([ebcebd7](https://github.com/perfect-panel/ppanel-web/commit/ebcebd7))
|
||||
|
||||
<a name="readme-top"></a>
|
||||
|
||||
# Changelog
|
||||
|
||||
## [1.4.2](https://github.com/perfect-panel/ppanel-web/compare/v1.4.1...v1.4.2) (2025-09-15)
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
- Add GitHub template repository link to ProtocolForm header for easier access ([8a0baf3](https://github.com/perfect-panel/ppanel-web/commit/8a0baf3))
|
||||
- Add readOnly prop to MonacoEditor and TemplatePreview components for improved content handling ([c4c4d5a](https://github.com/perfect-panel/ppanel-web/commit/c4c4d5a))
|
||||
|
||||
## [1.4.1](https://github.com/perfect-panel/ppanel-web/compare/v1.4.0...v1.4.1) (2025-09-15)
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
- Add copy subscription functionality to user subscription dashboard and improve localization for new features ([e2a357f](https://github.com/perfect-panel/ppanel-web/commit/e2a357f))
|
||||
- Simplify handleInputBlur function by removing unnecessary setTimeout ([6341562](https://github.com/perfect-panel/ppanel-web/commit/6341562))
|
||||
- Update TemplatePreview to use MonacoEditor for content display and improve error handling ([1d52642](https://github.com/perfect-panel/ppanel-web/commit/1d52642))
|
||||
- Update user dashboard link to correct path ([131693b](https://github.com/perfect-panel/ppanel-web/commit/131693b))
|
||||
|
||||
<a name="readme-top"></a>
|
||||
|
||||
# Changelog
|
||||
|
||||
# [1.4.0](https://github.com/perfect-panel/ppanel-web/compare/v1.3.0...v1.4.0) (2025-09-14)
|
||||
|
||||
### ♻ Code Refactoring
|
||||
|
||||
- **logs**: Add localization files and update existing translations for multiple languages ([2f20ac9](https://github.com/perfect-panel/ppanel-web/commit/2f20ac9))
|
||||
- **subscribe-form**: Replace server_group and server with node_tags and nodes in default values and form schema ([38dda84](https://github.com/perfect-panel/ppanel-web/commit/38dda84))
|
||||
- Add localization updates for log and server files across multiple languages ([2bcd4cf](https://github.com/perfect-panel/ppanel-web/commit/2bcd4cf))
|
||||
- Clean up NodeForm and ServerForm components by removing unused functions and optimizing state management ([10250d9](https://github.com/perfect-panel/ppanel-web/commit/10250d9))
|
||||
- Enhance log pages with Badge component and update translations ([a4de9df](https://github.com/perfect-panel/ppanel-web/commit/a4de9df))
|
||||
- Make 'scheme' field optional in client form schema ([f4a1237](https://github.com/perfect-panel/ppanel-web/commit/f4a1237))
|
||||
- Refactor server management API endpoints and typings ([4f7cc80](https://github.com/perfect-panel/ppanel-web/commit/4f7cc80))
|
||||
- Remove application management forms and related configurations ([0c43844](https://github.com/perfect-panel/ppanel-web/commit/0c43844))
|
||||
- Remove default options from TagInput component for improved flexibility ([6a3bb70](https://github.com/perfect-panel/ppanel-web/commit/6a3bb70))
|
||||
- Remove unused preview state variables and add sort order to node properties ([e63f823](https://github.com/perfect-panel/ppanel-web/commit/e63f823))
|
||||
- Rename buildScheme to buildSchema and update imports in server form components ([ee98e7e](https://github.com/perfect-panel/ppanel-web/commit/ee98e7e))
|
||||
- Simplify node display in subscribe form and remove unused Badge import ([551135d](https://github.com/perfect-panel/ppanel-web/commit/551135d))
|
||||
- Update bun.lockb to reflect dependency changes ([ba2b50e](https://github.com/perfect-panel/ppanel-web/commit/ba2b50e))
|
||||
- Update component imports and improve code consistency ([59faeab](https://github.com/perfect-panel/ppanel-web/commit/59faeab))
|
||||
- Update dependencies and improve code consistency across multiple files ([e37ae49](https://github.com/perfect-panel/ppanel-web/commit/e37ae49))
|
||||
- Update localization files and service imports ([d4b37e4](https://github.com/perfect-panel/ppanel-web/commit/d4b37e4))
|
||||
|
||||
### ✨ Features
|
||||
|
||||
- **config**: Add translations for server configuration in multiple languages ([f9a7ece](https://github.com/perfect-panel/ppanel-web/commit/f9a7ece))
|
||||
- **logs**: Add various log pages for tracking user activities and system events ([d85af49](https://github.com/perfect-panel/ppanel-web/commit/d85af49))
|
||||
- Add bandwidth fields and placeholders for upload and download in server configuration forms; update localization files for multiple languages ([3e5402f](https://github.com/perfect-panel/ppanel-web/commit/3e5402f))
|
||||
- Add batch delete functionality and enhance chart tooltips in statistics cards ([c4f536e](https://github.com/perfect-panel/ppanel-web/commit/c4f536e))
|
||||
- Add language support and descriptions in product localization files ([fd48856](https://github.com/perfect-panel/ppanel-web/commit/fd48856))
|
||||
- Add log cleanup settings and update localization files ([6ccf9b8](https://github.com/perfect-panel/ppanel-web/commit/6ccf9b8))
|
||||
- Add queryNodeTag function and integrate tag retrieval in NodeForm and SubscribeForm components ([4563c57](https://github.com/perfect-panel/ppanel-web/commit/4563c57))
|
||||
- Add quota management features and localization updates ([fce627b](https://github.com/perfect-panel/ppanel-web/commit/fce627b))
|
||||
- Add server form component with protocol configuration and localization support ([217ddce](https://github.com/perfect-panel/ppanel-web/commit/217ddce))
|
||||
- Enhance TagInput component with option handling and improved tag addition logic ([b6e778d](https://github.com/perfect-panel/ppanel-web/commit/b6e778d))
|
||||
- Implement data migration functionality and update localization files ([6d81bfd](https://github.com/perfect-panel/ppanel-web/commit/6d81bfd))
|
||||
- Refactor user detail and subscription management components ([973c06f](https://github.com/perfect-panel/ppanel-web/commit/973c06f))
|
||||
- Update server list fetching logic and adjust query parameters ([5272360](https://github.com/perfect-panel/ppanel-web/commit/5272360))
|
||||
|
||||
### 🐛 Bug Fixes
|
||||
|
||||
- **page**: Refine version checking logic and remove unnecessary comments for clarity ([26176a7](https://github.com/perfect-panel/ppanel-web/commit/26176a7))
|
||||
- Add localization updates and new utility functions ([4da5960](https://github.com/perfect-panel/ppanel-web/commit/4da5960))
|
||||
- Add user_subscribe_id filter to SubscribeLogPage and update typings; disable eslint in service index files ([ab6f6a6](https://github.com/perfect-panel/ppanel-web/commit/ab6f6a6))
|
||||
- Added system version card and system log dialog components; updated statistics page to include total server and user statistics ([fe69980](https://github.com/perfect-panel/ppanel-web/commit/fe69980))
|
||||
- Adjust timestamp calculations to use milliseconds instead of seconds in quota broadcast form submission ([8dffd69](https://github.com/perfect-panel/ppanel-web/commit/8dffd69))
|
||||
- Correct cookie key format for sidebar state retrieval ([9e01f4f](https://github.com/perfect-panel/ppanel-web/commit/9e01f4f))
|
||||
- Improve UI for protocol status display in server form component ([461fdb1](https://github.com/perfect-panel/ppanel-web/commit/461fdb1))
|
||||
- Increase pagination size limit for server and node lists to improve data retrieval ([7c0a312](https://github.com/perfect-panel/ppanel-web/commit/7c0a312))
|
||||
- Optimize Task Manager to use milliseconds to calculate timers, and simplify import statements ([d8fa13b](https://github.com/perfect-panel/ppanel-web/commit/d8fa13b))
|
||||
- Refactor protocol status display for improved readability in server form component ([f700be0](https://github.com/perfect-panel/ppanel-web/commit/f700be0))
|
||||
- Remove GroupTable and related components, simplify SubscribeTable and update language handling in subscription forms ([1ab9b39](https://github.com/perfect-panel/ppanel-web/commit/1ab9b39))
|
||||
- Remove redundant transport label from localization files ([88ce8d7](https://github.com/perfect-panel/ppanel-web/commit/88ce8d7))
|
||||
- Remove unnecessary comments and improve variable handling in GoTemplateEditor; ensure zero value displays as empty in EnhancedInput ([c4a47a4](https://github.com/perfect-panel/ppanel-web/commit/c4a47a4))
|
||||
- Remove unnecessary comments to simplify code readability ([a988cb3](https://github.com/perfect-panel/ppanel-web/commit/a988cb3))
|
||||
- Replace MarkdownEditor with HTMLEditor in EmailBroadcastForm; simplify content rendering in EmailTaskManager; disable eslint in service index files ([e2d83ec](https://github.com/perfect-panel/ppanel-web/commit/e2d83ec))
|
||||
- Replace redundant icon rendering with a single instance in system version card component ([e4429a5](https://github.com/perfect-panel/ppanel-web/commit/e4429a5))
|
||||
- Update billing URL fetching logic and improve version handling in system version card component ([1c8d4af](https://github.com/perfect-panel/ppanel-web/commit/1c8d4af))
|
||||
- Update condition for plugin field in PROTOCOL_FIELDS to include specific plugins ([6376ec1](https://github.com/perfect-panel/ppanel-web/commit/6376ec1))
|
||||
- Update getAppSubLink function to improve URL handling and encoding logic ([351fffc](https://github.com/perfect-panel/ppanel-web/commit/351fffc))
|
||||
- Update order_id to order_no in BalanceLogPage and related typings; enhance timezone switch component with additional features and localization updates ([ac36075](https://github.com/perfect-panel/ppanel-web/commit/ac36075))
|
||||
- Update protocol plugin handling and add new options in typings ([6ca2433](https://github.com/perfect-panel/ppanel-web/commit/6ca2433))
|
||||
- Update release URLs to include 'v' prefix for versioning in system version card component ([1d526b5](https://github.com/perfect-panel/ppanel-web/commit/1d526b5))
|
||||
- Update SidebarLeft component styles to enhance hover effects ([e4fbd5c](https://github.com/perfect-panel/ppanel-web/commit/e4fbd5c))
|
||||
- Update validation for days and gift_value fields in QuotaBroadcastForm; set default values to avoid errors ([39d746f](https://github.com/perfect-panel/ppanel-web/commit/39d746f))
|
||||
|
||||
### 📝 Documentation
|
||||
|
||||
* Merge branch 'main' into develop ([d7f8b3b](https://github.com/perfect-panel/ppanel-web/commit/d7f8b3b))
|
||||
- Merge branch 'main' into develop ([d7f8b3b](https://github.com/perfect-panel/ppanel-web/commit/d7f8b3b))
|
||||
|
||||
<a name="readme-top"></a>
|
||||
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import {
|
||||
Form,
|
||||
@@ -81,16 +80,7 @@ export default function CouponForm<T extends Record<string, any>>({
|
||||
|
||||
const type = form.watch('type');
|
||||
|
||||
const { data: subscribe } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 9999,
|
||||
});
|
||||
return data.data?.list as API.Subscribe[];
|
||||
},
|
||||
});
|
||||
const { subscribes } = useSubscribe();
|
||||
|
||||
return (
|
||||
<Sheet open={open} onOpenChange={setOpen}>
|
||||
@@ -247,9 +237,9 @@ export default function CouponForm<T extends Record<string, any>>({
|
||||
onChange={(value) => {
|
||||
form.setValue(field.name, value);
|
||||
}}
|
||||
options={subscribe?.map((item: API.Subscribe) => ({
|
||||
value: item.id,
|
||||
label: item.name,
|
||||
options={subscribes?.map((item) => ({
|
||||
value: item.id!,
|
||||
label: item.name!,
|
||||
}))}
|
||||
/>
|
||||
</FormControl>
|
||||
@@ -307,6 +297,7 @@ export default function CouponForm<T extends Record<string, any>>({
|
||||
<EnhancedInput
|
||||
placeholder={t('form.countPlaceholder')}
|
||||
type='number'
|
||||
min={0}
|
||||
step={1}
|
||||
{...field}
|
||||
onValueChange={(value) => {
|
||||
@@ -328,6 +319,7 @@ export default function CouponForm<T extends Record<string, any>>({
|
||||
<EnhancedInput
|
||||
placeholder={t('form.userLimitPlaceholder')}
|
||||
type='number'
|
||||
min={0}
|
||||
step={1}
|
||||
{...field}
|
||||
onValueChange={(value) => {
|
||||
|
||||
@@ -9,9 +9,8 @@ import {
|
||||
getCouponList,
|
||||
updateCoupon,
|
||||
} from '@/services/admin/coupon';
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { formatDate } from '@/utils/common';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Switch } from '@workspace/ui/components/switch';
|
||||
@@ -24,16 +23,7 @@ import CouponForm from './coupon-form';
|
||||
export default function Page() {
|
||||
const t = useTranslations('coupon');
|
||||
const [loading, setLoading] = useState(false);
|
||||
const { data } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 9999,
|
||||
});
|
||||
return data.data?.list as API.SubscribeGroup[];
|
||||
},
|
||||
});
|
||||
const { subscribes } = useSubscribe();
|
||||
const ref = useRef<ProTableActions>(null);
|
||||
return (
|
||||
<ProTable<API.Coupon, { group_id: number; query: string }>
|
||||
@@ -67,8 +57,8 @@ export default function Page() {
|
||||
{
|
||||
key: 'subscribe',
|
||||
placeholder: t('subscribe'),
|
||||
options: data?.map((item) => ({
|
||||
label: item.name,
|
||||
options: subscribes?.map((item) => ({
|
||||
label: item.name!,
|
||||
value: String(item.id),
|
||||
})),
|
||||
},
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
import { ProTable } from '@/components/pro-table';
|
||||
import { filterServerTrafficLog } from '@/services/admin/log';
|
||||
import { filterServerList } from '@/services/admin/server';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { useServer } from '@/store/server';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { formatBytes } from '@workspace/ui/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
@@ -13,20 +13,10 @@ import { useSearchParams } from 'next/navigation';
|
||||
export default function ServerTrafficLogPage() {
|
||||
const t = useTranslations('log');
|
||||
const sp = useSearchParams();
|
||||
const { getServerName, getServerById } = useServer();
|
||||
|
||||
const today = new Date().toISOString().split('T')[0];
|
||||
|
||||
const { data: servers = [] } = useQuery({
|
||||
queryKey: ['filterServerListAll'],
|
||||
queryFn: async () => {
|
||||
const { data } = await filterServerList({ page: 1, size: 999999999 });
|
||||
return data?.data?.list || [];
|
||||
},
|
||||
});
|
||||
|
||||
const getServerName = (id?: number) =>
|
||||
id ? (servers.find((s) => s.id === id)?.name ?? `Server ${id}`) : 'Unknown';
|
||||
|
||||
const initialFilters = {
|
||||
date: sp.get('date') || today,
|
||||
server_id: sp.get('server_id') ? Number(sp.get('server_id')) : undefined,
|
||||
@@ -50,11 +40,17 @@ export default function ServerTrafficLogPage() {
|
||||
{
|
||||
accessorKey: 'server_id',
|
||||
header: t('column.server'),
|
||||
cell: ({ row }) => (
|
||||
<span>
|
||||
{getServerName(row.original.server_id)} ({row.original.server_id})
|
||||
</span>
|
||||
),
|
||||
cell: ({ row }) => {
|
||||
const server = getServerById(row.original.server_id);
|
||||
const ratio = server?.ratio || 1;
|
||||
return (
|
||||
<div className='flex items-center gap-2'>
|
||||
<Badge>{row.original.server_id}</Badge>
|
||||
<span>{getServerName(row.original.server_id)}</span>
|
||||
<Badge variant='outline'>{ratio}X</Badge>
|
||||
</div>
|
||||
);
|
||||
},
|
||||
},
|
||||
{
|
||||
accessorKey: 'upload',
|
||||
|
||||
@@ -3,9 +3,8 @@
|
||||
import { UserDetail, UserSubscribeDetail } from '@/app/dashboard/user/user-detail';
|
||||
import { ProTable } from '@/components/pro-table';
|
||||
import { filterTrafficLogDetails } from '@/services/admin/log';
|
||||
import { filterServerList } from '@/services/admin/server';
|
||||
import { useServer } from '@/store/server';
|
||||
import { formatDate } from '@/utils/common';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { formatBytes } from '@workspace/ui/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useSearchParams } from 'next/navigation';
|
||||
@@ -13,20 +12,10 @@ import { useSearchParams } from 'next/navigation';
|
||||
export default function TrafficDetailsPage() {
|
||||
const t = useTranslations('log');
|
||||
const sp = useSearchParams();
|
||||
const { getServerName } = useServer();
|
||||
|
||||
const today = new Date().toISOString().split('T')[0];
|
||||
|
||||
const { data: servers = [] } = useQuery({
|
||||
queryKey: ['filterServerListAll'],
|
||||
queryFn: async () => {
|
||||
const { data } = await filterServerList({ page: 1, size: 999999999 });
|
||||
return data?.data?.list || [];
|
||||
},
|
||||
});
|
||||
|
||||
const getServerName = (id?: number) =>
|
||||
id ? (servers.find((s) => s.id === id)?.name ?? `Server ${id}`) : 'Unknown';
|
||||
|
||||
const initialFilters = {
|
||||
date: sp.get('date') || today,
|
||||
server_id: sp.get('server_id') ? Number(sp.get('server_id')) : undefined,
|
||||
|
||||
@@ -2,9 +2,8 @@
|
||||
|
||||
import { Display } from '@/components/display';
|
||||
import { createQuotaTask, queryQuotaTaskPreCount } from '@/services/admin/marketing';
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import {
|
||||
Form,
|
||||
@@ -73,17 +72,7 @@ export default function QuotaBroadcastForm() {
|
||||
const [isSubmitting, setIsSubmitting] = useState(false);
|
||||
const [open, setOpen] = useState(false);
|
||||
|
||||
// Get subscribe list
|
||||
const { data: subscribeList } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 999999999,
|
||||
});
|
||||
return data.data?.list as API.SubscribeItem[];
|
||||
},
|
||||
});
|
||||
const { subscribes } = useSubscribe();
|
||||
|
||||
// Calculate recipient count
|
||||
const calculateRecipients = async () => {
|
||||
@@ -217,21 +206,19 @@ export default function QuotaBroadcastForm() {
|
||||
value={field.value || []}
|
||||
onChange={field.onChange}
|
||||
placeholder={t('pleaseSelectSubscribers')}
|
||||
options={
|
||||
subscribeList?.map((subscribe) => ({
|
||||
value: subscribe.id!,
|
||||
label: subscribe.name!,
|
||||
children: (
|
||||
<div>
|
||||
<div>{subscribe.name}</div>
|
||||
<div className='text-muted-foreground text-xs'>
|
||||
<Display type='traffic' value={subscribe.traffic || 0} /> /{' '}
|
||||
<Display type='currency' value={subscribe.unit_price || 0} />
|
||||
</div>
|
||||
options={subscribes?.map((subscribe) => ({
|
||||
value: subscribe.id!,
|
||||
label: subscribe.name!,
|
||||
children: (
|
||||
<div>
|
||||
<div>{subscribe.name}</div>
|
||||
<div className='text-muted-foreground text-xs'>
|
||||
<Display type='traffic' value={subscribe.traffic || 0} /> /{' '}
|
||||
<Display type='currency' value={subscribe.unit_price || 0} />
|
||||
</div>
|
||||
),
|
||||
})) || []
|
||||
}
|
||||
</div>
|
||||
),
|
||||
}))}
|
||||
/>
|
||||
</FormControl>
|
||||
<FormMessage />
|
||||
|
||||
@@ -3,9 +3,8 @@
|
||||
import { Display } from '@/components/display';
|
||||
import { ProTable } from '@/components/pro-table';
|
||||
import { queryQuotaTaskList } from '@/services/admin/marketing';
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { formatDate } from '@/utils/common';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { ScrollArea } from '@workspace/ui/components/scroll-area';
|
||||
import {
|
||||
@@ -23,21 +22,9 @@ export default function QuotaTaskManager() {
|
||||
const t = useTranslations('marketing');
|
||||
const [open, setOpen] = useState(false);
|
||||
|
||||
// Get subscribe list to show subscription names
|
||||
const { data: subscribeList } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 999999999,
|
||||
});
|
||||
return data.data?.list as API.SubscribeItem[];
|
||||
},
|
||||
});
|
||||
|
||||
// Create a map for quick lookup of subscription names
|
||||
const { subscribes } = useSubscribe();
|
||||
const subscribeMap =
|
||||
subscribeList?.reduce(
|
||||
subscribes?.reduce(
|
||||
(acc, subscribe) => {
|
||||
acc[subscribe.id!] = subscribe.name!;
|
||||
return acc;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
'use client';
|
||||
|
||||
import { filterServerList, queryNodeTag } from '@/services/admin/server';
|
||||
import { useNode } from '@/store/node';
|
||||
import { useServer } from '@/store/server';
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import {
|
||||
Form,
|
||||
@@ -40,8 +40,6 @@ export type ProtocolName =
|
||||
| 'tuic'
|
||||
| 'anytls';
|
||||
|
||||
type ServerRow = API.Server;
|
||||
|
||||
const buildSchema = (t: ReturnType<typeof useTranslations>) =>
|
||||
z.object({
|
||||
name: z.string().trim().min(1, t('errors.nameRequired')),
|
||||
@@ -74,6 +72,20 @@ export default function NodeForm(props: {
|
||||
const Scheme = useMemo(() => buildSchema(t), [t]);
|
||||
const [open, setOpen] = useState(false);
|
||||
|
||||
const [autoFilledFields, setAutoFilledFields] = useState<Set<string>>(new Set());
|
||||
|
||||
const addAutoFilledField = (fieldName: string) => {
|
||||
setAutoFilledFields((prev) => new Set(prev).add(fieldName));
|
||||
};
|
||||
|
||||
const removeAutoFilledField = (fieldName: string) => {
|
||||
setAutoFilledFields((prev) => {
|
||||
const newSet = new Set(prev);
|
||||
newSet.delete(fieldName);
|
||||
return newSet;
|
||||
});
|
||||
};
|
||||
|
||||
const form = useForm<NodeFormValues>({
|
||||
resolver: zodResolver(Scheme),
|
||||
defaultValues: {
|
||||
@@ -89,36 +101,12 @@ export default function NodeForm(props: {
|
||||
|
||||
const serverId = form.watch('server_id');
|
||||
|
||||
const { data } = useQuery({
|
||||
enabled: open,
|
||||
queryKey: ['filterServerListAll'],
|
||||
queryFn: async () => {
|
||||
const { data } = await filterServerList({ page: 1, size: 999999999 });
|
||||
return data?.data?.list || [];
|
||||
},
|
||||
});
|
||||
const servers: ServerRow[] = data as ServerRow[];
|
||||
const { servers, getAvailableProtocols } = useServer();
|
||||
const { tags } = useNode();
|
||||
|
||||
const { data: tagsData } = useQuery({
|
||||
enabled: open,
|
||||
queryKey: ['queryNodeTag'],
|
||||
queryFn: async () => {
|
||||
const { data } = await queryNodeTag();
|
||||
return data?.data?.tags || [];
|
||||
},
|
||||
});
|
||||
const existingTags: string[] = tagsData as string[];
|
||||
const existingTags: string[] = tags || [];
|
||||
|
||||
const currentServer = useMemo(() => servers?.find((s) => s.id === serverId), [servers, serverId]);
|
||||
|
||||
const availableProtocols = useMemo(() => {
|
||||
return (currentServer?.protocols || [])
|
||||
.map((p) => ({
|
||||
protocol: (p as any).type as ProtocolName,
|
||||
port: (p as any).port as number | undefined,
|
||||
}))
|
||||
.filter((p) => !!p.protocol);
|
||||
}, [currentServer]);
|
||||
const availableProtocols = getAvailableProtocols(serverId);
|
||||
|
||||
useEffect(() => {
|
||||
if (initialValues) {
|
||||
@@ -139,60 +127,93 @@ export default function NodeForm(props: {
|
||||
const id = nextId ?? undefined;
|
||||
form.setValue('server_id', id);
|
||||
|
||||
const sel = servers.find((s) => s.id === id);
|
||||
const dirty = form.formState.dirtyFields as Record<string, any>;
|
||||
if (!id) {
|
||||
setAutoFilledFields(new Set());
|
||||
return;
|
||||
}
|
||||
|
||||
const selectedServer = servers.find((s) => s.id === id);
|
||||
if (!selectedServer) return;
|
||||
|
||||
const currentValues = form.getValues();
|
||||
const fieldsToFill: string[] = [];
|
||||
|
||||
if (!dirty.name) {
|
||||
form.setValue('name', (sel?.name as string) || '', { shouldDirty: false });
|
||||
if (!currentValues.name || autoFilledFields.has('name')) {
|
||||
form.setValue('name', selectedServer.name as string, { shouldDirty: false });
|
||||
fieldsToFill.push('name');
|
||||
}
|
||||
|
||||
if (
|
||||
!dirty.address &&
|
||||
(!currentValues.address || currentValues.address === (sel?.address as string))
|
||||
) {
|
||||
form.setValue('address', (sel?.address as string) || '', { shouldDirty: false });
|
||||
if (!currentValues.address || autoFilledFields.has('address')) {
|
||||
form.setValue('address', selectedServer.address as string, { shouldDirty: false });
|
||||
fieldsToFill.push('address');
|
||||
}
|
||||
|
||||
const allowed = (sel?.protocols || [])
|
||||
.map((p) => (p as any).type as ProtocolName)
|
||||
.filter(Boolean);
|
||||
const protocols = getAvailableProtocols(id);
|
||||
const firstProtocol = protocols[0];
|
||||
|
||||
const currentProtocol = form.getValues('protocol') as ProtocolName;
|
||||
if (firstProtocol && (!currentValues.protocol || autoFilledFields.has('protocol'))) {
|
||||
form.setValue('protocol', firstProtocol.protocol, { shouldDirty: false });
|
||||
fieldsToFill.push('protocol');
|
||||
|
||||
if (!allowed.includes(currentProtocol)) {
|
||||
const firstProtocol = allowed[0] || '';
|
||||
form.setValue('protocol', firstProtocol as any);
|
||||
if (!currentValues.port || currentValues.port === 0 || autoFilledFields.has('port')) {
|
||||
const port = firstProtocol.port || 0;
|
||||
form.setValue('port', port, { shouldDirty: false });
|
||||
fieldsToFill.push('port');
|
||||
}
|
||||
}
|
||||
|
||||
if (firstProtocol) {
|
||||
handleProtocolChange(firstProtocol);
|
||||
setAutoFilledFields(new Set(fieldsToFill));
|
||||
}
|
||||
|
||||
const handleManualFieldChange = (fieldName: keyof NodeFormValues, value: any) => {
|
||||
form.setValue(fieldName, value);
|
||||
removeAutoFilledField(fieldName);
|
||||
};
|
||||
|
||||
function handleProtocolChange(nextProto?: ProtocolName | null) {
|
||||
const protocol = (nextProto || '') as ProtocolName | '';
|
||||
form.setValue('protocol', protocol);
|
||||
|
||||
if (!protocol || !serverId) {
|
||||
removeAutoFilledField('protocol');
|
||||
return;
|
||||
}
|
||||
|
||||
const currentValues = form.getValues();
|
||||
const isPortAutoFilled = autoFilledFields.has('port');
|
||||
|
||||
removeAutoFilledField('protocol');
|
||||
|
||||
if (!currentValues.port || currentValues.port === 0 || isPortAutoFilled) {
|
||||
const protocolData = availableProtocols.find((p) => p.protocol === protocol);
|
||||
|
||||
if (protocolData) {
|
||||
const port = protocolData.port || 0;
|
||||
form.setValue('port', port, { shouldDirty: false });
|
||||
addAutoFilledField('port');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function handleProtocolChange(nextProto?: ProtocolName | null) {
|
||||
const p = (nextProto || '') as ProtocolName | '';
|
||||
form.setValue('protocol', p);
|
||||
if (!p || !currentServer) return;
|
||||
|
||||
const dirty = form.formState.dirtyFields as Record<string, any>;
|
||||
const currentValues = form.getValues();
|
||||
|
||||
if (!dirty.port) {
|
||||
const hit = (currentServer.protocols as any[]).find((x) => (x as any).type === p);
|
||||
const port = (hit as any)?.port as number | undefined;
|
||||
const newPort = typeof port === 'number' && port > 0 ? port : 0;
|
||||
|
||||
if (!currentValues.port || currentValues.port === 0 || currentValues.port === newPort) {
|
||||
form.setValue('port', newPort, { shouldDirty: false });
|
||||
}
|
||||
async function handleSubmit(values: NodeFormValues) {
|
||||
const result = await onSubmit(values);
|
||||
if (result) {
|
||||
setOpen(false);
|
||||
setAutoFilledFields(new Set());
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<Sheet open={open} onOpenChange={setOpen}>
|
||||
<SheetTrigger asChild>
|
||||
<Button onClick={() => form.reset()}>{trigger}</Button>
|
||||
<Button
|
||||
onClick={() => {
|
||||
form.reset();
|
||||
setAutoFilledFields(new Set());
|
||||
}}
|
||||
>
|
||||
{trigger}
|
||||
</Button>
|
||||
</SheetTrigger>
|
||||
|
||||
<SheetContent className='w-[560px] max-w-full'>
|
||||
@@ -253,7 +274,7 @@ export default function NodeForm(props: {
|
||||
<FormControl>
|
||||
<EnhancedInput
|
||||
{...field}
|
||||
onValueChange={(v) => form.setValue(field.name, v as string)}
|
||||
onValueChange={(v) => handleManualFieldChange('name', v as string)}
|
||||
/>
|
||||
</FormControl>
|
||||
<FormMessage />
|
||||
@@ -270,7 +291,7 @@ export default function NodeForm(props: {
|
||||
<FormControl>
|
||||
<EnhancedInput
|
||||
{...field}
|
||||
onValueChange={(v) => form.setValue(field.name, v as string)}
|
||||
onValueChange={(v) => handleManualFieldChange('address', v as string)}
|
||||
/>
|
||||
</FormControl>
|
||||
<FormMessage />
|
||||
@@ -291,7 +312,7 @@ export default function NodeForm(props: {
|
||||
min={1}
|
||||
max={65535}
|
||||
placeholder='1-65535'
|
||||
onValueChange={(v) => form.setValue(field.name, Number(v))}
|
||||
onValueChange={(v) => handleManualFieldChange('port', Number(v))}
|
||||
/>
|
||||
</FormControl>
|
||||
<FormMessage />
|
||||
@@ -327,7 +348,7 @@ export default function NodeForm(props: {
|
||||
</Button>
|
||||
<Button
|
||||
disabled={loading}
|
||||
onClick={form.handleSubmit(onSubmit, (errors) => {
|
||||
onClick={form.handleSubmit(handleSubmit, (errors) => {
|
||||
const key = Object.keys(errors)[0] as keyof typeof errors;
|
||||
if (key) toast.error(String(errors[key]?.message));
|
||||
return false;
|
||||
|
||||
@@ -5,12 +5,12 @@ import {
|
||||
createNode,
|
||||
deleteNode,
|
||||
filterNodeList,
|
||||
filterServerList,
|
||||
resetSortWithNode,
|
||||
toggleNodeStatus,
|
||||
updateNode,
|
||||
} from '@/services/admin/server';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { useNode } from '@/store/node';
|
||||
import { useServer } from '@/store/server';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Switch } from '@workspace/ui/components/switch';
|
||||
@@ -25,24 +25,9 @@ export default function NodesPage() {
|
||||
const ref = useRef<ProTableActions>(null);
|
||||
const [loading, setLoading] = useState(false);
|
||||
|
||||
const { data: servers = [] } = useQuery({
|
||||
queryKey: ['filterServerListAll'],
|
||||
queryFn: async () => {
|
||||
const { data } = await filterServerList({ page: 1, size: 999999999 });
|
||||
return data?.data?.list || [];
|
||||
},
|
||||
});
|
||||
|
||||
const getServerName = (id?: number) =>
|
||||
id ? (servers.find((s) => s.id === id)?.name ?? `#${id}`) : '—';
|
||||
const getServerOriginAddr = (id?: number) =>
|
||||
id ? (servers.find((s) => s.id === id)?.address ?? '—') : '—';
|
||||
const getProtocolOriginPort = (id?: number, proto?: string) => {
|
||||
if (!id || !proto) return '—';
|
||||
const hit = servers.find((s) => s.id === id)?.protocols?.find((p) => (p as any).type === proto);
|
||||
const p = (hit as any)?.port as number | undefined;
|
||||
return typeof p === 'number' ? String(p) : '—';
|
||||
};
|
||||
// Use our zustand store for server data
|
||||
const { getServerName, getServerAddress, getProtocolPort } = useServer();
|
||||
const { fetchNodes, fetchTags } = useNode();
|
||||
|
||||
return (
|
||||
<ProTable<API.Node, { search: string }>
|
||||
@@ -69,6 +54,8 @@ export default function NodesPage() {
|
||||
await createNode(body);
|
||||
toast.success(t('created'));
|
||||
ref.current?.refresh();
|
||||
fetchNodes();
|
||||
fetchTags();
|
||||
setLoading(false);
|
||||
return true;
|
||||
} catch (e) {
|
||||
@@ -90,6 +77,8 @@ export default function NodesPage() {
|
||||
await toggleNodeStatus({ id: row.original.id, enable: v });
|
||||
toast.success(v ? t('enabled_on') : t('enabled_off'));
|
||||
ref.current?.refresh();
|
||||
fetchNodes();
|
||||
fetchTags();
|
||||
}}
|
||||
/>
|
||||
),
|
||||
@@ -99,24 +88,20 @@ export default function NodesPage() {
|
||||
{
|
||||
id: 'address_port',
|
||||
header: `${t('address')}:${t('port')}`,
|
||||
cell: ({ row }) => (row.original.address || '—') + ':' + (row.original.port ?? '—'),
|
||||
cell: ({ row }) => `${row.original.address || '—'}:${row.original.port || '—'}`,
|
||||
},
|
||||
|
||||
{
|
||||
id: 'server_id',
|
||||
header: t('server'),
|
||||
cell: ({ row }) => (
|
||||
<div className='flex flex-wrap gap-2'>
|
||||
<Badge variant='outline'>
|
||||
{getServerName(row.original.server_id)} ·{' '}
|
||||
{getServerOriginAddr(row.original.server_id)}
|
||||
</Badge>
|
||||
<Badge variant='outline'>
|
||||
{row.original.protocol || '—'} ·{' '}
|
||||
{getProtocolOriginPort(row.original.server_id, row.original.protocol)}
|
||||
</Badge>
|
||||
</div>
|
||||
),
|
||||
cell: ({ row }) =>
|
||||
`${getServerName(row.original.server_id)}:${getServerAddress(row.original.server_id)}`,
|
||||
},
|
||||
{
|
||||
id: 'protocol',
|
||||
header: ` ${t('protocol')}:${t('port')}`,
|
||||
cell: ({ row }) =>
|
||||
`${row.original.protocol}:${getProtocolPort(row.original.server_id, row.original.protocol)}`,
|
||||
},
|
||||
{
|
||||
accessorKey: 'tags',
|
||||
@@ -152,30 +137,19 @@ export default function NodesPage() {
|
||||
trigger={t('edit')}
|
||||
title={t('drawerEditTitle')}
|
||||
loading={loading}
|
||||
initialValues={{
|
||||
name: row.name,
|
||||
server_id: row.server_id,
|
||||
protocol: row.protocol as any,
|
||||
address: row.address as any,
|
||||
port: row.port as any,
|
||||
tags: (row.tags as any) || [],
|
||||
}}
|
||||
initialValues={row}
|
||||
onSubmit={async (values) => {
|
||||
setLoading(true);
|
||||
try {
|
||||
const body: API.UpdateNodeRequest = {
|
||||
id: row.id,
|
||||
name: values.name,
|
||||
server_id: Number(values.server_id!),
|
||||
protocol: values.protocol,
|
||||
address: values.address,
|
||||
port: Number(values.port!),
|
||||
tags: values.tags || [],
|
||||
enabled: row.enabled,
|
||||
...row,
|
||||
...values,
|
||||
} as any;
|
||||
await updateNode(body);
|
||||
toast.success(t('updated'));
|
||||
ref.current?.refresh();
|
||||
fetchNodes();
|
||||
fetchTags();
|
||||
setLoading(false);
|
||||
return true;
|
||||
} catch (e) {
|
||||
@@ -193,6 +167,8 @@ export default function NodesPage() {
|
||||
await deleteNode({ id: row.id } as any);
|
||||
toast.success(t('deleted'));
|
||||
ref.current?.refresh();
|
||||
fetchNodes();
|
||||
fetchTags();
|
||||
}}
|
||||
cancelText={t('cancel')}
|
||||
confirmText={t('confirm')}
|
||||
@@ -201,18 +177,15 @@ export default function NodesPage() {
|
||||
key='copy'
|
||||
variant='outline'
|
||||
onClick={async () => {
|
||||
const { id, enabled, created_at, updated_at, ...rest } = row as any;
|
||||
const { id, enabled, created_at, updated_at, sort, ...rest } = row as any;
|
||||
await createNode({
|
||||
name: rest.name,
|
||||
server_id: rest.server_id,
|
||||
protocol: rest.protocol,
|
||||
address: rest.address,
|
||||
port: rest.port,
|
||||
tags: rest.tags || [],
|
||||
...rest,
|
||||
enabled: false,
|
||||
} as any);
|
||||
});
|
||||
toast.success(t('copied'));
|
||||
ref.current?.refresh();
|
||||
fetchNodes();
|
||||
fetchTags();
|
||||
}}
|
||||
>
|
||||
{t('copy')}
|
||||
@@ -229,6 +202,8 @@ export default function NodesPage() {
|
||||
await Promise.all(rows.map((r) => deleteNode({ id: r.id } as any)));
|
||||
toast.success(t('deleted'));
|
||||
ref.current?.refresh();
|
||||
fetchNodes();
|
||||
fetchTags();
|
||||
}}
|
||||
cancelText={t('cancel')}
|
||||
confirmText={t('confirm')}
|
||||
@@ -262,6 +237,7 @@ export default function NodesPage() {
|
||||
sort: item.sort,
|
||||
})) as API.SortItem[],
|
||||
});
|
||||
toast.success(t('sorted_success'));
|
||||
}
|
||||
return updatedItems;
|
||||
}}
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
'use client';
|
||||
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useSearchParams } from 'next/navigation';
|
||||
import { useRef } from 'react';
|
||||
@@ -8,7 +7,7 @@ import { useRef } from 'react';
|
||||
import { Display } from '@/components/display';
|
||||
import { ProTable, ProTableActions } from '@/components/pro-table';
|
||||
import { getOrderList, updateOrderStatus } from '@/services/admin/order';
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { formatDate } from '@/utils/common';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
@@ -32,16 +31,7 @@ export default function Page() {
|
||||
|
||||
const ref = useRef<ProTableActions>(null);
|
||||
|
||||
const { data: subscribeList } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 999999999,
|
||||
});
|
||||
return data.data?.list as API.SubscribeGroup[];
|
||||
},
|
||||
});
|
||||
const { subscribes, getSubscribeName } = useSubscribe();
|
||||
|
||||
const initialFilters = {
|
||||
search: sp.get('search') || undefined,
|
||||
@@ -68,9 +58,10 @@ export default function Page() {
|
||||
accessorKey: 'subscribe_id',
|
||||
header: t('subscribe'),
|
||||
cell: ({ row }) => {
|
||||
const name = subscribeList?.find(
|
||||
(item) => item.id === row.getValue('subscribe_id'),
|
||||
)?.name;
|
||||
if (row.original.type === 4) {
|
||||
return t(`type.${row.getValue('type')}`);
|
||||
}
|
||||
const name = getSubscribeName(row.getValue('subscribe_id'));
|
||||
const quantity = row.original.quantity;
|
||||
return name ? `${name} × ${quantity}` : '';
|
||||
},
|
||||
@@ -186,8 +177,8 @@ export default function Page() {
|
||||
{
|
||||
key: 'subscribe_id',
|
||||
placeholder: `${t('subscribe')}`,
|
||||
options: subscribeList?.map((item) => ({
|
||||
label: item.name,
|
||||
options: subscribes?.map((item) => ({
|
||||
label: item.name!,
|
||||
value: String(item.id),
|
||||
})),
|
||||
},
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
import { getTranslations } from 'next-intl/server';
|
||||
|
||||
import SubscribeTable from './subscribe-table';
|
||||
|
||||
export default async function Page() {
|
||||
const t = await getTranslations('product');
|
||||
|
||||
return <SubscribeTable />;
|
||||
}
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import { filterNodeList, queryNodeTag } from '@/services/admin/server';
|
||||
import { useNode } from '@/store/node';
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import {
|
||||
Accordion,
|
||||
AccordionContent,
|
||||
@@ -229,35 +228,9 @@ export default function SubscribeForm<T extends Record<string, any>>({
|
||||
if (bool) setOpen(false);
|
||||
}
|
||||
|
||||
const { data: nodes } = useQuery({
|
||||
queryKey: ['filterNodeListAll'],
|
||||
queryFn: async () => {
|
||||
const { data } = await filterNodeList({ page: 1, size: 999999999 });
|
||||
return (data.data?.list || []) as API.Node[];
|
||||
},
|
||||
});
|
||||
const { nodes, getAllAvailableTags, getNodesByTag, getNodesWithoutTags } = useNode();
|
||||
|
||||
const { data: allTagsData } = useQuery({
|
||||
queryKey: ['queryNodeTag'],
|
||||
queryFn: async () => {
|
||||
const { data } = await queryNodeTag();
|
||||
return data?.data?.tags || [];
|
||||
},
|
||||
});
|
||||
|
||||
const nodeExtractedTags = Array.from(
|
||||
new Set(
|
||||
((nodes as API.Node[]) || [])
|
||||
.flatMap((n) => (Array.isArray(n.tags) ? n.tags : []))
|
||||
.filter(Boolean),
|
||||
),
|
||||
) as string[];
|
||||
|
||||
const allAvailableTags = (allTagsData as string[]) || [];
|
||||
|
||||
const tagGroups = Array.from(new Set([...allAvailableTags, ...nodeExtractedTags])).filter(
|
||||
Boolean,
|
||||
);
|
||||
const tagGroups = getAllAvailableTags();
|
||||
|
||||
const unit_time = form.watch('unit_time');
|
||||
|
||||
@@ -806,10 +779,7 @@ export default function SubscribeForm<T extends Record<string, any>>({
|
||||
{tagGroups.map((tag) => {
|
||||
const value = field.value || [];
|
||||
const tagId = tag;
|
||||
const nodesWithTag =
|
||||
(nodes as API.Node[])?.filter((n) =>
|
||||
(n.tags || []).includes(tag),
|
||||
) || [];
|
||||
const nodesWithTag = getNodesByTag(tag);
|
||||
|
||||
return (
|
||||
<AccordionItem key={tag} value={String(tag)}>
|
||||
@@ -836,22 +806,20 @@ export default function SubscribeForm<T extends Record<string, any>>({
|
||||
</AccordionTrigger>
|
||||
<AccordionContent>
|
||||
<ul className='space-y-1'>
|
||||
{(nodes as API.Node[])
|
||||
?.filter((n) => (n.tags || []).includes(tag))
|
||||
?.map((node) => (
|
||||
<li
|
||||
key={node.id}
|
||||
className='flex items-center justify-between gap-3'
|
||||
>
|
||||
<span className='flex-1'>{node.name}</span>
|
||||
<span className='flex-1'>
|
||||
{node.address}:{node.port}
|
||||
</span>
|
||||
<span className='flex-1 text-right'>
|
||||
{node.protocol}
|
||||
</span>
|
||||
</li>
|
||||
))}
|
||||
{getNodesByTag(tag).map((node) => (
|
||||
<li
|
||||
key={node.id}
|
||||
className='flex items-center justify-between gap-3'
|
||||
>
|
||||
<span className='flex-1'>{node.name}</span>
|
||||
<span className='flex-1'>
|
||||
{node.address}:{node.port}
|
||||
</span>
|
||||
<span className='flex-1 text-right'>
|
||||
{node.protocol}
|
||||
</span>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</AccordionContent>
|
||||
</AccordionItem>
|
||||
@@ -872,34 +840,32 @@ export default function SubscribeForm<T extends Record<string, any>>({
|
||||
<FormLabel>{t('form.node')}</FormLabel>
|
||||
<FormControl>
|
||||
<div className='flex flex-col gap-2'>
|
||||
{(nodes as API.Node[])
|
||||
?.filter((item) => (item.tags || []).length === 0)
|
||||
?.map((item) => {
|
||||
const value = field.value || [];
|
||||
{getNodesWithoutTags().map((item) => {
|
||||
const value = field.value || [];
|
||||
|
||||
return (
|
||||
<div className='flex items-center gap-2' key={item.id}>
|
||||
<Checkbox
|
||||
checked={value.includes(item.id!)}
|
||||
onCheckedChange={(checked) => {
|
||||
return checked
|
||||
? form.setValue(field.name, [...value, item.id])
|
||||
: form.setValue(
|
||||
field.name,
|
||||
value.filter((value: number) => value !== item.id),
|
||||
);
|
||||
}}
|
||||
/>
|
||||
<Label className='flex w-full items-center justify-between gap-3'>
|
||||
<span className='flex-1'>{item.name}</span>
|
||||
<span className='flex-1'>
|
||||
{item.address}:{item.port}
|
||||
</span>
|
||||
<span className='flex-1 text-right'>{item.protocol}</span>
|
||||
</Label>
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
return (
|
||||
<div className='flex items-center gap-2' key={item.id}>
|
||||
<Checkbox
|
||||
checked={value.includes(item.id!)}
|
||||
onCheckedChange={(checked) => {
|
||||
return checked
|
||||
? form.setValue(field.name, [...value, item.id])
|
||||
: form.setValue(
|
||||
field.name,
|
||||
value.filter((value: number) => value !== item.id),
|
||||
);
|
||||
}}
|
||||
/>
|
||||
<Label className='flex w-full items-center justify-between gap-3'>
|
||||
<span className='flex-1'>{item.name}</span>
|
||||
<span className='flex-1'>
|
||||
{item.address}:{item.port}
|
||||
</span>
|
||||
<span className='flex-1 text-right'>{item.protocol}</span>
|
||||
</Label>
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
</FormControl>
|
||||
<FormMessage />
|
||||
|
||||
@@ -10,6 +10,7 @@ import {
|
||||
subscribeSort,
|
||||
updateSubscribe,
|
||||
} from '@/services/admin/subscribe';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Switch } from '@workspace/ui/components/switch';
|
||||
@@ -23,6 +24,7 @@ export default function SubscribeTable() {
|
||||
const t = useTranslations('product');
|
||||
const [loading, setLoading] = useState(false);
|
||||
const ref = useRef<ProTableActions>(null);
|
||||
const { fetchSubscribes } = useSubscribe();
|
||||
return (
|
||||
<ProTable<API.SubscribeItem, { group_id: number; query: string }>
|
||||
action={ref}
|
||||
@@ -42,6 +44,7 @@ export default function SubscribeTable() {
|
||||
});
|
||||
toast.success(t('createSuccess'));
|
||||
ref.current?.refresh();
|
||||
fetchSubscribes();
|
||||
setLoading(false);
|
||||
|
||||
return true;
|
||||
@@ -83,6 +86,7 @@ export default function SubscribeTable() {
|
||||
show: checked,
|
||||
} as API.UpdateSubscribeRequest);
|
||||
ref.current?.refresh();
|
||||
fetchSubscribes();
|
||||
}}
|
||||
/>
|
||||
);
|
||||
@@ -101,6 +105,7 @@ export default function SubscribeTable() {
|
||||
sell: checked,
|
||||
} as API.UpdateSubscribeRequest);
|
||||
ref.current?.refresh();
|
||||
fetchSubscribes();
|
||||
}}
|
||||
/>
|
||||
);
|
||||
@@ -186,6 +191,7 @@ export default function SubscribeTable() {
|
||||
} as API.UpdateSubscribeRequest);
|
||||
toast.success(t('updateSuccess'));
|
||||
ref.current?.refresh();
|
||||
fetchSubscribes();
|
||||
setLoading(false);
|
||||
return true;
|
||||
} catch (error) {
|
||||
@@ -206,6 +212,7 @@ export default function SubscribeTable() {
|
||||
});
|
||||
toast.success(t('deleteSuccess'));
|
||||
ref.current?.refresh();
|
||||
fetchSubscribes();
|
||||
}}
|
||||
cancelText={t('cancel')}
|
||||
confirmText={t('confirm')}
|
||||
@@ -224,6 +231,7 @@ export default function SubscribeTable() {
|
||||
} as API.CreateSubscribeRequest);
|
||||
toast.success(t('copySuccess'));
|
||||
ref.current?.refresh();
|
||||
fetchSubscribes();
|
||||
setLoading(false);
|
||||
return true;
|
||||
} catch (error) {
|
||||
@@ -248,6 +256,7 @@ export default function SubscribeTable() {
|
||||
|
||||
toast.success(t('deleteSuccess'));
|
||||
ref.current?.reset();
|
||||
fetchSubscribes();
|
||||
}}
|
||||
cancelText={t('cancel')}
|
||||
confirmText={t('confirm')}
|
||||
|
||||
@@ -0,0 +1,99 @@
|
||||
export const protocols = [
|
||||
'shadowsocks',
|
||||
'vmess',
|
||||
'vless',
|
||||
'trojan',
|
||||
'hysteria2',
|
||||
'tuic',
|
||||
'anytls',
|
||||
'socks',
|
||||
'naive',
|
||||
'http',
|
||||
'mieru',
|
||||
] as const;
|
||||
|
||||
// Global label map for display; fallback to raw value if missing
|
||||
export const LABELS = {
|
||||
// transport
|
||||
'tcp': 'TCP',
|
||||
'udp': 'UDP',
|
||||
'websocket': 'WebSocket',
|
||||
'grpc': 'gRPC',
|
||||
'mkcp': 'mKCP',
|
||||
'httpupgrade': 'HTTP Upgrade',
|
||||
'xhttp': 'XHTTP',
|
||||
// security
|
||||
'none': 'NONE',
|
||||
'tls': 'TLS',
|
||||
'reality': 'Reality',
|
||||
// fingerprint
|
||||
'chrome': 'Chrome',
|
||||
'firefox': 'Firefox',
|
||||
'safari': 'Safari',
|
||||
'ios': 'IOS',
|
||||
'android': 'Android',
|
||||
'edge': 'edge',
|
||||
'360': '360',
|
||||
'qq': 'QQ',
|
||||
// multiplex
|
||||
'low': 'Low',
|
||||
'middle': 'Middle',
|
||||
'high': 'High',
|
||||
} as const;
|
||||
|
||||
// Flat arrays for enum-like sets
|
||||
export const SS_CIPHERS = [
|
||||
'aes-128-gcm',
|
||||
'aes-192-gcm',
|
||||
'aes-256-gcm',
|
||||
'chacha20-ietf-poly1305',
|
||||
'2022-blake3-aes-128-gcm',
|
||||
'2022-blake3-aes-256-gcm',
|
||||
'2022-blake3-chacha20-poly1305',
|
||||
] as const;
|
||||
|
||||
export const TRANSPORTS = {
|
||||
vmess: ['tcp', 'websocket', 'grpc'] as const,
|
||||
vless: ['tcp', 'websocket', 'grpc', 'mkcp', 'httpupgrade', 'xhttp'] as const,
|
||||
trojan: ['tcp', 'websocket', 'grpc'] as const,
|
||||
mieru: ['tcp', 'udp'] as const,
|
||||
} as const;
|
||||
|
||||
export const SECURITY = {
|
||||
vmess: ['none', 'tls'] as const,
|
||||
vless: ['none', 'tls', 'reality'] as const,
|
||||
trojan: ['tls'] as const,
|
||||
hysteria2: ['tls'] as const,
|
||||
tuic: ['tls'] as const,
|
||||
anytls: ['tls'] as const,
|
||||
naive: ['none', 'tls'] as const,
|
||||
http: ['none', 'tls'] as const,
|
||||
} as const;
|
||||
|
||||
export const FLOWS = {
|
||||
vless: ['none', 'xtls-rprx-direct', 'xtls-rprx-splice', 'xtls-rprx-vision'] as const,
|
||||
} as const;
|
||||
|
||||
export const TUIC_UDP_RELAY_MODES = ['native', 'quic'] as const;
|
||||
export const TUIC_CONGESTION = ['bbr', 'cubic', 'new_reno'] as const;
|
||||
export const XHTTP_MODES = ['auto', 'packet-up', 'stream-up', 'stream-one'] as const;
|
||||
export const ENCRYPTION_TYPES = ['none', 'mlkem768x25519plus'] as const;
|
||||
export const ENCRYPTION_MODES = ['native', 'xorpub', 'random'] as const;
|
||||
export const ENCRYPTION_RTT = ['0rtt', '1rtt'] as const;
|
||||
export const FINGERPRINTS = [
|
||||
'chrome',
|
||||
'firefox',
|
||||
'safari',
|
||||
'ios',
|
||||
'android',
|
||||
'edge',
|
||||
'360',
|
||||
'qq',
|
||||
] as const;
|
||||
|
||||
export const multiplexLevels = ['none', 'low', 'middle', 'high'] as const;
|
||||
|
||||
export function getLabel(value: string): string {
|
||||
const label = (LABELS as Record<string, string>)[value];
|
||||
return label ?? value.toUpperCase();
|
||||
}
|
||||
@@ -0,0 +1,113 @@
|
||||
import { XHTTP_MODES } from './constants';
|
||||
import type { ProtocolType } from './types';
|
||||
|
||||
export function getProtocolDefaultConfig(proto: ProtocolType) {
|
||||
switch (proto) {
|
||||
case 'shadowsocks':
|
||||
return {
|
||||
type: 'shadowsocks',
|
||||
enable: false,
|
||||
port: null,
|
||||
cipher: 'chacha20-ietf-poly1305',
|
||||
server_key: null,
|
||||
obfs: 'none',
|
||||
obfs_host: null,
|
||||
obfs_path: null,
|
||||
} as any;
|
||||
case 'vmess':
|
||||
return {
|
||||
type: 'vmess',
|
||||
enable: false,
|
||||
port: null,
|
||||
transport: 'tcp',
|
||||
security: 'none',
|
||||
} as any;
|
||||
case 'vless':
|
||||
return {
|
||||
type: 'vless',
|
||||
enable: false,
|
||||
port: null,
|
||||
transport: 'tcp',
|
||||
security: 'none',
|
||||
flow: 'none',
|
||||
xhttp_mode: XHTTP_MODES[0], // 'auto'
|
||||
xhttp_extra: null,
|
||||
} as any;
|
||||
case 'trojan':
|
||||
return {
|
||||
type: 'trojan',
|
||||
enable: false,
|
||||
port: null,
|
||||
transport: 'tcp',
|
||||
security: 'tls',
|
||||
} as any;
|
||||
case 'hysteria2':
|
||||
return {
|
||||
type: 'hysteria2',
|
||||
enable: false,
|
||||
port: null,
|
||||
hop_ports: null,
|
||||
hop_interval: null,
|
||||
obfs: 'none',
|
||||
obfs_password: null,
|
||||
security: 'tls',
|
||||
up_mbps: null,
|
||||
down_mbps: null,
|
||||
} as any;
|
||||
case 'tuic':
|
||||
return {
|
||||
type: 'tuic',
|
||||
enable: false,
|
||||
port: null,
|
||||
disable_sni: false,
|
||||
reduce_rtt: false,
|
||||
udp_relay_mode: 'native',
|
||||
congestion_controller: 'bbr',
|
||||
security: 'tls',
|
||||
sni: null,
|
||||
allow_insecure: false,
|
||||
fingerprint: 'chrome',
|
||||
} as any;
|
||||
case 'socks':
|
||||
return {
|
||||
type: 'socks',
|
||||
enable: false,
|
||||
port: null,
|
||||
} as any;
|
||||
case 'naive':
|
||||
return {
|
||||
type: 'naive',
|
||||
enable: false,
|
||||
port: null,
|
||||
security: 'none',
|
||||
} as any;
|
||||
case 'http':
|
||||
return {
|
||||
type: 'http',
|
||||
enable: false,
|
||||
port: null,
|
||||
security: 'none',
|
||||
} as any;
|
||||
case 'mieru':
|
||||
return {
|
||||
type: 'mieru',
|
||||
enable: false,
|
||||
port: null,
|
||||
multiplex: 'none',
|
||||
transport: 'tcp',
|
||||
} as any;
|
||||
case 'anytls':
|
||||
return {
|
||||
type: 'anytls',
|
||||
enable: false,
|
||||
port: null,
|
||||
security: 'tls',
|
||||
padding_scheme: null,
|
||||
sni: null,
|
||||
allow_insecure: false,
|
||||
fingerprint: 'chrome',
|
||||
} as any;
|
||||
default:
|
||||
return {} as any;
|
||||
}
|
||||
}
|
||||
+173
-387
@@ -1,357 +1,24 @@
|
||||
import { z } from 'zod';
|
||||
|
||||
export const protocols = [
|
||||
'shadowsocks',
|
||||
'vmess',
|
||||
'vless',
|
||||
'trojan',
|
||||
'hysteria2',
|
||||
'tuic',
|
||||
'anytls',
|
||||
'socks',
|
||||
'naive',
|
||||
'http',
|
||||
'meru',
|
||||
] as const;
|
||||
|
||||
export type FieldConfig = {
|
||||
name: string;
|
||||
type: 'input' | 'select' | 'switch' | 'number' | 'textarea';
|
||||
label: string;
|
||||
placeholder?: string | ((t: (key: string) => string, protocol: any) => string);
|
||||
options?: readonly string[];
|
||||
defaultValue?: any;
|
||||
min?: number;
|
||||
max?: number;
|
||||
step?: number;
|
||||
suffix?: string;
|
||||
password?: number;
|
||||
condition?: (protocol: any, values: any) => boolean;
|
||||
group?: 'basic' | 'transport' | 'security' | 'reality' | 'plugin';
|
||||
gridSpan?: 1 | 2;
|
||||
};
|
||||
|
||||
// Global label map for display; fallback to raw value if missing
|
||||
export const LABELS = {
|
||||
// transport
|
||||
'tcp': 'TCP',
|
||||
'udp': 'UDP',
|
||||
'websocket': 'WebSocket',
|
||||
'grpc': 'gRPC',
|
||||
'mkcp': 'mKCP',
|
||||
'httpupgrade': 'HTTP Upgrade',
|
||||
'xhttp': 'XHTTP',
|
||||
// security
|
||||
'none': 'NONE',
|
||||
'tls': 'TLS',
|
||||
'reality': 'Reality',
|
||||
// fingerprint
|
||||
'chrome': 'Chrome',
|
||||
'firefox': 'Firefox',
|
||||
'safari': 'Safari',
|
||||
'ios': 'IOS',
|
||||
'android': 'Android',
|
||||
'edge': 'edge',
|
||||
'360': '360',
|
||||
'qq': 'QQ',
|
||||
// multiplex
|
||||
'off': 'Off',
|
||||
'low': 'Low',
|
||||
'middle': 'Middle',
|
||||
'high': 'High',
|
||||
// ss plugins
|
||||
'v2ray-plugin': 'V2Ray Plugin',
|
||||
'simple-obfs': 'Simple Obfs',
|
||||
} as const;
|
||||
|
||||
// Flat arrays for enum-like sets
|
||||
export const SS_CIPHERS = [
|
||||
'aes-128-gcm',
|
||||
'aes-192-gcm',
|
||||
'aes-256-gcm',
|
||||
'chacha20-ietf-poly1305',
|
||||
'2022-blake3-aes-128-gcm',
|
||||
'2022-blake3-aes-256-gcm',
|
||||
'2022-blake3-chacha20-poly1305',
|
||||
] as const;
|
||||
|
||||
export const SS_PLUGINS = ['none', 'simple-obfs', 'v2ray-plugin'] as const;
|
||||
|
||||
export const TRANSPORTS = {
|
||||
vmess: ['tcp', 'websocket', 'grpc'] as const,
|
||||
vless: ['tcp', 'websocket', 'grpc', 'mkcp', 'httpupgrade', 'xhttp'] as const,
|
||||
trojan: ['tcp', 'websocket', 'grpc'] as const,
|
||||
meru: ['tcp', 'udp'] as const,
|
||||
} as const;
|
||||
|
||||
export const SECURITY = {
|
||||
vmess: ['none', 'tls'] as const,
|
||||
vless: ['none', 'tls', 'reality'] as const,
|
||||
trojan: ['tls'] as const,
|
||||
hysteria2: ['tls'] as const,
|
||||
tuic: ['tls'] as const,
|
||||
anytls: ['tls'] as const,
|
||||
naive: ['none', 'tls'] as const,
|
||||
http: ['none', 'tls'] as const,
|
||||
} as const;
|
||||
|
||||
export const FLOWS = {
|
||||
vless: ['none', 'xtls-rprx-direct', 'xtls-rprx-splice', 'xtls-rprx-vision'] as const,
|
||||
} as const;
|
||||
|
||||
export const TUIC_UDP_RELAY_MODES = ['native', 'quic'] as const;
|
||||
export const TUIC_CONGESTION = ['bbr', 'cubic', 'new_reno'] as const;
|
||||
export const FINGERPRINTS = [
|
||||
'chrome',
|
||||
'firefox',
|
||||
'safari',
|
||||
'ios',
|
||||
'android',
|
||||
'edge',
|
||||
'360',
|
||||
'qq',
|
||||
] as const;
|
||||
|
||||
export const multiplexLevels = ['off', 'low', 'middle', 'high'] as const;
|
||||
|
||||
export function getLabel(value: string): string {
|
||||
const label = (LABELS as Record<string, string>)[value];
|
||||
return label ?? value.toUpperCase();
|
||||
}
|
||||
|
||||
const nullableString = z.string().nullish();
|
||||
const nullableBool = z.boolean().nullish();
|
||||
const nullablePort = z.number().int().min(0).max(65535).nullish();
|
||||
|
||||
const ss = z.object({
|
||||
type: z.literal('shadowsocks'),
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
cipher: z.enum(SS_CIPHERS as any).nullish(),
|
||||
server_key: nullableString,
|
||||
plugin: z.enum(SS_PLUGINS as any).nullish(),
|
||||
plugin_options: nullableString,
|
||||
});
|
||||
|
||||
const vmess = z.object({
|
||||
type: z.literal('vmess'),
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
transport: z.enum(TRANSPORTS.vmess as any).nullish(),
|
||||
security: z.enum(SECURITY.vmess as any).nullish(),
|
||||
path: nullableString,
|
||||
service_name: nullableString,
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const vless = z.object({
|
||||
type: z.literal('vless'),
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
transport: z.enum(TRANSPORTS.vless as any).nullish(),
|
||||
security: z.enum(SECURITY.vless as any).nullish(),
|
||||
path: nullableString,
|
||||
service_name: nullableString,
|
||||
flow: z.enum(FLOWS.vless as any).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
reality_server_addr: nullableString,
|
||||
reality_server_port: nullablePort,
|
||||
reality_private_key: nullableString,
|
||||
reality_public_key: nullableString,
|
||||
reality_short_id: nullableString,
|
||||
});
|
||||
|
||||
const trojan = z.object({
|
||||
type: z.literal('trojan'),
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
transport: z.enum(TRANSPORTS.trojan as any).nullish(),
|
||||
security: z.enum(SECURITY.trojan as any).nullish(),
|
||||
path: nullableString,
|
||||
service_name: nullableString,
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const hysteria2 = z.object({
|
||||
type: z.literal('hysteria2'),
|
||||
hop_ports: nullableString,
|
||||
hop_interval: z.number().nullish(),
|
||||
obfs_password: nullableString,
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.hysteria2 as any).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
up_mbps: z.number().nullish(),
|
||||
down_mbps: z.number().nullish(),
|
||||
});
|
||||
|
||||
const tuic = z.object({
|
||||
type: z.literal('tuic'),
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
disable_sni: z.boolean().nullish(),
|
||||
reduce_rtt: z.boolean().nullish(),
|
||||
udp_relay_mode: z.enum(TUIC_UDP_RELAY_MODES as any).nullish(),
|
||||
congestion_controller: z.enum(TUIC_CONGESTION as any).nullish(),
|
||||
security: z.enum(SECURITY.tuic as any).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const anytls = z.object({
|
||||
type: z.literal('anytls'),
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.anytls as any).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
padding_scheme: nullableString,
|
||||
});
|
||||
|
||||
const socks = z.object({
|
||||
type: z.literal('socks'),
|
||||
port: nullablePort,
|
||||
});
|
||||
|
||||
const naive = z.object({
|
||||
type: z.literal('naive'),
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.naive as any).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const http = z.object({
|
||||
type: z.literal('http'),
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.http as any).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const meru = z.object({
|
||||
type: z.literal('meru'),
|
||||
port: nullablePort,
|
||||
multiplex: z.enum(multiplexLevels).nullish(),
|
||||
transport: z.enum(TRANSPORTS.meru as any).nullish(),
|
||||
});
|
||||
|
||||
export const protocolApiScheme = z.discriminatedUnion('type', [
|
||||
ss,
|
||||
vmess,
|
||||
vless,
|
||||
trojan,
|
||||
hysteria2,
|
||||
tuic,
|
||||
anytls,
|
||||
socks,
|
||||
naive,
|
||||
http,
|
||||
meru,
|
||||
]);
|
||||
|
||||
export const formSchema = z.object({
|
||||
name: z.string().min(1),
|
||||
address: z.string().min(1),
|
||||
country: z.string().optional(),
|
||||
city: z.string().optional(),
|
||||
ratio: z.number().default(1),
|
||||
protocols: z.array(protocolApiScheme),
|
||||
});
|
||||
|
||||
export type ServerFormValues = z.infer<typeof formSchema>;
|
||||
|
||||
export type ProtocolType = (typeof protocols)[number];
|
||||
|
||||
export function getProtocolDefaultConfig(proto: ProtocolType) {
|
||||
switch (proto) {
|
||||
case 'shadowsocks':
|
||||
return {
|
||||
type: 'shadowsocks',
|
||||
port: null,
|
||||
cipher: 'chacha20-ietf-poly1305',
|
||||
server_key: null,
|
||||
plugin: 'none',
|
||||
plugin_opts: null,
|
||||
} as any;
|
||||
case 'vmess':
|
||||
return { type: 'vmess', port: null, transport: 'tcp', security: 'none' } as any;
|
||||
case 'vless':
|
||||
return { type: 'vless', port: null, transport: 'tcp', security: 'none', flow: 'none' } as any;
|
||||
case 'trojan':
|
||||
return { type: 'trojan', port: null, transport: 'tcp', security: 'tls' } as any;
|
||||
case 'hysteria2':
|
||||
return {
|
||||
type: 'hysteria2',
|
||||
port: null,
|
||||
hop_ports: null,
|
||||
hop_interval: null,
|
||||
obfs_password: null,
|
||||
security: 'tls',
|
||||
up_mbps: null,
|
||||
down_mbps: null,
|
||||
} as any;
|
||||
case 'tuic':
|
||||
return {
|
||||
type: 'tuic',
|
||||
port: null,
|
||||
disable_sni: false,
|
||||
reduce_rtt: false,
|
||||
udp_relay_mode: 'native',
|
||||
congestion_controller: 'bbr',
|
||||
security: 'tls',
|
||||
sni: null,
|
||||
allow_insecure: false,
|
||||
fingerprint: 'chrome',
|
||||
} as any;
|
||||
case 'socks':
|
||||
return {
|
||||
type: 'socks',
|
||||
port: null,
|
||||
} as any;
|
||||
case 'naive':
|
||||
return {
|
||||
type: 'naive',
|
||||
port: null,
|
||||
security: 'none',
|
||||
} as any;
|
||||
case 'http':
|
||||
return {
|
||||
type: 'http',
|
||||
port: null,
|
||||
security: 'none',
|
||||
} as any;
|
||||
case 'meru':
|
||||
return {
|
||||
type: 'meru',
|
||||
port: null,
|
||||
multiplex: 'off',
|
||||
transport: 'tcp',
|
||||
} as any;
|
||||
case 'anytls':
|
||||
return {
|
||||
type: 'anytls',
|
||||
port: null,
|
||||
security: 'tls',
|
||||
padding_scheme: null,
|
||||
sni: null,
|
||||
allow_insecure: false,
|
||||
fingerprint: 'chrome',
|
||||
} as any;
|
||||
default:
|
||||
return {} as any;
|
||||
}
|
||||
}
|
||||
import {
|
||||
generateMLKEM768KeyPair,
|
||||
generatePassword,
|
||||
generateRealityKeyPair,
|
||||
generateRealityShortId,
|
||||
} from '../generate';
|
||||
import {
|
||||
ENCRYPTION_MODES,
|
||||
ENCRYPTION_RTT,
|
||||
ENCRYPTION_TYPES,
|
||||
FINGERPRINTS,
|
||||
FLOWS,
|
||||
multiplexLevels,
|
||||
SECURITY,
|
||||
SS_CIPHERS,
|
||||
TRANSPORTS,
|
||||
TUIC_CONGESTION,
|
||||
TUIC_UDP_RELAY_MODES,
|
||||
XHTTP_MODES,
|
||||
} from './constants';
|
||||
import type { FieldConfig } from './types';
|
||||
|
||||
export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
shadowsocks: [
|
||||
@@ -367,7 +34,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
{
|
||||
name: 'cipher',
|
||||
type: 'select',
|
||||
label: 'encryption_method',
|
||||
label: 'cipher',
|
||||
options: SS_CIPHERS,
|
||||
defaultValue: 'chacha20-ietf-poly1305',
|
||||
group: 'basic',
|
||||
@@ -376,7 +43,9 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'server_key',
|
||||
type: 'input',
|
||||
label: 'server_key',
|
||||
password: 32,
|
||||
generate: {
|
||||
function: () => generatePassword(32),
|
||||
},
|
||||
group: 'basic',
|
||||
condition: (p) =>
|
||||
[
|
||||
@@ -386,29 +55,28 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
].includes(p.cipher),
|
||||
},
|
||||
{
|
||||
name: 'plugin',
|
||||
name: 'obfs',
|
||||
type: 'select',
|
||||
label: 'plugin',
|
||||
options: SS_PLUGINS,
|
||||
label: 'obfs',
|
||||
options: ['none', 'http', 'tls'],
|
||||
defaultValue: 'none',
|
||||
group: 'plugin',
|
||||
group: 'obfs',
|
||||
},
|
||||
{
|
||||
name: 'plugin_opts',
|
||||
type: 'textarea',
|
||||
label: 'plugin_opts',
|
||||
placeholder: (t: (key: string) => string, p: any) => {
|
||||
switch (p.plugin) {
|
||||
case 'simple-obfs':
|
||||
return 'obfs=http;obfs-host=www.bing.com;path=/';
|
||||
case 'v2ray-plugin':
|
||||
return 'WebSocket: mode=websocket;host=mydomain.me;path=/;tls=true\n\nQUIC: mode=quic;host=mydomain.me';
|
||||
default:
|
||||
return 'key=value;key2=value2';
|
||||
}
|
||||
},
|
||||
group: 'plugin',
|
||||
condition: (p) => ['simple-obfs', 'v2ray-plugin'].includes(p.plugin),
|
||||
name: 'obfs_host',
|
||||
type: 'input',
|
||||
label: 'obfs_host',
|
||||
placeholder: 'e.g. www.bing.com',
|
||||
group: 'obfs',
|
||||
condition: (p) => p.obfs && p.obfs !== 'none',
|
||||
},
|
||||
{
|
||||
name: 'obfs_path',
|
||||
type: 'input',
|
||||
label: 'obfs_path',
|
||||
placeholder: 'e.g. /path/to/obfs',
|
||||
group: 'obfs',
|
||||
condition: (p) => p.obfs && p.obfs !== 'none',
|
||||
},
|
||||
],
|
||||
vmess: [
|
||||
@@ -441,6 +109,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'host',
|
||||
type: 'input',
|
||||
label: 'host',
|
||||
placeholder: 'e.g. www.bing.com',
|
||||
group: 'transport',
|
||||
condition: (p) => ['websocket', 'xhttp', 'httpupgrade'].includes(p.transport),
|
||||
},
|
||||
@@ -448,6 +117,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'path',
|
||||
type: 'input',
|
||||
label: 'path',
|
||||
placeholder: 'e.g. /path/to/obfs',
|
||||
group: 'transport',
|
||||
condition: (p) => ['websocket', 'xhttp', 'httpupgrade'].includes(p.transport),
|
||||
},
|
||||
@@ -492,14 +162,6 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
placeholder: '1-65535',
|
||||
group: 'basic',
|
||||
},
|
||||
{
|
||||
name: 'flow',
|
||||
type: 'select',
|
||||
label: 'flow',
|
||||
options: FLOWS.vless,
|
||||
defaultValue: 'none',
|
||||
group: 'basic',
|
||||
},
|
||||
{
|
||||
name: 'transport',
|
||||
type: 'select',
|
||||
@@ -508,6 +170,15 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
defaultValue: 'tcp',
|
||||
group: 'transport',
|
||||
},
|
||||
{
|
||||
name: 'flow',
|
||||
type: 'select',
|
||||
label: 'flow',
|
||||
options: FLOWS.vless,
|
||||
defaultValue: 'none',
|
||||
group: 'transport',
|
||||
condition: (p) => p.transport === 'tcp',
|
||||
},
|
||||
{
|
||||
name: 'security',
|
||||
type: 'select',
|
||||
@@ -520,6 +191,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'host',
|
||||
type: 'input',
|
||||
label: 'host',
|
||||
placeholder: 'e.g. www.bing.com',
|
||||
group: 'transport',
|
||||
condition: (p) => ['websocket', 'mkcp', 'httpupgrade', 'xhttp'].includes(p.transport),
|
||||
},
|
||||
@@ -527,6 +199,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'path',
|
||||
type: 'input',
|
||||
label: 'path',
|
||||
placeholder: 'e.g. /path/to/obfs',
|
||||
group: 'transport',
|
||||
condition: (p) => ['websocket', 'mkcp', 'httpupgrade', 'xhttp'].includes(p.transport),
|
||||
},
|
||||
@@ -537,6 +210,23 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
group: 'transport',
|
||||
condition: (p) => p.transport === 'grpc',
|
||||
},
|
||||
{
|
||||
name: 'xhttp_mode',
|
||||
type: 'select',
|
||||
label: 'mode',
|
||||
options: XHTTP_MODES,
|
||||
defaultValue: 'auto',
|
||||
group: 'transport',
|
||||
condition: (p) => p.transport === 'xhttp',
|
||||
},
|
||||
{
|
||||
name: 'xhttp_extra',
|
||||
type: 'textarea',
|
||||
label: 'extra',
|
||||
placeholder: '{}',
|
||||
group: 'transport',
|
||||
condition: (p) => p.transport === 'xhttp',
|
||||
},
|
||||
{
|
||||
name: 'sni',
|
||||
type: 'input',
|
||||
@@ -584,6 +274,13 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
label: 'security_private_key',
|
||||
placeholder: (t) => t('security_private_key_placeholder'),
|
||||
group: 'reality',
|
||||
generate: {
|
||||
function: generateRealityKeyPair,
|
||||
updateFields: {
|
||||
reality_private_key: 'privateKey',
|
||||
reality_public_key: 'publicKey',
|
||||
},
|
||||
},
|
||||
condition: (p) => p.security === 'reality',
|
||||
},
|
||||
{
|
||||
@@ -599,8 +296,84 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
type: 'input',
|
||||
label: 'security_short_id',
|
||||
group: 'reality',
|
||||
generate: {
|
||||
function: generateRealityShortId,
|
||||
},
|
||||
condition: (p) => p.security === 'reality',
|
||||
},
|
||||
{
|
||||
name: 'encryption',
|
||||
type: 'select',
|
||||
label: 'encryption',
|
||||
options: ENCRYPTION_TYPES,
|
||||
defaultValue: 'none',
|
||||
group: 'encryption',
|
||||
},
|
||||
{
|
||||
name: 'encryption_mode',
|
||||
type: 'select',
|
||||
label: 'encryption_mode',
|
||||
options: ENCRYPTION_MODES,
|
||||
defaultValue: 'native',
|
||||
group: 'encryption',
|
||||
condition: (p) => p.encryption === 'mlkem768x25519plus',
|
||||
},
|
||||
{
|
||||
name: 'encryption_rtt',
|
||||
type: 'select',
|
||||
label: 'encryption_rtt',
|
||||
options: ENCRYPTION_RTT,
|
||||
defaultValue: '1rtt',
|
||||
group: 'encryption',
|
||||
condition: (p) => p.encryption === 'mlkem768x25519plus',
|
||||
},
|
||||
{
|
||||
name: 'encryption_ticket',
|
||||
type: 'input',
|
||||
label: 'encryption_ticket',
|
||||
placeholder: 'e.g. 600s',
|
||||
group: 'encryption',
|
||||
condition: (p) => p.encryption === 'mlkem768x25519plus' && p.encryption_rtt === '0rtt',
|
||||
},
|
||||
{
|
||||
name: 'encryption_server_padding',
|
||||
type: 'input',
|
||||
label: 'encryption_server_padding',
|
||||
placeholder: 'e.g. 100-111-1111.75-0-111.50-0-3333',
|
||||
group: 'encryption',
|
||||
condition: (p) => p.encryption === 'mlkem768x25519plus',
|
||||
},
|
||||
{
|
||||
name: 'encryption_private_key',
|
||||
type: 'input',
|
||||
label: 'encryption_private_key',
|
||||
placeholder: (t) => t('encryption_private_key_placeholder'),
|
||||
group: 'encryption',
|
||||
generate: {
|
||||
function: generateMLKEM768KeyPair,
|
||||
updateFields: {
|
||||
encryption_private_key: 'privateKey',
|
||||
encryption_password: 'publicKey',
|
||||
},
|
||||
},
|
||||
condition: (p) => p.encryption === 'mlkem768x25519plus',
|
||||
},
|
||||
{
|
||||
name: 'encryption_client_padding',
|
||||
type: 'input',
|
||||
label: 'encryption_client_padding',
|
||||
placeholder: 'e.g. 100-111-1111.75-0-111.50-0-3333',
|
||||
group: 'encryption',
|
||||
condition: (p) => p.encryption === 'mlkem768x25519plus',
|
||||
},
|
||||
{
|
||||
name: 'encryption_password',
|
||||
type: 'input',
|
||||
label: 'encryption_password',
|
||||
placeholder: (t) => t('encryption_password_placeholder'),
|
||||
group: 'encryption',
|
||||
condition: (p) => p.encryption === 'mlkem768x25519plus',
|
||||
},
|
||||
],
|
||||
trojan: [
|
||||
{
|
||||
@@ -632,6 +405,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'host',
|
||||
type: 'input',
|
||||
label: 'host',
|
||||
placeholder: 'e.g. www.bing.com',
|
||||
group: 'transport',
|
||||
condition: (p) => ['websocket', 'xhttp', 'httpupgrade'].includes(p.transport),
|
||||
},
|
||||
@@ -639,6 +413,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'path',
|
||||
type: 'input',
|
||||
label: 'path',
|
||||
placeholder: 'e.g. /path/to/obfs',
|
||||
group: 'transport',
|
||||
condition: (p) => ['websocket', 'xhttp', 'httpupgrade'].includes(p.transport),
|
||||
},
|
||||
@@ -699,13 +474,24 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
suffix: 'S',
|
||||
group: 'basic',
|
||||
},
|
||||
{
|
||||
name: 'obfs',
|
||||
type: 'select',
|
||||
label: 'obfs',
|
||||
options: ['none', 'salamander'],
|
||||
defaultValue: 'none',
|
||||
group: 'obfs',
|
||||
},
|
||||
{
|
||||
name: 'obfs_password',
|
||||
type: 'input',
|
||||
label: 'obfs_password',
|
||||
placeholder: (t) => t('obfs_password_placeholder'),
|
||||
password: 16,
|
||||
group: 'basic',
|
||||
generate: {
|
||||
function: () => generatePassword(16),
|
||||
},
|
||||
group: 'obfs',
|
||||
condition: (p) => p.obfs && p.obfs !== 'none',
|
||||
},
|
||||
{
|
||||
name: 'up_mbps',
|
||||
@@ -870,7 +656,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
condition: (p) => p.security !== 'none',
|
||||
},
|
||||
],
|
||||
meru: [
|
||||
mieru: [
|
||||
{
|
||||
name: 'port',
|
||||
type: 'number',
|
||||
@@ -892,7 +678,7 @@ export const PROTOCOL_FIELDS: Record<string, FieldConfig[]> = {
|
||||
name: 'transport',
|
||||
type: 'select',
|
||||
label: 'transport',
|
||||
options: TRANSPORTS.meru,
|
||||
options: TRANSPORTS.mieru,
|
||||
defaultValue: 'tcp',
|
||||
group: 'transport',
|
||||
},
|
||||
@@ -0,0 +1,30 @@
|
||||
// Re-export all constants
|
||||
export {
|
||||
ENCRYPTION_MODES,
|
||||
ENCRYPTION_RTT,
|
||||
ENCRYPTION_TYPES,
|
||||
FINGERPRINTS,
|
||||
FLOWS,
|
||||
LABELS,
|
||||
SECURITY,
|
||||
SS_CIPHERS,
|
||||
TRANSPORTS,
|
||||
TUIC_CONGESTION,
|
||||
TUIC_UDP_RELAY_MODES,
|
||||
XHTTP_MODES,
|
||||
getLabel,
|
||||
multiplexLevels,
|
||||
protocols,
|
||||
} from './constants';
|
||||
|
||||
// Re-export all types
|
||||
export type { FieldConfig, ProtocolType } from './types';
|
||||
|
||||
// Re-export all schemas
|
||||
export { formSchema, protocolApiScheme } from './schemas';
|
||||
|
||||
// Re-export defaults
|
||||
export { getProtocolDefaultConfig } from './defaults';
|
||||
|
||||
// Re-export fields
|
||||
export { PROTOCOL_FIELDS } from './fields';
|
||||
@@ -0,0 +1,187 @@
|
||||
import { z } from 'zod';
|
||||
import {
|
||||
ENCRYPTION_MODES,
|
||||
ENCRYPTION_RTT,
|
||||
ENCRYPTION_TYPES,
|
||||
FLOWS,
|
||||
multiplexLevels,
|
||||
SECURITY,
|
||||
SS_CIPHERS,
|
||||
TRANSPORTS,
|
||||
TUIC_CONGESTION,
|
||||
TUIC_UDP_RELAY_MODES,
|
||||
XHTTP_MODES,
|
||||
} from './constants';
|
||||
|
||||
const nullableString = z.string().nullish();
|
||||
const nullableBool = z.boolean().nullish();
|
||||
const nullablePort = z.number().int().min(0).max(65535).nullish();
|
||||
|
||||
const ss = z.object({
|
||||
type: z.literal('shadowsocks'),
|
||||
enable: nullableBool,
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
cipher: z.enum(SS_CIPHERS).nullish(),
|
||||
server_key: nullableString,
|
||||
obfs: z.enum(['none', 'http', 'tls'] as const).nullish(),
|
||||
obfs_host: nullableString,
|
||||
obfs_path: nullableString,
|
||||
});
|
||||
|
||||
const vmess = z.object({
|
||||
type: z.literal('vmess'),
|
||||
enable: nullableBool,
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
transport: z.enum(TRANSPORTS.vmess).nullish(),
|
||||
security: z.enum(SECURITY.vmess).nullish(),
|
||||
path: nullableString,
|
||||
service_name: nullableString,
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const vless = z.object({
|
||||
type: z.literal('vless'),
|
||||
enable: nullableBool,
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
transport: z.enum(TRANSPORTS.vless).nullish(),
|
||||
security: z.enum(SECURITY.vless).nullish(),
|
||||
path: nullableString,
|
||||
service_name: nullableString,
|
||||
flow: z.enum(FLOWS.vless).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
reality_server_addr: nullableString,
|
||||
reality_server_port: nullablePort,
|
||||
reality_private_key: nullableString,
|
||||
reality_public_key: nullableString,
|
||||
reality_short_id: nullableString,
|
||||
xhttp_mode: z.enum(XHTTP_MODES).nullish(),
|
||||
xhttp_extra: nullableString,
|
||||
encryption: z.enum(ENCRYPTION_TYPES).nullish(),
|
||||
encryption_mode: z.enum(ENCRYPTION_MODES).nullish(),
|
||||
encryption_rtt: z.enum(ENCRYPTION_RTT).nullish(),
|
||||
encryption_ticket: nullableString,
|
||||
encryption_server_padding: nullableString,
|
||||
encryption_private_key: nullableString,
|
||||
encryption_client_padding: nullableString,
|
||||
encryption_password: nullableString,
|
||||
});
|
||||
|
||||
const trojan = z.object({
|
||||
type: z.literal('trojan'),
|
||||
enable: nullableBool,
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
transport: z.enum(TRANSPORTS.trojan).nullish(),
|
||||
security: z.enum(SECURITY.trojan).nullish(),
|
||||
path: nullableString,
|
||||
service_name: nullableString,
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const hysteria2 = z.object({
|
||||
type: z.literal('hysteria2'),
|
||||
enable: nullableBool,
|
||||
hop_ports: nullableString,
|
||||
hop_interval: z.number().nullish(),
|
||||
obfs_password: nullableString,
|
||||
obfs: z.enum(['none', 'salamander'] as const).nullish(),
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.hysteria2).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
up_mbps: z.number().nullish(),
|
||||
down_mbps: z.number().nullish(),
|
||||
});
|
||||
|
||||
const tuic = z.object({
|
||||
type: z.literal('tuic'),
|
||||
enable: nullableBool,
|
||||
host: nullableString,
|
||||
port: nullablePort,
|
||||
disable_sni: z.boolean().nullish(),
|
||||
reduce_rtt: z.boolean().nullish(),
|
||||
udp_relay_mode: z.enum(TUIC_UDP_RELAY_MODES).nullish(),
|
||||
congestion_controller: z.enum(TUIC_CONGESTION).nullish(),
|
||||
security: z.enum(SECURITY.tuic).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const anytls = z.object({
|
||||
type: z.literal('anytls'),
|
||||
enable: nullableBool,
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.anytls).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
padding_scheme: nullableString,
|
||||
});
|
||||
|
||||
const socks = z.object({
|
||||
type: z.literal('socks'),
|
||||
enable: nullableBool,
|
||||
port: nullablePort,
|
||||
});
|
||||
|
||||
const naive = z.object({
|
||||
type: z.literal('naive'),
|
||||
enable: nullableBool,
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.naive).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const http = z.object({
|
||||
type: z.literal('http'),
|
||||
enable: nullableBool,
|
||||
port: nullablePort,
|
||||
security: z.enum(SECURITY.http).nullish(),
|
||||
sni: nullableString,
|
||||
allow_insecure: nullableBool,
|
||||
fingerprint: nullableString,
|
||||
});
|
||||
|
||||
const mieru = z.object({
|
||||
type: z.literal('mieru'),
|
||||
enable: nullableBool,
|
||||
port: nullablePort,
|
||||
multiplex: z.enum(multiplexLevels).nullish(),
|
||||
transport: z.enum(TRANSPORTS.mieru).nullish(),
|
||||
});
|
||||
|
||||
export const protocolApiScheme = z.discriminatedUnion('type', [
|
||||
ss,
|
||||
vmess,
|
||||
vless,
|
||||
trojan,
|
||||
hysteria2,
|
||||
tuic,
|
||||
anytls,
|
||||
socks,
|
||||
naive,
|
||||
http,
|
||||
mieru,
|
||||
]);
|
||||
|
||||
export const formSchema = z.object({
|
||||
name: z.string().min(1),
|
||||
address: z.string().min(1),
|
||||
country: z.string().optional(),
|
||||
city: z.string().optional(),
|
||||
ratio: z.number().default(1),
|
||||
protocols: z.array(protocolApiScheme),
|
||||
});
|
||||
@@ -0,0 +1,23 @@
|
||||
import { protocols } from './constants';
|
||||
|
||||
export type FieldConfig = {
|
||||
name: string;
|
||||
type: 'input' | 'select' | 'switch' | 'number' | 'textarea';
|
||||
label: string;
|
||||
placeholder?: string | ((t: (key: string) => string, protocol: any) => string);
|
||||
options?: readonly string[];
|
||||
defaultValue?: any;
|
||||
min?: number;
|
||||
max?: number;
|
||||
step?: number;
|
||||
suffix?: string;
|
||||
generate?: {
|
||||
function: () => Promise<string | Record<string, string>> | string | Record<string, string>;
|
||||
updateFields?: Record<string, string>;
|
||||
};
|
||||
condition?: (protocol: any, values: any) => boolean;
|
||||
group?: 'basic' | 'transport' | 'security' | 'reality' | 'obfs' | 'encryption';
|
||||
gridSpan?: 1 | 2;
|
||||
};
|
||||
|
||||
export type ProtocolType = (typeof protocols)[number];
|
||||
@@ -0,0 +1,4 @@
|
||||
export { generateMLKEM768KeyPair } from './mlkem768';
|
||||
export { generateRealityShortId } from './short-id';
|
||||
export { generatePassword } from './uid';
|
||||
export { generateRealityKeyPair } from './x25519';
|
||||
@@ -0,0 +1,16 @@
|
||||
import mlkem from 'mlkem-wasm';
|
||||
import { toB64Url } from './util';
|
||||
|
||||
export async function generateMLKEM768KeyPair() {
|
||||
const mlkemKeyPair = await mlkem.generateKey({ name: 'ML-KEM-768' }, true, [
|
||||
'encapsulateBits',
|
||||
'decapsulateBits',
|
||||
]);
|
||||
const mlkemPublicKeyRaw = await mlkem.exportKey('raw-public', mlkemKeyPair.publicKey);
|
||||
const mlkemPrivateKeyRaw = await mlkem.exportKey('raw-seed', mlkemKeyPair.privateKey);
|
||||
|
||||
return {
|
||||
publicKey: toB64Url(new Uint8Array(mlkemPublicKeyRaw)),
|
||||
privateKey: toB64Url(new Uint8Array(mlkemPrivateKeyRaw)),
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
/**
|
||||
* Generate a short ID for Reality
|
||||
* @returns A random hexadecimal string of length 2, 4, 6, 8, 10, 12, 14, or 16
|
||||
*/
|
||||
export function generateRealityShortId() {
|
||||
const hex = '0123456789abcdef';
|
||||
const lengths = [2, 4, 6, 8, 10, 12, 14, 16];
|
||||
const idx = Math.floor(Math.random() * lengths.length);
|
||||
const len = lengths[idx] ?? 16;
|
||||
let out = '';
|
||||
for (let i = 0; i < len; i++) {
|
||||
out += hex.charAt(Math.floor(Math.random() * hex.length));
|
||||
}
|
||||
return out;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
import { uid } from 'radash';
|
||||
|
||||
/**
|
||||
* Generate a random password
|
||||
* @param length Length of the password
|
||||
* @param charset Character set to use (defaults to alphanumeric)
|
||||
* @returns Randomly generated password
|
||||
*/
|
||||
export function generatePassword(length = 16, charset?: string) {
|
||||
return uid(length, charset).toLowerCase();
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
export function toB64Url(bytes: Uint8Array) {
|
||||
return btoa(String.fromCharCode(...bytes))
|
||||
.replace(/\+/g, '-')
|
||||
.replace(/\//g, '_')
|
||||
.replace(/=+$/g, '');
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
import { x25519 } from '@noble/curves/ed25519';
|
||||
import { toB64Url } from './util';
|
||||
|
||||
/**
|
||||
* Generate a Reality key pair
|
||||
* @returns An object containing the private and public keys in base64url format
|
||||
*/
|
||||
export function generateRealityKeyPair() {
|
||||
const { secretKey, publicKey } = x25519.keygen();
|
||||
return { privateKey: toB64Url(secretKey), publicKey: toB64Url(publicKey) };
|
||||
}
|
||||
@@ -15,6 +15,7 @@ import {
|
||||
SheetTrigger,
|
||||
} from '@workspace/ui/components/sheet';
|
||||
import { formatBytes } from '@workspace/ui/utils';
|
||||
import { Users } from 'lucide-react';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useState } from 'react';
|
||||
|
||||
@@ -92,8 +93,7 @@ export default function OnlineUsersCell({ status }: { status?: API.ServerStatus
|
||||
<Sheet open={open} onOpenChange={setOpen}>
|
||||
<SheetTrigger asChild>
|
||||
<button className='hover:text-foreground text-muted-foreground flex items-center gap-2 bg-transparent p-0 text-sm'>
|
||||
<Badge variant='secondary'>{status?.online.length}</Badge>
|
||||
<span>{t('onlineUsers')}</span>
|
||||
<Users className='h-4 w-4' /> {status?.online.length}
|
||||
</button>
|
||||
</SheetTrigger>
|
||||
<SheetContent className='h-screen w-screen max-w-none sm:h-auto sm:w-[900px] sm:max-w-[90vw]'>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
'use client';
|
||||
// Online users detail moved to separate component
|
||||
|
||||
import { ProTable, ProTableActions } from '@/components/pro-table';
|
||||
import {
|
||||
createServer,
|
||||
@@ -10,6 +10,8 @@ import {
|
||||
resetSortWithServer,
|
||||
updateServer,
|
||||
} from '@/services/admin/server';
|
||||
import { useNode } from '@/store/node';
|
||||
import { useServer } from '@/store/server';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
@@ -23,18 +25,6 @@ import OnlineUsersCell from './online-users-cell';
|
||||
import ServerConfig from './server-config';
|
||||
import ServerForm from './server-form';
|
||||
|
||||
type ProtocolName = 'shadowsocks' | 'vmess' | 'vless' | 'trojan' | 'hysteria2' | 'tuic' | 'anytls';
|
||||
|
||||
const PROTOCOL_COLORS: Record<ProtocolName, string> = {
|
||||
shadowsocks: 'bg-green-500',
|
||||
vmess: 'bg-rose-500',
|
||||
vless: 'bg-blue-500',
|
||||
trojan: 'bg-yellow-500',
|
||||
hysteria2: 'bg-purple-500',
|
||||
tuic: 'bg-cyan-500',
|
||||
anytls: 'bg-gray-500',
|
||||
};
|
||||
|
||||
function PctBar({ value }: { value: number }) {
|
||||
const v = value.toFixed(2);
|
||||
return (
|
||||
@@ -69,6 +59,8 @@ function RegionIpCell({
|
||||
|
||||
export default function ServersPage() {
|
||||
const t = useTranslations('servers');
|
||||
const { isServerReferencedByNodes } = useNode();
|
||||
const { fetchServers } = useServer();
|
||||
|
||||
const [loading, setLoading] = useState(false);
|
||||
const [migrating, setMigrating] = useState(false);
|
||||
@@ -129,6 +121,7 @@ export default function ServersPage() {
|
||||
await createServer(values as unknown as API.CreateServerRequest);
|
||||
toast.success(t('created'));
|
||||
ref.current?.refresh();
|
||||
fetchServers();
|
||||
setLoading(false);
|
||||
return true;
|
||||
} catch (e) {
|
||||
@@ -163,23 +156,16 @@ export default function ServersPage() {
|
||||
accessorKey: 'protocols',
|
||||
header: t('protocols'),
|
||||
cell: ({ row }) => {
|
||||
const list = (row.original.protocols || []) as API.Protocol[];
|
||||
if (!list.length) return t('noData');
|
||||
const list = row.original.protocols.filter(
|
||||
(p) => p.enable !== false,
|
||||
) as API.Protocol[];
|
||||
if (!list.length) return '—';
|
||||
return (
|
||||
<div className='flex flex-wrap gap-1'>
|
||||
{list.map((p, idx) => {
|
||||
const proto = ((p as any)?.type || '') as ProtocolName | '';
|
||||
if (!proto) return null;
|
||||
const color = PROTOCOL_COLORS[proto as ProtocolName];
|
||||
const port = (p as any)?.port as number | undefined;
|
||||
const label = `${proto}${port ? ` (${port})` : ''}`;
|
||||
return (
|
||||
<Badge
|
||||
key={idx}
|
||||
variant='outline'
|
||||
className={cn('text-primary-foreground', color)}
|
||||
>
|
||||
{label}
|
||||
<Badge key={idx} variant='outline'>
|
||||
{p.type} ({p.port})
|
||||
</Badge>
|
||||
);
|
||||
})}
|
||||
@@ -272,6 +258,7 @@ export default function ServersPage() {
|
||||
});
|
||||
toast.success(t('updated'));
|
||||
ref.current?.refresh();
|
||||
fetchServers();
|
||||
setLoading(false);
|
||||
return true;
|
||||
} catch (e) {
|
||||
@@ -282,13 +269,18 @@ export default function ServersPage() {
|
||||
/>,
|
||||
<ConfirmButton
|
||||
key='delete'
|
||||
trigger={<Button variant='destructive'>{t('delete')}</Button>}
|
||||
trigger={
|
||||
<Button variant='destructive' disabled={isServerReferencedByNodes(row.id)}>
|
||||
{t('delete')}
|
||||
</Button>
|
||||
}
|
||||
title={t('confirmDeleteTitle')}
|
||||
description={t('confirmDeleteDesc')}
|
||||
onConfirm={async () => {
|
||||
await deleteServer({ id: row.id } as any);
|
||||
toast.success(t('deleted'));
|
||||
ref.current?.refresh();
|
||||
fetchServers();
|
||||
}}
|
||||
cancelText={t('cancel')}
|
||||
confirmText={t('confirm')}
|
||||
@@ -311,6 +303,7 @@ export default function ServersPage() {
|
||||
await createServer(body);
|
||||
toast.success(t('copied'));
|
||||
ref.current?.refresh();
|
||||
fetchServers();
|
||||
setLoading(false);
|
||||
}}
|
||||
>
|
||||
@@ -318,16 +311,22 @@ export default function ServersPage() {
|
||||
</Button>,
|
||||
],
|
||||
batchRender(rows) {
|
||||
const hasReferencedServers = rows.some((row) => isServerReferencedByNodes(row.id));
|
||||
return [
|
||||
<ConfirmButton
|
||||
key='delete'
|
||||
trigger={<Button variant='destructive'>{t('delete')}</Button>}
|
||||
trigger={
|
||||
<Button variant='destructive' disabled={hasReferencedServers}>
|
||||
{t('delete')}
|
||||
</Button>
|
||||
}
|
||||
title={t('confirmDeleteTitle')}
|
||||
description={t('confirmDeleteDesc')}
|
||||
onConfirm={async () => {
|
||||
await Promise.all(rows.map((r) => deleteServer({ id: r.id })));
|
||||
toast.success(t('deleted'));
|
||||
ref.current?.refresh();
|
||||
fetchServers();
|
||||
}}
|
||||
cancelText={t('cancel')}
|
||||
confirmText={t('confirm')}
|
||||
@@ -361,6 +360,7 @@ export default function ServersPage() {
|
||||
sort: item.sort,
|
||||
})) as API.SortItem[],
|
||||
});
|
||||
toast.success(t('sorted_success'));
|
||||
}
|
||||
return updatedItems;
|
||||
}}
|
||||
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { ChartContainer, ChartTooltip } from '@workspace/ui/components/chart';
|
||||
|
||||
import {
|
||||
Form,
|
||||
FormControl,
|
||||
@@ -35,65 +35,11 @@ import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
import { DicesIcon } from 'lucide-react';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { uid } from 'radash';
|
||||
import { useEffect, useMemo, useState } from 'react';
|
||||
import { useEffect, useState } from 'react';
|
||||
import { useForm } from 'react-hook-form';
|
||||
import { Cell, Legend, Pie, PieChart } from 'recharts';
|
||||
import { toast } from 'sonner';
|
||||
import { z } from 'zod';
|
||||
|
||||
const COLORS = [
|
||||
'hsl(var(--chart-1))',
|
||||
'hsl(var(--chart-2))',
|
||||
'hsl(var(--chart-3))',
|
||||
'hsl(var(--chart-4))',
|
||||
'hsl(var(--chart-5))',
|
||||
];
|
||||
|
||||
const MINUTES_IN_DAY = 1440;
|
||||
|
||||
function getTimeRangeData(slots: API.TimePeriod[]) {
|
||||
const timePoints = slots
|
||||
.filter((slot) => slot.start_time && slot.end_time)
|
||||
.flatMap((slot) => {
|
||||
const [startH = 0, startM = 0] = slot.start_time.split(':').map(Number);
|
||||
const [endH = 0, endM = 0] = slot.end_time.split(':').map(Number);
|
||||
const start = startH * 60 + startM;
|
||||
let end = endH * 60 + endM;
|
||||
if (end < start) end += MINUTES_IN_DAY;
|
||||
return { start, end, multiplier: slot.multiplier };
|
||||
})
|
||||
.sort((a, b) => a.start - b.start);
|
||||
|
||||
const result: { name: string; value: number; multiplier: number }[] = [];
|
||||
let currentMinute = 0;
|
||||
|
||||
timePoints.forEach((point) => {
|
||||
if (point.start > currentMinute) {
|
||||
result.push({
|
||||
name: `${Math.floor(currentMinute / 60)}:${String(currentMinute % 60).padStart(2, '0')} - ${Math.floor(point.start / 60)}:${String(point.start % 60).padStart(2, '0')}`,
|
||||
value: point.start - currentMinute,
|
||||
multiplier: 1,
|
||||
});
|
||||
}
|
||||
result.push({
|
||||
name: `${Math.floor(point.start / 60)}:${String(point.start % 60).padStart(2, '0')} - ${Math.floor((point.end / 60) % 24)}:${String(point.end % 60).padStart(2, '0')}`,
|
||||
value: point.end - point.start,
|
||||
multiplier: point.multiplier,
|
||||
});
|
||||
currentMinute = point.end % MINUTES_IN_DAY;
|
||||
});
|
||||
|
||||
if (currentMinute < MINUTES_IN_DAY) {
|
||||
result.push({
|
||||
name: `${Math.floor(currentMinute / 60)}:${String(currentMinute % 60).padStart(2, '0')} - 24:00`,
|
||||
value: MINUTES_IN_DAY - currentMinute,
|
||||
multiplier: 1,
|
||||
});
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
const nodeConfigSchema = z.object({
|
||||
node_secret: z.string().optional(),
|
||||
node_pull_interval: z.number().optional(),
|
||||
@@ -150,20 +96,6 @@ export default function ServerConfig() {
|
||||
}
|
||||
}, [periodsResp]);
|
||||
|
||||
const chartTimeSlots = useMemo(() => getTimeRangeData(timeSlots), [timeSlots]);
|
||||
const chartConfig = useMemo(() => {
|
||||
return chartTimeSlots.reduce(
|
||||
(acc, item, index) => {
|
||||
acc[item.name] = {
|
||||
label: item.name,
|
||||
color: COLORS[index % COLORS.length] || 'hsl(var(--default-chart-color))',
|
||||
};
|
||||
return acc;
|
||||
},
|
||||
{} as Record<string, { label: string; color: string }>,
|
||||
);
|
||||
}, [chartTimeSlots]);
|
||||
|
||||
async function onSubmit(values: NodeConfigFormData) {
|
||||
setSaving(true);
|
||||
try {
|
||||
@@ -293,8 +225,8 @@ export default function ServerConfig() {
|
||||
{t('config.dynamicMultiplierDescription')}
|
||||
</p>
|
||||
|
||||
<div className='flex flex-col-reverse gap-8 md:flex-row md:items-start'>
|
||||
<div className='w-full md:w-1/2'>
|
||||
<div className='flex flex-col gap-2'>
|
||||
<div className='w-full'>
|
||||
<ArrayInput<API.TimePeriod>
|
||||
fields={[
|
||||
{ name: 'start_time', prefix: t('config.startTime'), type: 'time' },
|
||||
@@ -311,74 +243,18 @@ export default function ServerConfig() {
|
||||
/>
|
||||
<div className='mt-3 flex gap-2'>
|
||||
<Button
|
||||
type='button'
|
||||
size='sm'
|
||||
variant='outline'
|
||||
onClick={() => setTimeSlots(periodsResp || [])}
|
||||
>
|
||||
{t('config.reset')}
|
||||
</Button>
|
||||
<Button size='sm' onClick={savePeriods}>
|
||||
<Button size='sm' type='button' onClick={savePeriods}>
|
||||
{t('config.save')}
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className='w-full md:w-1/2'>
|
||||
<ChartContainer
|
||||
config={chartConfig}
|
||||
className='mx-auto aspect-[4/3] max-w-[400px]'
|
||||
>
|
||||
<PieChart>
|
||||
<Pie
|
||||
data={chartTimeSlots}
|
||||
cx='50%'
|
||||
cy='50%'
|
||||
labelLine={false}
|
||||
outerRadius='80%'
|
||||
fill='#8884d8'
|
||||
dataKey='value'
|
||||
label={({ percent, multiplier }) =>
|
||||
`${(multiplier || 0)?.toFixed(2)}x (${(percent * 100).toFixed(0)}%)`
|
||||
}
|
||||
>
|
||||
{chartTimeSlots.map((entry, index) => (
|
||||
<Cell key={`cell-${index}`} fill={COLORS[index % COLORS.length]} />
|
||||
))}
|
||||
</Pie>
|
||||
<ChartTooltip
|
||||
content={({ payload }) => {
|
||||
if (payload && payload.length) {
|
||||
const d = payload[0]?.payload as any;
|
||||
return (
|
||||
<div className='bg-background rounded-lg border p-2 shadow-sm'>
|
||||
<div className='grid grid-cols-2 gap-2'>
|
||||
<div className='flex flex-col'>
|
||||
<span className='text-muted-foreground text-[0.70rem] uppercase'>
|
||||
{t('config.timeSlot')}
|
||||
</span>
|
||||
<span className='text-muted-foreground font-bold'>
|
||||
{d.name || '—'}
|
||||
</span>
|
||||
</div>
|
||||
<div className='flex flex-col'>
|
||||
<span className='text-muted-foreground text-[0.70rem] uppercase'>
|
||||
{t('config.multiplier')}
|
||||
</span>
|
||||
<span className='font-bold'>
|
||||
{Number(d.multiplier).toFixed(2)}x
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}}
|
||||
/>
|
||||
<Legend />
|
||||
</PieChart>
|
||||
</ChartContainer>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
'use client';
|
||||
|
||||
import { useNode } from '@/store/node';
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import {
|
||||
Accordion,
|
||||
@@ -38,7 +39,6 @@ import { EnhancedInput } from '@workspace/ui/custom-components/enhanced-input';
|
||||
import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
import { cn } from '@workspace/ui/lib/utils';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { uid } from 'radash';
|
||||
import { useEffect, useState } from 'react';
|
||||
import { useForm, useWatch } from 'react-hook-form';
|
||||
import { toast } from 'sonner';
|
||||
@@ -49,18 +49,19 @@ import {
|
||||
getProtocolDefaultConfig,
|
||||
PROTOCOL_FIELDS,
|
||||
protocols as PROTOCOLS,
|
||||
ServerFormValues,
|
||||
} from './form-schema';
|
||||
|
||||
function DynamicField({
|
||||
field,
|
||||
control,
|
||||
form,
|
||||
protocolIndex,
|
||||
protocolData,
|
||||
t,
|
||||
}: {
|
||||
field: FieldConfig;
|
||||
control: any;
|
||||
form: any;
|
||||
protocolIndex: number;
|
||||
protocolData: any;
|
||||
t: (key: string) => string;
|
||||
@@ -97,17 +98,29 @@ function DynamicField({
|
||||
}
|
||||
onValueChange={(v) => fieldProps.onChange(v)}
|
||||
suffix={
|
||||
field.password ? (
|
||||
field.generate ? (
|
||||
<Button
|
||||
type='button'
|
||||
variant='ghost'
|
||||
onClick={() => {
|
||||
const length = field.password || 16;
|
||||
const result = uid(length).toLowerCase();
|
||||
fieldProps.onChange(result);
|
||||
onClick={async () => {
|
||||
const result = await field.generate!.function();
|
||||
if (typeof result === 'string') {
|
||||
fieldProps.onChange(result);
|
||||
} else if (field.generate!.updateFields) {
|
||||
Object.entries(field.generate!.updateFields).forEach(
|
||||
([fieldName, resultKey]) => {
|
||||
const fullFieldName = `protocols.${protocolIndex}.${fieldName}`;
|
||||
form.setValue(fullFieldName, (result as any)[resultKey]);
|
||||
},
|
||||
);
|
||||
} else {
|
||||
if (result.privateKey) {
|
||||
fieldProps.onChange(result.privateKey);
|
||||
}
|
||||
}
|
||||
}}
|
||||
>
|
||||
<Icon icon='mdi:refresh' className='h-4 w-4' />
|
||||
<Icon icon='mdi:key' className='h-4 w-4' />
|
||||
</Button>
|
||||
) : (
|
||||
field.suffix
|
||||
@@ -225,7 +238,7 @@ function DynamicField({
|
||||
field.placeholder
|
||||
? typeof field.placeholder === 'function'
|
||||
? field.placeholder(t, protocolData)
|
||||
: t(field.placeholder)
|
||||
: field.placeholder
|
||||
: undefined
|
||||
}
|
||||
onChange={(e) => fieldProps.onChange(e.target.value)}
|
||||
@@ -246,6 +259,7 @@ function renderFieldsByGroup(
|
||||
fields: FieldConfig[],
|
||||
group: string,
|
||||
control: any,
|
||||
form: any,
|
||||
protocolIndex: number,
|
||||
protocolData: any,
|
||||
t: (key: string) => string,
|
||||
@@ -260,6 +274,7 @@ function renderFieldsByGroup(
|
||||
key={field.name}
|
||||
field={field}
|
||||
control={control}
|
||||
form={form}
|
||||
protocolIndex={protocolIndex}
|
||||
protocolData={protocolData}
|
||||
t={t}
|
||||
@@ -274,6 +289,7 @@ function renderGroupCard(
|
||||
fields: FieldConfig[],
|
||||
group: string,
|
||||
control: any,
|
||||
form: any,
|
||||
protocolIndex: number,
|
||||
protocolData: any,
|
||||
t: (key: string) => string,
|
||||
@@ -294,7 +310,7 @@ function renderGroupCard(
|
||||
{t(title)}
|
||||
</legend>
|
||||
<div className='p-4 pt-2'>
|
||||
{renderFieldsByGroup(fields, group, control, protocolIndex, protocolData, t)}
|
||||
{renderFieldsByGroup(fields, group, control, form, protocolIndex, protocolData, t)}
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
@@ -305,14 +321,16 @@ export default function ServerForm(props: {
|
||||
trigger: string;
|
||||
title: string;
|
||||
loading?: boolean;
|
||||
initialValues?: Partial<ServerFormValues>;
|
||||
onSubmit: (values: ServerFormValues) => Promise<boolean> | boolean;
|
||||
initialValues?: Partial<API.Server>;
|
||||
onSubmit: (values: Partial<API.Server>) => Promise<boolean> | boolean;
|
||||
}) {
|
||||
const { trigger, title, loading, initialValues, onSubmit } = props;
|
||||
const t = useTranslations('servers');
|
||||
const [open, setOpen] = useState(false);
|
||||
const [accordionValue, setAccordionValue] = useState<string>();
|
||||
|
||||
const { isProtocolUsedInNodes } = useNode();
|
||||
|
||||
const form = useForm({
|
||||
resolver: zodResolver(formSchema),
|
||||
defaultValues: {
|
||||
@@ -321,7 +339,7 @@ export default function ServerForm(props: {
|
||||
country: '',
|
||||
city: '',
|
||||
ratio: 1,
|
||||
protocols: [],
|
||||
protocols: [] as any[],
|
||||
...initialValues,
|
||||
},
|
||||
});
|
||||
@@ -348,24 +366,18 @@ export default function ServerForm(props: {
|
||||
}, [initialValues]);
|
||||
|
||||
async function handleSubmit(values: Record<string, any>) {
|
||||
const filtered = (values?.protocols || []).filter((p: any, index: number) => {
|
||||
const port = Number(p?.port);
|
||||
const protocolType = PROTOCOLS[index];
|
||||
return protocolType && p && Number.isFinite(port) && port > 0 && port <= 65535;
|
||||
const filteredProtocols = (values?.protocols || []).filter((protocol: any) => {
|
||||
const port = Number(protocol?.port);
|
||||
return protocol && Number.isFinite(port) && port > 0 && port <= 65535;
|
||||
});
|
||||
|
||||
if (filtered.length === 0) {
|
||||
toast.error(t('validation_failed'));
|
||||
return;
|
||||
}
|
||||
|
||||
const result = {
|
||||
name: values.name,
|
||||
country: values.country,
|
||||
city: values.city,
|
||||
ratio: Number(values.ratio || 1),
|
||||
ratio: values.ratio || 1,
|
||||
address: values.address,
|
||||
protocols: filtered,
|
||||
protocols: filteredProtocols,
|
||||
};
|
||||
|
||||
const ok = await onSubmit(result);
|
||||
@@ -491,6 +503,7 @@ export default function ServerForm(props: {
|
||||
{t('protocol_configurations_desc')}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<Accordion
|
||||
type='single'
|
||||
collapsible
|
||||
@@ -504,56 +517,96 @@ export default function ServerForm(props: {
|
||||
PROTOCOLS.findIndex((t) => t === type),
|
||||
);
|
||||
const current = (protocolsValues[i] || {}) as Record<string, any>;
|
||||
const isEnabled = current.port && Number(current.port) > 0;
|
||||
const isEnabled = current?.enable !== false;
|
||||
const fields = PROTOCOL_FIELDS[type] || [];
|
||||
return (
|
||||
<AccordionItem key={type} value={type} className='mb-2 rounded-lg border'>
|
||||
<AccordionTrigger className='px-4 py-3 hover:no-underline'>
|
||||
<div className='flex w-full items-center justify-between'>
|
||||
<div className='flex flex-col items-start'>
|
||||
<div className='flex items-center gap-2'>
|
||||
<div className='flex flex-col items-start gap-1'>
|
||||
<div className='flex items-center gap-1'>
|
||||
<span className='font-medium capitalize'>{type}</span>
|
||||
</div>
|
||||
<span
|
||||
className={cn(
|
||||
'text-muted-foreground text-xs',
|
||||
isEnabled && 'text-green-500',
|
||||
{current.transport && (
|
||||
<Badge variant='secondary' className='text-xs'>
|
||||
{current.transport.toUpperCase()}
|
||||
</Badge>
|
||||
)}
|
||||
>
|
||||
{isEnabled ? t('enabled') : t('disabled')}
|
||||
</span>
|
||||
{current.security && current.security !== 'none' && (
|
||||
<Badge variant='outline' className='text-xs'>
|
||||
{current.security.toUpperCase()}
|
||||
</Badge>
|
||||
)}
|
||||
{current.port && <Badge className='text-xs'>{current.port}</Badge>}
|
||||
</div>
|
||||
<div className='flex items-center gap-1'>
|
||||
<span
|
||||
className={cn(
|
||||
'text-xs',
|
||||
isEnabled ? 'text-green-500' : 'text-muted-foreground',
|
||||
)}
|
||||
>
|
||||
{isEnabled ? t('enabled') : t('disabled')}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<div className='mr-2 flex items-center gap-1'>
|
||||
{current.transport && (
|
||||
<Badge variant='secondary' className='text-xs'>
|
||||
{current.transport.toUpperCase()}
|
||||
</Badge>
|
||||
<Switch
|
||||
className='mr-2'
|
||||
checked={!!isEnabled}
|
||||
disabled={Boolean(
|
||||
initialValues?.id &&
|
||||
isProtocolUsedInNodes(initialValues?.id || 0, type),
|
||||
)}
|
||||
{current.security && current.security !== 'none' && (
|
||||
<Badge variant='outline' className='text-xs'>
|
||||
{current.security.toUpperCase()}
|
||||
</Badge>
|
||||
)}
|
||||
|
||||
{current.port && <Badge className='text-xs'>{current.port}</Badge>}
|
||||
</div>
|
||||
onCheckedChange={(checked) => {
|
||||
form.setValue(`protocols.${i}.enable`, checked);
|
||||
}}
|
||||
onClick={(e) => e.stopPropagation()}
|
||||
/>
|
||||
</div>
|
||||
</AccordionTrigger>
|
||||
<AccordionContent className='px-4 pb-4 pt-0'>
|
||||
<div className='-mx-4 space-y-4 rounded-b-lg border-t px-4 pt-4'>
|
||||
{renderGroupCard('basic', fields, 'basic', control, i, current, t)}
|
||||
{renderGroupCard('plugin', fields, 'plugin', control, i, current, t)}
|
||||
{renderGroupCard('basic', fields, 'basic', control, form, i, current, t)}
|
||||
{renderGroupCard('obfs', fields, 'obfs', control, form, i, current, t)}
|
||||
{renderGroupCard(
|
||||
'transport',
|
||||
fields,
|
||||
'transport',
|
||||
control,
|
||||
form,
|
||||
i,
|
||||
current,
|
||||
t,
|
||||
)}
|
||||
{renderGroupCard(
|
||||
'security',
|
||||
fields,
|
||||
'security',
|
||||
control,
|
||||
form,
|
||||
i,
|
||||
current,
|
||||
t,
|
||||
)}
|
||||
{renderGroupCard(
|
||||
'reality',
|
||||
fields,
|
||||
'reality',
|
||||
control,
|
||||
form,
|
||||
i,
|
||||
current,
|
||||
t,
|
||||
)}
|
||||
{renderGroupCard(
|
||||
'encryption',
|
||||
fields,
|
||||
'encryption',
|
||||
control,
|
||||
form,
|
||||
i,
|
||||
current,
|
||||
t,
|
||||
)}
|
||||
{renderGroupCard('security', fields, 'security', control, i, current, t)}
|
||||
{renderGroupCard('reality', fields, 'reality', control, i, current, t)}
|
||||
</div>
|
||||
</AccordionContent>
|
||||
</AccordionItem>
|
||||
@@ -576,7 +629,8 @@ export default function ServerForm(props: {
|
||||
return false;
|
||||
})}
|
||||
>
|
||||
{loading && <Icon icon='mdi:loading' className='mr-2 animate-spin' />} {t('confirm')}
|
||||
{loading && <Icon icon='mdi:loading' className='mr-2 animate-spin' />}
|
||||
{t('confirm')}
|
||||
</Button>
|
||||
</SheetFooter>
|
||||
</SheetContent>
|
||||
|
||||
@@ -56,6 +56,7 @@ import { useRef, useState } from 'react';
|
||||
import { useForm } from 'react-hook-form';
|
||||
import { toast } from 'sonner';
|
||||
import { z } from 'zod';
|
||||
import { subscribeSchema } from './schema';
|
||||
import { TemplatePreview } from './template-preview';
|
||||
|
||||
const createClientFormSchema = (t: any) =>
|
||||
@@ -313,7 +314,21 @@ export function ProtocolForm() {
|
||||
columns={columns}
|
||||
request={request}
|
||||
header={{
|
||||
title: <h2 className='text-lg font-semibold'>{t('protocol.title')}</h2>,
|
||||
title: (
|
||||
<div className='flex items-center justify-between'>
|
||||
<h2 className='text-lg font-semibold'>{t('protocol.title')}</h2>
|
||||
<a
|
||||
href='https://github.com/perfect-panel/subscription-template'
|
||||
target='_blank'
|
||||
rel='noreferrer'
|
||||
className='text-primary inline-flex items-center gap-2 rounded-md px-3 py-1 text-sm font-medium hover:underline'
|
||||
>
|
||||
<Icon icon='mdi:github' className='h-4 w-4' />
|
||||
<span>Template Repo</span>
|
||||
<Icon icon='mdi:open-in-new' className='text-muted-foreground h-4 w-4' />
|
||||
</a>
|
||||
</div>
|
||||
),
|
||||
toolbar: <Button onClick={handleAdd}>{t('actions.add')}</Button>,
|
||||
}}
|
||||
actions={{
|
||||
@@ -648,137 +663,7 @@ export function ProtocolForm() {
|
||||
<FormControl>
|
||||
<GoTemplateEditor
|
||||
showLineNumbers
|
||||
schema={{
|
||||
SiteName: { type: 'string', description: 'Site name' },
|
||||
SubscribeName: { type: 'string', description: 'Subscribe name' },
|
||||
Proxies: {
|
||||
type: 'array',
|
||||
description: 'Array of proxy nodes',
|
||||
items: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
Name: { type: 'string', description: 'Node name' },
|
||||
Server: { type: 'string', description: 'Server host' },
|
||||
Port: { type: 'number', description: 'Server port' },
|
||||
Type: { type: 'string', description: 'Proxy type' },
|
||||
Tags: {
|
||||
type: 'array',
|
||||
description: 'Node tags',
|
||||
items: { type: 'string' },
|
||||
},
|
||||
Sort: { type: 'number', description: 'Node sort order' },
|
||||
// Security Options
|
||||
Security: {
|
||||
type: 'string',
|
||||
description: 'Security protocol',
|
||||
},
|
||||
SNI: {
|
||||
type: 'string',
|
||||
description: 'Server Name Indication for TLS',
|
||||
},
|
||||
AllowInsecure: {
|
||||
type: 'boolean',
|
||||
description:
|
||||
'Allow insecure connections (skip certificate verification)',
|
||||
},
|
||||
Fingerprint: {
|
||||
type: 'string',
|
||||
description: 'Client fingerprint for TLS connections',
|
||||
},
|
||||
RealityServerAddr: {
|
||||
type: 'string',
|
||||
description: 'Reality server address',
|
||||
},
|
||||
RealityServerPort: {
|
||||
type: 'number',
|
||||
description: 'Reality server port',
|
||||
},
|
||||
RealityPrivateKey: {
|
||||
type: 'string',
|
||||
description: 'Reality private key for authentication',
|
||||
},
|
||||
RealityPublicKey: {
|
||||
type: 'string',
|
||||
description: 'Reality public key for authentication',
|
||||
},
|
||||
RealityShortId: {
|
||||
type: 'string',
|
||||
description: 'Reality short ID for authentication',
|
||||
},
|
||||
// Transport Options
|
||||
Transport: {
|
||||
type: 'string',
|
||||
description: 'Transport protocol (e.g., ws, http, grpc)',
|
||||
},
|
||||
Host: {
|
||||
type: 'string',
|
||||
description: 'For WebSocket/HTTP/HTTPS',
|
||||
},
|
||||
Path: { type: 'string', description: 'For HTTP/HTTPS' },
|
||||
ServiceName: {
|
||||
type: 'string',
|
||||
description: 'For gRPC',
|
||||
},
|
||||
// Shadowsocks Options
|
||||
Method: { type: 'string', description: 'Encryption method' },
|
||||
ServerKey: {
|
||||
type: 'string',
|
||||
description: 'For Shadowsocks 2022',
|
||||
},
|
||||
// Vmess/Vless/Trojan Options
|
||||
Flow: {
|
||||
type: 'string',
|
||||
description: 'Flow for Vmess/Vless/Trojan',
|
||||
},
|
||||
// Hysteria2 Options
|
||||
HopPorts: {
|
||||
type: 'string',
|
||||
description: 'Comma-separated list of hop ports',
|
||||
},
|
||||
HopInterval: {
|
||||
type: 'number',
|
||||
description: 'Interval for hop ports in seconds',
|
||||
},
|
||||
ObfsPassword: {
|
||||
type: 'string',
|
||||
description: 'Obfuscation password for Hysteria2',
|
||||
},
|
||||
// Tuic Options
|
||||
DisableSNI: {
|
||||
type: 'boolean',
|
||||
description: 'Disable SNI',
|
||||
},
|
||||
ReduceRtt: {
|
||||
type: 'boolean',
|
||||
description: 'Reduce RTT',
|
||||
},
|
||||
UDPRelayMode: {
|
||||
type: 'string',
|
||||
description: 'UDP relay mode (e.g., "full", "partial")',
|
||||
},
|
||||
CongestionController: {
|
||||
type: 'string',
|
||||
description: 'Congestion controller (e.g., "cubic", "bbr")',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
UserInfo: {
|
||||
type: 'object',
|
||||
description: 'User information',
|
||||
properties: {
|
||||
Password: { type: 'string', description: 'User password' },
|
||||
ExpiredAt: { type: 'string', description: 'Expiration date' },
|
||||
Download: { type: 'number', description: 'Downloaded bytes' },
|
||||
Upload: { type: 'number', description: 'Uploaded bytes' },
|
||||
Traffic: { type: 'number', description: 'Total traffic bytes' },
|
||||
SubscribeURL: {
|
||||
type: 'string',
|
||||
description: 'Subscription URL',
|
||||
},
|
||||
},
|
||||
},
|
||||
}}
|
||||
schema={subscribeSchema}
|
||||
enableSprig
|
||||
value={field.value || ''}
|
||||
onChange={(value) => field.onChange(value)}
|
||||
|
||||
@@ -0,0 +1,225 @@
|
||||
export const subscribeSchema = {
|
||||
SiteName: { type: 'string', description: 'Site name' },
|
||||
SubscribeName: { type: 'string', description: 'Subscribe name' },
|
||||
Proxies: {
|
||||
type: 'array',
|
||||
description: 'Array of proxy nodes',
|
||||
items: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
Name: { type: 'string', description: 'Node name' },
|
||||
Server: { type: 'string', description: 'Server host' },
|
||||
Port: { type: 'number', description: 'Server port' },
|
||||
Type: { type: 'string', description: 'Proxy type' },
|
||||
Tags: {
|
||||
type: 'array',
|
||||
description: 'Node tags',
|
||||
items: { type: 'string' },
|
||||
},
|
||||
Sort: { type: 'number', description: 'Node sort order' },
|
||||
// Security Options
|
||||
Security: {
|
||||
type: 'string',
|
||||
description: 'Security protocol',
|
||||
},
|
||||
SNI: {
|
||||
type: 'string',
|
||||
description: 'Server Name Indication for TLS',
|
||||
},
|
||||
AllowInsecure: {
|
||||
type: 'boolean',
|
||||
description: 'Allow insecure connections (skip certificate verification)',
|
||||
},
|
||||
Fingerprint: {
|
||||
type: 'string',
|
||||
description: 'Client fingerprint for TLS connections',
|
||||
},
|
||||
RealityServerAddr: {
|
||||
type: 'string',
|
||||
description: 'Reality server address',
|
||||
},
|
||||
RealityServerPort: {
|
||||
type: 'number',
|
||||
description: 'Reality server port',
|
||||
},
|
||||
RealityPrivateKey: {
|
||||
type: 'string',
|
||||
description: 'Reality private key for authentication',
|
||||
},
|
||||
RealityPublicKey: {
|
||||
type: 'string',
|
||||
description: 'Reality public key for authentication',
|
||||
},
|
||||
RealityShortId: {
|
||||
type: 'string',
|
||||
description: 'Reality short ID for authentication',
|
||||
},
|
||||
// Transport Options
|
||||
Transport: {
|
||||
type: 'string',
|
||||
description: 'Transport protocol (e.g., ws, http, grpc)',
|
||||
},
|
||||
Host: {
|
||||
type: 'string',
|
||||
description: 'For WebSocket/HTTP/HTTPS',
|
||||
},
|
||||
Path: { type: 'string', description: 'For HTTP/HTTPS' },
|
||||
ServiceName: {
|
||||
type: 'string',
|
||||
description: 'For gRPC',
|
||||
},
|
||||
// Shadowsocks Options
|
||||
Method: { type: 'string', description: 'Encryption method' },
|
||||
ServerKey: {
|
||||
type: 'string',
|
||||
description: 'For Shadowsocks 2022',
|
||||
},
|
||||
// Vmess/Vless/Trojan Options
|
||||
Flow: {
|
||||
type: 'string',
|
||||
description: 'Flow for Vmess/Vless/Trojan',
|
||||
},
|
||||
// Hysteria2 Options
|
||||
HopPorts: {
|
||||
type: 'string',
|
||||
description: 'Comma-separated list of hop ports',
|
||||
},
|
||||
HopInterval: {
|
||||
type: 'number',
|
||||
description: 'Interval for hop ports in seconds',
|
||||
},
|
||||
ObfsPassword: {
|
||||
type: 'string',
|
||||
description: 'Obfuscation password for Hysteria2',
|
||||
},
|
||||
// Tuic Options
|
||||
DisableSNI: {
|
||||
type: 'boolean',
|
||||
description: 'Disable SNI',
|
||||
},
|
||||
ReduceRtt: {
|
||||
type: 'boolean',
|
||||
description: 'Reduce RTT',
|
||||
},
|
||||
UDPRelayMode: {
|
||||
type: 'string',
|
||||
description: 'UDP relay mode (e.g., "full", "partial")',
|
||||
},
|
||||
CongestionController: {
|
||||
type: 'string',
|
||||
description: 'Congestion controller (e.g., "cubic", "bbr")',
|
||||
},
|
||||
// Hysteria2 additional options
|
||||
UpMbps: {
|
||||
type: 'number',
|
||||
description: 'Upload bandwidth in Mbps',
|
||||
},
|
||||
DownMbps: {
|
||||
type: 'number',
|
||||
description: 'Download bandwidth in Mbps',
|
||||
},
|
||||
// VLESS encryption options
|
||||
Encryption: {
|
||||
type: 'string',
|
||||
description: 'Encryption type for VLESS',
|
||||
},
|
||||
EncryptionMode: {
|
||||
type: 'string',
|
||||
description: 'Encryption mode (e.g., "native", "xorpub", "random")',
|
||||
},
|
||||
EncryptionRtt: {
|
||||
type: 'string',
|
||||
description: 'Encryption RTT (e.g., "0rtt", "1rtt")',
|
||||
},
|
||||
EncryptionTicket: {
|
||||
type: 'string',
|
||||
description: 'Encryption ticket',
|
||||
},
|
||||
EncryptionServerPadding: {
|
||||
type: 'string',
|
||||
description: 'Server padding for encryption',
|
||||
},
|
||||
EncryptionClientPadding: {
|
||||
type: 'string',
|
||||
description: 'Client padding for encryption',
|
||||
},
|
||||
EncryptionPassword: {
|
||||
type: 'string',
|
||||
description: 'Encryption password',
|
||||
},
|
||||
EncryptionPrivateKey: {
|
||||
type: 'string',
|
||||
description: 'Private key for encryption',
|
||||
},
|
||||
// XHTTP options
|
||||
XhttpMode: {
|
||||
type: 'string',
|
||||
description: 'XHTTP mode (e.g., "auto", "packet-up", "stream-up", "stream-one")',
|
||||
},
|
||||
XhttpExtra: {
|
||||
type: 'string',
|
||||
description: 'XHTTP extra parameters',
|
||||
},
|
||||
// Shadowsocks obfs options (combined with Hysteria2 obfs)
|
||||
ObfsHost: {
|
||||
type: 'string',
|
||||
description: 'Obfuscation host',
|
||||
},
|
||||
ObfsPath: {
|
||||
type: 'string',
|
||||
description: 'Obfuscation path',
|
||||
},
|
||||
// Shadowsocks cipher
|
||||
Cipher: {
|
||||
type: 'string',
|
||||
description: 'Shadowsocks cipher method',
|
||||
},
|
||||
// AnyTLS options
|
||||
PaddingScheme: {
|
||||
type: 'string',
|
||||
description: 'Padding scheme for AnyTLS',
|
||||
},
|
||||
// Mieru options
|
||||
Multiplex: {
|
||||
type: 'string',
|
||||
description: 'Multiplex level (e.g., "none", "low", "middle", "high")',
|
||||
},
|
||||
// General protocol field
|
||||
Enable: {
|
||||
type: 'boolean',
|
||||
description: 'Whether this protocol is enabled',
|
||||
},
|
||||
// UUID for vmess/vless
|
||||
UUID: {
|
||||
type: 'string',
|
||||
description: 'User UUID for vmess/vless protocols',
|
||||
},
|
||||
// Alternative ID for vmess
|
||||
AlterId: {
|
||||
type: 'number',
|
||||
description: 'Alternative ID for vmess (deprecated)',
|
||||
},
|
||||
// Password for trojan/tuic
|
||||
Password: {
|
||||
type: 'string',
|
||||
description: 'Password for authentication',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
UserInfo: {
|
||||
type: 'object',
|
||||
description: 'User information',
|
||||
properties: {
|
||||
Password: { type: 'string', description: 'User password' },
|
||||
ExpiredAt: { type: 'string', description: 'Expiration date' },
|
||||
Download: { type: 'number', description: 'Downloaded bytes' },
|
||||
Upload: { type: 'number', description: 'Uploaded bytes' },
|
||||
Traffic: { type: 'number', description: 'Total traffic bytes' },
|
||||
SubscribeURL: {
|
||||
type: 'string',
|
||||
description: 'Subscription URL',
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
@@ -3,9 +3,15 @@
|
||||
import { previewSubscribeTemplate } from '@/services/admin/application';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import { Sheet, SheetContent, SheetHeader, SheetTitle } from '@workspace/ui/components/sheet';
|
||||
import {
|
||||
Sheet,
|
||||
SheetContent,
|
||||
SheetHeader,
|
||||
SheetTitle,
|
||||
SheetTrigger,
|
||||
} from '@workspace/ui/components/sheet';
|
||||
import { MonacoEditor } from '@workspace/ui/custom-components/editor/monaco-editor';
|
||||
import { Icon } from '@workspace/ui/custom-components/icon';
|
||||
import { Markdown } from '@workspace/ui/custom-components/markdown';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { useState } from 'react';
|
||||
|
||||
@@ -27,7 +33,6 @@ export function TemplatePreview({ applicationId, output_format }: TemplatePrevie
|
||||
|
||||
const originalContent = data?.data?.data?.template || '';
|
||||
const errorMessage = (error as any)?.data?.msg || error?.message || t('failed');
|
||||
const displayContent = originalContent || (error ? errorMessage : '');
|
||||
|
||||
const getDecodedContent = () => {
|
||||
if (output_format === 'base64' && originalContent) {
|
||||
@@ -41,49 +46,61 @@ export function TemplatePreview({ applicationId, output_format }: TemplatePrevie
|
||||
};
|
||||
|
||||
const getDisplayContent = () => {
|
||||
if (error) return errorMessage;
|
||||
if (!originalContent) return '';
|
||||
switch (output_format) {
|
||||
case 'base64':
|
||||
return `\`\`\`base64\n# ${t('base64.originalContent')}\n${displayContent}\n\n# ${t('base64.decodedContent')}\n${getDecodedContent()}\n\`\`\``;
|
||||
case 'yaml':
|
||||
return `\`\`\`yaml\n${displayContent}\n\`\`\``;
|
||||
case 'json':
|
||||
return `\`\`\`json\n${displayContent}\n\`\`\``;
|
||||
case 'conf':
|
||||
return `\`\`\`ini\n${displayContent}\n\`\`\``;
|
||||
case 'plain':
|
||||
return `\`\`\`text\n${displayContent}\n\`\`\``;
|
||||
case 'base64': {
|
||||
const decoded = getDecodedContent();
|
||||
return `${t('base64.originalContent')}:\n${originalContent}\n\n${t('base64.decodedContent')}:\n${decoded}`;
|
||||
}
|
||||
default:
|
||||
return displayContent;
|
||||
return originalContent;
|
||||
}
|
||||
};
|
||||
const mapLanguage = (fmt?: string) => {
|
||||
switch (fmt) {
|
||||
case 'json':
|
||||
return 'json';
|
||||
case 'yaml':
|
||||
return 'yaml';
|
||||
case 'base64':
|
||||
return 'ini';
|
||||
case 'plain':
|
||||
return 'ini';
|
||||
case 'conf':
|
||||
return 'ini';
|
||||
default:
|
||||
return 'ini';
|
||||
}
|
||||
};
|
||||
|
||||
const handleOpenChange = (newOpen: boolean) => {
|
||||
setIsOpen(newOpen);
|
||||
};
|
||||
|
||||
return (
|
||||
<>
|
||||
<Button variant='ghost' size='sm' onClick={() => setIsOpen(true)}>
|
||||
<Icon icon='mdi:eye' className='mr-2 h-4 w-4' />
|
||||
{t('preview')}
|
||||
</Button>
|
||||
<Sheet open={isOpen} onOpenChange={handleOpenChange}>
|
||||
<SheetContent className='w-[800px] max-w-[90vw] md:max-w-screen-md'>
|
||||
<SheetHeader>
|
||||
<SheetTitle>{t('title')}</SheetTitle>
|
||||
</SheetHeader>
|
||||
{isLoading ? (
|
||||
<div className='flex items-center justify-center'>
|
||||
<Icon icon='mdi:loading' className='h-6 w-6 animate-spin' />
|
||||
<span className='ml-2'>{t('loading')}</span>
|
||||
</div>
|
||||
) : (
|
||||
<div className='*:text-sm [&_pre>div>div+div]:max-h-[calc(100dvh-48px-36px-36px)] [&_pre>div>div+div]:overflow-auto'>
|
||||
<Markdown>{getDisplayContent()}</Markdown>
|
||||
</div>
|
||||
)}
|
||||
</SheetContent>
|
||||
</Sheet>
|
||||
</>
|
||||
<Sheet open={isOpen} onOpenChange={setIsOpen}>
|
||||
<SheetTrigger asChild>
|
||||
<Button variant='ghost'>
|
||||
<Icon icon='mdi:eye' className='h-4 w-4' />
|
||||
{t('preview')}
|
||||
</Button>
|
||||
</SheetTrigger>
|
||||
<SheetHeader>
|
||||
<SheetTitle></SheetTitle>
|
||||
</SheetHeader>
|
||||
<SheetContent className='w-[800px] max-w-[90vw] pt-10 md:max-w-screen-md'>
|
||||
{isLoading ? (
|
||||
<div className='flex items-center justify-center'>
|
||||
<Icon icon='mdi:loading' className='h-6 w-6 animate-spin' />
|
||||
<span className='ml-2'>{t('loading')}</span>
|
||||
</div>
|
||||
) : (
|
||||
<MonacoEditor
|
||||
title={t('title')}
|
||||
value={getDisplayContent()}
|
||||
language={mapLanguage(output_format)}
|
||||
showLineNumbers
|
||||
readOnly
|
||||
/>
|
||||
)}
|
||||
</SheetContent>
|
||||
</Sheet>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import { getRegisterConfig, updateRegisterConfig } from '@/services/admin/system';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
@@ -61,17 +61,7 @@ export default function RegisterConfig() {
|
||||
enabled: open,
|
||||
});
|
||||
|
||||
const { data: subscribe } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 9999,
|
||||
});
|
||||
return data.data?.list as API.Subscribe[];
|
||||
},
|
||||
enabled: open,
|
||||
});
|
||||
const { subscribes } = useSubscribe();
|
||||
|
||||
const form = useForm<RegisterFormData>({
|
||||
resolver: zodResolver(registerSchema),
|
||||
@@ -268,12 +258,10 @@ export default function RegisterConfig() {
|
||||
field.onChange(value);
|
||||
}
|
||||
}}
|
||||
options={
|
||||
subscribe?.map((item) => ({
|
||||
label: item.name,
|
||||
value: item.id,
|
||||
})) || []
|
||||
}
|
||||
options={subscribes?.map((item) => ({
|
||||
label: item.name!,
|
||||
value: item.id!,
|
||||
}))}
|
||||
className='bg-secondary w-32 rounded-r-none'
|
||||
/>
|
||||
)}
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
import { Display } from '@/components/display';
|
||||
import { ProTable, ProTableActions } from '@/components/pro-table';
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import {
|
||||
createUser,
|
||||
deleteUser,
|
||||
@@ -10,6 +9,7 @@ import {
|
||||
getUserList,
|
||||
updateUserBasicInfo,
|
||||
} from '@/services/admin/user';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { formatDate } from '@/utils/common';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Badge } from '@workspace/ui/components/badge';
|
||||
@@ -49,16 +49,7 @@ export default function Page() {
|
||||
const ref = useRef<ProTableActions>(null);
|
||||
const sp = useSearchParams();
|
||||
|
||||
const { data: subscribeList } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 9999,
|
||||
});
|
||||
return data.data?.list as API.SubscribeGroup[];
|
||||
},
|
||||
});
|
||||
const { subscribes } = useSubscribe();
|
||||
|
||||
const initialFilters = {
|
||||
search: sp.get('search') || undefined,
|
||||
@@ -69,6 +60,7 @@ export default function Page() {
|
||||
|
||||
return (
|
||||
<ProTable<API.User, API.GetUserListParams>
|
||||
key={initialFilters.user_id}
|
||||
action={ref}
|
||||
initialFilters={initialFilters}
|
||||
header={{
|
||||
@@ -194,9 +186,9 @@ export default function Page() {
|
||||
{
|
||||
key: 'subscribe_id',
|
||||
placeholder: t('subscription'),
|
||||
options: subscribeList?.map((item) => ({
|
||||
label: item.name,
|
||||
value: String(item.id),
|
||||
options: subscribes?.map((item) => ({
|
||||
label: item.name!,
|
||||
value: String(item.id!),
|
||||
})),
|
||||
},
|
||||
{
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
import { Display } from '@/components/display';
|
||||
import { ProTable, ProTableActions } from '@/components/pro-table';
|
||||
import useGlobalStore from '@/config/use-global';
|
||||
import {
|
||||
createUserSubscribe,
|
||||
deleteUserSubscribe,
|
||||
@@ -28,6 +29,7 @@ export default function UserSubscription({ userId }: { userId: number }) {
|
||||
const t = useTranslations('user');
|
||||
const [loading, setLoading] = useState(false);
|
||||
const ref = useRef<ProTableActions>(null);
|
||||
const { getUserSubscribeUrls } = useGlobalStore();
|
||||
|
||||
return (
|
||||
<ProTable<API.UserSubscribe, Record<string, unknown>>
|
||||
@@ -146,6 +148,16 @@ export default function UserSubscription({ userId }: { userId: number }) {
|
||||
return true;
|
||||
}}
|
||||
/>,
|
||||
<Button
|
||||
key='copy'
|
||||
variant='secondary'
|
||||
onClick={async () => {
|
||||
await navigator.clipboard.writeText(getUserSubscribeUrls(row.token)[0] || '');
|
||||
toast.success(t('copySuccess'));
|
||||
}}
|
||||
>
|
||||
{t('copySubscription')}
|
||||
</Button>,
|
||||
<ConfirmButton
|
||||
key='delete'
|
||||
trigger={<Button variant='destructive'>{t('delete')}</Button>}
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import { getSubscribeList } from '@/services/admin/subscribe';
|
||||
import { useSubscribe } from '@/store/subscribe';
|
||||
import { zodResolver } from '@hookform/resolvers/zod';
|
||||
import { useQuery } from '@tanstack/react-query';
|
||||
import { Button } from '@workspace/ui/components/button';
|
||||
import {
|
||||
Form,
|
||||
@@ -74,16 +73,7 @@ export function SubscriptionForm({ trigger, title, loading, initialData, onSubmi
|
||||
}
|
||||
};
|
||||
|
||||
const { data: subscribe } = useQuery({
|
||||
queryKey: ['getSubscribeList', 'all'],
|
||||
queryFn: async () => {
|
||||
const { data } = await getSubscribeList({
|
||||
page: 1,
|
||||
size: 9999,
|
||||
});
|
||||
return data.data?.list as API.Subscribe[];
|
||||
},
|
||||
});
|
||||
const { subscribes } = useSubscribe();
|
||||
|
||||
return (
|
||||
<Sheet open={open} onOpenChange={setOpen}>
|
||||
@@ -117,9 +107,9 @@ export function SubscriptionForm({ trigger, title, loading, initialData, onSubmi
|
||||
onChange={(value) => {
|
||||
form.setValue(field.name, value);
|
||||
}}
|
||||
options={subscribe?.map((item: API.Subscribe) => ({
|
||||
value: item.id,
|
||||
label: item.name,
|
||||
options={subscribes?.map((item) => ({
|
||||
value: item.id!,
|
||||
label: item.name!,
|
||||
}))}
|
||||
/>
|
||||
</FormControl>
|
||||
|
||||
@@ -86,7 +86,7 @@ export default function Statistics() {
|
||||
value: ServerTotal?.online_users || 0,
|
||||
subtitle: t('currentlyOnline'),
|
||||
icon: 'uil:users-alt',
|
||||
href: '/dashboard/users',
|
||||
href: '/dashboard/user',
|
||||
color: 'text-blue-600 dark:text-blue-400',
|
||||
iconBg: 'bg-blue-100 dark:bg-blue-900/30',
|
||||
},
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
import { NEXT_PUBLIC_API_URL, NEXT_PUBLIC_SITE_URL } from '@/config/constants';
|
||||
import { extractDomain } from '@workspace/ui/utils';
|
||||
import { create } from 'zustand';
|
||||
|
||||
export interface GlobalStore {
|
||||
@@ -5,9 +7,10 @@ export interface GlobalStore {
|
||||
user?: API.User;
|
||||
setCommon: (common: Partial<API.GetGlobalConfigResponse>) => void;
|
||||
setUser: (user?: API.User) => void;
|
||||
getUserSubscribeUrls: (uuid: string, type?: string) => string[];
|
||||
}
|
||||
|
||||
export const useGlobalStore = create<GlobalStore>((set) => ({
|
||||
export const useGlobalStore = create<GlobalStore>((set, get) => ({
|
||||
common: {
|
||||
site: {
|
||||
host: '',
|
||||
@@ -77,6 +80,22 @@ export const useGlobalStore = create<GlobalStore>((set) => ({
|
||||
},
|
||||
})),
|
||||
setUser: (user) => set({ user }),
|
||||
getUserSubscribeUrls: (uuid: string, type?: string) => {
|
||||
const { pan_domain, subscribe_domain, subscribe_path } = get().common.subscribe || {};
|
||||
const domains = subscribe_domain
|
||||
? subscribe_domain.split('\n')
|
||||
: [extractDomain(NEXT_PUBLIC_API_URL || NEXT_PUBLIC_SITE_URL || '', pan_domain)];
|
||||
|
||||
return domains.map((domain) => {
|
||||
if (pan_domain) {
|
||||
if (type) return `https://${uuid}.${type}.${domain}`;
|
||||
return `https://${uuid}.${domain}`;
|
||||
} else {
|
||||
if (type) return `https://${domain}${subscribe_path}?token=${uuid}&type=${type}`;
|
||||
return `https://${domain}${subscribe_path}?token=${uuid}`;
|
||||
}
|
||||
});
|
||||
},
|
||||
}));
|
||||
|
||||
export default useGlobalStore;
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Vyberte protokol…",
|
||||
"select_server": "Vyberte server…",
|
||||
"server": "Server",
|
||||
"sorted_success": "Úspěšně seřazeno",
|
||||
"tags": "Štítky",
|
||||
"tags_description": "Štítek pro skupinování oprávnění (včetně vazby na plán a dodací politiky).",
|
||||
"tags_placeholder": "Použijte Enter nebo čárku (,) pro přidání více štítků",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Zadejte šířku pásma, nechte prázdné pro BBR",
|
||||
"basic": "Základní konfigurace",
|
||||
"cancel": "Zrušit",
|
||||
"cipher": "Šifrovací algoritmus",
|
||||
"city": "Město",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Upravit server",
|
||||
"edit": "Upravit",
|
||||
"enabled": "Povoleno",
|
||||
"encryption_method": "Metoda šifrování",
|
||||
"encryption": "Metoda šifrování",
|
||||
"encryption_client_padding": "Padding klienta",
|
||||
"encryption_mode": "Režim",
|
||||
"encryption_password": "Heslo",
|
||||
"encryption_password_placeholder": "Nechte prázdné pro automatickou generaci, nahraďte ručně pro postkvantové šifrování",
|
||||
"encryption_private_key": "Soukromý klíč",
|
||||
"encryption_private_key_placeholder": "Nechte prázdné pro automatickou generaci, nahraďte ručně pro postkvantové šifrování",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Padding serveru",
|
||||
"encryption_ticket": "Čas lístku",
|
||||
"expireTime": "Čas vypršení",
|
||||
"expired": "Vypršelo",
|
||||
"extra": "Další konfigurace",
|
||||
"flow": "Tok",
|
||||
"hop_interval": "Interval skoku",
|
||||
"hop_ports": "Porty skoku",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Migrace dat se nezdařila",
|
||||
"migrated": "Data byla úspěšně migrována",
|
||||
"migrating": "Probíhá migrace...",
|
||||
"mode": "Režim",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Název",
|
||||
"noData": "Žádná data",
|
||||
"notAvailable": "Není k dispozici",
|
||||
"obfs": "Obfuskování",
|
||||
"obfs_host": "Obfs hostitel",
|
||||
"obfs_password": "Heslo pro obfuskaci",
|
||||
"obfs_password_placeholder": "Zadejte heslo pro obfuskaci",
|
||||
"obfs_path": "Obfs cesta",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Online uživatelé",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Servery",
|
||||
"path": "Cesta",
|
||||
"please_select": "Prosím vyberte",
|
||||
"plugin": "Konfigurace pluginu",
|
||||
"plugin_opts": "Možnosti pluginu",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Konfigurace protokolu",
|
||||
"protocol_configurations_desc": "Povolit a nakonfigurovat požadované typy protokolů",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Vyberte metodu šifrování",
|
||||
"server_key": "Klíč serveru",
|
||||
"service_name": "Název služby",
|
||||
"sorted_success": "Úspěšně seřazeno",
|
||||
"status": "Stav",
|
||||
"subscribeId": "ID předplatného",
|
||||
"subscription": "Předplatné",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Potvrdit",
|
||||
"confirmDelete": "Opravdu chcete smazat?",
|
||||
"confirmOffline": "Potvrdit offline",
|
||||
"copySubscription": "Kopírovat předplatné",
|
||||
"copySuccess": "Kopírování bylo úspěšné",
|
||||
"create": "Vytvořit",
|
||||
"createSubscription": "Vytvořit předplatné",
|
||||
"createSuccess": "Vytvoření úspěšné",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Protokoll auswählen…",
|
||||
"select_server": "Server auswählen…",
|
||||
"server": "Server",
|
||||
"sorted_success": "Erfolgreich sortiert",
|
||||
"tags": "Tags",
|
||||
"tags_description": "Berechtigungsgruppierungs-Tag (einschließlich Planbindung und Lieferrichtlinien).",
|
||||
"tags_placeholder": "Verwenden Sie Enter oder Komma (,) um mehrere Tags hinzuzufügen",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Geben Sie die Bandbreite ein, lassen Sie das Feld leer für BBR",
|
||||
"basic": "Grundkonfiguration",
|
||||
"cancel": "Abbrechen",
|
||||
"cipher": "Verschlüsselungsalgorithmus",
|
||||
"city": "Stadt",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Server bearbeiten",
|
||||
"edit": "Bearbeiten",
|
||||
"enabled": "Aktiviert",
|
||||
"encryption_method": "Verschlüsselungsmethode",
|
||||
"encryption": "Verschlüsselungsmethode",
|
||||
"encryption_client_padding": "Client-Padding",
|
||||
"encryption_mode": "Modus",
|
||||
"encryption_password": "Passwort",
|
||||
"encryption_password_placeholder": "Leer lassen für automatische Generierung, manuell ersetzen für post-quanten Verschlüsselung",
|
||||
"encryption_private_key": "Privater Schlüssel",
|
||||
"encryption_private_key_placeholder": "Leer lassen für automatische Generierung, manuell ersetzen für post-quanten Verschlüsselung",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Server-Padding",
|
||||
"encryption_ticket": "Ticketzeit",
|
||||
"expireTime": "Ablaufzeit",
|
||||
"expired": "Abgelaufen",
|
||||
"extra": "Zusätzliche Konfiguration",
|
||||
"flow": "Fluss",
|
||||
"hop_interval": "Hop-Intervall",
|
||||
"hop_ports": "Hop-Ports",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Datenmigration fehlgeschlagen",
|
||||
"migrated": "Daten erfolgreich migriert",
|
||||
"migrating": "Wird migriert...",
|
||||
"mode": "Modus",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Name",
|
||||
"noData": "Keine Daten",
|
||||
"notAvailable": "Nicht verfügbar",
|
||||
"obfs": "Obfuskation",
|
||||
"obfs_host": "Obfs-Host",
|
||||
"obfs_password": "Obfuskationspasswort",
|
||||
"obfs_password_placeholder": "Obfuskationspasswort eingeben",
|
||||
"obfs_path": "Obfs-Pfad",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Online-Benutzer",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Server",
|
||||
"path": "Pfad",
|
||||
"please_select": "Bitte auswählen",
|
||||
"plugin": "Plugin-Konfiguration",
|
||||
"plugin_opts": "Plugin-Optionen",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Protokollkonfigurationen",
|
||||
"protocol_configurations_desc": "Aktivieren und konfigurieren Sie die erforderlichen Protokolltypen",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Verschlüsselungsmethode auswählen",
|
||||
"server_key": "Server-Schlüssel",
|
||||
"service_name": "Dienstname",
|
||||
"sorted_success": "Erfolgreich sortiert",
|
||||
"status": "Status",
|
||||
"subscribeId": "Abonnement-ID",
|
||||
"subscription": "Abonnement",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Bestätigen",
|
||||
"confirmDelete": "Sind Sie sicher, dass Sie löschen möchten?",
|
||||
"confirmOffline": "Offline bestätigen",
|
||||
"copySubscription": "Abonnement kopieren",
|
||||
"copySuccess": "Kopie erfolgreich",
|
||||
"create": "Erstellen",
|
||||
"createSubscription": "Abonnement erstellen",
|
||||
"createSuccess": "Erstellung erfolgreich",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Select protocol…",
|
||||
"select_server": "Select server…",
|
||||
"server": "Server",
|
||||
"sorted_success": "Sorted successfully",
|
||||
"tags": "Tags",
|
||||
"tags_description": "Permission grouping tag (incl. plan binding and delivery policies).",
|
||||
"tags_placeholder": "Use Enter or comma (,) to add multiple tags",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Enter bandwidth, leave empty for BBR",
|
||||
"basic": "Basic Configuration",
|
||||
"cancel": "Cancel",
|
||||
"cipher": "Encryption Algorithm",
|
||||
"city": "City",
|
||||
"config": {
|
||||
"title": "Node configuration",
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Edit Server",
|
||||
"edit": "Edit",
|
||||
"enabled": "Enabled",
|
||||
"encryption_method": "Encryption method",
|
||||
"encryption": "Encryption Method",
|
||||
"encryption_client_padding": "Client Padding",
|
||||
"encryption_mode": "Mode",
|
||||
"encryption_password": "Password",
|
||||
"encryption_password_placeholder": "Leave empty for auto-generation, replace manually for post-quantum encryption",
|
||||
"encryption_private_key": "Private Key",
|
||||
"encryption_private_key_placeholder": "Leave empty for auto-generation, replace manually for post-quantum encryption",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Server Padding",
|
||||
"encryption_ticket": "Ticket time",
|
||||
"expireTime": "Expire time",
|
||||
"expired": "Expired",
|
||||
"extra": "Extra Configuration",
|
||||
"flow": "Flow",
|
||||
"hop_interval": "Hop interval",
|
||||
"hop_ports": "Hop ports",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Data migration failed",
|
||||
"migrated": "Data migrated successfully",
|
||||
"migrating": "Migrating...",
|
||||
"mode": "Mode",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Name",
|
||||
"noData": "No data",
|
||||
"notAvailable": "N/A",
|
||||
"obfs": "Obfuscation",
|
||||
"obfs_host": "Obfs Host",
|
||||
"obfs_password": "Obfuscation password",
|
||||
"obfs_password_placeholder": "Enter obfuscation password",
|
||||
"obfs_path": "Obfs Path",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Online users",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Servers",
|
||||
"path": "Path",
|
||||
"please_select": "Please select",
|
||||
"plugin": "Plugin Configuration",
|
||||
"plugin_opts": "Plugin Options",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Protocol Configurations",
|
||||
"protocol_configurations_desc": "Enable and configure the required protocol types",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Select encryption method",
|
||||
"server_key": "Server key",
|
||||
"service_name": "Service name",
|
||||
"sorted_success": "Sorted successfully",
|
||||
"status": "Status",
|
||||
"subscribeId": "Subscription ID",
|
||||
"subscription": "Subscription",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Confirm",
|
||||
"confirmDelete": "Confirm Delete",
|
||||
"confirmOffline": "Confirm Offline",
|
||||
"copySubscription": "Copy Subscription",
|
||||
"copySuccess": "Copy successful",
|
||||
"create": "Create",
|
||||
"createSubscription": "Create Subscription",
|
||||
"createSuccess": "Create successful",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Seleccionar protocolo…",
|
||||
"select_server": "Seleccionar servidor…",
|
||||
"server": "Servidor",
|
||||
"sorted_success": "Ordenado con éxito",
|
||||
"tags": "Etiquetas",
|
||||
"tags_description": "Etiqueta de agrupación de permisos (incl. vinculación de planes y políticas de entrega).",
|
||||
"tags_placeholder": "Usa Enter o coma (,) para añadir múltiples etiquetas",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Introduce el ancho de banda, deja vacío para BBR",
|
||||
"basic": "Configuración Básica",
|
||||
"cancel": "Cancelar",
|
||||
"cipher": "Algoritmo de Cifrado",
|
||||
"city": "Ciudad",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Editar Servidor",
|
||||
"edit": "Editar",
|
||||
"enabled": "Habilitado",
|
||||
"encryption_method": "Método de cifrado",
|
||||
"encryption": "Método de Cifrado",
|
||||
"encryption_client_padding": "Relleno del Cliente",
|
||||
"encryption_mode": "Modo",
|
||||
"encryption_password": "Contraseña",
|
||||
"encryption_password_placeholder": "Dejar vacío para auto-generación, reemplazar manualmente para cifrado post-cuántico",
|
||||
"encryption_private_key": "Clave Privada",
|
||||
"encryption_private_key_placeholder": "Dejar vacío para auto-generación, reemplazar manualmente para cifrado post-cuántico",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Relleno del Servidor",
|
||||
"encryption_ticket": "Tiempo de Ticket",
|
||||
"expireTime": "Tiempo de expiración",
|
||||
"expired": "Expirado",
|
||||
"extra": "Configuración Extra",
|
||||
"flow": "Flujo",
|
||||
"hop_interval": "Intervalo de salto",
|
||||
"hop_ports": "Puertos de salto",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "La migración de datos falló",
|
||||
"migrated": "Datos migrados con éxito",
|
||||
"migrating": "Migrando...",
|
||||
"mode": "Modo",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Nombre",
|
||||
"noData": "Sin datos",
|
||||
"notAvailable": "N/A",
|
||||
"obfs": "Ofuscación",
|
||||
"obfs_host": "Host de Ofuscación",
|
||||
"obfs_password": "Contraseña de ofuscación",
|
||||
"obfs_password_placeholder": "Ingrese la contraseña de ofuscación",
|
||||
"obfs_path": "Ruta de Ofuscación",
|
||||
"offline": "Desconectado",
|
||||
"online": "Conectado",
|
||||
"onlineUsers": "Usuarios en línea",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Servidores",
|
||||
"path": "Ruta",
|
||||
"please_select": "Por favor seleccione",
|
||||
"plugin": "Configuración del Plugin",
|
||||
"plugin_opts": "Opciones del Plugin",
|
||||
"port": "Puerto",
|
||||
"protocol_configurations": "Configuraciones de Protocolo",
|
||||
"protocol_configurations_desc": "Habilitar y configurar los tipos de protocolo requeridos",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Seleccionar método de cifrado",
|
||||
"server_key": "Clave del servidor",
|
||||
"service_name": "Nombre del servicio",
|
||||
"sorted_success": "Ordenado con éxito",
|
||||
"status": "Estado",
|
||||
"subscribeId": "ID de suscripción",
|
||||
"subscription": "Suscripción",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Confirmar",
|
||||
"confirmDelete": "¿Está seguro de que desea eliminar?",
|
||||
"confirmOffline": "Confirmar sin conexión",
|
||||
"copySubscription": "Copiar Suscripción",
|
||||
"copySuccess": "Copia exitosa",
|
||||
"create": "Crear",
|
||||
"createSubscription": "Crear suscripción",
|
||||
"createSuccess": "Creación exitosa",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Seleccionar protocolo…",
|
||||
"select_server": "Seleccionar servidor…",
|
||||
"server": "Servidor",
|
||||
"sorted_success": "Ordenado con éxito",
|
||||
"tags": "Etiquetas",
|
||||
"tags_description": "Etiqueta de agrupación de permisos (incl. vinculación de planes y políticas de entrega).",
|
||||
"tags_placeholder": "Usa Enter o coma (,) para agregar múltiples etiquetas",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Ingresa el ancho de banda, deja vacío para BBR",
|
||||
"basic": "Configuración Básica",
|
||||
"cancel": "Cancelar",
|
||||
"cipher": "Algoritmo de Cifrado",
|
||||
"city": "Ciudad",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Editar Servidor",
|
||||
"edit": "Editar",
|
||||
"enabled": "Habilitado",
|
||||
"encryption_method": "Método de encriptación",
|
||||
"encryption": "Método de Cifrado",
|
||||
"encryption_client_padding": "Relleno del Cliente",
|
||||
"encryption_mode": "Modo",
|
||||
"encryption_password": "Contraseña",
|
||||
"encryption_password_placeholder": "Dejar vacío para auto-generación, reemplazar manualmente para cifrado post-cuántico",
|
||||
"encryption_private_key": "Clave Privada",
|
||||
"encryption_private_key_placeholder": "Dejar vacío para auto-generación, reemplazar manualmente para cifrado post-cuántico",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Relleno del Servidor",
|
||||
"encryption_ticket": "Tiempo de Ticket",
|
||||
"expireTime": "Tiempo de expiración",
|
||||
"expired": "Expirado",
|
||||
"extra": "Configuración Extra",
|
||||
"flow": "Flujo",
|
||||
"hop_interval": "Intervalo de salto",
|
||||
"hop_ports": "Puertos de salto",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "La migración de datos falló",
|
||||
"migrated": "Datos migrados con éxito",
|
||||
"migrating": "Migrando...",
|
||||
"mode": "Modo",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Nombre",
|
||||
"noData": "Sin datos",
|
||||
"notAvailable": "N/A",
|
||||
"obfs": "Ofuscación",
|
||||
"obfs_host": "Host de Ofuscación",
|
||||
"obfs_password": "Contraseña de ofuscación",
|
||||
"obfs_password_placeholder": "Ingresa la contraseña de ofuscación",
|
||||
"obfs_path": "Ruta de Ofuscación",
|
||||
"offline": "Desconectado",
|
||||
"online": "Conectado",
|
||||
"onlineUsers": "Usuarios en línea",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Servidores",
|
||||
"path": "Ruta",
|
||||
"please_select": "Por favor selecciona",
|
||||
"plugin": "Configuración del Plugin",
|
||||
"plugin_opts": "Opciones del Plugin",
|
||||
"port": "Puerto",
|
||||
"protocol_configurations": "Configuraciones de Protocolo",
|
||||
"protocol_configurations_desc": "Habilitar y configurar los tipos de protocolo requeridos",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Selecciona el método de encriptación",
|
||||
"server_key": "Clave del servidor",
|
||||
"service_name": "Nombre del servicio",
|
||||
"sorted_success": "Ordenado con éxito",
|
||||
"status": "Estado",
|
||||
"subscribeId": "ID de suscripción",
|
||||
"subscription": "Suscripción",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Confirmar",
|
||||
"confirmDelete": "¿Está seguro de que desea eliminar?",
|
||||
"confirmOffline": "Confirmar sin conexión",
|
||||
"copySubscription": "Copiar Suscripción",
|
||||
"copySuccess": "Copia exitosa",
|
||||
"create": "Crear",
|
||||
"createSubscription": "Crear Suscripción",
|
||||
"createSuccess": "Creación exitosa",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "پروتکل را انتخاب کنید…",
|
||||
"select_server": "سرور را انتخاب کنید…",
|
||||
"server": "سرور",
|
||||
"sorted_success": "با موفقیت مرتب شد",
|
||||
"tags": "برچسبها",
|
||||
"tags_description": "برچسب گروهبندی مجوز (شامل پیوند برنامه و سیاستهای تحویل).",
|
||||
"tags_placeholder": "برای افزودن چندین برچسب از Enter یا ویرگول (,) استفاده کنید",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "عرض پهنای باند، برای BBR خالی بگذارید",
|
||||
"basic": "پیکربندی پایه",
|
||||
"cancel": "لغو",
|
||||
"cipher": "الگوریتم رمزنگاری",
|
||||
"city": "شهر",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "ویرایش سرور",
|
||||
"edit": "ویرایش",
|
||||
"enabled": "فعال",
|
||||
"encryption_method": "روش رمزنگاری",
|
||||
"encryption": "روش رمزنگاری",
|
||||
"encryption_client_padding": "پدینگ کلاینت",
|
||||
"encryption_mode": "حالت",
|
||||
"encryption_password": "گذرواژه",
|
||||
"encryption_password_placeholder": "برای تولید خودکار خالی بگذارید، به صورت دستی برای رمزنگاری پساکوانتومی جایگزین کنید",
|
||||
"encryption_private_key": "کلید خصوصی",
|
||||
"encryption_private_key_placeholder": "برای تولید خودکار خالی بگذارید، به صورت دستی برای رمزنگاری پساکوانتومی جایگزین کنید",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "پدینگ سرور",
|
||||
"encryption_ticket": "زمان بلیط",
|
||||
"expireTime": "زمان انقضا",
|
||||
"expired": "منقضی شده",
|
||||
"extra": "پیکربندی اضافی",
|
||||
"flow": "جریان",
|
||||
"hop_interval": "فاصله پرش",
|
||||
"hop_ports": "پورتهای پرش",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "انتقال داده ناموفق بود",
|
||||
"migrated": "داده با موفقیت منتقل شد",
|
||||
"migrating": "در حال انتقال...",
|
||||
"mode": "حالت",
|
||||
"multiplex": "چندمنظوره",
|
||||
"name": "نام",
|
||||
"noData": "هیچ دادهای",
|
||||
"notAvailable": "غیرقابل دسترسی",
|
||||
"obfs": "پنهانسازی",
|
||||
"obfs_host": "میزبان پنهانسازی",
|
||||
"obfs_password": "رمز عبور اختفا",
|
||||
"obfs_password_placeholder": "رمز عبور اختفا را وارد کنید",
|
||||
"obfs_path": "مسیر پنهانسازی",
|
||||
"offline": "آفلاین",
|
||||
"online": "آنلاین",
|
||||
"onlineUsers": "کاربران آنلاین",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "سرورها",
|
||||
"path": "مسیر",
|
||||
"please_select": "لطفاً انتخاب کنید",
|
||||
"plugin": "پیکربندی پلاگین",
|
||||
"plugin_opts": "گزینههای پلاگین",
|
||||
"port": "پورت",
|
||||
"protocol_configurations": "پیکربندیهای پروتکل",
|
||||
"protocol_configurations_desc": "پروتکلهای مورد نیاز را فعال و پیکربندی کنید",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "روش رمزنگاری را انتخاب کنید",
|
||||
"server_key": "کلید سرور",
|
||||
"service_name": "نام سرویس",
|
||||
"sorted_success": "با موفقیت مرتب شد",
|
||||
"status": "وضعیت",
|
||||
"subscribeId": "شناسه اشتراک",
|
||||
"subscription": "اشتراک",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "تأیید",
|
||||
"confirmDelete": "آیا مطمئن هستید که میخواهید حذف کنید؟",
|
||||
"confirmOffline": "تأیید آفلاین",
|
||||
"copySubscription": "کپی اشتراک",
|
||||
"copySuccess": "کپی با موفقیت انجام شد",
|
||||
"create": "ایجاد",
|
||||
"createSubscription": "ایجاد اشتراک",
|
||||
"createSuccess": "ایجاد با موفقیت انجام شد",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Valitse protokolla…",
|
||||
"select_server": "Valitse palvelin…",
|
||||
"server": "Palvelin",
|
||||
"sorted_success": "Lajiteltu onnistuneesti",
|
||||
"tags": "Tunnisteet",
|
||||
"tags_description": "Oikeuksien ryhmittelytunniste (mukaan lukien suunnitelman sitominen ja toimituskäytännöt).",
|
||||
"tags_placeholder": "Käytä Enteriä tai pilkkua (,) lisätäksesi useita tunnisteita",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Syötä kaistanleveys, jätä tyhjäksi BBR:lle",
|
||||
"basic": "Perusasetukset",
|
||||
"cancel": "Peruuta",
|
||||
"cipher": "Salausalgoritmi",
|
||||
"city": "Kaupunki",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Muokkaa palvelinta",
|
||||
"edit": "Muokkaa",
|
||||
"enabled": "Käytössä",
|
||||
"encryption_method": "Salausmenetelmä",
|
||||
"encryption": "Salausmenetelmä",
|
||||
"encryption_client_padding": "Asiakkaan täyte",
|
||||
"encryption_mode": "Tila",
|
||||
"encryption_password": "Salasana",
|
||||
"encryption_password_placeholder": "Jätä tyhjäksi automaattista generointia varten, vaihda manuaalisesti post-kvanttisalausta varten",
|
||||
"encryption_private_key": "Yksityinen avain",
|
||||
"encryption_private_key_placeholder": "Jätä tyhjäksi automaattista generointia varten, vaihda manuaalisesti post-kvanttisalausta varten",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Palvelimen täyte",
|
||||
"encryption_ticket": "Lippuaika",
|
||||
"expireTime": "Voimassaoloaika",
|
||||
"expired": "Vanhentunut",
|
||||
"extra": "Lisäasetukset",
|
||||
"flow": "Virta",
|
||||
"hop_interval": "Hyppyvälit",
|
||||
"hop_ports": "Hyppysatamat",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Tietojen siirto epäonnistui",
|
||||
"migrated": "Tiedot siirretty onnistuneesti",
|
||||
"migrating": "Siirretään...",
|
||||
"mode": "Tila",
|
||||
"multiplex": "Monistamo",
|
||||
"name": "Nimi",
|
||||
"noData": "Ei tietoja",
|
||||
"notAvailable": "Ei saatavilla",
|
||||
"obfs": "Häilytys",
|
||||
"obfs_host": "Häilytys isäntä",
|
||||
"obfs_password": "Häilytyssalasana",
|
||||
"obfs_password_placeholder": "Syötä häilytyssalasana",
|
||||
"obfs_path": "Häilytys polku",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Verkossa olevat käyttäjät",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Palvelimet",
|
||||
"path": "Polku",
|
||||
"please_select": "Ole hyvä ja valitse",
|
||||
"plugin": "Laajennuksen asetukset",
|
||||
"plugin_opts": "Laajennusvaihtoehdot",
|
||||
"port": "Portti",
|
||||
"protocol_configurations": "Protokolla-asetukset",
|
||||
"protocol_configurations_desc": "Ota käyttöön ja määritä tarvittavat protokollatyypit",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Valitse salausmenetelmä",
|
||||
"server_key": "Palvelimen avain",
|
||||
"service_name": "Palvelun nimi",
|
||||
"sorted_success": "Lajiteltu onnistuneesti",
|
||||
"status": "Tila",
|
||||
"subscribeId": "Tilauksen ID",
|
||||
"subscription": "Tilauksen",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Vahvista",
|
||||
"confirmDelete": "Oletko varma, että haluat poistaa?",
|
||||
"confirmOffline": "Vahvista offline-tila",
|
||||
"copySubscription": "Kopioi tilaus",
|
||||
"copySuccess": "Kopiointi onnistui",
|
||||
"create": "Luo",
|
||||
"createSubscription": "Luo tilaus",
|
||||
"createSuccess": "Luonti onnistui",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Sélectionner un protocole…",
|
||||
"select_server": "Sélectionner un serveur…",
|
||||
"server": "Serveur",
|
||||
"sorted_success": "Trié avec succès",
|
||||
"tags": "Étiquettes",
|
||||
"tags_description": "Étiquette de regroupement de permissions (y compris l'association de plan et les politiques de livraison).",
|
||||
"tags_placeholder": "Utilisez Entrée ou une virgule (,) pour ajouter plusieurs étiquettes",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Entrez la bande passante, laissez vide pour BBR",
|
||||
"basic": "Configuration de base",
|
||||
"cancel": "Annuler",
|
||||
"cipher": "Algorithme de chiffrement",
|
||||
"city": "Ville",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Modifier le serveur",
|
||||
"edit": "Modifier",
|
||||
"enabled": "Activé",
|
||||
"encryption_method": "Méthode de chiffrement",
|
||||
"encryption": "Méthode de chiffrement",
|
||||
"encryption_client_padding": "Remplissage client",
|
||||
"encryption_mode": "Mode",
|
||||
"encryption_password": "Mot de passe",
|
||||
"encryption_password_placeholder": "Laissez vide pour une génération automatique, remplacez manuellement pour un chiffrement post-quantique",
|
||||
"encryption_private_key": "Clé privée",
|
||||
"encryption_private_key_placeholder": "Laissez vide pour une génération automatique, remplacez manuellement pour un chiffrement post-quantique",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Remplissage serveur",
|
||||
"encryption_ticket": "Temps de ticket",
|
||||
"expireTime": "Temps d'expiration",
|
||||
"expired": "Expiré",
|
||||
"extra": "Configuration supplémentaire",
|
||||
"flow": "Flux",
|
||||
"hop_interval": "Intervalle de saut",
|
||||
"hop_ports": "Ports de saut",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Échec de la migration des données",
|
||||
"migrated": "Données migrées avec succès",
|
||||
"migrating": "Migration en cours...",
|
||||
"mode": "Mode",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Nom",
|
||||
"noData": "Aucune donnée",
|
||||
"notAvailable": "N/A",
|
||||
"obfs": "Obfuscation",
|
||||
"obfs_host": "Hôte Obfs",
|
||||
"obfs_password": "Mot de passe d'obfuscation",
|
||||
"obfs_password_placeholder": "Entrez le mot de passe d'obfuscation",
|
||||
"obfs_path": "Chemin Obfs",
|
||||
"offline": "Hors ligne",
|
||||
"online": "En ligne",
|
||||
"onlineUsers": "Utilisateurs en ligne",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Serveurs",
|
||||
"path": "Chemin",
|
||||
"please_select": "Veuillez sélectionner",
|
||||
"plugin": "Configuration du plugin",
|
||||
"plugin_opts": "Options du plugin",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Configurations de protocole",
|
||||
"protocol_configurations_desc": "Activer et configurer les types de protocole requis",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Sélectionner la méthode de chiffrement",
|
||||
"server_key": "Clé du serveur",
|
||||
"service_name": "Nom du service",
|
||||
"sorted_success": "Trié avec succès",
|
||||
"status": "Statut",
|
||||
"subscribeId": "ID d'abonnement",
|
||||
"subscription": "Abonnement",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Confirmer",
|
||||
"confirmDelete": "Êtes-vous sûr de vouloir supprimer ?",
|
||||
"confirmOffline": "Confirmer hors ligne",
|
||||
"copySubscription": "Copier l'abonnement",
|
||||
"copySuccess": "Copie réussie",
|
||||
"create": "Créer",
|
||||
"createSubscription": "Créer un abonnement",
|
||||
"createSuccess": "Création réussie",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "प्रोटोकॉल चुनें…",
|
||||
"select_server": "सर्वर चुनें…",
|
||||
"server": "सर्वर",
|
||||
"sorted_success": "सफलतापूर्वक क्रमबद्ध किया गया",
|
||||
"tags": "टैग",
|
||||
"tags_description": "अनुमति समूह टैग (योजना बाइंडिंग और वितरण नीतियों सहित)।",
|
||||
"tags_placeholder": "एकाधिक टैग जोड़ने के लिए Enter या कॉमा (,) का उपयोग करें",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "बैंडविड्थ दर्ज करें, BBR के लिए खाली छोड़ें",
|
||||
"basic": "बुनियादी कॉन्फ़िगरेशन",
|
||||
"cancel": "रद्द करें",
|
||||
"cipher": "एन्क्रिप्शन एल्गोरिदम",
|
||||
"city": "शहर",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "सर्वर संपादित करें",
|
||||
"edit": "संपादित करें",
|
||||
"enabled": "सक्षम",
|
||||
"encryption_method": "एन्क्रिप्शन विधि",
|
||||
"encryption": "एन्क्रिप्शन विधि",
|
||||
"encryption_client_padding": "क्लाइंट पैडिंग",
|
||||
"encryption_mode": "मोड",
|
||||
"encryption_password": "पासवर्ड",
|
||||
"encryption_password_placeholder": "स्वतः उत्पन्न करने के लिए खाली छोड़ें, पोस्ट-क्वांटम एन्क्रिप्शन के लिए मैन्युअल रूप से बदलें",
|
||||
"encryption_private_key": "निजी कुंजी",
|
||||
"encryption_private_key_placeholder": "स्वतः उत्पन्न करने के लिए खाली छोड़ें, पोस्ट-क्वांटम एन्क्रिप्शन के लिए मैन्युअल रूप से बदलें",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "सर्वर पैडिंग",
|
||||
"encryption_ticket": "टिकट समय",
|
||||
"expireTime": "समाप्ति समय",
|
||||
"expired": "समय समाप्त",
|
||||
"extra": "अतिरिक्त कॉन्फ़िगरेशन",
|
||||
"flow": "प्रवाह",
|
||||
"hop_interval": "हॉप अंतराल",
|
||||
"hop_ports": "हॉप पोर्ट",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "डेटा माइग्रेशन विफल",
|
||||
"migrated": "डेटा सफलतापूर्वक माइग्रेट किया गया",
|
||||
"migrating": "माइग्रेट किया जा रहा है...",
|
||||
"mode": "मोड",
|
||||
"multiplex": "मल्टीप्लेक्स",
|
||||
"name": "नाम",
|
||||
"noData": "कोई डेटा नहीं",
|
||||
"notAvailable": "उपलब्ध नहीं",
|
||||
"obfs": "ओबफस्केशन",
|
||||
"obfs_host": "ओबफ्स होस्ट",
|
||||
"obfs_password": "अवशोषण पासवर्ड",
|
||||
"obfs_password_placeholder": "अवशोषण पासवर्ड दर्ज करें",
|
||||
"obfs_path": "ओबफ्स पथ",
|
||||
"offline": "ऑफलाइन",
|
||||
"online": "ऑनलाइन",
|
||||
"onlineUsers": "ऑनलाइन उपयोगकर्ता",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "सर्वर",
|
||||
"path": "पथ",
|
||||
"please_select": "कृपया चुनें",
|
||||
"plugin": "प्लगइन कॉन्फ़िगरेशन",
|
||||
"plugin_opts": "प्लगइन विकल्प",
|
||||
"port": "पोर्ट",
|
||||
"protocol_configurations": "प्रोटोकॉल कॉन्फ़िगरेशन",
|
||||
"protocol_configurations_desc": "आवश्यक प्रोटोकॉल प्रकारों को सक्षम और कॉन्फ़िगर करें",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "एन्क्रिप्शन विधि चुनें",
|
||||
"server_key": "सर्वर कुंजी",
|
||||
"service_name": "सेवा का नाम",
|
||||
"sorted_success": "सफलता से क्रमबद्ध किया गया",
|
||||
"status": "स्थिति",
|
||||
"subscribeId": "सदस्यता आईडी",
|
||||
"subscription": "सदस्यता",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "पुष्टि करें",
|
||||
"confirmDelete": "क्या आप वाकई हटाना चाहते हैं?",
|
||||
"confirmOffline": "ऑफ़लाइन की पुष्टि करें",
|
||||
"copySubscription": "सदस्यता कॉपी करें",
|
||||
"copySuccess": "कॉपी सफल",
|
||||
"create": "सृजन",
|
||||
"createSubscription": "सदस्यता बनाएं",
|
||||
"createSuccess": "सृजन सफल",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Válassza ki a protokollt…",
|
||||
"select_server": "Válassza ki a szervert…",
|
||||
"server": "Szerver",
|
||||
"sorted_success": "Sikeresen rendezve",
|
||||
"tags": "Címkék",
|
||||
"tags_description": "Engedélyezési csoportosító címke (beleértve a tervkötést és a szállítási irányelveket).",
|
||||
"tags_placeholder": "Több címke hozzáadásához használja az Entert vagy a vesszőt (,)",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Adja meg a sávszélességet, hagyja üresen a BBR-hez",
|
||||
"basic": "Alapértelmezett Beállítások",
|
||||
"cancel": "Mégse",
|
||||
"cipher": "Titkosítási algoritmus",
|
||||
"city": "Város",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Szerver szerkesztése",
|
||||
"edit": "Szerkesztés",
|
||||
"enabled": "Engedélyezve",
|
||||
"encryption_method": "Titkosítási módszer",
|
||||
"encryption": "Titkosítási módszer",
|
||||
"encryption_client_padding": "Kliens kitöltés",
|
||||
"encryption_mode": "Mód",
|
||||
"encryption_password": "Jelszó",
|
||||
"encryption_password_placeholder": "Hagyja üresen az automatikus generáláshoz, cserélje ki kézzel a poszt-kvantum titkosításhoz",
|
||||
"encryption_private_key": "Privát kulcs",
|
||||
"encryption_private_key_placeholder": "Hagyja üresen az automatikus generáláshoz, cserélje ki kézzel a poszt-kvantum titkosításhoz",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Szerver kitöltés",
|
||||
"encryption_ticket": "Jegy idő",
|
||||
"expireTime": "Lejárati idő",
|
||||
"expired": "Lejárt",
|
||||
"extra": "További konfiguráció",
|
||||
"flow": "Forgalom",
|
||||
"hop_interval": "Ugrás időköz",
|
||||
"hop_ports": "Ugrás portok",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Az adatok migrálása sikertelen",
|
||||
"migrated": "Az adatok sikeresen migrálva",
|
||||
"migrating": "Migrálás...",
|
||||
"mode": "Mód",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Név",
|
||||
"noData": "Nincs adat",
|
||||
"notAvailable": "N/A",
|
||||
"obfs": "Obfuszkálás",
|
||||
"obfs_host": "Obfs gazda",
|
||||
"obfs_password": "Obfuszkálás jelszó",
|
||||
"obfs_password_placeholder": "Adja meg az obfuszkálás jelszót",
|
||||
"obfs_path": "Obfs útvonal",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Online felhasználók",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Szerverek",
|
||||
"path": "Útvonal",
|
||||
"please_select": "Kérjük, válasszon",
|
||||
"plugin": "Bővítmény Beállítások",
|
||||
"plugin_opts": "Bővítmény Opciók",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Protokoll Beállítások",
|
||||
"protocol_configurations_desc": "Engedélyezze és konfigurálja a szükséges protokolltípusokat",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Válassza ki a titkosítási módszert",
|
||||
"server_key": "Szerver kulcs",
|
||||
"service_name": "Szolgáltatás neve",
|
||||
"sorted_success": "Sikeresen rendezve",
|
||||
"status": "Állapot",
|
||||
"subscribeId": "Előfizetési ID",
|
||||
"subscription": "Előfizetés",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Megerősítés",
|
||||
"confirmDelete": "Biztosan törölni szeretné?",
|
||||
"confirmOffline": "Megerősítés offline",
|
||||
"copySubscription": "Előfizetés másolása",
|
||||
"copySuccess": "Másolás sikeres",
|
||||
"create": "Létrehozás",
|
||||
"createSubscription": "Előfizetés létrehozása",
|
||||
"createSuccess": "Sikeres létrehozás",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "プロトコルを選択…",
|
||||
"select_server": "サーバーを選択…",
|
||||
"server": "サーバー",
|
||||
"sorted_success": "正常にソートされました",
|
||||
"tags": "タグ",
|
||||
"tags_description": "権限グループ化タグ(プランバインディングおよび配信ポリシーを含む)。",
|
||||
"tags_placeholder": "複数のタグを追加するにはEnterまたはカンマ(,)を使用してください",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "帯域幅を入力してください。BBRの場合は空白のままにしてください。",
|
||||
"basic": "基本設定",
|
||||
"cancel": "キャンセル",
|
||||
"cipher": "暗号化アルゴリズム",
|
||||
"city": "都市",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "サーバーを編集",
|
||||
"edit": "編集",
|
||||
"enabled": "有効",
|
||||
"encryption_method": "暗号化方式",
|
||||
"encryption": "暗号化方式",
|
||||
"encryption_client_padding": "クライアントパディング",
|
||||
"encryption_mode": "モード",
|
||||
"encryption_password": "パスワード",
|
||||
"encryption_password_placeholder": "自動生成のために空白のままにし、ポスト量子暗号化のために手動で置き換えてください",
|
||||
"encryption_private_key": "秘密鍵",
|
||||
"encryption_private_key_placeholder": "自動生成のために空白のままにし、ポスト量子暗号化のために手動で置き換えてください",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "サーバーパディング",
|
||||
"encryption_ticket": "チケット時間",
|
||||
"expireTime": "有効期限",
|
||||
"expired": "期限切れ",
|
||||
"extra": "追加設定",
|
||||
"flow": "フロー",
|
||||
"hop_interval": "ホップ間隔",
|
||||
"hop_ports": "ホップポート",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "データの移行に失敗しました",
|
||||
"migrated": "データが正常に移行されました",
|
||||
"migrating": "移行中...",
|
||||
"mode": "モード",
|
||||
"multiplex": "マルチプレックス",
|
||||
"name": "名前",
|
||||
"noData": "データなし",
|
||||
"notAvailable": "利用不可",
|
||||
"obfs": "難読化",
|
||||
"obfs_host": "難読化ホスト",
|
||||
"obfs_password": "難読化パスワード",
|
||||
"obfs_password_placeholder": "難読化パスワードを入力してください",
|
||||
"obfs_path": "難読化パス",
|
||||
"offline": "オフライン",
|
||||
"online": "オンライン",
|
||||
"onlineUsers": "オンラインユーザー",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "サーバー",
|
||||
"path": "パス",
|
||||
"please_select": "選択してください",
|
||||
"plugin": "プラグイン設定",
|
||||
"plugin_opts": "プラグインオプション",
|
||||
"port": "ポート",
|
||||
"protocol_configurations": "プロトコル設定",
|
||||
"protocol_configurations_desc": "必要なプロトコルタイプを有効にして設定します",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "暗号化方式を選択",
|
||||
"server_key": "サーバーキー",
|
||||
"service_name": "サービス名",
|
||||
"sorted_success": "正常にソートされました",
|
||||
"status": "ステータス",
|
||||
"subscribeId": "サブスクリプションID",
|
||||
"subscription": "サブスクリプション",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "確認",
|
||||
"confirmDelete": "削除してもよろしいですか?",
|
||||
"confirmOffline": "オフラインを確認",
|
||||
"copySubscription": "サブスクリプションをコピー",
|
||||
"copySuccess": "コピーが成功しました",
|
||||
"create": "作成",
|
||||
"createSubscription": "サブスクリプションを作成",
|
||||
"createSuccess": "作成成功",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "프로토콜 선택…",
|
||||
"select_server": "서버 선택…",
|
||||
"server": "서버",
|
||||
"sorted_success": "정렬이 완료되었습니다.",
|
||||
"tags": "태그",
|
||||
"tags_description": "권한 그룹화 태그(계획 바인딩 및 배포 정책 포함).",
|
||||
"tags_placeholder": "여러 태그를 추가하려면 Enter 또는 쉼표(,)를 사용하세요",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "대역폭을 입력하세요. BBR을 사용하려면 비워 두세요.",
|
||||
"basic": "기본 설정",
|
||||
"cancel": "취소",
|
||||
"cipher": "암호화 알고리즘",
|
||||
"city": "도시",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "서버 편집",
|
||||
"edit": "편집",
|
||||
"enabled": "활성화됨",
|
||||
"encryption_method": "암호화 방법",
|
||||
"encryption": "암호화 방법",
|
||||
"encryption_client_padding": "클라이언트 패딩",
|
||||
"encryption_mode": "모드",
|
||||
"encryption_password": "비밀번호",
|
||||
"encryption_password_placeholder": "자동 생성하려면 비워 두고, 포스트 양자 암호화를 위해 수동으로 교체하세요",
|
||||
"encryption_private_key": "개인 키",
|
||||
"encryption_private_key_placeholder": "자동 생성하려면 비워 두고, 포스트 양자 암호화를 위해 수동으로 교체하세요",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "서버 패딩",
|
||||
"encryption_ticket": "티켓 시간",
|
||||
"expireTime": "만료 시간",
|
||||
"expired": "만료됨",
|
||||
"extra": "추가 구성",
|
||||
"flow": "흐름",
|
||||
"hop_interval": "홉 간격",
|
||||
"hop_ports": "홉 포트",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "데이터 마이그레이션 실패",
|
||||
"migrated": "데이터가 성공적으로 마이그레이션되었습니다",
|
||||
"migrating": "마이그레이션 중...",
|
||||
"mode": "모드",
|
||||
"multiplex": "멀티플렉스",
|
||||
"name": "이름",
|
||||
"noData": "데이터 없음",
|
||||
"notAvailable": "사용 불가",
|
||||
"obfs": "난독화",
|
||||
"obfs_host": "난독화 호스트",
|
||||
"obfs_password": "난독화 비밀번호",
|
||||
"obfs_password_placeholder": "난독화 비밀번호를 입력하세요",
|
||||
"obfs_path": "난독화 경로",
|
||||
"offline": "오프라인",
|
||||
"online": "온라인",
|
||||
"onlineUsers": "온라인 사용자",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "서버",
|
||||
"path": "경로",
|
||||
"please_select": "선택해 주세요",
|
||||
"plugin": "플러그인 설정",
|
||||
"plugin_opts": "플러그인 옵션",
|
||||
"port": "포트",
|
||||
"protocol_configurations": "프로토콜 설정",
|
||||
"protocol_configurations_desc": "필요한 프로토콜 유형을 활성화하고 구성합니다",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "암호화 방법 선택",
|
||||
"server_key": "서버 키",
|
||||
"service_name": "서비스 이름",
|
||||
"sorted_success": "정렬이 완료되었습니다.",
|
||||
"status": "상태",
|
||||
"subscribeId": "구독 ID",
|
||||
"subscription": "구독",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "확인",
|
||||
"confirmDelete": "삭제하시겠습니까?",
|
||||
"confirmOffline": "오프라인 확인",
|
||||
"copySubscription": "구독 복사",
|
||||
"copySuccess": "복사 성공",
|
||||
"create": "생성",
|
||||
"createSubscription": "구독 생성",
|
||||
"createSuccess": "생성 성공",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Velg protokoll…",
|
||||
"select_server": "Velg server…",
|
||||
"server": "Server",
|
||||
"sorted_success": "Sortert med suksess",
|
||||
"tags": "Tagger",
|
||||
"tags_description": "Tillatelsesgrupperingstagg (inkl. planbinding og leveringspolicyer).",
|
||||
"tags_placeholder": "Bruk Enter eller komma (,) for å legge til flere tagger",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Skriv inn båndbredde, la stå tomt for BBR",
|
||||
"basic": "Grunnleggende Konfigurasjon",
|
||||
"cancel": "Avbryt",
|
||||
"cipher": "Krypteringsalgoritme",
|
||||
"city": "By",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Rediger server",
|
||||
"edit": "Rediger",
|
||||
"enabled": "Aktivert",
|
||||
"encryption_method": "Krypteringsmetode",
|
||||
"encryption": "Krypteringsmetode",
|
||||
"encryption_client_padding": "Klient Padding",
|
||||
"encryption_mode": "Modus",
|
||||
"encryption_password": "Passord",
|
||||
"encryption_password_placeholder": "La stå tom for automatisk generering, erstatt manuelt for post-kvantum kryptering",
|
||||
"encryption_private_key": "Privat nøkkel",
|
||||
"encryption_private_key_placeholder": "La stå tom for automatisk generering, erstatt manuelt for post-kvantum kryptering",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Server Padding",
|
||||
"encryption_ticket": "Billettid",
|
||||
"expireTime": "Utløpstid",
|
||||
"expired": "Utløpt",
|
||||
"extra": "Ekstra konfigurasjon",
|
||||
"flow": "Flyt",
|
||||
"hop_interval": "Hoppintervall",
|
||||
"hop_ports": "Hoppporter",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Datamigrering mislyktes",
|
||||
"migrated": "Data migrert med suksess",
|
||||
"migrating": "Migrerer...",
|
||||
"mode": "Modus",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Navn",
|
||||
"noData": "Ingen data",
|
||||
"notAvailable": "Ikke tilgjengelig",
|
||||
"obfs": "Obfuskering",
|
||||
"obfs_host": "Obfs Vert",
|
||||
"obfs_password": "Obfuskasjonspassord",
|
||||
"obfs_password_placeholder": "Skriv inn obfuskasjonspassord",
|
||||
"obfs_path": "Obfs Sti",
|
||||
"offline": "Frakoblet",
|
||||
"online": "På nett",
|
||||
"onlineUsers": "Brukere på nett",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Servere",
|
||||
"path": "Sti",
|
||||
"please_select": "Vennligst velg",
|
||||
"plugin": "Plugin Konfigurasjon",
|
||||
"plugin_opts": "Plugin Alternativer",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Protokoll Konfigurasjoner",
|
||||
"protocol_configurations_desc": "Aktiver og konfigurer de nødvendige protokolltypene",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Velg krypteringsmetode",
|
||||
"server_key": "Servernøkkel",
|
||||
"service_name": "Tjenestenavn",
|
||||
"sorted_success": "Sortert med suksess",
|
||||
"status": "Status",
|
||||
"subscribeId": "Abonnements-ID",
|
||||
"subscription": "Abonnement",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "bekreft",
|
||||
"confirmDelete": "Er du sikker på at du vil slette?",
|
||||
"confirmOffline": "Bekreft frakoblet",
|
||||
"copySubscription": "Kopier abonnement",
|
||||
"copySuccess": "Kopiering vellykket",
|
||||
"create": "opprett",
|
||||
"createSubscription": "Opprett abonnement",
|
||||
"createSuccess": "Opprettelse vellykket",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Wybierz protokół…",
|
||||
"select_server": "Wybierz serwer…",
|
||||
"server": "Serwer",
|
||||
"sorted_success": "Posortowano pomyślnie",
|
||||
"tags": "Tagi",
|
||||
"tags_description": "Tag grupujący uprawnienia (w tym powiązania planu i polityki dostarczania).",
|
||||
"tags_placeholder": "Użyj Enter lub przecinka (,) aby dodać wiele tagów",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Wprowadź przepustowość, pozostaw puste dla BBR",
|
||||
"basic": "Podstawowa konfiguracja",
|
||||
"cancel": "Anuluj",
|
||||
"cipher": "Algorytm szyfrowania",
|
||||
"city": "Miasto",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Edytuj serwer",
|
||||
"edit": "Edytuj",
|
||||
"enabled": "Włączony",
|
||||
"encryption_method": "Metoda szyfrowania",
|
||||
"encryption": "Metoda szyfrowania",
|
||||
"encryption_client_padding": "Padding klienta",
|
||||
"encryption_mode": "Tryb",
|
||||
"encryption_password": "Hasło",
|
||||
"encryption_password_placeholder": "Pozostaw puste dla automatycznego generowania, zastąp ręcznie dla szyfrowania post-kwantowego",
|
||||
"encryption_private_key": "Klucz prywatny",
|
||||
"encryption_private_key_placeholder": "Pozostaw puste dla automatycznego generowania, zastąp ręcznie dla szyfrowania post-kwantowego",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Padding serwera",
|
||||
"encryption_ticket": "Czas biletu",
|
||||
"expireTime": "Czas wygaśnięcia",
|
||||
"expired": "Wygasł",
|
||||
"extra": "Dodatkowa konfiguracja",
|
||||
"flow": "Przepływ",
|
||||
"hop_interval": "Interwał skoku",
|
||||
"hop_ports": "Porty skoku",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Migracja danych nie powiodła się",
|
||||
"migrated": "Dane zostały pomyślnie zmigrowane",
|
||||
"migrating": "Migracja...",
|
||||
"mode": "Tryb",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Nazwa",
|
||||
"noData": "Brak danych",
|
||||
"notAvailable": "N/D",
|
||||
"obfs": "Obfuskacja",
|
||||
"obfs_host": "Host obfuskacji",
|
||||
"obfs_password": "Hasło obfuskacji",
|
||||
"obfs_password_placeholder": "Wprowadź hasło obfuskacji",
|
||||
"obfs_path": "Ścieżka obfuskacji",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Użytkownicy online",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Serwery",
|
||||
"path": "Ścieżka",
|
||||
"please_select": "Proszę wybrać",
|
||||
"plugin": "Konfiguracja wtyczki",
|
||||
"plugin_opts": "Opcje wtyczki",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Konfiguracje protokołów",
|
||||
"protocol_configurations_desc": "Włącz i skonfiguruj wymagane typy protokołów",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Wybierz metodę szyfrowania",
|
||||
"server_key": "Klucz serwera",
|
||||
"service_name": "Nazwa usługi",
|
||||
"sorted_success": "Posortowano pomyślnie",
|
||||
"status": "Status",
|
||||
"subscribeId": "ID subskrypcji",
|
||||
"subscription": "Subskrypcja",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Potwierdź",
|
||||
"confirmDelete": "Czy na pewno chcesz usunąć?",
|
||||
"confirmOffline": "Potwierdź tryb offline",
|
||||
"copySubscription": "Kopiuj subskrypcję",
|
||||
"copySuccess": "Kopiowanie zakończone sukcesem",
|
||||
"create": "Utwórz",
|
||||
"createSubscription": "Utwórz subskrypcję",
|
||||
"createSuccess": "Utworzono pomyślnie",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Selecionar protocolo…",
|
||||
"select_server": "Selecionar servidor…",
|
||||
"server": "Servidor",
|
||||
"sorted_success": "Ordenado com sucesso",
|
||||
"tags": "Tags",
|
||||
"tags_description": "Tag de agrupamento de permissões (incl. vinculação de plano e políticas de entrega).",
|
||||
"tags_placeholder": "Use Enter ou vírgula (,) para adicionar várias tags",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Insira a largura de banda, deixe em branco para BBR",
|
||||
"basic": "Configuração Básica",
|
||||
"cancel": "Cancelar",
|
||||
"cipher": "Algoritmo de Criptografia",
|
||||
"city": "Cidade",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Editar Servidor",
|
||||
"edit": "Editar",
|
||||
"enabled": "Ativado",
|
||||
"encryption_method": "Método de criptografia",
|
||||
"encryption": "Método de Criptografia",
|
||||
"encryption_client_padding": "Preenchimento do Cliente",
|
||||
"encryption_mode": "Modo",
|
||||
"encryption_password": "Senha",
|
||||
"encryption_password_placeholder": "Deixe em branco para auto-geração, substitua manualmente para criptografia pós-quântica",
|
||||
"encryption_private_key": "Chave Privada",
|
||||
"encryption_private_key_placeholder": "Deixe em branco para auto-geração, substitua manualmente para criptografia pós-quântica",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Preenchimento do Servidor",
|
||||
"encryption_ticket": "Tempo do Ticket",
|
||||
"expireTime": "Tempo de expiração",
|
||||
"expired": "Expirado",
|
||||
"extra": "Configuração Extra",
|
||||
"flow": "Fluxo",
|
||||
"hop_interval": "Intervalo de salto",
|
||||
"hop_ports": "Portas de salto",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "A migração de dados falhou",
|
||||
"migrated": "Dados migrados com sucesso",
|
||||
"migrating": "Migrando...",
|
||||
"mode": "Modo",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Nome",
|
||||
"noData": "Sem dados",
|
||||
"notAvailable": "N/D",
|
||||
"obfs": "Ofuscação",
|
||||
"obfs_host": "Host de Ofuscação",
|
||||
"obfs_password": "Senha de ofuscação",
|
||||
"obfs_password_placeholder": "Insira a senha de ofuscação",
|
||||
"obfs_path": "Caminho de Ofuscação",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Usuários online",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Servidores",
|
||||
"path": "Caminho",
|
||||
"please_select": "Por favor, selecione",
|
||||
"plugin": "Configuração do Plugin",
|
||||
"plugin_opts": "Opções do Plugin",
|
||||
"port": "Porta",
|
||||
"protocol_configurations": "Configurações de Protocolo",
|
||||
"protocol_configurations_desc": "Ative e configure os tipos de protocolo necessários",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Selecionar método de criptografia",
|
||||
"server_key": "Chave do servidor",
|
||||
"service_name": "Nome do serviço",
|
||||
"sorted_success": "Ordenado com sucesso",
|
||||
"status": "Status",
|
||||
"subscribeId": "ID de assinatura",
|
||||
"subscription": "Assinatura",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "confirmar",
|
||||
"confirmDelete": "Você tem certeza de que deseja excluir?",
|
||||
"confirmOffline": "Confirmar Offline",
|
||||
"copySubscription": "Copiar Assinatura",
|
||||
"copySuccess": "Cópia bem-sucedida",
|
||||
"create": "Criar",
|
||||
"createSubscription": "Criar Assinatura",
|
||||
"createSuccess": "Criação bem-sucedida",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Selectează protocolul…",
|
||||
"select_server": "Selectează serverul…",
|
||||
"server": "Server",
|
||||
"sorted_success": "Sortat cu succes",
|
||||
"tags": "Etichete",
|
||||
"tags_description": "Etichetă de grupare a permisiunilor (incluzând legarea planului și politicile de livrare).",
|
||||
"tags_placeholder": "Folosește Enter sau virgulă (,) pentru a adăuga mai multe etichete",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Introduceți lățimea de bandă, lăsați liber pentru BBR",
|
||||
"basic": "Configurare de bază",
|
||||
"cancel": "Anulează",
|
||||
"cipher": "Algoritm de criptare",
|
||||
"city": "Oraș",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Editează Server",
|
||||
"edit": "Editează",
|
||||
"enabled": "Activat",
|
||||
"encryption_method": "Metodă de criptare",
|
||||
"encryption": "Metodă de criptare",
|
||||
"encryption_client_padding": "Padding client",
|
||||
"encryption_mode": "Mod",
|
||||
"encryption_password": "Parolă",
|
||||
"encryption_password_placeholder": "Lăsați gol pentru generare automată, înlocuiți manual pentru criptare post-cuantică",
|
||||
"encryption_private_key": "Cheie privată",
|
||||
"encryption_private_key_placeholder": "Lăsați gol pentru generare automată, înlocuiți manual pentru criptare post-cuantică",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Padding server",
|
||||
"encryption_ticket": "Timp bilet",
|
||||
"expireTime": "Timp de expirare",
|
||||
"expired": "Expirat",
|
||||
"extra": "Configurație suplimentară",
|
||||
"flow": "Flux",
|
||||
"hop_interval": "Interval de hop",
|
||||
"hop_ports": "Porturi hop",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Migrarea datelor a eșuat",
|
||||
"migrated": "Datele au fost migrate cu succes",
|
||||
"migrating": "Se migrează...",
|
||||
"mode": "Mod",
|
||||
"multiplex": "Multiplex",
|
||||
"name": "Nume",
|
||||
"noData": "Fără date",
|
||||
"notAvailable": "N/A",
|
||||
"obfs": "Obfuscare",
|
||||
"obfs_host": "Host Obfs",
|
||||
"obfs_password": "Parola de obfuscare",
|
||||
"obfs_password_placeholder": "Introdu parola de obfuscare",
|
||||
"obfs_path": "Cale Obfs",
|
||||
"offline": "Offline",
|
||||
"online": "Online",
|
||||
"onlineUsers": "Utilizatori online",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Servere",
|
||||
"path": "Cale",
|
||||
"please_select": "Te rog selectează",
|
||||
"plugin": "Configurare plugin",
|
||||
"plugin_opts": "Opțiuni plugin",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Configurări protocol",
|
||||
"protocol_configurations_desc": "Activează și configurează tipurile de protocol necesare",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Selectează metoda de criptare",
|
||||
"server_key": "Cheie server",
|
||||
"service_name": "Nume serviciu",
|
||||
"sorted_success": "Sortat cu succes",
|
||||
"status": "Stare",
|
||||
"subscribeId": "ID abonament",
|
||||
"subscription": "Abonament",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Confirmare",
|
||||
"confirmDelete": "Sunteți sigur că doriți să ștergeți?",
|
||||
"confirmOffline": "Confirmare Offline",
|
||||
"copySubscription": "Copiază Abonamentul",
|
||||
"copySuccess": "Copiază cu succes",
|
||||
"create": "crea",
|
||||
"createSubscription": "Creează Abonament",
|
||||
"createSuccess": "Creat cu succes",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Выберите протокол…",
|
||||
"select_server": "Выберите сервер…",
|
||||
"server": "Сервер",
|
||||
"sorted_success": "Успешно отсортировано",
|
||||
"tags": "Теги",
|
||||
"tags_description": "Тег для группировки разрешений (включая привязку плана и политики доставки).",
|
||||
"tags_placeholder": "Используйте Enter или запятую (,) для добавления нескольких тегов",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Введите пропускную способность, оставьте пустым для BBR",
|
||||
"basic": "Базовая конфигурация",
|
||||
"cancel": "Отмена",
|
||||
"cipher": "Алгоритм шифрования",
|
||||
"city": "Город",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Редактировать сервер",
|
||||
"edit": "Редактировать",
|
||||
"enabled": "Включено",
|
||||
"encryption_method": "Метод шифрования",
|
||||
"encryption": "Метод шифрования",
|
||||
"encryption_client_padding": "Дополнение клиента",
|
||||
"encryption_mode": "Режим",
|
||||
"encryption_password": "Пароль",
|
||||
"encryption_password_placeholder": "Оставьте пустым для авто-генерации, замените вручную для пост-квантового шифрования",
|
||||
"encryption_private_key": "Закрытый ключ",
|
||||
"encryption_private_key_placeholder": "Оставьте пустым для авто-генерации, замените вручную для пост-квантового шифрования",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Дополнение сервера",
|
||||
"encryption_ticket": "Время билета",
|
||||
"expireTime": "Время истечения",
|
||||
"expired": "Истекло",
|
||||
"extra": "Дополнительная конфигурация",
|
||||
"flow": "Поток",
|
||||
"hop_interval": "Интервал перехода",
|
||||
"hop_ports": "Порты перехода",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Ошибка при переносе данных",
|
||||
"migrated": "Данные успешно перенесены",
|
||||
"migrating": "Перенос данных...",
|
||||
"mode": "Режим",
|
||||
"multiplex": "Мультиплекс",
|
||||
"name": "Имя",
|
||||
"noData": "Нет данных",
|
||||
"notAvailable": "Недоступно",
|
||||
"obfs": "Обфускация",
|
||||
"obfs_host": "Обфусцированный хост",
|
||||
"obfs_password": "Пароль обфускации",
|
||||
"obfs_password_placeholder": "Введите пароль обфускации",
|
||||
"obfs_path": "Обфусцированный путь",
|
||||
"offline": "Офлайн",
|
||||
"online": "Онлайн",
|
||||
"onlineUsers": "Онлайн пользователи",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Серверы",
|
||||
"path": "Путь",
|
||||
"please_select": "Пожалуйста, выберите",
|
||||
"plugin": "Конфигурация плагина",
|
||||
"plugin_opts": "Опции плагина",
|
||||
"port": "Порт",
|
||||
"protocol_configurations": "Конфигурации протоколов",
|
||||
"protocol_configurations_desc": "Включите и настройте необходимые типы протоколов",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Выберите метод шифрования",
|
||||
"server_key": "Ключ сервера",
|
||||
"service_name": "Имя службы",
|
||||
"sorted_success": "Успешно отсортировано",
|
||||
"status": "Статус",
|
||||
"subscribeId": "ID подписки",
|
||||
"subscription": "Подписка",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Подтвердить",
|
||||
"confirmDelete": "Вы уверены, что хотите удалить?",
|
||||
"confirmOffline": "Подтвердить офлайн",
|
||||
"copySubscription": "Копировать подписку",
|
||||
"copySuccess": "Копирование успешно",
|
||||
"create": "Создать",
|
||||
"createSubscription": "Создать подписку",
|
||||
"createSuccess": "Создание успешно",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "เลือกโปรโตคอล…",
|
||||
"select_server": "เลือกเซิร์ฟเวอร์…",
|
||||
"server": "เซิร์ฟเวอร์",
|
||||
"sorted_success": "เรียงลำดับเรียบร้อยแล้ว",
|
||||
"tags": "แท็ก",
|
||||
"tags_description": "แท็กการจัดกลุ่มสิทธิ์ (รวมถึงการผูกแผนและนโยบายการจัดส่ง)",
|
||||
"tags_placeholder": "ใช้ Enter หรือเครื่องหมายจุลภาค (,) เพื่อเพิ่มแท็กหลายรายการ",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "กรุณากรอกแบนด์วิธ ทิ้งว่างไว้สำหรับ BBR",
|
||||
"basic": "การตั้งค่าพื้นฐาน",
|
||||
"cancel": "ยกเลิก",
|
||||
"cipher": "อัลกอริธึมการเข้ารหัส",
|
||||
"city": "เมือง",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "แก้ไขเซิร์ฟเวอร์",
|
||||
"edit": "แก้ไข",
|
||||
"enabled": "เปิดใช้งาน",
|
||||
"encryption_method": "วิธีการเข้ารหัส",
|
||||
"encryption": "วิธีการเข้ารหัส",
|
||||
"encryption_client_padding": "การเติมข้อมูลของลูกค้า",
|
||||
"encryption_mode": "โหมด",
|
||||
"encryption_password": "รหัสผ่าน",
|
||||
"encryption_password_placeholder": "ปล่อยว่างเพื่อสร้างอัตโนมัติ เปลี่ยนด้วยตนเองสำหรับการเข้ารหัสหลังควอนตัม",
|
||||
"encryption_private_key": "กุญแจส่วนตัว",
|
||||
"encryption_private_key_placeholder": "ปล่อยว่างเพื่อสร้างอัตโนมัติ เปลี่ยนด้วยตนเองสำหรับการเข้ารหัสหลังควอนตัม",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "การเติมข้อมูลของเซิร์ฟเวอร์",
|
||||
"encryption_ticket": "เวลาตั๋ว",
|
||||
"expireTime": "เวลาหมดอายุ",
|
||||
"expired": "หมดอายุ",
|
||||
"extra": "การกำหนดค่าพิเศษ",
|
||||
"flow": "การไหล",
|
||||
"hop_interval": "ช่วงเวลาการกระโดด",
|
||||
"hop_ports": "พอร์ตการกระโดด",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "การย้ายข้อมูลล้มเหลว",
|
||||
"migrated": "ย้ายข้อมูลสำเร็จ",
|
||||
"migrating": "กำลังย้ายข้อมูล...",
|
||||
"mode": "โหมด",
|
||||
"multiplex": "หลายช่อง",
|
||||
"name": "ชื่อ",
|
||||
"noData": "ไม่มีข้อมูล",
|
||||
"notAvailable": "ไม่สามารถใช้ได้",
|
||||
"obfs": "การทำให้ไม่สามารถอ่านได้",
|
||||
"obfs_host": "โฮสต์การทำให้ไม่สามารถอ่านได้",
|
||||
"obfs_password": "รหัสผ่านการปกปิด",
|
||||
"obfs_password_placeholder": "กรอกรหัสผ่านการปกปิด",
|
||||
"obfs_path": "เส้นทางการทำให้ไม่สามารถอ่านได้",
|
||||
"offline": "ออฟไลน์",
|
||||
"online": "ออนไลน์",
|
||||
"onlineUsers": "ผู้ใช้งานออนไลน์",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "เซิร์ฟเวอร์",
|
||||
"path": "เส้นทาง",
|
||||
"please_select": "กรุณาเลือก",
|
||||
"plugin": "การตั้งค่าปลั๊กอิน",
|
||||
"plugin_opts": "ตัวเลือกปลั๊กอิน",
|
||||
"port": "พอร์ต",
|
||||
"protocol_configurations": "การตั้งค่าโปรโตคอล",
|
||||
"protocol_configurations_desc": "เปิดใช้งานและกำหนดค่าประเภทโปรโตคอลที่ต้องการ",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "เลือกวิธีการเข้ารหัส",
|
||||
"server_key": "คีย์เซิร์ฟเวอร์",
|
||||
"service_name": "ชื่อบริการ",
|
||||
"sorted_success": "เรียงลำดับเรียบร้อยแล้ว",
|
||||
"status": "สถานะ",
|
||||
"subscribeId": "ID การสมัครสมาชิก",
|
||||
"subscription": "การสมัครสมาชิก",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "ยืนยัน",
|
||||
"confirmDelete": "คุณแน่ใจหรือว่าต้องการลบ?",
|
||||
"confirmOffline": "ยืนยันออฟไลน์",
|
||||
"copySubscription": "คัดลอกการสมัครสมาชิก",
|
||||
"copySuccess": "คัดลอกสำเร็จ",
|
||||
"create": "สร้าง",
|
||||
"createSubscription": "สร้างการสมัครสมาชิก",
|
||||
"createSuccess": "สร้างสำเร็จ",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Protokol seçin…",
|
||||
"select_server": "Sunucu seçin…",
|
||||
"server": "Sunucu",
|
||||
"sorted_success": "Başarıyla sıralandı",
|
||||
"tags": "Etiketler",
|
||||
"tags_description": "İzin gruplama etiketi (plan bağlama ve teslimat politikaları dahil).",
|
||||
"tags_placeholder": "Birden fazla etiket eklemek için Enter veya virgül (,) kullanın",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Bant genişliğini girin, BBR için boş bırakın",
|
||||
"basic": "Temel Yapılandırma",
|
||||
"cancel": "İptal",
|
||||
"cipher": "Şifreleme Algoritması",
|
||||
"city": "Şehir",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Sunucuyu Düzenle",
|
||||
"edit": "Düzenle",
|
||||
"enabled": "Etkin",
|
||||
"encryption_method": "Şifreleme yöntemi",
|
||||
"encryption": "Şifreleme Yöntemi",
|
||||
"encryption_client_padding": "İstemci Dolgusu",
|
||||
"encryption_mode": "Mod",
|
||||
"encryption_password": "Şifre",
|
||||
"encryption_password_placeholder": "Otomatik oluşturma için boş bırakın, post-kuantum şifreleme için manuel olarak değiştirin",
|
||||
"encryption_private_key": "Özel Anahtar",
|
||||
"encryption_private_key_placeholder": "Otomatik oluşturma için boş bırakın, post-kuantum şifreleme için manuel olarak değiştirin",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Sunucu Dolgusu",
|
||||
"encryption_ticket": "Bilet süresi",
|
||||
"expireTime": "Son kullanma zamanı",
|
||||
"expired": "Süresi dolmuş",
|
||||
"extra": "Ek Yapılandırma",
|
||||
"flow": "Akış",
|
||||
"hop_interval": "Atlama aralığı",
|
||||
"hop_ports": "Atlama portları",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Veri taşıma işlemi başarısız oldu",
|
||||
"migrated": "Veri başarıyla taşındı",
|
||||
"migrating": "Taşınıyor...",
|
||||
"mode": "Mod",
|
||||
"multiplex": "Çoklu Salon",
|
||||
"name": "İsim",
|
||||
"noData": "Veri yok",
|
||||
"notAvailable": "Mevcut değil",
|
||||
"obfs": "Obfuscation",
|
||||
"obfs_host": "Obfs Ana Bilgisi",
|
||||
"obfs_password": "Gizleme şifresi",
|
||||
"obfs_password_placeholder": "Gizleme şifresini girin",
|
||||
"obfs_path": "Obfs Yolu",
|
||||
"offline": "Çevrimdışı",
|
||||
"online": "Çevrimiçi",
|
||||
"onlineUsers": "Çevrimiçi kullanıcılar",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Sunucular",
|
||||
"path": "Yol",
|
||||
"please_select": "Lütfen seçin",
|
||||
"plugin": "Eklenti Yapılandırması",
|
||||
"plugin_opts": "Eklenti Seçenekleri",
|
||||
"port": "Port",
|
||||
"protocol_configurations": "Protokol Yapılandırmaları",
|
||||
"protocol_configurations_desc": "Gerekli protokol türlerini etkinleştir ve yapılandır",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Şifreleme yöntemini seçin",
|
||||
"server_key": "Sunucu anahtarı",
|
||||
"service_name": "Hizmet adı",
|
||||
"sorted_success": "Başarıyla sıralandı",
|
||||
"status": "Durum",
|
||||
"subscribeId": "Abonelik ID",
|
||||
"subscription": "Abonelik",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Onayla",
|
||||
"confirmDelete": "Silmek istediğinizden emin misiniz?",
|
||||
"confirmOffline": "Çevrimdışı Onayla",
|
||||
"copySubscription": "Aboneliği Kopyala",
|
||||
"copySuccess": "Kopyalama başarılı",
|
||||
"create": "oluştur",
|
||||
"createSubscription": "Abonelik Oluştur",
|
||||
"createSuccess": "Başarıyla oluşturuldu",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Виберіть протокол…",
|
||||
"select_server": "Виберіть сервер…",
|
||||
"server": "Сервер",
|
||||
"sorted_success": "Успішно відсортовано",
|
||||
"tags": "Теги",
|
||||
"tags_description": "Тег для групування дозволів (включаючи прив'язку плану та політики доставки).",
|
||||
"tags_placeholder": "Використовуйте Enter або кому (,) для додавання кількох тегів",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Введіть пропускну здатність, залиште порожнім для BBR",
|
||||
"basic": "Базова конфігурація",
|
||||
"cancel": "Скасувати",
|
||||
"cipher": "Алгоритм шифрування",
|
||||
"city": "Місто",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Редагувати сервер",
|
||||
"edit": "Редагувати",
|
||||
"enabled": "Увімкнено",
|
||||
"encryption_method": "Метод шифрування",
|
||||
"encryption": "Метод шифрування",
|
||||
"encryption_client_padding": "Паддінг клієнта",
|
||||
"encryption_mode": "Режим",
|
||||
"encryption_password": "Пароль",
|
||||
"encryption_password_placeholder": "Залиште порожнім для автоматичної генерації, замініть вручну для пост-квантового шифрування",
|
||||
"encryption_private_key": "Приватний ключ",
|
||||
"encryption_private_key_placeholder": "Залиште порожнім для автоматичної генерації, замініть вручну для пост-квантового шифрування",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "Паддінг сервера",
|
||||
"encryption_ticket": "Час квитка",
|
||||
"expireTime": "Час закінчення",
|
||||
"expired": "Термін дії закінчився",
|
||||
"extra": "Додаткова конфігурація",
|
||||
"flow": "Потік",
|
||||
"hop_interval": "Інтервал стрибка",
|
||||
"hop_ports": "Порти стрибка",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Міграція даних не вдалася",
|
||||
"migrated": "Дані успішно мігрували",
|
||||
"migrating": "Міграція...",
|
||||
"mode": "Режим",
|
||||
"multiplex": "Мультиплекс",
|
||||
"name": "Ім'я",
|
||||
"noData": "Немає даних",
|
||||
"notAvailable": "Н/Д",
|
||||
"obfs": "Обфускація",
|
||||
"obfs_host": "Обфускаційний хост",
|
||||
"obfs_password": "Пароль обфускації",
|
||||
"obfs_password_placeholder": "Введіть пароль обфускації",
|
||||
"obfs_path": "Обфускаційний шлях",
|
||||
"offline": "Офлайн",
|
||||
"online": "Онлайн",
|
||||
"onlineUsers": "Онлайн користувачі",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Сервери",
|
||||
"path": "Шлях",
|
||||
"please_select": "Будь ласка, виберіть",
|
||||
"plugin": "Конфігурація плагіна",
|
||||
"plugin_opts": "Опції плагіна",
|
||||
"port": "Порт",
|
||||
"protocol_configurations": "Конфігурації протоколів",
|
||||
"protocol_configurations_desc": "Увімкніть та налаштуйте необхідні типи протоколів",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Виберіть метод шифрування",
|
||||
"server_key": "Ключ сервера",
|
||||
"service_name": "Назва служби",
|
||||
"sorted_success": "Успішно відсортовано",
|
||||
"status": "Статус",
|
||||
"subscribeId": "ID підписки",
|
||||
"subscription": "Підписка",
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
"confirm": "Підтвердити",
|
||||
"confirmDelete": "Ви впевнені, що хочете видалити?",
|
||||
"confirmOffline": "Підтвердити офлайн",
|
||||
"copySubscription": "Копіювати підписку",
|
||||
"copySuccess": "Копіювання успішне",
|
||||
"create": "створити",
|
||||
"createSubscription": "Створити підписку",
|
||||
"createSuccess": "Створено успішно",
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
"select_protocol": "Chọn giao thức…",
|
||||
"select_server": "Chọn máy chủ…",
|
||||
"server": "Máy chủ",
|
||||
"sorted_success": "Sắp xếp thành công",
|
||||
"tags": "Thẻ",
|
||||
"tags_description": "Thẻ nhóm quyền (bao gồm ràng buộc kế hoạch và chính sách giao hàng).",
|
||||
"tags_placeholder": "Sử dụng Enter hoặc dấu phẩy (,) để thêm nhiều thẻ",
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
"bandwidth_placeholder": "Nhập băng thông, để trống cho BBR",
|
||||
"basic": "Cấu Hình Cơ Bản",
|
||||
"cancel": "Hủy",
|
||||
"cipher": "Thuật toán Mã hóa",
|
||||
"city": "Thành phố",
|
||||
"config": {
|
||||
"actions": {
|
||||
@@ -49,9 +50,19 @@
|
||||
"drawerEditTitle": "Chỉnh sửa Máy chủ",
|
||||
"edit": "Chỉnh sửa",
|
||||
"enabled": "Đã bật",
|
||||
"encryption_method": "Phương pháp mã hóa",
|
||||
"encryption": "Phương pháp Mã hóa",
|
||||
"encryption_client_padding": "B padding của Client",
|
||||
"encryption_mode": "Chế độ",
|
||||
"encryption_password": "Mật khẩu",
|
||||
"encryption_password_placeholder": "Để trống để tự động tạo, thay thế thủ công cho mã hóa sau lượng tử",
|
||||
"encryption_private_key": "Khóa riêng",
|
||||
"encryption_private_key_placeholder": "Để trống để tự động tạo, thay thế thủ công cho mã hóa sau lượng tử",
|
||||
"encryption_rtt": "RTT",
|
||||
"encryption_server_padding": "B padding của Server",
|
||||
"encryption_ticket": "Thời gian vé",
|
||||
"expireTime": "Thời gian hết hạn",
|
||||
"expired": "Đã hết hạn",
|
||||
"extra": "Cấu hình thêm",
|
||||
"flow": "Lưu lượng",
|
||||
"hop_interval": "Khoảng thời gian nhảy",
|
||||
"hop_ports": "Cổng nhảy",
|
||||
@@ -64,12 +75,16 @@
|
||||
"migrateFailed": "Di chuyển dữ liệu thất bại",
|
||||
"migrated": "Dữ liệu đã được di chuyển thành công",
|
||||
"migrating": "Đang di chuyển...",
|
||||
"mode": "Chế độ",
|
||||
"multiplex": "Rạp chiếu phim",
|
||||
"name": "Tên",
|
||||
"noData": "Không có dữ liệu",
|
||||
"notAvailable": "Không khả dụng",
|
||||
"obfs": "Làm mờ",
|
||||
"obfs_host": "Máy chủ Obfs",
|
||||
"obfs_password": "Mật khẩu làm mờ",
|
||||
"obfs_password_placeholder": "Nhập mật khẩu làm mờ",
|
||||
"obfs_path": "Đường dẫn Obfs",
|
||||
"offline": "Ngoại tuyến",
|
||||
"online": "Trực tuyến",
|
||||
"onlineUsers": "Người dùng trực tuyến",
|
||||
@@ -78,8 +93,6 @@
|
||||
"pageTitle": "Máy chủ",
|
||||
"path": "Đường dẫn",
|
||||
"please_select": "Vui lòng chọn",
|
||||
"plugin": "Cấu Hình Plugin",
|
||||
"plugin_opts": "Tùy Chọn Plugin",
|
||||
"port": "Cổng",
|
||||
"protocol_configurations": "Cấu Hình Giao Thức",
|
||||
"protocol_configurations_desc": "Kích hoạt và cấu hình các loại giao thức cần thiết",
|
||||
@@ -103,6 +116,7 @@
|
||||
"select_encryption_method": "Chọn phương pháp mã hóa",
|
||||
"server_key": "Khóa máy chủ",
|
||||
"service_name": "Tên dịch vụ",
|
||||
"sorted_success": "Sắp xếp thành công",
|
||||
"status": "Trạng thái",
|
||||
"subscribeId": "ID đăng ký",
|
||||
"subscription": "Đăng ký",
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user