@sensiblestats/widget-react 0.85.0 → 0.86.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +17 -0
- package/dist/index.cjs +767 -283
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +762 -278
- package/dist/index.js.map +1 -1
- package/dist/styles.css +100 -15
- package/package.json +2 -2
package/dist/styles.css
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
--ss-w-cta: #f5a623; --ss-w-cta-ink: #1b1300;
|
|
6
6
|
--ss-w-ink: #14181d; --ss-w-faint: #6b7580; --ss-w-line: #e4e8ec;
|
|
7
7
|
--ss-w-panel: #ffffff; --ss-w-bubble: #f3f5f7; --ss-w-nav: #0e1622;
|
|
8
|
-
--ss-w-pos: #1aa563; --ss-w-neg: #e0524b;
|
|
8
|
+
--ss-w-pos: #1aa563; --ss-w-neg: #e0524b; --ss-w-warn: #c07a00;
|
|
9
9
|
--ss-w-home: #3a63a8; --ss-w-away: #c8102e; --ss-w-track: #e9edf1;
|
|
10
10
|
--ss-w-correct: #1f9d55; --ss-w-wrong: #b9bbc2;
|
|
11
11
|
--ss-w-radius: 16px; --ss-w-offset-x: 20px; --ss-w-offset-y: 20px;
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
--ss-w-accent: #37c891; --ss-w-cta: #ffb638; --ss-w-cta-ink: #1b1300;
|
|
18
18
|
--ss-w-ink: #e8edf2; --ss-w-faint: #8b95a1;
|
|
19
19
|
--ss-w-line: #2a3441; --ss-w-panel: #141b24; --ss-w-bubble: #1e2732; --ss-w-nav: #0a0f16;
|
|
20
|
-
--ss-w-pos: #37c891; --ss-w-neg: #f0655d;
|
|
20
|
+
--ss-w-pos: #37c891; --ss-w-neg: #f0655d; --ss-w-warn: #e0a030;
|
|
21
21
|
--ss-w-home: #5b83c8; --ss-w-away: #e8384f; --ss-w-track: #232d3a;
|
|
22
22
|
--ss-w-correct: #37c86b; --ss-w-wrong: #3a3a41;
|
|
23
23
|
}
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
--ss-w-accent: #37c891; --ss-w-cta: #ffb638; --ss-w-cta-ink: #1b1300;
|
|
27
27
|
--ss-w-ink: #e8edf2; --ss-w-faint: #8b95a1;
|
|
28
28
|
--ss-w-line: #2a3441; --ss-w-panel: #141b24; --ss-w-bubble: #1e2732; --ss-w-nav: #0a0f16;
|
|
29
|
-
--ss-w-pos: #37c891; --ss-w-neg: #f0655d;
|
|
29
|
+
--ss-w-pos: #37c891; --ss-w-neg: #f0655d; --ss-w-warn: #e0a030;
|
|
30
30
|
--ss-w-home: #5b83c8; --ss-w-away: #e8384f; --ss-w-track: #232d3a;
|
|
31
31
|
--ss-w-correct: #37c86b; --ss-w-wrong: #3a3a41;
|
|
32
32
|
}
|
|
@@ -1003,8 +1003,13 @@
|
|
|
1003
1003
|
.ss-w-fandash-live-team-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; font-weight: 700; line-height: 1.15; color: var(--ss-w-ink); }
|
|
1004
1004
|
.ss-w-fandash-live-score-main { display: flex; align-items: baseline; justify-content: center; font-size: 36px; font-weight: 850; font-variant-numeric: tabular-nums; line-height: 1; white-space: nowrap; color: var(--ss-w-ink); }
|
|
1005
1005
|
.ss-w-fandash-live-score-sep { color: var(--ss-w-faint); font-weight: 500; margin: 0 5px; }
|
|
1006
|
-
.ss-w-fandash-live-scorers { margin-top: 12px; display: flex; justify-content:
|
|
1007
|
-
.ss-w-fandash-live-scorers
|
|
1006
|
+
.ss-w-fandash-live-scorers-row { margin-top: 12px; display: flex; justify-content: space-between; gap: 10px; }
|
|
1007
|
+
.ss-w-fandash-live-scorers { display: flex; align-items: center; gap: 7px; min-width: 0; font-size: 12.5px; color: var(--ss-w-faint); overflow-wrap: anywhere; }
|
|
1008
|
+
.ss-w-fandash-live-scorers--home { justify-content: flex-start; }
|
|
1009
|
+
.ss-w-fandash-live-scorers--away { justify-content: flex-end; }
|
|
1010
|
+
.ss-w-fandash-live-scorers--home .ss-w-fandash-live-scorers-icon { color: var(--ss-w-home); }
|
|
1011
|
+
.ss-w-fandash-live-scorers--away .ss-w-fandash-live-scorers-icon { color: var(--ss-w-away); }
|
|
1012
|
+
.ss-w-fandash-live-scorers-icon { flex: none; }
|
|
1008
1013
|
|
|
1009
1014
|
/* live timeline: a compact two-sided event list down a centre spine -- each club's events sit on
|
|
1010
1015
|
its own side (home left, away right), most-recent 3 shown with a "See more" toggle for the
|
|
@@ -1157,7 +1162,7 @@
|
|
|
1157
1162
|
.ss-w-sq-name { font-size: 13px; font-weight: 600; color: var(--ss-w-ink); }
|
|
1158
1163
|
.ss-w-sq-name { flex: 1; min-width: 0; }
|
|
1159
1164
|
.ss-w-sq-name-1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
|
1160
|
-
.ss-w-sq-seg { display: flex;
|
|
1165
|
+
.ss-w-sq-seg { display: flex; gap: 2px; padding: 2px; border-radius: var(--ss-w-radius); background: var(--ss-w-track); }
|
|
1161
1166
|
.ss-w-sq-seg-btn { flex: 1; padding: 5px 8px; border: 0; border-radius: calc(var(--ss-w-radius) - 2px); background: transparent; font: inherit; font-size: 12px; font-weight: 600; color: var(--ss-w-faint); cursor: pointer; }
|
|
1162
1167
|
.ss-w-sq-seg-btn[aria-pressed="true"] { background: var(--ss-w-panel); color: var(--ss-w-ink); }
|
|
1163
1168
|
.ss-w-sq-seg-btn:focus-visible, .ss-w-sq-tap:focus-visible, .ss-w-pd-back:focus-visible { outline: 2px solid var(--ss-w-accent); outline-offset: 1px; }
|
|
@@ -1165,15 +1170,95 @@
|
|
|
1165
1170
|
.ss-w-sq-col { flex: none; width: 40px; text-align: center; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ss-w-ink); }
|
|
1166
1171
|
.ss-w-sq-head { border-bottom: 0; padding-bottom: 0; }
|
|
1167
1172
|
.ss-w-sq-head .ss-w-sq-col { font-size: 10px; font-weight: 700; color: var(--ss-w-faint); }
|
|
1168
|
-
.ss-w-
|
|
1169
|
-
.ss-w-
|
|
1170
|
-
.ss-w-
|
|
1171
|
-
.ss-w-
|
|
1172
|
-
.ss-w-
|
|
1173
|
-
.ss-w-
|
|
1174
|
-
.ss-w-
|
|
1175
|
-
.ss-w-
|
|
1176
|
-
.ss-w-
|
|
1173
|
+
.ss-w-sq-stats { padding-top: 10px; gap: 10px; }
|
|
1174
|
+
.ss-w-sq-card { background: var(--ss-w-panel); border: 1px solid var(--ss-w-line); border-radius: 12px; overflow: hidden; }
|
|
1175
|
+
.ss-w-sq-stats .ss-w-sq-row { display: grid; grid-template-columns: 1fr 26px 30px 36px 20px 20px 20px 20px 36px; gap: 0; padding: 7px 10px; font-size: 11px; }
|
|
1176
|
+
.ss-w-sq-card > :last-child { border-bottom: 0; }
|
|
1177
|
+
.ss-w-sq-pos, .ss-w-sq-c20, .ss-w-sq-c30, .ss-w-sq-c36 { text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 11px; font-weight: 400; font-variant-numeric: tabular-nums; color: var(--ss-w-ink); }
|
|
1178
|
+
.ss-w-sq-stats .ss-w-sq-head { padding-bottom: 7px; border-bottom: 1px solid var(--ss-w-line); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; color: var(--ss-w-faint); }
|
|
1179
|
+
.ss-w-sq-stats .ss-w-sq-head > span { font-size: 9px; font-weight: 700; color: var(--ss-w-faint); }
|
|
1180
|
+
.ss-w-sq-player { display: flex; align-items: center; gap: 6px; min-width: 0; }
|
|
1181
|
+
.ss-w-sq-badge { flex: none; width: 18px; height: 18px; border-radius: 6px; background: var(--ss-w-track); color: var(--ss-w-faint); font-size: 9px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
|
|
1182
|
+
.ss-w-sq-stats .ss-w-sq-name { font-size: 11px; }
|
|
1183
|
+
.ss-w-sq-rtg { font-weight: 700; }
|
|
1184
|
+
.ss-w-sq-rtg-none { color: var(--ss-w-faint); font-weight: 400; }
|
|
1185
|
+
.ss-w-sq-stats .ss-w-pos-ink { color: var(--ss-w-pos); font-weight: 700; }
|
|
1186
|
+
.ss-w-sq-foot { padding: 0 2px; font-size: 10.5px; color: var(--ss-w-faint); }
|
|
1187
|
+
.ss-w-sq-bar { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 10px 14px 0; }
|
|
1188
|
+
.ss-w-sq-bar .ss-w-sq-seg { margin: 0; }
|
|
1189
|
+
.ss-w-sq-bar .ss-w-sq-seg:only-child { flex: 1; }
|
|
1190
|
+
.ss-w-sq-bar .ss-w-sq-seg:not(:only-child) { flex: none; }
|
|
1191
|
+
.ss-w-sq-eyebrow { flex: 1; min-width: 0; font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ss-w-faint); }
|
|
1192
|
+
@media (max-width: 429px) { .ss-w-sq-badge { display: none; } }
|
|
1193
|
+
@media (max-width: 359px) {
|
|
1194
|
+
.ss-w-sq-yr { display: none; }
|
|
1195
|
+
.ss-w-sq-stats .ss-w-sq-row { grid-template-columns: 1fr 26px 30px 36px 20px 20px 36px; }
|
|
1196
|
+
}
|
|
1197
|
+
.ss-w-pd-bar { flex: none; display: flex; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--ss-w-line); line-height: normal; }
|
|
1198
|
+
.ss-w-pd-back { display: flex; align-items: center; gap: 2px; min-height: 32px; padding: 8px 8px 8px 0; margin: -8px 0; border: 0; background: transparent; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--ss-w-faint); cursor: pointer; }
|
|
1199
|
+
.ss-w-pd-back:hover { color: var(--ss-w-ink); }
|
|
1200
|
+
.ss-w-mon-list.ss-w-pd-list { padding: 16px; gap: 14px; line-height: normal; }
|
|
1201
|
+
.ss-w-pd-card { background: var(--ss-w-panel); border: 1px solid var(--ss-w-line); border-radius: 12px; }
|
|
1202
|
+
.ss-w-pd-faint { color: var(--ss-w-faint); }
|
|
1203
|
+
.ss-w-pd-profile { display: flex; gap: 12px; padding: 14px; }
|
|
1204
|
+
.ss-w-pd-photo { flex: none; border-radius: 50%; border: 1px solid var(--ss-w-line); background: var(--ss-w-bubble); object-fit: cover; }
|
|
1205
|
+
.ss-w-pd-avatar { display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--ss-w-ink); }
|
|
1206
|
+
.ss-w-pd-profile-main { flex: 1; min-width: 0; }
|
|
1207
|
+
.ss-w-pd-name { font-size: 16px; font-weight: 800; color: var(--ss-w-ink); overflow-wrap: break-word; }
|
|
1208
|
+
.ss-w-pd-sub { margin-top: 1px; font-size: 12px; color: var(--ss-w-faint); }
|
|
1209
|
+
/* Two columns as on the board, collapsing to one when a column would drop under 80px (narrow phones). */
|
|
1210
|
+
.ss-w-pd-bio { display: grid; grid-template-columns: repeat(auto-fill, minmax(max(80px, calc((100% - 10px) / 2)), 1fr)); gap: 4px 10px; margin-top: 10px; font-size: 11.5px; }
|
|
1211
|
+
.ss-w-pd-bio-item { min-width: 0; overflow-wrap: break-word; }
|
|
1212
|
+
.ss-w-pd-pitch { position: relative; flex: none; width: 56px; height: 76px; border: 1px solid var(--ss-w-line); border-radius: 6px; background: var(--ss-w-track); }
|
|
1213
|
+
.ss-w-pd-pitch-dot { position: absolute; width: 11px; height: 11px; border-radius: 50%; background: var(--ss-w-accent); border: 2px solid var(--ss-w-nav); transform: translate(-50%, -50%); }
|
|
1214
|
+
.ss-w-pd-avail { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; }
|
|
1215
|
+
.ss-w-pd-avail-text { min-width: 0; }
|
|
1216
|
+
.ss-w-pd-avail-next { font-size: 12.5px; font-weight: 700; }
|
|
1217
|
+
.ss-w-pd-avail-note { margin-top: 1px; font-size: 11px; color: var(--ss-w-faint); }
|
|
1218
|
+
.ss-w-pd-pill { flex: none; padding: 4px 10px; border-radius: 999px; font-size: 11px; font-weight: 700; white-space: nowrap; }
|
|
1219
|
+
.ss-w-pd-pill--pos, .ss-w-pd-chip--pos { background: color-mix(in srgb, var(--ss-w-pos) 14%, transparent); color: var(--ss-w-pos); }
|
|
1220
|
+
.ss-w-pd-pill--warn, .ss-w-pd-chip--warn { background: color-mix(in srgb, var(--ss-w-warn) 14%, transparent); color: var(--ss-w-warn); }
|
|
1221
|
+
.ss-w-pd-pill--neg, .ss-w-pd-chip--neg { background: color-mix(in srgb, var(--ss-w-neg) 14%, transparent); color: var(--ss-w-neg); }
|
|
1222
|
+
.ss-w-pd-pill--draw { background: var(--ss-w-track); color: var(--ss-w-faint); }
|
|
1223
|
+
.ss-w-pd-eyebrow { font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ss-w-faint); padding: 0 2px; }
|
|
1224
|
+
.ss-w-pd-eyebrow--block { margin-bottom: 8px; }
|
|
1225
|
+
.ss-w-pd-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
|
|
1226
|
+
.ss-w-pd-tile { min-width: 0; padding: 10px; background: var(--ss-w-panel); border: 1px solid var(--ss-w-line); border-radius: 12px; }
|
|
1227
|
+
.ss-w-pd-tile-label { font-size: 10.5px; color: var(--ss-w-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
|
1228
|
+
.ss-w-pd-tile-value { margin-top: 2px; font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; }
|
|
1229
|
+
.ss-w-pd-pos-ink { color: var(--ss-w-pos); }
|
|
1230
|
+
/* Below 360px the board's 10px tile padding clips "Matches"/"Minutes" (43px) in a ~34px label box. */
|
|
1231
|
+
@media (max-width: 359px) {
|
|
1232
|
+
.ss-w-pd-tiles { gap: 6px; }
|
|
1233
|
+
.ss-w-pd-tile { padding: 10px 6px; }
|
|
1234
|
+
}
|
|
1235
|
+
.ss-w-pd-perf-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 2px; }
|
|
1236
|
+
.ss-w-pd-perf-head .ss-w-pd-eyebrow { flex: 1; min-width: 0; }
|
|
1237
|
+
.ss-w-pd-seg { flex: none; display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: var(--ss-w-track); }
|
|
1238
|
+
.ss-w-pd-seg-btn { padding: 5px 12px; border: 0; border-radius: 999px; background: transparent; font: inherit; font-size: 11.5px; font-weight: 700; line-height: normal; white-space: nowrap; color: var(--ss-w-faint); cursor: pointer; }
|
|
1239
|
+
.ss-w-pd-seg-btn[aria-pressed="true"] { background: var(--ss-w-nav); color: #fff; }
|
|
1240
|
+
.ss-w-pd-seg-btn:focus-visible { outline: 2px solid var(--ss-w-accent); outline-offset: 1px; }
|
|
1241
|
+
.ss-w-pd-perf-sub { margin-bottom: 10px; font-size: 11px; color: var(--ss-w-faint); }
|
|
1242
|
+
.ss-w-pd-perf-head + .ss-w-pd-perf-cards { margin-top: 10px; }
|
|
1243
|
+
.ss-w-pd-perf-cards { display: flex; flex-direction: column; gap: 8px; }
|
|
1244
|
+
.ss-w-pd-perf-card { padding: 14px; }
|
|
1245
|
+
.ss-w-pd-perf-group { margin-bottom: 10px; font-size: 12.5px; font-weight: 700; }
|
|
1246
|
+
.ss-w-pd-bar-row + .ss-w-pd-bar-row { margin-top: 12px; }
|
|
1247
|
+
.ss-w-pd-bar-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 5px; font-size: 12.5px; }
|
|
1248
|
+
.ss-w-pd-bar-label { min-width: 0; overflow-wrap: break-word; }
|
|
1249
|
+
.ss-w-pd-bar-value { flex: none; font-weight: 700; font-variant-numeric: tabular-nums; }
|
|
1250
|
+
.ss-w-pd-track { height: 6px; border-radius: 999px; background: var(--ss-w-track); overflow: hidden; }
|
|
1251
|
+
.ss-w-pd-fill { height: 100%; border-radius: 999px; }
|
|
1252
|
+
.ss-w-pd-fill--pos { background: var(--ss-w-pos); }
|
|
1253
|
+
.ss-w-pd-fill--warn { background: var(--ss-w-warn); }
|
|
1254
|
+
.ss-w-pd-fill--neg { background: var(--ss-w-neg); }
|
|
1255
|
+
.ss-w-pd-match { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto auto; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--ss-w-line); }
|
|
1256
|
+
.ss-w-pd-match:last-child { border-bottom: none; }
|
|
1257
|
+
.ss-w-pd-match-date { font-size: 10.5px; color: var(--ss-w-faint); }
|
|
1258
|
+
.ss-w-pd-match-opp { font-size: 12.5px; font-weight: 600; overflow-wrap: break-word; }
|
|
1259
|
+
.ss-w-pd-match-sub { margin-top: 1px; font-size: 10.5px; color: var(--ss-w-faint); }
|
|
1260
|
+
.ss-w-pd-chip-empty { min-width: 30px; }
|
|
1261
|
+
.ss-w-pd-chip { min-width: 30px; padding: 3px 0; border-radius: 6px; text-align: center; font-size: 11.5px; font-weight: 800; font-variant-numeric: tabular-nums; }
|
|
1177
1262
|
.ss-w-rec-list { margin: 0; padding: 0; list-style: none; }
|
|
1178
1263
|
.ss-w-rec-value { flex: none; font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ss-w-ink); }
|
|
1179
1264
|
.ss-w-rec-since { font-size: 12px; color: var(--ss-w-faint); }
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sensiblestats/widget-react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.86.1",
|
|
4
4
|
"description": "Embeddable SensibleStats chat widget for React.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.cjs",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"prepublishOnly": "yarn build"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@sensiblestats/widget-sdk": "^0.
|
|
40
|
+
"@sensiblestats/widget-sdk": "^0.56.0",
|
|
41
41
|
"react-markdown": "^9.0.1",
|
|
42
42
|
"remark-gfm": "^4.0.0"
|
|
43
43
|
},
|