[PR #3588] [MERGED] chore: use Intl for date formatting #5462

Closed
opened 2026-10-31 20:47:08 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/MHSanaei/3x-ui/pull/3588
Author: @sh1shd
Created: 11/10/2025
Status: ✅ Merged
Merged: 12/3/2025
Merged by: @MHSanaei

Base: main ← Head: chore/intl-formatting


📝 Commits (4)

  • db97eda chore: use Intl for date formatting
  • 2ec6817 fix: show last traffic reset
  • 2be7ec1 chore: use raw timestamps
  • dd3ae55 fix: remove unnecessary import

📊 Changes

9 files changed (+57 additions, -278 deletions)

View changed files

➖ web/assets/js/util/date-util.js (+0 -151)
📝 web/assets/js/util/index.js (+31 -0)
📝 web/html/common/page.html (+0 -1)
📝 web/html/component/aClientTable.html (+14 -56)
📝 web/html/form/inbound.html (+1 -3)
📝 web/html/inbounds.html (+5 -23)
📝 web/html/index.html (+1 -3)
📝 web/html/modals/inbound_info_modal.html (+3 -18)
📝 web/html/settings/panel/subscription/subpage.html (+2 -23)

📄 Description

What is the pull request?

This pull request reworks the date and time formatting logic. It now uses JavaScript's built-in Intl API for time formatting.

The Intl API supports many locales and works in all popular browsers.

It also formats relative dates in different languages.

Which part of the application is affected by the change?

  • Frontend
  • Backend

Type of Changes

  • Bug fix
  • New feature
  • Refactoring
  • Other

Screenshots

English Russian Persian
image image image

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/MHSanaei/3x-ui/pull/3588 **Author:** [@sh1shd](https://github.com/sh1shd) **Created:** 11/10/2025 **Status:** ✅ Merged **Merged:** 12/3/2025 **Merged by:** [@MHSanaei](https://github.com/MHSanaei) **Base:** `main` ← **Head:** `chore/intl-formatting` --- ### 📝 Commits (4) - [`db97eda`](https://github.com/MHSanaei/3x-ui/commit/db97eda391aba86f4dfd7376a7d1eff9e82c0a9c) chore: use `Intl` for date formatting - [`2ec6817`](https://github.com/MHSanaei/3x-ui/commit/2ec68170d32d0419122065a298f78597b6d92130) fix: show last traffic reset - [`2be7ec1`](https://github.com/MHSanaei/3x-ui/commit/2be7ec124173882f17f1cc6f128dbe083c2c230e) chore: use raw timestamps - [`dd3ae55`](https://github.com/MHSanaei/3x-ui/commit/dd3ae55d78289d54333fd6275ce588336e300094) fix: remove unnecessary import ### 📊 Changes **9 files changed** (+57 additions, -278 deletions) <details> <summary>View changed files</summary> ➖ `web/assets/js/util/date-util.js` (+0 -151) 📝 `web/assets/js/util/index.js` (+31 -0) 📝 `web/html/common/page.html` (+0 -1) 📝 `web/html/component/aClientTable.html` (+14 -56) 📝 `web/html/form/inbound.html` (+1 -3) 📝 `web/html/inbounds.html` (+5 -23) 📝 `web/html/index.html` (+1 -3) 📝 `web/html/modals/inbound_info_modal.html` (+3 -18) 📝 `web/html/settings/panel/subscription/subpage.html` (+2 -23) </details> ### 📄 Description ## What is the pull request? This pull request reworks the date and time formatting logic. It now uses JavaScript's built-in `Intl` API for time formatting. The `Intl` API supports many locales and works in all popular browsers. It also formats relative dates in different languages. ## Which part of the application is affected by the change? - [X] Frontend - [ ] Backend ## Type of Changes - [ ] Bug fix - [ ] New feature - [X] Refactoring - [ ] Other ## Screenshots | English | Russian | Persian | | - | - | - | | <img width="211" height="247" alt="image" src="https://github.com/user-attachments/assets/d0c3b83e-8b20-41e2-88cf-b32f20be6106" /> | <img width="176" height="236" alt="image" src="https://github.com/user-attachments/assets/3fbc7b86-058b-42f6-a0b3-d714406e17e7" /> | <img width="159" height="240" alt="image" src="https://github.com/user-attachments/assets/f721a2b8-af28-490e-bab4-ea8c2b777a66" /> | --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 20:47:08 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
MHSanaei/3x-ui#5462
No description provided.