mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[PR #5935] [MERGED] feat(sub): allow identity tokens on every subscription link #6032
Labels
No labels
backlog
bug
clarification needed
documentation
duplicate
enhancement
github_actions
good first issue
invalid
javascript
New Feature
PR welcomed
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
MHSanaei/3x-ui#6032
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/MHSanaei/3x-ui/pull/5935
Author: @H-TTTTT
Created: 7/13/2026
Status: ✅ Merged
Merged: 7/28/2026
Merged by: @MHSanaei
Base:
main← Head:feat/5659-sub-identity-all-links📝 Commits (1)
5806b74feat(sub): allow identity tokens on every subscription link📊 Changes
29 files changed (+190 additions, -9 deletions)
View changed files
📝
docs/public/openapi.json(+8 -0)📝
frontend/public/openapi.json(+8 -0)📝
frontend/src/generated/examples.ts(+2 -0)📝
frontend/src/generated/schemas.ts(+8 -0)📝
frontend/src/generated/types.ts(+2 -0)📝
frontend/src/generated/zod.ts(+2 -0)📝
frontend/src/models/setting.ts(+1 -0)📝
frontend/src/pages/settings/SubscriptionGeneralTab.tsx(+10 -0)📝
frontend/src/schemas/setting.ts(+1 -0)➕
frontend/src/test/setting-sub-identity.test.ts(+22 -0)📝
internal/sub/remark_vars.go(+5 -1)📝
internal/sub/remark_vars_test.go(+37 -0)📝
internal/sub/service.go(+8 -3)📝
internal/web/entity/entity.go(+6 -5)📝
internal/web/service/setting.go(+5 -0)➕
internal/web/service/setting_sub_identity_test.go(+39 -0)📝
internal/web/translation/ar-EG.json(+2 -0)📝
internal/web/translation/en-US.json(+2 -0)📝
internal/web/translation/es-ES.json(+2 -0)📝
internal/web/translation/fa-IR.json(+2 -0)...and 9 more files
📄 Description
Summary
subShowIdentityOnAllLinksboolean setting, defaulting tofalse, with persistence, generated API schemas, localized labels, and a settings switch.{{EMAIL}}and{{USERNAME}}on every raw, JSON, and Clash subscription-body link when enabled.Closes #5659
Rendered fixture
Template:
{{INBOUND}}-{{EMAIL}}|{{USERNAME}}|📊{{TRAFFIC_LEFT}}|{{STATUS_EMOJI}}DE-alice@x|alice@x|📊80.00GB|✅, secondDEDE-alice@x|alice@x|📊80.00GB|✅, secondDE-alice@x|alice@xVerification
go test ./internal/sub ./internal/web/service -run TestIdentityOnAllLinks -count=1 -vgo test ./internal/sub ./internal/web/service -count=1golangci-lint rungo build ./...npm test -- src/test/setting-sub-identity.test.tsnpm test -- --maxWorkers=1(765 passed)npm run typechecknpm run lintnpm run buildnpm run genfollowed by a clean generated-file diff check🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.