fix(viewer): make chat translation controls compact

This commit is contained in:
coyotte508 2026-09-21 21:53:03 +02:00
commit 3666bb0948
4 changed files with 12 additions and 9 deletions

10
pnpm-lock.yaml generated
View file

@ -86,8 +86,8 @@ importers:
viewer:
dependencies:
'@boardgamers/protocol':
specifier: 0.4.0
version: 0.4.0
specifier: 0.4.2
version: 0.4.2
container-engine:
specifier: workspace:../engine
version: link:../engine
@ -1042,10 +1042,10 @@ packages:
}
engines: { node: '>=6.9.0' }
'@boardgamers/protocol@0.4.0':
'@boardgamers/protocol@0.4.2':
resolution:
{
integrity: sha512-dqrU94QGPZAh7vWhHmu2AHY6bFo7NbNVytb3dyUidou8R6P0FfT3xm0qLR8LbrE4EHEYmm99LajdfTfKmgwEzQ==,
integrity: sha512-dFWwj/uIR8LZuiFSPX++63f4Ivd3cG4JFFWCCObOu6u5RYw5GBT95rcSIiiWRLkBkXWKXgv3awQ/RMrAf+uFDQ==,
}
'@cspotcode/source-map-support@0.8.1':
@ -11586,7 +11586,7 @@ snapshots:
'@babel/helper-string-parser': 7.29.7
'@babel/helper-validator-identifier': 7.29.7
'@boardgamers/protocol@0.4.0':
'@boardgamers/protocol@0.4.2':
dependencies:
zod: 4.6.2

View file

@ -18,7 +18,7 @@ allowBuilds:
autoInstallPeers: false
minimumReleaseAgeExclude:
- '@boardgamers/protocol@0.4.0'
- '@boardgamers/protocol@0.4.0 || 0.4.2'
- '@boardgamers/protocol@0.2.2 || 0.3.0 || 0.3.1 || 0.3.3'
# The cli-plugin-typescript fork-ts-checker shim does a bare

View file

@ -1,6 +1,6 @@
{
"name": "container-viewer",
"version": "2.0.4",
"version": "2.0.5",
"repository": {
"type": "git",
"url": "git+https://github.com/boardgamers/container.git",
@ -19,7 +19,7 @@
"preview:tutorial": "node scripts/tutorial-preview.mjs"
},
"dependencies": {
"@boardgamers/protocol": "0.4.0",
"@boardgamers/protocol": "0.4.2",
"container-engine": "workspace:../engine",
"core-js": "^3.6.5",
"lodash": "^4.17.19",

View file

@ -33,7 +33,10 @@ export function mountGameChat(emitter: ViewerEmitter<any, any>, host: Element):
.bgs-game-chat button:disabled{color:#788786;border-color:#b0bcb8;background:#dce3df;cursor:default}
.bgs-game-chat .chat-mention{height:auto;padding:0 2px;border:0;background:transparent;color:inherit;font:inherit;font-weight:bold;text-decoration:underline}
.bgs-game-chat article a{color:inherit;text-decoration:underline}
.bgs-game-chat .chat-translate{height:auto;min-height:24px;padding:2px 4px;margin-left:6px;border:0;background:transparent;color:inherit;font-size:.8em;text-decoration:underline}
.bgs-game-chat .chat-translate{display:inline-flex;align-items:center;justify-content:center;vertical-align:middle;width:24px;height:24px;min-height:0;padding:4px;margin-left:3px;border:0;background:transparent;color:inherit;opacity:.55}
.bgs-game-chat .chat-translate:hover,.bgs-game-chat .chat-translate:focus-visible{opacity:1}
.bgs-game-chat .chat-translate[aria-pressed="true"]{opacity:1;background:#75818d26}
.bgs-game-chat .chat-translate[aria-busy="true"]{background:transparent;cursor:wait}
.chat-suggestions{display:flex;flex-wrap:wrap;gap:4px;margin-top:4px}
.chat-suggestions:empty{display:none}
.chat-suggestions button[aria-pressed="true"]{outline:2px solid #527f89}