mirror of
https://gitee.com/wanwujie/sub2api
synced 2026-05-05 13:40:44 +08:00
feat(channels): themed model popover + group-badge with rate, subscription & exclusivity
Pricing popover: - Teleport to body + fixed-position re-measuring on hover/scroll/resize so it escapes the card's overflow-hidden clip that was chopping off the lower half of the panel. - Header + border adopt the platform theme via platformBorderClass / platformBadgeLightClass so each model card reads at a glance. Accessible groups: - Backend AvailableGroupRef / user DTO now expose subscription_type, rate_multiplier and is_exclusive. User-specific rates continue to come from /groups/rates (same pattern as the API keys page). - Table renders groups through the shared GroupBadge, which already deepens subscription-type colors and shows default vs custom rate as <s>default</s> <b>custom</b>. - Exclusive groups are labelled with a purple shield row, public groups with a grey globe row so admins and users can tell at a glance which groups they got via explicit grant vs. public access. i18n keys for exclusive / public / their tooltips added to zh + en.
This commit is contained in:
@@ -10,6 +10,12 @@ export interface UserAvailableGroup {
|
||||
id: number
|
||||
name: string
|
||||
platform: string
|
||||
/** 'standard' | 'subscription' — 订阅分组视觉加深,和 API 密钥页保持一致。 */
|
||||
subscription_type: string
|
||||
/** 分组默认倍率。用户专属倍率(若有)通过 /groups/rates 获取后在前端 join。 */
|
||||
rate_multiplier: number
|
||||
/** true = 专属分组(小范围授权);false = 公开分组。 */
|
||||
is_exclusive: boolean
|
||||
}
|
||||
|
||||
export interface UserPricingInterval {
|
||||
|
||||
Reference in New Issue
Block a user