Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4f72dda6fa |
@@ -146,7 +146,7 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.tableHint {
|
.tableHint {
|
||||||
color: #949494;
|
color: #888;
|
||||||
font-size: 0.8rem;
|
font-size: 0.8rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin-top: 1rem;
|
margin-top: 1rem;
|
||||||
@@ -357,7 +357,7 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.seatEmptyLabel {
|
.seatEmptyLabel {
|
||||||
color: #8a8a8a;
|
color: #6d6d6d;
|
||||||
font-size: 0.6rem;
|
font-size: 0.6rem;
|
||||||
letter-spacing: 0.08em;
|
letter-spacing: 0.08em;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
@@ -373,7 +373,7 @@ body {
|
|||||||
top: 2px;
|
top: 2px;
|
||||||
left: 6px;
|
left: 6px;
|
||||||
font-size: 0.58rem;
|
font-size: 0.58rem;
|
||||||
color: #8a8a8a;
|
color: #777;
|
||||||
}
|
}
|
||||||
|
|
||||||
.seatPuckName {
|
.seatPuckName {
|
||||||
@@ -578,7 +578,7 @@ body {
|
|||||||
|
|
||||||
.cardSlot.cardSlotEmpty {
|
.cardSlot.cardSlotEmpty {
|
||||||
background: #191919;
|
background: #191919;
|
||||||
color: #8a8a8a;
|
color: #5c5c5c;
|
||||||
border-style: dashed;
|
border-style: dashed;
|
||||||
border-color: #3f3f3f;
|
border-color: #3f3f3f;
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
@@ -694,7 +694,7 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.addChipsCurrency {
|
.addChipsCurrency {
|
||||||
color: #8a8a8a;
|
color: #777;
|
||||||
font-size: 1.3rem;
|
font-size: 1.3rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -735,7 +735,7 @@ body {
|
|||||||
background: none;
|
background: none;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
color: #d8b46a;
|
color: #a9782f;
|
||||||
font-family: inherit;
|
font-family: inherit;
|
||||||
font-size: 0.78rem;
|
font-size: 0.78rem;
|
||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
@@ -834,7 +834,7 @@ body {
|
|||||||
margin: 0;
|
margin: 0;
|
||||||
padding-top: 0.6rem;
|
padding-top: 0.6rem;
|
||||||
border-top: 1px solid #2c2c2c;
|
border-top: 1px solid #2c2c2c;
|
||||||
color: #8a8a8a;
|
color: #7a7a7a;
|
||||||
font-size: 0.72rem;
|
font-size: 0.72rem;
|
||||||
line-height: 1.45;
|
line-height: 1.45;
|
||||||
}
|
}
|
||||||
@@ -1213,7 +1213,7 @@ body {
|
|||||||
|
|
||||||
.subPanel summary {
|
.subPanel summary {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
color: #9a9a9a;
|
color: #8f8f8f;
|
||||||
font-size: 0.78rem;
|
font-size: 0.78rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1249,7 +1249,7 @@ body {
|
|||||||
|
|
||||||
.fieldHint {
|
.fieldHint {
|
||||||
font-size: 0.75rem;
|
font-size: 0.75rem;
|
||||||
color: #949494;
|
color: #888;
|
||||||
line-height: 1.4;
|
line-height: 1.4;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
@@ -1306,7 +1306,7 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.standingsHeader {
|
.standingsHeader {
|
||||||
color: #8a8a8a;
|
color: #777;
|
||||||
font-size: 0.7rem;
|
font-size: 0.7rem;
|
||||||
letter-spacing: 0.04em;
|
letter-spacing: 0.04em;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
@@ -1374,7 +1374,7 @@ body {
|
|||||||
|
|
||||||
.handHistoryTime {
|
.handHistoryTime {
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
color: #8a8a8a;
|
color: #777;
|
||||||
font-size: 0.72rem;
|
font-size: 0.72rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1494,7 +1494,7 @@ body.hasActionBar #holdemSidebar {
|
|||||||
flex: none;
|
flex: none;
|
||||||
min-width: 3.1rem;
|
min-width: 3.1rem;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
color: #949494;
|
color: #7d7d7d;
|
||||||
font-variant-numeric: tabular-nums;
|
font-variant-numeric: tabular-nums;
|
||||||
transition: color 0.3s ease;
|
transition: color 0.3s ease;
|
||||||
}
|
}
|
||||||
@@ -1732,7 +1732,7 @@ body.hasActionBar #holdemSidebar {
|
|||||||
|
|
||||||
.seatPuckStack {
|
.seatPuckStack {
|
||||||
font-size: 0.58rem;
|
font-size: 0.58rem;
|
||||||
color: #9a9a9a;
|
color: #8f8f8f;
|
||||||
font-variant-numeric: tabular-nums;
|
font-variant-numeric: tabular-nums;
|
||||||
margin-top: 0.1rem;
|
margin-top: 0.1rem;
|
||||||
}
|
}
|
||||||
@@ -1836,7 +1836,7 @@ body.hasActionBar #toastHost {
|
|||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: #949494;
|
color: #888;
|
||||||
font-size: 0.8rem;
|
font-size: 0.8rem;
|
||||||
font-family: inherit;
|
font-family: inherit;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|||||||
@@ -183,10 +183,38 @@ document.addEventListener("DOMContentLoaded", () => {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
document.getElementById("seatCountInput").addEventListener("change", e => {
|
// A seat that has anything of a player in it — a name, chips, cash in, or a hand
|
||||||
HoldemState.resizeSeats(state, Number(e.target.value));
|
// in progress. Shrinking the table throws these away permanently, and it also
|
||||||
hooks.save(state);
|
// orphans them in the session standings, where they keep their winnings but lose
|
||||||
Render.renderAll();
|
// the stack and buy-in the settle-up is worked out from.
|
||||||
|
const seatHasSomeoneIn = player =>
|
||||||
|
!!(player.name && player.name.trim()) ||
|
||||||
|
player.inHand ||
|
||||||
|
(Number(player.stack) || 0) > 0 ||
|
||||||
|
(Number(player.buyIns) || 0) > 0 ||
|
||||||
|
(Number(player.amountOverride) || 0) > 0;
|
||||||
|
|
||||||
|
document.getElementById("seatCountInput").addEventListener("change", async e => {
|
||||||
|
const requested = Math.max(2, Math.min(24, Math.floor(Number(e.target.value)) || state.seatCount));
|
||||||
|
const losing = state.seats.slice(requested).filter(seatHasSomeoneIn);
|
||||||
|
|
||||||
|
if (losing.length > 0) {
|
||||||
|
const who = losing
|
||||||
|
.map((p, i) => HoldemState.displayName(p, requested + state.seats.slice(requested).indexOf(p)))
|
||||||
|
.join(", ");
|
||||||
|
const ok = await Dialog.confirm({
|
||||||
|
title: `Remove ${losing.length} ${losing.length === 1 ? "player" : "players"}?`,
|
||||||
|
message: `Going down to ${requested} seats takes ${who} off the table along with their chips and buy-ins, and their session totals stop adding up.`,
|
||||||
|
confirmLabel: "Remove them",
|
||||||
|
danger: true,
|
||||||
|
});
|
||||||
|
if (!ok) {
|
||||||
|
e.target.value = state.seatCount;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
runUndoable(`Table set to ${requested} seats.`, () => HoldemState.resizeSeats(state, requested));
|
||||||
});
|
});
|
||||||
|
|
||||||
document.getElementById("directionSelect").addEventListener("change", e => {
|
document.getElementById("directionSelect").addEventListener("change", e => {
|
||||||
|
|||||||
Reference in New Issue
Block a user