团队页(P0,sub-agent):创建账户(role-choice双卡+随机生成+每日/月/总额三档)、 分享凭据(cred-card+单项/一键复制)、编辑成员/重置密码(警示框)/月限额(5预设pill+实时剩余), 全用 TeamModal 外壳 + team-page.css restraint token 重写(不复用 styles.css 旧暖米类) 账户页(P0,sub-agent):充值扫码弹窗(QR占位+金额+赠送+双按钮)、三表 filter-bar、 项目/成员表列重排(role-pill/progress-mini/status-tag),CSS 在 account-page.css 验证: tsc 0 · build 0 · 走查 团队2弹窗(role-choice双卡/三额度/预设)+账户充值弹窗 开关ESC 全过 · 3 筛选条在 · 0 console error ⚠️ 真实数据缺(未造假,已降级):Project 无 owner 字段→账户项目表去「成员+角色」列; TeamMember 无完成数/最近活跃→去这两列。需后端补字段才能完整还原(移交监督)。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
188 lines
17 KiB
CSS
188 lines
17 KiB
CSS
/* 团队页 · 从 public/exact/team.html 内联 <style> 忠实移植(仅页面结构 9-127,
|
|
modal 段沿用共享 TeamModal,默认隐藏不入 diff),整段 scope 进 .team-page 防冲突。
|
|
依赖 design-restraint.css 的全局 .stat(padding 24/28 + border-right)——与镜像 restraint.css 一致。 */
|
|
.team-page {
|
|
/* ─── 团队信息卡(深色 banner · 上标题行 + 下统计行)─── */
|
|
.team-top { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; margin-bottom: 24px; align-items: stretch; }
|
|
|
|
.team-banner {
|
|
background: var(--accent-black);
|
|
color: var(--accent-white);
|
|
padding: 22px 28px 24px;
|
|
position: relative;
|
|
border: 1px solid var(--accent-black);
|
|
border-radius: var(--r-md);
|
|
}
|
|
|
|
/* ─── 团队动态卡(贴 banner 右边)─── */
|
|
.team-feed { background: var(--surface); border: 1px solid var(--border-faint); border-radius: var(--r-md); padding: 16px 18px; display: flex; flex-direction: column; min-width: 0; }
|
|
.team-feed .h { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
|
|
.team-feed .h h3 { font-size: 14px; font-weight: 600; margin: 0; }
|
|
.team-feed .h .ct { font-family: var(--font-mono); font-size: 12px; color: var(--black-alpha-48); }
|
|
.team-feed .h .more { margin-left: auto; font-family: var(--font-mono); font-size: 12px; color: var(--heat); text-decoration: none; cursor: pointer; }
|
|
.team-feed .feed-list { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; max-height: 240px; padding-right: 4px; scrollbar-width: thin; }
|
|
.team-feed .feed-list::-webkit-scrollbar { width: 4px; }
|
|
.team-feed .feed-list::-webkit-scrollbar-thumb { background: var(--border-faint); border-radius: 2px; }
|
|
.team-feed .feed-item { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 10px; align-items: start; }
|
|
.team-feed .feed-item .av { width: 24px; height: 24px; border-radius: 50%; background: var(--background-lighter); border: 1px solid var(--border-faint); display: grid; place-items: center; font-size: 12px; font-weight: 600; color: var(--accent-black); }
|
|
.team-feed .feed-item .txt { font-size: 13px; line-height: 1.45; color: var(--accent-black); min-width: 0; }
|
|
.team-feed .feed-item .txt .who { font-weight: 600; }
|
|
.team-feed .feed-item .txt .act { color: var(--black-alpha-56); margin: 0 3px; }
|
|
.team-feed .feed-item .txt .obj { color: var(--heat); }
|
|
.team-feed .feed-item .txt .obj-money { color: var(--accent-forest); font-variant-numeric: tabular-nums; font-family: var(--font-mono); }
|
|
.team-feed .feed-item .ts { font-family: var(--font-mono); font-size: 12px; color: var(--black-alpha-48); margin-top: 2px; letter-spacing: .02em; }
|
|
/* 4 个装订线小十字(2 个 pseudo + 2 个 span)*/
|
|
.team-banner::before, .team-banner::after,
|
|
.team-banner > .corner-tr, .team-banner > .corner-bl {
|
|
content: ''; position: absolute; width: 14px; height: 14px;
|
|
background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 21' fill='%23e8e8e8'%3E%3Cpath d='M10.5 4C10.5 7.31371 7.81371 10 4.5 10H0.5V11H4.5C7.81371 11 10.5 13.6863 10.5 17V21H11.5V17C11.5 13.6863 14.1863 11 17.5 11H21.5V10H17.5C14.1863 10 11.5 7.31371 11.5 4V0H10.5V4Z'/%3E%3C/svg%3E") no-repeat center;
|
|
background-size: contain; pointer-events: none;
|
|
}
|
|
.team-banner::before { top: -7px; left: -7px; }
|
|
.team-banner::after { bottom: -7px; right: -7px; }
|
|
.team-banner > .corner-tr { top: -7px; right: -7px; }
|
|
.team-banner > .corner-bl { bottom: -7px; left: -7px; }
|
|
|
|
/* 第 1 行:标题 + 主操作 */
|
|
.banner-head { display: flex; align-items: flex-start; gap: 20px; }
|
|
.banner-id { flex: 1; min-width: 0; }
|
|
.banner-id .lbl { font-family: var(--font-mono); font-size: 12px; color: rgba(255,255,255,.55); letter-spacing: .06em; text-transform: uppercase; }
|
|
.banner-id .nm { font-size: 22px; font-weight: 700; letter-spacing: -.012em; margin-top: 4px; display: flex; align-items: baseline; gap: 10px; }
|
|
.banner-id .nm .tag { font-size: 12px; font-family: var(--font-mono); padding: 2px 8px; background: rgba(255,255,255,.12); border-radius: var(--r-pill); letter-spacing: .04em; font-weight: 500; }
|
|
.banner-id .meta { font-size: 12px; color: rgba(255,255,255,.5); margin-top: 6px; font-family: var(--font-mono); letter-spacing: .02em; }
|
|
.banner-actions { display: flex; gap: 8px; flex-shrink: 0; }
|
|
.banner-actions .btn { background: var(--accent-white); color: var(--accent-black); border-color: var(--accent-white); }
|
|
.banner-actions .btn:hover { background: var(--background-base); }
|
|
.banner-actions .btn-ghost { background: transparent; color: var(--accent-white); border: 1px solid rgba(255,255,255,.25); }
|
|
.banner-actions .btn-ghost:hover { background: rgba(255,255,255,.08); color: var(--accent-white); }
|
|
|
|
/* 分隔线 */
|
|
.banner-divider { height: 1px; background: rgba(255,255,255,.1); margin: 20px 0 18px; }
|
|
|
|
/* 第 2 行:4 列统计 */
|
|
.banner-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
|
|
.banner-stats .stat { min-width: 0; }
|
|
.banner-stats .stat .lbl { font-family: var(--font-mono); font-size: 12px; color: rgba(255,255,255,.55); letter-spacing: .06em; text-transform: uppercase; }
|
|
.banner-stats .stat .v { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -.012em; margin-top: 6px; }
|
|
/* color 必须显式写,否则会被 restraint.css 全局 .stat .v 的 color: var(--accent-black) 覆盖成黑字 */
|
|
.banner-stats .stat .v { color: var(--accent-white); }
|
|
.banner-stats .stat .v.warn { color: #FFB870; }
|
|
.banner-stats .stat .sub { font-size: 12px; color: rgba(255,255,255,.5); margin-top: 4px; font-family: var(--font-mono); letter-spacing: .02em; }
|
|
|
|
/* ─── 主体两栏 ─── */
|
|
.team-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; }
|
|
|
|
.pane { background: var(--surface); border: 1px solid var(--border-faint); border-radius: var(--r-md); padding: 20px; margin-bottom: 16px; }
|
|
.pane h3 { font-size: 14px; font-weight: 600; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
|
|
.pane h3 .ct { font-family: var(--font-mono); font-size: 12px; color: var(--black-alpha-48); font-weight: 400; }
|
|
.pane h3 .spacer { margin-left: auto; }
|
|
|
|
/* ─── 成员表 ─── */
|
|
.members-table th { white-space: nowrap; }
|
|
.members-table .av { flex: 0 0 32px; width: 32px; height: 32px; border-radius: 50%; background: var(--background-lighter); display: inline-grid; place-items: center; font-weight: 600; font-size: 13px; color: var(--accent-black); border: 1px solid var(--border-faint); }
|
|
.members-table .who { display: flex; align-items: center; gap: 10px; }
|
|
.members-table .member-cell { display: flex; align-items: center; gap: 10px; min-width: 0; }
|
|
.members-table .member-cell .member-meta { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
|
|
.members-table .nm { font-weight: 500; font-size: 14px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 260px; }
|
|
.members-table .em { font-size: 12px; color: var(--black-alpha-48); font-family: var(--font-mono); line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 260px; }
|
|
.members-table .role-pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--r-pill); font-size: 12px; font-weight: 500; }
|
|
.members-table .role-pill .dot { width: 6px; height: 6px; border-radius: 50%; }
|
|
.members-table .role-super { background: var(--heat-12); color: var(--heat); }
|
|
.members-table .role-super .dot { background: var(--heat); }
|
|
.members-table .role-admin { background: rgba(30,64,175,.1); color: #1E40AF; }
|
|
.members-table .role-admin .dot { background: #1E40AF; }
|
|
.members-table .role-member { background: var(--background-lighter); color: var(--black-alpha-56); }
|
|
.members-table .role-member .dot { background: var(--black-alpha-56); }
|
|
.members-table .quota-cell { font-variant-numeric: tabular-nums; font-family: var(--font-mono); font-size: 12px; }
|
|
.members-table .quota-cell .lbl { color: var(--black-alpha-48); }
|
|
.members-table .quota-cell .v { color: var(--accent-black); font-weight: 600; }
|
|
.members-table .used-bar { width: 80px; height: 4px; background: var(--background-lighter); border-radius: 2px; overflow: hidden; margin-top: 4px; }
|
|
.members-table .used-bar > span { display: block; height: 100%; background: var(--heat); }
|
|
.members-table .used-bar > span.ok { background: var(--accent-forest); }
|
|
.members-table .used-bar > span.warn { background: #B45309; }
|
|
.members-table .acts { display: flex; gap: 4px; justify-content: flex-end; }
|
|
.members-table .icon-btn-sm { width: 28px; height: 28px; display: inline-grid; place-items: center; border: 1px solid var(--border-faint); border-radius: var(--r-sm); background: var(--surface); cursor: pointer; color: var(--black-alpha-56); transition: all var(--t-base); }
|
|
.members-table .icon-btn-sm:hover { color: var(--heat); border-color: var(--heat-20); }
|
|
.members-table .icon-btn-sm svg { width: 14px; height: 14px; }
|
|
.members-table .icon-btn-sm.danger:hover { color: var(--accent-crimson); border-color: var(--accent-crimson); }
|
|
.members-table tr.pending td { opacity: .65; }
|
|
.members-table tr.pending .nm::after { content: '· 待激活'; font-size: 12px; color: var(--black-alpha-48); margin-left: 6px; font-weight: 400; font-family: var(--font-mono); }
|
|
|
|
/* ─── 角色权限矩阵 ─── */
|
|
.perm-table { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); border: 1px solid var(--border-muted); border-radius: var(--r-md); overflow: hidden; font-size: 13px; }
|
|
.perm-table th, .perm-table td { padding: 8px 10px; border-bottom: 0; }
|
|
.perm-table th { border-bottom: 1px solid var(--border-muted); background: var(--background-lighter); font-family: var(--font-mono); font-size: 12px; font-weight: 500; color: var(--black-alpha-48); letter-spacing: .04em; text-transform: uppercase; text-align: left; }
|
|
.perm-table th:not(:first-child), .perm-table td:not(:first-child) { text-align: center; }
|
|
.perm-table tbody td:first-child { color: var(--accent-black); }
|
|
.perm-table .yes { color: var(--accent-forest); font-weight: 600; }
|
|
.perm-table .no { color: var(--black-alpha-32); }
|
|
}
|
|
|
|
/* ═══════════════════════════════════════════════════════════════════
|
|
团队页定制弹窗 · 注意:TeamModal 经 createPortal 挂到 document.body,
|
|
弹窗内容在 .modal.invite-modal 之下、不在 .team-page 内 → 这些类必须
|
|
写在顶层(不能 scope 进 .team-page)。全部用 restraint token,不写裸 hex。
|
|
绝不复用 styles.css 旧暖米调色板的同名类(.role-choice/.cred-card 等)。
|
|
═══════════════════════════════════════════════════════════════════ */
|
|
|
|
/* 共用:字段必填星标 / 标签副注 */
|
|
.invite-modal .field-label .req { color: var(--accent-crimson); margin-left: 2px; }
|
|
.invite-modal .field-label .lbl-note { color: var(--black-alpha-48); font-weight: 400; margin-left: 2px; font-family: var(--font-mono); }
|
|
|
|
/* 共用:输入框 + 行内随机生成按钮 */
|
|
.invite-modal .input-with-gen { display: flex; gap: 8px; }
|
|
.invite-modal .input-with-gen .input { flex: 1; min-width: 0; }
|
|
.invite-modal .input-with-gen .btn-sm { height: 38px; padding: 0 12px; flex: 0 0 auto; }
|
|
.invite-modal .pw-input { letter-spacing: .04em; }
|
|
/* 数字输入去掉 spinner(对齐设计稿) */
|
|
.invite-modal .num-input::-webkit-outer-spin-button,
|
|
.invite-modal .num-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
|
|
.invite-modal .num-input { -moz-appearance: textfield; font-variant-numeric: tabular-nums; }
|
|
|
|
/* ─── 角色双卡(创建账户 / 编辑成员共用)─── */
|
|
.invite-modal .role-choices { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
|
|
.invite-modal .role-choice { padding: 12px 14px; border: 1px solid var(--border-faint); border-radius: var(--r-md); cursor: pointer; transition: border-color var(--t-base), background var(--t-base); }
|
|
.invite-modal .role-choice:hover { background: var(--background-lighter); }
|
|
.invite-modal .role-choice.selected { border-color: var(--heat); background: var(--heat-12); }
|
|
.invite-modal .role-choice .title { font-size: 13px; font-weight: 600; color: var(--accent-black); }
|
|
.invite-modal .role-choice .desc { font-size: 11px; color: var(--black-alpha-56); margin-top: 2px; font-family: var(--font-mono); letter-spacing: .02em; }
|
|
|
|
/* ─── 创建账户:三档额度网格 ─── */
|
|
.create-acct-modal .quota-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
|
|
.create-acct-modal .quota-cell { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
|
|
.create-acct-modal .quota-cell .qk { font-family: var(--font-mono); font-size: 10.5px; color: var(--black-alpha-48); letter-spacing: .02em; }
|
|
.create-acct-modal .quota-cell .input { height: 34px; padding: 0 10px; }
|
|
|
|
/* ─── 分享凭据:cred-card(icon 沿用 .ic-m 单橙锚点,符合「全场只有一个 accent」)─── */
|
|
.share-acct-modal .cred-card { background: var(--background-lighter); border: 1px solid var(--border-faint); border-radius: var(--r-md); overflow: hidden; }
|
|
.share-acct-modal .cred-row { display: grid; grid-template-columns: 80px minmax(0, 1fr) 28px; gap: 12px; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--border-faint); }
|
|
.share-acct-modal .cred-row:last-child { border-bottom: 0; }
|
|
.share-acct-modal .cred-row .ck { font-size: 11.5px; color: var(--black-alpha-48); font-family: var(--font-mono); letter-spacing: .02em; }
|
|
.share-acct-modal .cred-row .cv { font-size: 13px; color: var(--accent-black); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
.share-acct-modal .cred-row .cv.mono { font-family: var(--font-mono); letter-spacing: .04em; }
|
|
.share-acct-modal .cred-copy { width: 28px; height: 28px; background: transparent; border: 1px solid var(--border-faint); border-radius: var(--r-sm); color: var(--black-alpha-56); display: grid; place-items: center; cursor: pointer; transition: border-color var(--t-base), color var(--t-base); }
|
|
.share-acct-modal .cred-copy:hover { border-color: var(--heat-20); color: var(--heat); }
|
|
.share-acct-modal .cred-rules { margin-top: 14px; font-family: var(--font-mono); font-size: 11px; color: var(--black-alpha-56); letter-spacing: .02em; line-height: 1.7; }
|
|
.share-acct-modal .cred-rules .li { display: flex; gap: 8px; }
|
|
.share-acct-modal .cred-rules .li::before { content: '//'; color: var(--black-alpha-32); flex: 0 0 auto; }
|
|
.share-acct-modal .cred-copy-all { margin-top: 14px; }
|
|
.share-acct-modal .cred-copy-all .btn-sm { width: 100%; justify-content: center; }
|
|
|
|
/* ─── 编辑成员:只读用户名框 ─── */
|
|
.edit-member-modal .readonly-input { background: var(--background-lighter); color: var(--black-alpha-56); cursor: not-allowed; }
|
|
|
|
/* ─── 重置密码:警示框 ─── */
|
|
.reset-pwd-modal .reset-pwd-warn { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; background: var(--heat-12); border: 1px solid var(--heat-20); border-radius: var(--r-md); margin-bottom: 14px; font-size: 12.5px; color: var(--heat); line-height: 1.5; }
|
|
.reset-pwd-modal .reset-pwd-warn svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; }
|
|
|
|
/* ─── 设置月限额:快捷预设 pill + 实时剩余额度 ─── */
|
|
.limit-modal .limit-presets { display: flex; flex-wrap: wrap; gap: 6px; }
|
|
.limit-modal .limit-presets .lp { height: 32px; padding: 0 12px; background: var(--surface); border: 1px solid var(--border-faint); border-radius: var(--r-pill); font-size: 12px; font-family: var(--font-mono); color: var(--accent-black); cursor: pointer; font-variant-numeric: tabular-nums; transition: border-color var(--t-base), background var(--t-base), color var(--t-base); }
|
|
.limit-modal .limit-presets .lp:hover { border-color: var(--heat-20); background: var(--heat-12); color: var(--heat); }
|
|
.limit-modal .limit-presets .lp.selected { border-color: var(--heat); background: var(--heat-12); color: var(--heat); font-weight: 600; }
|
|
.limit-modal .limit-info { margin-top: 14px; padding: 10px 12px; background: var(--background-lighter); border-radius: var(--r-md); font-size: 11.5px; display: flex; flex-direction: column; gap: 4px; }
|
|
.limit-modal .limit-info .li-row { display: flex; align-items: baseline; gap: 8px; }
|
|
.limit-modal .limit-info .lk { font-family: var(--font-mono); color: var(--black-alpha-48); letter-spacing: .02em; }
|
|
.limit-modal .limit-info .lv { margin-left: auto; font-variant-numeric: tabular-nums; color: var(--accent-black); font-weight: 600; }
|
|
.limit-modal .limit-info .lv.neg { color: var(--accent-crimson); }
|